@elementor/editor-editing-panel 4.3.0-1041 → 4.3.0-1042
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +86 -11
- package/dist/index.d.ts +86 -11
- package/dist/index.js +1120 -1005
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1006 -902
- package/dist/index.mjs.map +1 -1
- package/package.json +24 -24
- package/src/components/css-classes/css-class-menu.tsx +29 -30
- package/src/components/style-sections-definition.ts +119 -0
- package/src/components/style-sections.tsx +22 -0
- package/src/components/style-states/pseudo-state-menu-items.tsx +44 -0
- package/src/components/style-states/pseudo-states.ts +17 -0
- package/src/components/style-states/use-pseudo-states.ts +18 -0
- package/src/components/style-tab.tsx +8 -123
- package/src/contexts/styles-inheritance-context.tsx +11 -1
- package/src/hooks/use-default-style-tag-from-preview.ts +14 -0
- package/src/index.ts +20 -3
package/dist/index.d.mts
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import * as _elementor_locations from '@elementor/locations';
|
|
2
|
-
import { StyleDefinition, StyleDefinitionVariant, StyleDefinitionState, StyleDefinitionID } from '@elementor/editor-styles';
|
|
3
1
|
import * as react from 'react';
|
|
4
2
|
import { PropsWithChildren, FC, ReactNode, Dispatch, ComponentProps, ComponentType } from 'react';
|
|
3
|
+
import { AutocompleteProps, AutocompleteChangeReason, ListProps, Theme, ChipProps } from '@elementor/ui';
|
|
4
|
+
import * as _elementor_locations from '@elementor/locations';
|
|
5
|
+
import { StyleDefinition, StyleDefinitionState, StyleDefinitionVariant, StyleDefinitionID } from '@elementor/editor-styles';
|
|
5
6
|
import { Control as Control$1, ElementControl, Element, ElementType, ControlLayout, ControlItem } from '@elementor/editor-elements';
|
|
6
7
|
import * as _elementor_editor_props from '@elementor/editor-props';
|
|
7
|
-
import { PropKey, AnyTransformable, PropTypeUtil, PropsSchema, ObjectPropType, TransformablePropValue, PropValue, PropType, Props as Props$
|
|
8
|
+
import { PropKey, AnyTransformable, PropTypeUtil, PropsSchema, ObjectPropType, TransformablePropValue, PropValue, PropType, Props as Props$4 } from '@elementor/editor-props';
|
|
8
9
|
import * as _emotion_styled from '@emotion/styled';
|
|
9
10
|
import * as _mui_system from '@mui/system';
|
|
10
|
-
import { Theme, ChipProps } from '@elementor/ui';
|
|
11
11
|
import { StylesProvider } from '@elementor/editor-styles-repository';
|
|
12
12
|
import * as _mui_material from '@mui/material';
|
|
13
13
|
import * as _elementor_editor_controls from '@elementor/editor-controls';
|
|
@@ -15,6 +15,16 @@ import { ControlComponent, AdornmentComponent } from '@elementor/editor-controls
|
|
|
15
15
|
import * as zod from 'zod';
|
|
16
16
|
import * as _elementor_utils from '@elementor/utils';
|
|
17
17
|
|
|
18
|
+
type Option = {
|
|
19
|
+
label: string;
|
|
20
|
+
value: string | null;
|
|
21
|
+
fixed?: boolean;
|
|
22
|
+
key?: string;
|
|
23
|
+
};
|
|
24
|
+
type InternalKeys = '_group' | '_action';
|
|
25
|
+
type SafeOptionConstraint = Option & {
|
|
26
|
+
[K in InternalKeys]?: never;
|
|
27
|
+
};
|
|
18
28
|
type ValidationResult = {
|
|
19
29
|
isValid: true;
|
|
20
30
|
errorMessage: null;
|
|
@@ -23,6 +33,30 @@ type ValidationResult = {
|
|
|
23
33
|
errorMessage: string;
|
|
24
34
|
};
|
|
25
35
|
type ValidationEvent = 'inputChange' | 'create';
|
|
36
|
+
type OnSelect<TOption extends Option> = (value: TOption[], reason: AutocompleteChangeReason, option: TOption) => void;
|
|
37
|
+
type OnCreate = (value: string) => unknown;
|
|
38
|
+
type Validate = (value: string, event: ValidationEvent) => ValidationResult;
|
|
39
|
+
type CreatableAutocompleteProps<TOption extends SafeOptionConstraint> = Omit<AutocompleteProps<TOption, true, true, true>, 'renderInput' | 'onSelect' | 'options'> & {
|
|
40
|
+
selected: TOption[];
|
|
41
|
+
options: TOption[];
|
|
42
|
+
placeholder?: string;
|
|
43
|
+
entityName?: {
|
|
44
|
+
singular: string;
|
|
45
|
+
plural: string;
|
|
46
|
+
};
|
|
47
|
+
renderEmptyState?: (props: {
|
|
48
|
+
searchValue: string;
|
|
49
|
+
onClear: () => void;
|
|
50
|
+
}) => React.ReactNode;
|
|
51
|
+
onSelect?: OnSelect<TOption>;
|
|
52
|
+
onCreate?: OnCreate;
|
|
53
|
+
validate?: Validate;
|
|
54
|
+
};
|
|
55
|
+
|
|
56
|
+
declare const CreatableAutocomplete: <TOption extends SafeOptionConstraint>(props: CreatableAutocompleteProps<TOption> & {
|
|
57
|
+
ref?: react.ForwardedRef<HTMLElement>;
|
|
58
|
+
}) => ReturnType<typeof CreatableAutocompleteInner>;
|
|
59
|
+
declare function CreatableAutocompleteInner<TOption extends SafeOptionConstraint>({ selected, options, entityName, onSelect, placeholder, onCreate, validate, renderEmptyState, ...props }: CreatableAutocompleteProps<TOption>, ref: react.ForwardedRef<HTMLElement>): react.JSX.Element;
|
|
26
60
|
|
|
27
61
|
declare const injectIntoCssClassConvert: (args: _elementor_locations.InjectArgs<{
|
|
28
62
|
styleDef: StyleDefinition | null;
|
|
@@ -53,6 +87,8 @@ type SectionContentProps = PropsWithChildren<{
|
|
|
53
87
|
}>;
|
|
54
88
|
declare const SectionContent: FC<SectionContentProps>;
|
|
55
89
|
|
|
90
|
+
declare function SectionsList(props: ListProps): react.JSX.Element;
|
|
91
|
+
|
|
56
92
|
declare const SettingsControl: ({ control: { value, type } }: {
|
|
57
93
|
control: Control$1 | ElementControl;
|
|
58
94
|
}) => react.JSX.Element | null;
|
|
@@ -74,6 +110,36 @@ declare const StyleIndicator: _emotion_styled.StyledComponent<_mui_system.MUISty
|
|
|
74
110
|
|
|
75
111
|
declare const injectIntoStyleTab: (args: _elementor_locations.InjectArgs<object>) => void;
|
|
76
112
|
|
|
113
|
+
declare const StyleSections: () => react.JSX.Element;
|
|
114
|
+
|
|
115
|
+
type StyleSectionDefinition = {
|
|
116
|
+
name: string;
|
|
117
|
+
title: string;
|
|
118
|
+
component: () => react.JSX.Element;
|
|
119
|
+
fields: string[];
|
|
120
|
+
};
|
|
121
|
+
declare const STYLE_SECTIONS: StyleSectionDefinition[];
|
|
122
|
+
declare const STYLE_SECTION_NAMES: string[];
|
|
123
|
+
|
|
124
|
+
type StyleDefinitionStateWithNormal = NonNullable<StyleDefinitionState> | 'normal';
|
|
125
|
+
|
|
126
|
+
type PseudoStateOption = {
|
|
127
|
+
key: StyleDefinitionStateWithNormal;
|
|
128
|
+
value: StyleDefinitionState | null;
|
|
129
|
+
label: string;
|
|
130
|
+
};
|
|
131
|
+
declare const DEFAULT_PSEUDO_STATES: PseudoStateOption[];
|
|
132
|
+
|
|
133
|
+
type PseudoStateMenuItemsProps = {
|
|
134
|
+
states: PseudoStateOption[];
|
|
135
|
+
activeState: StyleDefinitionState | null;
|
|
136
|
+
onSelectState: (state: StyleDefinitionState | null) => void;
|
|
137
|
+
onClose?: () => void;
|
|
138
|
+
};
|
|
139
|
+
declare function PseudoStateMenuItems({ states, activeState, onSelectState, onClose }: PseudoStateMenuItemsProps): react.JSX.Element;
|
|
140
|
+
|
|
141
|
+
declare function usePseudoStates(): PseudoStateOption[];
|
|
142
|
+
|
|
77
143
|
declare const injectIntoGridFields: (args: _elementor_locations.InjectArgs<object>) => void;
|
|
78
144
|
|
|
79
145
|
type SectionType = {
|
|
@@ -85,13 +151,18 @@ type SectionType = {
|
|
|
85
151
|
onClick: () => void;
|
|
86
152
|
};
|
|
87
153
|
};
|
|
88
|
-
type Props$
|
|
154
|
+
type Props$3 = {
|
|
89
155
|
section: SectionType;
|
|
90
156
|
fields?: string[];
|
|
91
157
|
unmountOnExit?: boolean;
|
|
92
158
|
};
|
|
93
|
-
declare const StyleTabSection: ({ section, fields, unmountOnExit }: Props$
|
|
159
|
+
declare const StyleTabSection: ({ section, fields, unmountOnExit }: Props$3) => react.JSX.Element;
|
|
94
160
|
|
|
161
|
+
type ContextValue$2 = {
|
|
162
|
+
prop: string;
|
|
163
|
+
};
|
|
164
|
+
type Props$2 = PropsWithChildren<ContextValue$2>;
|
|
165
|
+
declare function ClassesPropProvider({ children, prop }: Props$2): react.JSX.Element;
|
|
95
166
|
declare function useClassesProp(): string;
|
|
96
167
|
|
|
97
168
|
type ContextValue$1 = {
|
|
@@ -99,8 +170,8 @@ type ContextValue$1 = {
|
|
|
99
170
|
elementType: ElementType;
|
|
100
171
|
settings: Record<string, AnyTransformable | null>;
|
|
101
172
|
};
|
|
102
|
-
type Props = PropsWithChildren<ContextValue$1>;
|
|
103
|
-
declare function ElementProvider({ children, element, elementType, settings }: Props): react.JSX.Element;
|
|
173
|
+
type Props$1 = PropsWithChildren<ContextValue$1>;
|
|
174
|
+
declare function ElementProvider({ children, element, elementType, settings }: Props$1): react.JSX.Element;
|
|
104
175
|
declare function useElement(): ContextValue$1;
|
|
105
176
|
|
|
106
177
|
type ContextValue = {
|
|
@@ -117,8 +188,12 @@ type ContextValueWithoutProvider = {
|
|
|
117
188
|
id: null;
|
|
118
189
|
provider: null;
|
|
119
190
|
};
|
|
191
|
+
type Props = PropsWithChildren<Omit<ContextValue, 'provider'>>;
|
|
192
|
+
declare function StyleProvider({ children, ...props }: Props): react.JSX.Element;
|
|
120
193
|
declare function useStyle(): ContextValue;
|
|
121
194
|
|
|
195
|
+
declare function StyleInheritanceProvider({ children }: PropsWithChildren): react.JSX.Element;
|
|
196
|
+
|
|
122
197
|
type ControlRegistry = Record<string, {
|
|
123
198
|
component: ControlComponent;
|
|
124
199
|
layout: ControlLayout;
|
|
@@ -2324,9 +2399,9 @@ type DependencyEffect = {
|
|
|
2324
2399
|
isHidden: boolean;
|
|
2325
2400
|
isDisabled: (propType: PropType) => boolean;
|
|
2326
2401
|
};
|
|
2327
|
-
declare function getElementSettingsWithDefaults(propsSchema: PropsSchema, elementSettings?: Props$
|
|
2328
|
-
declare function extractDependencyEffect(bind: string, propsSchema: PropsSchema, settings: Props$
|
|
2402
|
+
declare function getElementSettingsWithDefaults(propsSchema: PropsSchema, elementSettings?: Props$4): Values;
|
|
2403
|
+
declare function extractDependencyEffect(bind: string, propsSchema: PropsSchema, settings: Props$4): DependencyEffect;
|
|
2329
2404
|
declare function extractOrderedDependencies(dependenciesPerTargetMapping: Record<string, string[]>): string[];
|
|
2330
2405
|
declare function getUpdatedValues(values: Values, dependencies: string[], propsSchema: PropsSchema, elementValues: Values, elementId: string): Values;
|
|
2331
2406
|
|
|
2332
|
-
export { Control as BaseControl, ControlLabel, type ControlType, ControlTypeContainer, CustomCssIndicator, type DependencyEffect, type DynamicTag, type DynamicTags, type DynamicTagsManager, EditingPanelTabs, type Defaults as ElementPanelDefaults, ElementProvider, FIELD_TYPE, HISTORY_DEBOUNCE_WAIT, SectionContent, SettingsControl, SettingsField, StyleIndicator, StyleTabSection, StylesProviderCannotUpdatePropsError, type ValidationEvent, type ValidationResult, controlsRegistry, createTopLevelObjectType, doApplyClasses, doGetAppliedClasses, doUnapplyClass, extractDependencyEffect, extractOrderedDependencies, getElementSettingsWithDefaults, getFieldIndicators, getSubtitle, getTitle, getUpdatedValues, init, injectIntoClassSelectorActions, injectIntoCssClassConvert, injectIntoGridFields, injectIntoPanelHeaderTop, injectIntoStyleTab, isDynamicPropValue, registerEditingPanelReplacement, registerElementPanelDefaults, registerFieldIndicator, registerStyleProviderToColors, setLicenseConfig, useClassesProp, useCustomCss, useElement, usePanelActions, usePanelStatus, useStateByElement, useStyle, useStylesRerender };
|
|
2407
|
+
export { Control as BaseControl, ClassesPropProvider, ControlLabel, type ControlType, ControlTypeContainer, CreatableAutocomplete, type CreatableAutocompleteProps, CustomCssIndicator, DEFAULT_PSEUDO_STATES, type DependencyEffect, type DynamicTag, type DynamicTags, type DynamicTagsManager, EditingPanelTabs, type Defaults as ElementPanelDefaults, ElementProvider, FIELD_TYPE, HISTORY_DEBOUNCE_WAIT, type Option, PseudoStateMenuItems, type PseudoStateOption, STYLE_SECTIONS, STYLE_SECTION_NAMES, SectionContent, SectionsList, SettingsControl, SettingsField, StyleIndicator, StyleInheritanceProvider, StyleProvider, type StyleSectionDefinition, StyleSections, StyleTabSection, StylesProviderCannotUpdatePropsError, type ValidationEvent, type ValidationResult, controlsRegistry, createTopLevelObjectType, doApplyClasses, doGetAppliedClasses, doUnapplyClass, extractDependencyEffect, extractOrderedDependencies, getElementSettingsWithDefaults, getFieldIndicators, getSubtitle, getTitle, getUpdatedValues, init, injectIntoClassSelectorActions, injectIntoCssClassConvert, injectIntoGridFields, injectIntoPanelHeaderTop, injectIntoStyleTab, isDynamicPropValue, registerEditingPanelReplacement, registerElementPanelDefaults, registerFieldIndicator, registerStyleProviderToColors, setLicenseConfig, useClassesProp, useCustomCss, useElement, usePanelActions, usePanelStatus, usePseudoStates, useStateByElement, useStyle, useStylesRerender };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import * as _elementor_locations from '@elementor/locations';
|
|
2
|
-
import { StyleDefinition, StyleDefinitionVariant, StyleDefinitionState, StyleDefinitionID } from '@elementor/editor-styles';
|
|
3
1
|
import * as react from 'react';
|
|
4
2
|
import { PropsWithChildren, FC, ReactNode, Dispatch, ComponentProps, ComponentType } from 'react';
|
|
3
|
+
import { AutocompleteProps, AutocompleteChangeReason, ListProps, Theme, ChipProps } from '@elementor/ui';
|
|
4
|
+
import * as _elementor_locations from '@elementor/locations';
|
|
5
|
+
import { StyleDefinition, StyleDefinitionState, StyleDefinitionVariant, StyleDefinitionID } from '@elementor/editor-styles';
|
|
5
6
|
import { Control as Control$1, ElementControl, Element, ElementType, ControlLayout, ControlItem } from '@elementor/editor-elements';
|
|
6
7
|
import * as _elementor_editor_props from '@elementor/editor-props';
|
|
7
|
-
import { PropKey, AnyTransformable, PropTypeUtil, PropsSchema, ObjectPropType, TransformablePropValue, PropValue, PropType, Props as Props$
|
|
8
|
+
import { PropKey, AnyTransformable, PropTypeUtil, PropsSchema, ObjectPropType, TransformablePropValue, PropValue, PropType, Props as Props$4 } from '@elementor/editor-props';
|
|
8
9
|
import * as _emotion_styled from '@emotion/styled';
|
|
9
10
|
import * as _mui_system from '@mui/system';
|
|
10
|
-
import { Theme, ChipProps } from '@elementor/ui';
|
|
11
11
|
import { StylesProvider } from '@elementor/editor-styles-repository';
|
|
12
12
|
import * as _mui_material from '@mui/material';
|
|
13
13
|
import * as _elementor_editor_controls from '@elementor/editor-controls';
|
|
@@ -15,6 +15,16 @@ import { ControlComponent, AdornmentComponent } from '@elementor/editor-controls
|
|
|
15
15
|
import * as zod from 'zod';
|
|
16
16
|
import * as _elementor_utils from '@elementor/utils';
|
|
17
17
|
|
|
18
|
+
type Option = {
|
|
19
|
+
label: string;
|
|
20
|
+
value: string | null;
|
|
21
|
+
fixed?: boolean;
|
|
22
|
+
key?: string;
|
|
23
|
+
};
|
|
24
|
+
type InternalKeys = '_group' | '_action';
|
|
25
|
+
type SafeOptionConstraint = Option & {
|
|
26
|
+
[K in InternalKeys]?: never;
|
|
27
|
+
};
|
|
18
28
|
type ValidationResult = {
|
|
19
29
|
isValid: true;
|
|
20
30
|
errorMessage: null;
|
|
@@ -23,6 +33,30 @@ type ValidationResult = {
|
|
|
23
33
|
errorMessage: string;
|
|
24
34
|
};
|
|
25
35
|
type ValidationEvent = 'inputChange' | 'create';
|
|
36
|
+
type OnSelect<TOption extends Option> = (value: TOption[], reason: AutocompleteChangeReason, option: TOption) => void;
|
|
37
|
+
type OnCreate = (value: string) => unknown;
|
|
38
|
+
type Validate = (value: string, event: ValidationEvent) => ValidationResult;
|
|
39
|
+
type CreatableAutocompleteProps<TOption extends SafeOptionConstraint> = Omit<AutocompleteProps<TOption, true, true, true>, 'renderInput' | 'onSelect' | 'options'> & {
|
|
40
|
+
selected: TOption[];
|
|
41
|
+
options: TOption[];
|
|
42
|
+
placeholder?: string;
|
|
43
|
+
entityName?: {
|
|
44
|
+
singular: string;
|
|
45
|
+
plural: string;
|
|
46
|
+
};
|
|
47
|
+
renderEmptyState?: (props: {
|
|
48
|
+
searchValue: string;
|
|
49
|
+
onClear: () => void;
|
|
50
|
+
}) => React.ReactNode;
|
|
51
|
+
onSelect?: OnSelect<TOption>;
|
|
52
|
+
onCreate?: OnCreate;
|
|
53
|
+
validate?: Validate;
|
|
54
|
+
};
|
|
55
|
+
|
|
56
|
+
declare const CreatableAutocomplete: <TOption extends SafeOptionConstraint>(props: CreatableAutocompleteProps<TOption> & {
|
|
57
|
+
ref?: react.ForwardedRef<HTMLElement>;
|
|
58
|
+
}) => ReturnType<typeof CreatableAutocompleteInner>;
|
|
59
|
+
declare function CreatableAutocompleteInner<TOption extends SafeOptionConstraint>({ selected, options, entityName, onSelect, placeholder, onCreate, validate, renderEmptyState, ...props }: CreatableAutocompleteProps<TOption>, ref: react.ForwardedRef<HTMLElement>): react.JSX.Element;
|
|
26
60
|
|
|
27
61
|
declare const injectIntoCssClassConvert: (args: _elementor_locations.InjectArgs<{
|
|
28
62
|
styleDef: StyleDefinition | null;
|
|
@@ -53,6 +87,8 @@ type SectionContentProps = PropsWithChildren<{
|
|
|
53
87
|
}>;
|
|
54
88
|
declare const SectionContent: FC<SectionContentProps>;
|
|
55
89
|
|
|
90
|
+
declare function SectionsList(props: ListProps): react.JSX.Element;
|
|
91
|
+
|
|
56
92
|
declare const SettingsControl: ({ control: { value, type } }: {
|
|
57
93
|
control: Control$1 | ElementControl;
|
|
58
94
|
}) => react.JSX.Element | null;
|
|
@@ -74,6 +110,36 @@ declare const StyleIndicator: _emotion_styled.StyledComponent<_mui_system.MUISty
|
|
|
74
110
|
|
|
75
111
|
declare const injectIntoStyleTab: (args: _elementor_locations.InjectArgs<object>) => void;
|
|
76
112
|
|
|
113
|
+
declare const StyleSections: () => react.JSX.Element;
|
|
114
|
+
|
|
115
|
+
type StyleSectionDefinition = {
|
|
116
|
+
name: string;
|
|
117
|
+
title: string;
|
|
118
|
+
component: () => react.JSX.Element;
|
|
119
|
+
fields: string[];
|
|
120
|
+
};
|
|
121
|
+
declare const STYLE_SECTIONS: StyleSectionDefinition[];
|
|
122
|
+
declare const STYLE_SECTION_NAMES: string[];
|
|
123
|
+
|
|
124
|
+
type StyleDefinitionStateWithNormal = NonNullable<StyleDefinitionState> | 'normal';
|
|
125
|
+
|
|
126
|
+
type PseudoStateOption = {
|
|
127
|
+
key: StyleDefinitionStateWithNormal;
|
|
128
|
+
value: StyleDefinitionState | null;
|
|
129
|
+
label: string;
|
|
130
|
+
};
|
|
131
|
+
declare const DEFAULT_PSEUDO_STATES: PseudoStateOption[];
|
|
132
|
+
|
|
133
|
+
type PseudoStateMenuItemsProps = {
|
|
134
|
+
states: PseudoStateOption[];
|
|
135
|
+
activeState: StyleDefinitionState | null;
|
|
136
|
+
onSelectState: (state: StyleDefinitionState | null) => void;
|
|
137
|
+
onClose?: () => void;
|
|
138
|
+
};
|
|
139
|
+
declare function PseudoStateMenuItems({ states, activeState, onSelectState, onClose }: PseudoStateMenuItemsProps): react.JSX.Element;
|
|
140
|
+
|
|
141
|
+
declare function usePseudoStates(): PseudoStateOption[];
|
|
142
|
+
|
|
77
143
|
declare const injectIntoGridFields: (args: _elementor_locations.InjectArgs<object>) => void;
|
|
78
144
|
|
|
79
145
|
type SectionType = {
|
|
@@ -85,13 +151,18 @@ type SectionType = {
|
|
|
85
151
|
onClick: () => void;
|
|
86
152
|
};
|
|
87
153
|
};
|
|
88
|
-
type Props$
|
|
154
|
+
type Props$3 = {
|
|
89
155
|
section: SectionType;
|
|
90
156
|
fields?: string[];
|
|
91
157
|
unmountOnExit?: boolean;
|
|
92
158
|
};
|
|
93
|
-
declare const StyleTabSection: ({ section, fields, unmountOnExit }: Props$
|
|
159
|
+
declare const StyleTabSection: ({ section, fields, unmountOnExit }: Props$3) => react.JSX.Element;
|
|
94
160
|
|
|
161
|
+
type ContextValue$2 = {
|
|
162
|
+
prop: string;
|
|
163
|
+
};
|
|
164
|
+
type Props$2 = PropsWithChildren<ContextValue$2>;
|
|
165
|
+
declare function ClassesPropProvider({ children, prop }: Props$2): react.JSX.Element;
|
|
95
166
|
declare function useClassesProp(): string;
|
|
96
167
|
|
|
97
168
|
type ContextValue$1 = {
|
|
@@ -99,8 +170,8 @@ type ContextValue$1 = {
|
|
|
99
170
|
elementType: ElementType;
|
|
100
171
|
settings: Record<string, AnyTransformable | null>;
|
|
101
172
|
};
|
|
102
|
-
type Props = PropsWithChildren<ContextValue$1>;
|
|
103
|
-
declare function ElementProvider({ children, element, elementType, settings }: Props): react.JSX.Element;
|
|
173
|
+
type Props$1 = PropsWithChildren<ContextValue$1>;
|
|
174
|
+
declare function ElementProvider({ children, element, elementType, settings }: Props$1): react.JSX.Element;
|
|
104
175
|
declare function useElement(): ContextValue$1;
|
|
105
176
|
|
|
106
177
|
type ContextValue = {
|
|
@@ -117,8 +188,12 @@ type ContextValueWithoutProvider = {
|
|
|
117
188
|
id: null;
|
|
118
189
|
provider: null;
|
|
119
190
|
};
|
|
191
|
+
type Props = PropsWithChildren<Omit<ContextValue, 'provider'>>;
|
|
192
|
+
declare function StyleProvider({ children, ...props }: Props): react.JSX.Element;
|
|
120
193
|
declare function useStyle(): ContextValue;
|
|
121
194
|
|
|
195
|
+
declare function StyleInheritanceProvider({ children }: PropsWithChildren): react.JSX.Element;
|
|
196
|
+
|
|
122
197
|
type ControlRegistry = Record<string, {
|
|
123
198
|
component: ControlComponent;
|
|
124
199
|
layout: ControlLayout;
|
|
@@ -2324,9 +2399,9 @@ type DependencyEffect = {
|
|
|
2324
2399
|
isHidden: boolean;
|
|
2325
2400
|
isDisabled: (propType: PropType) => boolean;
|
|
2326
2401
|
};
|
|
2327
|
-
declare function getElementSettingsWithDefaults(propsSchema: PropsSchema, elementSettings?: Props$
|
|
2328
|
-
declare function extractDependencyEffect(bind: string, propsSchema: PropsSchema, settings: Props$
|
|
2402
|
+
declare function getElementSettingsWithDefaults(propsSchema: PropsSchema, elementSettings?: Props$4): Values;
|
|
2403
|
+
declare function extractDependencyEffect(bind: string, propsSchema: PropsSchema, settings: Props$4): DependencyEffect;
|
|
2329
2404
|
declare function extractOrderedDependencies(dependenciesPerTargetMapping: Record<string, string[]>): string[];
|
|
2330
2405
|
declare function getUpdatedValues(values: Values, dependencies: string[], propsSchema: PropsSchema, elementValues: Values, elementId: string): Values;
|
|
2331
2406
|
|
|
2332
|
-
export { Control as BaseControl, ControlLabel, type ControlType, ControlTypeContainer, CustomCssIndicator, type DependencyEffect, type DynamicTag, type DynamicTags, type DynamicTagsManager, EditingPanelTabs, type Defaults as ElementPanelDefaults, ElementProvider, FIELD_TYPE, HISTORY_DEBOUNCE_WAIT, SectionContent, SettingsControl, SettingsField, StyleIndicator, StyleTabSection, StylesProviderCannotUpdatePropsError, type ValidationEvent, type ValidationResult, controlsRegistry, createTopLevelObjectType, doApplyClasses, doGetAppliedClasses, doUnapplyClass, extractDependencyEffect, extractOrderedDependencies, getElementSettingsWithDefaults, getFieldIndicators, getSubtitle, getTitle, getUpdatedValues, init, injectIntoClassSelectorActions, injectIntoCssClassConvert, injectIntoGridFields, injectIntoPanelHeaderTop, injectIntoStyleTab, isDynamicPropValue, registerEditingPanelReplacement, registerElementPanelDefaults, registerFieldIndicator, registerStyleProviderToColors, setLicenseConfig, useClassesProp, useCustomCss, useElement, usePanelActions, usePanelStatus, useStateByElement, useStyle, useStylesRerender };
|
|
2407
|
+
export { Control as BaseControl, ClassesPropProvider, ControlLabel, type ControlType, ControlTypeContainer, CreatableAutocomplete, type CreatableAutocompleteProps, CustomCssIndicator, DEFAULT_PSEUDO_STATES, type DependencyEffect, type DynamicTag, type DynamicTags, type DynamicTagsManager, EditingPanelTabs, type Defaults as ElementPanelDefaults, ElementProvider, FIELD_TYPE, HISTORY_DEBOUNCE_WAIT, type Option, PseudoStateMenuItems, type PseudoStateOption, STYLE_SECTIONS, STYLE_SECTION_NAMES, SectionContent, SectionsList, SettingsControl, SettingsField, StyleIndicator, StyleInheritanceProvider, StyleProvider, type StyleSectionDefinition, StyleSections, StyleTabSection, StylesProviderCannotUpdatePropsError, type ValidationEvent, type ValidationResult, controlsRegistry, createTopLevelObjectType, doApplyClasses, doGetAppliedClasses, doUnapplyClass, extractDependencyEffect, extractOrderedDependencies, getElementSettingsWithDefaults, getFieldIndicators, getSubtitle, getTitle, getUpdatedValues, init, injectIntoClassSelectorActions, injectIntoCssClassConvert, injectIntoGridFields, injectIntoPanelHeaderTop, injectIntoStyleTab, isDynamicPropValue, registerEditingPanelReplacement, registerElementPanelDefaults, registerFieldIndicator, registerStyleProviderToColors, setLicenseConfig, useClassesProp, useCustomCss, useElement, usePanelActions, usePanelStatus, usePseudoStates, useStateByElement, useStyle, useStylesRerender };
|