Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve interactive messages : tooltips and new lines #109

Open
oblx opened this issue Jul 17, 2018 · 0 comments
Open

Improve interactive messages : tooltips and new lines #109

oblx opened this issue Jul 17, 2018 · 0 comments
Assignees
Labels
enhancement New feature for the Web-API

Comments

@oblx
Copy link
Contributor

oblx commented Jul 17, 2018

Tooltips would be really great to explain what options are about and we could add a simple argument :

{
    "id": "duel-choice",
    "target": "string",
    "uuid": "randomstring",
    "message": "How would like your duel flavored ?",
    "options": 
    [
        {
            "key": "duel-1-kill",
            "value": " [1 Kill]",
            "tooltip": "Duel is over after one reaches 1 kill"
        },
        {
            "key": "duel-5-kill",
            "value": " [5 Kills]",
            "tooltip": "Duel is over after one reaches 5 kills"
        },
        {
            "key": "duel-2-deaths",
            "value": " [2 deaths]",
            "tooltip": "Duel is over after one get killed :\n2 times"
        },
        {
            "key": "duel-cancel",
            "value": " [Cancel]",
            "tooltip": "Cancel this duel\n&cMake love not war"
        },
    ]
}

Maybe we could also improve the way options are displayed with \n, interactive, suffix and prefix. Similar to tooltips but in a different way :

"options": 
[

    {
        "interactive": "false",
        "value": "&f=============&6SEPARATOR&f=============",
        "suffix": "\n"
    },
    {
        "key": "answer-id-whatever",
        "prefix": "Sell it for $200",
        "value": "&a[Accept]",
        "suffix": "\n",
        "interactive": "true"
    },
    {
        "key": "answer-id-whatever",
        "prefix": "Sell it for $300",
        "value": "&c[Much better]",
        "interactive": "true"
    },
    {
        "interactive": "false",
        "value": "\n&f=============&6SEPARATOR&f=============",
    }
]

Would output in chat :

=============SEPARATOR=============
Sell it for $200 [Acceptable]
Sell it for $300 [Much better]
=============SEPARATOR=============

Just some random ideas 🤓

@Valandur Valandur self-assigned this Jul 27, 2018
@Valandur Valandur added the enhancement New feature for the Web-API label Jul 27, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature for the Web-API
Projects
None yet
Development

No branches or pull requests

2 participants