-
Notifications
You must be signed in to change notification settings - Fork 18
Widgets Options v7
- status: complete
- version: 7.x
- follows from: Widgets Operations
When creating a new widget instance via get
or append
node.widgets.get('VisualTimer', options);
node.widgets.append('VisualTimer', root, options);
the following options are available to control:
Core elements
-
title
: sets the title in the header of the widget. If FALSE, the header is removed. Default: the widget's title or en empty string. -
footer
: sets the content in the footer of the widget. If FALSE, the footer is removed. Default: FALSE. -
context
: sets the Bootstrap framework context for the widget (e.g., 'primary', 'danger', etc.'). -
className
: adds a className to the widget's panelDiv element.
Initial state
-
disabled
: if TRUE, the widget will start in a disabled state. Default: FALSE. -
highlighted
: if TRUE, the widget will start in a highlighted state. Default: FALSE. -
collapsed
: if TRUE, the widget will start in a collapsed state. Default: FALSE. -
hidden
: if TRUE, the widget will start in a collapsed state. Default: FALSE.
Buttons in the header
-
closable
: if TRUE a button is added in the header to close (destroy) the widget. -
collapsible
: if TRUE a button is added in the header to collapse/uncollapse the widget. -
collapseTarget
: if specified, when collapsed, a widget is moved inside this element. Note: a shared collapseTarget element for all widgets can be specified via the global widgets setup.
Other
-
docked
: if TRUE, the widget will be docked at the bottom of the page -
storeRef:
if FALSE, the widget is not added tonode.widgets.instances
andnode.widgets.lastAppended
. Default: TRUE. Note: cannot be FALSE ifdocked
is TRUE. -
id
: user-defined id (added as.id
).
Additionally, each widget is assigned a random unique id stored under the
(.wid
property)
-
wid
: random unique widget id.
Go back to the wiki Home.
Copyright (C) 2021 Stefano Balietti
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.