@wix/site-ui 1.306.0 → 1.307.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/Dialog/index.css +4 -0
- package/dist/Dialog/index.d.ts +3 -1
- package/dist/Dialog/index.js +18 -4
- package/dist/index.d.ts +11 -9
- package/package.json +2 -2
package/dist/Dialog/index.css
CHANGED
package/dist/Dialog/index.d.ts
CHANGED
|
@@ -139,7 +139,7 @@ export declare const Dialog: {
|
|
|
139
139
|
Viewport: React_2.ForwardRefExoticComponent<Omit<Omit<Omit<AlertDialogViewportProps, "ref"> & React_2.RefAttributes<HTMLDivElement>, "ref">, "className"> & {
|
|
140
140
|
className?: string;
|
|
141
141
|
} & React_2.RefAttributes<HTMLDivElement>>;
|
|
142
|
-
Root: typeof
|
|
142
|
+
Root: typeof Root;
|
|
143
143
|
Trigger: typeof Trigger;
|
|
144
144
|
Portal: ({ container, ...props }: PortalProps) => JSX_2.Element;
|
|
145
145
|
Handle: typeof Dialog_2.Handle;
|
|
@@ -948,6 +948,8 @@ declare interface ReasonToEventMap {
|
|
|
948
948
|
|
|
949
949
|
declare type ReferenceType = Element | VirtualElement;
|
|
950
950
|
|
|
951
|
+
declare function Root<Payload = unknown>({ modal, ...props }: Dialog_2.Root.Props<Payload>): JSX_2.Element;
|
|
952
|
+
|
|
951
953
|
declare const scrub: "scrub";
|
|
952
954
|
|
|
953
955
|
declare const selectors: {
|
package/dist/Dialog/index.js
CHANGED
|
@@ -8,11 +8,13 @@ import * as __rspack_external_react from "react";
|
|
|
8
8
|
const Dialog_module = {
|
|
9
9
|
backdrop: "backdrop-EHLKAc",
|
|
10
10
|
viewport: "viewport-nOzLZZ",
|
|
11
|
+
containScroll: "containScroll-M8I4Mc",
|
|
11
12
|
popup: "popup-RjSkgq",
|
|
12
13
|
close: "close-zqdBdX",
|
|
13
14
|
title: "title-U8Hyut",
|
|
14
15
|
description: "description-ZV1a4j"
|
|
15
16
|
};
|
|
17
|
+
const PageScrollUnlockedContext = /*#__PURE__*/ __rspack_external_react.createContext(false);
|
|
16
18
|
const Portal = ({ container, ...props })=>/*#__PURE__*/ jsx(DialogPortal_DialogPortal, {
|
|
17
19
|
container: container ?? getThemedContainer(),
|
|
18
20
|
...props
|
|
@@ -42,11 +44,23 @@ const Title = /*#__PURE__*/ __rspack_external_react.forwardRef(({ className, ...
|
|
|
42
44
|
className: clsx(Dialog_module.title, className),
|
|
43
45
|
...props
|
|
44
46
|
}));
|
|
45
|
-
const Viewport = /*#__PURE__*/ __rspack_external_react.forwardRef(({ className, ...props }, ref)
|
|
47
|
+
const Viewport = /*#__PURE__*/ __rspack_external_react.forwardRef(({ className, ...props }, ref)=>{
|
|
48
|
+
const pageScrollUnlocked = __rspack_external_react.useContext(PageScrollUnlockedContext);
|
|
49
|
+
return /*#__PURE__*/ jsx(DialogViewport_DialogViewport, {
|
|
46
50
|
ref: ref,
|
|
47
|
-
className: clsx(Dialog_module.viewport, className),
|
|
51
|
+
className: clsx(Dialog_module.viewport, pageScrollUnlocked && Dialog_module.containScroll, className),
|
|
48
52
|
...props
|
|
49
|
-
})
|
|
53
|
+
});
|
|
54
|
+
});
|
|
55
|
+
function Root({ modal = true, ...props }) {
|
|
56
|
+
return /*#__PURE__*/ jsx(PageScrollUnlockedContext.Provider, {
|
|
57
|
+
value: 'trap-focus' === modal,
|
|
58
|
+
children: /*#__PURE__*/ jsx(DialogRoot, {
|
|
59
|
+
modal: modal,
|
|
60
|
+
...props
|
|
61
|
+
})
|
|
62
|
+
});
|
|
63
|
+
}
|
|
50
64
|
function Trigger({ className, ...props }) {
|
|
51
65
|
return /*#__PURE__*/ jsx(DialogTrigger_DialogTrigger, {
|
|
52
66
|
...props,
|
|
@@ -60,7 +74,7 @@ const Dialog = {
|
|
|
60
74
|
Popup: Popup,
|
|
61
75
|
Title: Title,
|
|
62
76
|
Viewport: Viewport,
|
|
63
|
-
Root:
|
|
77
|
+
Root: Root,
|
|
64
78
|
Trigger: Trigger,
|
|
65
79
|
Portal: Portal,
|
|
66
80
|
Handle: DialogHandle,
|
package/dist/index.d.ts
CHANGED
|
@@ -3157,7 +3157,7 @@ export declare const Dialog: {
|
|
|
3157
3157
|
Viewport: React_2.ForwardRefExoticComponent<Omit<Omit<Omit<AlertDialogViewportProps_2, "ref"> & React_2.RefAttributes<HTMLDivElement>, "ref">, "className"> & {
|
|
3158
3158
|
className?: string;
|
|
3159
3159
|
} & React_2.RefAttributes<HTMLDivElement>>;
|
|
3160
|
-
Root: typeof
|
|
3160
|
+
Root: typeof Root_3;
|
|
3161
3161
|
Trigger: typeof Trigger_3;
|
|
3162
3162
|
Portal: ({ container, ...props }: PortalProps) => JSX_2.Element;
|
|
3163
3163
|
Handle: typeof Dialog_2.Handle;
|
|
@@ -6346,7 +6346,7 @@ export declare const NavigationMenu: {
|
|
|
6346
6346
|
Icon: React_2.ForwardRefExoticComponent<Omit<Omit<Omit<NavigationMenuIconProps_2, "ref"> & React_2.RefAttributes<HTMLSpanElement>, "ref">, "className"> & {
|
|
6347
6347
|
className?: string;
|
|
6348
6348
|
} & React_2.RefAttributes<HTMLSpanElement>>;
|
|
6349
|
-
Root: typeof
|
|
6349
|
+
Root: typeof Root_4;
|
|
6350
6350
|
Portal: React_2.ForwardRefExoticComponent<Omit<NavigationMenuPortalProps_2, "ref"> & React_2.RefAttributes<HTMLDivElement>>;
|
|
6351
6351
|
};
|
|
6352
6352
|
|
|
@@ -8366,7 +8366,7 @@ export declare interface ProgressValueProps extends Omit<BaseUIComponentProps<'s
|
|
|
8366
8366
|
export declare interface ProgressValueState extends ProgressRootState {}
|
|
8367
8367
|
|
|
8368
8368
|
export declare const Radio: {
|
|
8369
|
-
Root: typeof
|
|
8369
|
+
Root: typeof Root_5;
|
|
8370
8370
|
Indicator: React_2.ForwardRefExoticComponent<Omit<Omit<Omit<RadioIndicatorProps_2, "ref"> & React_2.RefAttributes<HTMLSpanElement>, "ref">, "className"> & {
|
|
8371
8371
|
className?: string;
|
|
8372
8372
|
} & React_2.RefAttributes<HTMLSpanElement>>;
|
|
@@ -8775,13 +8775,15 @@ declare function Root_2<Value = any>({ className, dir, separator, 'aria-label':
|
|
|
8775
8775
|
separator?: React_2.ReactNode;
|
|
8776
8776
|
}): JSX_2.Element;
|
|
8777
8777
|
|
|
8778
|
-
declare function Root_3<
|
|
8778
|
+
declare function Root_3<Payload = unknown>({ modal, ...props }: Dialog_2.Root.Props<Payload>): JSX_2.Element;
|
|
8779
8779
|
|
|
8780
|
-
declare function Root_4<Value>({ className,
|
|
8780
|
+
declare function Root_4<Value = any>({ className, orientation, ...props }: WithStringClassName<NavigationMenu_2.Root.Props<Value>>): JSX_2.Element;
|
|
8781
8781
|
|
|
8782
|
-
declare function Root_5<Value
|
|
8782
|
+
declare function Root_5<Value>({ className, size, style, ...props }: RootProps_2<Value>): JSX_2.Element;
|
|
8783
8783
|
|
|
8784
|
-
declare
|
|
8784
|
+
declare function Root_6<Value extends number | ReadonlyArray<number>>({ className, size, style, ...props }: RootProps_3<Value>): JSX_2.Element;
|
|
8785
|
+
|
|
8786
|
+
declare const Root_7: React_2.ForwardRefExoticComponent<Omit<Omit<Omit<ToastRootProps_2, "ref"> & React_2.RefAttributes<HTMLDivElement>, "ref">, "className"> & {
|
|
8785
8787
|
className?: string;
|
|
8786
8788
|
} & {
|
|
8787
8789
|
skin?: string;
|
|
@@ -11739,7 +11741,7 @@ export declare const Slider: {
|
|
|
11739
11741
|
Indicator: React_2.ForwardRefExoticComponent<Omit<Omit<Omit<SliderIndicatorProps_2, "ref"> & React_2.RefAttributes<HTMLDivElement>, "ref">, "className"> & {
|
|
11740
11742
|
className?: string;
|
|
11741
11743
|
} & React_2.RefAttributes<HTMLDivElement>>;
|
|
11742
|
-
Root: typeof
|
|
11744
|
+
Root: typeof Root_6;
|
|
11743
11745
|
};
|
|
11744
11746
|
|
|
11745
11747
|
export declare namespace Slider_2 {
|
|
@@ -12806,7 +12808,7 @@ declare type ToastNamespace = {
|
|
|
12806
12808
|
Provider: typeof Toast_2.Provider;
|
|
12807
12809
|
Portal: typeof Portal;
|
|
12808
12810
|
Viewport: typeof Viewport;
|
|
12809
|
-
Root: typeof
|
|
12811
|
+
Root: typeof Root_7;
|
|
12810
12812
|
Title: typeof Title_2;
|
|
12811
12813
|
Close: typeof CloseButton;
|
|
12812
12814
|
useToastManager: typeof Toast_2.useToastManager;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wix/site-ui",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.307.0",
|
|
4
4
|
"description": "Pure UI components for the Wix site builder",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -95,5 +95,5 @@
|
|
|
95
95
|
"registry": "https://registry.npmjs.org/",
|
|
96
96
|
"access": "public"
|
|
97
97
|
},
|
|
98
|
-
"falconPackageHash": "
|
|
98
|
+
"falconPackageHash": "897e7589cc1211e7c27a38dab7d7123acc891838bf54a7872b808b1d"
|
|
99
99
|
}
|