@jonmilner/ui 0.25.2 → 0.25.3
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/Alert/Alert.css +1 -1
- package/dist/Avatar/Avatar.css +1 -1
- package/dist/Badge/Badge.css +1 -1
- package/dist/Box/Box.css +1 -1
- package/dist/Button/Button.css +1 -1
- package/dist/Checkbox/Checkbox.css +1 -1
- package/dist/Chip/Chip.css +1 -1
- package/dist/Clickable/Clickable.css +1 -1
- package/dist/ClickableBox/ClickableBox.css +1 -1
- package/dist/Code/Code.css +1 -1
- package/dist/ColorField/ColorField.css +1 -1
- package/dist/Combobox/Combobox.css +1 -1
- package/dist/Dialog/Dialog.css +1 -1
- package/dist/Dialog/client.d.mts +1 -1
- package/dist/Dialog/client.mjs +32 -51
- package/dist/Drawer/Drawer.css +2 -0
- package/dist/Drawer/Drawer.css.mjs +7 -0
- package/dist/Drawer/client.d.mts +12 -0
- package/dist/Drawer/client.mjs +96 -0
- package/dist/Drawer/index.d.mts +27 -0
- package/dist/Drawer/index.mjs +118 -0
- package/dist/Field/Field.css +1 -1
- package/dist/Heading/Heading.css +1 -1
- package/dist/Icon/Icon.css +1 -1
- package/dist/IconButton/IconButton.css +1 -1
- package/dist/Inline/Inline.css +1 -1
- package/dist/Link/Link.css +1 -1
- package/dist/Markdown/Markdown.css +1 -1
- package/dist/Menu/Menu.css +1 -1
- package/dist/MultiSelect/MultiSelect.css +1 -1
- package/dist/NavList/NavList.css +1 -1
- package/dist/NumberField/NumberField.css +1 -1
- package/dist/Popover/Popover.css +1 -1
- package/dist/RadioGroup/RadioGroup.css +1 -1
- package/dist/SearchField/SearchField.css +1 -1
- package/dist/Select/Select.css +1 -1
- package/dist/Sidebar/Sidebar.css +1 -1
- package/dist/SidebarLayout/SidebarLayout.css +1 -1
- package/dist/Stack/Stack.css +1 -1
- package/dist/Switch/Switch.css +1 -1
- package/dist/TabBar/TabBar.css +2 -0
- package/dist/TabBar/TabBar.css.mjs +7 -0
- package/dist/TabBar/index.d.mts +25 -0
- package/dist/TabBar/index.mjs +61 -0
- package/dist/Table/Table.css +1 -1
- package/dist/Tabs/Tabs.css +1 -1
- package/dist/Tag/Tag.css +1 -1
- package/dist/Text/Text.css +1 -1
- package/dist/TextField/TextField.css +1 -1
- package/dist/Textarea/Textarea.css +1 -1
- package/dist/Toast/Toast.css +1 -1
- package/dist/Tooltip/Tooltip.css +1 -1
- package/dist/VisuallyHidden/VisuallyHidden.css +1 -1
- package/dist/base.css +1 -1
- package/dist/docs/Dialog.md +1 -0
- package/dist/docs/Drawer.md +156 -0
- package/dist/docs/NavList.md +1 -0
- package/dist/docs/Sidebar.md +1 -0
- package/dist/docs/TabBar.md +135 -0
- package/dist/docs/Tabs.md +1 -1
- package/dist/docs/llms.txt +2 -0
- package/dist/docs/manifest.json +235 -1
- package/dist/index.d.mts +5 -2
- package/dist/index.mjs +37 -35
- package/dist/popup/client.mjs +1 -1
- package/dist/popup/modal-frame.d.mts +3 -0
- package/dist/popup/modal-frame.mjs +30 -0
- package/dist/styles/atoms.css +1 -1
- package/dist/styles/layers.css +1 -1
- package/dist/styles/responsive.css +1 -1
- package/dist/styles/scroll-region.css +1 -1
- package/dist/styles/status-message.css +1 -1
- package/package.json +9 -1
package/dist/docs/NavList.md
CHANGED
|
@@ -14,6 +14,7 @@ A column of links to an app's pages, with the current page marked: a sidebar's o
|
|
|
14
14
|
## When not to use
|
|
15
15
|
|
|
16
16
|
- Switching views that share one page and keep the URL: use `Tabs`.
|
|
17
|
+
- An app's three to five top-level sections along the bottom of a phone screen, icon above label: use `TabBar`.
|
|
17
18
|
- An item that runs an action or command, such as Sign out or New project: use `Menu` or `Button`. The link itself only navigates. An action that belongs to one row, such as Rename or Delete for that row's page, goes beside the link in `action` (ADR 0169).
|
|
18
19
|
- Links in running text, or one link on its own: use a link (`Clickable as="a"`).
|
|
19
20
|
- A tree of collapsible or nested groups, or a drawer that slides in on a phone: not supported. One level of groups, always open.
|
package/dist/docs/Sidebar.md
CHANGED
|
@@ -13,6 +13,7 @@ An app's sidebar: a named `aside` on the `bgPanel` surface, with a header row, t
|
|
|
13
13
|
|
|
14
14
|
- A sidebar that never collapses and needs no surface or footer: `SidebarLayout.Sidebar` alone, with a `NavList` in it.
|
|
15
15
|
- A drawer that slides over the page on a phone: not supported. Below 48em of the layout's width the sidebar stacks above the page, full width.
|
|
16
|
+
- An app's three to five top-level sections on a phone: use `TabBar` along the bottom of the screen; the app's layout shows it in place of the sidebar there.
|
|
16
17
|
- Secondary content beside the page (filters, an outline): `SidebarLayout.Sidebar as="aside"`.
|
|
17
18
|
|
|
18
19
|
## Rules
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
# TabBar
|
|
2
|
+
|
|
3
|
+
## Purpose
|
|
4
|
+
|
|
5
|
+
A bar along the bottom of a phone screen that moves between an app's three to five top-level sections. The parts are `TabBar` (a named `nav` around a list) and `TabBar.Item` (one link: an icon above a one- or two-word label, with an optional count beside the icon). The items share the bar's width equally. Items are links inside a `nav` landmark, not ARIA tabs: an `<a>` by default, or a router's `Link` through `as`, which keeps the router's props typed. The app says which item is current; TabBar reads nothing from the URL (ADR 0205).
|
|
6
|
+
|
|
7
|
+
## When to use
|
|
8
|
+
|
|
9
|
+
- A phone-first app's top-level sections, always one tap away at the bottom of the screen: Recipes, Plan, Shopping, On hand.
|
|
10
|
+
- Three to five sections of equal weight, each its own route, each with an icon and a short label.
|
|
11
|
+
- A section with a count worth seeing from anywhere (items left to buy, unread messages): `count` beside its icon.
|
|
12
|
+
|
|
13
|
+
## When not to use
|
|
14
|
+
|
|
15
|
+
- The same links on a wide screen, or more than five of them: use `NavList`, in a `Sidebar` when they run down the side of the page. An app that shows a TabBar on a phone and a Sidebar on a wide screen renders both and hides one in its own layout; TabBar does not hide itself.
|
|
16
|
+
- Switching panels inside one page that keep the URL: use `Tabs`. TabBar's items change the page.
|
|
17
|
+
- An action or command, such as New recipe or Sign out: use `Button`, `IconButton` or `Menu`. An item only navigates.
|
|
18
|
+
- Fixing the bar to the viewport: the app's layout does that (`position: fixed` or a sticky footer row). TabBar is a plain block that sits where it is rendered.
|
|
19
|
+
|
|
20
|
+
## Rules
|
|
21
|
+
|
|
22
|
+
- `TabBar` needs a name, and its type requires one: `aria-label` ("Sections", "Main") or `aria-labelledby`. A page with another `nav` tells them apart by these names. Its props land on the `nav`.
|
|
23
|
+
- Children are three to five `TabBar.Item`s. The bar puts them in one row of equal columns, whatever their labels; more than five is not supported.
|
|
24
|
+
- `TabBar.Item` is an `<a>` by default: pass `href`. With `as={Link}`, it takes the router's props instead (`to`, `prefetch`) and its type checks them. Every other prop, `ref` and the style props included, lands on the link; the `li` around it takes none. Use the router's plain `Link`, not a `NavLink` that sets `aria-current` itself.
|
|
25
|
+
- `icon` is required: an icon component (`icon={InboxIcon}`), drawn at `xl` (20px) above the label and hidden from assistive tech, since the label names the link.
|
|
26
|
+
- The label is the item's children: a word or two of text, `xs` and medium. It stays on one line; a label too long for its column ends in an ellipsis, and the link's name keeps the full text.
|
|
27
|
+
- `current` marks the link to the section on screen: `aria-current="page"`, the `accent` colour, a semibold label, and a 2px `accent` line, 32px wide, on the bar's top edge above the item. Set it on one item at most. It is the only way to set `aria-current`: the type omits the raw attribute.
|
|
28
|
+
- `count` is a subtle `Badge` at `xs` beside the icon, at its inline-end top corner; the icon stays centred. It is part of the link's accessible name, read after the label, so a bare number says nothing ("Shopping 6"). Give it its meaning with `VisuallyHidden`: `count={<>6<VisuallyHidden> left to buy</VisuallyHidden></>}`. A nullish, boolean or empty count renders nothing, but a `0` or a fragment around one does not: guard it (`left > 0 && <>…</>`) to hide a zero. Keep it short: two or three characters.
|
|
29
|
+
- The bar is `bg` with one `border` separator along its top, `8` of inline padding, and `env(safe-area-inset-bottom)` of padding below the items (at least `4`, so a focus ring stays inside the bar), so they clear a phone's home indicator. That inset is 0 unless the page's viewport meta has `viewport-fit=cover`. The background and inline padding are default style props, so the consumer's win; the separator and the bottom inset are the component's CSS.
|
|
30
|
+
- Items are at least 56px (`xl`) high, `fgMuted` with `4` of inline padding and a `med` radius, as default style props; the consumer's win. Hover turns a non-current item `fg` where hover is real (`(hover: hover)`).
|
|
31
|
+
- A server component can render the whole bar, router `Link` included: no part has hooks.
|
|
32
|
+
|
|
33
|
+
## Do
|
|
34
|
+
|
|
35
|
+
```tsx
|
|
36
|
+
<TabBar aria-label="Sections">
|
|
37
|
+
<TabBar.Item href="/recipes" icon={BookIcon}>
|
|
38
|
+
Recipes
|
|
39
|
+
</TabBar.Item>
|
|
40
|
+
<TabBar.Item href="/plan" icon={ClipboardIcon}>
|
|
41
|
+
Plan
|
|
42
|
+
</TabBar.Item>
|
|
43
|
+
<TabBar.Item
|
|
44
|
+
count={
|
|
45
|
+
<>
|
|
46
|
+
6<VisuallyHidden> left to buy</VisuallyHidden>
|
|
47
|
+
</>
|
|
48
|
+
}
|
|
49
|
+
current
|
|
50
|
+
href="/shopping"
|
|
51
|
+
icon={ShoppingCartIcon}
|
|
52
|
+
>
|
|
53
|
+
Shopping
|
|
54
|
+
</TabBar.Item>
|
|
55
|
+
<TabBar.Item href="/on-hand" icon={RefrigeratorIcon}>
|
|
56
|
+
On hand
|
|
57
|
+
</TabBar.Item>
|
|
58
|
+
</TabBar>
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
```tsx
|
|
62
|
+
// A router's link: its props stay typed. The router says which item is current. The app's layout
|
|
63
|
+
// fixes the bar to the bottom of the screen.
|
|
64
|
+
<TabBar aria-label="Sections" className={layout.bottomBar}>
|
|
65
|
+
{sections.map((section) => (
|
|
66
|
+
<TabBar.Item
|
|
67
|
+
as={Link}
|
|
68
|
+
current={pathname.startsWith(section.to)}
|
|
69
|
+
icon={section.icon}
|
|
70
|
+
key={section.to}
|
|
71
|
+
to={section.to}
|
|
72
|
+
>
|
|
73
|
+
{section.label}
|
|
74
|
+
</TabBar.Item>
|
|
75
|
+
))}
|
|
76
|
+
</TabBar>
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
## Don't
|
|
80
|
+
|
|
81
|
+
```tsx
|
|
82
|
+
// No name: another nav on the page could not be told apart. The type rejects it.
|
|
83
|
+
<TabBar>
|
|
84
|
+
<TabBar.Item href="/" icon={InboxIcon}>
|
|
85
|
+
Inbox
|
|
86
|
+
</TabBar.Item>
|
|
87
|
+
</TabBar>
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
```tsx
|
|
91
|
+
// A sentence for a label: it cannot fit a fifth of a phone's width, so it is cut short.
|
|
92
|
+
<TabBar.Item href="/shopping" icon={ShoppingCartIcon}>
|
|
93
|
+
Your shopping list for this week
|
|
94
|
+
</TabBar.Item>
|
|
95
|
+
```
|
|
96
|
+
|
|
97
|
+
```tsx
|
|
98
|
+
// A button that runs an action: a TabBar item navigates. Put the action in the page.
|
|
99
|
+
<TabBar.Item as="button" icon={PlusIcon} onClick={addRecipe}>
|
|
100
|
+
Add
|
|
101
|
+
</TabBar.Item>
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
## Accessibility
|
|
105
|
+
|
|
106
|
+
- A `nav` landmark named by its `aria-label` or `aria-labelledby`, around a native list: screen readers announce the landmark and the number of links, and their landmark commands reach it (WAI-ARIA landmarks). These are links, not ARIA tabs: no `tablist` role and no arrow-key model, since each item loads a page.
|
|
107
|
+
- The current item has `aria-current="page"`, announced as "current page". Its line and semibold label show it without colour alone (WCAG 1.4.1). Under forced colours the line is `Highlight`.
|
|
108
|
+
- Label text is `fgMuted`, and the current item's `accent`, on the bar's `bg`: both are checked 4.5:1 pairs in light and dark (ADR 0031).
|
|
109
|
+
- The icon is hidden; the label and the count, with its meaning, make the link's name. A truncated label keeps its full text in the name.
|
|
110
|
+
- Links are in the tab order in reading order and show the shared focus ring. Every item is at least 56px high and a quarter to a fifth of the bar wide, past the 24px floor (WCAG 2.5.8, ADR 0124) and the 44px touch guideline.
|
|
111
|
+
|
|
112
|
+
## Props
|
|
113
|
+
|
|
114
|
+
Generated from the TypeScript types.
|
|
115
|
+
|
|
116
|
+
### TabBar
|
|
117
|
+
|
|
118
|
+
| Prop | Type | Required | Description |
|
|
119
|
+
| --- | --- | --- | --- |
|
|
120
|
+
| `aria-label` | `string` | no | Defines a string value that labels the current element. |
|
|
121
|
+
| `aria-labelledby` | `string` | no | Identifies the element (or elements) that labels the current element. |
|
|
122
|
+
|
|
123
|
+
Also accepts the style props (see `manifest.json` `styleProps`).
|
|
124
|
+
|
|
125
|
+
### TabBar.Item
|
|
126
|
+
|
|
127
|
+
| Prop | Type | Required | Description |
|
|
128
|
+
| --- | --- | --- | --- |
|
|
129
|
+
| `as` | `ElementType` | no | |
|
|
130
|
+
| `children` | `ReactNode` | yes | |
|
|
131
|
+
| `count` | `ReactNode` | no | |
|
|
132
|
+
| `current` | `boolean` | no | |
|
|
133
|
+
| `icon` | `ComponentType` | yes | |
|
|
134
|
+
|
|
135
|
+
Also accepts every `<a>` attribute (change the element with `as`) and the style props (see `manifest.json` `styleProps`).
|
package/dist/docs/Tabs.md
CHANGED
|
@@ -11,7 +11,7 @@ Switches between views that share one place on the page. The parts are `Tabs` (t
|
|
|
11
11
|
|
|
12
12
|
## When not to use
|
|
13
13
|
|
|
14
|
-
- Moving between pages or routes: use `NavList`, or links (`Clickable as="a"`) in a `nav`. Tabs do not change the URL and the panels are not separate pages.
|
|
14
|
+
- Moving between pages or routes: use `NavList`, `TabBar` for an app's top-level sections along the bottom of a phone screen, or links (`Clickable as="a"`) in a `nav`. Tabs do not change the URL and the panels are not separate pages.
|
|
15
15
|
- A sequence the user must go through in order: use a stepper.
|
|
16
16
|
- Two or three options that set a value in a form: use `RadioGroup`.
|
|
17
17
|
- Content that should be readable at once, or compared side by side: show it all, or use sections with headings.
|
package/dist/docs/llms.txt
CHANGED
|
@@ -30,6 +30,7 @@
|
|
|
30
30
|
- [ColorField](ColorField.md): A form field for one colour as a `#rrggbb` string: a swatch, the browser's own colour picker (`<input type="color">`), before a hex text input (role `textbox`) that holds the value. Picking a colour writes its hex; typing a valid hex moves the swatch. The hex input has TextField's look, with the swatch over its inline-start padding. Built on Base UI's `Input` and a native colour input, since Base UI has no colour picker (ADR 0003, 0114); it composes `Field` for its label, description and error (ADR 0026). Three sizes at Button's heights (`sm`, `med`, `lg`: 24, 32 and 40 px, ADR 0124); the swatch is 24px, or 32px in `lg`.
|
|
31
31
|
- [Combobox](Combobox.md): A form field for picking one value, or any number with `multiple`, from a list long enough that the user types to narrow it. A trigger drawn as MultiSelect's opens a popup with a filter input above the options; typing keeps the options whose label holds the query, ignoring case and accents. Each picked option shows a check mark, and the trigger shows the picked label, or with `multiple` the joined labels, then a count ("3 selected") once they would not fit. Built on Base UI's `Combobox` (ADR 0003, 0142), which owns the keyboard and focus: focus moves into the filter as the popup opens and stays there, the arrow keys move the highlight, Enter picks, Esc and an outside click close it, and focus returns to the trigger. It shares MultiSelect's and Select's trigger, popup, option rows and summary (ADR 0134, 0142) and composes `Field` for its label, description and error (ADR 0026).
|
|
32
32
|
- [Dialog](Dialog.md): A modal panel over the page for one short task: edit a name, fill a small form, read details that need a decision. Built on Base UI's Dialog, which owns the behavior: focus moves into the dialog and stays there, the page behind is hidden from assistive tech and does not scroll, Esc and a click on the backdrop close it, and focus returns to the trigger. The parts add the look: a dimmed backdrop, a raised panel with a title, and a zoom-and-fade that is a plain fade under reduced motion.
|
|
33
|
+
- [Drawer](Drawer.md): A modal panel that slides up from the bottom edge, for a short task or a few actions tied to the page behind it, without leaving that page, on a touch screen. Built on Base UI's Drawer, which owns the behavior: focus moves into the panel and stays there, the page behind is hidden from assistive tech and does not scroll, and Esc, a press on the backdrop, the close button and a downward swipe all close it, with focus back on the trigger. The parts add the look: a dimmed backdrop, a panel with a drag handle, a title and a close button, and a slide that is a plain fade under reduced motion.
|
|
33
34
|
- [Field](Field.md): Wires one form control to its label, description and error: ids, `htmlFor`, `aria-describedby` and `aria-invalid`. It is input-agnostic: the control inside is Base UI's `Field.Control` or a Base UI control (Checkbox, Combobox), and Base UI does the wiring. The parts are `Field` (the root, a flex column), `Field.Label`, `Field.Description` and `Field.Error`. Built on Base UI `Field` (ADR 0003, 0026, 0046); `@base-ui/react` is a peer dependency, so the app's Base UI controls and Field share one copy of its contexts.
|
|
34
35
|
- [Flex](Flex.md): The flex primitive `Stack` and `Inline` are built from: a `Box` with `display="flex"` as a default style prop. It takes every `Box` prop, adds none, and has no class of its own, so `<Flex>` renders exactly `<Box display="flex">`.
|
|
35
36
|
- [Heading](Heading.md): Section and page headings. A `Text` with heading defaults: the `heading` font role, `semibold`, `sm` leading, and balanced line wrapping. The level (`as`) and the look (`size`) are separate, so the outline stays right whatever the design calls for.
|
|
@@ -52,6 +53,7 @@
|
|
|
52
53
|
- [SidebarLayout](SidebarLayout.md): A page's navigation or secondary column beside its main content. `SidebarLayout` is a wrapping flex row; `SidebarLayout.Sidebar` keeps a fixed width (`inlineSize="sidebar"`, 15rem) at the inline start and `SidebarLayout.Main` takes the rest. When the layout itself is narrower than 48em, the sidebar stacks above main at full width. It reads its own width through a container query, not the viewport's, so it stacks inside a narrow slot on a wide screen too. When wide, the sidebar is sticky: it stays in view while the page scrolls, capped at the viewport's height, and scrolls on its own when its content is taller. An optional `SidebarLayout.Header` spans the full width above both: wide, it pins to the top of the viewport and the sidebar sticks below it; stacked, it scrolls away with the page. Every part is a `Box` and takes style props, except the few the layout fixes (see Rules).
|
|
53
54
|
- [Stack](Stack.md): A vertical column of children with even space between them. `Stack` is a `Flex` (a `Box` with `display="flex"`) with `flexDirection="column"` as a default style prop, spaced by a required `gap`. Children render as they are: no wrapper per child.
|
|
54
55
|
- [Switch](Switch.md): Turns one setting on or off, and the change applies the moment it flips. Built on Base UI `Switch` (ADR 0003, 0137): a `span` with `role="switch"` and `aria-checked`, plus a hidden checkbox input that submits with a form. The span is a 24 px target with the shared focus ring around a pill track: off is an outlined track with the thumb at the start, on a filled `accent` track with the thumb at the end. It composes `Field` for its label, description and error (ADR 0026), with the label after the switch.
|
|
56
|
+
- [TabBar](TabBar.md): A bar along the bottom of a phone screen that moves between an app's three to five top-level sections. The parts are `TabBar` (a named `nav` around a list) and `TabBar.Item` (one link: an icon above a one- or two-word label, with an optional count beside the icon). The items share the bar's width equally. Items are links inside a `nav` landmark, not ARIA tabs: an `<a>` by default, or a router's `Link` through `as`, which keeps the router's props typed. The app says which item is current; TabBar reads nothing from the URL (ADR 0205).
|
|
55
57
|
- [Table](Table.md): Records in rows that share named columns, so a reader can scan and compare them: transactions, members, invoices. A native `table` with parts for each element (`Table.Head`, `Table.Body`, `Table.Foot`, `Table.Row`, `Table.HeaderCell`, `Table.Cell`, `Table.ColumnGroup`, `Table.Column`), and `Table.ScrollArea` for a table wider than its container. It has no `grid` role and no roving focus: a link, `Checkbox` or `Menu` in a cell keeps the page's tab order, and a screen reader's table commands work as on any table.
|
|
56
58
|
- [Tabs](Tabs.md): Switches between views that share one place on the page. The parts are `Tabs` (the root, a flex column; a row when vertical), `Tabs.List` (the `tablist`), `Tabs.Tab` (a `tab` button on `Clickable`) and `Tabs.Panel` (the `tabpanel`). Built on Base UI `Tabs` (ADR 0003, 0046): it owns the selection, one tab stop with arrow-key roving, `aria-selected`, and the ids that tie each tab to its panel. The selected tab shows an accent bar that fades and grows in (ADR 0049).
|
|
57
59
|
- [Tag](Tag.md): A label that puts content in a category: a topic, a label, a user-made category. A `span` with a subtle tone fill (gray by default) and an `xs` (4px) radius (a small mark's step in `docs/shape.md`, so wrapped lines stay inside the fill) around a `Text` in the `label` font. It can be read-only, a link, or removable. `appearance="outline"` swaps the fill for a 1px border, a `med` (8px) radius and a small dot in the tone's color, for a quieter label among dense content.
|
package/dist/docs/manifest.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "./manifest.schema.json",
|
|
3
3
|
"package": "@jonmilner/ui",
|
|
4
|
-
"version": "0.25.
|
|
4
|
+
"version": "0.25.3",
|
|
5
5
|
"components": [
|
|
6
6
|
{
|
|
7
7
|
"name": "Alert",
|
|
@@ -1185,6 +1185,187 @@
|
|
|
1185
1185
|
],
|
|
1186
1186
|
"exports": []
|
|
1187
1187
|
},
|
|
1188
|
+
{
|
|
1189
|
+
"name": "Drawer",
|
|
1190
|
+
"styleProps": false,
|
|
1191
|
+
"props": [
|
|
1192
|
+
{
|
|
1193
|
+
"name": "children",
|
|
1194
|
+
"type": "ReactNode",
|
|
1195
|
+
"required": false
|
|
1196
|
+
},
|
|
1197
|
+
{
|
|
1198
|
+
"name": "defaultOpen",
|
|
1199
|
+
"type": "boolean",
|
|
1200
|
+
"required": false,
|
|
1201
|
+
"description": "Whether the drawer is initially open.\n\nTo render a controlled drawer, use the `open` prop instead."
|
|
1202
|
+
},
|
|
1203
|
+
{
|
|
1204
|
+
"name": "onOpenChange",
|
|
1205
|
+
"type": "((open: boolean, eventDetails: DrawerRootChangeEventDetails) => void)",
|
|
1206
|
+
"required": false,
|
|
1207
|
+
"description": "Event handler called when the drawer is opened or closed."
|
|
1208
|
+
},
|
|
1209
|
+
{
|
|
1210
|
+
"name": "onOpenChangeComplete",
|
|
1211
|
+
"type": "((open: boolean) => void)",
|
|
1212
|
+
"required": false,
|
|
1213
|
+
"description": "Event handler called after any animations complete when the drawer is opened or closed."
|
|
1214
|
+
},
|
|
1215
|
+
{
|
|
1216
|
+
"name": "open",
|
|
1217
|
+
"type": "boolean",
|
|
1218
|
+
"required": false,
|
|
1219
|
+
"description": "Whether the drawer is currently open."
|
|
1220
|
+
}
|
|
1221
|
+
],
|
|
1222
|
+
"parts": [
|
|
1223
|
+
{
|
|
1224
|
+
"name": "Drawer.Actions",
|
|
1225
|
+
"styleProps": true,
|
|
1226
|
+
"props": []
|
|
1227
|
+
},
|
|
1228
|
+
{
|
|
1229
|
+
"name": "Drawer.Body",
|
|
1230
|
+
"styleProps": true,
|
|
1231
|
+
"props": []
|
|
1232
|
+
},
|
|
1233
|
+
{
|
|
1234
|
+
"name": "Drawer.Close",
|
|
1235
|
+
"styleProps": true,
|
|
1236
|
+
"props": [
|
|
1237
|
+
{
|
|
1238
|
+
"name": "iconEnd",
|
|
1239
|
+
"type": "ComponentType",
|
|
1240
|
+
"required": false
|
|
1241
|
+
},
|
|
1242
|
+
{
|
|
1243
|
+
"name": "iconStart",
|
|
1244
|
+
"type": "ComponentType",
|
|
1245
|
+
"required": false
|
|
1246
|
+
},
|
|
1247
|
+
{
|
|
1248
|
+
"name": "size",
|
|
1249
|
+
"type": "\"lg\" | \"med\" | \"sm\"",
|
|
1250
|
+
"required": false,
|
|
1251
|
+
"values": [
|
|
1252
|
+
"lg",
|
|
1253
|
+
"med",
|
|
1254
|
+
"sm"
|
|
1255
|
+
]
|
|
1256
|
+
},
|
|
1257
|
+
{
|
|
1258
|
+
"name": "uppercase",
|
|
1259
|
+
"type": "boolean",
|
|
1260
|
+
"required": false
|
|
1261
|
+
},
|
|
1262
|
+
{
|
|
1263
|
+
"name": "variant",
|
|
1264
|
+
"type": "\"ghost\" | \"primary\" | \"secondary\"",
|
|
1265
|
+
"required": false,
|
|
1266
|
+
"values": [
|
|
1267
|
+
"ghost",
|
|
1268
|
+
"primary",
|
|
1269
|
+
"secondary"
|
|
1270
|
+
]
|
|
1271
|
+
}
|
|
1272
|
+
]
|
|
1273
|
+
},
|
|
1274
|
+
{
|
|
1275
|
+
"name": "Drawer.Popup",
|
|
1276
|
+
"styleProps": true,
|
|
1277
|
+
"props": [
|
|
1278
|
+
{
|
|
1279
|
+
"name": "closeLabel",
|
|
1280
|
+
"type": "string",
|
|
1281
|
+
"required": false
|
|
1282
|
+
},
|
|
1283
|
+
{
|
|
1284
|
+
"name": "description",
|
|
1285
|
+
"type": "ReactNode",
|
|
1286
|
+
"required": false
|
|
1287
|
+
},
|
|
1288
|
+
{
|
|
1289
|
+
"name": "finalFocus",
|
|
1290
|
+
"type": "boolean | RefObject<HTMLElement | null> | ((closeType: InteractionType) => void | boolean | HTMLElement | null)",
|
|
1291
|
+
"required": false,
|
|
1292
|
+
"description": "Determines the element to focus when the drawer is closed.\n\n- `false`: Do not move focus.\n- `true`: Move focus based on the default behavior (trigger or previously focused element).\n- `RefObject`: Move focus to the ref element.\n- `function`: Called with the interaction type (`mouse`, `touch`, `pen`, or `keyboard`).\n Return an element to focus, `true` to use the default behavior, or `false`/`undefined` to do nothing."
|
|
1293
|
+
},
|
|
1294
|
+
{
|
|
1295
|
+
"name": "initialFocus",
|
|
1296
|
+
"type": "boolean | RefObject<HTMLElement | null> | ((openType: InteractionType) => void | boolean | HTMLElement | null)",
|
|
1297
|
+
"required": false,
|
|
1298
|
+
"description": "Determines the element to focus when the drawer is opened.\n\n- `false`: Do not move focus.\n- `true`: Move focus based on the default behavior (first tabbable element or popup).\n- `RefObject`: Move focus to the ref element.\n- `function`: Called with the interaction type (`mouse`, `touch`, `pen`, or `keyboard`).\n Return an element to focus, `true` to use the default behavior, or `false`/`undefined` to do nothing."
|
|
1299
|
+
},
|
|
1300
|
+
{
|
|
1301
|
+
"name": "title",
|
|
1302
|
+
"type": "string | number | bigint | Iterable<ReactNode> | Promise<AwaitedReactNode> | ReactElement<unknown, string | JSXElementConstructor<any>> | ReactPortal",
|
|
1303
|
+
"required": true
|
|
1304
|
+
}
|
|
1305
|
+
]
|
|
1306
|
+
},
|
|
1307
|
+
{
|
|
1308
|
+
"name": "Drawer.Trigger",
|
|
1309
|
+
"styleProps": true,
|
|
1310
|
+
"props": [
|
|
1311
|
+
{
|
|
1312
|
+
"name": "handle",
|
|
1313
|
+
"type": "DrawerHandle<unknown>",
|
|
1314
|
+
"required": false,
|
|
1315
|
+
"description": "A handle to associate the trigger with a drawer.\nCan be created with the Drawer.createHandle() method."
|
|
1316
|
+
},
|
|
1317
|
+
{
|
|
1318
|
+
"name": "iconEnd",
|
|
1319
|
+
"type": "ComponentType",
|
|
1320
|
+
"required": false
|
|
1321
|
+
},
|
|
1322
|
+
{
|
|
1323
|
+
"name": "iconStart",
|
|
1324
|
+
"type": "ComponentType",
|
|
1325
|
+
"required": false
|
|
1326
|
+
},
|
|
1327
|
+
{
|
|
1328
|
+
"name": "id",
|
|
1329
|
+
"type": "string",
|
|
1330
|
+
"required": false,
|
|
1331
|
+
"description": "ID of the trigger. In addition to being forwarded to the rendered element,\nit is also used to specify the active trigger for drawers in controlled mode (with the Drawer.Root `triggerId` prop)."
|
|
1332
|
+
},
|
|
1333
|
+
{
|
|
1334
|
+
"name": "payload",
|
|
1335
|
+
"type": "unknown",
|
|
1336
|
+
"required": false,
|
|
1337
|
+
"description": "A payload to pass to the drawer when it is opened."
|
|
1338
|
+
},
|
|
1339
|
+
{
|
|
1340
|
+
"name": "size",
|
|
1341
|
+
"type": "\"lg\" | \"med\" | \"sm\"",
|
|
1342
|
+
"required": false,
|
|
1343
|
+
"values": [
|
|
1344
|
+
"lg",
|
|
1345
|
+
"med",
|
|
1346
|
+
"sm"
|
|
1347
|
+
]
|
|
1348
|
+
},
|
|
1349
|
+
{
|
|
1350
|
+
"name": "uppercase",
|
|
1351
|
+
"type": "boolean",
|
|
1352
|
+
"required": false
|
|
1353
|
+
},
|
|
1354
|
+
{
|
|
1355
|
+
"name": "variant",
|
|
1356
|
+
"type": "\"ghost\" | \"primary\" | \"secondary\"",
|
|
1357
|
+
"required": false,
|
|
1358
|
+
"values": [
|
|
1359
|
+
"ghost",
|
|
1360
|
+
"primary",
|
|
1361
|
+
"secondary"
|
|
1362
|
+
]
|
|
1363
|
+
}
|
|
1364
|
+
]
|
|
1365
|
+
}
|
|
1366
|
+
],
|
|
1367
|
+
"exports": []
|
|
1368
|
+
},
|
|
1188
1369
|
{
|
|
1189
1370
|
"name": "Field",
|
|
1190
1371
|
"styleProps": true,
|
|
@@ -3571,6 +3752,59 @@
|
|
|
3571
3752
|
"parts": [],
|
|
3572
3753
|
"exports": []
|
|
3573
3754
|
},
|
|
3755
|
+
{
|
|
3756
|
+
"name": "TabBar",
|
|
3757
|
+
"styleProps": true,
|
|
3758
|
+
"props": [
|
|
3759
|
+
{
|
|
3760
|
+
"name": "aria-label",
|
|
3761
|
+
"type": "string",
|
|
3762
|
+
"required": false,
|
|
3763
|
+
"description": "Defines a string value that labels the current element."
|
|
3764
|
+
},
|
|
3765
|
+
{
|
|
3766
|
+
"name": "aria-labelledby",
|
|
3767
|
+
"type": "string",
|
|
3768
|
+
"required": false,
|
|
3769
|
+
"description": "Identifies the element (or elements) that labels the current element."
|
|
3770
|
+
}
|
|
3771
|
+
],
|
|
3772
|
+
"parts": [
|
|
3773
|
+
{
|
|
3774
|
+
"name": "TabBar.Item",
|
|
3775
|
+
"styleProps": true,
|
|
3776
|
+
"props": [
|
|
3777
|
+
{
|
|
3778
|
+
"name": "as",
|
|
3779
|
+
"type": "ElementType",
|
|
3780
|
+
"required": false
|
|
3781
|
+
},
|
|
3782
|
+
{
|
|
3783
|
+
"name": "children",
|
|
3784
|
+
"type": "ReactNode",
|
|
3785
|
+
"required": true
|
|
3786
|
+
},
|
|
3787
|
+
{
|
|
3788
|
+
"name": "count",
|
|
3789
|
+
"type": "ReactNode",
|
|
3790
|
+
"required": false
|
|
3791
|
+
},
|
|
3792
|
+
{
|
|
3793
|
+
"name": "current",
|
|
3794
|
+
"type": "boolean",
|
|
3795
|
+
"required": false
|
|
3796
|
+
},
|
|
3797
|
+
{
|
|
3798
|
+
"name": "icon",
|
|
3799
|
+
"type": "ComponentType",
|
|
3800
|
+
"required": true
|
|
3801
|
+
}
|
|
3802
|
+
],
|
|
3803
|
+
"element": "a"
|
|
3804
|
+
}
|
|
3805
|
+
],
|
|
3806
|
+
"exports": []
|
|
3807
|
+
},
|
|
3574
3808
|
{
|
|
3575
3809
|
"name": "Table",
|
|
3576
3810
|
"styleProps": true,
|
package/dist/index.d.mts
CHANGED
|
@@ -17,9 +17,11 @@ import { ColorField, ColorFieldProps } from "./ColorField/index.mjs";
|
|
|
17
17
|
import { Combobox, ComboboxOption, ComboboxProps } from "./Combobox/index.mjs";
|
|
18
18
|
import { Dialog, DialogActionsProps, DialogBodyProps, DialogPopupProps, DialogProps } from "./Dialog/index.mjs";
|
|
19
19
|
import { SearchFieldInputProps } from "./SearchField/client.mjs";
|
|
20
|
-
import {
|
|
20
|
+
import { Drawer, DrawerActionsProps, DrawerBodyProps, DrawerPopupProps, DrawerProps } from "./Drawer/index.mjs";
|
|
21
21
|
import { ColorFieldInputProps } from "./ColorField/client.mjs";
|
|
22
|
+
import { Field, FieldDescriptionProps, FieldErrorProps, FieldLabelProps, FieldProps } from "./Field/index.mjs";
|
|
22
23
|
import { Flex, FlexProps } from "./Flex/index.mjs";
|
|
24
|
+
import { DrawerCloseProps, DrawerTriggerProps } from "./Drawer/client.mjs";
|
|
23
25
|
import { Heading, HeadingLevel, HeadingProps, HeadingSize } from "./Heading/index.mjs";
|
|
24
26
|
import { Icon, IconProps } from "./Icon/index.mjs";
|
|
25
27
|
import { IconButton, IconButtonProps } from "./IconButton/index.mjs";
|
|
@@ -42,6 +44,7 @@ import { Sidebar, SidebarProps } from "./Sidebar/index.mjs";
|
|
|
42
44
|
import { SidebarLayout, SidebarLayoutHeaderProps, SidebarLayoutMainProps, SidebarLayoutProps, SidebarLayoutSidebarProps } from "./SidebarLayout/index.mjs";
|
|
43
45
|
import { Stack, StackProps } from "./Stack/index.mjs";
|
|
44
46
|
import { Switch, SwitchProps } from "./Switch/index.mjs";
|
|
47
|
+
import { TabBar, TabBarItemOwnProps, TabBarItemProps, TabBarProps } from "./TabBar/index.mjs";
|
|
45
48
|
import { Table, TableBodyProps, TableCellProps, TableColumnGroupProps, TableColumnProps, TableFootProps, TableHeadProps, TableHeaderCellProps, TableProps, TableRowProps, TableScrollAreaProps, TableSortDirection } from "./Table/index.mjs";
|
|
46
49
|
import { Tabs, TabsListProps, TabsPanelProps, TabsProps, TabsTabProps } from "./Tabs/index.mjs";
|
|
47
50
|
import { Tag, TagProps } from "./Tag/index.mjs";
|
|
@@ -56,4 +59,4 @@ import { ThemeProvider, ThemeProviderProps } from "./theme/ThemeProvider.mjs";
|
|
|
56
59
|
import { Toast } from "./Toast/index.mjs";
|
|
57
60
|
import { Tooltip, TooltipProps, TooltipProviderProps } from "./Tooltip/index.mjs";
|
|
58
61
|
import { VisuallyHidden, VisuallyHiddenProps } from "./VisuallyHidden/index.mjs";
|
|
59
|
-
export { Alert, AlertDialog, type AlertDialogProps, type AlertDialogTriggerProps, type AlertProps, Avatar, type AvatarProps, Badge, type BadgeProps, Body, type BodyProps, type BodySize, Box, type BoxProps, Button, type ButtonProps, Caption, type CaptionProps, Checkbox, type CheckboxProps, Chip, ChipGroup, type ChipGroupProps, type ChipProps, Clickable, ClickableBox, type ClickableBoxProps, type ClickableBoxTargetProps, type ClickableProps, Code, type CodeBlockProps, type CodeInlineProps, type CodeProps, ColorField, type ColorFieldInputProps, type ColorFieldProps, Combobox, type ComboboxOption, type ComboboxProps, Dialog, type DialogActionsProps, type DialogBodyProps, type DialogCloseProps, type DialogPopupProps, type DialogProps, type DialogTriggerProps, Field, type FieldDescriptionProps, type FieldErrorProps, type FieldLabelProps, type FieldProps, Flex, type FlexProps, Heading, type HeadingLevel, type HeadingProps, type HeadingSize, Icon, IconButton, type IconButtonProps, type IconProps, Inline, type InlineProps, Label, type LabelProps, type LabelSize, Link, type LinkProps, Markdown, type MarkdownComponents, type MarkdownLinkPolicy, type MarkdownNode, type MarkdownProps, Menu, type MenuGroupProps, type MenuItemProps, type MenuLinkItemProps, type MenuPopupProps, type MenuProps, type MenuSeparatorProps, type MenuSubmenuRootProps, type MenuSubmenuTriggerProps, type MenuTriggerProps, MultiSelect, type MultiSelectOption, type MultiSelectProps, NavList, type NavListGroupProps, type NavListItemOwnProps, type NavListItemProps, type NavListProps, NumberField, type NumberFieldInputProps, type NumberFieldProps, Popover, type PopoverCloseProps, type PopoverPopupProps, type PopoverProps, type PopoverTriggerProps, RadioGroup, type RadioGroupOption, type RadioGroupProps, Run, type RunProps, SearchField, type SearchFieldInputProps, type SearchFieldProps, Select, type SelectOption, type SelectProps, Sidebar, SidebarLayout, type SidebarLayoutHeaderProps, type SidebarLayoutMainProps, type SidebarLayoutProps, type SidebarLayoutSidebarProps, type SidebarProps, Stack, type StackProps, type StyleProps, Switch, type SwitchProps, Table, type TableBodyProps, type TableCellProps, type TableColumnGroupProps, type TableColumnProps, type TableFootProps, type TableHeadProps, type TableHeaderCellProps, type TableProps, type TableRowProps, type TableScrollAreaProps, type TableSortDirection, Tabs, type TabsListProps, type TabsPanelProps, type TabsProps, type TabsTabProps, Tag, type TagProps, Text, TextField, type TextFieldInputProps, type TextFieldProps, type TextProps, Textarea, type TextareaInputProps, type TextareaProps, type Theme, ThemeProvider, type ThemeProviderProps, Toast, type ToastOptions, type ToastProviderProps, type ToastVariant, Tooltip, type TooltipPopupProps, type TooltipProps, type TooltipProviderProps, type TooltipTriggerProps, VisuallyHidden, type VisuallyHiddenProps, defineTheme, useToast };
|
|
62
|
+
export { Alert, AlertDialog, type AlertDialogProps, type AlertDialogTriggerProps, type AlertProps, Avatar, type AvatarProps, Badge, type BadgeProps, Body, type BodyProps, type BodySize, Box, type BoxProps, Button, type ButtonProps, Caption, type CaptionProps, Checkbox, type CheckboxProps, Chip, ChipGroup, type ChipGroupProps, type ChipProps, Clickable, ClickableBox, type ClickableBoxProps, type ClickableBoxTargetProps, type ClickableProps, Code, type CodeBlockProps, type CodeInlineProps, type CodeProps, ColorField, type ColorFieldInputProps, type ColorFieldProps, Combobox, type ComboboxOption, type ComboboxProps, Dialog, type DialogActionsProps, type DialogBodyProps, type DialogCloseProps, type DialogPopupProps, type DialogProps, type DialogTriggerProps, Drawer, type DrawerActionsProps, type DrawerBodyProps, type DrawerCloseProps, type DrawerPopupProps, type DrawerProps, type DrawerTriggerProps, Field, type FieldDescriptionProps, type FieldErrorProps, type FieldLabelProps, type FieldProps, Flex, type FlexProps, Heading, type HeadingLevel, type HeadingProps, type HeadingSize, Icon, IconButton, type IconButtonProps, type IconProps, Inline, type InlineProps, Label, type LabelProps, type LabelSize, Link, type LinkProps, Markdown, type MarkdownComponents, type MarkdownLinkPolicy, type MarkdownNode, type MarkdownProps, Menu, type MenuGroupProps, type MenuItemProps, type MenuLinkItemProps, type MenuPopupProps, type MenuProps, type MenuSeparatorProps, type MenuSubmenuRootProps, type MenuSubmenuTriggerProps, type MenuTriggerProps, MultiSelect, type MultiSelectOption, type MultiSelectProps, NavList, type NavListGroupProps, type NavListItemOwnProps, type NavListItemProps, type NavListProps, NumberField, type NumberFieldInputProps, type NumberFieldProps, Popover, type PopoverCloseProps, type PopoverPopupProps, type PopoverProps, type PopoverTriggerProps, RadioGroup, type RadioGroupOption, type RadioGroupProps, Run, type RunProps, SearchField, type SearchFieldInputProps, type SearchFieldProps, Select, type SelectOption, type SelectProps, Sidebar, SidebarLayout, type SidebarLayoutHeaderProps, type SidebarLayoutMainProps, type SidebarLayoutProps, type SidebarLayoutSidebarProps, type SidebarProps, Stack, type StackProps, type StyleProps, Switch, type SwitchProps, TabBar, type TabBarItemOwnProps, type TabBarItemProps, type TabBarProps, Table, type TableBodyProps, type TableCellProps, type TableColumnGroupProps, type TableColumnProps, type TableFootProps, type TableHeadProps, type TableHeaderCellProps, type TableProps, type TableRowProps, type TableScrollAreaProps, type TableSortDirection, Tabs, type TabsListProps, type TabsPanelProps, type TabsProps, type TabsTabProps, Tag, type TagProps, Text, TextField, type TextFieldInputProps, type TextFieldProps, type TextProps, Textarea, type TextareaInputProps, type TextareaProps, type Theme, ThemeProvider, type ThemeProviderProps, Toast, type ToastOptions, type ToastProviderProps, type ToastVariant, Tooltip, type TooltipPopupProps, type TooltipProps, type TooltipProviderProps, type TooltipTriggerProps, VisuallyHidden, type VisuallyHiddenProps, defineTheme, useToast };
|
package/dist/index.mjs
CHANGED
|
@@ -14,38 +14,40 @@ import { Code as p } from "./Code/index.mjs";
|
|
|
14
14
|
import { ColorField as m } from "./ColorField/index.mjs";
|
|
15
15
|
import { Combobox as h } from "./Combobox/index.mjs";
|
|
16
16
|
import { Dialog as g } from "./Dialog/index.mjs";
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
import {
|
|
37
|
-
import {
|
|
38
|
-
import {
|
|
39
|
-
import {
|
|
40
|
-
import {
|
|
41
|
-
import {
|
|
42
|
-
import {
|
|
43
|
-
import {
|
|
44
|
-
import {
|
|
45
|
-
import {
|
|
46
|
-
import {
|
|
47
|
-
import {
|
|
48
|
-
import {
|
|
49
|
-
import {
|
|
50
|
-
import {
|
|
51
|
-
|
|
17
|
+
import { Drawer as _ } from "./Drawer/index.mjs";
|
|
18
|
+
import { Field as v } from "./Field/index.mjs";
|
|
19
|
+
import { Flex as y } from "./Flex/index.mjs";
|
|
20
|
+
import { Heading as b } from "./Heading/index.mjs";
|
|
21
|
+
import { Icon as x } from "./Icon/index.mjs";
|
|
22
|
+
import { IconButton as S } from "./IconButton/index.mjs";
|
|
23
|
+
import { Inline as C } from "./Inline/index.mjs";
|
|
24
|
+
import { Label as w } from "./Label/index.mjs";
|
|
25
|
+
import { Link as T } from "./Link/index.mjs";
|
|
26
|
+
import { Markdown as E } from "./Markdown/index.mjs";
|
|
27
|
+
import { Menu as D } from "./Menu/index.mjs";
|
|
28
|
+
import { MultiSelect as O } from "./MultiSelect/index.mjs";
|
|
29
|
+
import { NavList as k } from "./NavList/index.mjs";
|
|
30
|
+
import { NumberField as A } from "./NumberField/index.mjs";
|
|
31
|
+
import { Popover as j } from "./Popover/index.mjs";
|
|
32
|
+
import { RadioGroup as M } from "./RadioGroup/index.mjs";
|
|
33
|
+
import { Run as N } from "./Run/index.mjs";
|
|
34
|
+
import { SearchField as P } from "./SearchField/index.mjs";
|
|
35
|
+
import { Select as F } from "./Select/index.mjs";
|
|
36
|
+
import { Sidebar as I } from "./Sidebar/index.mjs";
|
|
37
|
+
import { SidebarLayout as L } from "./SidebarLayout/index.mjs";
|
|
38
|
+
import { Stack as R } from "./Stack/index.mjs";
|
|
39
|
+
import { Switch as z } from "./Switch/index.mjs";
|
|
40
|
+
import { TabBar as B } from "./TabBar/index.mjs";
|
|
41
|
+
import { Table as V } from "./Table/index.mjs";
|
|
42
|
+
import { Tabs as H } from "./Tabs/index.mjs";
|
|
43
|
+
import { Tag as U } from "./Tag/index.mjs";
|
|
44
|
+
import { Text as W } from "./Text/index.mjs";
|
|
45
|
+
import { Textarea as G } from "./Textarea/index.mjs";
|
|
46
|
+
import { TextField as K } from "./TextField/index.mjs";
|
|
47
|
+
import { defineTheme as q } from "./theme/define-theme.mjs";
|
|
48
|
+
import { ThemeProvider as J } from "./theme/ThemeProvider.mjs";
|
|
49
|
+
import { Toast as Y } from "./Toast/index.mjs";
|
|
50
|
+
import { useToast as X } from "./Toast/client.mjs";
|
|
51
|
+
import { Tooltip as Z } from "./Tooltip/index.mjs";
|
|
52
|
+
import { VisuallyHidden as Q } from "./VisuallyHidden/index.mjs";
|
|
53
|
+
export { e as Alert, t as AlertDialog, n as Avatar, r as Badge, i as Body, a as Box, o as Button, s as Caption, c as Checkbox, l as Chip, u as ChipGroup, d as Clickable, f as ClickableBox, p as Code, m as ColorField, h as Combobox, g as Dialog, _ as Drawer, v as Field, y as Flex, b as Heading, x as Icon, S as IconButton, C as Inline, w as Label, T as Link, E as Markdown, D as Menu, O as MultiSelect, k as NavList, A as NumberField, j as Popover, M as RadioGroup, N as Run, P as SearchField, F as Select, I as Sidebar, L as SidebarLayout, R as Stack, z as Switch, B as TabBar, V as Table, H as Tabs, U as Tag, W as Text, K as TextField, G as Textarea, J as ThemeProvider, Y as Toast, Z as Tooltip, Q as VisuallyHidden, q as defineTheme, X as useToast };
|
package/dist/popup/client.mjs
CHANGED
|
@@ -133,4 +133,4 @@ function S(e, { finalFocus: t, modal: n = !1, open: r, returnTo: c }) {
|
|
|
133
133
|
ref: b
|
|
134
134
|
};
|
|
135
135
|
}
|
|
136
|
-
export { m as PopupScope, g as triggerElement, S as useClosingRule, h as usePopupScope, _ as useRecordOpenChange };
|
|
136
|
+
export { m as PopupScope, v as attachRef, g as triggerElement, S as useClosingRule, h as usePopupScope, _ as useRecordOpenChange };
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { Box as e } from "../Box/base.mjs";
|
|
3
|
+
import { join as t } from "../styles/join.mjs";
|
|
4
|
+
import { useClosingRule as n } from "./client.mjs";
|
|
5
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
6
|
+
// src/popup/modal-frame.tsx
|
|
7
|
+
function i(e) {
|
|
8
|
+
return e && typeof e == "object" ? {
|
|
9
|
+
finalFocus: !1,
|
|
10
|
+
returnTo: e
|
|
11
|
+
} : { finalFocus: e !== void 0 && e !== !0 };
|
|
12
|
+
}
|
|
13
|
+
function a({ open: i, finalFocus: a, frame: o, returnTo: s, ref: c, className: l, style: u, ...d }) {
|
|
14
|
+
return /* @__PURE__ */ r(e, {
|
|
15
|
+
...d,
|
|
16
|
+
...o,
|
|
17
|
+
...n(c, {
|
|
18
|
+
finalFocus: a,
|
|
19
|
+
modal: !0,
|
|
20
|
+
open: i,
|
|
21
|
+
returnTo: s
|
|
22
|
+
}),
|
|
23
|
+
className: t(l, o.className),
|
|
24
|
+
style: {
|
|
25
|
+
...u,
|
|
26
|
+
...o.style
|
|
27
|
+
}
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
export { a as ModalPopupElement, i as closingFocus };
|