-
-
Notifications
You must be signed in to change notification settings - Fork 188
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
Fancy keyboard #60
Comments
@gerardovf yes, I guess the node-red ui will eat all your special chars but you can prepare the payload in an upstream function node, something like
|
@guidone You were right!! Now only the 'newLine' is still not working... (I wanted to show a 2x2 buttons keyboard) I used this page to get the emoji conversion: http://www.fileformat.info/info/unicode/char/search.htm Then in the upstream function node I inserted: console.log(msg); |
@guidone I also checked that 'newLine' is working with "inline-buttons" console.log(msg); |
Hi guidone,
In python I can create this nice keyboards:
HIGH_BRIGHTNESS_SYMBOL = "\U0001F506" # b'\xF0\x9F\x94\x86'
LOW_BRIGHTNESS_SYMBOL = "\U0001F505" # b'\xF0\x9F\x94\x85'
UPWARDS_BLACK_ARROW = "\U00002B06" # b'\xE2\xAC\x86'
DOWNWARDS_BLACK_ARROW = "\U00002B07" # b'\xE2\xAC\x87'
DOOR = "\U0001f6aa" # b'\xF0\x9F\x9A\xAA'
VERTICAL_TRAFFIC_LIGHT = "\U0001F6A6" # b'\xF0\x9F\x9A\xA6'
CAMERA = "\U0001F4F7" # b'\xF0\x9F\x93\xB7'
def setNormalKeyboard(cid):
markup = types.ReplyKeyboardMarkup()
itembtn11 = types.KeyboardButton(UPWARDS_BLACK_ARROW+"\nBlind #1")
itembtn12 = types.KeyboardButton(UPWARDS_BLACK_ARROW+"\nBlind #2")
itembtn13 = types.KeyboardButton(UPWARDS_BLACK_ARROW+"\nBlind #3")
itembtn14 = types.KeyboardButton(UPWARDS_BLACK_ARROW+"\nBlind #4")
itembtn15 = types.KeyboardButton(HIGH_BRIGHTNESS_SYMBOL+"\nON")
markup.row(itembtn11, itembtn12, itembtn13, itembtn14, itembtn15)
itembtn21 = types.KeyboardButton(DOWNWARDS_BLACK_ARROW+"\nBlind #1")
itembtn22 = types.KeyboardButton(DOWNWARDS_BLACK_ARROW+"\nBlind #2")
itembtn23 = types.KeyboardButton(DOWNWARDS_BLACK_ARROW+"\nBlind #3")
itembtn24 = types.KeyboardButton(DOWNWARDS_BLACK_ARROW+"\nBlind #4")
itembtn25 = types.KeyboardButton(LOW_BRIGHTNESS_SYMBOL+"\nOFF")
markup.row(itembtn21, itembtn22, itembtn23, itembtn24, itembtn25)
itembtn31 = types.KeyboardButton(CAMERA+"#1")
itembtn32 = types.KeyboardButton(CAMERA+"#2")
itembtn33 = types.KeyboardButton(DOOR+"\nSmall Door1")
itembtn34 = types.KeyboardButton(VERTICAL_TRAFFIC_LIGHT+"\nMORE")
markup.row(itembtn31, itembtn32, itembtn33, itembtn34)
Can I do the same with your Chatbot?
The text was updated successfully, but these errors were encountered: