Class StudioChartsPreviewLoader
java.lang.Object
io.jmix.chartsflowui.kit.meta.loader.StudioChartsPreviewLoader
- All Implemented Interfaces:
StudioPreviewComponentLoader
Studio preview loader for the
charts:chart component.
A real JmixChart is used: even without data ECharts draws the declared title, legend
and axes, which is exactly what the runtime shows for an empty chart. Only the visual skeleton
of the options is mapped (title text, legend, axis types, series names) — data bindings and the
rest of the extensive options model stay design-time-irrelevant.
-
Field Summary
FieldsFields inherited from interface io.jmix.flowui.kit.meta.component.preview.StudioPreviewComponentLoader
FRAGMENT_SCHEMA, MAIN_VIEW_SCHEMA, MAIN_VIEW_TAB_MODE_SCHEMA, VIEW_OR_FRAGMENT_SCHEMAS, VIEW_SCHEMA -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected @Nullable AbstractSeries<?> createSeries(String tagName) booleanisSupported(org.dom4j.Element element) Define the element that this loader can load.@Nullable com.vaadin.flow.component.Componentload(org.dom4j.Element componentElement, org.dom4j.Element viewElement) Create vaadin component from component xml element.@Nullable com.vaadin.flow.component.Componentload(org.dom4j.Element componentElement, org.dom4j.Element viewElement, StudioPreviewEnvironment environment) Create vaadin component from component xml element, with access to Studio-resolved context (e.g.protected voidprotected voidloadSeries(org.dom4j.Element componentElement, JmixChart chart) protected voidloadTitle(org.dom4j.Element componentElement, StudioPreviewEnvironment environment, JmixChart chart) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.jmix.flowui.kit.meta.component.preview.StudioPreviewComponentLoader
hasViewOrFragmentSchema, loadBoolean, loadBoolean, loadClassNames, loadComponentBaseAttributes, loadDouble, loadDouble, loadEnabled, loadEnum, loadEnum, loadFieldAttributes, loadHeight, loadInteger, loadInteger, loadLocalizedString, loadMaxHeight, loadMaxWidth, loadMinHeight, loadMinWidth, loadSizeAttributes, loadString, loadString, loadString, loadThemeNames, loadTooltip, loadWidth, propertyCaption, split, split
-
Field Details
-
CHARTS_SCHEMA
- See Also:
-
CHART_ELEMENT
- See Also:
-
-
Constructor Details
-
StudioChartsPreviewLoader
public StudioChartsPreviewLoader()
-
-
Method Details
-
isSupported
public boolean isSupported(org.dom4j.Element element) Description copied from interface:StudioPreviewComponentLoaderDefine the element that this loader can load.- Specified by:
isSupportedin interfaceStudioPreviewComponentLoader
-
load
public @Nullable com.vaadin.flow.component.Component load(org.dom4j.Element componentElement, org.dom4j.Element viewElement) Description copied from interface:StudioPreviewComponentLoaderCreate vaadin component from component xml element.- Specified by:
loadin interfaceStudioPreviewComponentLoader- Parameters:
componentElement- xml element of componentviewElement- xml element of view containingcomponentElement- See Also:
-
load
public @Nullable com.vaadin.flow.component.Component load(org.dom4j.Element componentElement, org.dom4j.Element viewElement, StudioPreviewEnvironment environment) Description copied from interface:StudioPreviewComponentLoaderCreate vaadin component from component xml element, with access to Studio-resolved context (e.g. localized messages, entity property captions).- Specified by:
loadin interfaceStudioPreviewComponentLoader- Parameters:
componentElement- xml element of componentviewElement- xml element of view containingcomponentElementenvironment- Studio-side environment;StudioPreviewEnvironment.NOOPwhen unavailable- See Also:
-
loadTitle
protected void loadTitle(org.dom4j.Element componentElement, StudioPreviewEnvironment environment, JmixChart chart) -
loadAxes
-
loadSeries
-
createSeries
-