@gridui/modal 2.1.0 → 2.2.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/README.md +18 -2
- package/dist/index.js +4 -2
- package/dist/index.js.map +2 -2
- package/dist/modal-panel/modal-panel.d.ts +9 -1
- package/dist/styled.js +4 -0
- package/dist/styles.css +594 -3
- package/dist/styles.local.css +226 -0
- package/docs/catalog.json +2 -1
- package/docs/reference/modal-panel.md +4 -0
- package/package.json +13 -8
package/README.md
CHANGED
|
@@ -3,10 +3,20 @@
|
|
|
3
3
|
Core family. Public API: `Modal`, `ModalAction`, `ModalActionProps`, `ModalActions`, `ModalActionsProps`, `ModalBody`, `ModalBodyProps`, `ModalClose`, `ModalCloseProps`, `ModalDescription`, `ModalDescriptionProps`, `ModalFooter`, `ModalFooterNote`, `ModalFooterNoteProps`, `ModalFooterProps`, `ModalHeader`, `ModalHeaderProps`, `ModalPanel`, `ModalPanelProps`, `ModalProps`, `ModalSectionProps`, `ModalSpace`, `ModalSpacing`, `ModalTitle`, `ModalTitleProps`, `ModalTrigger`, `ModalTriggerProps`.
|
|
4
4
|
|
|
5
5
|
Import components from `@gridui/modal` and load `@gridui/modal/styles.css` after Theme.
|
|
6
|
-
|
|
6
|
+
Applications own routes, labels, state persistence, and branding.
|
|
7
7
|
|
|
8
8
|
See [component ownership](https://github.com/sudo-ui/GridUI-React-Monorepo/blob/main/docs/component-ownership.md) and [release history](https://github.com/sudo-ui/GridUI-React-Monorepo/tree/main/packages-core/modal/.changeset/history).
|
|
9
9
|
|
|
10
|
+
## Styles
|
|
11
|
+
|
|
12
|
+
Load Theme once. Use `@gridui/modal/styled` for automatic component CSS in
|
|
13
|
+
CSS-aware bundlers, or keep the CSS-free root import and load `@gridui/modal/styles.css`.
|
|
14
|
+
Both entries expose the same root API. The standalone stylesheet includes component
|
|
15
|
+
dependency styles; Theme/reset remain separate. See the
|
|
16
|
+
[integration guide](https://github.com/sudo-ui/GridUI-React-Monorepo/blob/main/docs/usage/integration.md)
|
|
17
|
+
for static HTML loading, SSR limits, and avoiding duplicate CSS.
|
|
18
|
+
|
|
19
|
+
|
|
10
20
|
## Modal
|
|
11
21
|
|
|
12
22
|
The centered modal shares Radix Dialog's focus and dismissal behavior with
|
|
@@ -83,7 +93,7 @@ consumers decide when an asynchronous primary action has succeeded.
|
|
|
83
93
|
|
|
84
94
|
|
|
85
95
|
|
|
86
|
-
Surface motion uses `@gridui/overlay`;
|
|
96
|
+
Surface motion uses `@gridui/overlay`; its styles are included.
|
|
87
97
|
|
|
88
98
|
[Component reference](docs/reference/README.md) contains focused API pages for each public component.
|
|
89
99
|
|
|
@@ -91,3 +101,9 @@ Shared animation policy and tempo come from `MotionConfig` in `@gridui/motion`.
|
|
|
91
101
|
Disabled or reduced-motion policy settles decoration without disabling interaction.
|
|
92
102
|
See the [motion guide](https://github.com/sudo-ui/GridUI-React-Monorepo/tree/main/packages-core/motion)
|
|
93
103
|
for CSS scopes, portal behavior, and specialized timing contracts.
|
|
104
|
+
|
|
105
|
+
## Local color scopes
|
|
106
|
+
|
|
107
|
+
Pass `container` to the portaled panel/content to mount it in a local
|
|
108
|
+
`data-gridui-system` region. Dialog panels use that host for their backdrop too.
|
|
109
|
+
The default remains `document.body`; React ancestry does not determine CSS inheritance.
|
package/dist/index.js
CHANGED
|
@@ -216,6 +216,7 @@ var ModalPanel = (props) => {
|
|
|
216
216
|
const {
|
|
217
217
|
className,
|
|
218
218
|
forceMount,
|
|
219
|
+
container,
|
|
219
220
|
...restProps
|
|
220
221
|
} = props;
|
|
221
222
|
const content = /* @__PURE__ */ jsx10(
|
|
@@ -229,16 +230,17 @@ var ModalPanel = (props) => {
|
|
|
229
230
|
}
|
|
230
231
|
);
|
|
231
232
|
return /* @__PURE__ */ jsxs2(Fragment, { children: [
|
|
232
|
-
/* @__PURE__ */ jsx10(Dialog5.Portal, { children: /* @__PURE__ */ jsx10(
|
|
233
|
+
/* @__PURE__ */ jsx10(Dialog5.Portal, { container, children: /* @__PURE__ */ jsx10(
|
|
233
234
|
Dialog5.Overlay,
|
|
234
235
|
{
|
|
235
|
-
className: cn8(overlayBackdropStyles(), "gridui-modal-overlay gridui-u-modal--fixed gridui-u-modal--inset-0 gridui-u-modal--z-(--gridui-z-dialog-backdrop)
|
|
236
|
+
className: cn8(overlayBackdropStyles(), "gridui-modal-overlay gridui-u-modal--fixed gridui-u-modal--inset-0 gridui-u-modal--z-(--gridui-z-dialog-backdrop)"),
|
|
236
237
|
style: motionStyle
|
|
237
238
|
}
|
|
238
239
|
) }),
|
|
239
240
|
/* @__PURE__ */ jsx10(
|
|
240
241
|
Dialog5.Portal,
|
|
241
242
|
{
|
|
243
|
+
container,
|
|
242
244
|
forceMount,
|
|
243
245
|
children: forceMount ? /* @__PURE__ */ jsx10(RetainedLayer, { children: content }) : content
|
|
244
246
|
}
|
package/dist/index.js.map
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../src/modal/modal.tsx", "../src/modal-action/modal-action.tsx", "../src/modal-actions/modal-actions.tsx", "../src/modal-body/modal-body.tsx", "../src/modal-close/modal-close.tsx", "../src/modal-description/modal-description.tsx", "../src/modal-footer/modal-footer.tsx", "../src/modal-footer-note/modal-footer-note.tsx", "../src/modal-header/modal-header.tsx", "../src/modal-panel/modal-panel.tsx", "../src/modal-title/modal-title.tsx", "../src/modal-trigger/modal-trigger.tsx"],
|
|
4
|
-
"sourcesContent": ["/**\n * @author WMXPY\n * @package Modal\n * @namespace Modal\n * @description Modal\n */\n\nimport { OverlayOpen, useOverlayState } from \"@gridui/overlay\";\nimport { type Space } from \"@gridui/style-utils/responsive\";\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalSpace = Space;\n\nexport type ModalProps = ComponentPropsWithRef<typeof Dialog.Root>;\n\nexport const Modal: FC<ModalProps> = (props: ModalProps) => {\n const state = useOverlayState(props);\n return (<OverlayOpen.Provider\n value={state.open}\n >\n <Dialog.Root\n {...props}\n {...state}\n />\n </OverlayOpen.Provider>);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalAction\n * @description Modal Action\n */\n\nimport { Button, type ButtonProps } from \"@gridui/button\";\nimport { cn } from \"@gridui/style-utils\";\nimport type { FC } from \"react\";\n\nexport type ModalActionProps = ButtonProps;\n\nexport const ModalAction: FC<ModalActionProps> = (props: ModalActionProps) => {\n const { className, ...restProps } = props;\n return (<Button\n {...restProps}\n className={cn(\"gridui-modal-action\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalActions\n * @description Modal Actions\n */\n\nimport { ButtonGroup } from \"@gridui/button\";\nimport { cn } from \"@gridui/style-utils\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalActionsProps = ComponentPropsWithRef<\"div\">;\n\nexport const ModalActions: FC<ModalActionsProps> = (props: ModalActionsProps) => {\n const { className, ...restProps } = props;\n return (<ButtonGroup\n layout=\"cells\"\n {...restProps}\n className={cn(\"gridui-modal-actions\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalBody\n * @description Modal Body\n */\n\nimport { useInteractionOutline, useScrollbars } from \"@gridui/overlay\";\nimport { cn } from \"@gridui/style-utils\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalBodyProps = ComponentPropsWithRef<\"div\">;\n\nexport const ModalBody: FC<ModalBodyProps> = (props: ModalBodyProps) => {\n const { ref: forwardedRef, className, tabIndex = 0, ...restProps } = props;\n const scrollbarRef = useScrollbars({ ref: forwardedRef });\n const ref = useInteractionOutline({ ref: scrollbarRef });\n return (<div\n {...restProps}\n ref={ref}\n tabIndex={tabIndex}\n className={cn(\"gridui-u-modal--min-h-0 gridui-u-modal--min-w-0 gridui-u-modal--overflow-auto gridui-u-modal--overscroll-contain gridui-u-modal--p-gridui-24 gridui-u-modal--wrap-anywhere\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalClose\n * @description Modal Close\n */\n\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalCloseProps = ComponentPropsWithRef<typeof Dialog.Close>;\n\nexport const ModalClose: FC<ModalCloseProps> = (props: ModalCloseProps) => {\n return (<Dialog.Close\n {...props}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalDescription\n * @description Modal Description\n */\n\nimport { cn } from \"@gridui/style-utils\";\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalDescriptionProps = ComponentPropsWithRef<typeof Dialog.Description>;\n\nexport const ModalDescription: FC<ModalDescriptionProps> = (props: ModalDescriptionProps) => {\n const {\n className,\n ...restProps\n } = props;\n return (<Dialog.Description\n {...restProps}\n className={cn(\"gridui-u-modal--mt-gridui-8 gridui-u-modal--mb-0 gridui-u-modal--type-supporting gridui-u-modal--text-muted\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalFooter\n * @description Modal Footer\n */\n\nimport type { ModalSectionProps } from \"../shared/types\";\nimport { useInteractionOutline, useScrollbars } from \"@gridui/overlay\";\nimport { cn } from \"@gridui/style-utils\";\nimport { spacingVariables } from \"@gridui/style-utils/responsive\";\nimport type { FC } from \"react\";\n\nexport type ModalFooterProps = ModalSectionProps;\n\nexport const ModalFooter: FC<ModalFooterProps> = (props: ModalFooterProps) => {\n const {\n ref: forwardedRef,\n paddingBlock = 24,\n style,\n className,\n ...restProps\n } = props;\n const outlineRef = useInteractionOutline({ ref: forwardedRef });\n const ref = useScrollbars({ ref: outlineRef });\n return (<div\n {...restProps}\n ref={ref}\n style={{\n ...spacingVariables(\"modal-space\", paddingBlock),\n ...style,\n }}\n className={cn(\"gridui-modal-section gridui-modal-footer gridui-u-modal--max-h-[40dvh] gridui-u-modal--overflow-y-auto gridui-u-modal--shrink-0\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalFooterNote\n * @description Modal Footer Note\n */\n\nimport { cn } from \"@gridui/style-utils\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalFooterNoteProps = ComponentPropsWithRef<\"div\">;\n\nexport const ModalFooterNote: FC<ModalFooterNoteProps> = (props: ModalFooterNoteProps) => {\n const { className, ...restProps } = props;\n return (<div\n {...restProps}\n className={cn(\"gridui-u-modal--min-w-0 gridui-u-modal--px-gridui-24 gridui-u-modal--py-(--gridui-modal-padding) gridui-u-modal--type-supporting gridui-u-modal--text-muted gridui-u-modal--wrap-anywhere\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalHeader\n * @description Modal Header\n */\n\nimport type { ModalSectionProps } from \"../shared/types\";\nimport { Button } from \"@gridui/button\";\nimport { useInteractionOutline, useScrollbars } from \"@gridui/overlay\";\nimport { cn } from \"@gridui/style-utils\";\nimport { spacingVariables } from \"@gridui/style-utils/responsive\";\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport { X } from \"lucide-react\";\nimport type { FC } from \"react\";\n\nexport type ModalHeaderProps = ModalSectionProps & {\n readonly closeLabel: string;\n};\n\nexport const ModalHeader: FC<ModalHeaderProps> = (props: ModalHeaderProps) => {\n const {\n closeLabel,\n children,\n paddingBlock = 24,\n style,\n className,\n ...restProps\n } = props;\n const scrollbarRef = useScrollbars<HTMLDivElement>();\n const scrollRef = useInteractionOutline({ ref: scrollbarRef });\n return (<div\n {...restProps}\n style={{\n ...spacingVariables(\"modal-space\", paddingBlock),\n ...style,\n }}\n className={cn(\"gridui-modal-section gridui-modal-header gridui-u-modal--relative gridui-u-modal--z-(--gridui-z-content) gridui-u-modal--overflow-visible gridui-u-modal--shrink-0 gridui-u-modal--grid gridui-u-modal--grid-cols-[minmax(0,1fr)_auto]\", className)}\n >\n <div\n ref={scrollRef}\n className=\"gridui-u-modal--max-h-[40dvh] gridui-u-modal--min-w-0 gridui-u-modal--overflow-y-auto gridui-u-modal--px-gridui-24 gridui-u-modal--py-(--gridui-modal-padding) gridui-u-modal--wrap-anywhere\"\n >\n {children}\n </div>\n <Dialog.Close\n asChild\n >\n <Button\n aria-label={closeLabel}\n variant=\"quiet\"\n className=\"gridui-modal-close gridui-u-modal--self-stretch gridui-u-modal--w-gridui-64 gridui-u-modal--min-h-11 gridui-u-modal--rounded-none gridui-u-modal--border-border gridui-u-modal--p-0\"\n >\n <X\n aria-hidden=\"true\"\n />\n </Button>\n </Dialog.Close>\n </div>);\n};\n", "import { useMotionStyle } from \"@gridui/motion/policy\";\n/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalPanel\n * @description Modal Panel\n */\n\nimport { interactionLayerProps, overlayBackdropStyles, overlaySurfaceStyles, RetainedLayer } from \"@gridui/overlay\";\nimport { cn } from \"@gridui/style-utils\";\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalPanelProps = ComponentPropsWithRef<typeof Dialog.Content>;\n\nexport const ModalPanel: FC<ModalPanelProps> = (props: ModalPanelProps) => {\n const motionStyle = useMotionStyle();\n const {\n className,\n forceMount,\n ...restProps\n } = props;\n const content = (<Dialog.Content\n {...interactionLayerProps}\n {...restProps}\n forceMount={forceMount}\n className={cn(overlaySurfaceStyles({ kind: \"dialog\" }), \"gridui-modal-panel gridui-u-modal--fixed gridui-u-modal--z-(--gridui-z-dialog) gridui-u-modal--left-1/2 gridui-u-modal--top-1/2 gridui-u-modal---translate-x-1/2 gridui-u-modal---translate-y-1/2 gridui-u-modal--flex gridui-u-modal--flex-col gridui-u-modal--w-[min(calc(100%-32px),var(--gridui-modal-width,37rem))] gridui-u-modal--max-h-[calc(100dvh-32px)] gridui-u-modal--min-w-0 gridui-u-modal--type-body\", className)}\n style={{ ...(restProps.style), ...motionStyle }}\n />);\n return (<>\n <Dialog.Portal>\n <Dialog.Overlay\n className={cn(overlayBackdropStyles(), \"gridui-modal-overlay gridui-u-modal--fixed gridui-u-modal--inset-0 gridui-u-modal--z-(--gridui-z-dialog-backdrop) gridui-u-modal--bg-[light-dark(rgb(0_0_0/25%),rgb(0_0_0/60%))]\")}\n style={motionStyle}\n />\n </Dialog.Portal>\n <Dialog.Portal\n forceMount={forceMount}\n >\n {forceMount ? (<RetainedLayer>\n {content}\n </RetainedLayer>) : content}\n </Dialog.Portal>\n </>);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalTitle\n * @description Modal Title\n */\n\nimport { cn } from \"@gridui/style-utils\";\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalTitleProps = ComponentPropsWithRef<typeof Dialog.Title>;\n\nexport const ModalTitle: FC<ModalTitleProps> = (props: ModalTitleProps) => {\n const { className, ...restProps } = props;\n return (<Dialog.Title\n {...restProps}\n className={cn(\"gridui-u-modal--m-0 gridui-u-modal--type-heading\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalTrigger\n * @description Modal Trigger\n */\n\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalTriggerProps = ComponentPropsWithRef<typeof Dialog.Trigger>;\n\nexport const ModalTrigger: FC<ModalTriggerProps> = (props: ModalTriggerProps) => {\n return (<Dialog.Trigger\n {...props}\n />);\n};\n"],
|
|
5
|
-
"mappings": ";AAOA,SAAS,aAAa,uBAAuB;AAC7C,OAA2B;AAC3B,YAAY,YAAY;AAYhB;AALD,IAAM,QAAwB,CAAC,UAAsB;AACxD,QAAM,QAAQ,gBAAgB,KAAK;AACnC,SAAQ;AAAA,IAAC,YAAY;AAAA,IAAZ;AAAA,MACL,OAAO,MAAM;AAAA,MAEb;AAAA,QAAQ;AAAA,QAAP;AAAA,UACI,GAAG;AAAA,UACH,GAAG;AAAA;AAAA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CAAC,UAA4B;AAC1E,QAAM;AAAA,IACF;AAAA,IACA;AAAA,IACA,eAAe;AAAA,IACf;AAAA,IACA;AAAA,IACA,GAAG;AAAA,EACP,IAAI;AACJ,QAAM,eAAeJ,eAA8B;AACnD,QAAM,YAAYD,uBAAsB,EAAE,KAAK,aAAa,CAAC;AAC7D,SAAQ;AAAA,IAAC;AAAA;AAAA,MACJ,GAAG;AAAA,MACJ,OAAO;AAAA,QACH,GAAGG,kBAAiB,eAAe,YAAY;AAAA,QAC/C,GAAG;AAAA,MACP;AAAA,MACA,WAAWD,IAAG,0OAA0O,SAAS;AAAA,MAEjQ;AAAA,wBAAAG;AAAA,UAAC;AAAA;AAAA,YACG,KAAK;AAAA,YACL,WAAU;AAAA,YAET;AAAA;AAAA,QACL;AAAA,QACA,gBAAAA;AAAA,UAAQ;AAAA,UAAP;AAAA,YACG,SAAO;AAAA,YAEP,0BAAAA;AAAA,cAACN;AAAA,cAAA;AAAA,gBACG,cAAY;AAAA,gBACZ,SAAQ;AAAA,gBACR,WAAU;AAAA,gBAEV,0BAAAM;AAAA,kBAAC;AAAA;AAAA,oBACG,eAAY;AAAA;AAAA,gBAChB;AAAA;AAAA,YACJ;AAAA;AAAA,QACJ;AAAA;AAAA;AAAA,EACJ;AACJ;;;
|
|
4
|
+
"sourcesContent": ["/**\n * @author WMXPY\n * @package Modal\n * @namespace Modal\n * @description Modal\n */\n\nimport { OverlayOpen, useOverlayState } from \"@gridui/overlay\";\nimport { type Space } from \"@gridui/style-utils/responsive\";\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalSpace = Space;\n\nexport type ModalProps = ComponentPropsWithRef<typeof Dialog.Root>;\n\nexport const Modal: FC<ModalProps> = (props: ModalProps) => {\n const state = useOverlayState(props);\n return (<OverlayOpen.Provider\n value={state.open}\n >\n <Dialog.Root\n {...props}\n {...state}\n />\n </OverlayOpen.Provider>);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalAction\n * @description Modal Action\n */\n\nimport { Button, type ButtonProps } from \"@gridui/button\";\nimport { cn } from \"@gridui/style-utils\";\nimport type { FC } from \"react\";\n\nexport type ModalActionProps = ButtonProps;\n\nexport const ModalAction: FC<ModalActionProps> = (props: ModalActionProps) => {\n const { className, ...restProps } = props;\n return (<Button\n {...restProps}\n className={cn(\"gridui-modal-action\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalActions\n * @description Modal Actions\n */\n\nimport { ButtonGroup } from \"@gridui/button\";\nimport { cn } from \"@gridui/style-utils\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalActionsProps = ComponentPropsWithRef<\"div\">;\n\nexport const ModalActions: FC<ModalActionsProps> = (props: ModalActionsProps) => {\n const { className, ...restProps } = props;\n return (<ButtonGroup\n layout=\"cells\"\n {...restProps}\n className={cn(\"gridui-modal-actions\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalBody\n * @description Modal Body\n */\n\nimport { useInteractionOutline, useScrollbars } from \"@gridui/overlay\";\nimport { cn } from \"@gridui/style-utils\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalBodyProps = ComponentPropsWithRef<\"div\">;\n\nexport const ModalBody: FC<ModalBodyProps> = (props: ModalBodyProps) => {\n const { ref: forwardedRef, className, tabIndex = 0, ...restProps } = props;\n const scrollbarRef = useScrollbars({ ref: forwardedRef });\n const ref = useInteractionOutline({ ref: scrollbarRef });\n return (<div\n {...restProps}\n ref={ref}\n tabIndex={tabIndex}\n className={cn(\"gridui-u-modal--min-h-0 gridui-u-modal--min-w-0 gridui-u-modal--overflow-auto gridui-u-modal--overscroll-contain gridui-u-modal--p-gridui-24 gridui-u-modal--wrap-anywhere\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalClose\n * @description Modal Close\n */\n\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalCloseProps = ComponentPropsWithRef<typeof Dialog.Close>;\n\nexport const ModalClose: FC<ModalCloseProps> = (props: ModalCloseProps) => {\n return (<Dialog.Close\n {...props}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalDescription\n * @description Modal Description\n */\n\nimport { cn } from \"@gridui/style-utils\";\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalDescriptionProps = ComponentPropsWithRef<typeof Dialog.Description>;\n\nexport const ModalDescription: FC<ModalDescriptionProps> = (props: ModalDescriptionProps) => {\n const {\n className,\n ...restProps\n } = props;\n return (<Dialog.Description\n {...restProps}\n className={cn(\"gridui-u-modal--mt-gridui-8 gridui-u-modal--mb-0 gridui-u-modal--type-supporting gridui-u-modal--text-muted\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalFooter\n * @description Modal Footer\n */\n\nimport type { ModalSectionProps } from \"../shared/types\";\nimport { useInteractionOutline, useScrollbars } from \"@gridui/overlay\";\nimport { cn } from \"@gridui/style-utils\";\nimport { spacingVariables } from \"@gridui/style-utils/responsive\";\nimport type { FC } from \"react\";\n\nexport type ModalFooterProps = ModalSectionProps;\n\nexport const ModalFooter: FC<ModalFooterProps> = (props: ModalFooterProps) => {\n const {\n ref: forwardedRef,\n paddingBlock = 24,\n style,\n className,\n ...restProps\n } = props;\n const outlineRef = useInteractionOutline({ ref: forwardedRef });\n const ref = useScrollbars({ ref: outlineRef });\n return (<div\n {...restProps}\n ref={ref}\n style={{\n ...spacingVariables(\"modal-space\", paddingBlock),\n ...style,\n }}\n className={cn(\"gridui-modal-section gridui-modal-footer gridui-u-modal--max-h-[40dvh] gridui-u-modal--overflow-y-auto gridui-u-modal--shrink-0\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalFooterNote\n * @description Modal Footer Note\n */\n\nimport { cn } from \"@gridui/style-utils\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalFooterNoteProps = ComponentPropsWithRef<\"div\">;\n\nexport const ModalFooterNote: FC<ModalFooterNoteProps> = (props: ModalFooterNoteProps) => {\n const { className, ...restProps } = props;\n return (<div\n {...restProps}\n className={cn(\"gridui-u-modal--min-w-0 gridui-u-modal--px-gridui-24 gridui-u-modal--py-(--gridui-modal-padding) gridui-u-modal--type-supporting gridui-u-modal--text-muted gridui-u-modal--wrap-anywhere\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalHeader\n * @description Modal Header\n */\n\nimport type { ModalSectionProps } from \"../shared/types\";\nimport { Button } from \"@gridui/button\";\nimport { useInteractionOutline, useScrollbars } from \"@gridui/overlay\";\nimport { cn } from \"@gridui/style-utils\";\nimport { spacingVariables } from \"@gridui/style-utils/responsive\";\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport { X } from \"lucide-react\";\nimport type { FC } from \"react\";\n\nexport type ModalHeaderProps = ModalSectionProps & {\n readonly closeLabel: string;\n};\n\nexport const ModalHeader: FC<ModalHeaderProps> = (props: ModalHeaderProps) => {\n const {\n closeLabel,\n children,\n paddingBlock = 24,\n style,\n className,\n ...restProps\n } = props;\n const scrollbarRef = useScrollbars<HTMLDivElement>();\n const scrollRef = useInteractionOutline({ ref: scrollbarRef });\n return (<div\n {...restProps}\n style={{\n ...spacingVariables(\"modal-space\", paddingBlock),\n ...style,\n }}\n className={cn(\"gridui-modal-section gridui-modal-header gridui-u-modal--relative gridui-u-modal--z-(--gridui-z-content) gridui-u-modal--overflow-visible gridui-u-modal--shrink-0 gridui-u-modal--grid gridui-u-modal--grid-cols-[minmax(0,1fr)_auto]\", className)}\n >\n <div\n ref={scrollRef}\n className=\"gridui-u-modal--max-h-[40dvh] gridui-u-modal--min-w-0 gridui-u-modal--overflow-y-auto gridui-u-modal--px-gridui-24 gridui-u-modal--py-(--gridui-modal-padding) gridui-u-modal--wrap-anywhere\"\n >\n {children}\n </div>\n <Dialog.Close\n asChild\n >\n <Button\n aria-label={closeLabel}\n variant=\"quiet\"\n className=\"gridui-modal-close gridui-u-modal--self-stretch gridui-u-modal--w-gridui-64 gridui-u-modal--min-h-11 gridui-u-modal--rounded-none gridui-u-modal--border-border gridui-u-modal--p-0\"\n >\n <X\n aria-hidden=\"true\"\n />\n </Button>\n </Dialog.Close>\n </div>);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalPanel\n * @description Modal Panel\n */\n\nimport { useMotionStyle } from \"@gridui/motion/policy\";\n/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalPanel\n * @description Modal Panel\n */\n\nimport { interactionLayerProps, overlayBackdropStyles, overlaySurfaceStyles, RetainedLayer } from \"@gridui/overlay\";\nimport { cn } from \"@gridui/style-utils\";\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalPanelProps = ComponentPropsWithRef<typeof Dialog.Content> & {\n readonly container?: ComponentPropsWithRef<typeof Dialog.Portal>[\"container\"];\n};\n\nexport const ModalPanel: FC<ModalPanelProps> = (props: ModalPanelProps) => {\n const motionStyle = useMotionStyle();\n const {\n className,\n forceMount,\n container,\n ...restProps\n } = props;\n const content = (<Dialog.Content\n {...interactionLayerProps}\n {...restProps}\n forceMount={forceMount}\n className={cn(overlaySurfaceStyles({ kind: \"dialog\" }), \"gridui-modal-panel gridui-u-modal--fixed gridui-u-modal--z-(--gridui-z-dialog) gridui-u-modal--left-1/2 gridui-u-modal--top-1/2 gridui-u-modal---translate-x-1/2 gridui-u-modal---translate-y-1/2 gridui-u-modal--flex gridui-u-modal--flex-col gridui-u-modal--w-[min(calc(100%-32px),var(--gridui-modal-width,37rem))] gridui-u-modal--max-h-[calc(100dvh-32px)] gridui-u-modal--min-w-0 gridui-u-modal--type-body\", className)}\n style={{ ...(restProps.style), ...motionStyle }}\n />);\n return (<>\n <Dialog.Portal container={container}>\n <Dialog.Overlay\n className={cn(overlayBackdropStyles(), \"gridui-modal-overlay gridui-u-modal--fixed gridui-u-modal--inset-0 gridui-u-modal--z-(--gridui-z-dialog-backdrop)\")}\n style={motionStyle}\n />\n </Dialog.Portal>\n <Dialog.Portal\n container={container}\n forceMount={forceMount}\n >\n {forceMount ? (<RetainedLayer>\n {content}\n </RetainedLayer>) : content}\n </Dialog.Portal>\n </>);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalTitle\n * @description Modal Title\n */\n\nimport { cn } from \"@gridui/style-utils\";\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalTitleProps = ComponentPropsWithRef<typeof Dialog.Title>;\n\nexport const ModalTitle: FC<ModalTitleProps> = (props: ModalTitleProps) => {\n const { className, ...restProps } = props;\n return (<Dialog.Title\n {...restProps}\n className={cn(\"gridui-u-modal--m-0 gridui-u-modal--type-heading\", className)}\n />);\n};\n", "/**\n * @author WMXPY\n * @package Modal\n * @namespace ModalTrigger\n * @description Modal Trigger\n */\n\nimport * as Dialog from \"@radix-ui/react-dialog\";\nimport type { ComponentPropsWithRef, FC } from \"react\";\n\nexport type ModalTriggerProps = ComponentPropsWithRef<typeof Dialog.Trigger>;\n\nexport const ModalTrigger: FC<ModalTriggerProps> = (props: ModalTriggerProps) => {\n return (<Dialog.Trigger\n {...props}\n />);\n};\n"],
|
|
5
|
+
"mappings": ";AAOA,SAAS,aAAa,uBAAuB;AAC7C,OAA2B;AAC3B,YAAY,YAAY;AAYhB;AALD,IAAM,QAAwB,CAAC,UAAsB;AACxD,QAAM,QAAQ,gBAAgB,KAAK;AACnC,SAAQ;AAAA,IAAC,YAAY;AAAA,IAAZ;AAAA,MACL,OAAO,MAAM;AAAA,MAEb;AAAA,QAAQ;AAAA,QAAP;AAAA,UACI,GAAG;AAAA,UACH,GAAG;AAAA;AAAA,MACR;AAAA;AAAA,EACJ;AACJ;;;ACnBA,SAAS,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,EAAE,GAAI,UAAU,OAAQ,GAAG,YAAY;AAAA;AAAA,EAClD;AACA,SAAQ,gBAAAG,MAAA,YACJ;AAAA,oBAAAD,MAAQ,gBAAP,EAAc,WACX,0BAAAA;AAAA,MAAQ;AAAA,MAAP;AAAA,QACG,WAAWF,IAAG,sBAAsB,GAAG,mHAAmH;AAAA,QAClK,OAAO;AAAA;AAAA,IACH,GACJ;AAAA,IACA,gBAAAE;AAAA,MAAQ;AAAA,MAAP;AAAA,QACG;AAAA,QACA;AAAA,QAEC,uBAAc,gBAAAA,MAAC,iBACX,mBACL,IAAoB;AAAA;AAAA,IACxB;AAAA,KACJ;AACJ;;;AChDA,SAAS,MAAAE,WAAU;AACnB,YAAYC,aAAY;AAOZ,gBAAAC,aAAA;AAFL,IAAM,aAAkC,CAAC,UAA2B;AACvE,QAAM,EAAE,WAAW,GAAG,UAAU,IAAI;AACpC,SAAQ,gBAAAA;AAAA,IAAQ;AAAA,IAAP;AAAA,MACJ,GAAG;AAAA,MACJ,WAAWF,IAAG,oDAAoD,SAAS;AAAA;AAAA,EAC/E;AACJ;;;ACZA,YAAYG,aAAY;AAMZ,gBAAAC,aAAA;AADL,IAAM,eAAsC,CAAC,UAA6B;AAC7E,SAAQ,gBAAAA;AAAA,IAAQ;AAAA,IAAP;AAAA,MACJ,GAAG;AAAA;AAAA,EACR;AACJ;",
|
|
6
6
|
"names": ["jsx", "cn", "jsx", "cn", "jsx", "Dialog", "jsx", "cn", "Dialog", "jsx", "useInteractionOutline", "useScrollbars", "cn", "jsx", "cn", "jsx", "Button", "useInteractionOutline", "useScrollbars", "cn", "spacingVariables", "Dialog", "jsx", "cn", "Dialog", "jsx", "jsxs", "cn", "Dialog", "jsx", "Dialog", "jsx"]
|
|
7
7
|
}
|
|
@@ -1,4 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @author WMXPY
|
|
3
|
+
* @package Modal
|
|
4
|
+
* @namespace ModalPanel
|
|
5
|
+
* @description Modal Panel
|
|
6
|
+
*/
|
|
1
7
|
import * as Dialog from "@radix-ui/react-dialog";
|
|
2
8
|
import type { ComponentPropsWithRef, FC } from "react";
|
|
3
|
-
export type ModalPanelProps = ComponentPropsWithRef<typeof Dialog.Content
|
|
9
|
+
export type ModalPanelProps = ComponentPropsWithRef<typeof Dialog.Content> & {
|
|
10
|
+
readonly container?: ComponentPropsWithRef<typeof Dialog.Portal>["container"];
|
|
11
|
+
};
|
|
4
12
|
export declare const ModalPanel: FC<ModalPanelProps>;
|
package/dist/styled.js
ADDED
package/dist/styles.css
CHANGED
|
@@ -1,3 +1,597 @@
|
|
|
1
|
+
/*! tailwindcss v4.3.5 | MIT License | https://tailwindcss.com */
|
|
2
|
+
@layer properties;
|
|
3
|
+
@layer theme, base, components, utilities;
|
|
4
|
+
@layer theme {
|
|
5
|
+
:root, :host {
|
|
6
|
+
--spacing: 0.25rem;
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
@layer utilities {
|
|
10
|
+
.gridui-u-button--pointer-events-none {
|
|
11
|
+
pointer-events: none;
|
|
12
|
+
}
|
|
13
|
+
.gridui-u-button--inline-flex {
|
|
14
|
+
display: inline-flex;
|
|
15
|
+
}
|
|
16
|
+
.gridui-u-button--h-full {
|
|
17
|
+
height: 100%;
|
|
18
|
+
}
|
|
19
|
+
.gridui-u-button--h-gridui-control {
|
|
20
|
+
height: var(--gridui-control-min-height);
|
|
21
|
+
}
|
|
22
|
+
.gridui-u-button--min-h-18 {
|
|
23
|
+
min-height: calc(var(--spacing) * 18);
|
|
24
|
+
}
|
|
25
|
+
.gridui-u-button--min-h-gridui-control {
|
|
26
|
+
min-height: var(--gridui-control-min-height);
|
|
27
|
+
}
|
|
28
|
+
.gridui-u-button--min-h-gridui-control-large {
|
|
29
|
+
min-height: var(--gridui-control-min-height-large);
|
|
30
|
+
}
|
|
31
|
+
.gridui-u-button--min-h-gridui-control-small {
|
|
32
|
+
min-height: var(--gridui-control-min-height-small);
|
|
33
|
+
}
|
|
34
|
+
.gridui-u-button--w-fit {
|
|
35
|
+
width: fit-content;
|
|
36
|
+
}
|
|
37
|
+
.gridui-u-button--w-full {
|
|
38
|
+
width: 100%;
|
|
39
|
+
}
|
|
40
|
+
.gridui-u-button--w-gridui-64 {
|
|
41
|
+
width: var(--gridui-space-64);
|
|
42
|
+
}
|
|
43
|
+
.gridui-u-button--w-gridui-control {
|
|
44
|
+
width: var(--gridui-control-min-height);
|
|
45
|
+
}
|
|
46
|
+
.gridui-u-button--w-gridui-control-large {
|
|
47
|
+
width: var(--gridui-control-min-height-large);
|
|
48
|
+
}
|
|
49
|
+
.gridui-u-button--w-gridui-control-small {
|
|
50
|
+
width: var(--gridui-control-min-height-small);
|
|
51
|
+
}
|
|
52
|
+
.gridui-u-button--max-w-full {
|
|
53
|
+
max-width: 100%;
|
|
54
|
+
}
|
|
55
|
+
.gridui-u-button--min-w-0 {
|
|
56
|
+
min-width: 0px;
|
|
57
|
+
}
|
|
58
|
+
.gridui-u-button--min-w-gridui-24 {
|
|
59
|
+
min-width: var(--gridui-space-24);
|
|
60
|
+
}
|
|
61
|
+
.gridui-u-button--flex-1 {
|
|
62
|
+
flex: 1;
|
|
63
|
+
}
|
|
64
|
+
.gridui-u-button--shrink-0 {
|
|
65
|
+
flex-shrink: 0;
|
|
66
|
+
}
|
|
67
|
+
.gridui-u-button--cursor-pointer {
|
|
68
|
+
cursor: pointer;
|
|
69
|
+
}
|
|
70
|
+
.gridui-u-button--flex-col {
|
|
71
|
+
flex-direction: column;
|
|
72
|
+
}
|
|
73
|
+
.gridui-u-button--items-center {
|
|
74
|
+
align-items: center;
|
|
75
|
+
}
|
|
76
|
+
.gridui-u-button--items-stretch {
|
|
77
|
+
align-items: stretch;
|
|
78
|
+
}
|
|
79
|
+
.gridui-u-button--justify-between {
|
|
80
|
+
justify-content: space-between;
|
|
81
|
+
}
|
|
82
|
+
.gridui-u-button--justify-center {
|
|
83
|
+
justify-content: center;
|
|
84
|
+
}
|
|
85
|
+
.gridui-u-button--justify-start {
|
|
86
|
+
justify-content: flex-start;
|
|
87
|
+
}
|
|
88
|
+
.gridui-u-button--gap-0 {
|
|
89
|
+
gap: 0px;
|
|
90
|
+
}
|
|
91
|
+
.gridui-u-button--gap-gridui-8 {
|
|
92
|
+
gap: var(--gridui-space-8);
|
|
93
|
+
}
|
|
94
|
+
.gridui-u-button--gap-gridui-32 {
|
|
95
|
+
gap: var(--gridui-space-32);
|
|
96
|
+
}
|
|
97
|
+
.gridui-u-button--self-stretch {
|
|
98
|
+
align-self: stretch;
|
|
99
|
+
}
|
|
100
|
+
.gridui-u-button--rounded-control {
|
|
101
|
+
border-radius: var(--gridui-control-radius);
|
|
102
|
+
}
|
|
103
|
+
.gridui-u-button--rounded-none {
|
|
104
|
+
border-radius: 0;
|
|
105
|
+
}
|
|
106
|
+
.gridui-u-button--border-0 {
|
|
107
|
+
border-style: var(--tw-border-style);
|
|
108
|
+
border-width: 0px;
|
|
109
|
+
}
|
|
110
|
+
.gridui-u-button--border-b {
|
|
111
|
+
border-bottom-style: var(--tw-border-style);
|
|
112
|
+
border-bottom-width: 1px;
|
|
113
|
+
}
|
|
114
|
+
.gridui-u-button--border-accent-background {
|
|
115
|
+
border-color: var(--gridui-accent-background);
|
|
116
|
+
}
|
|
117
|
+
.gridui-u-button--border-control-border {
|
|
118
|
+
border-color: var(--gridui-control-border);
|
|
119
|
+
}
|
|
120
|
+
.gridui-u-button--border-foreground {
|
|
121
|
+
border-color: var(--gridui-foreground);
|
|
122
|
+
}
|
|
123
|
+
.gridui-u-button--bg-accent-background {
|
|
124
|
+
background-color: var(--gridui-accent-background);
|
|
125
|
+
}
|
|
126
|
+
.gridui-u-button--bg-selection-background {
|
|
127
|
+
background-color: var(--gridui-selection-background);
|
|
128
|
+
}
|
|
129
|
+
.gridui-u-button--bg-transparent {
|
|
130
|
+
background-color: transparent;
|
|
131
|
+
}
|
|
132
|
+
.gridui-u-button--p-0 {
|
|
133
|
+
padding: 0px;
|
|
134
|
+
}
|
|
135
|
+
.gridui-u-button--px-0 {
|
|
136
|
+
padding-inline: 0px;
|
|
137
|
+
}
|
|
138
|
+
.gridui-u-button--px-gridui-8 {
|
|
139
|
+
padding-inline: var(--gridui-space-8);
|
|
140
|
+
}
|
|
141
|
+
.gridui-u-button--px-gridui-16 {
|
|
142
|
+
padding-inline: var(--gridui-space-16);
|
|
143
|
+
}
|
|
144
|
+
.gridui-u-button--px-gridui-24 {
|
|
145
|
+
padding-inline: var(--gridui-space-24);
|
|
146
|
+
}
|
|
147
|
+
.gridui-u-button--py-gridui-4 {
|
|
148
|
+
padding-block: var(--gridui-space-4);
|
|
149
|
+
}
|
|
150
|
+
.gridui-u-button--py-gridui-8 {
|
|
151
|
+
padding-block: var(--gridui-space-8);
|
|
152
|
+
}
|
|
153
|
+
.gridui-u-button--py-gridui-16 {
|
|
154
|
+
padding-block: var(--gridui-space-16);
|
|
155
|
+
}
|
|
156
|
+
.gridui-u-button--text-center {
|
|
157
|
+
text-align: center;
|
|
158
|
+
}
|
|
159
|
+
.gridui-u-button--text-left {
|
|
160
|
+
text-align: left;
|
|
161
|
+
}
|
|
162
|
+
.gridui-u-button--text-start {
|
|
163
|
+
text-align: start;
|
|
164
|
+
}
|
|
165
|
+
.gridui-u-button--type-supporting {
|
|
166
|
+
font: var(--gridui-type-supporting);
|
|
167
|
+
font-family: var(--gridui-font-body);
|
|
168
|
+
letter-spacing: normal;
|
|
169
|
+
}
|
|
170
|
+
.gridui-u-button--type-ui {
|
|
171
|
+
font: var(--gridui-type-ui);
|
|
172
|
+
font-family: var(--gridui-font-body);
|
|
173
|
+
letter-spacing: normal;
|
|
174
|
+
}
|
|
175
|
+
.gridui-u-button--wrap-anywhere {
|
|
176
|
+
overflow-wrap: anywhere;
|
|
177
|
+
}
|
|
178
|
+
.gridui-u-button--text-accent-foreground {
|
|
179
|
+
color: var(--gridui-accent-foreground);
|
|
180
|
+
}
|
|
181
|
+
.gridui-u-button--text-foreground {
|
|
182
|
+
color: var(--gridui-foreground);
|
|
183
|
+
}
|
|
184
|
+
.gridui-u-button--no-underline {
|
|
185
|
+
text-decoration-line: none;
|
|
186
|
+
}
|
|
187
|
+
.gridui-u-button--\[transition-property\:var\(--gridui-motion-transition\,color\,background-color\,border-color\,text-decoration-color\,fill\,stroke\)\] {
|
|
188
|
+
transition-property: var(--gridui-motion-transition,color,background-color,border-color,text-decoration-color,fill,stroke);
|
|
189
|
+
}
|
|
190
|
+
.gridui-u-button--duration-\[calc\(var\(--gridui-motion-duration-quick\)\*var\(--gridui-motion-factor\,1\)\)\] {
|
|
191
|
+
--tw-duration: calc(var(--gridui-motion-duration-quick) * var(--gridui-motion-factor,1));
|
|
192
|
+
transition-duration: calc(var(--gridui-motion-duration-quick) * var(--gridui-motion-factor,1));
|
|
193
|
+
}
|
|
194
|
+
.gridui-u-button--ease-\(--gridui-motion-ease-out\) {
|
|
195
|
+
--tw-ease: var(--gridui-motion-ease-out);
|
|
196
|
+
transition-timing-function: var(--gridui-motion-ease-out);
|
|
197
|
+
}
|
|
198
|
+
.gridui-u-button--\[--gridui-button-icon-size\:var\(--gridui-icon-size\)\] {
|
|
199
|
+
--gridui-button-icon-size: var(--gridui-icon-size);
|
|
200
|
+
}
|
|
201
|
+
.gridui-u-button--\[--gridui-button-icon-size\:var\(--gridui-icon-size-large\)\] {
|
|
202
|
+
--gridui-button-icon-size: var(--gridui-icon-size-large);
|
|
203
|
+
}
|
|
204
|
+
.gridui-u-button--\[--gridui-button-icon-size\:var\(--gridui-space-32\)\] {
|
|
205
|
+
--gridui-button-icon-size: var(--gridui-space-32);
|
|
206
|
+
}
|
|
207
|
+
.gridui-u-button--\[--gridui-button-icon-size\:var\(--gridui-space-48\)\] {
|
|
208
|
+
--gridui-button-icon-size: var(--gridui-space-48);
|
|
209
|
+
}
|
|
210
|
+
@media (hover: hover) {
|
|
211
|
+
.gridui-u-button--not-disabled\:not-aria-disabled\:not-data-disabled\:hover\:bg-accent-hover:not(:disabled):not([aria-disabled="true"]):not([data-disabled]):hover {
|
|
212
|
+
background-color: var(--gridui-accent-hover);
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
.gridui-u-button--not-disabled\:not-aria-disabled\:not-data-disabled\:active\:bg-accent-pressed:not(:disabled):not([aria-disabled="true"]):not([data-disabled]):active {
|
|
216
|
+
background-color: var(--gridui-accent-pressed);
|
|
217
|
+
}
|
|
218
|
+
.gridui-u-button--not-disabled\:not-aria-disabled\:not-data-disabled\:active\:bg-surface-pressed:not(:disabled):not([aria-disabled="true"]):not([data-disabled]):active {
|
|
219
|
+
background-color: var(--gridui-surface-pressed);
|
|
220
|
+
}
|
|
221
|
+
.gridui-u-button--disabled\:cursor-not-allowed:disabled {
|
|
222
|
+
cursor: not-allowed;
|
|
223
|
+
}
|
|
224
|
+
.gridui-u-button--aria-disabled\:cursor-not-allowed[aria-disabled="true"] {
|
|
225
|
+
cursor: not-allowed;
|
|
226
|
+
}
|
|
227
|
+
.gridui-u-button--data-disabled\:cursor-not-allowed[data-disabled] {
|
|
228
|
+
cursor: not-allowed;
|
|
229
|
+
}
|
|
230
|
+
.gridui-u-button--data-gridui-busy\:cursor-wait[data-gridui-busy] {
|
|
231
|
+
cursor: wait;
|
|
232
|
+
}
|
|
233
|
+
@media (prefers-reduced-motion: reduce) {
|
|
234
|
+
.gridui-u-button--motion-reduce\:transition-none {
|
|
235
|
+
transition-property: none;
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
.gridui-u-button--\[\&_\>_span\]\:whitespace-nowrap > span {
|
|
239
|
+
white-space: nowrap;
|
|
240
|
+
}
|
|
241
|
+
.gridui-u-button--\[\&_\>_span\]\:\[writing-mode\:vertical-rl\] > span {
|
|
242
|
+
writing-mode: vertical-rl;
|
|
243
|
+
}
|
|
244
|
+
.gridui-u-button--\[\&_svg\]\:pointer-events-none svg {
|
|
245
|
+
pointer-events: none;
|
|
246
|
+
}
|
|
247
|
+
.gridui-u-button--\[\&_svg\]\:h-\(--gridui-button-icon-size\) svg {
|
|
248
|
+
height: var(--gridui-button-icon-size);
|
|
249
|
+
}
|
|
250
|
+
.gridui-u-button--\[\&_svg\]\:w-\(--gridui-button-icon-size\) svg {
|
|
251
|
+
width: var(--gridui-button-icon-size);
|
|
252
|
+
}
|
|
253
|
+
.gridui-u-button--\[\&_svg\]\:shrink-0 svg {
|
|
254
|
+
flex-shrink: 0;
|
|
255
|
+
}
|
|
256
|
+
.gridui-u-button--\[\&\.gridui-button-extra-large\]\:h-18.gridui-button-extra-large {
|
|
257
|
+
height: calc(var(--spacing) * 18);
|
|
258
|
+
}
|
|
259
|
+
.gridui-u-button--\[\&\.gridui-button-extra-large\]\:w-18.gridui-button-extra-large {
|
|
260
|
+
width: calc(var(--spacing) * 18);
|
|
261
|
+
}
|
|
262
|
+
.gridui-u-button--\[\&\.gridui-button-large\]\:h-gridui-control-large.gridui-button-large {
|
|
263
|
+
height: var(--gridui-control-min-height-large);
|
|
264
|
+
}
|
|
265
|
+
.gridui-u-button--\[\&\.gridui-button-large\]\:w-gridui-control-large.gridui-button-large {
|
|
266
|
+
width: var(--gridui-control-min-height-large);
|
|
267
|
+
}
|
|
268
|
+
.gridui-u-button--\[\&\.gridui-button-small\]\:h-gridui-control-small.gridui-button-small {
|
|
269
|
+
height: var(--gridui-control-min-height-small);
|
|
270
|
+
}
|
|
271
|
+
.gridui-u-button--\[\&\.gridui-button-small\]\:w-gridui-control-small.gridui-button-small {
|
|
272
|
+
width: var(--gridui-control-min-height-small);
|
|
273
|
+
}
|
|
274
|
+
@media (pointer: coarse) {
|
|
275
|
+
.gridui-u-button--pointer-coarse\:\[\&\.gridui-button-small\]\:h-gridui-control.gridui-button-small {
|
|
276
|
+
height: var(--gridui-control-min-height);
|
|
277
|
+
}
|
|
278
|
+
.gridui-u-button--pointer-coarse\:\[\&\.gridui-button-small\]\:w-gridui-control.gridui-button-small {
|
|
279
|
+
width: var(--gridui-control-min-height);
|
|
280
|
+
}
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
@layer components {
|
|
284
|
+
.gridui-button {
|
|
285
|
+
border: 1px solid transparent;
|
|
286
|
+
}
|
|
287
|
+
.gridui-button-cell {
|
|
288
|
+
border: 0;
|
|
289
|
+
}
|
|
290
|
+
.gridui-button-label-content {
|
|
291
|
+
display: inline-flex;
|
|
292
|
+
min-width: 0;
|
|
293
|
+
flex-direction: inherit;
|
|
294
|
+
align-items: inherit;
|
|
295
|
+
justify-content: inherit;
|
|
296
|
+
gap: inherit;
|
|
297
|
+
}
|
|
298
|
+
.gridui-button-body {
|
|
299
|
+
display: inline-flex;
|
|
300
|
+
flex: 1;
|
|
301
|
+
min-width: 0;
|
|
302
|
+
flex-direction: inherit;
|
|
303
|
+
align-items: inherit;
|
|
304
|
+
justify-content: inherit;
|
|
305
|
+
gap: inherit;
|
|
306
|
+
}
|
|
307
|
+
.gridui-button:is(:disabled, [aria-disabled="true"]:not([data-gridui-busy]), [data-disabled]) > .gridui-button-content, .gridui-button:is(:disabled, [aria-disabled="true"]:not([data-gridui-busy]), [data-disabled]) > .gridui-button-start-region > .gridui-button-content, .gridui-button:is(:disabled, [aria-disabled="true"]:not([data-gridui-busy]), [data-disabled]) > .gridui-button-end-region > .gridui-button-content {
|
|
308
|
+
opacity: 0.5;
|
|
309
|
+
}
|
|
310
|
+
.gridui-button-start-region {
|
|
311
|
+
min-width: calc(var(--gridui-button-icon-size) + var(--gridui-space-16));
|
|
312
|
+
border-inline-end: 1px solid;
|
|
313
|
+
border-color: inherit;
|
|
314
|
+
}
|
|
315
|
+
.gridui-button-end-region {
|
|
316
|
+
border-inline-start: 1px solid;
|
|
317
|
+
border-color: inherit;
|
|
318
|
+
}
|
|
319
|
+
@media (prefers-reduced-motion: no-preference) {
|
|
320
|
+
.gridui-button-icon-motion-outward:not(:disabled, [aria-disabled="true"]:not([data-gridui-busy]), [data-disabled], [aria-readonly="true"], [data-readonly], [readonly]) .gridui-button-end-icon {
|
|
321
|
+
transition: var(--gridui-motion-transition, transform calc(var(--gridui-motion-duration-quick) * var(--gridui-motion-factor, 1)) var(--gridui-motion-ease-out));
|
|
322
|
+
}
|
|
323
|
+
.gridui-button-icon-motion-outward:not(:disabled, [aria-disabled="true"]:not([data-gridui-busy]), [data-disabled], [aria-readonly="true"], [data-readonly], [readonly]):hover .gridui-button-end-icon {
|
|
324
|
+
transform: var(--gridui-motion-transform, translate(var(--gridui-space-4), calc(-1 * var(--gridui-space-4))));
|
|
325
|
+
}
|
|
326
|
+
.gridui-button-icon-motion-outward:not(:disabled, [aria-disabled="true"]:not([data-gridui-busy]), [data-disabled], [aria-readonly="true"], [data-readonly], [readonly]):dir(rtl):hover .gridui-button-end-icon {
|
|
327
|
+
transform: var(--gridui-motion-transform, translate(calc(-1 * var(--gridui-space-4)), calc(-1 * var(--gridui-space-4))));
|
|
328
|
+
}
|
|
329
|
+
}
|
|
330
|
+
.gridui-button-group {
|
|
331
|
+
--gridui-button-group-padding-block: var(--gridui-space-24);
|
|
332
|
+
container: gridui-button-group / inline-size;
|
|
333
|
+
min-width: 0;
|
|
334
|
+
}
|
|
335
|
+
.gridui-button-group-items {
|
|
336
|
+
display: grid;
|
|
337
|
+
grid-auto-flow: column;
|
|
338
|
+
grid-auto-columns: minmax(0, 1fr);
|
|
339
|
+
align-items: stretch;
|
|
340
|
+
}
|
|
341
|
+
.gridui-button-group-items[data-layout="standard"] {
|
|
342
|
+
gap: var(--gridui-space-8);
|
|
343
|
+
}
|
|
344
|
+
.gridui-button-group-items[data-layout="cells"] > [data-gridui-button-group-item]:not([hidden]) ~ [data-gridui-button-group-item]:not([hidden])::before {
|
|
345
|
+
position: absolute;
|
|
346
|
+
inset-block: 0;
|
|
347
|
+
inset-inline-start: 0;
|
|
348
|
+
width: 1px;
|
|
349
|
+
background: var(--gridui-button-group-border, var(--gridui-border));
|
|
350
|
+
pointer-events: none;
|
|
351
|
+
content: "";
|
|
352
|
+
}
|
|
353
|
+
@container gridui-button-group (max-width: 20rem) {
|
|
354
|
+
.gridui-button-group-items {
|
|
355
|
+
grid-auto-flow: row;
|
|
356
|
+
grid-auto-rows: 1fr;
|
|
357
|
+
}
|
|
358
|
+
.gridui-button-group-items[data-layout="cells"] > [data-gridui-button-group-item]:not([hidden]) ~ [data-gridui-button-group-item]:not([hidden])::before {
|
|
359
|
+
inset-block: 0 auto;
|
|
360
|
+
inset-inline: 0;
|
|
361
|
+
width: auto;
|
|
362
|
+
height: 1px;
|
|
363
|
+
}
|
|
364
|
+
}
|
|
365
|
+
}
|
|
366
|
+
@layer utilities {
|
|
367
|
+
.gridui-button-group-items > [data-gridui-button-group-item] {
|
|
368
|
+
position: relative;
|
|
369
|
+
width: 100%;
|
|
370
|
+
height: 100%;
|
|
371
|
+
min-width: 0;
|
|
372
|
+
}
|
|
373
|
+
.gridui-button-group-items[data-layout="cells"] > [data-gridui-button-group-item] {
|
|
374
|
+
min-height: 2.75rem;
|
|
375
|
+
padding: var(--gridui-button-group-padding-block) var(--gridui-space-24);
|
|
376
|
+
border: 0;
|
|
377
|
+
border-radius: 0;
|
|
378
|
+
}
|
|
379
|
+
}
|
|
380
|
+
@property --tw-border-style {
|
|
381
|
+
syntax: "*";
|
|
382
|
+
inherits: false;
|
|
383
|
+
initial-value: solid;
|
|
384
|
+
}
|
|
385
|
+
@property --tw-duration {
|
|
386
|
+
syntax: "*";
|
|
387
|
+
inherits: false;
|
|
388
|
+
}
|
|
389
|
+
@property --tw-ease {
|
|
390
|
+
syntax: "*";
|
|
391
|
+
inherits: false;
|
|
392
|
+
}
|
|
393
|
+
@layer properties {
|
|
394
|
+
@supports ((-webkit-hyphens: none) and (not (margin-trim: block))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))) {
|
|
395
|
+
*, ::before, ::after, ::backdrop {
|
|
396
|
+
--tw-border-style: solid;
|
|
397
|
+
--tw-duration: initial;
|
|
398
|
+
--tw-ease: initial;
|
|
399
|
+
}
|
|
400
|
+
}
|
|
401
|
+
}
|
|
402
|
+
|
|
403
|
+
/*! tailwindcss v4.3.5 | MIT License | https://tailwindcss.com */
|
|
404
|
+
@layer properties;
|
|
405
|
+
@layer theme, base, components, utilities;
|
|
406
|
+
@layer theme {
|
|
407
|
+
:root, :host {
|
|
408
|
+
--spacing: 0.25rem;
|
|
409
|
+
}
|
|
410
|
+
}
|
|
411
|
+
@layer utilities {
|
|
412
|
+
.gridui-u-overlay--z-\(--gridui-z-popover\) {
|
|
413
|
+
z-index: var(--gridui-z-popover);
|
|
414
|
+
}
|
|
415
|
+
.gridui-u-overlay--flex {
|
|
416
|
+
display: flex;
|
|
417
|
+
}
|
|
418
|
+
.gridui-u-overlay--inline-flex {
|
|
419
|
+
display: inline-flex;
|
|
420
|
+
}
|
|
421
|
+
.gridui-u-overlay--size-gridui-16 {
|
|
422
|
+
width: var(--gridui-space-16);
|
|
423
|
+
height: var(--gridui-space-16);
|
|
424
|
+
}
|
|
425
|
+
.gridui-u-overlay--min-h-10 {
|
|
426
|
+
min-height: calc(var(--spacing) * 10);
|
|
427
|
+
}
|
|
428
|
+
.gridui-u-overlay--min-w-0 {
|
|
429
|
+
min-width: 0px;
|
|
430
|
+
}
|
|
431
|
+
.gridui-u-overlay--shrink-0 {
|
|
432
|
+
flex-shrink: 0;
|
|
433
|
+
}
|
|
434
|
+
.gridui-u-overlay--cursor-pointer {
|
|
435
|
+
cursor: pointer;
|
|
436
|
+
}
|
|
437
|
+
.gridui-u-overlay--items-center {
|
|
438
|
+
align-items: center;
|
|
439
|
+
}
|
|
440
|
+
.gridui-u-overlay--justify-center {
|
|
441
|
+
justify-content: center;
|
|
442
|
+
}
|
|
443
|
+
.gridui-u-overlay--gap-gridui-8 {
|
|
444
|
+
gap: var(--gridui-space-8);
|
|
445
|
+
}
|
|
446
|
+
.gridui-u-overlay--rounded-control {
|
|
447
|
+
border-radius: var(--gridui-control-radius);
|
|
448
|
+
}
|
|
449
|
+
.gridui-u-overlay--border {
|
|
450
|
+
border-style: var(--tw-border-style);
|
|
451
|
+
border-width: 1px;
|
|
452
|
+
}
|
|
453
|
+
.gridui-u-overlay--border-solid {
|
|
454
|
+
--tw-border-style: solid;
|
|
455
|
+
border-style: solid;
|
|
456
|
+
}
|
|
457
|
+
.gridui-u-overlay--border-border {
|
|
458
|
+
border-color: var(--gridui-border);
|
|
459
|
+
}
|
|
460
|
+
.gridui-u-overlay--bg-background {
|
|
461
|
+
background-color: var(--gridui-background);
|
|
462
|
+
}
|
|
463
|
+
.gridui-u-overlay--p-0 {
|
|
464
|
+
padding: 0px;
|
|
465
|
+
}
|
|
466
|
+
.gridui-u-overlay--p-gridui-8 {
|
|
467
|
+
padding: var(--gridui-space-8);
|
|
468
|
+
}
|
|
469
|
+
.gridui-u-overlay--px-gridui-8 {
|
|
470
|
+
padding-inline: var(--gridui-space-8);
|
|
471
|
+
}
|
|
472
|
+
.gridui-u-overlay--py-gridui-8 {
|
|
473
|
+
padding-block: var(--gridui-space-8);
|
|
474
|
+
}
|
|
475
|
+
.gridui-u-overlay--type-data {
|
|
476
|
+
font: var(--gridui-type-data);
|
|
477
|
+
font-family: var(--gridui-font-body);
|
|
478
|
+
letter-spacing: normal;
|
|
479
|
+
font-variant-numeric: tabular-nums;
|
|
480
|
+
}
|
|
481
|
+
.gridui-u-overlay--type-caption {
|
|
482
|
+
font: var(--gridui-type-caption);
|
|
483
|
+
font-family: var(--gridui-font-body);
|
|
484
|
+
letter-spacing: normal;
|
|
485
|
+
}
|
|
486
|
+
.gridui-u-overlay--wrap-anywhere {
|
|
487
|
+
overflow-wrap: anywhere;
|
|
488
|
+
}
|
|
489
|
+
.gridui-u-overlay--whitespace-normal {
|
|
490
|
+
white-space: normal;
|
|
491
|
+
}
|
|
492
|
+
.gridui-u-overlay--text-foreground {
|
|
493
|
+
color: var(--gridui-foreground);
|
|
494
|
+
}
|
|
495
|
+
.gridui-u-overlay--text-inherit {
|
|
496
|
+
color: inherit;
|
|
497
|
+
}
|
|
498
|
+
.gridui-u-overlay--text-muted {
|
|
499
|
+
color: var(--gridui-muted);
|
|
500
|
+
}
|
|
501
|
+
.gridui-u-overlay--no-underline {
|
|
502
|
+
text-decoration-line: none;
|
|
503
|
+
}
|
|
504
|
+
.gridui-u-overlay--aria-selected\:bg-selection-background[aria-selected="true"] {
|
|
505
|
+
background-color: var(--gridui-selection-background);
|
|
506
|
+
}
|
|
507
|
+
.gridui-u-overlay--aria-\[current\=page\]\:bg-selection-background[aria-current="page"] {
|
|
508
|
+
background-color: var(--gridui-selection-background);
|
|
509
|
+
}
|
|
510
|
+
.gridui-u-overlay--data-disabled\:pointer-events-none[data-disabled] {
|
|
511
|
+
pointer-events: none;
|
|
512
|
+
}
|
|
513
|
+
.gridui-u-overlay--data-disabled\:opacity-50[data-disabled] {
|
|
514
|
+
opacity: 50%;
|
|
515
|
+
}
|
|
516
|
+
.gridui-u-overlay--data-\[state\=checked\]\:bg-selection-background[data-state="checked"] {
|
|
517
|
+
background-color: var(--gridui-selection-background);
|
|
518
|
+
}
|
|
519
|
+
}
|
|
520
|
+
@layer components {
|
|
521
|
+
.gridui-overlay-surface {
|
|
522
|
+
--gridui-surface-offset-x: 0px;
|
|
523
|
+
--gridui-surface-offset-y: 0px;
|
|
524
|
+
--gridui-overlay-enter-duration: var(--gridui-motion-duration-normal);
|
|
525
|
+
--gridui-overlay-fill-mode: both;
|
|
526
|
+
transform-origin: var(--gridui-overlay-origin, center);
|
|
527
|
+
}
|
|
528
|
+
.gridui-overlay-dialog {
|
|
529
|
+
--gridui-overlay-fill-mode: none;
|
|
530
|
+
transform-origin: center;
|
|
531
|
+
}
|
|
532
|
+
.gridui-overlay-tooltip {
|
|
533
|
+
--gridui-overlay-enter-duration: var(--gridui-motion-duration-quick);
|
|
534
|
+
}
|
|
535
|
+
.gridui-overlay-floating[data-side="bottom"] {
|
|
536
|
+
--gridui-surface-offset-y: calc(-1 * var(--gridui-motion-distance));
|
|
537
|
+
}
|
|
538
|
+
.gridui-overlay-floating[data-side="top"] {
|
|
539
|
+
--gridui-surface-offset-y: var(--gridui-motion-distance);
|
|
540
|
+
}
|
|
541
|
+
.gridui-overlay-floating[data-side="left"] {
|
|
542
|
+
--gridui-surface-offset-x: var(--gridui-motion-distance);
|
|
543
|
+
}
|
|
544
|
+
.gridui-overlay-floating[data-side="right"] {
|
|
545
|
+
--gridui-surface-offset-x: calc(-1 * var(--gridui-motion-distance));
|
|
546
|
+
}
|
|
547
|
+
.gridui-overlay-surface[data-state="closed"] {
|
|
548
|
+
pointer-events: none;
|
|
549
|
+
}
|
|
550
|
+
.gridui-overlay-surface:not([data-side="none"]):is([data-state="open"], [data-state="delayed-open"], [data-state="instant-open"]) {
|
|
551
|
+
animation: var(--gridui-motion-animation, gridui-surface-enter calc(var(--gridui-overlay-enter-duration) * var(--gridui-motion-factor, 1)) var(--gridui-motion-ease-out) var(--gridui-overlay-fill-mode));
|
|
552
|
+
}
|
|
553
|
+
.gridui-overlay-surface:not([data-side="none"])[data-state="closed"] {
|
|
554
|
+
animation: var(--gridui-motion-animation, gridui-surface-exit calc(var(--gridui-motion-duration-quick) * var(--gridui-motion-factor, 1)) var(--gridui-motion-ease-in) var(--gridui-overlay-fill-mode));
|
|
555
|
+
}
|
|
556
|
+
.gridui-overlay-backdrop {
|
|
557
|
+
background: var(--gridui-backdrop);
|
|
558
|
+
@supports (color: color-mix(in lab, red, red)) {
|
|
559
|
+
background: color-mix(in srgb, var(--gridui-backdrop) var(--gridui-backdrop-opacity), transparent);
|
|
560
|
+
}
|
|
561
|
+
--gridui-overlay-enter-duration: var(--gridui-motion-duration-normal);
|
|
562
|
+
--gridui-overlay-exit-duration: var(--gridui-motion-duration-quick);
|
|
563
|
+
--gridui-overlay-fill-mode: none;
|
|
564
|
+
}
|
|
565
|
+
.gridui-overlay-backdrop-deliberate {
|
|
566
|
+
--gridui-overlay-enter-duration: var(--gridui-motion-duration-deliberate);
|
|
567
|
+
--gridui-overlay-exit-duration: var(--gridui-motion-duration-normal);
|
|
568
|
+
--gridui-overlay-fill-mode: both;
|
|
569
|
+
}
|
|
570
|
+
.gridui-overlay-backdrop[data-state="open"] {
|
|
571
|
+
animation: var(--gridui-motion-animation, gridui-fade-enter calc(var(--gridui-overlay-enter-duration) * var(--gridui-motion-factor, 1)) var(--gridui-motion-ease-out) var(--gridui-overlay-fill-mode));
|
|
572
|
+
}
|
|
573
|
+
.gridui-overlay-backdrop[data-state="closed"] {
|
|
574
|
+
animation: var(--gridui-motion-animation, gridui-fade-exit calc(var(--gridui-overlay-exit-duration) * var(--gridui-motion-factor, 1)) var(--gridui-motion-ease-in) var(--gridui-overlay-fill-mode));
|
|
575
|
+
}
|
|
576
|
+
@media (prefers-reduced-motion: reduce) {
|
|
577
|
+
.gridui-overlay-surface:not([data-side="none"])[data-state], .gridui-overlay-backdrop[data-state] {
|
|
578
|
+
animation: none;
|
|
579
|
+
}
|
|
580
|
+
}
|
|
581
|
+
}
|
|
582
|
+
@property --tw-border-style {
|
|
583
|
+
syntax: "*";
|
|
584
|
+
inherits: false;
|
|
585
|
+
initial-value: solid;
|
|
586
|
+
}
|
|
587
|
+
@layer properties {
|
|
588
|
+
@supports ((-webkit-hyphens: none) and (not (margin-trim: block))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))) {
|
|
589
|
+
*, ::before, ::after, ::backdrop {
|
|
590
|
+
--tw-border-style: solid;
|
|
591
|
+
}
|
|
592
|
+
}
|
|
593
|
+
}
|
|
594
|
+
|
|
1
595
|
/*! tailwindcss v4.3.5 | MIT License | https://tailwindcss.com */
|
|
2
596
|
@layer properties;
|
|
3
597
|
@layer theme, base, components, utilities;
|
|
@@ -105,9 +699,6 @@
|
|
|
105
699
|
.gridui-u-modal--border-border {
|
|
106
700
|
border-color: var(--gridui-border);
|
|
107
701
|
}
|
|
108
|
-
.gridui-u-modal--bg-\[light-dark\(rgb\(0_0_0\/25\%\)\,rgb\(0_0_0\/60\%\)\)\] {
|
|
109
|
-
background-color: light-dark(rgb(0 0 0/25%),rgb(0 0 0/60%));
|
|
110
|
-
}
|
|
111
702
|
.gridui-u-modal--p-0 {
|
|
112
703
|
padding: 0px;
|
|
113
704
|
}
|
|
@@ -0,0 +1,226 @@
|
|
|
1
|
+
/*! tailwindcss v4.3.5 | MIT License | https://tailwindcss.com */
|
|
2
|
+
@layer properties;
|
|
3
|
+
@layer theme, base, components, utilities;
|
|
4
|
+
@layer theme {
|
|
5
|
+
:root, :host {
|
|
6
|
+
--spacing: 0.25rem;
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
@layer utilities {
|
|
10
|
+
.gridui-u-modal--fixed {
|
|
11
|
+
position: fixed;
|
|
12
|
+
}
|
|
13
|
+
.gridui-u-modal--relative {
|
|
14
|
+
position: relative;
|
|
15
|
+
}
|
|
16
|
+
.gridui-u-modal--inset-0 {
|
|
17
|
+
inset: 0px;
|
|
18
|
+
}
|
|
19
|
+
.gridui-u-modal--top-1\/2 {
|
|
20
|
+
top: calc(1 / 2 * 100%);
|
|
21
|
+
}
|
|
22
|
+
.gridui-u-modal--left-1\/2 {
|
|
23
|
+
left: calc(1 / 2 * 100%);
|
|
24
|
+
}
|
|
25
|
+
.gridui-u-modal--z-\(--gridui-z-content\) {
|
|
26
|
+
z-index: var(--gridui-z-content);
|
|
27
|
+
}
|
|
28
|
+
.gridui-u-modal--z-\(--gridui-z-dialog\) {
|
|
29
|
+
z-index: var(--gridui-z-dialog);
|
|
30
|
+
}
|
|
31
|
+
.gridui-u-modal--z-\(--gridui-z-dialog-backdrop\) {
|
|
32
|
+
z-index: var(--gridui-z-dialog-backdrop);
|
|
33
|
+
}
|
|
34
|
+
.gridui-u-modal--m-0 {
|
|
35
|
+
margin: 0px;
|
|
36
|
+
}
|
|
37
|
+
.gridui-u-modal--mt-gridui-8 {
|
|
38
|
+
margin-top: var(--gridui-space-8);
|
|
39
|
+
}
|
|
40
|
+
.gridui-u-modal--mb-0 {
|
|
41
|
+
margin-bottom: 0px;
|
|
42
|
+
}
|
|
43
|
+
.gridui-u-modal--flex {
|
|
44
|
+
display: flex;
|
|
45
|
+
}
|
|
46
|
+
.gridui-u-modal--grid {
|
|
47
|
+
display: grid;
|
|
48
|
+
}
|
|
49
|
+
.gridui-u-modal--max-h-\[40dvh\] {
|
|
50
|
+
max-height: 40dvh;
|
|
51
|
+
}
|
|
52
|
+
.gridui-u-modal--max-h-\[calc\(100dvh-32px\)\] {
|
|
53
|
+
max-height: calc(100dvh - 32px);
|
|
54
|
+
}
|
|
55
|
+
.gridui-u-modal--min-h-0 {
|
|
56
|
+
min-height: 0px;
|
|
57
|
+
}
|
|
58
|
+
.gridui-u-modal--min-h-11 {
|
|
59
|
+
min-height: calc(var(--spacing) * 11);
|
|
60
|
+
}
|
|
61
|
+
.gridui-u-modal--w-\[min\(calc\(100\%-32px\)\,var\(--gridui-modal-width\,37rem\)\)\] {
|
|
62
|
+
width: min(calc(100% - 32px), var(--gridui-modal-width,37rem));
|
|
63
|
+
}
|
|
64
|
+
.gridui-u-modal--w-gridui-64 {
|
|
65
|
+
width: var(--gridui-space-64);
|
|
66
|
+
}
|
|
67
|
+
.gridui-u-modal--min-w-0 {
|
|
68
|
+
min-width: 0px;
|
|
69
|
+
}
|
|
70
|
+
.gridui-u-modal--shrink-0 {
|
|
71
|
+
flex-shrink: 0;
|
|
72
|
+
}
|
|
73
|
+
.gridui-u-modal---translate-x-1\/2 {
|
|
74
|
+
--tw-translate-x: calc(calc(1 / 2 * 100%) * -1);
|
|
75
|
+
translate: var(--tw-translate-x) var(--tw-translate-y);
|
|
76
|
+
}
|
|
77
|
+
.gridui-u-modal---translate-y-1\/2 {
|
|
78
|
+
--tw-translate-y: calc(calc(1 / 2 * 100%) * -1);
|
|
79
|
+
translate: var(--tw-translate-x) var(--tw-translate-y);
|
|
80
|
+
}
|
|
81
|
+
.gridui-u-modal--grid-cols-\[minmax\(0\,1fr\)_auto\] {
|
|
82
|
+
grid-template-columns: minmax(0,1fr) auto;
|
|
83
|
+
}
|
|
84
|
+
.gridui-u-modal--flex-col {
|
|
85
|
+
flex-direction: column;
|
|
86
|
+
}
|
|
87
|
+
.gridui-u-modal--self-stretch {
|
|
88
|
+
align-self: stretch;
|
|
89
|
+
}
|
|
90
|
+
.gridui-u-modal--overflow-auto {
|
|
91
|
+
overflow: auto;
|
|
92
|
+
}
|
|
93
|
+
.gridui-u-modal--overflow-visible {
|
|
94
|
+
overflow: visible;
|
|
95
|
+
}
|
|
96
|
+
.gridui-u-modal--overflow-y-auto {
|
|
97
|
+
overflow-y: auto;
|
|
98
|
+
}
|
|
99
|
+
.gridui-u-modal--overscroll-contain {
|
|
100
|
+
overscroll-behavior: contain;
|
|
101
|
+
}
|
|
102
|
+
.gridui-u-modal--rounded-none {
|
|
103
|
+
border-radius: 0;
|
|
104
|
+
}
|
|
105
|
+
.gridui-u-modal--border-border {
|
|
106
|
+
border-color: var(--gridui-border);
|
|
107
|
+
}
|
|
108
|
+
.gridui-u-modal--p-0 {
|
|
109
|
+
padding: 0px;
|
|
110
|
+
}
|
|
111
|
+
.gridui-u-modal--p-gridui-24 {
|
|
112
|
+
padding: var(--gridui-space-24);
|
|
113
|
+
}
|
|
114
|
+
.gridui-u-modal--px-gridui-24 {
|
|
115
|
+
padding-inline: var(--gridui-space-24);
|
|
116
|
+
}
|
|
117
|
+
.gridui-u-modal--py-\(--gridui-modal-padding\) {
|
|
118
|
+
padding-block: var(--gridui-modal-padding);
|
|
119
|
+
}
|
|
120
|
+
.gridui-u-modal--type-heading {
|
|
121
|
+
font: var(--gridui-type-heading);
|
|
122
|
+
font-family: var(--gridui-font-body);
|
|
123
|
+
letter-spacing: normal;
|
|
124
|
+
text-wrap: balance;
|
|
125
|
+
}
|
|
126
|
+
.gridui-u-modal--type-body {
|
|
127
|
+
font: var(--gridui-type-body);
|
|
128
|
+
font-family: var(--gridui-font-body);
|
|
129
|
+
letter-spacing: normal;
|
|
130
|
+
}
|
|
131
|
+
.gridui-u-modal--type-supporting {
|
|
132
|
+
font: var(--gridui-type-supporting);
|
|
133
|
+
font-family: var(--gridui-font-body);
|
|
134
|
+
letter-spacing: normal;
|
|
135
|
+
}
|
|
136
|
+
.gridui-u-modal--wrap-anywhere {
|
|
137
|
+
overflow-wrap: anywhere;
|
|
138
|
+
}
|
|
139
|
+
.gridui-u-modal--text-muted {
|
|
140
|
+
color: var(--gridui-muted);
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
@layer components {
|
|
144
|
+
.gridui-modal-section {
|
|
145
|
+
--gridui-modal-padding: var(--gridui-modal-space);
|
|
146
|
+
}
|
|
147
|
+
@media (min-width: 40rem) {
|
|
148
|
+
.gridui-modal-section {
|
|
149
|
+
--gridui-modal-padding: var(--gridui-modal-space-sm);
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
@media (min-width: 48rem) {
|
|
153
|
+
.gridui-modal-section {
|
|
154
|
+
--gridui-modal-padding: var(--gridui-modal-space-md);
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
@media (min-width: 64rem) {
|
|
158
|
+
.gridui-modal-section {
|
|
159
|
+
--gridui-modal-padding: var(--gridui-modal-space-lg);
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
.gridui-modal-header {
|
|
163
|
+
border-block-end: 1px solid var(--gridui-border);
|
|
164
|
+
}
|
|
165
|
+
.gridui-button.gridui-modal-close {
|
|
166
|
+
border-width: 0;
|
|
167
|
+
border-inline-start-width: 1px;
|
|
168
|
+
}
|
|
169
|
+
.gridui-modal-actions.gridui-button-group {
|
|
170
|
+
--gridui-button-group-padding-block: var(--gridui-modal-padding);
|
|
171
|
+
flex: 1 1 16rem;
|
|
172
|
+
}
|
|
173
|
+
@media (min-width: 40rem) {
|
|
174
|
+
.gridui-modal-actions {
|
|
175
|
+
margin-inline-start: auto;
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
.gridui-modal-footer {
|
|
179
|
+
display: flex;
|
|
180
|
+
flex-wrap: wrap;
|
|
181
|
+
align-items: stretch;
|
|
182
|
+
border-block-start: 1px solid var(--gridui-border);
|
|
183
|
+
}
|
|
184
|
+
.gridui-modal-footer > :not(.gridui-modal-actions) {
|
|
185
|
+
flex: 1 1 12rem;
|
|
186
|
+
align-self: center;
|
|
187
|
+
}
|
|
188
|
+
@media (min-width: 40rem) {
|
|
189
|
+
.gridui-modal-footer {
|
|
190
|
+
flex-wrap: nowrap;
|
|
191
|
+
}
|
|
192
|
+
.gridui-modal-footer > :not(.gridui-modal-actions) + .gridui-modal-actions {
|
|
193
|
+
border-inline-start: 1px solid var(--gridui-border);
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
@media (max-width: 39.999rem) {
|
|
197
|
+
.gridui-modal-footer > :not(.gridui-modal-actions) + .gridui-modal-actions {
|
|
198
|
+
flex-basis: 100%;
|
|
199
|
+
border-block-start: 1px solid var(--gridui-border);
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
@property --tw-translate-x {
|
|
204
|
+
syntax: "*";
|
|
205
|
+
inherits: false;
|
|
206
|
+
initial-value: 0;
|
|
207
|
+
}
|
|
208
|
+
@property --tw-translate-y {
|
|
209
|
+
syntax: "*";
|
|
210
|
+
inherits: false;
|
|
211
|
+
initial-value: 0;
|
|
212
|
+
}
|
|
213
|
+
@property --tw-translate-z {
|
|
214
|
+
syntax: "*";
|
|
215
|
+
inherits: false;
|
|
216
|
+
initial-value: 0;
|
|
217
|
+
}
|
|
218
|
+
@layer properties {
|
|
219
|
+
@supports ((-webkit-hyphens: none) and (not (margin-trim: block))) or ((-moz-orient: inline) and (not (color:rgb(from red r g b)))) {
|
|
220
|
+
*, ::before, ::after, ::backdrop {
|
|
221
|
+
--tw-translate-x: 0;
|
|
222
|
+
--tw-translate-y: 0;
|
|
223
|
+
--tw-translate-z: 0;
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
}
|
package/docs/catalog.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 1,
|
|
3
3
|
"name": "@gridui/modal",
|
|
4
|
-
"version": "2.
|
|
4
|
+
"version": "2.2.0",
|
|
5
5
|
"category": "core",
|
|
6
6
|
"description": "GridUI React modal",
|
|
7
7
|
"usage": "The centered modal shares Radix Dialog's focus and dismissal behavior with Drawer. Its header owns a title cell and a full-height close cell; its footer owns an optional note and edge-aligned action cells. Header and footer accept independent responsive `paddingBlock` values. The body owns content scrolling and defaults to `tabIndex={0}` so text-only content can be scrolled with the keyboard inside the focus scope. Supply a name when using a region role; native `tabIndex` overrides remain available. Small viewports stack footer actions below the note. See the composition example and API.",
|
|
@@ -164,6 +164,7 @@
|
|
|
164
164
|
"@gridui/overlay/styles.css",
|
|
165
165
|
"@gridui/modal/styles.css"
|
|
166
166
|
],
|
|
167
|
+
"styledImport": "@gridui/modal/styled",
|
|
167
168
|
"examples": [
|
|
168
169
|
"https://github.com/sudo-ui/GridUI-React-Monorepo/blob/main/packages-core/modal/stories/composition.mdx",
|
|
169
170
|
"https://github.com/sudo-ui/GridUI-React-Monorepo/blob/main/packages-core/modal/stories/forms-retention.mdx",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gridui/modal",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.2.0",
|
|
4
4
|
"description": "GridUI React modal",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"type": "module",
|
|
@@ -10,14 +10,19 @@
|
|
|
10
10
|
"docs"
|
|
11
11
|
],
|
|
12
12
|
"sideEffects": [
|
|
13
|
-
"**/*.css"
|
|
13
|
+
"**/*.css",
|
|
14
|
+
"./dist/styled.js"
|
|
14
15
|
],
|
|
15
16
|
"exports": {
|
|
16
17
|
".": {
|
|
17
18
|
"types": "./dist/index.d.ts",
|
|
18
19
|
"import": "./dist/index.js"
|
|
19
20
|
},
|
|
20
|
-
"./styles.css": "./dist/styles.css"
|
|
21
|
+
"./styles.css": "./dist/styles.css",
|
|
22
|
+
"./styled": {
|
|
23
|
+
"types": "./dist/index.d.ts",
|
|
24
|
+
"import": "./dist/styled.js"
|
|
25
|
+
}
|
|
21
26
|
},
|
|
22
27
|
"publishConfig": {
|
|
23
28
|
"access": "public"
|
|
@@ -27,13 +32,13 @@
|
|
|
27
32
|
"react-dom": "^19.2.0"
|
|
28
33
|
},
|
|
29
34
|
"dependencies": {
|
|
30
|
-
"@gridui/button": "^5.
|
|
31
|
-
"@gridui/
|
|
35
|
+
"@gridui/button": "^5.2.0",
|
|
36
|
+
"@gridui/motion": "^1.0.2",
|
|
37
|
+
"@gridui/overlay": "^2.4.0",
|
|
32
38
|
"@gridui/style-utils": "^4.0.0",
|
|
33
|
-
"@gridui/theme": "^
|
|
39
|
+
"@gridui/theme": "^4.0.0",
|
|
34
40
|
"@radix-ui/react-dialog": "1.3.1",
|
|
35
|
-
"lucide-react": "1.72.0"
|
|
36
|
-
"@gridui/motion": "^1.0.1"
|
|
41
|
+
"lucide-react": "1.72.0"
|
|
37
42
|
},
|
|
38
43
|
"devDependencies": {
|
|
39
44
|
"@gridui-internal/configuration": "0.0.0-internal",
|