LayerSelectMixin#
- class jdaviz.core.template_mixin.LayerSelectMixin(**kwargs: Any)[source]#
Bases:
VuetifyTemplate
,HubListener
Applies the LayerSelect component as a mixin in the base plugin. This automatically adds traitlets as well as new properties to the plugin with minimal extra code. For multiple instances or custom traitlet names/defaults, use the component instead.
To use in a plugin:
add
LayerSelectMixin
as a mixin to the classuse the traitlets available from the plugin or properties/methods available from
plugin.layer
.
Example template (label and hint are optional):
<plugin-layer-select :items="layer_items" :selected.sync="layer_selected" :show_if_single_entry="true" label="Layer" hint="Select layer." />
Public constructor
Attributes Summary
An instance of a Python list.
A boolean (True, False) trait.
A trait which allows any value.
A trait for unicode strings.
Attributes Documentation
- layer_items#
An instance of a Python list.
- layer_multiselect#
A boolean (True, False) trait.
- layer_selected#
A trait which allows any value.
- layer_viewer#
A trait for unicode strings.