@ngrok/mantle 0.93.7 → 0.94.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 +13 -1
- package/dist/accordion.js +1 -1
- package/dist/agent.json +1181 -36
- package/dist/alert-CH99Rw-R.js +1 -0
- package/dist/{alert-BcSBNR3S.d.ts → alert-HffaioZM.d.ts} +31 -21
- package/dist/alert-center.d.ts +15 -3
- package/dist/alert-center.js +1 -1
- package/dist/alert-dialog.d.ts +15 -2
- package/dist/alert-dialog.js +1 -1
- package/dist/alert.d.ts +6 -1
- package/dist/alert.js +1 -1
- package/dist/anchor.d.ts +12 -0
- package/dist/app-layout.d.ts +16 -1
- package/dist/app-layout.js +1 -1
- package/dist/area-chart.d.ts +144 -88
- package/dist/area-chart.js +1 -1
- package/dist/avatar.d.ts +12 -0
- package/dist/badge.d.ts +13 -1
- package/dist/bar-chart.d.ts +144 -89
- package/dist/bar-chart.js +1 -1
- package/dist/breadcrumb.d.ts +11 -0
- package/dist/breadcrumb.js +1 -1
- package/dist/browser-only.d.ts +8 -0
- package/dist/{button-Yxyu1XMd.d.ts → button-BGwOPjGV.d.ts} +7 -1
- package/dist/{button-B8k98Pby.js → button-BWGUuWnu.js} +1 -1
- package/dist/{button-CPsKGDK0.d.ts → button-Cgf2IcEC.d.ts} +8 -1
- package/dist/button-Cu9e3SM7.js +1 -0
- package/dist/{button-BX-4lYUn.d.ts → button-K0pKc3GN.d.ts} +3 -3
- package/dist/button.d.ts +9 -3
- package/dist/button.js +1 -1
- package/dist/calendar.d.ts +7 -0
- package/dist/calendar.js +1 -1
- package/dist/card.d.ts +6 -1
- package/dist/centered-layout.d.ts +11 -0
- package/dist/chart-BO9EwQ60.js +1 -0
- package/dist/chart-CE5Uaqz9.js +1 -0
- package/dist/chart-DCTGGlWL.js +1 -0
- package/dist/chart-DudCw24t.js +2 -0
- package/dist/{chart-BpfbtOUN.d.ts → chart-jitNqimS.d.ts} +99 -103
- package/dist/{checkbox-DmSQXs26.js → checkbox-CS504fKk.js} +1 -1
- package/dist/checkbox.d.ts +14 -1
- package/dist/checkbox.js +1 -1
- package/dist/{choice-BLR0_MeB.d.ts → choice-BwfmbepO.d.ts} +7 -1
- package/dist/choice-uyYccm0A.js +1 -0
- package/dist/choice.d.ts +6 -1
- package/dist/choice.js +1 -1
- package/dist/code-block.d.ts +13 -2
- package/dist/code-block.js +1 -1
- package/dist/code-block_highlight-utils.d.ts +5 -0
- package/dist/code.d.ts +13 -0
- package/dist/color-CHZbU1Ww.js +1 -0
- package/dist/color.js +1 -1
- package/dist/combobox.d.ts +28 -14
- package/dist/combobox.js +1 -1
- package/dist/command.d.ts +14 -2
- package/dist/command.js +1 -1
- package/dist/cx.js +1 -1
- package/dist/data-table.d.ts +50 -19
- package/dist/data-table.js +1 -1
- package/dist/description-list.d.ts +12 -1
- package/dist/dialog-B9JAGy_x.d.ts +28 -0
- package/dist/{dialog-7TUgiSzX.js → dialog-CsugEt2A.js} +1 -1
- package/dist/{dialog-2fRO4ca4.d.ts → dialog-DD5H3EH1.d.ts} +10 -2
- package/dist/dialog.d.ts +7 -2
- package/dist/dialog.js +1 -1
- package/dist/dropdown-menu-DHdgaw4P.js +1 -0
- package/dist/{dropdown-menu-CpjRwMWe.d.ts → dropdown-menu-DmDxYPde.d.ts} +34 -26
- package/dist/dropdown-menu.d.ts +6 -1
- package/dist/dropdown-menu.js +1 -1
- package/dist/empty.d.ts +5 -0
- package/dist/empty.js +1 -1
- package/dist/{field-V_gnkcmN.d.ts → field-BshcNVe_.d.ts} +1 -1
- package/dist/field.d.ts +17 -6
- package/dist/field.js +1 -1
- package/dist/flag.d.ts +8 -0
- package/dist/hooks.d.ts +5 -0
- package/dist/hooks.js +1 -1
- package/dist/hover-card.d.ts +23 -12
- package/dist/{icon-ByLVhdYq.d.ts → icon-NYvyyRMG.d.ts} +6 -0
- package/dist/icon.d.ts +7 -2
- package/dist/icon.js +1 -1
- package/dist/{icons-DP3lQw5O.js → icons-4JA-SGfv.js} +1 -1
- package/dist/icons.d.ts +13 -1
- package/dist/icons.js +1 -1
- package/dist/{index-BhfgyurF.d.ts → index-KJ06KK6t.d.ts} +3 -3
- package/dist/input-BjCDSOPA.js +1 -0
- package/dist/input-DHovzBjS.js +1 -0
- package/dist/{input-Dx5owTCc.d.ts → input-q8o5uMhW.d.ts} +11 -1
- package/dist/input.d.ts +34 -2
- package/dist/input.js +1 -1
- package/dist/kbd.d.ts +12 -0
- package/dist/{label-nHqqYS7e.js → label-DmDwzPD8.js} +1 -1
- package/dist/{label-Dn5CPJUj.d.ts → label-r2sJcSQ4.d.ts} +6 -0
- package/dist/label.d.ts +6 -1
- package/dist/label.js +1 -1
- package/dist/line-chart.d.ts +139 -82
- package/dist/line-chart.js +1 -1
- package/dist/{list-RFRIQxU2.js → list-CO_yLdln.js} +1 -1
- package/dist/list.d.ts +19 -1
- package/dist/list.js +1 -1
- package/dist/live-region.d.ts +14 -1
- package/dist/llms.txt +78 -76
- package/dist/main.d.ts +12 -0
- package/dist/mantle.css +110 -65
- package/dist/media-object.d.ts +12 -0
- package/dist/migrations/0014-chart-named-colors.yml +1389 -0
- package/dist/migrations/0015-segmented-control.yml +788 -0
- package/dist/multi-select.d.ts +15 -2
- package/dist/multi-select.js +1 -1
- package/dist/otp-input.d.ts +17 -5
- package/dist/otp-input.js +1 -1
- package/dist/pagination.d.ts +92 -3
- package/dist/pagination.js +1 -1
- package/dist/popover-BhTFutCz.d.ts +1 -0
- package/dist/{popover-BfB2I9G0.d.ts → popover-lwkwWcRW.d.ts} +16 -7
- package/dist/popover.d.ts +7 -2
- package/dist/progress.d.ts +27 -10
- package/dist/progress.js +1 -1
- package/dist/qr-code.d.ts +9 -1
- package/dist/query.d.ts +2 -2
- package/dist/query.js +1 -1
- package/dist/radio-group-jj2abc0t.js +1 -0
- package/dist/radio-group-sLz5AA9I.d.ts +27 -0
- package/dist/radio-group.d.ts +20 -99
- package/dist/radio-group.js +1 -1
- package/dist/sandbar.d.ts +14 -1
- package/dist/sandbar.js +1 -1
- package/dist/sandboxed-on-click.d.ts +8 -0
- package/dist/scatter-plot.d.ts +126 -64
- package/dist/scatter-plot.js +1 -1
- package/dist/segmented-control.d.ts +136 -0
- package/dist/segmented-control.js +1 -0
- package/dist/{select-BkhBxtOT.d.ts → select-BqmpVJJT.d.ts} +29 -21
- package/dist/select-C6Su0dU0.js +1 -0
- package/dist/select.d.ts +6 -1
- package/dist/select.js +1 -1
- package/dist/selectable-list.d.ts +13 -2
- package/dist/selectable-list.js +1 -1
- package/dist/{separator-D9AWEkcJ.d.ts → separator-QfH0ot5K.d.ts} +3 -1
- package/dist/separator.d.ts +6 -1
- package/dist/{sheet-CSJc_sB4.js → sheet-Bd2LIhzF.js} +1 -1
- package/dist/sheet.d.ts +15 -2
- package/dist/sheet.js +1 -1
- package/dist/sidebar.d.ts +19 -3
- package/dist/sidebar.js +1 -1
- package/dist/skeleton.d.ts +11 -0
- package/dist/skip-to-main-link.d.ts +11 -0
- package/dist/skip-to-main-link.js +1 -1
- package/dist/slider.d.ts +10 -0
- package/dist/{slot-C0OCJjdJ.d.ts → slot-D12N_fZJ.d.ts} +3 -1
- package/dist/slot.d.ts +6 -1
- package/dist/split-button.d.ts +14 -3
- package/dist/split-button.js +1 -1
- package/dist/strata.d.ts +13 -0
- package/dist/switch.d.ts +13 -1
- package/dist/switch.js +1 -1
- package/dist/{table-vT6Okwfa.d.ts → table-rWiVWEgB.d.ts} +79 -0
- package/dist/table.d.ts +6 -1
- package/dist/tabs.d.ts +23 -11
- package/dist/tabs.js +1 -1
- package/dist/text-area.d.ts +11 -1
- package/dist/theme-DdZgLvKH.js +1 -0
- package/dist/theme-switcher.d.ts +16 -2
- package/dist/theme-switcher.js +1 -1
- package/dist/theme.d.ts +12 -0
- package/dist/theme.js +1 -1
- package/dist/toast.d.ts +14 -1
- package/dist/toast.js +1 -1
- package/dist/{tooltip-NcLIeBy5.d.ts → tooltip-CpK3XTor.d.ts} +15 -8
- package/dist/tooltip.d.ts +6 -1
- package/dist/truncated-text.d.ts +27 -13
- package/dist/truncated-text.js +1 -1
- package/dist/types.d.ts +1 -1
- package/dist/types.js +1 -1
- package/dist/use-inert-siblings-CNmNuS2h.js +1 -0
- package/dist/use-swipe-to-dismiss-i__cTF2v.js +1 -0
- package/dist/utils.d.ts +1 -1
- package/dist/utils.js +1 -1
- package/dist/visually-hidden.d.ts +13 -0
- package/dist/well.d.ts +6 -1
- package/package.json +6 -6
- package/src/components/chart/d3-license.md +25 -0
- package/dist/alert-P9lwn25X.js +0 -1
- package/dist/button-Dge0D5bl.js +0 -1
- package/dist/chart-BpWfQAwf.js +0 -2
- package/dist/choice-2Lrv8_nl.js +0 -1
- package/dist/dialog-Dp0QGWwo.d.ts +0 -28
- package/dist/dropdown-menu-BHBzCDSZ.js +0 -1
- package/dist/input-CpQ6jlpI.js +0 -1
- package/dist/popover-C96V8SXi.d.ts +0 -1
- package/dist/select-CAAYk4Yj.js +0 -1
- package/dist/theme-C-glc5Q-.js +0 -1
- package/dist/use-swipe-to-dismiss-DceYk1Id.js +0 -1
package/dist/icons.d.ts
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
|
-
|
|
1
|
+
/**
|
|
2
|
+
* Re-exports for the Icons component — the ngrok-specific icons that
|
|
3
|
+
* `@phosphor-icons/react` does not ship.
|
|
4
|
+
*
|
|
5
|
+
* @useWhen Show an ngrok glyph that `@phosphor-icons/react` does not ship, such as the ngrok
|
|
6
|
+
* wordmark or the icon for a traffic policy file.
|
|
7
|
+
*
|
|
8
|
+
* @siblings
|
|
9
|
+
* - `Icon`: the glyph comes from `@phosphor-icons/react`.
|
|
10
|
+
*
|
|
11
|
+
* @see https://mantle.ngrok.com/components/data-display/icons
|
|
12
|
+
*/
|
|
2
13
|
import { a as AlphanumericSortingDirection, c as TimeSortingDirection, o as SortingDirection, s as SortingMode } from "./direction-CpRzTtZh.js";
|
|
14
|
+
import { t as SvgAttributes } from "./icon-CgNqu-fl.js";
|
|
3
15
|
import { i as Theme } from "./theme-w1CrMM-x.js";
|
|
4
16
|
import { ComponentProps } from "react";
|
|
5
17
|
type Props = SvgAttributes & ({
|
package/dist/icons.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as e}from"./icons-
|
|
1
|
+
import{t as e}from"./icons-CDLz5lpI.js";import{t}from"./icons-CSwTVV2m.js";import{n,t as r}from"./icons-4JA-SGfv.js";import{c as i}from"react/compiler-runtime";import{jsx as a}from"react/jsx-runtime";function o(e){let t=i(3),n;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(n=/* @__PURE__ */ a(`path`,{d:`M32.272 12.011c-1.298-1.466-2.904-2.205-4.812-2.205-1.176 0-2.26.233-3.255.7a7.995 7.995 0 0 0-2.581 1.906 9.205 9.205 0 0 0-1.715 2.853 9.773 9.773 0 0 0-.628 3.546c0 1.25.194 2.39.58 3.419.362.98.918 1.877 1.635 2.636A7.543 7.543 0 0 0 24 26.584c.965.41 2.025.617 3.176.617.522 0 1.005-.041 1.445-.116.439-.075.858-.2 1.26-.37.4-.175.79-.398 1.18-.664.385-.27.792-.612 1.21-1.018v4.353h-.005v.421h-5.33l-4.005 4.64v.798h15.037v-24.98h-5.697v1.746Zm-.014 7.979a4.25 4.25 0 0 1-.786 1.215 3.555 3.555 0 0 1-2.592 1.1 3.627 3.627 0 0 1-1.464-.292 3.508 3.508 0 0 1-1.166-.808 3.93 3.93 0 0 1-1.054-2.72c0-.519.097-1.006.298-1.457a3.77 3.77 0 0 1 .804-1.181 4.114 4.114 0 0 1 1.162-.808 3.484 3.484 0 0 1 2.817-.016c.448.19.844.463 1.181.81.336.347.6.743.804 1.194.202.452.298.95.298 1.493 0 .505-.104 1.005-.302 1.47m-16.261-7.708a6.173 6.173 0 0 0-2.06-1.602 4.875 4.875 0 0 0-.57-.22 6.383 6.383 0 0 0-.923-.216H8.383L5.697 13.39v-3.082H.002v16.61h5.695V15.712h5.35l.444-.01v11.214h5.697V16.528c0-.885-.084-1.674-.25-2.366a4.655 4.655 0 0 0-.941-1.877zm38.367-2.018h-6.213l-2.47 2.863v-2.864h-5.7v16.61h5.71l.004-11.117h4.144l4.526-5.26zm31.051 7.672 7.79-7.392v-.281H85.7l-5.975 5.991V0h-5.696v26.87h5.696v-6.766l6.262 6.763h7.663v-.316l-8.233-8.617zm-16.11-5.78a9.436 9.436 0 0 0-3.085-1.842 10.953 10.953 0 0 0-3.855-.664c-1.407 0-2.705.226-3.884.678a9.611 9.611 0 0 0-3.072 1.858 8.488 8.488 0 0 0-2.016 2.788 8.281 8.281 0 0 0-.722 3.449c0 1.362.24 2.596.722 3.707a8.52 8.52 0 0 0 2.002 2.862c.85.798 1.86 1.415 3.036 1.847 1.177.432 2.455.647 3.842.647 1.406 0 2.707-.215 3.919-.647 1.204-.431 2.24-1.04 3.098-1.833a8.583 8.583 0 0 0 2.031-2.816c.493-1.09.742-2.29.742-3.611 0-1.316-.244-2.52-.722-3.612a8.424 8.424 0 0 0-2.035-2.81Zm-3.558 7.864c-.2.461-.463.869-.786 1.215a3.573 3.573 0 0 1-2.592 1.1c-.502 0-.981-.096-1.434-.291a3.44 3.44 0 0 1-1.16-.809 4.155 4.155 0 0 1-.788-1.215 3.825 3.825 0 0 1-.297-1.537c0-.517.098-1.004.297-1.456.201-.451.46-.849.787-1.194a3.579 3.579 0 0 1 2.597-1.1c.502 0 .98.096 1.43.29.448.19.839.461 1.16.81.328.345.586.752.786 1.214.2.461.297.954.297 1.471 0 .538-.096 1.04-.297 1.502`}),t[0]=n):n=t[0];let r;return t[1]===e?r=t[2]:(r=/* @__PURE__ */ a(`svg`,{fill:`currentColor`,height:`1em`,viewBox:`0 0 94 36`,width:`2.61em`,...e,children:n}),t[1]=e,t[2]=r),r}function s(e){let t=i(3),n;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(n=/* @__PURE__ */ a(`path`,{d:`M27.2 6.18a9.47 9.47 0 0 0-3.12-2.5A9.42 9.42 0 0 0 21.82 3h-6.14l-4.06 4.9V3.1H3V29h8.62V11.53h8.09l.67-.02v17.48H29V12.8c0-1.37-.13-2.6-.38-3.68a7.35 7.35 0 0 0-1.42-2.93Z`}),t[0]=n):n=t[0];let r;return t[1]===e?r=t[2]:(r=/* @__PURE__ */ a(`svg`,{fill:`currentColor`,height:`1em`,viewBox:`0 0 32 32`,width:`1em`,...e,children:n}),t[1]=e,t[2]=r),r}export{r as AutoThemeIcon,s as NgrokLettermarkIcon,o as NgrokWordmarkIcon,e as SortIcon,n as ThemeIcon,t as TrafficPolicyFileIcon};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "./as-child-DFxX3U2i.js";
|
|
2
2
|
import "./with-style-props-CuT30s0W.js";
|
|
3
3
|
import { CSSProperties } from "react";
|
|
4
|
-
import { VariantProps } from "class-variance-authority";
|
|
4
|
+
import { VariantProps as VariantProps$1 } from "class-variance-authority";
|
|
5
5
|
type Booleanish = boolean | "true" | "false";
|
|
6
6
|
/**
|
|
7
7
|
* Parse/coerce a booleanish value (boolean | "true" | "false") into a boolean.
|
|
@@ -17,7 +17,7 @@ type DeepNonNullable<Type> = { [Property in keyof Type]-?: Type[Property] & {};
|
|
|
17
17
|
*
|
|
18
18
|
* Using VariantProps directly from CVA produces that can be `null`, which is not what we want.
|
|
19
19
|
*/
|
|
20
|
-
type VariantProps
|
|
20
|
+
type VariantProps<Variants extends (props: Record<PropertyKey, unknown> | undefined) => string> = Partial<DeepNonNullable<VariantProps$1<Variants>>>;
|
|
21
21
|
/**
|
|
22
22
|
* A CSS custom property (CSS variable) name.
|
|
23
23
|
*
|
|
@@ -51,4 +51,4 @@ type CssProperties = CSSProperties & Record<CssVariableName, string | number>;
|
|
|
51
51
|
* style={$cssProperties({ display: "block", "--gap": 8, ...style })}
|
|
52
52
|
*/
|
|
53
53
|
declare const $cssProperties: (input: CssProperties) => CSSProperties;
|
|
54
|
-
export { Booleanish as a, DeepNonNullable as i, CssProperties as n, parseBooleanish as o, VariantProps
|
|
54
|
+
export { Booleanish as a, DeepNonNullable as i, CssProperties as n, parseBooleanish as o, VariantProps as r, $cssProperties as t };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e={"data-1p-ignore":!0,"data-bwignore":!0,"data-form-type":`other`,"data-lpignore":`true`,"data-protonpass-ignore":!0};export{e as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{t as e}from"./booleanish-BfvnW6vy.js";import{n as t}from"./compose-refs-sFdxsL7k.js";import{t as n}from"./clsx-DUGZgXfJ.js";import{t as r}from"./cx-CK7o_rVv.js";import{t as i}from"./data-slot-EM6s2WEU.js";import{a,r as o}from"./field-CPvjazWN.js";import{t as s}from"./icon-kK0c-POG.js";import{c}from"react/compiler-runtime";import{createContext as l,useContext as u,useRef as d}from"react";import{jsx as f,jsxs as p}from"react/jsx-runtime";import{CheckCircleIcon as m}from"@phosphor-icons/react/CheckCircle";import{WarningIcon as h}from"@phosphor-icons/react/Warning";import{WarningDiamondIcon as g}from"@phosphor-icons/react/WarningDiamond";const _=e=>{let t=c(17),n,r,i,a;t[0]===e?(n=t[1],r=t[2],i=t[3],a=t[4]):({children:n,className:r,ref:a,...i}=e,t[0]=e,t[1]=n,t[2]=r,t[3]=i,t[4]=a);let o=!!n,s=d(null);if(o){let e;return t[5]!==n||t[6]!==r||t[7]!==i||t[8]!==a?(e=/* @__PURE__ */ f(b,{className:r,forwardedRef:a,innerRef:s,...i,children:n}),t[5]=n,t[6]=r,t[7]=i,t[8]=a,t[9]=e):e=t[9],e}let l;t[10]===i?l=t[11]:(l=/* @__PURE__ */ f(v,{...i}),t[10]=i,t[11]=l);let u;return t[12]!==r||t[13]!==i||t[14]!==a||t[15]!==l?(u=/* @__PURE__ */ f(b,{...i,className:r,forwardedRef:a,innerRef:s,children:l}),t[12]=r,t[13]=i,t[14]=a,t[15]=l,t[16]=u):u=t[16],u},v=e=>{let n=c(31),s,l,d,p,m,h;n[0]===e?(s=n[1],l=n[2],d=n[3],p=n[4],m=n[5],h=n[6]):({"aria-invalid":s,"data-slot":p,className:d,ref:m,validation:l,...h}=e,n[0]=e,n[1]=s,n[2]=l,n[3]=d,n[4]=p,n[5]=m,n[6]=h);let g=u(y),_,v,b,x,S;n[7]===g?(_=n[8],v=n[9],b=n[10],x=n[11],S=n[12]):({"aria-invalid":v,forwardedRef:b,innerRef:x,validation:S,..._}=g,n[7]=g,n[8]=_,n[9]=v,n[10]=b,n[11]=x,n[12]=S);let C=a(),w=v??s,T=S??l??C,E;n[13]!==w||n[14]!==T?(E=o({"aria-invalid":w,validation:T}),n[13]=w,n[14]=T,n[15]=E):E=n[15];let{ariaInvalid:D,validation:O}=E,k=h.type??_.type??`text`,A;n[16]!==_||n[17]!==h||n[18]!==k?(A={..._,...h,type:k},n[16]=_,n[17]=h,n[18]=k,n[19]=A):A=n[19];let j=A,M=t(m,b,x),N;n[20]===p?N=n[21]:(N=i(p,`input-capture`),n[20]=p,n[21]=N);let P;n[22]===d?P=n[23]:(P=r(`placeholder:text-placeholder min-w-0 flex-1 bg-transparent text-left autofill:shadow-[inset_0_0_0px_1000px_var(--color-blue-50)] focus:outline-hidden`,d),n[22]=d,n[23]=P);let F;return n[24]!==D||n[25]!==M||n[26]!==j||n[27]!==N||n[28]!==P||n[29]!==O?(F=/* @__PURE__ */ f(`input`,{"aria-invalid":D,"data-slot":N,"data-validation":O,className:P,ref:M,...j}),n[24]=D,n[25]=M,n[26]=j,n[27]=N,n[28]=P,n[29]=O,n[30]=F):F=n[30],F},y=l({validation:void 0,innerRef:{current:null}}),b=t=>{let n=c(51),s,l,u,d,m,h,g,_,v,b,S,C;n[0]===t?(s=n[1],l=n[2],u=n[3],d=n[4],m=n[5],h=n[6],g=n[7],_=n[8],v=n[9],b=n[10],S=n[11],C=n[12]):({"aria-invalid":l,"aria-disabled":s,"data-slot":h,children:d,className:m,disabled:g,forwardedRef:_,innerRef:v,style:S,type:C,validation:u,...b}=t,n[0]=t,n[1]=s,n[2]=l,n[3]=u,n[4]=d,n[5]=m,n[6]=h,n[7]=g,n[8]=_,n[9]=v,n[10]=b,n[11]=S,n[12]=C);let w=a(),T=u??w,E;n[13]!==l||n[14]!==T?(E=o({"aria-invalid":l,validation:T}),n[13]=l,n[14]=T,n[15]=E):E=n[15];let{validation:D}=E,O;n[16]!==s||n[17]!==l||n[18]!==u||n[19]!==g||n[20]!==_||n[21]!==v||n[22]!==b||n[23]!==C?(O={"aria-invalid":l,"aria-disabled":s,disabled:g,type:C,validation:u,...b,forwardedRef:_,innerRef:v},n[16]=s,n[17]=l,n[18]=u,n[19]=g,n[20]=_,n[21]=v,n[22]=b,n[23]=C,n[24]=O):O=n[24];let k=O,A;n[25]===h?A=n[26]:(A=i(h,`input`),n[25]=h,n[26]=A);let j;n[27]!==s||n[28]!==g?(j=e(g??s)||void 0,n[27]=s,n[28]=g,n[29]=j):j=n[29];let M=D||void 0,N;n[30]===m?N=n[31]:(N=r(`pointer-coarse:text-base h-9 text-sm`,`bg-form relative flex w-full items-center gap-1.5 rounded-md border px-3 py-2 file:border-0 file:bg-transparent file:text-sm file:font-medium focus-within:outline-hidden focus-within:ring-4`,`data-disabled:opacity-50`,`has-[input:not(:first-child)]:ps-2.5 has-[input:not(:last-child)]:pe-2.5 [&>:not(input)]:shrink-0 [&_svg]:size-5`,`border-form text-strong focus-within:border-accent-600 focus-within:ring-focus-accent`,`data-validation-success:border-success-600 focus-within:data-validation-success:border-success-600 focus-within:data-validation-success:ring-focus-success`,`data-validation-warning:border-warning-600 focus-within:data-validation-warning:border-warning-600 focus-within:data-validation-warning:ring-focus-warning`,`data-validation-error:border-danger-600 focus-within:data-validation-error:border-danger-600 focus-within:data-validation-error:ring-focus-danger motion-safe:data-validation-error:animate-shake`,`has-[>[data-validation=error]]:border-danger-600 focus-within:has-[>[data-validation=error]]:border-danger-600 focus-within:has-[>[data-validation=error]]:ring-focus-danger motion-safe:has-[>[data-validation=error]]:animate-shake`,`autofill:shadow-[inset_0_0_0px_1000px_var(--color-blue-50)] has-autofill:bg-blue-50 has-autofill:[-webkit-text-fill-color:var(--text-color-strong)]`,m),n[30]=m,n[31]=N);let P,F;n[32]===v?(P=n[33],F=n[34]):(P=e=>{e.target!==v?.current&&e.preventDefault()},F=e=>{let t=v.current;t!=null&&e.detail!==0&&t.focus()},n[32]=v,n[33]=P,n[34]=F);let I;n[35]!==b.name||n[36]!==D?(I=/* @__PURE__ */ f(x,{name:b.name,validation:D}),n[35]=b.name,n[36]=D,n[37]=I):I=n[37];let L;n[38]!==d||n[39]!==S||n[40]!==I||n[41]!==A||n[42]!==j||n[43]!==M||n[44]!==N||n[45]!==P||n[46]!==F?(L=/* @__PURE__ */ p(`div`,{role:`none`,"data-slot":A,"data-disabled":j,"data-validation":M,className:N,onMouseDown:P,onClick:F,style:S,children:[d,I]}),n[38]=d,n[39]=S,n[40]=I,n[41]=A,n[42]=j,n[43]=M,n[44]=N,n[45]=P,n[46]=F,n[47]=L):L=n[47];let R;return n[48]!==k||n[49]!==L?(R=/* @__PURE__ */ f(y.Provider,{value:k,children:L}),n[48]=k,n[49]=L,n[50]=R):R=n[50],R},x=e=>{let t=c(9),{name:r,validation:i}=e;switch(i){case`error`:{let e;t[0]===r?e=t[1]:(e=n(`The value entered for the`,r,`input has failed validation.`),t[0]=r,t[1]=e);let i;t[2]===e?i=t[3]:(i=/* @__PURE__ */ f(`span`,{className:`sr-only`,children:e}),t[2]=e,t[3]=i);let a;t[4]===Symbol.for(`react.memo_cache_sentinel`)?(a=/* @__PURE__ */ f(s,{svg:/* @__PURE__ */ f(h,{"aria-hidden":!0,weight:`fill`})}),t[4]=a):a=t[4];let o;return t[5]===i?o=t[6]:(o=/* @__PURE__ */ p(`div`,{className:`text-danger-600 order-last select-none`,children:[i,a]}),t[5]=i,t[6]=o),o}case`success`:{let e;return t[7]===Symbol.for(`react.memo_cache_sentinel`)?(e=/* @__PURE__ */ f(`div`,{className:`text-success-600 order-last select-none`,children:/* @__PURE__ */ f(s,{svg:/* @__PURE__ */ f(m,{weight:`fill`})})}),t[7]=e):e=t[7],e}case`warning`:{let e;return t[8]===Symbol.for(`react.memo_cache_sentinel`)?(e=/* @__PURE__ */ f(`div`,{className:`text-warning-600 order-last select-none`,children:/* @__PURE__ */ f(s,{svg:/* @__PURE__ */ f(g,{weight:`fill`})})}),t[8]=e):e=t[8],e}default:return null}};export{v as n,_ as t};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as WithDataSlot } from "./data-slot-B-LqAcBB.js";
|
|
2
|
-
import { o as WithValidation } from "./field-
|
|
2
|
+
import { o as WithValidation } from "./field-BshcNVe_.js";
|
|
3
3
|
import { ComponentProps, PropsWithChildren } from "react";
|
|
4
4
|
/**
|
|
5
5
|
* (Not a Boolean attribute!) The autocomplete attribute takes as its value a space-separated string that describes what,
|
|
@@ -54,6 +54,16 @@ type InputProps = Omit<ComponentProps<"input">, "autoComplete" | "type"> & BaseP
|
|
|
54
54
|
* An interactive form control that accepts data from the user. Supports many
|
|
55
55
|
* input types and validation states, and composes with adornment children.
|
|
56
56
|
*
|
|
57
|
+
* @useWhen Accept one line of text from the user, such as a name, an email address, a URL, or a
|
|
58
|
+
* search term.
|
|
59
|
+
*
|
|
60
|
+
* @siblings
|
|
61
|
+
* - `TextArea`: the text spans several lines.
|
|
62
|
+
* - `PasswordInput`: the value is a password or another secret.
|
|
63
|
+
* - `OtpInput`: the value is a one-time passcode.
|
|
64
|
+
* - `Combobox`: the user picks the value from a list of suggestions.
|
|
65
|
+
* - `Query`: the field filters a list with free text and `key:value` qualifiers.
|
|
66
|
+
*
|
|
57
67
|
* @see https://mantle.ngrok.com/components/forms/input
|
|
58
68
|
*
|
|
59
69
|
* @example
|
package/dist/input.d.ts
CHANGED
|
@@ -1,6 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Re-exports for the Input component family.
|
|
3
|
+
*
|
|
4
|
+
* @see https://mantle.ngrok.com/components/forms/input
|
|
5
|
+
* @see https://mantle.ngrok.com/components/forms/password-input
|
|
6
|
+
*/
|
|
7
|
+
import { a as AutoComplete, c as WithInputType, i as InputProps, n as InputCapture, o as InputType, r as InputCaptureProps, s as WithAutoComplete, t as Input } from "./input-q8o5uMhW.js";
|
|
8
|
+
import { o as WithValidation, r as Validation } from "./field-BshcNVe_.js";
|
|
1
9
|
import { t as WithDataSlot } from "./data-slot-B-LqAcBB.js";
|
|
2
|
-
import { o as WithValidation, r as Validation } from "./field-V_gnkcmN.js";
|
|
3
|
-
import { a as AutoComplete, c as WithInputType, i as InputProps, n as InputCapture, o as InputType, r as InputCaptureProps, s as WithAutoComplete, t as Input } from "./input-Dx5owTCc.js";
|
|
4
10
|
import { ComponentProps } from "react";
|
|
5
11
|
/**
|
|
6
12
|
* The props for the `PasswordInput` component.
|
|
@@ -61,6 +67,12 @@ type PasswordInputProps = Omit<ComponentProps<"input">, "autoComplete" | "type">
|
|
|
61
67
|
* `type="text"`. Some password managers may pause autofill in this state,
|
|
62
68
|
* which is the intended security trade-off.
|
|
63
69
|
*
|
|
70
|
+
* @useWhen Accept a password or another secret value, with a button that shows or hides it.
|
|
71
|
+
*
|
|
72
|
+
* @siblings
|
|
73
|
+
* - `Input`: the value is never sensitive.
|
|
74
|
+
* - `OtpInput`: the value is a one-time passcode.
|
|
75
|
+
*
|
|
64
76
|
* @see https://mantle.ngrok.com/components/forms/password-input
|
|
65
77
|
*
|
|
66
78
|
* @example
|
|
@@ -107,4 +119,24 @@ declare const PasswordInput: ({ "data-slot": dataSlot, disabled, id: idProp, onV
|
|
|
107
119
|
* ```
|
|
108
120
|
*/
|
|
109
121
|
export declare function isInput(value: unknown): value is HTMLInputElement;
|
|
122
|
+
/**
|
|
123
|
+
* Attributes that tell 1Password, Bitwarden, Dashlane, LastPass, and Proton
|
|
124
|
+
* Pass to skip an input: no badge, no fill, no save prompt. Spread them on an
|
|
125
|
+
* input that is not a credential, such as a search or filter box.
|
|
126
|
+
*
|
|
127
|
+
* Do not spread them on a one-time-code input. Most of these managers fill
|
|
128
|
+
* one-time codes, and an ignore attribute stops that fill.
|
|
129
|
+
*
|
|
130
|
+
* @example
|
|
131
|
+
* ```tsx
|
|
132
|
+
* <Input type="search" aria-label="Search" {...passwordManagerIgnoreProps} />
|
|
133
|
+
* ```
|
|
134
|
+
*/
|
|
135
|
+
export declare const passwordManagerIgnoreProps: {
|
|
136
|
+
readonly "data-1p-ignore": true;
|
|
137
|
+
readonly "data-bwignore": true;
|
|
138
|
+
readonly "data-form-type": "other";
|
|
139
|
+
readonly "data-lpignore": "true";
|
|
140
|
+
readonly "data-protonpass-ignore": true;
|
|
141
|
+
};
|
|
110
142
|
export { type AutoComplete, Input, InputCapture, type InputCaptureProps, type InputProps, type InputType, PasswordInput, type PasswordInputProps, type Validation, type WithAutoComplete, type WithInputType, type WithValidation };
|
package/dist/input.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{n as e,t}from"./input-DHovzBjS.js";import{t as n}from"./use-isomorphic-layout-effect-CLSmHzo4.js";import{t as r}from"./use-prefers-reduced-motion-CU6mWmOe.js";import{t as i}from"./icon-kK0c-POG.js";import{t as a}from"./data-slot-EM6s2WEU.js";import{t as o}from"./input-DQyN6gN0.js";import{t as s}from"./input-BjCDSOPA.js";import{c}from"react/compiler-runtime";import{useId as l,useRef as u,useState as d}from"react";import{jsx as f,jsxs as p}from"react/jsx-runtime";import{EyeIcon as m}from"@phosphor-icons/react/Eye";import{EyeClosedIcon as h}from"@phosphor-icons/react/EyeClosed";const g=o=>{let s=c(34),g,_,v,y,b,x,S;s[0]===o?(g=s[1],_=s[2],v=s[3],y=s[4],b=s[5],x=s[6],S=s[7]):({"data-slot":g,disabled:_,id:v,onValueVisibilityChange:y,ref:x,showValue:S,...b}=o,s[0]=o,s[1]=g,s[2]=_,s[3]=v,s[4]=y,s[5]=b,s[6]=x,s[7]=S);let C=l(),w=v??C,T=S!=null,[E,D]=d(!1),O=T?S:E,k=O?`text`:`password`,A=O?m:h,j=u(null),M=u(O),N,P;s[8]===O?(N=s[9],P=s[10]):(N=()=>{if(M.current===O)return;M.current=O;let e=j.current;e==null||r()||e.animate([{scale:`1 0.5`},{scale:`1`}],{duration:200,easing:`cubic-bezier(0.23, 1, 0.32, 1)`})},P=[O],s[8]=O,s[9]=N,s[10]=P),n(N,P);let F;s[11]===g?F=s[12]:(F=a(g,`password-input`),s[11]=g,s[12]=F);let I;s[13]===Symbol.for(`react.memo_cache_sentinel`)?(I=/* @__PURE__ */ f(e,{}),s[13]=I):I=s[13];let L;s[14]!==T||s[15]!==y||s[16]!==O?(L=()=>{let e=!O;T||D(e),y?.(e)},s[14]=T,s[15]=y,s[16]=O,s[17]=L):L=s[17];let R;s[18]===A?R=s[19]:(R=/* @__PURE__ */ f(i,{ref:j,svg:/* @__PURE__ */ f(A,{"aria-hidden":!0})}),s[18]=A,s[19]=R);let z;s[20]!==_||s[21]!==w||s[22]!==O||s[23]!==L||s[24]!==R?(z=/* @__PURE__ */ f(`button`,{type:`button`,disabled:_,"data-slot":`password-input-toggle`,"aria-label":`Show value`,"aria-pressed":O,"aria-controls":w,className:`text-body hover:text-strong focus-visible:ring-focus-accent ml-1 cursor-pointer rounded-xs bg-inherit p-0 focus-visible:ring-2 focus-visible:outline-hidden`,onClick:L,children:R}),s[20]=_,s[21]=w,s[22]=O,s[23]=L,s[24]=R,s[25]=z):z=s[25];let B;return s[26]!==_||s[27]!==w||s[28]!==b||s[29]!==x||s[30]!==F||s[31]!==z||s[32]!==k?(B=/* @__PURE__ */ p(t,{"data-slot":F,disabled:_,id:w,type:k,ref:x,...b,children:[I,z]}),s[26]=_,s[27]=w,s[28]=b,s[29]=x,s[30]=F,s[31]=z,s[32]=k,s[33]=B):B=s[33],B};export{t as Input,e as InputCapture,g as PasswordInput,o as isInput,s as passwordManagerIgnoreProps};
|
package/dist/kbd.d.ts
CHANGED
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Re-exports for the Kbd component.
|
|
3
|
+
*
|
|
4
|
+
* @see https://mantle.ngrok.com/components/data-display/kbd
|
|
5
|
+
*/
|
|
1
6
|
import { t as WithDataSlot } from "./data-slot-B-LqAcBB.js";
|
|
2
7
|
import { ComponentProps } from "react";
|
|
3
8
|
/**
|
|
@@ -27,6 +32,13 @@ import { ComponentProps } from "react";
|
|
|
27
32
|
* key the reader's keyboard does not have. The `translate` prop is omitted from
|
|
28
33
|
* the type, so no call site can turn the guard off.
|
|
29
34
|
*
|
|
35
|
+
* @useWhen Show a keyboard key or a shortcut hint, such as `⌘` and `K`, in prose, a tooltip, or a
|
|
36
|
+
* menu item.
|
|
37
|
+
*
|
|
38
|
+
* @siblings
|
|
39
|
+
* - `Code`: the text is a fragment of code, not a key.
|
|
40
|
+
* - `Badge`: the label is a status, a category, or a count.
|
|
41
|
+
*
|
|
30
42
|
* @see https://mantle.ngrok.com/components/data-display/kbd
|
|
31
43
|
* @see https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Global_attributes/translate
|
|
32
44
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as e}from"./
|
|
1
|
+
import{t as e}from"./booleanish-BfvnW6vy.js";import{t}from"./cx-CK7o_rVv.js";import{t as n}from"./data-slot-EM6s2WEU.js";import{c as r}from"react/compiler-runtime";import{jsx as i}from"react/jsx-runtime";const a=a=>{let o=r(26),s,c,l,u,d,f,p,m;o[0]===a?(s=o[1],c=o[2],l=o[3],u=o[4],d=o[5],f=o[6],p=o[7],m=o[8]):({"data-slot":u,"aria-disabled":s,children:c,className:l,disabled:d,onMouseDown:f,ref:m,...p}=a,o[0]=a,o[1]=s,o[2]=c,o[3]=l,o[4]=u,o[5]=d,o[6]=f,o[7]=p,o[8]=m);let h;o[9]!==s||o[10]!==d?(h=e(d??s)||void 0,o[9]=s,o[10]=d,o[11]=h):h=o[11];let g;o[12]===u?g=o[13]:(g=n(u,`label`),o[12]=u,o[13]=g);let _;o[14]===l?_=o[15]:(_=t(`text-strong cursor-pointer text-sm peer-disabled:cursor-default has-disabled:cursor-default data-disabled:cursor-default font-sans`,`[:where(&:not(:has(input,textarea,select,button,[contenteditable])))]:font-medium`,l),o[14]=l,o[15]=_);let v;o[16]===f?v=o[17]:(v=e=>{e.target instanceof Element&&e.target.closest(`button, input, select, textarea`)||(f?.(e),!e.defaultPrevented&&e.detail>1&&e.preventDefault())},o[16]=f,o[17]=v);let y;return o[18]!==c||o[19]!==p||o[20]!==m||o[21]!==h||o[22]!==g||o[23]!==_||o[24]!==v?(y=/* @__PURE__ */ i(`label`,{"data-disabled":h,"data-slot":g,className:_,onMouseDown:v,ref:m,...p,children:c}),o[18]=c,o[19]=p,o[20]=m,o[21]=h,o[22]=g,o[23]=_,o[24]=v,o[25]=y):y=o[25],y};export{a as t};
|
|
@@ -42,6 +42,12 @@ type LabelProps = ComponentProps<"label"> & {
|
|
|
42
42
|
* passing a font-weight utility on the `Label` itself, e.g.
|
|
43
43
|
* `<Label className="font-bold">`.
|
|
44
44
|
*
|
|
45
|
+
* @useWhen Give a form control a visible caption that names it and focuses it on a click.
|
|
46
|
+
*
|
|
47
|
+
* @siblings
|
|
48
|
+
* - `Field`: the control also needs a description or validation errors.
|
|
49
|
+
* - `Choice`: the control needs a title and a description beside it.
|
|
50
|
+
*
|
|
45
51
|
* @see https://mantle.ngrok.com/components/forms/label
|
|
46
52
|
*
|
|
47
53
|
* @example
|
package/dist/label.d.ts
CHANGED
package/dist/label.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export{t as Label}from"./label-
|
|
1
|
+
export{t as Label}from"./label-DmDwzPD8.js";
|