sakura/other-sites/me/botui
2022-06-27 10:35:06 +08:00
..
build First Commit 2022-06-27 10:35:06 +08:00
src First Commit 2022-06-27 10:35:06 +08:00
typings First Commit 2022-06-27 10:35:06 +08:00
.bumpedrc First Commit 2022-06-27 10:35:06 +08:00
.gitignore First Commit 2022-06-27 10:35:06 +08:00
.npmignore First Commit 2022-06-27 10:35:06 +08:00
CHANGELOG.md First Commit 2022-06-27 10:35:06 +08:00
CODE_OF_CONDUCT.md First Commit 2022-06-27 10:35:06 +08:00
CONTRIBUTING.md First Commit 2022-06-27 10:35:06 +08:00
Gulpfile.js First Commit 2022-06-27 10:35:06 +08:00
LICENSE First Commit 2022-06-27 10:35:06 +08:00
package.json First Commit 2022-06-27 10:35:06 +08:00
preview.png First Commit 2022-06-27 10:35:06 +08:00
README.md First Commit 2022-06-27 10:35:06 +08:00
test.html First Commit 2022-06-27 10:35:06 +08:00

BotUI

Join the chat at https://gitter.im/BotUIChat/botui npm npm

A JavaScript framework to create conversational UIs.

Main Site - Read Docs - Examples

Quick look

preview

<div class="botui-app-container" id="botui-app">
  <bot-ui></bot-ui>
</div>
var botui = new BotUI('botui-app'); // give it the id of container

botui.message.bot({ // show first message
  delay: 200,
  content: 'hello'
}).then(function () {
  return botui.message.bot({ // second one
    delay: 1000, // wait 1 sec.
    content: 'how are you?'
  });
}).then(function () {
  return botui.action.button({ // let user do something
    delay: 1000,
    action: [
      {
        text: 'Good',
        value: 'good'
      },
      {
        text: 'Really Good',
        value: 'really_good'
      }
    ]
  });
}).then(function (res) {
  return botui.message.bot({
    delay: 1000,
    content: 'You are feeling ' + res.text + '!'
  });
});

License

MIT License - Copyrights (c) 2017 - Moin Uddin