This project implements modal dialogs for sciter.js.
- works on Windows, Mac and Linux
- modal dialog with icon
- fully skinnable
- translatable using callback
- any button can open a link in the browser
- git clone the repository
- install packages
npm install - install latest sciter sdk
npm run install-sdk - start the demo
npm run scapp
- A recent version of Node.js
node(tested with 22 LTS) and its package managernpm.- On Windows download and run the installer
- On Linux check the installation guide
You can either add it to your project using npm or by copying the src directory.
- install package
npm install sciter-dialogs
- add the
srcdir to your project
// if using npm import import Dialogs from "node_modules/sciter-dialogs/src/dialogs.js"; // if src copied import Dialogs from "src/dialogs.js"; const value = Dialogs.show("question", "Do you want to update widget?", "yes no cancel");Dialogs.setOptions({ css: [ __DIR__ + "src/dialog-win.css", __DIR__ + "css/test.css", ] });Dialogs.setOptions({ callback: dialogCallback, }); /** * Dialog callback * @param DOMElement root * @return void */ function dialogCallback(root) { // get all dialog elements to translate root.$$("[data-i18n]").map(function(element) { element.textContent += " (i18n)"; }); }- add "don't show again" checkbox
- add keyboard shortcuts to buttons ̲
- in some cases dialog is not modal
