@plexui/vue 0.10.0 → 0.12.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/es/components/ButtonGroup/ButtonGroup.js +7 -0
- package/dist/es/components/ButtonGroup/ButtonGroup.js.map +1 -1
- package/dist/es/components/ButtonGroup/index.js.map +1 -1
- package/dist/es/components/ContextMenu/shared.js +3 -2
- package/dist/es/components/ContextMenu/shared.js.map +1 -1
- package/dist/es/components/Dialog/Dialog.js +135 -18
- package/dist/es/components/Dialog/Dialog.js.map +1 -1
- package/dist/es/components/Dialog/dialogSteps.js +85 -0
- package/dist/es/components/Dialog/dialogSteps.js.map +1 -0
- package/dist/es/components/Dialog/dialogViewport.js +74 -0
- package/dist/es/components/Dialog/dialogViewport.js.map +1 -0
- package/dist/es/components/Dialog/index.js +1 -1
- package/dist/es/components/Dialog/index.js.map +1 -1
- package/dist/es/components/Dialog/sheetDrag.js +2 -1
- package/dist/es/components/Dialog/sheetDrag.js.map +1 -1
- package/dist/es/components/IndexBar/IndexBar.js +215 -0
- package/dist/es/components/IndexBar/IndexBar.js.map +1 -0
- package/dist/es/components/IndexBar/index.js +2 -0
- package/dist/es/components/IndexBar/index.js.map +1 -0
- package/dist/es/components/MarkdownEditor/MarkdownEditor.js +149 -1
- package/dist/es/components/MarkdownEditor/MarkdownEditor.js.map +1 -1
- package/dist/es/components/Menu/Menu.js +54 -28
- package/dist/es/components/Menu/Menu.js.map +1 -1
- package/dist/es/components/Page/Page.js +2 -2
- package/dist/es/components/Page/Page.js.map +1 -1
- package/dist/es/components/PhoneLayout/PhoneLayout.js +50 -0
- package/dist/es/components/PhoneLayout/PhoneLayout.js.map +1 -0
- package/dist/es/components/PhoneLayout/index.js +2 -0
- package/dist/es/components/PhoneLayout/index.js.map +1 -0
- package/dist/es/components/Popover/Popover.js +1 -1
- package/dist/es/components/Popover/Popover.js.map +1 -1
- package/dist/es/components/Popover/deferredPointerDownOutside.js +59 -4
- package/dist/es/components/Popover/deferredPointerDownOutside.js.map +1 -1
- package/dist/es/components/Select/Select.js +2 -2
- package/dist/es/components/Select/Select.js.map +1 -1
- package/dist/es/components/Slider/Slider.js +34 -3
- package/dist/es/components/Slider/Slider.js.map +1 -1
- package/dist/es/components/SwipeActions/SwipeActions.js +374 -0
- package/dist/es/components/SwipeActions/SwipeActions.js.map +1 -0
- package/dist/es/components/SwipeActions/index.js +2 -0
- package/dist/es/components/SwipeActions/index.js.map +1 -0
- package/dist/es/components/Switch/Switch.js +3 -1
- package/dist/es/components/Switch/Switch.js.map +1 -1
- package/dist/es/components/TabBar/TabBar.js +23 -8
- package/dist/es/components/TabBar/TabBar.js.map +1 -1
- package/dist/es/components/TabBar/index.js.map +1 -1
- package/dist/es/components/Tabs/Tabs.js +1 -0
- package/dist/es/components/Tabs/Tabs.js.map +1 -1
- package/dist/es/components/TagInput/TagInput.js +3 -46
- package/dist/es/components/TagInput/TagInput.js.map +1 -1
- package/dist/es/components/Textarea/Textarea.js +1 -0
- package/dist/es/components/Textarea/Textarea.js.map +1 -1
- package/dist/es/components/Tip/Tip.js +276 -0
- package/dist/es/components/Tip/Tip.js.map +1 -0
- package/dist/es/components/Tip/index.js +2 -0
- package/dist/es/components/Tip/index.js.map +1 -0
- package/dist/es/components/Toast/ToastRenderer.js +30 -13
- package/dist/es/components/Toast/ToastRenderer.js.map +1 -1
- package/dist/es/components/Toast/Toaster.js +17 -6
- package/dist/es/components/Toast/Toaster.js.map +1 -1
- package/dist/es/components/Toast/toastLifecycle.js +113 -1
- package/dist/es/components/Toast/toastLifecycle.js.map +1 -1
- package/dist/es/components/Toolbar/Toolbar.js +3 -3
- package/dist/es/components/Toolbar/Toolbar.js.map +1 -1
- package/dist/es/composables/useEscCloseStack.js +8 -4
- package/dist/es/composables/useEscCloseStack.js.map +1 -1
- package/dist/es/composables/usePhoneSubmenu.js +3 -2
- package/dist/es/composables/usePhoneSubmenu.js.map +1 -1
- package/dist/es/lib/floatingBoundary.js +3 -1
- package/dist/es/lib/floatingBoundary.js.map +1 -1
- package/dist/es/lib/helpers.js +21 -0
- package/dist/es/lib/helpers.js.map +1 -1
- package/dist/es/lib/menuInitialFocus.js +5 -3
- package/dist/es/lib/menuInitialFocus.js.map +1 -1
- package/dist/es/lib/menuSubmenuPlacement.js +129 -5
- package/dist/es/lib/menuSubmenuPlacement.js.map +1 -1
- package/dist/es/lib/menuTriggerCover.js +10 -4
- package/dist/es/lib/menuTriggerCover.js.map +1 -1
- package/dist/es/lib/phoneLayout.js +16 -0
- package/dist/es/lib/phoneLayout.js.map +1 -0
- package/dist/es/lib/toastRegion.js +6 -0
- package/dist/es/lib/toastRegion.js.map +1 -0
- package/dist/types/components/ButtonGroup/ButtonGroup.d.ts +13 -0
- package/dist/types/components/ButtonGroup/index.d.ts +1 -1
- package/dist/types/components/ContextMenu/shared.d.ts +3 -2
- package/dist/types/components/Dialog/Dialog.d.ts +93 -3
- package/dist/types/components/Dialog/dialogSteps.d.ts +10 -0
- package/dist/types/components/Dialog/dialogViewport.d.ts +1 -0
- package/dist/types/components/Dialog/index.d.ts +1 -1
- package/dist/types/components/IndexBar/IndexBar.d.ts +112 -0
- package/dist/types/components/IndexBar/index.d.ts +1 -0
- package/dist/types/components/Menu/Menu.d.ts +14 -15
- package/dist/types/components/Page/Page.d.ts +2 -2
- package/dist/types/components/PhoneLayout/PhoneLayout.d.ts +21 -0
- package/dist/types/components/PhoneLayout/index.d.ts +1 -0
- package/dist/types/components/Popover/deferredPointerDownOutside.d.ts +1 -1
- package/dist/types/components/SwipeActions/SwipeActions.d.ts +135 -0
- package/dist/types/components/SwipeActions/index.d.ts +1 -0
- package/dist/types/components/TabBar/TabBar.d.ts +55 -6
- package/dist/types/components/TabBar/index.d.ts +1 -1
- package/dist/types/components/Tip/Tip.d.ts +146 -0
- package/dist/types/components/Tip/index.d.ts +1 -0
- package/dist/types/components/Toast/toastLifecycle.d.ts +34 -0
- package/dist/types/components/Toolbar/Toolbar.d.ts +9 -7
- package/dist/types/composables/useEscCloseStack.d.ts +2 -2
- package/dist/types/composables/usePhoneSubmenu.d.ts +2 -1
- package/dist/types/lib/helpers.d.ts +6 -0
- package/dist/types/lib/menuSubmenuPlacement.d.ts +9 -2
- package/dist/types/lib/phoneLayout.d.ts +11 -0
- package/dist/types/lib/toastRegion.d.ts +5 -0
- package/package.json +2 -2
|
@@ -6,6 +6,13 @@ export type TabBarSearch = {
|
|
|
6
6
|
/** Accessible name of the search tab. @default "Search" */
|
|
7
7
|
label?: string;
|
|
8
8
|
};
|
|
9
|
+
/** The prominent tab of a `TabBar`; its symbol is the `prominent-icon` slot of the bar (React `prominent.icon`). */
|
|
10
|
+
export type TabBarProminent = {
|
|
11
|
+
/** The value of the prominent tab. */
|
|
12
|
+
value: string;
|
|
13
|
+
/** Accessible name of the prominent tab: its circle shows the symbol only. */
|
|
14
|
+
label: string;
|
|
15
|
+
};
|
|
9
16
|
declare const TabBarItemComponent: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
10
17
|
/** The value of the tab. */
|
|
11
18
|
value: {
|
|
@@ -24,7 +31,7 @@ declare const TabBarItemComponent: import("vue").DefineComponent<import("vue").E
|
|
|
24
31
|
type: BooleanConstructor;
|
|
25
32
|
default: boolean;
|
|
26
33
|
};
|
|
27
|
-
/** @internal The search tab
|
|
34
|
+
/** @internal The search and the prominent tab show their symbol only. */
|
|
28
35
|
hideLabel: {
|
|
29
36
|
type: BooleanConstructor;
|
|
30
37
|
default: boolean;
|
|
@@ -52,7 +59,7 @@ declare const TabBarItemComponent: import("vue").DefineComponent<import("vue").E
|
|
|
52
59
|
type: BooleanConstructor;
|
|
53
60
|
default: boolean;
|
|
54
61
|
};
|
|
55
|
-
/** @internal The search tab
|
|
62
|
+
/** @internal The search and the prominent tab show their symbol only. */
|
|
56
63
|
hideLabel: {
|
|
57
64
|
type: BooleanConstructor;
|
|
58
65
|
default: boolean;
|
|
@@ -84,7 +91,7 @@ export declare const TabBarItem: import("vue").DefineComponent<import("vue").Ext
|
|
|
84
91
|
type: BooleanConstructor;
|
|
85
92
|
default: boolean;
|
|
86
93
|
};
|
|
87
|
-
/** @internal The search tab
|
|
94
|
+
/** @internal The search and the prominent tab show their symbol only. */
|
|
88
95
|
hideLabel: {
|
|
89
96
|
type: BooleanConstructor;
|
|
90
97
|
default: boolean;
|
|
@@ -112,7 +119,7 @@ export declare const TabBarItem: import("vue").DefineComponent<import("vue").Ext
|
|
|
112
119
|
type: BooleanConstructor;
|
|
113
120
|
default: boolean;
|
|
114
121
|
};
|
|
115
|
-
/** @internal The search tab
|
|
122
|
+
/** @internal The search and the prominent tab show their symbol only. */
|
|
116
123
|
hideLabel: {
|
|
117
124
|
type: BooleanConstructor;
|
|
118
125
|
default: boolean;
|
|
@@ -139,6 +146,16 @@ declare const TabBarComponent: import("vue").DefineComponent<import("vue").Extra
|
|
|
139
146
|
type: PropType<TabBarSearch>;
|
|
140
147
|
default: undefined;
|
|
141
148
|
};
|
|
149
|
+
/**
|
|
150
|
+
* The one destination the app lifts out of the capsule, a cart or a library, in a glass circle of its own at
|
|
151
|
+
* the trailing end, as the iOS 27 prominent tab role; its symbol is the `prominent-icon` slot. It takes the
|
|
152
|
+
* circle of the search tab: with both, search is the last tab of the capsule, as iOS gives search that place
|
|
153
|
+
* only when no other tab is prominent.
|
|
154
|
+
*/
|
|
155
|
+
prominent: {
|
|
156
|
+
type: PropType<TabBarProminent>;
|
|
157
|
+
default: undefined;
|
|
158
|
+
};
|
|
142
159
|
/**
|
|
143
160
|
* `onScrollDown` minimizes the bar to the selected tab while the content of the `Page` scrolls down and
|
|
144
161
|
* expands it when the content scrolls back up; a tap on the minimized tab expands it too. @default "never"
|
|
@@ -192,6 +209,16 @@ declare const TabBarComponent: import("vue").DefineComponent<import("vue").Extra
|
|
|
192
209
|
type: PropType<TabBarSearch>;
|
|
193
210
|
default: undefined;
|
|
194
211
|
};
|
|
212
|
+
/**
|
|
213
|
+
* The one destination the app lifts out of the capsule, a cart or a library, in a glass circle of its own at
|
|
214
|
+
* the trailing end, as the iOS 27 prominent tab role; its symbol is the `prominent-icon` slot. It takes the
|
|
215
|
+
* circle of the search tab: with both, search is the last tab of the capsule, as iOS gives search that place
|
|
216
|
+
* only when no other tab is prominent.
|
|
217
|
+
*/
|
|
218
|
+
prominent: {
|
|
219
|
+
type: PropType<TabBarProminent>;
|
|
220
|
+
default: undefined;
|
|
221
|
+
};
|
|
195
222
|
/**
|
|
196
223
|
* `onScrollDown` minimizes the bar to the selected tab while the content of the `Page` scrolls down and
|
|
197
224
|
* expands it when the content scrolls back up; a tap on the minimized tab expands it too. @default "never"
|
|
@@ -230,6 +257,7 @@ declare const TabBarComponent: import("vue").DefineComponent<import("vue").Extra
|
|
|
230
257
|
defaultValue: string;
|
|
231
258
|
ariaLabel: string;
|
|
232
259
|
background: BarBackground;
|
|
260
|
+
prominent: TabBarProminent;
|
|
233
261
|
minimizeBehavior: "never" | "onScrollDown";
|
|
234
262
|
minimized: boolean;
|
|
235
263
|
defaultMinimized: boolean;
|
|
@@ -239,8 +267,8 @@ export type TabBarProps = InstanceType<typeof TabBarComponent>["$props"];
|
|
|
239
267
|
/**
|
|
240
268
|
* The tab bar of a phone screen after the iOS 26 kit Tab Bar - iPhone (507:24689): two to five tabs, each a
|
|
241
269
|
* symbol over a label, in a floating glass capsule at the bottom, the selected tab on a pill, and an optional
|
|
242
|
-
* search tab in a circle of its own. It minimizes to the selected tab while the content scrolls
|
|
243
|
-
* layout navigates with a Sidebar or Tabs, so the bar never renders from 768px up.
|
|
270
|
+
* search or prominent tab in a circle of its own. It minimizes to the selected tab while the content scrolls
|
|
271
|
+
* down. A desktop layout navigates with a Sidebar or Tabs, so the bar never renders from 768px up.
|
|
244
272
|
*/
|
|
245
273
|
export declare const TabBar: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
246
274
|
/** The controlled value of the selected tab. Bind with `v-model:value`. */
|
|
@@ -258,6 +286,16 @@ export declare const TabBar: import("vue").DefineComponent<import("vue").Extract
|
|
|
258
286
|
type: PropType<TabBarSearch>;
|
|
259
287
|
default: undefined;
|
|
260
288
|
};
|
|
289
|
+
/**
|
|
290
|
+
* The one destination the app lifts out of the capsule, a cart or a library, in a glass circle of its own at
|
|
291
|
+
* the trailing end, as the iOS 27 prominent tab role; its symbol is the `prominent-icon` slot. It takes the
|
|
292
|
+
* circle of the search tab: with both, search is the last tab of the capsule, as iOS gives search that place
|
|
293
|
+
* only when no other tab is prominent.
|
|
294
|
+
*/
|
|
295
|
+
prominent: {
|
|
296
|
+
type: PropType<TabBarProminent>;
|
|
297
|
+
default: undefined;
|
|
298
|
+
};
|
|
261
299
|
/**
|
|
262
300
|
* `onScrollDown` minimizes the bar to the selected tab while the content of the `Page` scrolls down and
|
|
263
301
|
* expands it when the content scrolls back up; a tap on the minimized tab expands it too. @default "never"
|
|
@@ -311,6 +349,16 @@ export declare const TabBar: import("vue").DefineComponent<import("vue").Extract
|
|
|
311
349
|
type: PropType<TabBarSearch>;
|
|
312
350
|
default: undefined;
|
|
313
351
|
};
|
|
352
|
+
/**
|
|
353
|
+
* The one destination the app lifts out of the capsule, a cart or a library, in a glass circle of its own at
|
|
354
|
+
* the trailing end, as the iOS 27 prominent tab role; its symbol is the `prominent-icon` slot. It takes the
|
|
355
|
+
* circle of the search tab: with both, search is the last tab of the capsule, as iOS gives search that place
|
|
356
|
+
* only when no other tab is prominent.
|
|
357
|
+
*/
|
|
358
|
+
prominent: {
|
|
359
|
+
type: PropType<TabBarProminent>;
|
|
360
|
+
default: undefined;
|
|
361
|
+
};
|
|
314
362
|
/**
|
|
315
363
|
* `onScrollDown` minimizes the bar to the selected tab while the content of the `Page` scrolls down and
|
|
316
364
|
* expands it when the content scrolls back up; a tap on the minimized tab expands it too. @default "never"
|
|
@@ -349,6 +397,7 @@ export declare const TabBar: import("vue").DefineComponent<import("vue").Extract
|
|
|
349
397
|
defaultValue: string;
|
|
350
398
|
ariaLabel: string;
|
|
351
399
|
background: BarBackground;
|
|
400
|
+
prominent: TabBarProminent;
|
|
352
401
|
minimizeBehavior: "never" | "onScrollDown";
|
|
353
402
|
minimized: boolean;
|
|
354
403
|
defaultMinimized: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { TabBar, TabBarItem, type TabBarItemProps, type TabBarProps, type TabBarSearch } from "./TabBar.js";
|
|
1
|
+
export { TabBar, TabBarItem, type TabBarItemProps, type TabBarProminent, type TabBarProps, type TabBarSearch } from "./TabBar.js";
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
import { type PropType } from "vue";
|
|
2
|
+
/** The edge of an inline tip that points at what it explains. */
|
|
3
|
+
export type TipArrowEdge = "top" | "bottom" | "left" | "right";
|
|
4
|
+
/** How a tip's actions show on a phone. */
|
|
5
|
+
export type TipMobileActions = "rows" | "buttons";
|
|
6
|
+
declare const TipComponent: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
7
|
+
/** Shows the Close button; called when it is clicked. */
|
|
8
|
+
onClose: PropType<() => void>;
|
|
9
|
+
/** Draws an arrow at this edge, pointing at what the tip explains (TipKit's annotation). */
|
|
10
|
+
arrowEdge: PropType<TipArrowEdge>;
|
|
11
|
+
/** The tip's title: what the feature is (or the `title` slot). */
|
|
12
|
+
title: StringConstructor;
|
|
13
|
+
/** One or two sentences on how to use it (or the `description` slot). */
|
|
14
|
+
description: StringConstructor;
|
|
15
|
+
/**
|
|
16
|
+
* How the actions show at 767px and below: rows of text under a separator, as iOS tips show them, or the buttons
|
|
17
|
+
* as given, each a full-width capsule under the message, as an iOS card that asks for a permission.
|
|
18
|
+
* @default "rows"
|
|
19
|
+
*/
|
|
20
|
+
mobileActions: PropType<TipMobileActions>;
|
|
21
|
+
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
22
|
+
[key: string]: any;
|
|
23
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
24
|
+
/** Shows the Close button; called when it is clicked. */
|
|
25
|
+
onClose: PropType<() => void>;
|
|
26
|
+
/** Draws an arrow at this edge, pointing at what the tip explains (TipKit's annotation). */
|
|
27
|
+
arrowEdge: PropType<TipArrowEdge>;
|
|
28
|
+
/** The tip's title: what the feature is (or the `title` slot). */
|
|
29
|
+
title: StringConstructor;
|
|
30
|
+
/** One or two sentences on how to use it (or the `description` slot). */
|
|
31
|
+
description: StringConstructor;
|
|
32
|
+
/**
|
|
33
|
+
* How the actions show at 767px and below: rows of text under a separator, as iOS tips show them, or the buttons
|
|
34
|
+
* as given, each a full-width capsule under the message, as an iOS card that asks for a permission.
|
|
35
|
+
* @default "rows"
|
|
36
|
+
*/
|
|
37
|
+
mobileActions: PropType<TipMobileActions>;
|
|
38
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
39
|
+
/**
|
|
40
|
+
* A tip anchored to a control, after TipKit's popover tip. The default slot is the control; `icon`,
|
|
41
|
+
* `title`, `description` and `actions` slots fill the tip. It does not take the focus. Bind `v-model:open`.
|
|
42
|
+
*/
|
|
43
|
+
export declare const TipPopover: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
44
|
+
/** Shows the tip (controlled, `v-model:open`). */
|
|
45
|
+
open: {
|
|
46
|
+
type: BooleanConstructor;
|
|
47
|
+
default: undefined;
|
|
48
|
+
};
|
|
49
|
+
/** Shows the tip at first (uncontrolled). @default false */
|
|
50
|
+
defaultOpen: {
|
|
51
|
+
type: BooleanConstructor;
|
|
52
|
+
default: boolean;
|
|
53
|
+
};
|
|
54
|
+
/** The side of the control the tip shows on. Turned when it does not fit. @default "bottom" */
|
|
55
|
+
side: {
|
|
56
|
+
type: PropType<"top" | "right" | "bottom" | "left">;
|
|
57
|
+
default: string;
|
|
58
|
+
};
|
|
59
|
+
/** The alignment against the control. @default "center" */
|
|
60
|
+
align: {
|
|
61
|
+
type: PropType<"start" | "center" | "end">;
|
|
62
|
+
default: string;
|
|
63
|
+
};
|
|
64
|
+
/** The distance from the control to the arrow's point, in pixels. @default 4 */
|
|
65
|
+
sideOffset: {
|
|
66
|
+
type: NumberConstructor;
|
|
67
|
+
default: number;
|
|
68
|
+
};
|
|
69
|
+
/** Shows the Close button. @default true */
|
|
70
|
+
closeButton: {
|
|
71
|
+
type: BooleanConstructor;
|
|
72
|
+
default: boolean;
|
|
73
|
+
};
|
|
74
|
+
/** The tip's title: what the feature is (or the `title` slot). */
|
|
75
|
+
title: StringConstructor;
|
|
76
|
+
/** One or two sentences on how to use it (or the `description` slot). */
|
|
77
|
+
description: StringConstructor;
|
|
78
|
+
/**
|
|
79
|
+
* How the actions show at 767px and below: rows of text under a separator, as iOS tips show them, or the buttons
|
|
80
|
+
* as given, each a full-width capsule under the message, as an iOS card that asks for a permission.
|
|
81
|
+
* @default "rows"
|
|
82
|
+
*/
|
|
83
|
+
mobileActions: PropType<TipMobileActions>;
|
|
84
|
+
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
85
|
+
[key: string]: any;
|
|
86
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
87
|
+
/** Close, Escape or a press outside closes the tip. */
|
|
88
|
+
"update:open": (open: boolean) => boolean;
|
|
89
|
+
}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
90
|
+
/** Shows the tip (controlled, `v-model:open`). */
|
|
91
|
+
open: {
|
|
92
|
+
type: BooleanConstructor;
|
|
93
|
+
default: undefined;
|
|
94
|
+
};
|
|
95
|
+
/** Shows the tip at first (uncontrolled). @default false */
|
|
96
|
+
defaultOpen: {
|
|
97
|
+
type: BooleanConstructor;
|
|
98
|
+
default: boolean;
|
|
99
|
+
};
|
|
100
|
+
/** The side of the control the tip shows on. Turned when it does not fit. @default "bottom" */
|
|
101
|
+
side: {
|
|
102
|
+
type: PropType<"top" | "right" | "bottom" | "left">;
|
|
103
|
+
default: string;
|
|
104
|
+
};
|
|
105
|
+
/** The alignment against the control. @default "center" */
|
|
106
|
+
align: {
|
|
107
|
+
type: PropType<"start" | "center" | "end">;
|
|
108
|
+
default: string;
|
|
109
|
+
};
|
|
110
|
+
/** The distance from the control to the arrow's point, in pixels. @default 4 */
|
|
111
|
+
sideOffset: {
|
|
112
|
+
type: NumberConstructor;
|
|
113
|
+
default: number;
|
|
114
|
+
};
|
|
115
|
+
/** Shows the Close button. @default true */
|
|
116
|
+
closeButton: {
|
|
117
|
+
type: BooleanConstructor;
|
|
118
|
+
default: boolean;
|
|
119
|
+
};
|
|
120
|
+
/** The tip's title: what the feature is (or the `title` slot). */
|
|
121
|
+
title: StringConstructor;
|
|
122
|
+
/** One or two sentences on how to use it (or the `description` slot). */
|
|
123
|
+
description: StringConstructor;
|
|
124
|
+
/**
|
|
125
|
+
* How the actions show at 767px and below: rows of text under a separator, as iOS tips show them, or the buttons
|
|
126
|
+
* as given, each a full-width capsule under the message, as an iOS card that asks for a permission.
|
|
127
|
+
* @default "rows"
|
|
128
|
+
*/
|
|
129
|
+
mobileActions: PropType<TipMobileActions>;
|
|
130
|
+
}>> & Readonly<{
|
|
131
|
+
"onUpdate:open"?: ((open: boolean) => any) | undefined;
|
|
132
|
+
}>, {
|
|
133
|
+
open: boolean;
|
|
134
|
+
defaultOpen: boolean;
|
|
135
|
+
side: "left" | "right" | "bottom" | "top";
|
|
136
|
+
sideOffset: number;
|
|
137
|
+
align: "center" | "end" | "start";
|
|
138
|
+
closeButton: boolean;
|
|
139
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
140
|
+
/** A tip inside the page, after TipKit: a title, a description, an optional symbol, actions and Close. */
|
|
141
|
+
export declare const Tip: typeof TipComponent & {
|
|
142
|
+
Popover: typeof TipPopover;
|
|
143
|
+
};
|
|
144
|
+
export type TipProps = InstanceType<typeof TipComponent>["$props"];
|
|
145
|
+
export type TipPopoverProps = InstanceType<typeof TipPopover>["$props"];
|
|
146
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Tip, TipPopover, type TipArrowEdge, type TipMobileActions, type TipPopoverProps, type TipProps } from "./Tip.js";
|
|
@@ -54,6 +54,14 @@ export declare class ToastLifecycle<T extends ToastData> {
|
|
|
54
54
|
private lists;
|
|
55
55
|
private suppressed;
|
|
56
56
|
private lastPointerType;
|
|
57
|
+
private region;
|
|
58
|
+
private announcers;
|
|
59
|
+
private announced;
|
|
60
|
+
/** Alerts read by the assertive announcer: shown behind the stack, their own role could not speak */
|
|
61
|
+
private assertive;
|
|
62
|
+
private announceTimers;
|
|
63
|
+
private pending;
|
|
64
|
+
private flushTimer?;
|
|
57
65
|
constructor(dismissStore: (id: ToastId) => unknown, notify: (reason: "dismiss" | "auto", toast: T) => void);
|
|
58
66
|
subscribe: (listener: () => void) => () => void;
|
|
59
67
|
snapshot: () => number;
|
|
@@ -62,6 +70,17 @@ export declare class ToastLifecycle<T extends ToastData> {
|
|
|
62
70
|
get paused(): boolean;
|
|
63
71
|
connect(doc: Document): void;
|
|
64
72
|
private visibility;
|
|
73
|
+
private isolate;
|
|
74
|
+
setRegion(node: HTMLElement | null): void;
|
|
75
|
+
setAnnouncer(kind: "polite" | "assertive", node: HTMLElement | null): void;
|
|
76
|
+
/** An error that waits to be closed interrupts as an alert; every other toast is read politely. */
|
|
77
|
+
alert(entry: ToastEntry<T>): boolean;
|
|
78
|
+
/** Whether a toast's content carries role="alert": an alert, unless it came in behind the stack and the assertive announcer read it. */
|
|
79
|
+
alertRole(entry: ToastEntry<T>, custom: boolean): boolean;
|
|
80
|
+
private visible;
|
|
81
|
+
/** Reads a toast's words once, and again only when they change (a promise that settles, a custom toast's own state). */
|
|
82
|
+
speak(id: ToastId, node: HTMLElement, custom: boolean): void;
|
|
83
|
+
private flush;
|
|
65
84
|
disconnect(): void;
|
|
66
85
|
sync(toasts: T[], config: ToastConfig): void;
|
|
67
86
|
private pause;
|
|
@@ -84,6 +103,21 @@ export declare class ToastLifecycle<T extends ToastData> {
|
|
|
84
103
|
pointerMove(id: ToastId, event: PointerEvent): void;
|
|
85
104
|
pointerEnd(id: ToastId, event: PointerEvent, cancelled?: boolean): void;
|
|
86
105
|
}
|
|
106
|
+
/** The words a toast says: its title and description, or a custom toast's text. */
|
|
107
|
+
export declare const toastText: (node: HTMLElement) => string;
|
|
108
|
+
/** Hides the polite announcer from sight, not from a screen reader. */
|
|
109
|
+
export declare const announcerStyle: {
|
|
110
|
+
readonly position: "absolute";
|
|
111
|
+
readonly width: "1px";
|
|
112
|
+
readonly height: "1px";
|
|
113
|
+
readonly margin: "-1px";
|
|
114
|
+
readonly padding: "0";
|
|
115
|
+
readonly overflow: "hidden";
|
|
116
|
+
readonly clip: "rect(0 0 0 0)";
|
|
117
|
+
readonly clipPath: "inset(50%)";
|
|
118
|
+
readonly whiteSpace: "nowrap";
|
|
119
|
+
readonly border: "0";
|
|
120
|
+
};
|
|
87
121
|
export type Offset = number | string | Partial<Record<"top" | "right" | "bottom" | "left", number | string>>;
|
|
88
122
|
export declare const offsetStyles: (offset: Offset | undefined, mobileOffset: Offset | undefined) => Record<string, string>;
|
|
89
123
|
export declare const documentDirection: (doc: Document | undefined) => "ltr" | "rtl";
|
|
@@ -5,9 +5,11 @@ export type ToolbarTitleStyle = "inline" | "large" | "compact-large" | "compact-
|
|
|
5
5
|
export type ToolbarTitleAlign = "center" | "start";
|
|
6
6
|
/**
|
|
7
7
|
* How a bar meets the content scrolled under it, after the scroll edge effect of iOS 26:
|
|
8
|
-
* - `"soft"
|
|
8
|
+
* - `"soft"` (the default of a bottom bar): at the top, the canvas color covers the content under the bar's controls and fades out past them, over a
|
|
9
|
+
* light blur; at the bottom of a page the content stays clear under and around the controls, as on native iOS 26,
|
|
10
|
+
* and a Sheet's bottom bar fades its content into the panel
|
|
9
11
|
* - `"hard"`: an opaque bar of the canvas color with a line once content is under it
|
|
10
|
-
* - `"glass"
|
|
12
|
+
* - `"glass"` (the default of a top bar): a translucent, blurred bar with a hairline, shown once content is under it
|
|
11
13
|
* - `"solid"`: an opaque bar of the canvas color without a line
|
|
12
14
|
*/
|
|
13
15
|
export type BarBackground = "soft" | "hard" | "glass" | "solid";
|
|
@@ -44,10 +46,10 @@ declare const ToolbarComponent: import("vue").DefineComponent<import("vue").Extr
|
|
|
44
46
|
type: PropType<ToolbarTitleAlign>;
|
|
45
47
|
default: string;
|
|
46
48
|
};
|
|
47
|
-
/** How the bar meets the content scrolled under it on a phone. @default "soft" */
|
|
49
|
+
/** How the bar meets the content scrolled under it on a phone. @default "glass" at the top, "soft" at the bottom */
|
|
48
50
|
background: {
|
|
49
51
|
type: PropType<ToolbarBackground>;
|
|
50
|
-
default:
|
|
52
|
+
default: undefined;
|
|
51
53
|
};
|
|
52
54
|
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
53
55
|
[key: string]: any;
|
|
@@ -67,10 +69,10 @@ declare const ToolbarComponent: import("vue").DefineComponent<import("vue").Extr
|
|
|
67
69
|
type: PropType<ToolbarTitleAlign>;
|
|
68
70
|
default: string;
|
|
69
71
|
};
|
|
70
|
-
/** How the bar meets the content scrolled under it on a phone. @default "soft" */
|
|
72
|
+
/** How the bar meets the content scrolled under it on a phone. @default "glass" at the top, "soft" at the bottom */
|
|
71
73
|
background: {
|
|
72
74
|
type: PropType<ToolbarBackground>;
|
|
73
|
-
default:
|
|
75
|
+
default: undefined;
|
|
74
76
|
};
|
|
75
77
|
}>> & Readonly<{}>, {
|
|
76
78
|
background: ToolbarBackground;
|
|
@@ -83,7 +85,7 @@ export type ToolbarProps = {
|
|
|
83
85
|
placement?: ToolbarPlacement;
|
|
84
86
|
titleStyle?: ToolbarTitleStyle;
|
|
85
87
|
titleAlign?: ToolbarTitleAlign;
|
|
86
|
-
/** How the bar meets the content scrolled under it on a phone. @default "soft" */
|
|
88
|
+
/** How the bar meets the content scrolled under it on a phone. @default "glass" at the top, "soft" at the bottom */
|
|
87
89
|
background?: ToolbarBackground;
|
|
88
90
|
} & HTMLAttributes;
|
|
89
91
|
/** A phone toolbar, top or bottom. It never renders at the desktop breakpoint. */
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type MaybeRefOrGetter } from "vue";
|
|
2
2
|
/**
|
|
3
3
|
* Escape closes the most recently registered listener first, so nested
|
|
4
|
-
* overlays close one at a time.
|
|
4
|
+
* overlays close one at a time. The callback gets the key event, already prevented.
|
|
5
5
|
*/
|
|
6
|
-
export declare const useEscCloseStack: (listening: MaybeRefOrGetter<boolean>, cb: () => void) => void;
|
|
6
|
+
export declare const useEscCloseStack: (listening: MaybeRefOrGetter<boolean>, cb: (event: KeyboardEvent) => void) => void;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import { type ComputedRef, type ShallowRef } from "vue";
|
|
2
2
|
import { type MenuFloatingBoundary, type PhoneSubmenuState } from "../lib/menuSubmenuPlacement.js";
|
|
3
|
-
|
|
3
|
+
/** `onParentPress` collapses the submenu when a press lands on the parent it stands over. */
|
|
4
|
+
export declare function usePhoneSubmenu(active: () => boolean, trigger: ShallowRef<HTMLElement | null>, content: ShallowRef<HTMLElement | null>, boundary: ComputedRef<MenuFloatingBoundary>, onParentPress?: () => void): ShallowRef<PhoneSubmenuState, PhoneSubmenuState>;
|
|
@@ -25,6 +25,12 @@ export declare const toFilterProperty: ({ blur }?: {
|
|
|
25
25
|
export declare const dataAttributes: (props: Record<string, unknown>) => {
|
|
26
26
|
[k: string]: unknown;
|
|
27
27
|
};
|
|
28
|
+
/**
|
|
29
|
+
* A copy of a key event that a handler can cancel. An event that reaches the Escape stack is already prevented, so
|
|
30
|
+
* its own `defaultPrevented` cannot tell whether an owner's handler asked to keep the overlay open. The copy keeps
|
|
31
|
+
* the key, the modifiers and the target.
|
|
32
|
+
*/
|
|
33
|
+
export declare const cancelableKeyCopy: (event: KeyboardEvent) => KeyboardEvent;
|
|
28
34
|
export declare const preventDefaultHandler: (evt: Event) => void;
|
|
29
35
|
/**
|
|
30
36
|
* For an overlay's close auto focus: focus that moved on to something else
|
|
@@ -50,8 +50,15 @@ export declare function readMenuBoundaryRect(document: Document, boundary: MenuF
|
|
|
50
50
|
export declare function readMenuTriggerLabel(trigger: HTMLElement): string;
|
|
51
51
|
export declare function focusPhoneSubmenuEntry(content: HTMLElement): void;
|
|
52
52
|
export declare function samePhoneSubmenuState(a: PhoneSubmenuState, b: PhoneSubmenuState): boolean;
|
|
53
|
-
/**
|
|
54
|
-
|
|
53
|
+
/**
|
|
54
|
+
* Own only these Phone attributes/variables. Primitive focus and dismissal stay intact.
|
|
55
|
+
*
|
|
56
|
+
* While a phone submenu stands over its parent the parent is behind it, as in iOS 26 (owner, plan 176): a press on it
|
|
57
|
+
* collapses the submenu (`onParentPress`) and chooses none of its rows, which take no presses (Menu.module.css), and
|
|
58
|
+
* it is hidden from a screen reader. Focus left in it by the press that opened the submenu moves into the submenu, as
|
|
59
|
+
* VoiceOver's moves into an iOS submenu, and a focus that returns to it (the submenu collapsing) shows it again.
|
|
60
|
+
*/
|
|
61
|
+
export declare function observePhoneSubmenu(trigger: HTMLElement, content: HTMLElement, boundary: MenuFloatingBoundary, update: (state: PhoneSubmenuState) => void, onParentPress?: () => void): {
|
|
55
62
|
refresh: () => void;
|
|
56
63
|
dispose: () => void;
|
|
57
64
|
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The phone layout outside a narrow window (plan 176). The style sheets apply their phone rules (767px and below)
|
|
3
|
+
* inside an element marked `data-plex-layout="phone"` too, at any window width: PhoneLayout marks one, and so does a
|
|
4
|
+
* Dialog with `layout="phone"`. Scripts that change what they do on a phone ask the same question here.
|
|
5
|
+
*/
|
|
6
|
+
export declare const PHONE_LAYOUT_SCOPE = "[data-plex-layout=\"phone\"]";
|
|
7
|
+
export declare const PHONE_MEDIA = "(max-width: 767px)";
|
|
8
|
+
/** The window is 767px wide or narrower. */
|
|
9
|
+
export declare const isPhoneWindow: (view: Window | null | undefined) => boolean;
|
|
10
|
+
/** The element is laid out as on a phone: inside a phone layout, or in a window 767px wide or narrower. */
|
|
11
|
+
export declare const isPhoneLayout: (element: Element) => boolean;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The toast region is a layer of its own above any overlay: a press, focus or Escape inside a toast belongs to the
|
|
3
|
+
* toast, never to a Dialog, Popover or Menu under it. Every toast list carries `data-sonner-toaster`.
|
|
4
|
+
*/
|
|
5
|
+
export declare const inToastRegion: (target: EventTarget | null | undefined) => boolean;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@plexui/vue",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.12.0",
|
|
4
4
|
"description": "Plex UI components for Vue 3, built on Reka UI and the shared @plexui/styles CSS",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -77,7 +77,7 @@
|
|
|
77
77
|
"@maskito/core": "5.2.2",
|
|
78
78
|
"@maskito/kit": "5.2.2",
|
|
79
79
|
"@maskito/vue": "5.2.2",
|
|
80
|
-
"@plexui/styles": "^0.1.
|
|
80
|
+
"@plexui/styles": "^0.1.36",
|
|
81
81
|
"@tanstack/table-core": "8.21.3",
|
|
82
82
|
"@tanstack/vue-table": "8.21.3",
|
|
83
83
|
"@tiptap/core": "3.21.0",
|