panels: add noSync option

This commit is contained in:
jean-emmanuel 2018-01-30 12:38:51 +01:00
parent 885c15a2a3
commit 3fc792826f
5 changed files with 14 additions and 1 deletions

View file

@ -59,7 +59,10 @@ Panels can contains tabs or widgets. These can be absolutely positioned and can
- usage: spacing size used in `layout` expression, can be set as a `[vertical,horizontal]` array.
- note: this only applies when the panel contains widgets, not tabs
### `noSync`
- type: `boolean`
- default: `false`
- usage: set to `true` to prevent tab changes from synchronizing between clients that share the same session file
## Strip
@ -126,6 +129,11 @@ Modals are buttons that turn into a centered popup panels when enabled. They can
- default: `empty`
- usage: alternative label for the popup
### `noSync`
- type: `boolean`
- default: `false`
- usage: set to `true` to prevent modal's state changes from synchronizing between clients that share the same session file
### `options`
- see panel's [`options`](#panel)

View file

@ -29,6 +29,7 @@ var WidgetManager = class WidgetManager extends EventEmitter {
split: this.widgets[hash].split,
target: this.widgets[hash].getProp('target'),
address: this.widgets[hash].getProp('address'),
noSync: this.widgets[hash].getProp('noSync'),
}
})
}
@ -112,6 +113,7 @@ var WidgetManager = class WidgetManager extends EventEmitter {
split: widget.split,
target: widget.getProp('target'),
address: widget.getProp('address'),
noSync: widget.getProp('noSync'),
}
})

View file

@ -40,6 +40,7 @@ module.exports = class Modal extends Panel {
address:'auto',
preArgs:[],
target:[],
noSync:false,
_chidlren:'children',

View file

@ -42,6 +42,7 @@ module.exports = class Panel extends _widgets_base {
address:'auto',
preArgs:[],
target:[],
noSync:false,
_children:'children',

View file

@ -28,6 +28,7 @@ module.exports = class Root extends Panel {
address:'/root',
preArgs:[],
target:[],
noSync:false,
_children:'children',