@ngrok/mantle 0.63.2 → 0.64.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/accordion.d.ts +1 -1
- package/dist/accordion.js +1 -1
- package/dist/accordion.js.map +1 -1
- package/dist/alert-dialog.d.ts +13 -13
- package/dist/alert-dialog.js +1 -1
- package/dist/alert-dialog.js.map +1 -1
- package/dist/alert.d.ts +7 -7
- package/dist/alert.js +1 -1
- package/dist/alert.js.map +1 -1
- package/dist/anchor.d.ts +1 -1
- package/dist/anchor.js +1 -1
- package/dist/anchor.js.map +1 -1
- package/dist/badge.d.ts +1 -1
- package/dist/badge.js +1 -1
- package/dist/badge.js.map +1 -1
- package/dist/{button-DQcrsUyD.d.ts → button-DLUUf_c-.d.ts} +1 -1
- package/dist/button.d.ts +2 -2
- package/dist/button.js +1 -1
- package/dist/calendar.js +1 -1
- package/dist/card.d.ts +5 -5
- package/dist/card.js +1 -1
- package/dist/card.js.map +1 -1
- package/dist/checkbox.d.ts +1 -1
- package/dist/checkbox.js.map +1 -1
- package/dist/{chunk-TS7XNZ62.js → chunk-5XDZE2OU.js} +2 -2
- package/dist/chunk-5XDZE2OU.js.map +1 -0
- package/dist/chunk-ADF5DAYG.js +2 -0
- package/dist/chunk-ADF5DAYG.js.map +1 -0
- package/dist/{chunk-U32WN4A7.js → chunk-CBRSMQ26.js} +2 -2
- package/dist/{chunk-U32WN4A7.js.map → chunk-CBRSMQ26.js.map} +1 -1
- package/dist/{chunk-NQZYWYVH.js → chunk-ELZLLG6G.js} +2 -2
- package/dist/{chunk-73DPYKW5.js → chunk-HLRTYX4G.js} +2 -2
- package/dist/chunk-HLRTYX4G.js.map +1 -0
- package/dist/{chunk-SBVSECWW.js → chunk-IVQ626TU.js} +2 -2
- package/dist/chunk-IVQ626TU.js.map +1 -0
- package/dist/chunk-LB366VCO.js +2 -0
- package/dist/chunk-LB366VCO.js.map +1 -0
- package/dist/{chunk-LURP5WQR.js → chunk-MLXONRJD.js} +2 -2
- package/dist/chunk-MLXONRJD.js.map +1 -0
- package/dist/{chunk-3ESTDWHQ.js → chunk-QK3NV2Q3.js} +2 -2
- package/dist/chunk-QK3NV2Q3.js.map +1 -0
- package/dist/{chunk-5M264XXH.js → chunk-RED6SFAV.js} +1 -1
- package/dist/chunk-RED6SFAV.js.map +1 -0
- package/dist/{chunk-NZ6DRFAL.js → chunk-SBQHQ2SJ.js} +1 -1
- package/dist/chunk-SBQHQ2SJ.js.map +1 -0
- package/dist/{chunk-QWZXK2IF.js → chunk-W5A5HSFE.js} +2 -2
- package/dist/{chunk-QWZXK2IF.js.map → chunk-W5A5HSFE.js.map} +1 -1
- package/dist/{chunk-KVXXQCAI.js → chunk-ZS2HEB67.js} +2 -2
- package/dist/chunk-ZS2HEB67.js.map +1 -0
- package/dist/code-block.d.ts +9 -9
- package/dist/code-block.js +2 -2
- package/dist/code-block.js.map +1 -1
- package/dist/code.d.ts +1 -1
- package/dist/code.js.map +1 -1
- package/dist/combobox.d.ts +8 -8
- package/dist/combobox.js +1 -1
- package/dist/combobox.js.map +1 -1
- package/dist/command.d.ts +18 -21
- package/dist/command.js +1 -1
- package/dist/command.js.map +1 -1
- package/dist/data-table.d.ts +13 -13
- package/dist/data-table.js +1 -1
- package/dist/data-table.js.map +1 -1
- package/dist/description-list.d.ts +4 -4
- package/dist/description-list.js +1 -1
- package/dist/description-list.js.map +1 -1
- package/dist/dialog.d.ts +13 -13
- package/dist/dialog.js +1 -1
- package/dist/dropdown-menu.d.ts +14 -14
- package/dist/dropdown-menu.js +1 -1
- package/dist/flag.d.ts +1 -1
- package/dist/flag.js.map +1 -1
- package/dist/hooks.d.ts +2 -2
- package/dist/hooks.js +1 -1
- package/dist/hooks.js.map +1 -1
- package/dist/hover-card.d.ts +4 -4
- package/dist/hover-card.js.map +1 -1
- package/dist/{icon-CkvpQ4BK.d.ts → icon-DXTMiV1L.d.ts} +1 -1
- package/dist/{icon-button-D4BTvC7F.d.ts → icon-button-CT71Ti9V.d.ts} +1 -1
- package/dist/icon.d.ts +2 -2
- package/dist/icon.js +1 -1
- package/dist/icons.d.ts +20 -2
- package/dist/icons.js +1 -1
- package/dist/icons.js.map +1 -1
- package/dist/input.d.ts +3 -3
- package/dist/input.js +1 -1
- package/dist/input.js.map +1 -1
- package/dist/label.d.ts +1 -1
- package/dist/label.js.map +1 -1
- package/dist/media-object.d.ts +3 -3
- package/dist/media-object.js +1 -1
- package/dist/media-object.js.map +1 -1
- package/dist/pagination.d.ts +6 -6
- package/dist/pagination.js +1 -1
- package/dist/pagination.js.map +1 -1
- package/dist/popover.d.ts +5 -5
- package/dist/popover.js.map +1 -1
- package/dist/radio-group.d.ts +11 -11
- package/dist/radio-group.js +1 -1
- package/dist/radio-group.js.map +1 -1
- package/dist/sandboxed-on-click.d.ts +2 -2
- package/dist/sandboxed-on-click.js +1 -1
- package/dist/sandboxed-on-click.js.map +1 -1
- package/dist/select.d.ts +8 -8
- package/dist/select.js +1 -1
- package/dist/separator.d.ts +2 -2
- package/dist/separator.js +1 -1
- package/dist/sheet.d.ts +13 -13
- package/dist/sheet.js +1 -1
- package/dist/sheet.js.map +1 -1
- package/dist/skeleton.d.ts +1 -1
- package/dist/skeleton.js +1 -1
- package/dist/skeleton.js.map +1 -1
- package/dist/slider.d.ts +75 -0
- package/dist/slider.js +2 -0
- package/dist/slider.js.map +1 -0
- package/dist/slot.d.ts +1 -1
- package/dist/slot.js +1 -1
- package/dist/split-button.d.ts +8 -8
- package/dist/split-button.js +1 -1
- package/dist/split-button.js.map +1 -1
- package/dist/{svg-only-Bj2yffO4.d.ts → svg-only-Cp8Mu_sh.d.ts} +1 -1
- package/dist/switch.d.ts +1 -1
- package/dist/switch.js.map +1 -1
- package/dist/table.d.ts +9 -9
- package/dist/table.js +1 -1
- package/dist/tabs.d.ts +5 -5
- package/dist/tabs.js.map +1 -1
- package/dist/text-area.d.ts +1 -1
- package/dist/text-area.js.map +1 -1
- package/dist/theme.d.ts +28 -2
- package/dist/theme.js +1 -1
- package/dist/toast.d.ts +7 -7
- package/dist/toast.js +1 -1
- package/dist/tooltip.d.ts +6 -6
- package/dist/tooltip.js.map +1 -1
- package/package.json +11 -12
- package/dist/auto-scroll-to-hash.d.ts +0 -70
- package/dist/auto-scroll-to-hash.js +0 -2
- package/dist/auto-scroll-to-hash.js.map +0 -1
- package/dist/chunk-3ESTDWHQ.js.map +0 -1
- package/dist/chunk-5M264XXH.js.map +0 -1
- package/dist/chunk-73DPYKW5.js.map +0 -1
- package/dist/chunk-KVXXQCAI.js.map +0 -1
- package/dist/chunk-LURP5WQR.js.map +0 -1
- package/dist/chunk-NZ6DRFAL.js.map +0 -1
- package/dist/chunk-ODDNPNLN.js +0 -2
- package/dist/chunk-ODDNPNLN.js.map +0 -1
- package/dist/chunk-SBVSECWW.js.map +0 -1
- package/dist/chunk-SMYI7SUP.js +0 -2
- package/dist/chunk-SMYI7SUP.js.map +0 -1
- package/dist/chunk-TS7XNZ62.js.map +0 -1
- package/dist/chunk-ZYMZVPDT.js +0 -2
- package/dist/chunk-ZYMZVPDT.js.map +0 -1
- /package/dist/{chunk-NQZYWYVH.js.map → chunk-ELZLLG6G.js.map} +0 -0
package/dist/separator.d.ts
CHANGED
|
@@ -9,7 +9,7 @@ type Orientation = (typeof orientations)[number];
|
|
|
9
9
|
* A container to layout a group of horizontal separators and other children.
|
|
10
10
|
* Overrides all children `Separator`s to be `orientation="horizontal"`.
|
|
11
11
|
*
|
|
12
|
-
* @see https://mantle.ngrok.com/components/separator
|
|
12
|
+
* @see https://mantle.ngrok.com/components/separator
|
|
13
13
|
*
|
|
14
14
|
* @example
|
|
15
15
|
* ```tsx
|
|
@@ -53,7 +53,7 @@ type SeparatorProps = ComponentProps<"div"> & WithAsChild & {
|
|
|
53
53
|
/**
|
|
54
54
|
* Visually or semantically separates content.
|
|
55
55
|
*
|
|
56
|
-
* @see https://mantle.ngrok.com/components/separator
|
|
56
|
+
* @see https://mantle.ngrok.com/components/separator
|
|
57
57
|
*
|
|
58
58
|
* @example
|
|
59
59
|
* ```tsx
|
package/dist/separator.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as r,b as o}from"./chunk-
|
|
1
|
+
import{a as r,b as o}from"./chunk-MLXONRJD.js";import"./chunk-ADF5DAYG.js";import"./chunk-PFXFESEN.js";export{r as HorizontalSeparatorGroup,o as Separator};
|
|
2
2
|
//# sourceMappingURL=separator.js.map
|
package/dist/sheet.d.ts
CHANGED
|
@@ -4,7 +4,7 @@ import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
|
4
4
|
import * as react from 'react';
|
|
5
5
|
import { HTMLAttributes } from 'react';
|
|
6
6
|
import { VariantProps } from 'class-variance-authority';
|
|
7
|
-
import { a as IconButtonProps } from './icon-button-
|
|
7
|
+
import { a as IconButtonProps } from './icon-button-CT71Ti9V.js';
|
|
8
8
|
import { R as Root } from './primitive-CBR_XmVa.js';
|
|
9
9
|
import './as-child-DJ7x3JFV.js';
|
|
10
10
|
import './variant-props-oDo2u-We.js';
|
|
@@ -114,7 +114,7 @@ declare const Sheet: {
|
|
|
114
114
|
* The root component for a `Sheet`. Should compose the `Sheet.Trigger` and `Sheet.Content`.
|
|
115
115
|
* Acts as a stateful provider for the Sheet's open/closed state.
|
|
116
116
|
*
|
|
117
|
-
* @see https://mantle.ngrok.com/components/sheet#
|
|
117
|
+
* @see https://mantle.ngrok.com/components/sheet#sheetroot
|
|
118
118
|
*
|
|
119
119
|
* @example
|
|
120
120
|
* ```tsx
|
|
@@ -142,7 +142,7 @@ declare const Sheet: {
|
|
|
142
142
|
/**
|
|
143
143
|
* A group container for the actions of a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.
|
|
144
144
|
*
|
|
145
|
-
* @see https://mantle.ngrok.com/components/sheet#
|
|
145
|
+
* @see https://mantle.ngrok.com/components/sheet#sheetactions
|
|
146
146
|
*
|
|
147
147
|
* @example
|
|
148
148
|
* ```tsx
|
|
@@ -159,7 +159,7 @@ declare const Sheet: {
|
|
|
159
159
|
* The body container for a `Sheet`. This is where you would typically place the main content of the sheet, such as forms or text.
|
|
160
160
|
* Should be rendered as a child of `Sheet.Content`.
|
|
161
161
|
*
|
|
162
|
-
* @see https://mantle.ngrok.com/components/sheet#
|
|
162
|
+
* @see https://mantle.ngrok.com/components/sheet#sheetbody
|
|
163
163
|
*
|
|
164
164
|
* @example
|
|
165
165
|
* ```tsx
|
|
@@ -187,7 +187,7 @@ declare const Sheet: {
|
|
|
187
187
|
* Usually contained within the `Sheet.Footer` component.
|
|
188
188
|
* Renders an unstyled button by default, but can be customized with the `asChild` prop.
|
|
189
189
|
*
|
|
190
|
-
* @see https://mantle.ngrok.com/components/sheet#
|
|
190
|
+
* @see https://mantle.ngrok.com/components/sheet#sheetclose
|
|
191
191
|
*
|
|
192
192
|
* @example
|
|
193
193
|
* ```tsx
|
|
@@ -203,7 +203,7 @@ declare const Sheet: {
|
|
|
203
203
|
* An icon button that closes the `Sheet` when clicked.
|
|
204
204
|
* Should be rendered within the `Sheet.Header` as a child of `Sheet.Actions`.
|
|
205
205
|
*
|
|
206
|
-
* @see https://mantle.ngrok.com/components/sheet#
|
|
206
|
+
* @see https://mantle.ngrok.com/components/sheet#sheetcloseiconbutton
|
|
207
207
|
*
|
|
208
208
|
* @example
|
|
209
209
|
* ```tsx
|
|
@@ -226,7 +226,7 @@ declare const Sheet: {
|
|
|
226
226
|
* Renders on top of the overlay backdrop.
|
|
227
227
|
* Should contain the `Sheet.Header`, `Sheet.Body`, and `Sheet.Footer`.
|
|
228
228
|
*
|
|
229
|
-
* @see https://mantle.ngrok.com/components/sheet#
|
|
229
|
+
* @see https://mantle.ngrok.com/components/sheet#sheetcontent
|
|
230
230
|
*
|
|
231
231
|
* @example
|
|
232
232
|
* ```tsx
|
|
@@ -269,7 +269,7 @@ declare const Sheet: {
|
|
|
269
269
|
/**
|
|
270
270
|
* A description for a sheet. Typically rendered as a child of `Sheet.Header`.
|
|
271
271
|
*
|
|
272
|
-
* @see https://mantle.ngrok.com/components/sheet#
|
|
272
|
+
* @see https://mantle.ngrok.com/components/sheet#sheetdescription
|
|
273
273
|
*
|
|
274
274
|
* @example
|
|
275
275
|
* ```tsx
|
|
@@ -291,7 +291,7 @@ declare const Sheet: {
|
|
|
291
291
|
* The footer container for a `Sheet`. This is where you would typically place close and submit buttons.
|
|
292
292
|
* Should be rendered as a child of `Sheet.Content`.
|
|
293
293
|
*
|
|
294
|
-
* @see https://mantle.ngrok.com/components/sheet#
|
|
294
|
+
* @see https://mantle.ngrok.com/components/sheet#sheetfooter
|
|
295
295
|
*
|
|
296
296
|
* @example
|
|
297
297
|
* ```tsx
|
|
@@ -326,7 +326,7 @@ declare const Sheet: {
|
|
|
326
326
|
* The header container for a `Sheet`. This is where you would typically place the title, description, and actions.
|
|
327
327
|
* Should be rendered as a child of `Sheet.Content`.
|
|
328
328
|
*
|
|
329
|
-
* @see https://mantle.ngrok.com/components/sheet#
|
|
329
|
+
* @see https://mantle.ngrok.com/components/sheet#sheetheader
|
|
330
330
|
*
|
|
331
331
|
* @example
|
|
332
332
|
* ```tsx
|
|
@@ -353,7 +353,7 @@ declare const Sheet: {
|
|
|
353
353
|
* The title for a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.
|
|
354
354
|
* Defaults to an `h2` element, but can be changed via the `asChild` prop.
|
|
355
355
|
*
|
|
356
|
-
* @see https://mantle.ngrok.com/components/sheet#
|
|
356
|
+
* @see https://mantle.ngrok.com/components/sheet#sheettitle
|
|
357
357
|
*
|
|
358
358
|
* @example
|
|
359
359
|
* ```tsx
|
|
@@ -371,7 +371,7 @@ declare const Sheet: {
|
|
|
371
371
|
/**
|
|
372
372
|
* A group container for the title and actions of a sheet. Typically rendered as a child of `Sheet.Header`.
|
|
373
373
|
*
|
|
374
|
-
* @see https://mantle.ngrok.com/components/sheet#
|
|
374
|
+
* @see https://mantle.ngrok.com/components/sheet#sheettitlegroup
|
|
375
375
|
*
|
|
376
376
|
* @example
|
|
377
377
|
* ```tsx
|
|
@@ -390,7 +390,7 @@ declare const Sheet: {
|
|
|
390
390
|
* The button trigger for a `Sheet`. Should be rendered as a child of the `Sheet` component.
|
|
391
391
|
* Renders an unstyled button by default, but can be customized with the `asChild` prop.
|
|
392
392
|
*
|
|
393
|
-
* @see https://mantle.ngrok.com/components/sheet#
|
|
393
|
+
* @see https://mantle.ngrok.com/components/sheet#sheettrigger
|
|
394
394
|
*
|
|
395
395
|
* @example
|
|
396
396
|
* ```tsx
|
package/dist/sheet.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as u,b as v,c as S,d as m,e as p,f as d,g as h,h as f}from"./chunk-
|
|
1
|
+
import{a as u,b as v,c as S,d as m,e as p,f as d,g as h,h as f}from"./chunk-ELZLLG6G.js";import{d as c}from"./chunk-5XDZE2OU.js";import"./chunk-LB366VCO.js";import"./chunk-6J7D73WA.js";import"./chunk-NJNFZ2EG.js";import"./chunk-KMNACVH6.js";import{c as y}from"./chunk-CBRSMQ26.js";import"./chunk-63ZAW25Z.js";import"./chunk-72TJUKMV.js";import"./chunk-OP6JMBKJ.js";import"./chunk-IVQ626TU.js";import"./chunk-ADF5DAYG.js";import"./chunk-SBQHQ2SJ.js";import{a}from"./chunk-PFXFESEN.js";import{XIcon as W}from"@phosphor-icons/react/X";import{cva as E}from"class-variance-authority";import{forwardRef as s}from"react";import{jsx as o,jsxs as z}from"react/jsx-runtime";var P=u;P.displayName="Sheet";var C=v;C.displayName="SheetTrigger";var g=m;g.displayName="SheetClose";var N=S;N.displayName="SheetPortal";var b=s(({className:e,...t},i)=>o(p,{className:a("bg-overlay data-state-closed:animate-out data-state-closed:fade-out-0 data-state-open:animate-in data-state-open:fade-in-0 fixed inset-0 z-40 backdrop-blur-xs",e),...t,ref:i}));b.displayName=p.displayName;var V=E("bg-dialog border-dialog inset-y-0 h-full w-full fixed z-40 flex flex-col shadow-lg outline-hidden transition ease-in-out focus-within:outline-hidden data-state-closed:duration-100 data-state-closed:animate-out data-state-open:duration-100 data-state-open:animate-in",{variants:{side:{left:"data-state-closed:slide-out-to-left data-state-open:slide-in-from-left left-0 border-r",right:"data-state-closed:slide-out-to-right data-state-open:slide-in-from-right right-0 border-l"}},defaultVariants:{side:"right"}}),x=s(({children:e,className:t,onInteractOutside:i,onPointerDownOutside:r,preferredWidth:l="sm:max-w-[30rem]",side:B="right",...O},A)=>z(N,{children:[o(b,{}),o(d,{className:a(V({side:B}),l,t),onInteractOutside:n=>{c(n),i?.(n)},onPointerDownOutside:n=>{c(n),r?.(n)},ref:A,...O,children:e})]}));x.displayName=d.displayName;var T=({size:e="md",type:t="button",label:i="Close Sheet",appearance:r="ghost",...l})=>o(m,{asChild:!0,children:o(y,{appearance:r,icon:o(W,{}),label:i,size:e,type:t,...l})});T.displayName="SheetCloseIconButton";var R=({className:e,...t})=>o("div",{className:a("scrollbar text-body flex-1 overflow-y-auto p-6",e),...t});R.displayName="SheetBody";var H=({className:e,...t})=>o("div",{className:a("border-dialog-muted flex shrink-0 flex-col gap-2 border-b py-4 pl-6 pr-4","has-[.icon-button]:pr-4",e),...t});H.displayName="SheetHeader";var D=({className:e,...t})=>o("div",{className:a("border-dialog-muted flex shrink-0 justify-end gap-2 border-t px-6 py-2.5",e),...t});D.displayName="SheetFooter";var L=s(({className:e,...t},i)=>o(h,{ref:i,className:a("text-strong flex-1 truncate text-lg font-medium",e),...t}));L.displayName=h.displayName;var M=s(({children:e,className:t,...i},r)=>o("div",{className:a("flex items-center justify-between gap-2",t),...i,ref:r,children:e}));M.displayName="SheetTitleGroup";var I=s(({className:e,...t},i)=>o(f,{ref:i,className:a("text-body text-sm",e),...t}));I.displayName=f.displayName;var w=s(({children:e,className:t,...i},r)=>o("div",{className:a("flex h-full items-center gap-2",t),...i,ref:r,children:e}));w.displayName="SheetActions";var k={Root:P,Actions:w,Body:R,Close:g,CloseIconButton:T,Content:x,Description:I,Footer:D,Header:H,Title:L,TitleGroup:M,Trigger:C};export{k as Sheet};
|
|
2
2
|
//# sourceMappingURL=sheet.js.map
|
package/dist/sheet.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/components/sheet/sheet.tsx"],"sourcesContent":["import { XIcon } from \"@phosphor-icons/react/X\";\nimport { type VariantProps, cva } from \"class-variance-authority\";\nimport type { ComponentPropsWithoutRef, ComponentRef, HTMLAttributes } from \"react\";\nimport { forwardRef } from \"react\";\nimport { cx } from \"../../utils/cx/cx.js\";\nimport { IconButton, type IconButtonProps } from \"../button/icon-button.js\";\nimport * as SheetPrimitive from \"../dialog/primitive.js\";\nimport { preventCloseOnPromptInteraction } from \"../toast/toast.js\";\n\n/**\n * The root component for a `Sheet`. Should compose the `Sheet.Trigger` and `Sheet.Content`.\n * Acts as a stateful provider for the Sheet's open/closed state.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet\n *\n * @example\n * ```tsx\n * // Triggering a stateful sheet\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Root = SheetPrimitive.Root;\nRoot.displayName = \"Sheet\";\n\n/**\n * The button trigger for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-trigger\n *\n * @example\n * ```tsx\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Trigger = SheetPrimitive.Trigger;\nTrigger.displayName = \"SheetTrigger\";\n\n/**\n * The close button for a `Sheet`. Should be rendered as a child of the `Sheet.Content` component.\n * Usually contained within the `Sheet.Footer` component.\n * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-close\n *\n * @example\n * ```tsx\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Close = SheetPrimitive.Close;\nClose.displayName = \"SheetClose\";\n\n/**\n * The portal for a sheet. Should be rendered as a child of the `Sheet` component.\n * Renders a portal that the `SheetOverlay` and `Sheet.Content` is rendered into.\n *\n * @private\n */\nconst SheetPortal = SheetPrimitive.Portal;\nSheetPortal.displayName = \"SheetPortal\";\n\n/**\n * The overlay backdrop for a sheet. Should be rendered as a child of the `SheetPortal` component.\n *\n * You likely don't need to use this component directly, as it is used internally by the `Sheet.Content` component.\n *\n * @private\n */\nconst SheetOverlay = forwardRef<\n\tComponentRef<typeof SheetPrimitive.Overlay>,\n\tComponentPropsWithoutRef<typeof SheetPrimitive.Overlay>\n>(({ className, ...props }, ref) => (\n\t<SheetPrimitive.Overlay\n\t\tclassName={cx(\n\t\t\t\"bg-overlay data-state-closed:animate-out data-state-closed:fade-out-0 data-state-open:animate-in data-state-open:fade-in-0 fixed inset-0 z-40 backdrop-blur-xs\",\n\t\t\tclassName,\n\t\t)}\n\t\t{...props}\n\t\tref={ref}\n\t/>\n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst SheetVariants = cva(\n\t\"bg-dialog border-dialog inset-y-0 h-full w-full fixed z-40 flex flex-col shadow-lg outline-hidden transition ease-in-out focus-within:outline-hidden data-state-closed:duration-100 data-state-closed:animate-out data-state-open:duration-100 data-state-open:animate-in\",\n\t{\n\t\tvariants: {\n\t\t\t/**\n\t\t\t * The side of the screen the sheet should slide in from.\n\t\t\t */\n\t\t\tside: {\n\t\t\t\tleft: \"data-state-closed:slide-out-to-left data-state-open:slide-in-from-left left-0 border-r\",\n\t\t\t\tright:\n\t\t\t\t\t\"data-state-closed:slide-out-to-right data-state-open:slide-in-from-right right-0 border-l\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tside: \"right\",\n\t\t},\n\t},\n);\n\ntype SheetContentProps = ComponentPropsWithoutRef<typeof SheetPrimitive.Content> &\n\tVariantProps<typeof SheetVariants> & {\n\t\t/**\n\t\t * The preferred width of the `Sheet.Content` as a tailwind `max-w-` class.\n\t\t *\n\t\t * By default, a `Sheet`'s content width is responsive with a default\n\t\t * preferred width: the maximum width of the `Sheet.Content` when the window\n\t\t * viewport is larger than the mobile breakpoint (`sm`).\n\t\t *\n\t\t * @default `sm:max-w-[30rem]`\n\t\t */\n\t\tpreferredWidth?: `sm:max-w-${string}`;\n\t};\n\n/**\n * The main container for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n * Renders on top of the overlay backdrop.\n * Should contain the `Sheet.Header`, `Sheet.Body`, and `Sheet.Footer`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-content\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Content = forwardRef<ComponentRef<\"div\">, SheetContentProps>(\n\t(\n\t\t{\n\t\t\tchildren,\n\t\t\tclassName,\n\t\t\tonInteractOutside,\n\t\t\tonPointerDownOutside,\n\t\t\tpreferredWidth = \"sm:max-w-[30rem]\",\n\t\t\tside = \"right\",\n\t\t\t...props\n\t\t},\n\t\tref,\n\t) => (\n\t\t<SheetPortal>\n\t\t\t<SheetOverlay />\n\t\t\t<SheetPrimitive.Content\n\t\t\t\tclassName={cx(SheetVariants({ side }), preferredWidth, className)}\n\t\t\t\tonInteractOutside={(event) => {\n\t\t\t\t\tpreventCloseOnPromptInteraction(event);\n\t\t\t\t\tonInteractOutside?.(event);\n\t\t\t\t}}\n\t\t\t\tonPointerDownOutside={(event) => {\n\t\t\t\t\tpreventCloseOnPromptInteraction(event);\n\t\t\t\t\tonPointerDownOutside?.(event);\n\t\t\t\t}}\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</SheetPrimitive.Content>\n\t\t</SheetPortal>\n\t),\n);\nContent.displayName = SheetPrimitive.Content.displayName;\n\ntype SheetCloseIconButtonProps = Partial<Omit<IconButtonProps, \"icon\">>;\n\n/**\n * An icon button that closes the `Sheet` when clicked.\n * Should be rendered within the `Sheet.Header` as a child of `Sheet.Actions`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-close-icon-button\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst CloseIconButton = ({\n\tsize = \"md\",\n\ttype = \"button\",\n\tlabel = \"Close Sheet\",\n\tappearance = \"ghost\",\n\t...props\n}: SheetCloseIconButtonProps) => (\n\t<SheetPrimitive.Close asChild>\n\t\t<IconButton\n\t\t\tappearance={appearance}\n\t\t\ticon={<XIcon />}\n\t\t\tlabel={label}\n\t\t\tsize={size}\n\t\t\ttype={type}\n\t\t\t{...props}\n\t\t/>\n\t</SheetPrimitive.Close>\n);\nCloseIconButton.displayName = \"SheetCloseIconButton\";\n\n/**\n * The body container for a `Sheet`. This is where you would typically place the main content of the sheet, such as forms or text.\n * Should be rendered as a child of `Sheet.Content`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-body\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Body = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (\n\t<div className={cx(\"scrollbar text-body flex-1 overflow-y-auto p-6\", className)} {...props} />\n);\nBody.displayName = \"SheetBody\";\n\n/**\n * The header container for a `Sheet`. This is where you would typically place the title, description, and actions.\n * Should be rendered as a child of `Sheet.Content`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-header\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Header = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (\n\t<div\n\t\tclassName={cx(\n\t\t\t\"border-dialog-muted flex shrink-0 flex-col gap-2 border-b py-4 pl-6 pr-4\",\n\t\t\t\"has-[.icon-button]:pr-4\", // when there are actions in the header, shorten the padding\n\t\t\tclassName,\n\t\t)}\n\t\t{...props}\n\t/>\n);\nHeader.displayName = \"SheetHeader\";\n\n/**\n * The footer container for a `Sheet`. This is where you would typically place close and submit buttons.\n * Should be rendered as a child of `Sheet.Content`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-footer\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Footer = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (\n\t<div\n\t\tclassName={cx(\n\t\t\t\"border-dialog-muted flex shrink-0 justify-end gap-2 border-t px-6 py-2.5\",\n\t\t\tclassName,\n\t\t)}\n\t\t{...props}\n\t/>\n);\nFooter.displayName = \"SheetFooter\";\n\n/**\n * The title for a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n * Defaults to an `h2` element, but can be changed via the `asChild` prop.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-title\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Title = forwardRef<\n\tComponentRef<typeof SheetPrimitive.Title>,\n\tComponentPropsWithoutRef<typeof SheetPrimitive.Title>\n>(({ className, ...props }, ref) => (\n\t<SheetPrimitive.Title\n\t\tref={ref}\n\t\tclassName={cx(\"text-strong flex-1 truncate text-lg font-medium\", className)}\n\t\t{...props}\n\t/>\n));\nTitle.displayName = SheetPrimitive.Title.displayName;\n\n/**\n * A group container for the title and actions of a sheet. Typically rendered as a child of `Sheet.Header`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-title-group\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst TitleGroup = forwardRef<ComponentRef<\"div\">, HTMLAttributes<HTMLDivElement>>(\n\t({ children, className, ...props }, ref) => (\n\t\t<div className={cx(\"flex items-center justify-between gap-2\", className)} {...props} ref={ref}>\n\t\t\t{children}\n\t\t</div>\n\t),\n);\nTitleGroup.displayName = \"SheetTitleGroup\";\n\n/**\n * A description for a sheet. Typically rendered as a child of `Sheet.Header`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-description\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Description = forwardRef<\n\tComponentRef<typeof SheetPrimitive.Description>,\n\tComponentPropsWithoutRef<typeof SheetPrimitive.Description>\n>(({ className, ...props }, ref) => (\n\t<SheetPrimitive.Description ref={ref} className={cx(\"text-body text-sm\", className)} {...props} />\n));\nDescription.displayName = SheetPrimitive.Description.displayName;\n\n/**\n * A group container for the actions of a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n *\n * @see https://mantle.ngrok.com/components/sheet#api-sheet-actions\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Actions = forwardRef<ComponentRef<\"div\">, HTMLAttributes<HTMLDivElement>>(\n\t({ children, className, ...props }, ref) => (\n\t\t<div className={cx(\"flex h-full items-center gap-2\", className)} {...props} ref={ref}>\n\t\t\t{children}\n\t\t</div>\n\t),\n);\nActions.displayName = \"SheetActions\";\n\n/**\n * A container that overlays the current view from the edge of the screen.\n * It is a lightweight way of allowing users to complete a task without losing\n * contextual information of the view beneath it.\n *\n * @see https://mantle.ngrok.com/components/sheet\n *\n * @example\n * ```tsx\n * // Triggering a stateful sheet\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Sheet = {\n\t/**\n\t * The root component for a `Sheet`. Should compose the `Sheet.Trigger` and `Sheet.Content`.\n\t * Acts as a stateful provider for the Sheet's open/closed state.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet\n\t *\n\t * @example\n\t * ```tsx\n\t * // Triggering a stateful sheet\n\t * <Sheet.Root>\n\t * <Sheet.Trigger asChild>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Open Sheet\n\t * </Button>\n\t * </Sheet.Trigger>\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * </Sheet.Content>\n\t * </Sheet.Root>\n\t * ```\n\t */\n\tRoot,\n\t/**\n\t * A group container for the actions of a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-actions\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * ```\n\t */\n\tActions,\n\t/**\n\t * The body container for a `Sheet`. This is where you would typically place the main content of the sheet, such as forms or text.\n\t * Should be rendered as a child of `Sheet.Content`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-body\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * <Sheet.Body>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Body>\n\t * </Sheet.Content>\n\t * ```\n\t */\n\tBody,\n\t/**\n\t * The close button for a `Sheet`. Should be rendered as a child of the `Sheet.Content` component.\n\t * Usually contained within the `Sheet.Footer` component.\n\t * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-close\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Footer>\n\t * <Sheet.Close asChild>\n\t * <Button type=\"button\">Close</Button>\n\t * </Sheet.Close>\n\t * </Sheet.Footer>\n\t * ```\n\t */\n\tClose,\n\t/**\n\t * An icon button that closes the `Sheet` when clicked.\n\t * Should be rendered within the `Sheet.Header` as a child of `Sheet.Actions`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-close-icon-button\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tCloseIconButton,\n\t/**\n\t * The main container for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n\t * Renders on top of the overlay backdrop.\n\t * Should contain the `Sheet.Header`, `Sheet.Body`, and `Sheet.Footer`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-content\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Root>\n\t * <Sheet.Trigger asChild>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Open Sheet\n\t * </Button>\n\t * </Sheet.Trigger>\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * <Sheet.Body>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Body>\n\t * </Sheet.Content>\n\t * </Sheet.Root>\n\t * ```\n\t */\n\tContent,\n\t/**\n\t * A description for a sheet. Typically rendered as a child of `Sheet.Header`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-description\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * <Sheet.Description>\n\t * This action cannot be undone.\n\t * </Sheet.Description>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tDescription,\n\t/**\n\t * The footer container for a `Sheet`. This is where you would typically place close and submit buttons.\n\t * Should be rendered as a child of `Sheet.Content`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-footer\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * <Sheet.Body>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Body>\n\t * <Sheet.Footer>\n\t * <Sheet.Close asChild>\n\t * <Button type=\"button\">Close</Button>\n\t * </Sheet.Close>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Save\n\t * </Button>\n\t * </Sheet.Footer>\n\t * </Sheet.Content>\n\t * ```\n\t */\n\tFooter,\n\t/**\n\t * The header container for a `Sheet`. This is where you would typically place the title, description, and actions.\n\t * Should be rendered as a child of `Sheet.Content`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-header\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * <Sheet.Description>\n\t * This action cannot be undone.\n\t * </Sheet.Description>\n\t * </Sheet.Header>\n\t * </Sheet.Content>\n\t * ```\n\t */\n\tHeader,\n\t/**\n\t * The title for a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n\t * Defaults to an `h2` element, but can be changed via the `asChild` prop.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-title\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tTitle,\n\t/**\n\t * A group container for the title and actions of a sheet. Typically rendered as a child of `Sheet.Header`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-title-group\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tTitleGroup,\n\t/**\n\t * The button trigger for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n\t * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#api-sheet-trigger\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Root>\n\t * <Sheet.Trigger asChild>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Open Sheet\n\t * </Button>\n\t * </Sheet.Trigger>\n\t * <Sheet.Content>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Content>\n\t * </Sheet.Root>\n\t * ```\n\t */\n\tTrigger,\n} as const;\n\nexport {\n\t//,\n\tSheet,\n};\n"],"mappings":"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","names":["XIcon","cva","forwardRef","jsx","jsxs","Root","Trigger","Close","SheetPortal","Portal","SheetOverlay","forwardRef","className","props","ref","Overlay","cx","SheetVariants","cva","Content","children","onInteractOutside","onPointerDownOutside","preferredWidth","side","event","preventCloseOnPromptInteraction","CloseIconButton","size","type","label","appearance","IconButton","XIcon","Body","Header","Footer","Title","TitleGroup","Description","Actions","Sheet"]}
|
|
1
|
+
{"version":3,"sources":["../src/components/sheet/sheet.tsx"],"sourcesContent":["import { XIcon } from \"@phosphor-icons/react/X\";\nimport { type VariantProps, cva } from \"class-variance-authority\";\nimport type { ComponentPropsWithoutRef, ComponentRef, HTMLAttributes } from \"react\";\nimport { forwardRef } from \"react\";\nimport { cx } from \"../../utils/cx/cx.js\";\nimport { IconButton, type IconButtonProps } from \"../button/icon-button.js\";\nimport * as SheetPrimitive from \"../dialog/primitive.js\";\nimport { preventCloseOnPromptInteraction } from \"../toast/toast.js\";\n\n/**\n * The root component for a `Sheet`. Should compose the `Sheet.Trigger` and `Sheet.Content`.\n * Acts as a stateful provider for the Sheet's open/closed state.\n *\n * @see https://mantle.ngrok.com/components/sheet#sheetroot\n *\n * @example\n * ```tsx\n * // Triggering a stateful sheet\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Root = SheetPrimitive.Root;\nRoot.displayName = \"Sheet\";\n\n/**\n * The button trigger for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n *\n * @see https://mantle.ngrok.com/components/sheet#sheettrigger\n *\n * @example\n * ```tsx\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Trigger = SheetPrimitive.Trigger;\nTrigger.displayName = \"SheetTrigger\";\n\n/**\n * The close button for a `Sheet`. Should be rendered as a child of the `Sheet.Content` component.\n * Usually contained within the `Sheet.Footer` component.\n * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n *\n * @see https://mantle.ngrok.com/components/sheet#sheetclose\n *\n * @example\n * ```tsx\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Close = SheetPrimitive.Close;\nClose.displayName = \"SheetClose\";\n\n/**\n * The portal for a sheet. Should be rendered as a child of the `Sheet` component.\n * Renders a portal that the `SheetOverlay` and `Sheet.Content` is rendered into.\n *\n * @private\n */\nconst SheetPortal = SheetPrimitive.Portal;\nSheetPortal.displayName = \"SheetPortal\";\n\n/**\n * The overlay backdrop for a sheet. Should be rendered as a child of the `SheetPortal` component.\n *\n * You likely don't need to use this component directly, as it is used internally by the `Sheet.Content` component.\n *\n * @private\n */\nconst SheetOverlay = forwardRef<\n\tComponentRef<typeof SheetPrimitive.Overlay>,\n\tComponentPropsWithoutRef<typeof SheetPrimitive.Overlay>\n>(({ className, ...props }, ref) => (\n\t<SheetPrimitive.Overlay\n\t\tclassName={cx(\n\t\t\t\"bg-overlay data-state-closed:animate-out data-state-closed:fade-out-0 data-state-open:animate-in data-state-open:fade-in-0 fixed inset-0 z-40 backdrop-blur-xs\",\n\t\t\tclassName,\n\t\t)}\n\t\t{...props}\n\t\tref={ref}\n\t/>\n));\nSheetOverlay.displayName = SheetPrimitive.Overlay.displayName;\n\nconst SheetVariants = cva(\n\t\"bg-dialog border-dialog inset-y-0 h-full w-full fixed z-40 flex flex-col shadow-lg outline-hidden transition ease-in-out focus-within:outline-hidden data-state-closed:duration-100 data-state-closed:animate-out data-state-open:duration-100 data-state-open:animate-in\",\n\t{\n\t\tvariants: {\n\t\t\t/**\n\t\t\t * The side of the screen the sheet should slide in from.\n\t\t\t */\n\t\t\tside: {\n\t\t\t\tleft: \"data-state-closed:slide-out-to-left data-state-open:slide-in-from-left left-0 border-r\",\n\t\t\t\tright:\n\t\t\t\t\t\"data-state-closed:slide-out-to-right data-state-open:slide-in-from-right right-0 border-l\",\n\t\t\t},\n\t\t},\n\t\tdefaultVariants: {\n\t\t\tside: \"right\",\n\t\t},\n\t},\n);\n\ntype SheetContentProps = ComponentPropsWithoutRef<typeof SheetPrimitive.Content> &\n\tVariantProps<typeof SheetVariants> & {\n\t\t/**\n\t\t * The preferred width of the `Sheet.Content` as a tailwind `max-w-` class.\n\t\t *\n\t\t * By default, a `Sheet`'s content width is responsive with a default\n\t\t * preferred width: the maximum width of the `Sheet.Content` when the window\n\t\t * viewport is larger than the mobile breakpoint (`sm`).\n\t\t *\n\t\t * @default `sm:max-w-[30rem]`\n\t\t */\n\t\tpreferredWidth?: `sm:max-w-${string}`;\n\t};\n\n/**\n * The main container for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n * Renders on top of the overlay backdrop.\n * Should contain the `Sheet.Header`, `Sheet.Body`, and `Sheet.Footer`.\n *\n * @see https://mantle.ngrok.com/components/sheet#sheetcontent\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Content = forwardRef<ComponentRef<\"div\">, SheetContentProps>(\n\t(\n\t\t{\n\t\t\tchildren,\n\t\t\tclassName,\n\t\t\tonInteractOutside,\n\t\t\tonPointerDownOutside,\n\t\t\tpreferredWidth = \"sm:max-w-[30rem]\",\n\t\t\tside = \"right\",\n\t\t\t...props\n\t\t},\n\t\tref,\n\t) => (\n\t\t<SheetPortal>\n\t\t\t<SheetOverlay />\n\t\t\t<SheetPrimitive.Content\n\t\t\t\tclassName={cx(SheetVariants({ side }), preferredWidth, className)}\n\t\t\t\tonInteractOutside={(event) => {\n\t\t\t\t\tpreventCloseOnPromptInteraction(event);\n\t\t\t\t\tonInteractOutside?.(event);\n\t\t\t\t}}\n\t\t\t\tonPointerDownOutside={(event) => {\n\t\t\t\t\tpreventCloseOnPromptInteraction(event);\n\t\t\t\t\tonPointerDownOutside?.(event);\n\t\t\t\t}}\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t>\n\t\t\t\t{children}\n\t\t\t</SheetPrimitive.Content>\n\t\t</SheetPortal>\n\t),\n);\nContent.displayName = SheetPrimitive.Content.displayName;\n\ntype SheetCloseIconButtonProps = Partial<Omit<IconButtonProps, \"icon\">>;\n\n/**\n * An icon button that closes the `Sheet` when clicked.\n * Should be rendered within the `Sheet.Header` as a child of `Sheet.Actions`.\n *\n * @see https://mantle.ngrok.com/components/sheet#sheetcloseiconbutton\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst CloseIconButton = ({\n\tsize = \"md\",\n\ttype = \"button\",\n\tlabel = \"Close Sheet\",\n\tappearance = \"ghost\",\n\t...props\n}: SheetCloseIconButtonProps) => (\n\t<SheetPrimitive.Close asChild>\n\t\t<IconButton\n\t\t\tappearance={appearance}\n\t\t\ticon={<XIcon />}\n\t\t\tlabel={label}\n\t\t\tsize={size}\n\t\t\ttype={type}\n\t\t\t{...props}\n\t\t/>\n\t</SheetPrimitive.Close>\n);\nCloseIconButton.displayName = \"SheetCloseIconButton\";\n\n/**\n * The body container for a `Sheet`. This is where you would typically place the main content of the sheet, such as forms or text.\n * Should be rendered as a child of `Sheet.Content`.\n *\n * @see https://mantle.ngrok.com/components/sheet#sheetbody\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Body = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (\n\t<div className={cx(\"scrollbar text-body flex-1 overflow-y-auto p-6\", className)} {...props} />\n);\nBody.displayName = \"SheetBody\";\n\n/**\n * The header container for a `Sheet`. This is where you would typically place the title, description, and actions.\n * Should be rendered as a child of `Sheet.Content`.\n *\n * @see https://mantle.ngrok.com/components/sheet#sheetheader\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Header = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (\n\t<div\n\t\tclassName={cx(\n\t\t\t\"border-dialog-muted flex shrink-0 flex-col gap-2 border-b py-4 pl-6 pr-4\",\n\t\t\t\"has-[.icon-button]:pr-4\", // when there are actions in the header, shorten the padding\n\t\t\tclassName,\n\t\t)}\n\t\t{...props}\n\t/>\n);\nHeader.displayName = \"SheetHeader\";\n\n/**\n * The footer container for a `Sheet`. This is where you would typically place close and submit buttons.\n * Should be rendered as a child of `Sheet.Content`.\n *\n * @see https://mantle.ngrok.com/components/sheet#sheetfooter\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Footer = ({ className, ...props }: HTMLAttributes<HTMLDivElement>) => (\n\t<div\n\t\tclassName={cx(\n\t\t\t\"border-dialog-muted flex shrink-0 justify-end gap-2 border-t px-6 py-2.5\",\n\t\t\tclassName,\n\t\t)}\n\t\t{...props}\n\t/>\n);\nFooter.displayName = \"SheetFooter\";\n\n/**\n * The title for a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n * Defaults to an `h2` element, but can be changed via the `asChild` prop.\n *\n * @see https://mantle.ngrok.com/components/sheet#sheettitle\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Title = forwardRef<\n\tComponentRef<typeof SheetPrimitive.Title>,\n\tComponentPropsWithoutRef<typeof SheetPrimitive.Title>\n>(({ className, ...props }, ref) => (\n\t<SheetPrimitive.Title\n\t\tref={ref}\n\t\tclassName={cx(\"text-strong flex-1 truncate text-lg font-medium\", className)}\n\t\t{...props}\n\t/>\n));\nTitle.displayName = SheetPrimitive.Title.displayName;\n\n/**\n * A group container for the title and actions of a sheet. Typically rendered as a child of `Sheet.Header`.\n *\n * @see https://mantle.ngrok.com/components/sheet#sheettitlegroup\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst TitleGroup = forwardRef<ComponentRef<\"div\">, HTMLAttributes<HTMLDivElement>>(\n\t({ children, className, ...props }, ref) => (\n\t\t<div className={cx(\"flex items-center justify-between gap-2\", className)} {...props} ref={ref}>\n\t\t\t{children}\n\t\t</div>\n\t),\n);\nTitleGroup.displayName = \"SheetTitleGroup\";\n\n/**\n * A description for a sheet. Typically rendered as a child of `Sheet.Header`.\n *\n * @see https://mantle.ngrok.com/components/sheet#sheetdescription\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Description = forwardRef<\n\tComponentRef<typeof SheetPrimitive.Description>,\n\tComponentPropsWithoutRef<typeof SheetPrimitive.Description>\n>(({ className, ...props }, ref) => (\n\t<SheetPrimitive.Description ref={ref} className={cx(\"text-body text-sm\", className)} {...props} />\n));\nDescription.displayName = SheetPrimitive.Description.displayName;\n\n/**\n * A group container for the actions of a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n *\n * @see https://mantle.ngrok.com/components/sheet#sheetactions\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Actions = forwardRef<ComponentRef<\"div\">, HTMLAttributes<HTMLDivElement>>(\n\t({ children, className, ...props }, ref) => (\n\t\t<div className={cx(\"flex h-full items-center gap-2\", className)} {...props} ref={ref}>\n\t\t\t{children}\n\t\t</div>\n\t),\n);\nActions.displayName = \"SheetActions\";\n\n/**\n * A container that overlays the current view from the edge of the screen.\n * It is a lightweight way of allowing users to complete a task without losing\n * contextual information of the view beneath it.\n *\n * @see https://mantle.ngrok.com/components/sheet\n *\n * @example\n * ```tsx\n * // Triggering a stateful sheet\n * <Sheet.Root>\n * <Sheet.Trigger asChild>\n * <Button type=\"button\" appearance=\"filled\">\n * Open Sheet\n * </Button>\n * </Sheet.Trigger>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n *\n * @example\n * ```tsx\n * // Sheet without a trigger (e.g. router controlled)\n * <Sheet open opOpenChange={() => onClose()}>\n * <Sheet.Content>\n * <Sheet.Header>\n * <Sheet.TitleGroup>\n * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n * <Sheet.Actions>\n * <IconButton\n * appearance=\"ghost\"\n * type=\"button\"\n * icon={<TrashSimple />}\n * label=\"Delete\"\n * />\n * <Separator orientation=\"vertical\" className=\"h-[80%]\" />\n * <Sheet.CloseIconButton />\n * </Sheet.Actions>\n * </Sheet.TitleGroup>\n * <Sheet.Description>\n * This action cannot be undone. This will permanently delete your account and remove your data from our servers.\n * </Sheet.Description>\n * </Sheet.Header>\n * <Sheet.Body>\n * <p>\n * Consequat do voluptate culpa fugiat consequat nostrud duis\n * aliqua minim. Tempor voluptate cillum elit velit. Voluptate\n * aliqua ipsum aliqua dolore in nisi ea fugiat aliqua velit\n * proident amet.\n * </p>\n * </Sheet.Body>\n * <Sheet.Footer>\n * <Sheet.Close asChild>\n * <Button type=\"button\">Close</Button>\n * </Sheet.Close>\n * <Button type=\"button\" appearance=\"filled\">\n * Save\n * </Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet.Root>\n * ```\n */\nconst Sheet = {\n\t/**\n\t * The root component for a `Sheet`. Should compose the `Sheet.Trigger` and `Sheet.Content`.\n\t * Acts as a stateful provider for the Sheet's open/closed state.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#sheetroot\n\t *\n\t * @example\n\t * ```tsx\n\t * // Triggering a stateful sheet\n\t * <Sheet.Root>\n\t * <Sheet.Trigger asChild>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Open Sheet\n\t * </Button>\n\t * </Sheet.Trigger>\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * </Sheet.Content>\n\t * </Sheet.Root>\n\t * ```\n\t */\n\tRoot,\n\t/**\n\t * A group container for the actions of a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#sheetactions\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Are you absolutely sure?</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * ```\n\t */\n\tActions,\n\t/**\n\t * The body container for a `Sheet`. This is where you would typically place the main content of the sheet, such as forms or text.\n\t * Should be rendered as a child of `Sheet.Content`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#sheetbody\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * <Sheet.Body>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Body>\n\t * </Sheet.Content>\n\t * ```\n\t */\n\tBody,\n\t/**\n\t * The close button for a `Sheet`. Should be rendered as a child of the `Sheet.Content` component.\n\t * Usually contained within the `Sheet.Footer` component.\n\t * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#sheetclose\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Footer>\n\t * <Sheet.Close asChild>\n\t * <Button type=\"button\">Close</Button>\n\t * </Sheet.Close>\n\t * </Sheet.Footer>\n\t * ```\n\t */\n\tClose,\n\t/**\n\t * An icon button that closes the `Sheet` when clicked.\n\t * Should be rendered within the `Sheet.Header` as a child of `Sheet.Actions`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#sheetcloseiconbutton\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tCloseIconButton,\n\t/**\n\t * The main container for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n\t * Renders on top of the overlay backdrop.\n\t * Should contain the `Sheet.Header`, `Sheet.Body`, and `Sheet.Footer`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#sheetcontent\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Root>\n\t * <Sheet.Trigger asChild>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Open Sheet\n\t * </Button>\n\t * </Sheet.Trigger>\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * <Sheet.Body>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Body>\n\t * </Sheet.Content>\n\t * </Sheet.Root>\n\t * ```\n\t */\n\tContent,\n\t/**\n\t * A description for a sheet. Typically rendered as a child of `Sheet.Header`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#sheetdescription\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * <Sheet.Description>\n\t * This action cannot be undone.\n\t * </Sheet.Description>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tDescription,\n\t/**\n\t * The footer container for a `Sheet`. This is where you would typically place close and submit buttons.\n\t * Should be rendered as a child of `Sheet.Content`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#sheetfooter\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * <Sheet.Body>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Body>\n\t * <Sheet.Footer>\n\t * <Sheet.Close asChild>\n\t * <Button type=\"button\">Close</Button>\n\t * </Sheet.Close>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Save\n\t * </Button>\n\t * </Sheet.Footer>\n\t * </Sheet.Content>\n\t * ```\n\t */\n\tFooter,\n\t/**\n\t * The header container for a `Sheet`. This is where you would typically place the title, description, and actions.\n\t * Should be rendered as a child of `Sheet.Content`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#sheetheader\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Content>\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * <Sheet.Description>\n\t * This action cannot be undone.\n\t * </Sheet.Description>\n\t * </Sheet.Header>\n\t * </Sheet.Content>\n\t * ```\n\t */\n\tHeader,\n\t/**\n\t * The title for a `Sheet`. Typically rendered as a child of `Sheet.TitleGroup`.\n\t * Defaults to an `h2` element, but can be changed via the `asChild` prop.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#sheettitle\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tTitle,\n\t/**\n\t * A group container for the title and actions of a sheet. Typically rendered as a child of `Sheet.Header`.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#sheettitlegroup\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Header>\n\t * <Sheet.TitleGroup>\n\t * <Sheet.Title>Sheet Title</Sheet.Title>\n\t * <Sheet.Actions>\n\t * <Sheet.CloseIconButton />\n\t * </Sheet.Actions>\n\t * </Sheet.TitleGroup>\n\t * </Sheet.Header>\n\t * ```\n\t */\n\tTitleGroup,\n\t/**\n\t * The button trigger for a `Sheet`. Should be rendered as a child of the `Sheet` component.\n\t * Renders an unstyled button by default, but can be customized with the `asChild` prop.\n\t *\n\t * @see https://mantle.ngrok.com/components/sheet#sheettrigger\n\t *\n\t * @example\n\t * ```tsx\n\t * <Sheet.Root>\n\t * <Sheet.Trigger asChild>\n\t * <Button type=\"button\" appearance=\"filled\">\n\t * Open Sheet\n\t * </Button>\n\t * </Sheet.Trigger>\n\t * <Sheet.Content>\n\t * <p>This is the sheet content.</p>\n\t * </Sheet.Content>\n\t * </Sheet.Root>\n\t * ```\n\t */\n\tTrigger,\n} as const;\n\nexport {\n\t//,\n\tSheet,\n};\n"],"mappings":"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","names":["XIcon","cva","forwardRef","jsx","jsxs","Root","Trigger","Close","SheetPortal","Portal","SheetOverlay","forwardRef","className","props","ref","Overlay","cx","SheetVariants","cva","Content","children","onInteractOutside","onPointerDownOutside","preferredWidth","side","event","preventCloseOnPromptInteraction","CloseIconButton","size","type","label","appearance","IconButton","XIcon","Body","Header","Footer","Title","TitleGroup","Description","Actions","Sheet"]}
|
package/dist/skeleton.d.ts
CHANGED
package/dist/skeleton.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as e}from"./chunk-
|
|
1
|
+
import{a as e}from"./chunk-ADF5DAYG.js";import{a as o}from"./chunk-PFXFESEN.js";import{forwardRef as s}from"react";import{jsx as i}from"react/jsx-runtime";var t=s(({asChild:r=!1,className:n,...p},l)=>i(r?e:"div",{className:o("dark-high-contrast:bg-black/30 high-contrast:bg-black/30 h-4 animate-pulse rounded-md bg-gray-300/25 dark:bg-gray-950/10",n),ref:l,...p}));t.displayName="Skeleton";export{t as Skeleton};
|
|
2
2
|
//# sourceMappingURL=skeleton.js.map
|
package/dist/skeleton.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/components/skeleton/skeleton.tsx"],"sourcesContent":["import { type ComponentProps, type ComponentRef, forwardRef } from \"react\";\nimport type { SelfClosingWithAsChild } from \"../../types/as-child.js\";\nimport { cx } from \"../../utils/cx/cx.js\";\nimport { Slot } from \"../slot/index.js\";\n\ntype Props = Exclude<ComponentProps<\"div\">, \"children\"> & SelfClosingWithAsChild;\n\n/**\n * A skeleton is a placeholder for content that is loading.\n * By using a skeleton, you can give the user an idea of what the content will\n * look like and reduce the perceived loading time and CLS (Cumulative Layout Shift).\n *\n * @note Default height is 1rem.\n *\n * @see https://mantle.ngrok.com/components/skeleton
|
|
1
|
+
{"version":3,"sources":["../src/components/skeleton/skeleton.tsx"],"sourcesContent":["import { type ComponentProps, type ComponentRef, forwardRef } from \"react\";\nimport type { SelfClosingWithAsChild } from \"../../types/as-child.js\";\nimport { cx } from \"../../utils/cx/cx.js\";\nimport { Slot } from \"../slot/index.js\";\n\ntype Props = Exclude<ComponentProps<\"div\">, \"children\"> & SelfClosingWithAsChild;\n\n/**\n * A skeleton is a placeholder for content that is loading.\n * By using a skeleton, you can give the user an idea of what the content will\n * look like and reduce the perceived loading time and CLS (Cumulative Layout Shift).\n *\n * @note Default height is 1rem.\n *\n * @see https://mantle.ngrok.com/components/skeleton\n *\n * @example\n * ```tsx\n * <Skeleton className=\"w-1/2\" />\n *\n * <Skeleton className=\"w-1/2\" />\n *\n * <Skeleton className=\"h-12 w-12 rounded-full\" />\n * ```\n */\nconst Skeleton = forwardRef<ComponentRef<\"div\">, Props>(\n\t({ asChild = false, className, ...props }, ref) => {\n\t\tconst Component = asChild ? Slot : \"div\";\n\n\t\treturn (\n\t\t\t<Component\n\t\t\t\tclassName={cx(\n\t\t\t\t\t\"dark-high-contrast:bg-black/30 high-contrast:bg-black/30 h-4 animate-pulse rounded-md bg-gray-300/25 dark:bg-gray-950/10\",\n\t\t\t\t\tclassName,\n\t\t\t\t)}\n\t\t\t\tref={ref}\n\t\t\t\t{...props}\n\t\t\t/>\n\t\t);\n\t},\n);\nSkeleton.displayName = \"Skeleton\";\n\nexport {\n\t//,\n\tSkeleton,\n};\n"],"mappings":"gFAAA,OAAiD,cAAAA,MAAkB,QA8BhE,cAAAC,MAAA,oBALH,IAAMC,EAAWC,EAChB,CAAC,CAAE,QAAAC,EAAU,GAAO,UAAAC,EAAW,GAAGC,CAAM,EAAGC,IAIzCN,EAHiBG,EAAUI,EAAO,MAGjC,CACA,UAAWC,EACV,2HACAJ,CACD,EACA,IAAKE,EACJ,GAAGD,EACL,CAGH,EACAJ,EAAS,YAAc","names":["forwardRef","jsx","Skeleton","forwardRef","asChild","className","props","ref","Slot","cx"]}
|
package/dist/slider.d.ts
ADDED
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as SliderPrimitive from '@radix-ui/react-slider';
|
|
3
|
+
import { ComponentProps } from 'react';
|
|
4
|
+
|
|
5
|
+
type SliderBaseProps = Omit<ComponentProps<typeof SliderPrimitive.Root>, "defaultValue" | "value">;
|
|
6
|
+
/**
|
|
7
|
+
* Value props for the {@link Slider} component. Either both `defaultValue` and
|
|
8
|
+
* `value` must be the same type (both `number` or both `number[]`), or only one
|
|
9
|
+
* may be provided.
|
|
10
|
+
*/
|
|
11
|
+
type SliderValueProps = {
|
|
12
|
+
/**
|
|
13
|
+
* The value of the slider when initially rendered. Use when you do not need
|
|
14
|
+
* to control the state of the slider.
|
|
15
|
+
*/
|
|
16
|
+
defaultValue?: number;
|
|
17
|
+
/**
|
|
18
|
+
* The controlled value of the slider. Must be used with `onValueChange`.
|
|
19
|
+
*/
|
|
20
|
+
value?: number;
|
|
21
|
+
} | {
|
|
22
|
+
/**
|
|
23
|
+
* The values of the slider when initially rendered. Use when you do not need
|
|
24
|
+
* to control the state of the slider. Pass an array to create a range slider
|
|
25
|
+
* with multiple thumbs.
|
|
26
|
+
*/
|
|
27
|
+
defaultValue?: number[];
|
|
28
|
+
/**
|
|
29
|
+
* The controlled values of the slider. Must be used with `onValueChange`.
|
|
30
|
+
* Pass an array to create a range slider with multiple thumbs.
|
|
31
|
+
*/
|
|
32
|
+
value?: number[];
|
|
33
|
+
};
|
|
34
|
+
/**
|
|
35
|
+
* Props for the {@link Slider} component.
|
|
36
|
+
*/
|
|
37
|
+
type SliderProps = SliderBaseProps & SliderValueProps;
|
|
38
|
+
/**
|
|
39
|
+
* An input where the user selects a value from within a given range.
|
|
40
|
+
*
|
|
41
|
+
* @see https://mantle.ngrok.com/components/slider
|
|
42
|
+
*
|
|
43
|
+
* @example
|
|
44
|
+
* ```tsx
|
|
45
|
+
* // single thumb
|
|
46
|
+
* <Slider
|
|
47
|
+
* defaultValue={75}
|
|
48
|
+
* max={100}
|
|
49
|
+
* step={1}
|
|
50
|
+
* />
|
|
51
|
+
* ```
|
|
52
|
+
*
|
|
53
|
+
* @example
|
|
54
|
+
* ```tsx
|
|
55
|
+
* // range
|
|
56
|
+
* <Slider
|
|
57
|
+
* defaultValue={[25, 50]}
|
|
58
|
+
* max={100}
|
|
59
|
+
* step={5}
|
|
60
|
+
* />
|
|
61
|
+
* ```
|
|
62
|
+
*
|
|
63
|
+
* @example
|
|
64
|
+
* ```tsx
|
|
65
|
+
* // multiple thumbs
|
|
66
|
+
* <Slider
|
|
67
|
+
* defaultValue={[10, 20, 70]}
|
|
68
|
+
* max={100}
|
|
69
|
+
* step={10}
|
|
70
|
+
* />
|
|
71
|
+
* ```
|
|
72
|
+
*/
|
|
73
|
+
declare function Slider({ className, defaultValue, value, min, max, ...props }: SliderProps): react_jsx_runtime.JSX.Element;
|
|
74
|
+
|
|
75
|
+
export { Slider, type SliderProps };
|
package/dist/slider.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a as i}from"./chunk-PFXFESEN.js";import*as e from"@radix-ui/react-slider";import{jsx as a,jsxs as p}from"react/jsx-runtime";function f({className:d,defaultValue:r,value:t,min:o=0,max:s=100,...u}){let l=t!=null?Array.isArray(t)?t:[t]:void 0,n=r!=null?Array.isArray(r)?r:[r]:void 0,c=l??n??[o];return p(e.Root,{"data-slot":"slider",defaultValue:n,value:l,min:o,max:s,className:i("data-orientation-vertical:min-h-40 relative flex w-full touch-none items-center select-none data-disabled:opacity-50 data-orientation-vertical:h-full data-orientation-vertical:w-auto data-orientation-vertical:flex-col",d),...u,children:[a(e.Track,{"data-slot":"slider-track",className:i("bg-neutral-300 rounded-full relative grow overflow-hidden","data-orientation-horizontal:h-1.5 data-orientation-horizontal:w-full","data-orientation-vertical:w-1.5 data-orientation-vertical:h-full"),children:a(e.Range,{"data-slot":"slider-range",className:"bg-accent-500 absolute select-none data-orientation-horizontal:h-full data-orientation-vertical:w-full"})}),Array.from({length:c.length},(v,m)=>a(e.Thumb,{"data-slot":"slider-thumb",className:i("bg-card border-card relative size-4.5 rounded-full border","shadow-sm transition-[color,box-shadow]","after:absolute after:-inset-2","focus-visible:ring-3 focus-visible:ring-accent-500/20 focus-visible:outline-hidden","block shrink-0 cursor-pointer select-none","data-disabled:pointer-events-none data-disabled:cursor-default")},m))]})}export{f as Slider};
|
|
2
|
+
//# sourceMappingURL=slider.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/components/slider/slider.tsx"],"sourcesContent":["\"use client\";\n\nimport * as SliderPrimitive from \"@radix-ui/react-slider\";\nimport type { ComponentProps } from \"react\";\nimport { cx } from \"../../utils/cx/cx.js\";\n\ntype SliderBaseProps = Omit<ComponentProps<typeof SliderPrimitive.Root>, \"defaultValue\" | \"value\">;\n\n/**\n * Value props for the {@link Slider} component. Either both `defaultValue` and\n * `value` must be the same type (both `number` or both `number[]`), or only one\n * may be provided.\n */\ntype SliderValueProps =\n\t| {\n\t\t\t/**\n\t\t\t * The value of the slider when initially rendered. Use when you do not need\n\t\t\t * to control the state of the slider.\n\t\t\t */\n\t\t\tdefaultValue?: number;\n\t\t\t/**\n\t\t\t * The controlled value of the slider. Must be used with `onValueChange`.\n\t\t\t */\n\t\t\tvalue?: number;\n\t }\n\t| {\n\t\t\t/**\n\t\t\t * The values of the slider when initially rendered. Use when you do not need\n\t\t\t * to control the state of the slider. Pass an array to create a range slider\n\t\t\t * with multiple thumbs.\n\t\t\t */\n\t\t\tdefaultValue?: number[];\n\t\t\t/**\n\t\t\t * The controlled values of the slider. Must be used with `onValueChange`.\n\t\t\t * Pass an array to create a range slider with multiple thumbs.\n\t\t\t */\n\t\t\tvalue?: number[];\n\t };\n\n/**\n * Props for the {@link Slider} component.\n */\ntype SliderProps = SliderBaseProps & SliderValueProps;\n\n/**\n * An input where the user selects a value from within a given range.\n *\n * @see https://mantle.ngrok.com/components/slider\n *\n * @example\n * ```tsx\n * // single thumb\n * <Slider\n * defaultValue={75}\n * max={100}\n * step={1}\n * />\n * ```\n *\n * @example\n * ```tsx\n * // range\n * <Slider\n * defaultValue={[25, 50]}\n * max={100}\n * step={5}\n * />\n * ```\n *\n * @example\n * ```tsx\n * // multiple thumbs\n * <Slider\n * defaultValue={[10, 20, 70]}\n * max={100}\n * step={10}\n * />\n * ```\n */\nfunction Slider({ className, defaultValue, value, min = 0, max = 100, ...props }: SliderProps) {\n\tconst normalizedValue = value != null ? (Array.isArray(value) ? value : [value]) : undefined;\n\tconst normalizedDefaultValue =\n\t\tdefaultValue != null\n\t\t\t? Array.isArray(defaultValue)\n\t\t\t\t? defaultValue\n\t\t\t\t: [defaultValue]\n\t\t\t: undefined;\n\tconst values = normalizedValue ?? normalizedDefaultValue ?? [min];\n\n\treturn (\n\t\t<SliderPrimitive.Root\n\t\t\tdata-slot=\"slider\"\n\t\t\tdefaultValue={normalizedDefaultValue}\n\t\t\tvalue={normalizedValue}\n\t\t\tmin={min}\n\t\t\tmax={max}\n\t\t\tclassName={cx(\n\t\t\t\t\"data-orientation-vertical:min-h-40 relative flex w-full touch-none items-center select-none data-disabled:opacity-50 data-orientation-vertical:h-full data-orientation-vertical:w-auto data-orientation-vertical:flex-col\",\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\t{...props}\n\t\t>\n\t\t\t<SliderPrimitive.Track\n\t\t\t\tdata-slot=\"slider-track\"\n\t\t\t\tclassName={cx(\n\t\t\t\t\t\"bg-neutral-300 rounded-full relative grow overflow-hidden\",\n\t\t\t\t\t\"data-orientation-horizontal:h-1.5 data-orientation-horizontal:w-full\",\n\t\t\t\t\t\"data-orientation-vertical:w-1.5 data-orientation-vertical:h-full\",\n\t\t\t\t)}\n\t\t\t>\n\t\t\t\t<SliderPrimitive.Range\n\t\t\t\t\tdata-slot=\"slider-range\"\n\t\t\t\t\tclassName=\"bg-accent-500 absolute select-none data-orientation-horizontal:h-full data-orientation-vertical:w-full\"\n\t\t\t\t/>\n\t\t\t</SliderPrimitive.Track>\n\t\t\t{Array.from({ length: values.length }, (_, index) => (\n\t\t\t\t<SliderPrimitive.Thumb\n\t\t\t\t\tdata-slot=\"slider-thumb\"\n\t\t\t\t\tkey={index}\n\t\t\t\t\tclassName={cx(\n\t\t\t\t\t\t\"bg-card border-card relative size-4.5 rounded-full border\",\n\t\t\t\t\t\t\"shadow-sm transition-[color,box-shadow]\",\n\t\t\t\t\t\t\"after:absolute after:-inset-2\",\n\t\t\t\t\t\t\"focus-visible:ring-3 focus-visible:ring-accent-500/20 focus-visible:outline-hidden\",\n\t\t\t\t\t\t\"block shrink-0 cursor-pointer select-none\",\n\t\t\t\t\t\t\"data-disabled:pointer-events-none data-disabled:cursor-default\",\n\t\t\t\t\t)}\n\t\t\t\t/>\n\t\t\t))}\n\t\t</SliderPrimitive.Root>\n\t);\n}\n\nexport { Slider };\nexport type { SliderProps };\n"],"mappings":"wCAEA,UAAYA,MAAqB,yBAwF/B,OAoBE,OAAAC,EApBF,QAAAC,MAAA,oBAXF,SAASC,EAAO,CAAE,UAAAC,EAAW,aAAAC,EAAc,MAAAC,EAAO,IAAAC,EAAM,EAAG,IAAAC,EAAM,IAAK,GAAGC,CAAM,EAAgB,CAC9F,IAAMC,EAAkBJ,GAAS,KAAQ,MAAM,QAAQA,CAAK,EAAIA,EAAQ,CAACA,CAAK,EAAK,OAC7EK,EACLN,GAAgB,KACb,MAAM,QAAQA,CAAY,EACzBA,EACA,CAACA,CAAY,EACd,OACEO,EAASF,GAAmBC,GAA0B,CAACJ,CAAG,EAEhE,OACCL,EAAiB,OAAhB,CACA,YAAU,SACV,aAAcS,EACd,MAAOD,EACP,IAAKH,EACL,IAAKC,EACL,UAAWK,EACV,4NACAT,CACD,EACC,GAAGK,EAEJ,UAAAR,EAAiB,QAAhB,CACA,YAAU,eACV,UAAWY,EACV,4DACA,uEACA,kEACD,EAEA,SAAAZ,EAAiB,QAAhB,CACA,YAAU,eACV,UAAU,yGACX,EACD,EACC,MAAM,KAAK,CAAE,OAAQW,EAAO,MAAO,EAAG,CAACE,EAAGC,IAC1Cd,EAAiB,QAAhB,CACA,YAAU,eAEV,UAAWY,EACV,4DACA,0CACA,gCACA,qFACA,4CACA,gEACD,GARKE,CASN,CACA,GACF,CAEF","names":["SliderPrimitive","jsx","jsxs","Slider","className","defaultValue","value","min","max","props","normalizedValue","normalizedDefaultValue","values","cx","_","index"]}
|
package/dist/slot.d.ts
CHANGED
|
@@ -6,7 +6,7 @@ import * as _radix_ui_react_slot from '@radix-ui/react-slot';
|
|
|
6
6
|
* components that can be rendered as different elements. Automatically merges
|
|
7
7
|
* className props using `cx` for proper Tailwind class handling.
|
|
8
8
|
*
|
|
9
|
-
* @see https://mantle.ngrok.com/components/slot
|
|
9
|
+
* @see https://mantle.ngrok.com/components/slot
|
|
10
10
|
*
|
|
11
11
|
* @example
|
|
12
12
|
* ```tsx
|
package/dist/slot.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"./chunk-
|
|
1
|
+
import{a}from"./chunk-ADF5DAYG.js";import"./chunk-PFXFESEN.js";export{a as Slot};
|
|
2
2
|
//# sourceMappingURL=slot.js.map
|
package/dist/split-button.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
|
|
2
2
|
import * as react from 'react';
|
|
3
3
|
import { ComponentProps, ReactNode } from 'react';
|
|
4
|
-
import { B as Button } from './button-
|
|
5
|
-
import { I as IconButton } from './icon-button-
|
|
4
|
+
import { B as Button } from './button-DLUUf_c-.js';
|
|
5
|
+
import { I as IconButton } from './icon-button-CT71Ti9V.js';
|
|
6
6
|
import { DropdownMenu } from './dropdown-menu.js';
|
|
7
7
|
import './deep-non-nullable-SmpSvoSd.js';
|
|
8
8
|
import 'class-variance-authority';
|
|
@@ -21,7 +21,7 @@ type MenuTriggerProps = Omit<ComponentProps<typeof IconButton>, "appearance" | "
|
|
|
21
21
|
* related alternatives through a dropdown menu. Best for when users typically
|
|
22
22
|
* want one action but occasionally need variants.
|
|
23
23
|
*
|
|
24
|
-
* @see https://mantle.ngrok.com/components/split-button#
|
|
24
|
+
* @see https://mantle.ngrok.com/components/split-button#splitbuttonroot
|
|
25
25
|
*
|
|
26
26
|
* @example
|
|
27
27
|
* ```tsx
|
|
@@ -51,7 +51,7 @@ declare const SplitButton: {
|
|
|
51
51
|
* related alternatives through a dropdown menu. Best for when users typically
|
|
52
52
|
* want one action but occasionally need variants.
|
|
53
53
|
*
|
|
54
|
-
* @see https://mantle.ngrok.com/components/split-button#
|
|
54
|
+
* @see https://mantle.ngrok.com/components/split-button#splitbuttonroot
|
|
55
55
|
*
|
|
56
56
|
* @example
|
|
57
57
|
* ```tsx
|
|
@@ -79,7 +79,7 @@ declare const SplitButton: {
|
|
|
79
79
|
/**
|
|
80
80
|
* The most common action users can trigger with a single click.
|
|
81
81
|
*
|
|
82
|
-
* @see https://mantle.ngrok.com/components/split-button#
|
|
82
|
+
* @see https://mantle.ngrok.com/components/split-button#splitbuttonprimaryaction
|
|
83
83
|
*
|
|
84
84
|
* @example
|
|
85
85
|
* ```tsx
|
|
@@ -107,7 +107,7 @@ declare const SplitButton: {
|
|
|
107
107
|
/**
|
|
108
108
|
* The button that opens the split button dropdown menu.
|
|
109
109
|
*
|
|
110
|
-
* @see https://mantle.ngrok.com/components/split-button#
|
|
110
|
+
* @see https://mantle.ngrok.com/components/split-button#splitbuttonmenutrigger
|
|
111
111
|
*
|
|
112
112
|
* @example
|
|
113
113
|
* ```tsx
|
|
@@ -136,7 +136,7 @@ declare const SplitButton: {
|
|
|
136
136
|
* The container for the split button dropdown menu content. Appears in a
|
|
137
137
|
* portal with scrolling and animations.
|
|
138
138
|
*
|
|
139
|
-
* @see https://mantle.ngrok.com/components/split-button#
|
|
139
|
+
* @see https://mantle.ngrok.com/components/split-button#splitbuttonmenucontent
|
|
140
140
|
*
|
|
141
141
|
* @example
|
|
142
142
|
* ```tsx
|
|
@@ -167,7 +167,7 @@ declare const SplitButton: {
|
|
|
167
167
|
* A standard item in the split button dropdown menu that can be selected or
|
|
168
168
|
* activated.
|
|
169
169
|
*
|
|
170
|
-
* @see https://mantle.ngrok.com/components/split-button#
|
|
170
|
+
* @see https://mantle.ngrok.com/components/split-button#splitbuttonmenuitem
|
|
171
171
|
*
|
|
172
172
|
* @example
|
|
173
173
|
* ```tsx
|
package/dist/split-button.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as r}from"./chunk-
|
|
1
|
+
import{a as r}from"./chunk-QK3NV2Q3.js";import"./chunk-MLXONRJD.js";import{a as u}from"./chunk-W5A5HSFE.js";import{c as m}from"./chunk-CBRSMQ26.js";import"./chunk-63ZAW25Z.js";import"./chunk-72TJUKMV.js";import"./chunk-OP6JMBKJ.js";import{a as s}from"./chunk-IVQ626TU.js";import"./chunk-ADF5DAYG.js";import"./chunk-SBQHQ2SJ.js";import{a}from"./chunk-PFXFESEN.js";import{CaretDownIcon as w}from"@phosphor-icons/react/CaretDown";import{forwardRef as p}from"react";import{jsx as n}from"react/jsx-runtime";var d=p(({className:o,children:t,dir:e,open:i,defaultOpen:C,onOpenChange:P,modal:g,...M},R)=>n(r.Root,{dir:e,open:i,defaultOpen:C,onOpenChange:P,modal:g,children:n("div",{"data-slot":"split-button",className:a("flex flex-row [&>*:first-child]:rounded-r-none [&>*:last-child]:rounded-l-none [&>*:not(:first-child):not(:last-child)]:rounded-none [&>*:not(:first-child)]:-ml-px [&>*:focus]:relative [&>*:focus]:z-10 [&>*:hover]:relative [&>*:hover]:z-10 *:active:scale-100!",o),ref:R,...M,children:t})}));d.displayName="SplitButton";var l=p(({type:o="button",...t},e)=>n(u,{appearance:"outlined",priority:"neutral",ref:e,type:o,...t}));l.displayName="SplitButtonPrimaryAction";var c=p(({icon:o,type:t="button",...e},i)=>n(r.Trigger,{asChild:!0,className:"group",children:n(m,{icon:o??n(s,{svg:n(w,{weight:"bold",className:"size-4 group-data-[state=open]:-rotate-180 transition-transform ease-out duration-150"})}),appearance:"outlined",ref:i,type:t,...e})}));c.displayName="SplitButtonMenuTrigger";var f=p(({align:o="end",...t},e)=>n(r.Content,{align:o,ref:e,...t}));f.displayName="SplitButtonMenuContent";var y=p(({className:o,...t},e)=>n(r.Item,{className:a("justify-between gap-4",o),ref:e,...t}));y.displayName="SplitButtonMenuItem";var h={Root:d,PrimaryAction:l,MenuTrigger:c,MenuContent:f,MenuItem:y};export{h as SplitButton};
|
|
2
2
|
//# sourceMappingURL=split-button.js.map
|