@elementor/editor-controls 0.3.1 → 0.4.1

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/CHANGELOG.md CHANGED
@@ -1,5 +1,21 @@
1
1
  # @elementor/editor-controls
2
2
 
3
+ ## 0.4.1
4
+
5
+ ### Patch Changes
6
+
7
+ - 6a3622a: background infra changes
8
+ - Updated dependencies [6a3622a]
9
+ - @elementor/editor-props@0.5.1
10
+
11
+ ## 0.4.0
12
+
13
+ ### Minor Changes
14
+
15
+ - 3019657: Add render control test util.
16
+ - 2653cf0: Pass empty string to control input null values.
17
+ - 862178c: Set mixed border value properly from empty initial state.
18
+
3
19
  ## 0.3.1
4
20
 
5
21
  ### Patch Changes
package/dist/index.d.mts CHANGED
@@ -38,8 +38,6 @@ declare const StrokeControl: ControlComponent<() => React.JSX.Element>;
38
38
 
39
39
  declare const BoxShadowRepeaterControl: ControlComponent<() => React.JSX.Element>;
40
40
 
41
- declare const BackgroundOverlayRepeaterControl: ControlComponent<() => React.JSX.Element>;
42
-
43
41
  type Props$2 = {
44
42
  options: Array<{
45
43
  label: string;
@@ -125,22 +123,22 @@ declare const GapControl: ControlComponent<({ label }: {
125
123
  label: string;
126
124
  }) => React.JSX.Element>;
127
125
 
126
+ declare const BackgroundControl: ControlComponent<() => React.JSX.Element>;
127
+
128
128
  declare const ControlLabel: ({ children }: {
129
129
  children: React.ReactNode;
130
130
  }) => React.JSX.Element;
131
131
 
132
- type ReplaceWhenParams = {
133
- value: PropValue;
134
- };
135
- type CreateControlReplacement = {
136
- component: ComponentType;
137
- condition: ({ value }: ReplaceWhenParams) => boolean;
138
- };
139
- declare const ControlReplacementProvider: ({ component, condition, children, }: React.PropsWithChildren<CreateControlReplacement>) => React.JSX.Element;
140
- declare const createControlReplacement: () => {
141
- replaceControl: ({ component, condition }: CreateControlReplacement) => void;
142
- getControlReplacement: () => CreateControlReplacement;
132
+ type ControlActionsItems = Array<{
133
+ id: string;
134
+ MenuItem: React.ComponentType;
135
+ }>;
136
+ type ControlActionsContext = {
137
+ items: ControlActionsItems;
143
138
  };
139
+ type ControlActionsProviderProps = PropsWithChildren<ControlActionsContext>;
140
+ declare const ControlActionsProvider: ({ children, items }: ControlActionsProviderProps) => React.JSX.Element;
141
+ declare const useControlActions: () => ControlActionsContext;
144
142
 
145
143
  type BoundPropContext<T extends PropValue> = {
146
144
  bind: PropKey;
@@ -161,15 +159,18 @@ type UseBoundProp<TValue> = {
161
159
  declare function useBoundProp<TValue extends PropValue>(): BoundPropContext<TValue>;
162
160
  declare function useBoundProp<TKey extends string, TValue extends PropValue>(propTypeUtil: PropTypeUtil<TKey, TValue>): UseBoundProp<TValue>;
163
161
 
164
- type ControlActionsContext = {
165
- items: Array<{
166
- id: string;
167
- MenuItem: React.ComponentType;
168
- }>;
162
+ type ReplaceWhenParams = {
163
+ value: PropValue;
164
+ };
165
+ type CreateControlReplacement = {
166
+ component: ComponentType;
167
+ condition: ({ value }: ReplaceWhenParams) => boolean;
168
+ };
169
+ declare const ControlReplacementProvider: ({ component, condition, children, }: React.PropsWithChildren<CreateControlReplacement>) => React.JSX.Element;
170
+ declare const createControlReplacement: () => {
171
+ replaceControl: ({ component, condition }: CreateControlReplacement) => void;
172
+ getControlReplacement: () => CreateControlReplacement;
169
173
  };
170
- type ControlActionsProviderProps = PropsWithChildren<ControlActionsContext>;
171
- declare const ControlActionsProvider: ({ children, items }: ControlActionsProviderProps) => React.JSX.Element;
172
- declare const useControlActions: () => ControlActionsContext;
173
174
 
174
175
  type UseInternalStateOptions<TValue> = {
175
176
  external: TValue | null;
@@ -179,4 +180,4 @@ type UseInternalStateOptions<TValue> = {
179
180
  };
180
181
  declare const useSyncExternalState: <TValue>({ external, setExternal, persistWhen, fallback, }: UseInternalStateOptions<TValue>) => readonly [TValue, (setter: ((value: TValue) => TValue) | TValue) => void];
181
182
 
182
- export { BackgroundOverlayRepeaterControl, BoundPropProvider, BoxShadowRepeaterControl, ColorControl, ControlActionsProvider, type ControlComponent, ControlLabel, ControlReplacementProvider, ControlToggleButtonGroup, type EqualUnequalItems, EqualUnequalSizesControl, FontFamilyControl, GapControl, ImageControl, LinkControl, LinkedDimensionsControl, NumberControl, SelectControl, SizeControl, StrokeControl, TextAreaControl, TextControl, type ToggleButtonGroupItem, ToggleControl, UrlControl, createControlReplacement, useBoundProp, useControlActions, useSyncExternalState };
183
+ export { BackgroundControl, BoundPropProvider, type BoundPropProviderProps, BoxShadowRepeaterControl, ColorControl, type ControlActionsItems, ControlActionsProvider, type ControlComponent, ControlLabel, ControlReplacementProvider, ControlToggleButtonGroup, type EqualUnequalItems, EqualUnequalSizesControl, FontFamilyControl, GapControl, ImageControl, LinkControl, LinkedDimensionsControl, NumberControl, SelectControl, SizeControl, StrokeControl, TextAreaControl, TextControl, type ToggleButtonGroupItem, ToggleControl, UrlControl, createControlReplacement, useBoundProp, useControlActions, useSyncExternalState };
package/dist/index.d.ts CHANGED
@@ -38,8 +38,6 @@ declare const StrokeControl: ControlComponent<() => React.JSX.Element>;
38
38
 
39
39
  declare const BoxShadowRepeaterControl: ControlComponent<() => React.JSX.Element>;
40
40
 
41
- declare const BackgroundOverlayRepeaterControl: ControlComponent<() => React.JSX.Element>;
42
-
43
41
  type Props$2 = {
44
42
  options: Array<{
45
43
  label: string;
@@ -125,22 +123,22 @@ declare const GapControl: ControlComponent<({ label }: {
125
123
  label: string;
126
124
  }) => React.JSX.Element>;
127
125
 
126
+ declare const BackgroundControl: ControlComponent<() => React.JSX.Element>;
127
+
128
128
  declare const ControlLabel: ({ children }: {
129
129
  children: React.ReactNode;
130
130
  }) => React.JSX.Element;
131
131
 
132
- type ReplaceWhenParams = {
133
- value: PropValue;
134
- };
135
- type CreateControlReplacement = {
136
- component: ComponentType;
137
- condition: ({ value }: ReplaceWhenParams) => boolean;
138
- };
139
- declare const ControlReplacementProvider: ({ component, condition, children, }: React.PropsWithChildren<CreateControlReplacement>) => React.JSX.Element;
140
- declare const createControlReplacement: () => {
141
- replaceControl: ({ component, condition }: CreateControlReplacement) => void;
142
- getControlReplacement: () => CreateControlReplacement;
132
+ type ControlActionsItems = Array<{
133
+ id: string;
134
+ MenuItem: React.ComponentType;
135
+ }>;
136
+ type ControlActionsContext = {
137
+ items: ControlActionsItems;
143
138
  };
139
+ type ControlActionsProviderProps = PropsWithChildren<ControlActionsContext>;
140
+ declare const ControlActionsProvider: ({ children, items }: ControlActionsProviderProps) => React.JSX.Element;
141
+ declare const useControlActions: () => ControlActionsContext;
144
142
 
145
143
  type BoundPropContext<T extends PropValue> = {
146
144
  bind: PropKey;
@@ -161,15 +159,18 @@ type UseBoundProp<TValue> = {
161
159
  declare function useBoundProp<TValue extends PropValue>(): BoundPropContext<TValue>;
162
160
  declare function useBoundProp<TKey extends string, TValue extends PropValue>(propTypeUtil: PropTypeUtil<TKey, TValue>): UseBoundProp<TValue>;
163
161
 
164
- type ControlActionsContext = {
165
- items: Array<{
166
- id: string;
167
- MenuItem: React.ComponentType;
168
- }>;
162
+ type ReplaceWhenParams = {
163
+ value: PropValue;
164
+ };
165
+ type CreateControlReplacement = {
166
+ component: ComponentType;
167
+ condition: ({ value }: ReplaceWhenParams) => boolean;
168
+ };
169
+ declare const ControlReplacementProvider: ({ component, condition, children, }: React.PropsWithChildren<CreateControlReplacement>) => React.JSX.Element;
170
+ declare const createControlReplacement: () => {
171
+ replaceControl: ({ component, condition }: CreateControlReplacement) => void;
172
+ getControlReplacement: () => CreateControlReplacement;
169
173
  };
170
- type ControlActionsProviderProps = PropsWithChildren<ControlActionsContext>;
171
- declare const ControlActionsProvider: ({ children, items }: ControlActionsProviderProps) => React.JSX.Element;
172
- declare const useControlActions: () => ControlActionsContext;
173
174
 
174
175
  type UseInternalStateOptions<TValue> = {
175
176
  external: TValue | null;
@@ -179,4 +180,4 @@ type UseInternalStateOptions<TValue> = {
179
180
  };
180
181
  declare const useSyncExternalState: <TValue>({ external, setExternal, persistWhen, fallback, }: UseInternalStateOptions<TValue>) => readonly [TValue, (setter: ((value: TValue) => TValue) | TValue) => void];
181
182
 
182
- export { BackgroundOverlayRepeaterControl, BoundPropProvider, BoxShadowRepeaterControl, ColorControl, ControlActionsProvider, type ControlComponent, ControlLabel, ControlReplacementProvider, ControlToggleButtonGroup, type EqualUnequalItems, EqualUnequalSizesControl, FontFamilyControl, GapControl, ImageControl, LinkControl, LinkedDimensionsControl, NumberControl, SelectControl, SizeControl, StrokeControl, TextAreaControl, TextControl, type ToggleButtonGroupItem, ToggleControl, UrlControl, createControlReplacement, useBoundProp, useControlActions, useSyncExternalState };
183
+ export { BackgroundControl, BoundPropProvider, type BoundPropProviderProps, BoxShadowRepeaterControl, ColorControl, type ControlActionsItems, ControlActionsProvider, type ControlComponent, ControlLabel, ControlReplacementProvider, ControlToggleButtonGroup, type EqualUnequalItems, EqualUnequalSizesControl, FontFamilyControl, GapControl, ImageControl, LinkControl, LinkedDimensionsControl, NumberControl, SelectControl, SizeControl, StrokeControl, TextAreaControl, TextControl, type ToggleButtonGroupItem, ToggleControl, UrlControl, createControlReplacement, useBoundProp, useControlActions, useSyncExternalState };