@wix/editor-react-components 1.2452.0 → 1.2453.0
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/site/components/AccordionComponent/AccordionItem.d.ts +1 -1
- package/dist/site/components/AccordionComponent/component.js +59 -34
- package/dist/site/components/AccordionComponent/manifestConfigs/iconPositionConfig.d.ts +2 -2
- package/dist/site/components/AccordionComponent/types.d.ts +9 -3
- package/dist/site/components/AudioPlayer/component.js +92 -35
- package/dist/site/components/AudioPlayer/manifestConfigs/controlsConfig.d.ts +8 -8
- package/dist/site/components/AudioPlayer/manifestConfigs/coverMediaConfig.d.ts +1 -1
- package/dist/site/components/AudioPlayer/types.d.ts +26 -0
- package/dist/site/components/Breadcrumbs/BreadcrumbItem.d.ts +1 -1
- package/dist/site/components/Breadcrumbs/Separator.d.ts +3 -1
- package/dist/site/components/Breadcrumbs/component.js +20 -11
- package/dist/site/components/Breadcrumbs/types.d.ts +10 -7
- package/dist/site/components/Button/Button.types.d.ts +5 -0
- package/dist/site/components/Checkbox/Checkbox.types.d.ts +8 -0
- package/dist/site/components/Checkbox/component.js +7 -3
- package/dist/site/components/CheckboxGroup/CheckboxGroup.types.d.ts +12 -0
- package/dist/site/components/CheckboxGroup/component.js +41 -31
- package/dist/site/components/CollapsibleText/component.js +7 -5
- package/dist/site/components/CollapsibleText/types.d.ts +1 -0
- package/dist/site/components/DatePicker/DatePicker.types.d.ts +28 -0
- package/dist/site/components/DatePicker/component.js +128 -88
- package/dist/site/components/DatePicker/components/DatePickerCalendar.d.ts +3 -1
- package/dist/site/components/DatePicker/components/DatePickerField.d.ts +9 -1
- package/dist/site/components/DatePicker/components/DatePickerLabel.d.ts +2 -1
- package/dist/site/components/Dropdown/Dropdown.types.d.ts +25 -0
- package/dist/site/components/Dropdown/component.js +36 -23
- package/dist/site/components/Dropdown/components/DropdownChips.d.ts +2 -1
- package/dist/site/components/Dropdown/components/DropdownList.d.ts +3 -1
- package/dist/site/components/Dropdown/components/DropdownTrigger.d.ts +3 -1
- package/dist/site/components/LegacyAppWidget/component.js +3 -2
- package/dist/site/components/LegacyAppWidget/components/AppWidget.types.d.ts +4 -2
- package/dist/site/components/LegacyContainer/component.d.ts +3 -1
- package/dist/site/components/LegacyContainer/component.js +2 -0
- package/dist/site/components/LegacyContainer/components/Container.types.d.ts +2 -1
- package/dist/site/components/LegacyMultiStateBox/LegacyMultiStateBox.types.d.ts +2 -0
- package/dist/site/components/Line/manifestConfigs/shapeConfig.d.ts +2 -2
- package/dist/site/components/Line/manifestConfigs/typeConfig.d.ts +2 -2
- package/dist/site/components/Lottie/component.js +4 -1
- package/dist/site/components/Lottie/types.d.ts +6 -0
- package/dist/site/components/Menu/Menu.types.d.ts +33 -3
- package/dist/site/components/Menu/component.js +62 -30
- package/dist/site/components/Menu/components/MenuContent/MenuItem/MenuItemLabel.d.ts +1 -0
- package/dist/site/components/Menu/components/Submenu/types.d.ts +2 -0
- package/dist/site/components/Menu/manifestConfigs/dropdownConfig.d.ts +45 -45
- package/dist/site/components/ProgressBar/ProgressBar.d.ts +9 -8
- package/dist/site/components/ProgressBar/component.js +8 -3
- package/dist/site/components/RadioButtons/RadioButtons.types.d.ts +12 -0
- package/dist/site/components/RadioButtons/component.js +61 -54
- package/dist/site/components/ShareButtons/ShareButtons.types.d.ts +13 -0
- package/dist/site/components/ShareButtons/component.js +23 -8
- package/dist/site/components/ShareButtons/constants.d.ts +1 -1
- package/dist/site/components/Slideshow/SlideIndicators.d.ts +2 -5
- package/dist/site/components/Slideshow/Slideshow.d.ts +10 -7
- package/dist/site/components/Slideshow/component.js +23 -12
- package/dist/site/components/Tabs/Tabs.d.ts +9 -0
- package/dist/site/components/Tabs/component.js +23 -10
- package/dist/site/components/Tabs/components/ScrollControls/ScrollControls.d.ts +3 -0
- package/dist/site/components/TestComp/TestComp.d.ts +3 -0
- package/dist/site/components/TestComp/component.js +39 -9
- package/dist/site/components/TextBox/TextBox.types.d.ts +12 -0
- package/dist/site/components/TextBox/component.js +9 -4
- package/dist/site/components/TextEffectsShared/manifestBase.d.ts +15 -15
- package/dist/site/components/TimePicker/TimePicker.types.d.ts +16 -0
- package/dist/site/components/TimePicker/component.js +59 -33
- package/dist/site/components/TimePicker/components/TimePickerField.d.ts +3 -1
- package/dist/site/components/TransparentVideo/useTransparentVideo.d.ts +1 -1
- package/dist/site/components/chunks/Button.js +7 -4
- package/dist/site/components/chunks/ResponsiveBox.js +9 -6
- package/dist/site/components/chunks/ResponsiveContainer.js +8 -2
- package/dist/site/components/chunks/types.impl.js +0 -18
- package/package.json +4 -4
|
@@ -395,7 +395,8 @@ const useChipOverflow = (ref, count) => {
|
|
|
395
395
|
const DropdownChips = ({
|
|
396
396
|
items,
|
|
397
397
|
inputControl,
|
|
398
|
-
removeItemLabel
|
|
398
|
+
removeItemLabel,
|
|
399
|
+
chipClassName
|
|
399
400
|
}) => {
|
|
400
401
|
const chipsRef = useRef(null);
|
|
401
402
|
const visible = useChipOverflow(chipsRef, items.length);
|
|
@@ -417,7 +418,8 @@ const DropdownChips = ({
|
|
|
417
418
|
styles.chip,
|
|
418
419
|
selectors.chip,
|
|
419
420
|
formatClassNames(semanticClassNames.chip),
|
|
420
|
-
index === visible - 1 && styles.chipShrink
|
|
421
|
+
index === visible - 1 && styles.chipShrink,
|
|
422
|
+
chipClassName
|
|
421
423
|
),
|
|
422
424
|
children: [
|
|
423
425
|
/* @__PURE__ */ jsx("span", { className: styles.chipLabel, children: item.label }),
|
|
@@ -456,17 +458,21 @@ const DropdownTrigger = ({
|
|
|
456
458
|
describedById,
|
|
457
459
|
isInvalid,
|
|
458
460
|
onFocus,
|
|
459
|
-
onBlur
|
|
461
|
+
onBlur,
|
|
462
|
+
elementProps
|
|
460
463
|
}) => {
|
|
464
|
+
var _a, _b, _c, _d;
|
|
461
465
|
const triggerClassName = clsx(
|
|
462
466
|
styles.trigger,
|
|
463
467
|
selectors.trigger,
|
|
464
|
-
formatClassNames(semanticClassNames.trigger)
|
|
468
|
+
formatClassNames(semanticClassNames.trigger),
|
|
469
|
+
(_a = elementProps == null ? void 0 : elementProps.trigger) == null ? void 0 : _a.className
|
|
465
470
|
);
|
|
466
471
|
const inputGroupClassName = clsx(
|
|
467
472
|
styles.trigger,
|
|
468
473
|
selectors.input,
|
|
469
|
-
formatClassNames(semanticClassNames.input)
|
|
474
|
+
formatClassNames(semanticClassNames.input),
|
|
475
|
+
(_b = elementProps == null ? void 0 : elementProps.input) == null ? void 0 : _b.className
|
|
470
476
|
);
|
|
471
477
|
const clearControl = clearable ? /* @__PURE__ */ jsx(
|
|
472
478
|
Combobox.Clear,
|
|
@@ -474,7 +480,8 @@ const DropdownTrigger = ({
|
|
|
474
480
|
className: clsx(
|
|
475
481
|
styles.clear,
|
|
476
482
|
selectors.clear,
|
|
477
|
-
formatClassNames(semanticClassNames.clear)
|
|
483
|
+
formatClassNames(semanticClassNames.clear),
|
|
484
|
+
(_c = elementProps == null ? void 0 : elementProps.clearButton) == null ? void 0 : _c.className
|
|
478
485
|
),
|
|
479
486
|
"aria-label": clearLabel,
|
|
480
487
|
"data-testid": TestIds.clear,
|
|
@@ -503,7 +510,8 @@ const DropdownTrigger = ({
|
|
|
503
510
|
{
|
|
504
511
|
items: selectedItems,
|
|
505
512
|
inputControl,
|
|
506
|
-
removeItemLabel
|
|
513
|
+
removeItemLabel,
|
|
514
|
+
chipClassName: (_d = elementProps == null ? void 0 : elementProps.chip) == null ? void 0 : _d.className
|
|
507
515
|
}
|
|
508
516
|
),
|
|
509
517
|
clearControl
|
|
@@ -544,12 +552,20 @@ const DropdownList = ({
|
|
|
544
552
|
isMultiple,
|
|
545
553
|
hasInput,
|
|
546
554
|
hasQuery,
|
|
547
|
-
popoverContainer
|
|
555
|
+
popoverContainer,
|
|
556
|
+
elementProps
|
|
548
557
|
}) => {
|
|
558
|
+
var _a, _b;
|
|
559
|
+
const listClassName = clsx(
|
|
560
|
+
selectors.list,
|
|
561
|
+
formatClassNames(semanticClassNames.listbox),
|
|
562
|
+
(_a = elementProps == null ? void 0 : elementProps.list) == null ? void 0 : _a.className
|
|
563
|
+
);
|
|
549
564
|
const optionClassName = clsx(
|
|
550
565
|
styles.option,
|
|
551
566
|
selectors.option,
|
|
552
|
-
formatClassNames(semanticClassNames.option)
|
|
567
|
+
formatClassNames(semanticClassNames.option),
|
|
568
|
+
(_b = elementProps == null ? void 0 : elementProps.option) == null ? void 0 : _b.className
|
|
553
569
|
);
|
|
554
570
|
const renderItem = (item) => /* @__PURE__ */ jsxs(Combobox.Item, { value: item, className: optionClassName, children: [
|
|
555
571
|
item.label,
|
|
@@ -572,11 +588,7 @@ const DropdownList = ({
|
|
|
572
588
|
/* @__PURE__ */ jsx(
|
|
573
589
|
Combobox.List,
|
|
574
590
|
{
|
|
575
|
-
className: clsx(
|
|
576
|
-
styles.inlineList,
|
|
577
|
-
selectors.list,
|
|
578
|
-
formatClassNames(semanticClassNames.listbox)
|
|
579
|
-
),
|
|
591
|
+
className: clsx(styles.inlineList, listClassName),
|
|
580
592
|
"data-testid": TestIds.listbox,
|
|
581
593
|
style: isGrid ? gridStyle : void 0,
|
|
582
594
|
children: listChildren
|
|
@@ -588,11 +600,7 @@ const DropdownList = ({
|
|
|
588
600
|
return /* @__PURE__ */ jsx(Combobox.Portal, { container: popoverContainer ?? void 0, children: /* @__PURE__ */ jsx(Combobox.Positioner, { className: styles.positioner, sideOffset: 4, children: /* @__PURE__ */ jsxs(
|
|
589
601
|
Combobox.Popup,
|
|
590
602
|
{
|
|
591
|
-
className: clsx(
|
|
592
|
-
styles.popup,
|
|
593
|
-
selectors.list,
|
|
594
|
-
formatClassNames(semanticClassNames.listbox)
|
|
595
|
-
),
|
|
603
|
+
className: clsx(styles.popup, listClassName),
|
|
596
604
|
"data-testid": TestIds.listbox,
|
|
597
605
|
children: [
|
|
598
606
|
/* @__PURE__ */ jsx(
|
|
@@ -611,6 +619,7 @@ const DropdownList = ({
|
|
|
611
619
|
const noop = () => {
|
|
612
620
|
};
|
|
613
621
|
function Dropdown(props) {
|
|
622
|
+
var _a;
|
|
614
623
|
const environmentService = useService(EnvironmentDefinition);
|
|
615
624
|
const { translate } = useService(
|
|
616
625
|
TranslationsDefinition
|
|
@@ -634,7 +643,8 @@ function Dropdown(props) {
|
|
|
634
643
|
onInput = noop,
|
|
635
644
|
onFocus = noop,
|
|
636
645
|
onBlur = noop,
|
|
637
|
-
wix
|
|
646
|
+
wix,
|
|
647
|
+
elementProps
|
|
638
648
|
} = props;
|
|
639
649
|
const label2 = props.label ?? defaultValues.label;
|
|
640
650
|
const placeholder = props.placeholder ?? defaultValues.placeholder;
|
|
@@ -743,7 +753,8 @@ function Dropdown(props) {
|
|
|
743
753
|
describedById: descriptionId,
|
|
744
754
|
isInvalid,
|
|
745
755
|
onFocus,
|
|
746
|
-
onBlur: handleBlur
|
|
756
|
+
onBlur: handleBlur,
|
|
757
|
+
elementProps
|
|
747
758
|
}
|
|
748
759
|
);
|
|
749
760
|
const list2 = /* @__PURE__ */ jsx(
|
|
@@ -760,7 +771,8 @@ function Dropdown(props) {
|
|
|
760
771
|
isMultiple,
|
|
761
772
|
hasInput,
|
|
762
773
|
hasQuery,
|
|
763
|
-
popoverContainer
|
|
774
|
+
popoverContainer,
|
|
775
|
+
elementProps
|
|
764
776
|
}
|
|
765
777
|
);
|
|
766
778
|
const field = /* @__PURE__ */ jsxs(
|
|
@@ -802,7 +814,8 @@ function Dropdown(props) {
|
|
|
802
814
|
className: clsx(
|
|
803
815
|
styles.label,
|
|
804
816
|
selectors.label,
|
|
805
|
-
formatClassNames(semanticClassNames.label)
|
|
817
|
+
formatClassNames(semanticClassNames.label),
|
|
818
|
+
(_a = elementProps == null ? void 0 : elementProps.label) == null ? void 0 : _a.className
|
|
806
819
|
),
|
|
807
820
|
"data-testid": TestIds.label,
|
|
808
821
|
children: [
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
import { DropdownItem } from '../dropdownUtils';
|
|
3
|
-
export declare const DropdownChips: ({ items, inputControl, removeItemLabel, }: {
|
|
3
|
+
export declare const DropdownChips: ({ items, inputControl, removeItemLabel, chipClassName, }: {
|
|
4
4
|
items: Array<DropdownItem>;
|
|
5
5
|
inputControl: React.ReactNode;
|
|
6
6
|
removeItemLabel: string;
|
|
7
|
+
chipClassName?: string;
|
|
7
8
|
}) => React.ReactElement;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
import { DropdownItem } from '../dropdownUtils';
|
|
3
|
+
import { DropdownElementProps } from '../Dropdown.types';
|
|
3
4
|
type DropdownListProps = {
|
|
4
5
|
optionItems: Array<DropdownItem>;
|
|
5
6
|
filterItem: (item: DropdownItem, typed: string) => boolean;
|
|
@@ -13,6 +14,7 @@ type DropdownListProps = {
|
|
|
13
14
|
hasInput: boolean;
|
|
14
15
|
hasQuery: boolean;
|
|
15
16
|
popoverContainer: HTMLDivElement | null;
|
|
17
|
+
elementProps?: DropdownElementProps;
|
|
16
18
|
};
|
|
17
|
-
export declare const DropdownList: ({ optionItems, filterItem, inputValue, limit, isGrid, isSearchable, columns, inline, isMultiple, hasInput, hasQuery, popoverContainer, }: DropdownListProps) => React.ReactElement;
|
|
19
|
+
export declare const DropdownList: ({ optionItems, filterItem, inputValue, limit, isGrid, isSearchable, columns, inline, isMultiple, hasInput, hasQuery, popoverContainer, elementProps, }: DropdownListProps) => React.ReactElement;
|
|
18
20
|
export {};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
import { DropdownItem } from '../dropdownUtils';
|
|
3
|
+
import { DropdownElementProps } from '../Dropdown.types';
|
|
3
4
|
type DropdownTriggerProps = {
|
|
4
5
|
isMultiple: boolean;
|
|
5
6
|
isSearchable: boolean;
|
|
@@ -15,6 +16,7 @@ type DropdownTriggerProps = {
|
|
|
15
16
|
isInvalid: boolean;
|
|
16
17
|
onFocus: (event: React.FocusEvent) => void;
|
|
17
18
|
onBlur: (event: React.FocusEvent) => void;
|
|
19
|
+
elementProps?: DropdownElementProps;
|
|
18
20
|
};
|
|
19
|
-
export declare const DropdownTrigger: ({ isMultiple, isSearchable, clearable, selectedLabel, selectedItems, placeholder, ariaLabel, labelId, clearLabel, removeItemLabel, describedById, isInvalid, onFocus, onBlur, }: DropdownTriggerProps) => React.ReactElement;
|
|
21
|
+
export declare const DropdownTrigger: ({ isMultiple, isSearchable, clearable, selectedLabel, selectedItems, placeholder, ariaLabel, labelId, clearLabel, removeItemLabel, describedById, isInvalid, onFocus, onBlur, elementProps, }: DropdownTriggerProps) => React.ReactElement;
|
|
20
22
|
export {};
|
|
@@ -10,7 +10,8 @@ const ResponsiveAppWidget = (props) => {
|
|
|
10
10
|
containerProps,
|
|
11
11
|
containerRootClassName = "",
|
|
12
12
|
className = "",
|
|
13
|
-
shouldUseClassName
|
|
13
|
+
shouldUseClassName,
|
|
14
|
+
elementProps
|
|
14
15
|
} = props;
|
|
15
16
|
return /* @__PURE__ */ jsx(
|
|
16
17
|
"div",
|
|
@@ -20,7 +21,7 @@ const ResponsiveAppWidget = (props) => {
|
|
|
20
21
|
[className]: shouldUseClassName
|
|
21
22
|
}),
|
|
22
23
|
...getDataAttributes(props),
|
|
23
|
-
children: /* @__PURE__ */ jsx(ResponsiveContainer, { ...containerProps, children })
|
|
24
|
+
children: /* @__PURE__ */ jsx(ResponsiveContainer, { ...containerProps, elementProps, children })
|
|
24
25
|
}
|
|
25
26
|
);
|
|
26
27
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DefaultCompPlatformProps, DefaultContainerProps } from '../../../../types/vendored/editor-elements-types-thunderbolt';
|
|
2
|
-
import { ResponsiveContainerPlatformProps } from '../../../../common/ResponsiveContainer/ResponsiveContainer.types';
|
|
2
|
+
import { ContainerElementProps, ResponsiveContainerPlatformProps } from '../../../../common/ResponsiveContainer/ResponsiveContainer.types';
|
|
3
3
|
type AppWidgetMapperProps = {
|
|
4
4
|
shouldUseClassName: boolean;
|
|
5
5
|
};
|
|
@@ -7,5 +7,7 @@ type ResponsiveAppWidgetPlatformProps = {
|
|
|
7
7
|
containerProps: ResponsiveContainerPlatformProps;
|
|
8
8
|
containerRootClassName?: string;
|
|
9
9
|
};
|
|
10
|
-
export type IResponsiveAppWidgetProps = DefaultCompPlatformProps & DefaultContainerProps & ResponsiveAppWidgetPlatformProps & AppWidgetMapperProps
|
|
10
|
+
export type IResponsiveAppWidgetProps = DefaultCompPlatformProps & DefaultContainerProps & ResponsiveAppWidgetPlatformProps & AppWidgetMapperProps & {
|
|
11
|
+
elementProps?: ContainerElementProps;
|
|
12
|
+
};
|
|
11
13
|
export {};
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
import { IResponsiveBoxProps } from './components/Container.types';
|
|
3
|
+
import { ContainerElementProps } from '../../../common/ResponsiveContainer/ResponsiveContainer.types';
|
|
3
4
|
import { ResponsiveContainerProps } from '../../../types/vendored/mappers-legacy-service';
|
|
4
5
|
export type LegacyContainerProps = {
|
|
5
6
|
id: string;
|
|
@@ -8,6 +9,7 @@ export type LegacyContainerProps = {
|
|
|
8
9
|
containerRootClassName: string;
|
|
9
10
|
role?: IResponsiveBoxProps['role'];
|
|
10
11
|
translations?: any;
|
|
12
|
+
elementProps?: ContainerElementProps;
|
|
11
13
|
};
|
|
12
|
-
declare const LegacyContainer: ({ id, className, containerProps, containerRootClassName, role, translations, children, }: React.PropsWithChildren<LegacyContainerProps>) => React.JSX.Element;
|
|
14
|
+
declare const LegacyContainer: ({ id, className, containerProps, containerRootClassName, role, translations, elementProps, children, }: React.PropsWithChildren<LegacyContainerProps>) => React.JSX.Element;
|
|
13
15
|
export default LegacyContainer;
|
|
@@ -22,6 +22,7 @@ const LegacyContainer = ({
|
|
|
22
22
|
containerRootClassName,
|
|
23
23
|
role,
|
|
24
24
|
translations,
|
|
25
|
+
elementProps,
|
|
25
26
|
children
|
|
26
27
|
}) => /* @__PURE__ */ jsx(
|
|
27
28
|
ResponsiveBox,
|
|
@@ -32,6 +33,7 @@ const LegacyContainer = ({
|
|
|
32
33
|
containerRootClassName,
|
|
33
34
|
role,
|
|
34
35
|
translations,
|
|
36
|
+
elementProps,
|
|
35
37
|
children: () => /* @__PURE__ */ jsx(ResponsiveContainer, { ...containerProps, children: () => children })
|
|
36
38
|
}
|
|
37
39
|
);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CorvidTypes, CorvidKeyboardEventHandler, IComponentEvent } from '../../../../types/vendored/editor-elements-types-corvid';
|
|
2
2
|
import { DefaultContainerProps, DefaultCompPlatformProps } from '../../../../types/vendored/editor-elements-types-thunderbolt';
|
|
3
|
-
import { ResponsiveContainerPlatformProps } from '../../../../common/ResponsiveContainer/ResponsiveContainer.types';
|
|
3
|
+
import { ContainerElementProps, ResponsiveContainerPlatformProps } from '../../../../common/ResponsiveContainer/ResponsiveContainer.types';
|
|
4
4
|
import { IElementPropsSDKActions } from '../../../../common/sdk/props-factories/elementPropsSDKFactory';
|
|
5
5
|
import { IClickPropsSDKActions } from '../../../../common/sdk/props-factories/clickPropsSDKFactory';
|
|
6
6
|
import { IFocusPropsSDKActions, IFocusPropsImperativeActions } from '../../../../common/sdk/props-factories/focusPropsSDKFactory';
|
|
@@ -59,6 +59,7 @@ export type IResponsiveBoxProps = DefaultCompPlatformProps & ContainerSDKActions
|
|
|
59
59
|
ref?: React.Ref<IContainerImperativeActions>;
|
|
60
60
|
observeChildListChange?: (id: string, target: HTMLElement) => void;
|
|
61
61
|
shouldUseContainerLayoutClass?: boolean;
|
|
62
|
+
elementProps?: ContainerElementProps;
|
|
62
63
|
};
|
|
63
64
|
export type ISkinableContainerProps = IContainerProps & {
|
|
64
65
|
classes: Record<string, string>;
|
|
@@ -2,6 +2,7 @@ import { default as React } from 'react';
|
|
|
2
2
|
import { DefaultContainerProps, DefaultCompPlatformProps } from '../../../types/vendored/editor-elements-types-thunderbolt';
|
|
3
3
|
import { AriaProps } from '../../../types/vendored/editor-elements-types-a11y';
|
|
4
4
|
import { IResponsiveBoxProps } from '../LegacyContainer/components/Container.types';
|
|
5
|
+
import { ContainerElementProps } from '../../../common/ResponsiveContainer/ResponsiveContainer.types';
|
|
5
6
|
interface RenderContainerProps {
|
|
6
7
|
state: React.ReactNode;
|
|
7
8
|
}
|
|
@@ -11,5 +12,6 @@ export type ILegacyMultiStateBoxProps = Omit<IResponsiveBoxProps, 'children' | '
|
|
|
11
12
|
selectedStateId?: string;
|
|
12
13
|
onChange?: (event: React.ChangeEvent) => void;
|
|
13
14
|
renderContainer?: (props: RenderContainerProps) => React.ReactElement<any> | null;
|
|
15
|
+
elementProps?: ContainerElementProps;
|
|
14
16
|
};
|
|
15
17
|
export {};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
export type Edge = 'before' | 'after';
|
|
2
2
|
export declare const getShapeConfig: (edge: Edge, displayName: string) => {
|
|
3
|
-
cssPropertyType: import('@wix/
|
|
3
|
+
cssPropertyType: import('@wix/component-protocol/schema').CssPropertyEnumCssPropertyType;
|
|
4
4
|
defaultValue: string;
|
|
5
5
|
displayName: string;
|
|
6
6
|
customEnum: {
|
|
7
|
-
cssPropertyType: import('@wix/
|
|
7
|
+
cssPropertyType: import('@wix/component-protocol/schema').CssPropertyEnumCssPropertyType;
|
|
8
8
|
options: {
|
|
9
9
|
value: string;
|
|
10
10
|
displayName: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare const newTypeConfig: {
|
|
2
2
|
customEnum: {
|
|
3
|
-
cssPropertyType: import('@wix/
|
|
3
|
+
cssPropertyType: import('@wix/component-protocol/schema').CssPropertyEnumCssPropertyType;
|
|
4
4
|
options: {
|
|
5
5
|
value: string;
|
|
6
6
|
displayName: string;
|
|
@@ -12,5 +12,5 @@ export declare const newTypeConfig: {
|
|
|
12
12
|
};
|
|
13
13
|
displayName: string;
|
|
14
14
|
defaultValue: string;
|
|
15
|
-
cssPropertyType: import('@wix/
|
|
15
|
+
cssPropertyType: import('@wix/component-protocol/schema').CssPropertyEnumCssPropertyType;
|
|
16
16
|
};
|
|
@@ -16943,6 +16943,7 @@ const isIOS = (win) => {
|
|
|
16943
16943
|
return /iPad|iPhone|iPod/.test(platform) || platform === "MacIntel" && /Macintosh/.test(userAgent) && (((_c = win == null ? void 0 : win.navigator) == null ? void 0 : _c.maxTouchPoints) ?? 0) > 1;
|
|
16944
16944
|
};
|
|
16945
16945
|
const Lottie = (props) => {
|
|
16946
|
+
var _a;
|
|
16946
16947
|
const { translate } = useService(TranslationsDefinition);
|
|
16947
16948
|
const translateByKey = translate(ARIA_LABEL_NAMESPACE);
|
|
16948
16949
|
const t = (key2) => getTranslation(translateByKey, key2, TranslationKeys, DefaultTranslations);
|
|
@@ -16957,6 +16958,7 @@ const Lottie = (props) => {
|
|
|
16957
16958
|
speed = rootDataDefaults.speed,
|
|
16958
16959
|
showButtonOnHover: showButtonOnHover2 = rootDataDefaults.showButtonOnHover,
|
|
16959
16960
|
allowClickToStop = rootDataDefaults.allowClickToStop,
|
|
16961
|
+
elementProps,
|
|
16960
16962
|
onClick,
|
|
16961
16963
|
onDblClick,
|
|
16962
16964
|
onMouseIn,
|
|
@@ -17048,7 +17050,8 @@ const Lottie = (props) => {
|
|
|
17048
17050
|
...direction ? { direction } : {},
|
|
17049
17051
|
className: clsx(
|
|
17050
17052
|
semanticSelectors.playButton,
|
|
17051
|
-
styles.playButton
|
|
17053
|
+
styles.playButton,
|
|
17054
|
+
(_a = elementProps == null ? void 0 : elementProps.playButton) == null ? void 0 : _a.className
|
|
17052
17055
|
),
|
|
17053
17056
|
a11y: {
|
|
17054
17057
|
ariaLabel: isPlaying ? t("pauseButton") : t("playButton"),
|
|
@@ -24,6 +24,12 @@ export interface LottieProps extends SdkFunctionClickableProps, SdkFunctionMouse
|
|
|
24
24
|
showButtonOnHover?: string;
|
|
25
25
|
/** Clicking the canvas pauses/resumes the animation. Default `true`. */
|
|
26
26
|
allowClickToStop?: boolean;
|
|
27
|
+
/** Per-element className overrides keyed by manifest element name. */
|
|
28
|
+
elementProps?: {
|
|
29
|
+
playButton?: {
|
|
30
|
+
className?: string;
|
|
31
|
+
};
|
|
32
|
+
};
|
|
27
33
|
}
|
|
28
34
|
export interface UseLottieParams {
|
|
29
35
|
animationUrl?: string;
|
|
@@ -11,13 +11,36 @@ export type MenuItemType = MenuItemData & {
|
|
|
11
11
|
isContainerItem?: boolean;
|
|
12
12
|
forceOpen?: boolean;
|
|
13
13
|
};
|
|
14
|
+
export type MenuDropdownItemsElementProps = {
|
|
15
|
+
item?: {
|
|
16
|
+
className?: string;
|
|
17
|
+
};
|
|
18
|
+
subItem?: {
|
|
19
|
+
className?: string;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
export type MenuDropdownElementProps = {
|
|
23
|
+
className?: string;
|
|
24
|
+
elementProps?: MenuDropdownItemsElementProps;
|
|
25
|
+
};
|
|
26
|
+
export type MenuNavbarElementProps = {
|
|
27
|
+
item?: {
|
|
28
|
+
className?: string;
|
|
29
|
+
};
|
|
30
|
+
scrollButton?: {
|
|
31
|
+
className?: string;
|
|
32
|
+
};
|
|
33
|
+
dropdown?: MenuDropdownElementProps;
|
|
34
|
+
};
|
|
35
|
+
export type HamburgerMenuElementProps = {
|
|
36
|
+
hamburgerCloseButton?: ButtonProps;
|
|
37
|
+
};
|
|
14
38
|
export type HamburgerMenuProps = {
|
|
39
|
+
className?: string;
|
|
15
40
|
isOpen?: boolean;
|
|
16
41
|
content?: React.ReactNode;
|
|
17
42
|
headerContent?: React.ReactNode;
|
|
18
|
-
elementProps?:
|
|
19
|
-
hamburgerCloseButton?: ButtonProps;
|
|
20
|
-
};
|
|
43
|
+
elementProps?: HamburgerMenuElementProps;
|
|
21
44
|
};
|
|
22
45
|
export type MenuProps = SdkFunctionMouseHoverProps & {
|
|
23
46
|
/** DOM `id` on the root `.menu`. */
|
|
@@ -37,10 +60,12 @@ export type MenuProps = SdkFunctionMouseHoverProps & {
|
|
|
37
60
|
/** Props forwarded to nested elements. `navbar` carries the items and the navbar `a11y` bag; `hamburgerMenu` holds the dialog slots; `hamburgerOpenButton` is the open-button prop bag. */
|
|
38
61
|
elementProps: {
|
|
39
62
|
navbar?: {
|
|
63
|
+
className?: string;
|
|
40
64
|
items?: Array<MenuItemType>;
|
|
41
65
|
direction?: Direction;
|
|
42
66
|
submenuDirection?: Direction;
|
|
43
67
|
a11y?: A11y;
|
|
68
|
+
elementProps?: MenuNavbarElementProps;
|
|
44
69
|
};
|
|
45
70
|
hamburgerMenu?: HamburgerMenuProps;
|
|
46
71
|
hamburgerOpenButton?: ButtonProps;
|
|
@@ -61,6 +86,8 @@ export type DropdownProps = (HorizontalDropdownProps | VerticalDropdownProps) &
|
|
|
61
86
|
item: MenuItemType;
|
|
62
87
|
isOpen?: boolean;
|
|
63
88
|
menuOrientation: MenuOrientationType;
|
|
89
|
+
className?: string;
|
|
90
|
+
elementProps?: MenuDropdownItemsElementProps;
|
|
64
91
|
};
|
|
65
92
|
export type MenuStates = {
|
|
66
93
|
hamburgerMenuOpen?: boolean;
|
|
@@ -111,6 +138,7 @@ export type IMenuContentProps = Partial<IMenuItemsPropsSDKActions> & {
|
|
|
111
138
|
direction?: Direction;
|
|
112
139
|
submenuDirection?: Direction;
|
|
113
140
|
submenuToggleIdPrefix?: string;
|
|
141
|
+
menuElementProps?: MenuNavbarElementProps;
|
|
114
142
|
};
|
|
115
143
|
export type IMenuItemProps = Partial<IMenuItemsPropsSDKActions> & {
|
|
116
144
|
item: PropsWithChildren<MenuItemData & {
|
|
@@ -123,6 +151,7 @@ export type IMenuItemProps = Partial<IMenuItemsPropsSDKActions> & {
|
|
|
123
151
|
getAnimationPackage: () => MenuAnimationNameType;
|
|
124
152
|
submenuDirection?: Direction;
|
|
125
153
|
submenuToggleIdPrefix?: string;
|
|
154
|
+
menuElementProps?: MenuNavbarElementProps;
|
|
126
155
|
} & Translations;
|
|
127
156
|
export type ScrollControlsProps = {
|
|
128
157
|
isScrollForwardButtonShown: boolean;
|
|
@@ -130,6 +159,7 @@ export type ScrollControlsProps = {
|
|
|
130
159
|
scrollPageForward: () => void;
|
|
131
160
|
scrollPageToBackward: () => void;
|
|
132
161
|
previewState?: string;
|
|
162
|
+
scrollButtonClassName?: string;
|
|
133
163
|
};
|
|
134
164
|
export type ScrollButtonProps = {
|
|
135
165
|
className?: string;
|