@plexui/vue 0.29.1 → 0.31.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.
@@ -8,11 +8,19 @@ import { type BarBackground, type BarBackgroundAlias } from "../Toolbar/Toolbar.
8
8
  export type DialogConfirmClose = {
9
9
  /** The question, such as "Are you sure you want to discard this new note?"; text or vnodes, as React takes a node */
10
10
  message: VNodeChild;
11
+ /** A quieter line under the question, such as what a save left behind */
12
+ detail?: VNodeChild;
11
13
  /** The answer that closes and loses the changes. @default "Discard Changes" */
12
14
  confirmLabel?: VNodeChild;
13
15
  /** The alert's answer that keeps the dialog open. @default "Keep Editing" */
14
16
  cancelLabel?: VNodeChild;
15
17
  };
18
+ /**
19
+ * `confirmClose` as a value, or as a function the dialog calls at each close attempt (Close, DialogClose, Escape, a
20
+ * press outside, a sheet pulled down) before it decides: it returns the question, or nothing to close at once. An
21
+ * owner that commits typed words only on blur commits them there, then compares.
22
+ */
23
+ export type DialogConfirmCloseProp = DialogConfirmClose | (() => DialogConfirmClose | false | null | undefined) | false | null;
16
24
  /** Modal dialog root. Uncontrolled by default; bind `v-model:open` to control it. */
17
25
  export declare const Dialog: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
