-
-
Notifications
You must be signed in to change notification settings - Fork 15
Widgets
Widgets are small tiles that can be added by any user to their Project Alice interface. Those widgets usually present some useful information or quick actions the user would want to see on its interface.
Module developers can add widgets to their modules very simply. If you know that you'll be adding widgets to your module beforehand, then you have the option in the "moduler" tool to create them. If you want to add them after your module was generated you will need to add a few files to your module:
- Create a "widgets" directory into your module main directory
- Create the following directories in the "widgets" directory:
- css
- fonts
- js
- lang
- template
Each module has to be uniquely named and needs its own files. Let's take an exemple! We want to create a widget that displays the current year for the module DateDayTimeYear. This is how the module directory tree would look like:
- DateDayTimeYear
- dialogTemplate
- talks
-
widgets
- css
- fonts
- img
- js
- lang
- templates
- CurrentYear.py
- DateDayTimeYear.install
- DateDayTimeYear.py
- README.md
Click on the filenames to view their default content!