18
26
  open: {
@@ -101,7 +109,7 @@ export declare const DialogContent: import("vue").DefineComponent<import("vue").
101
109
  * there are none. Setting `open` to false yourself, such as after Save, closes at once.
102
110
  */
103
111
  confirmClose: {
104
- type: PropType<DialogConfirmClose | false | null>;
112
+ type: PropType<DialogConfirmCloseProp>;
105
113
  default: undefined;
106
114
  };
107
115
  /** Stack order of the overlay and the dialog. @default 50 */
@@ -182,7 +190,7 @@ export declare const DialogContent: import("vue").DefineComponent<import("vue").
182
190
  * there are none. Setting `open` to false yourself, such as after Save, closes at once.
183
191
  */
184
192
  confirmClose: {
185
- type: PropType<DialogConfirmClose | false | null>;
193
+ type: PropType<DialogConfirmCloseProp>;
186
194
  default: undefined;
187
195
  };
188
196
  /** Stack order of the overlay and the dialog. @default 50 */
@@ -201,9 +209,9 @@ export declare const DialogContent: import("vue").DefineComponent<import("vue").
201
209
  layout: "auto" | "phone";
202
210
  pill: boolean;
203
211
  placement: DialogPlacement;
204
- showClose: boolean;
205
212
  surface: "plain" | "grouped";
206
- confirmClose: false | DialogConfirmClose | null;
213
+ showClose: boolean;
214
+ confirmClose: DialogConfirmCloseProp;
207
215
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
208
216
  /** How a Sheet's bar meets the content scrolled under it; see `BarBackground`. `"solid"` is the earlier name of `"hard"`. */
209
217
  export type DialogBarBackground = BarBackground | BarBackgroundAlias;
@@ -1 +1 @@
1
- export { Dialog, DialogBody, DialogClose, DialogContent, DialogDescription, DialogDescriptionSlot, DialogFooter, DialogHeader, DialogHeaderAction, DialogSteps, DialogTitle, DialogTrigger, type DialogBarBackground, type DialogConfirmClose, type DialogHeaderProps, type DialogFooterProps, type DialogHeaderActionProps, type DialogContentProps, type DialogInteractOutsideEvent, type DialogLayerProps, type DialogPlacement, type DialogProps, type DialogStepsProps, } from "./Dialog.js";
1
+ export { Dialog, DialogBody, DialogClose, DialogContent, DialogDescription, DialogDescriptionSlot, DialogFooter, DialogHeader, DialogHeaderAction, DialogSteps, DialogTitle, DialogTrigger, type DialogBarBackground, type DialogConfirmClose, type DialogConfirmCloseProp, type DialogHeaderProps, type DialogFooterProps, type DialogHeaderActionProps, type DialogContentProps, type DialogInteractOutsideEvent, type DialogLayerProps, type DialogPlacement, type DialogProps, type DialogStepsProps, } from "./Dialog.js";
@@ -174,12 +174,12 @@ declare const FloatingLabelInputComponent: import("vue").DefineComponent<import(
174
174
  defaultValue: string | number;
175
175
  disabled: boolean;
176
176
  pill: boolean;
177
+ rows: number;
177
178
  readOnly: boolean;
178
179
  readonly: boolean;
179
180
  allowAutofillExtensions: boolean;
180
181
  revealable: boolean;
181
182
  multiline: boolean;
182
- rows: number;
183
183
  labelPlacement: "inside" | "border";
184
184
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
185
185
  type FloatingLabelInputOwnProps = InstanceType<typeof FloatingLabelInputComponent>["$props"];
@@ -149,8 +149,8 @@ declare const MarkdownEditorComponent: import("vue").DefineComponent<import("vue
149
149
  defaultValue: string;
150
150
  disabled: boolean;
151
151
  variant: "soft" | "outline";
152
- ariaInvalid: boolean;
153
152
  rows: number;
153
+ ariaInvalid: boolean;
154
154
  breaks: boolean;
155
155
  formats: MarkdownEditorFormat[];
156
156
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
@@ -302,8 +302,8 @@ export declare const MarkdownEditor: import("vue").DefineComponent<import("vue")
302
302
  defaultValue: string;
303
303
  disabled: boolean;
304
304
  variant: "soft" | "outline";
305
- ariaInvalid: boolean;
306
305
  rows: number;
306
+ ariaInvalid: boolean;
307
307
  breaks: boolean;
308
308
  formats: MarkdownEditorFormat[];
309
309
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
@@ -3,6 +3,13 @@ import { type BarBackground, type BarBackgroundAlias } from "../Toolbar/Toolbar.
3
3
  /** How a phone bar of the page meets the content scrolled under it; see `BarBackground`. `"solid"` is the earlier name of `"hard"`. */
4
4
  export type PageBarBackground = BarBackground | BarBackgroundAlias;
5
5
  export type PageWidth = "full" | "wide" | "column";
6
+ /**
7
+ * Follows the rows of a large title's bar (Toolbar.Row) in the content. They stand under the title and, scrolled up to
8
+ * the bar, stay under its controls (`position: sticky`): they are pinned once the sticky offset moves them off the
9
+ * title's bottom, where they would stand. It reports that and their height, which the bar's background takes in. React's
10
+ * twin.
11
+ */
12
+ export declare function followTitleRows(content: HTMLElement, rows: HTMLElement, report: (pinned: boolean, height: number) => void): () => void;
6
13
  declare const PageComponent: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
7
14
  /**
8
15
  * Width of the column that header and content share: `"full"` (edge to
@@ -158,11 +158,11 @@ declare const TextareaComponent: import("vue").DefineComponent<import("vue").Ext
158
158
  disabled: boolean;
159
159
  size: "3xs" | "2xs" | "xs" | "sm" | "md" | "lg" | "xl" | "2xl" | "3xl";
160
160
  variant: "soft" | "outline" | "ghost";
161
+ rows: number;
161
162
  readOnly: boolean;
162
163
  readonly: boolean;
163
164
  allowAutofillExtensions: boolean;
164
165
  autoSelect: boolean;
165
- rows: number;
166
166
  autoResize: boolean;
167
167
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
168
168
  type TextareaOwnProps = InstanceType<typeof TextareaComponent>["$props"];
@@ -46,6 +46,11 @@ export type ToolbarHost = {
46
46
  largeTitleRowSlot?: Ref<HTMLElement | null>;
47
47
  /** The rows under a large title are pinned under the bar, so its background reaches under them. */
48
48
  rowsPinned?: Ref<boolean>;
49
+ /**
50
+ * `false` while the host has no content to keep a large title in (a Dialog without DialogBody): the title and its
51
+ * rows stay in the bar. Otherwise the rows wait for their place, so they mount once, there.
52
+ */
53
+ holdsLargeTitle?: Ref<boolean>;
49
54
  };
50
55
  export declare const TOOLBAR_HOST: InjectionKey<ToolbarHost>;
51
56
  declare const ToolbarComponent: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@plexui/vue",
3
- "version": "0.29.1",
3
+ "version": "0.31.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.8.1",
80
+ "@plexui/styles": "^0.10.0",
81
81
  "@tanstack/table-core": "8.21.3",
82
82
  "@tanstack/vue-table": "8.21.3",
83
83
  "@tiptap/core": "3.21.0",