ngwr 16.5.0 → 16.6.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/back-top/styles/_index.scss +6 -0
- package/breadcrumbs/styles/_rules.scss +34 -0
- package/cascader/styles/_rules.scss +7 -0
- package/charts/chart-legend/styles/_index.scss +1 -9
- package/counter/styles/_index.scss +1 -8
- package/date-picker/styles/_index.scss +15 -9
- package/dialog/styles/_index.scss +37 -0
- package/editor/styles/_index.scss +1 -8
- package/event-calendar/styles/_index.scss +2 -6
- package/fesm2022/ngwr-affix.mjs +1 -1
- package/fesm2022/ngwr-affix.mjs.map +1 -1
- package/fesm2022/ngwr-anchor.mjs +9 -2
- package/fesm2022/ngwr-anchor.mjs.map +1 -1
- package/fesm2022/ngwr-animations-aurora.mjs.map +1 -1
- package/fesm2022/ngwr-animations-blur-reveal.mjs.map +1 -1
- package/fesm2022/ngwr-animations-click-sparks.mjs.map +1 -1
- package/fesm2022/ngwr-animations-confetti.mjs.map +1 -1
- package/fesm2022/ngwr-animations-decode.mjs.map +1 -1
- package/fesm2022/ngwr-animations-destruct.mjs.map +1 -1
- package/fesm2022/ngwr-animations-dot-grid.mjs.map +1 -1
- package/fesm2022/ngwr-animations-falling-letters.mjs.map +1 -1
- package/fesm2022/ngwr-animations-flow-lines.mjs.map +1 -1
- package/fesm2022/ngwr-animations-fluid-cursor.mjs.map +1 -1
- package/fesm2022/ngwr-animations-glitch.mjs.map +1 -1
- package/fesm2022/ngwr-animations-glow-border.mjs.map +1 -1
- package/fesm2022/ngwr-animations-gradient-flow.mjs.map +1 -1
- package/fesm2022/ngwr-animations-marquee.mjs.map +1 -1
- package/fesm2022/ngwr-animations-orbit.mjs.map +1 -1
- package/fesm2022/ngwr-animations-reveal.mjs.map +1 -1
- package/fesm2022/ngwr-animations-ripple-grid.mjs.map +1 -1
- package/fesm2022/ngwr-animations-rotate-reveal.mjs.map +1 -1
- package/fesm2022/ngwr-animations-shimmer.mjs.map +1 -1
- package/fesm2022/ngwr-animations-spotlight.mjs.map +1 -1
- package/fesm2022/ngwr-animations-thread-lines.mjs.map +1 -1
- package/fesm2022/ngwr-animations-tilt.mjs +20 -13
- package/fesm2022/ngwr-animations-tilt.mjs.map +1 -1
- package/fesm2022/ngwr-animations-typewriter.mjs.map +1 -1
- package/fesm2022/ngwr-breadcrumbs.mjs +40 -7
- package/fesm2022/ngwr-breadcrumbs.mjs.map +1 -1
- package/fesm2022/ngwr-button.mjs +12 -3
- package/fesm2022/ngwr-button.mjs.map +1 -1
- package/fesm2022/ngwr-carousel.mjs +8 -2
- package/fesm2022/ngwr-carousel.mjs.map +1 -1
- package/fesm2022/ngwr-cascader.mjs +24 -4
- package/fesm2022/ngwr-cascader.mjs.map +1 -1
- package/fesm2022/ngwr-charts-core.mjs +12 -5
- package/fesm2022/ngwr-charts-core.mjs.map +1 -1
- package/fesm2022/ngwr-charts-meter-group.mjs +4 -2
- package/fesm2022/ngwr-charts-meter-group.mjs.map +1 -1
- package/fesm2022/ngwr-checkbox.mjs +3 -2
- package/fesm2022/ngwr-checkbox.mjs.map +1 -1
- package/fesm2022/ngwr-color-picker.mjs +21 -1
- package/fesm2022/ngwr-color-picker.mjs.map +1 -1
- package/fesm2022/ngwr-context-menu.mjs +4 -5
- package/fesm2022/ngwr-context-menu.mjs.map +1 -1
- package/fesm2022/ngwr-date-picker-testing.mjs.map +1 -1
- package/fesm2022/ngwr-date-picker.mjs +49 -1
- package/fesm2022/ngwr-date-picker.mjs.map +1 -1
- package/fesm2022/ngwr-dialog.mjs +16 -6
- package/fesm2022/ngwr-dialog.mjs.map +1 -1
- package/fesm2022/ngwr-directives.mjs +9 -6
- package/fesm2022/ngwr-directives.mjs.map +1 -1
- package/fesm2022/ngwr-event-calendar.mjs +20 -9
- package/fesm2022/ngwr-event-calendar.mjs.map +1 -1
- package/fesm2022/ngwr-form.mjs +170 -3
- package/fesm2022/ngwr-form.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-ar.mjs +15 -0
- package/fesm2022/ngwr-i18n-ar.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-cs.mjs +15 -0
- package/fesm2022/ngwr-i18n-cs.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-de.mjs +15 -0
- package/fesm2022/ngwr-i18n-de.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-en.mjs +15 -0
- package/fesm2022/ngwr-i18n-en.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-es.mjs +15 -0
- package/fesm2022/ngwr-i18n-es.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-fr.mjs +15 -0
- package/fesm2022/ngwr-i18n-fr.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-he.mjs +15 -0
- package/fesm2022/ngwr-i18n-he.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-hi.mjs +15 -0
- package/fesm2022/ngwr-i18n-hi.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-id.mjs +15 -0
- package/fesm2022/ngwr-i18n-id.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-it.mjs +15 -0
- package/fesm2022/ngwr-i18n-it.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-ja.mjs +15 -0
- package/fesm2022/ngwr-i18n-ja.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-ko.mjs +15 -0
- package/fesm2022/ngwr-i18n-ko.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-nl.mjs +15 -0
- package/fesm2022/ngwr-i18n-nl.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-pl.mjs +15 -0
- package/fesm2022/ngwr-i18n-pl.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-pt.mjs +15 -0
- package/fesm2022/ngwr-i18n-pt.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-ru.mjs +15 -0
- package/fesm2022/ngwr-i18n-ru.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-sv.mjs +15 -0
- package/fesm2022/ngwr-i18n-sv.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-tr.mjs +15 -0
- package/fesm2022/ngwr-i18n-tr.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-uk.mjs +15 -0
- package/fesm2022/ngwr-i18n-uk.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-vi.mjs +15 -0
- package/fesm2022/ngwr-i18n-vi.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-zh-tw.mjs +15 -0
- package/fesm2022/ngwr-i18n-zh-tw.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-zh.mjs +15 -0
- package/fesm2022/ngwr-i18n-zh.mjs.map +1 -1
- package/fesm2022/ngwr-i18n.mjs +82 -11
- package/fesm2022/ngwr-i18n.mjs.map +1 -1
- package/fesm2022/ngwr-input-number.mjs +24 -1
- package/fesm2022/ngwr-input-number.mjs.map +1 -1
- package/fesm2022/ngwr-input-otp.mjs +2 -2
- package/fesm2022/ngwr-input-otp.mjs.map +1 -1
- package/fesm2022/ngwr-input.mjs +10 -2
- package/fesm2022/ngwr-input.mjs.map +1 -1
- package/fesm2022/ngwr-layout.mjs.map +1 -1
- package/fesm2022/ngwr-list.mjs +1 -1
- package/fesm2022/ngwr-list.mjs.map +1 -1
- package/fesm2022/ngwr-loading-bar-router.mjs.map +1 -1
- package/fesm2022/ngwr-loading-bar.mjs +2 -2
- package/fesm2022/ngwr-loading-bar.mjs.map +1 -1
- package/fesm2022/ngwr-mention.mjs +8 -0
- package/fesm2022/ngwr-mention.mjs.map +1 -1
- package/fesm2022/ngwr-meta.mjs +9 -6
- package/fesm2022/ngwr-meta.mjs.map +1 -1
- package/fesm2022/ngwr-page-header.mjs +21 -0
- package/fesm2022/ngwr-page-header.mjs.map +1 -1
- package/fesm2022/ngwr-pagination.mjs +2 -0
- package/fesm2022/ngwr-pagination.mjs.map +1 -1
- package/fesm2022/ngwr-pipes.mjs +8 -1
- package/fesm2022/ngwr-pipes.mjs.map +1 -1
- package/fesm2022/ngwr-popconfirm.mjs +2 -1
- package/fesm2022/ngwr-popconfirm.mjs.map +1 -1
- package/fesm2022/ngwr-popover.mjs +47 -3
- package/fesm2022/ngwr-popover.mjs.map +1 -1
- package/fesm2022/ngwr-qr.mjs +6 -2
- package/fesm2022/ngwr-qr.mjs.map +1 -1
- package/fesm2022/ngwr-radio.mjs +71 -5
- package/fesm2022/ngwr-radio.mjs.map +1 -1
- package/fesm2022/ngwr-schema-form.mjs +10 -1
- package/fesm2022/ngwr-schema-form.mjs.map +1 -1
- package/fesm2022/ngwr-scroll.mjs +1 -3
- package/fesm2022/ngwr-scroll.mjs.map +1 -1
- package/fesm2022/ngwr-segmented.mjs +20 -0
- package/fesm2022/ngwr-segmented.mjs.map +1 -1
- package/fesm2022/ngwr-select.mjs +80 -9
- package/fesm2022/ngwr-select.mjs.map +1 -1
- package/fesm2022/ngwr-sortable-list.mjs +16 -4
- package/fesm2022/ngwr-sortable-list.mjs.map +1 -1
- package/fesm2022/ngwr-storage.mjs +1 -1
- package/fesm2022/ngwr-storage.mjs.map +1 -1
- package/fesm2022/ngwr-switch.mjs +2 -2
- package/fesm2022/ngwr-switch.mjs.map +1 -1
- package/fesm2022/ngwr-table.mjs +41 -7
- package/fesm2022/ngwr-table.mjs.map +1 -1
- package/fesm2022/ngwr-tabs-router.mjs.map +1 -1
- package/fesm2022/ngwr-textarea.mjs +2 -2
- package/fesm2022/ngwr-textarea.mjs.map +1 -1
- package/fesm2022/ngwr-toast.mjs +28 -0
- package/fesm2022/ngwr-toast.mjs.map +1 -1
- package/fesm2022/ngwr-tour.mjs +2 -2
- package/fesm2022/ngwr-tour.mjs.map +1 -1
- package/fesm2022/ngwr-typography.mjs +20 -0
- package/fesm2022/ngwr-typography.mjs.map +1 -1
- package/fesm2022/ngwr-utils-router.mjs.map +1 -1
- package/fesm2022/ngwr-utils.mjs +46 -4
- package/fesm2022/ngwr-utils.mjs.map +1 -1
- package/fesm2022/ngwr-validators.mjs +33 -1
- package/fesm2022/ngwr-validators.mjs.map +1 -1
- package/fesm2022/ngwr-version.mjs +1 -1
- package/fesm2022/ngwr-version.mjs.map +1 -1
- package/form/styles/_index.scss +37 -0
- package/graph/styles/_index.scss +1 -9
- package/i18n/ar.json +15 -0
- package/i18n/cs.json +15 -0
- package/i18n/de.json +15 -0
- package/i18n/en.json +15 -0
- package/i18n/es.json +15 -0
- package/i18n/fr.json +15 -0
- package/i18n/he.json +15 -0
- package/i18n/hi.json +15 -0
- package/i18n/id.json +15 -0
- package/i18n/it.json +15 -0
- package/i18n/ja.json +15 -0
- package/i18n/ko.json +15 -0
- package/i18n/nl.json +15 -0
- package/i18n/pl.json +15 -0
- package/i18n/pt.json +15 -0
- package/i18n/ru.json +15 -0
- package/i18n/sv.json +15 -0
- package/i18n/tr.json +15 -0
- package/i18n/uk.json +15 -0
- package/i18n/vi.json +15 -0
- package/i18n/zh-TW.json +15 -0
- package/i18n/zh.json +15 -0
- package/image-cropper/styles/_index.scss +1 -9
- package/input-number/styles/_index.scss +7 -0
- package/layout/styles/_index.scss +13 -1
- package/llms-full.txt +10 -10
- package/loading-bar/styles/_rules.scss +6 -0
- package/package.json +2 -2
- package/page-header/styles/_index.scss +18 -0
- package/popover/styles/_index.scss +7 -0
- package/schematics/use/symbol-map.json +2 -0
- package/segmented/styles/_index.scss +7 -0
- package/select/styles/_index.scss +7 -0
- package/sidebar/styles/_index.scss +6 -0
- package/skills/ngwr/references/catalog.md +1 -1
- package/sortable-list/styles/_rules.scss +1 -9
- package/speed-dial/styles/_index.scss +6 -0
- package/stepper/styles/_index.scss +1 -9
- package/table/styles/_index.scss +49 -0
- package/theme/_index.scss +12 -1
- package/theme/styles/_colors.scss +11 -0
- package/theme/styles/_contrast.scss +6 -0
- package/theme/styles/_index.scss +1 -0
- package/theme/styles/_mixins.scss +45 -0
- package/theme/styles/_print.scss +17 -0
- package/toast/styles/_index.scss +7 -0
- package/tour/styles/_index.scss +8 -0
- package/tree/styles/_index.scss +1 -9
- package/types/ngwr-anchor.d.ts +3 -0
- package/types/ngwr-animations-aurora.d.ts +6 -0
- package/types/ngwr-animations-blur-reveal.d.ts +6 -0
- package/types/ngwr-animations-click-sparks.d.ts +6 -0
- package/types/ngwr-animations-confetti.d.ts +6 -0
- package/types/ngwr-animations-decode.d.ts +6 -0
- package/types/ngwr-animations-destruct.d.ts +6 -0
- package/types/ngwr-animations-dot-grid.d.ts +6 -0
- package/types/ngwr-animations-falling-letters.d.ts +6 -0
- package/types/ngwr-animations-flow-lines.d.ts +6 -0
- package/types/ngwr-animations-fluid-cursor.d.ts +6 -0
- package/types/ngwr-animations-glitch.d.ts +6 -0
- package/types/ngwr-animations-glow-border.d.ts +6 -0
- package/types/ngwr-animations-gradient-flow.d.ts +6 -0
- package/types/ngwr-animations-marquee.d.ts +6 -0
- package/types/ngwr-animations-orbit.d.ts +6 -0
- package/types/ngwr-animations-reveal.d.ts +6 -0
- package/types/ngwr-animations-ripple-grid.d.ts +6 -0
- package/types/ngwr-animations-rotate-reveal.d.ts +6 -0
- package/types/ngwr-animations-shimmer.d.ts +6 -0
- package/types/ngwr-animations-spotlight.d.ts +6 -0
- package/types/ngwr-animations-thread-lines.d.ts +6 -0
- package/types/ngwr-animations-tilt.d.ts +10 -0
- package/types/ngwr-animations-typewriter.d.ts +6 -0
- package/types/ngwr-breadcrumbs.d.ts +25 -0
- package/types/ngwr-button.d.ts +23 -3
- package/types/ngwr-carousel.d.ts +2 -0
- package/types/ngwr-cascader.d.ts +7 -0
- package/types/ngwr-charts-core.d.ts +16 -0
- package/types/ngwr-charts-meter-group.d.ts +2 -0
- package/types/ngwr-checkbox.d.ts +1 -0
- package/types/ngwr-color-picker.d.ts +1 -0
- package/types/ngwr-context-menu.d.ts +1 -1
- package/types/ngwr-date-picker.d.ts +19 -0
- package/types/ngwr-dialog.d.ts +39 -8
- package/types/ngwr-directives.d.ts +12 -4
- package/types/ngwr-drawer.d.ts +1 -1
- package/types/ngwr-dropdown.d.ts +1 -1
- package/types/ngwr-event-calendar.d.ts +4 -0
- package/types/ngwr-form.d.ts +85 -1
- package/types/ngwr-i18n.d.ts +65 -5
- package/types/ngwr-input-number.d.ts +8 -0
- package/types/ngwr-input.d.ts +7 -0
- package/types/ngwr-layout.d.ts +1 -1
- package/types/ngwr-loading-bar-router.d.ts +6 -0
- package/types/ngwr-page-header.d.ts +23 -1
- package/types/ngwr-popconfirm.d.ts +1 -1
- package/types/ngwr-popover.d.ts +28 -4
- package/types/ngwr-radio.d.ts +47 -5
- package/types/ngwr-segmented.d.ts +7 -0
- package/types/ngwr-select.d.ts +57 -13
- package/types/ngwr-sortable-list.d.ts +20 -7
- package/types/ngwr-table.d.ts +58 -5
- package/types/ngwr-tabs-router.d.ts +6 -0
- package/types/ngwr-toast.d.ts +11 -0
- package/types/ngwr-tour.d.ts +0 -1
- package/types/ngwr-typography.d.ts +7 -0
- package/types/ngwr-utils-router.d.ts +6 -0
- package/types/ngwr-utils.d.ts +56 -2
- package/types/ngwr-validators.d.ts +49 -1
- package/types/ngwr-version.d.ts +1 -1
- package/typography/styles/_index.scss +4 -0
- package/window/styles/_index.scss +1 -9
package/types/ngwr-dialog.d.ts
CHANGED
|
@@ -101,6 +101,8 @@ type WrDialogRole = 'dialog' | 'alertdialog';
|
|
|
101
101
|
* `cdkFocusInitial` wins in every mode.
|
|
102
102
|
*/
|
|
103
103
|
type WrDialogAutoFocus = 'first-tabbable' | 'dialog' | false;
|
|
104
|
+
/** A dialog size: a width step, read from `--wr-dialog-width-<size>`, and the scale of the dialog's parts. */
|
|
105
|
+
type WrDialogSize = 'sm' | 'md' | 'lg';
|
|
104
106
|
/**
|
|
105
107
|
* Options accepted by `WrDialog.open()`.
|
|
106
108
|
*/
|
|
@@ -136,10 +138,34 @@ interface WrDialogOptions<D = unknown> {
|
|
|
136
138
|
readonly closable?: boolean;
|
|
137
139
|
/** Accessible name for the dismiss button. Falls back to the `dialog.close` catalog key. */
|
|
138
140
|
readonly closeLabel?: string;
|
|
139
|
-
/**
|
|
141
|
+
/**
|
|
142
|
+
* `sm`, `md` or `lg`. A width step, 28rem, 40rem and 56rem unless the
|
|
143
|
+
* `--wr-dialog-width-<size>` hooks say otherwise, and the scale of the
|
|
144
|
+
* dialog: its padding, title, text, dismiss button and footer gap, through
|
|
145
|
+
* the `--wr-dialog-*` hooks. `md` scales nothing. A `wr-btn` inside with no
|
|
146
|
+
* `size` of its own takes this one, the buttons of `confirm()` and `alert()`
|
|
147
|
+
* included. The panel gets the `wr-dialog-panel--<size>` class and still
|
|
148
|
+
* narrows to the viewport gutter. An explicit `width` wins over the width
|
|
149
|
+
* step only. With neither, the panel is as wide as its content.
|
|
150
|
+
* @default undefined, or what `withDialog()` sets for `open()`
|
|
151
|
+
*/
|
|
152
|
+
readonly size?: WrDialogSize;
|
|
153
|
+
/** Width applied to the panel — any valid CSS length. Wins over the width of a `size`. */
|
|
140
154
|
readonly width?: string;
|
|
155
|
+
/**
|
|
156
|
+
* Minimum width applied to the panel, in place of `--wr-dialog-min-width`.
|
|
157
|
+
* A minimum wins over the viewport gutter, so a long one overflows a phone.
|
|
158
|
+
*/
|
|
159
|
+
readonly minWidth?: string;
|
|
141
160
|
/** Maximum width applied to the panel. */
|
|
142
161
|
readonly maxWidth?: string;
|
|
162
|
+
/**
|
|
163
|
+
* Height applied to the panel — any valid CSS length. The viewport gutter
|
|
164
|
+
* still caps it, and `[wrDialogContent]` takes the room left and scrolls.
|
|
165
|
+
*/
|
|
166
|
+
readonly height?: string;
|
|
167
|
+
/** Maximum height applied to the panel, in place of the viewport gutter. */
|
|
168
|
+
readonly maxHeight?: string;
|
|
143
169
|
/**
|
|
144
170
|
* Extra CSS classes for the panel. A space-separated string works as well as
|
|
145
171
|
* an array — the CDK would throw `InvalidCharacterError` on the first, so the
|
|
@@ -179,7 +205,7 @@ interface WrDialogOptions<D = unknown> {
|
|
|
179
205
|
readonly autoFocus?: WrDialogAutoFocus;
|
|
180
206
|
}
|
|
181
207
|
/** The `WrDialogOptions` that `confirm()` and `alert()` pass through to the dialog. */
|
|
182
|
-
type WrDialogMessageOptions = Pick<WrDialogOptions, 'width' | 'maxWidth' | 'panelClass' | 'closeOnBackdropClick' | 'closeOnEscape' | 'closeOnNavigation' | 'tabTitle' | 'autoFocus' | 'toasts'>;
|
|
208
|
+
type WrDialogMessageOptions = Pick<WrDialogOptions, 'size' | 'width' | 'maxWidth' | 'panelClass' | 'closeOnBackdropClick' | 'closeOnEscape' | 'closeOnNavigation' | 'tabTitle' | 'autoFocus' | 'toasts'>;
|
|
183
209
|
/** The meaning a `confirm()` or an `alert()` dialog shows as an icon before its title. */
|
|
184
210
|
type WrDialogIntent = 'info' | 'success' | 'warning' | 'danger';
|
|
185
211
|
/**
|
|
@@ -234,8 +260,11 @@ interface WrDialogAlertOptions extends WrDialogMessageOptions {
|
|
|
234
260
|
/** An icon before the title, in the intent's color. It is decorative. */
|
|
235
261
|
readonly intent?: WrDialogIntent;
|
|
236
262
|
}
|
|
237
|
-
/**
|
|
238
|
-
|
|
263
|
+
/**
|
|
264
|
+
* App-wide dialog defaults, passed to `provideWr(withDialog(...))`. `size`
|
|
265
|
+
* applies to `open()` only: `confirm()` and `alert()` take their own.
|
|
266
|
+
*/
|
|
267
|
+
type WrDialogDefaults = Pick<WrDialogOptions, 'tabTitle' | 'autoFocus' | 'size'>;
|
|
239
268
|
/**
|
|
240
269
|
* Opens dialog components in an isolated NGWR overlay.
|
|
241
270
|
*
|
|
@@ -270,6 +299,7 @@ export declare class WrDialog {
|
|
|
270
299
|
private readonly defaults;
|
|
271
300
|
private readonly order;
|
|
272
301
|
open<C, R = unknown, D = unknown>(component: ComponentType<C>, options?: WrDialogOptions<D>): WrDialogRef<C, R>;
|
|
302
|
+
private mount;
|
|
273
303
|
/**
|
|
274
304
|
* Ask a yes-or-no question and get the answer: `true` only when the user
|
|
275
305
|
* pressed the confirm button. Escape, the backdrop, the cancel button, a
|
|
@@ -418,8 +448,9 @@ export declare const WR_DIALOG_DATA: InjectionToken<unknown>;
|
|
|
418
448
|
export declare const WR_DIALOG_REF: InjectionToken<WrDialogRef<unknown, unknown>>;
|
|
419
449
|
/**
|
|
420
450
|
* App-wide dialog defaults, as a feature of `provideWr()`: `tabTitle`, so
|
|
421
|
-
* every dialog names the browser tab while it is open,
|
|
422
|
-
* focus goes on open
|
|
451
|
+
* every dialog names the browser tab while it is open, `autoFocus`, where
|
|
452
|
+
* focus goes on open, and `size`, the size of every `open()`. The same
|
|
453
|
+
* option on `open()` or `confirm()` still wins.
|
|
423
454
|
*
|
|
424
455
|
* Bootstrap only: `WrDialog` is root-provided and reads it once, from the root
|
|
425
456
|
* injector, so in a route's `providers` it changes nothing.
|
|
@@ -508,7 +539,7 @@ export declare class WrDialogFooter {
|
|
|
508
539
|
*
|
|
509
540
|
* @default 'end'
|
|
510
541
|
*/
|
|
511
|
-
readonly align: import("@angular/core").InputSignal<"center" | "
|
|
542
|
+
readonly align: import("@angular/core").InputSignal<"center" | "end" | "start">;
|
|
512
543
|
protected readonly classes: import("@angular/core").Signal<string>;
|
|
513
544
|
static ɵfac: i0.ɵɵFactoryDeclaration<WrDialogFooter, never>;
|
|
514
545
|
static ɵdir: i0.ɵɵDirectiveDeclaration<WrDialogFooter, "[wrDialogFooter]", never, {
|
|
@@ -548,4 +579,4 @@ export declare class WrDialogClose<R = unknown> {
|
|
|
548
579
|
};
|
|
549
580
|
}, {}, never, never, true, never>;
|
|
550
581
|
}
|
|
551
|
-
export type { WrDialogAlertOptions, WrDialogAutoFocus, WrDialogConfirmOptions, WrDialogDefaults, WrDialogIntent, WrDialogMessageOptions, WrDialogOptions, WrDialogRole };
|
|
582
|
+
export type { WrDialogAlertOptions, WrDialogAutoFocus, WrDialogConfirmOptions, WrDialogDefaults, WrDialogIntent, WrDialogMessageOptions, WrDialogOptions, WrDialogRole, WrDialogSize };
|
|
@@ -1,18 +1,26 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
/**
|
|
3
|
-
* Focus the host element after the first render
|
|
4
|
-
* expression
|
|
3
|
+
* Focus the host element after the first render, or whenever the bound
|
|
4
|
+
* expression turns truthy. `"first"` focuses the first focusable element
|
|
5
|
+
* inside the host instead: the control of a form, a card or a dialog body.
|
|
6
|
+
* Disabled and hidden elements are skipped.
|
|
5
7
|
*
|
|
6
8
|
* @example
|
|
7
9
|
* ```html
|
|
8
10
|
* <input wrAutofocus />
|
|
9
11
|
* <input [wrAutofocus]="shouldFocus()" />
|
|
12
|
+
* <form wrAutofocus="first">…</form>
|
|
13
|
+
* <form [wrAutofocus]="editing() && 'first'">…</form>
|
|
10
14
|
* ```
|
|
11
15
|
*/
|
|
12
16
|
export declare class WrAutofocus {
|
|
13
|
-
/**
|
|
14
|
-
|
|
17
|
+
/**
|
|
18
|
+
* Truthy = focus the host, `'first'` = focus the first focusable element
|
|
19
|
+
* inside it. Defaults to `true` so bare `wrAutofocus` works.
|
|
20
|
+
*/
|
|
21
|
+
readonly wrAutofocus: import("@angular/core").InputSignalWithTransform<boolean | "first", unknown>;
|
|
15
22
|
private readonly el;
|
|
23
|
+
private readonly injector;
|
|
16
24
|
constructor();
|
|
17
25
|
static ɵfac: i0.ɵɵFactoryDeclaration<WrAutofocus, never>;
|
|
18
26
|
static ɵdir: i0.ɵɵDirectiveDeclaration<WrAutofocus, "[wrAutofocus]", never, {
|
package/types/ngwr-drawer.d.ts
CHANGED
|
@@ -582,7 +582,7 @@ export declare class WrDrawerContent {
|
|
|
582
582
|
export declare class WrDrawerFooter {
|
|
583
583
|
constructor();
|
|
584
584
|
/** Horizontal alignment of footer content. @default 'end' */
|
|
585
|
-
readonly align: import("@angular/core").InputSignal<"center" | "
|
|
585
|
+
readonly align: import("@angular/core").InputSignal<"center" | "end" | "start">;
|
|
586
586
|
protected readonly classes: import("@angular/core").Signal<string>;
|
|
587
587
|
static ɵfac: i0.ɵɵFactoryDeclaration<WrDrawerFooter, never>;
|
|
588
588
|
static ɵdir: i0.ɵɵDirectiveDeclaration<WrDrawerFooter, "[wrDrawerFooter]", never, {
|
package/types/ngwr-dropdown.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import * as i0 from "@angular/core";
|
|
|
2
2
|
import { TemplateRef } from "@angular/core";
|
|
3
3
|
import { WrClassInput } from "ngwr/utils";
|
|
4
4
|
import { WrAnchoredPosition } from "ngwr/overlay";
|
|
5
|
-
import
|
|
5
|
+
import "@angular/cdk/overlay";
|
|
6
6
|
/**
|
|
7
7
|
* Holds the menu content rendered when a {@link WrDropdown} opens.
|
|
8
8
|
*
|
|
@@ -388,6 +388,10 @@ export declare class WrEventCalendar {
|
|
|
388
388
|
*/
|
|
389
389
|
private stepRow;
|
|
390
390
|
private shift;
|
|
391
|
+
/** Wall-clock minutes since midnight of the day `date` is on. */
|
|
392
|
+
private wallMinutes;
|
|
393
|
+
/** The wall-clock time `minutes` after midnight of `date`'s day; past 1440 it rolls into the next days. */
|
|
394
|
+
private atMinutes;
|
|
391
395
|
private startOfDay;
|
|
392
396
|
private startOfWeek;
|
|
393
397
|
/** Whole days apart — computed on the day floor, so DST cannot round it off. */
|
package/types/ngwr-form.d.ts
CHANGED
|
@@ -1,6 +1,82 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
import { AfterContentChecked, InjectionToken, Signal } from "@angular/core";
|
|
3
3
|
import { NgControl, ValidationErrors } from "@angular/forms";
|
|
4
|
+
/**
|
|
5
|
+
* Lays out the fields of a form: a column with a gap by default, a wrapping
|
|
6
|
+
* row with `inline`, or rows of `columns` equal columns that fall back to one
|
|
7
|
+
* column when the form itself is narrow.
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```html
|
|
11
|
+
* <form wrForm columns="2">
|
|
12
|
+
* <wr-form-field label="First name"><input wrInput /></wr-form-field>
|
|
13
|
+
* <wr-form-field label="Last name"><input wrInput /></wr-form-field>
|
|
14
|
+
* <wr-form-field label="Email" wrFormSpan><input wrInput /></wr-form-field>
|
|
15
|
+
* </form>
|
|
16
|
+
* ```
|
|
17
|
+
*
|
|
18
|
+
* @see https://ngwr.dev/reference/components/form
|
|
19
|
+
*/
|
|
20
|
+
export declare class WrForm {
|
|
21
|
+
constructor();
|
|
22
|
+
/**
|
|
23
|
+
* Lay the fields out in a wrapping row, aligned on their bottom edge.
|
|
24
|
+
* `columns` is ignored.
|
|
25
|
+
*
|
|
26
|
+
* @default false
|
|
27
|
+
*/
|
|
28
|
+
readonly inline: import("@angular/core").InputSignalWithTransform<boolean, any>;
|
|
29
|
+
/**
|
|
30
|
+
* How many equal columns a row holds. Below a form width of `30rem` every
|
|
31
|
+
* field takes a full row.
|
|
32
|
+
*
|
|
33
|
+
* @default 1
|
|
34
|
+
*/
|
|
35
|
+
readonly columns: import("@angular/core").InputSignalWithTransform<number, unknown>;
|
|
36
|
+
protected readonly grid: import("@angular/core").Signal<boolean>;
|
|
37
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<WrForm, never>;
|
|
38
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<WrForm, "[wrForm]", never, {
|
|
39
|
+
"inline": {
|
|
40
|
+
"alias": "inline";
|
|
41
|
+
"required": false;
|
|
42
|
+
"isSignal": true;
|
|
43
|
+
};
|
|
44
|
+
"columns": {
|
|
45
|
+
"alias": "columns";
|
|
46
|
+
"required": false;
|
|
47
|
+
"isSignal": true;
|
|
48
|
+
};
|
|
49
|
+
}, {}, never, never, true, never>;
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Stretches a child of `[wrForm]` over several columns: all of them with no
|
|
53
|
+
* value, or the given number.
|
|
54
|
+
*
|
|
55
|
+
* @example
|
|
56
|
+
* ```html
|
|
57
|
+
* <wr-form-field label="Address" wrFormSpan="2"><input wrInput /></wr-form-field>
|
|
58
|
+
* ```
|
|
59
|
+
*
|
|
60
|
+
* @see https://ngwr.dev/reference/components/form
|
|
61
|
+
*/
|
|
62
|
+
export declare class WrFormSpan {
|
|
63
|
+
constructor();
|
|
64
|
+
/**
|
|
65
|
+
* Columns to span. Empty or `'full'` takes the whole row.
|
|
66
|
+
*
|
|
67
|
+
* @default 'full'
|
|
68
|
+
*/
|
|
69
|
+
readonly span: import("@angular/core").InputSignalWithTransform<number | "full", unknown>;
|
|
70
|
+
protected readonly track: import("@angular/core").Signal<string>;
|
|
71
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<WrFormSpan, never>;
|
|
72
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<WrFormSpan, "[wrFormSpan]", never, {
|
|
73
|
+
"span": {
|
|
74
|
+
"alias": "wrFormSpan";
|
|
75
|
+
"required": false;
|
|
76
|
+
"isSignal": true;
|
|
77
|
+
};
|
|
78
|
+
}, {}, never, never, true, never>;
|
|
79
|
+
}
|
|
4
80
|
/**
|
|
5
81
|
* Wraps a label + control + error message into a single field row.
|
|
6
82
|
*
|
|
@@ -89,6 +165,12 @@ interface WrFormFieldContext {
|
|
|
89
165
|
* field without it simply describes nothing but its errors.
|
|
90
166
|
*/
|
|
91
167
|
readonly hintId?: Signal<string | null>;
|
|
168
|
+
/**
|
|
169
|
+
* Whether the field is marked `required`. Read through `useFormFieldAria()` as
|
|
170
|
+
* `aria-required`. Optional so an app that provides its own `WR_FORM_FIELD`
|
|
171
|
+
* keeps compiling.
|
|
172
|
+
*/
|
|
173
|
+
readonly required?: Signal<boolean>;
|
|
92
174
|
}
|
|
93
175
|
/** Present only inside a `<wr-form-field>`; inject with `{ optional: true }`. */
|
|
94
176
|
export declare const WR_FORM_FIELD: InjectionToken<WrFormFieldContext>;
|
|
@@ -172,7 +254,7 @@ export declare class WrFormField implements WrFormFieldContext, AfterContentChec
|
|
|
172
254
|
readonly label: import("@angular/core").InputSignal<string>;
|
|
173
255
|
/** Hint text shown below the control. Hidden when an error is visible. */
|
|
174
256
|
readonly hint: import("@angular/core").InputSignal<string>;
|
|
175
|
-
/** Show a `*` next to the label. @default false */
|
|
257
|
+
/** Show a `*` next to the label and set `aria-required` on the projected control. @default false */
|
|
176
258
|
readonly required: import("@angular/core").InputSignalWithTransform<boolean, any>;
|
|
177
259
|
/**
|
|
178
260
|
* Show an "optional" marker next to the label — the word comes from
|
|
@@ -361,6 +443,8 @@ interface WrFormFieldAria {
|
|
|
361
443
|
readonly describedBy: Signal<string | null>;
|
|
362
444
|
/** `'true'` while the field has a validation error, `null` otherwise. */
|
|
363
445
|
readonly ariaInvalid: Signal<'true' | null>;
|
|
446
|
+
/** `'true'` while the field is `required`, `null` otherwise. */
|
|
447
|
+
readonly ariaRequired: Signal<'true' | null>;
|
|
364
448
|
/**
|
|
365
449
|
* Id of the field's `<label>`, for a control `<label for>` cannot reach.
|
|
366
450
|
*
|
package/types/ngwr-i18n.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
|
-
import { EnvironmentProviders, InjectionToken, PipeTransform, Provider, Signal } from "@angular/core";
|
|
2
|
+
import { EnvironmentProviders, InjectionToken, Injector, PipeTransform, Provider, Signal } from "@angular/core";
|
|
3
3
|
import { Observable } from "rxjs";
|
|
4
4
|
/** Translation catalog — flat or nested record of strings. */
|
|
5
5
|
interface WrI18nCatalog {
|
|
@@ -144,6 +144,8 @@ export declare class WrI18n {
|
|
|
144
144
|
private readonly revision;
|
|
145
145
|
/** In-flight load promises — dedupes parallel `t()` callers. @internal */
|
|
146
146
|
private readonly inflight;
|
|
147
|
+
/** Keys whose last load failed: `t()` does not retry them, `use()` and `registerScope()` do. @internal */
|
|
148
|
+
private readonly failed;
|
|
147
149
|
/** Registered scopes — auto-loaded whenever the locale changes. @internal */
|
|
148
150
|
private readonly scopes;
|
|
149
151
|
/** Active locale. Writes go through `use()` so storage stays in sync. */
|
|
@@ -363,9 +365,8 @@ interface WrI18nHttpLoaderConfig {
|
|
|
363
365
|
readonly rootPath?: string;
|
|
364
366
|
}
|
|
365
367
|
/**
|
|
366
|
-
* Loader that fetches catalogs via `HttpClient`.
|
|
367
|
-
*
|
|
368
|
-
* user code.
|
|
368
|
+
* Loader that fetches catalogs via `HttpClient`. A failure errors the stream;
|
|
369
|
+
* the service logs it, serves the key and retries on the next `use()`.
|
|
369
370
|
*/
|
|
370
371
|
export declare class WrI18nHttpLoader implements WrI18nLoader {
|
|
371
372
|
private readonly config;
|
|
@@ -499,4 +500,63 @@ export declare function wrReadI18nText(key: string, fallback: string): Signal<st
|
|
|
499
500
|
* ```
|
|
500
501
|
*/
|
|
501
502
|
export declare function useI18nFormatter(key: string, fallback: string): (params?: WrI18nParams) => string;
|
|
502
|
-
|
|
503
|
+
/** A screen's own sentence for one status: the text, or a function of the error. */
|
|
504
|
+
type WrHttpErrorOverride = string | ((error: unknown) => string);
|
|
505
|
+
/** Options of {@link wrHttpErrorText}. */
|
|
506
|
+
interface WrHttpErrorTextOptions {
|
|
507
|
+
/** The screen's own sentence per status, `0` being a network failure. Wins over everything else. */
|
|
508
|
+
readonly overrides?: Readonly<Partial<Record<number, WrHttpErrorOverride>>>;
|
|
509
|
+
/**
|
|
510
|
+
* Prefer the sentence the server put in the body: `error.error.message`, or
|
|
511
|
+
* a body that is a plain string. For an API that writes its errors for the
|
|
512
|
+
* person at the screen.
|
|
513
|
+
* @default false
|
|
514
|
+
*/
|
|
515
|
+
readonly serverMessage?: boolean;
|
|
516
|
+
/** Where to read `WrI18n` from when the call is outside an injection context, such as a `catch`. */
|
|
517
|
+
readonly injector?: Injector;
|
|
518
|
+
}
|
|
519
|
+
/**
|
|
520
|
+
* The HTTP status of a failed request: of an `HttpErrorResponse`, a `Response`
|
|
521
|
+
* or anything else carrying a numeric `status`. `0` is a request nothing
|
|
522
|
+
* answered (offline, CORS, a dropped connection); `null` is a value that is not
|
|
523
|
+
* an HTTP error at all.
|
|
524
|
+
*
|
|
525
|
+
* @example
|
|
526
|
+
* ```ts
|
|
527
|
+
* if (wrHttpStatus(error) === 401) void router.navigate(['/login']);
|
|
528
|
+
* ```
|
|
529
|
+
*
|
|
530
|
+
* @see https://ngwr.dev/reference/utils/wr-http-error-text
|
|
531
|
+
*/
|
|
532
|
+
export declare function wrHttpStatus(error: unknown): number | null;
|
|
533
|
+
/**
|
|
534
|
+
* A sentence for a failed request, in the active language. Highest first:
|
|
535
|
+
*
|
|
536
|
+
* 1. `overrides[status]`, the screen's own wording.
|
|
537
|
+
* 2. With `serverMessage`, the sentence in the response body.
|
|
538
|
+
* 3. The catalog: `httpError.<status>`, then `httpError.4xx` / `httpError.5xx`
|
|
539
|
+
* (both take `{{status}}`), `httpError.network` for status `0`, and
|
|
540
|
+
* `httpError.unknown` for the rest. An app's own catalog wins over ngwr's,
|
|
541
|
+
* and English is the floor when neither has the key.
|
|
542
|
+
*
|
|
543
|
+
* Call it in an injection context, or pass `injector` from a `catch` or a
|
|
544
|
+
* callback.
|
|
545
|
+
*
|
|
546
|
+
* @example
|
|
547
|
+
* ```ts
|
|
548
|
+
* private readonly injector = inject(Injector);
|
|
549
|
+
*
|
|
550
|
+
* try {
|
|
551
|
+
* await this.api.save(order);
|
|
552
|
+
* } catch (error) {
|
|
553
|
+
* this.toast.danger(
|
|
554
|
+
* wrHttpErrorText(error, { injector: this.injector, overrides: { 409: 'This name is taken.' } })
|
|
555
|
+
* );
|
|
556
|
+
* }
|
|
557
|
+
* ```
|
|
558
|
+
*
|
|
559
|
+
* @see https://ngwr.dev/reference/utils/wr-http-error-text
|
|
560
|
+
*/
|
|
561
|
+
export declare function wrHttpErrorText(error: unknown, options?: WrHttpErrorTextOptions): string;
|
|
562
|
+
export type { ProvideWrI18nOptions, WrHttpErrorOverride, WrHttpErrorTextOptions, WrI18nBaseCatalogs, WrI18nCatalog, WrI18nConfig, WrI18nConfigResolved, WrI18nHttpLoaderConfig, WrI18nLoader, WrI18nMissingHandler, WrI18nParams, WrI18nStaticCatalogs, WrI18nStaticScopedCatalogs, WrI18nTranslateOptions };
|
|
@@ -104,6 +104,8 @@ export declare class WrInputNumber<M extends WrInputNumberMode = 'number'> imple
|
|
|
104
104
|
* `--wr-control-*` contract. @default 'md'
|
|
105
105
|
*/
|
|
106
106
|
readonly size: import("@angular/core").InputSignal<WrInputSize>;
|
|
107
|
+
/** Stretch the field to fill its parent's width. @default false */
|
|
108
|
+
readonly block: import("@angular/core").InputSignalWithTransform<boolean, any>;
|
|
107
109
|
/** Pill-shaped corners — forwarded to the group AND the field. @default false */
|
|
108
110
|
readonly rounded: import("@angular/core").InputSignalWithTransform<boolean, any>;
|
|
109
111
|
/** Optional prefix label (e.g. `"$"`). */
|
|
@@ -169,6 +171,7 @@ export declare class WrInputNumber<M extends WrInputNumberMode = 'number'> imple
|
|
|
169
171
|
private readonly group;
|
|
170
172
|
/** Text currently in the input (may be partial / invalid mid-type). */
|
|
171
173
|
protected readonly text: import("@angular/core").WritableSignal<string>;
|
|
174
|
+
private lastCommitted;
|
|
172
175
|
/** Whether the input is focused. While true, the input handlers own `text`. */
|
|
173
176
|
protected readonly focused: import("@angular/core").WritableSignal<boolean>;
|
|
174
177
|
private readonly field;
|
|
@@ -282,6 +285,11 @@ export declare class WrInputNumber<M extends WrInputNumberMode = 'number'> imple
|
|
|
282
285
|
"required": false;
|
|
283
286
|
"isSignal": true;
|
|
284
287
|
};
|
|
288
|
+
"block": {
|
|
289
|
+
"alias": "block";
|
|
290
|
+
"required": false;
|
|
291
|
+
"isSignal": true;
|
|
292
|
+
};
|
|
285
293
|
"rounded": {
|
|
286
294
|
"alias": "rounded";
|
|
287
295
|
"required": false;
|
package/types/ngwr-input.d.ts
CHANGED
|
@@ -65,6 +65,13 @@ export declare class WrInput {
|
|
|
65
65
|
private readonly fieldAria;
|
|
66
66
|
protected readonly describedBy: import("@angular/core").Signal<string | null>;
|
|
67
67
|
protected readonly ariaInvalid: import("@angular/core").Signal<"true" | null>;
|
|
68
|
+
/** The element's own `aria-required`, read once: a hand-written one wins over the field's. */
|
|
69
|
+
private readonly ownAriaRequired;
|
|
70
|
+
/**
|
|
71
|
+
* Native `required` (including the one Signal Forms binds) already announces it,
|
|
72
|
+
* so the field's `required` only fills in when neither is there.
|
|
73
|
+
*/
|
|
74
|
+
protected ariaRequired(): string | null;
|
|
68
75
|
/**
|
|
69
76
|
* Control size. @default 'md'
|
|
70
77
|
*
|
package/types/ngwr-layout.d.ts
CHANGED
|
@@ -93,7 +93,7 @@ export declare class WrLayoutHeader {
|
|
|
93
93
|
}
|
|
94
94
|
/**
|
|
95
95
|
* Main content area of a {@link WrLayout}. Flex-grows to fill
|
|
96
|
-
* remaining space.
|
|
96
|
+
* remaining space. Its padding is `--wr-layout-content-padding`, one length.
|
|
97
97
|
*/
|
|
98
98
|
export declare class WrLayoutContent {
|
|
99
99
|
constructor();
|
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*
|
|
4
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
5
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
6
|
+
*/
|
|
1
7
|
import { EnvironmentProviders } from "@angular/core";
|
|
2
8
|
/**
|
|
3
9
|
* Drive {@link WrLoadingBar} from router navigations: `NavigationStart` takes a
|
|
@@ -30,6 +30,16 @@ import * as i0 from "@angular/core";
|
|
|
30
30
|
* header's height plus `--wr-page-header-sticky-top`, and focus, anchors and
|
|
31
31
|
* `scrollIntoView()` all stop short of it.
|
|
32
32
|
*
|
|
33
|
+
* The filters row is inside the header's own box, so under `sticky` it stays in
|
|
34
|
+
* view with the title: it is the place for a view switch or tabs as well.
|
|
35
|
+
*
|
|
36
|
+
* `bleed` carries the header over the padding of the box it tops, to the top and
|
|
37
|
+
* both side edges, and pads it by as much, so a sticky header's background and
|
|
38
|
+
* border run edge to edge. The amount is `--wr-page-header-bleed`, which reads
|
|
39
|
+
* `--wr-layout-content-padding`: inside `wr-layout-content` it follows the
|
|
40
|
+
* content's padding, and anywhere else it is zero until set. Make the header
|
|
41
|
+
* the first thing in that box.
|
|
42
|
+
*
|
|
33
43
|
* A bare `<div>` wrapper in the actions or the filters slot, one with no `class`
|
|
34
44
|
* and no `style`, is laid out as a wrapping row with the region's own gap, so
|
|
35
45
|
* the controls inside it are spaced exactly like controls projected one by one.
|
|
@@ -40,7 +50,7 @@ import * as i0 from "@angular/core";
|
|
|
40
50
|
*
|
|
41
51
|
* @example
|
|
42
52
|
* ```html
|
|
43
|
-
* <wr-page-header title="Settings" subtitle="Manage your workspace" compact sticky>
|
|
53
|
+
* <wr-page-header title="Settings" subtitle="Manage your workspace" compact sticky bleed>
|
|
44
54
|
* <nav wrPageHeaderBreadcrumbs>…</nav>
|
|
45
55
|
* <div wrPageHeaderActions>
|
|
46
56
|
* <button wr-btn>Invite</button>
|
|
@@ -84,6 +94,13 @@ export declare class WrPageHeader {
|
|
|
84
94
|
* @default false
|
|
85
95
|
*/
|
|
86
96
|
readonly sticky: import("@angular/core").InputSignalWithTransform<boolean, any>;
|
|
97
|
+
/**
|
|
98
|
+
* Run over the padding of the box the header tops, to the top and both side
|
|
99
|
+
* edges, by `--wr-page-header-bleed` (the content padding inside
|
|
100
|
+
* `wr-layout-content`, zero elsewhere until set).
|
|
101
|
+
* @default false
|
|
102
|
+
*/
|
|
103
|
+
readonly bleed: import("@angular/core").InputSignalWithTransform<boolean, any>;
|
|
87
104
|
static ɵfac: i0.ɵɵFactoryDeclaration<WrPageHeader, never>;
|
|
88
105
|
static ɵcmp: i0.ɵɵComponentDeclaration<WrPageHeader, "wr-page-header", never, {
|
|
89
106
|
"title": {
|
|
@@ -111,5 +128,10 @@ export declare class WrPageHeader {
|
|
|
111
128
|
"required": false;
|
|
112
129
|
"isSignal": true;
|
|
113
130
|
};
|
|
131
|
+
"bleed": {
|
|
132
|
+
"alias": "bleed";
|
|
133
|
+
"required": false;
|
|
134
|
+
"isSignal": true;
|
|
135
|
+
};
|
|
114
136
|
}, {}, never, ["[wrPageHeaderBreadcrumbs]", "[wrPageHeaderActions]", "[wrPageHeaderExtra]", "[wrPageHeaderFilters]"], true, never>;
|
|
115
137
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
import { WrClassInput } from "ngwr/utils";
|
|
3
3
|
import { WrAnchoredPosition, WrOverlayAutoFocus } from "ngwr/overlay";
|
|
4
|
-
import
|
|
4
|
+
import "@angular/cdk/overlay";
|
|
5
5
|
export declare class WrPopconfirm {
|
|
6
6
|
/** Confirmation message. */
|
|
7
7
|
readonly message: import("@angular/core").InputSignal<string>;
|
package/types/ngwr-popover.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
|
-
import { Signal, TemplateRef } from "@angular/core";
|
|
2
|
+
import { AfterViewInit, Signal, TemplateRef } from "@angular/core";
|
|
3
3
|
import { WrClassInput } from "ngwr/utils";
|
|
4
4
|
import { WrAnchoredPosition, WrOverlayAutoFocus } from "ngwr/overlay";
|
|
5
|
-
import
|
|
5
|
+
import "@angular/cdk/overlay";
|
|
6
6
|
/**
|
|
7
7
|
* What a chart's hover tooltip says about one section.
|
|
8
8
|
*
|
|
@@ -186,7 +186,7 @@ export declare function useChartTooltip(enabled: Signal<boolean | 'hoverable'>,
|
|
|
186
186
|
* @internal
|
|
187
187
|
*/
|
|
188
188
|
export declare function wrCoerceChartTooltip(value: unknown): boolean | 'hoverable';
|
|
189
|
-
export declare class WrPopover {
|
|
189
|
+
export declare class WrPopover implements AfterViewInit {
|
|
190
190
|
/**
|
|
191
191
|
* Content to render inside the panel.
|
|
192
192
|
* - In **popover** mode (default): pass a `TemplateRef`.
|
|
@@ -199,7 +199,11 @@ export declare class WrPopover {
|
|
|
199
199
|
* - `'popover'` (default) — template content, click trigger, dialog
|
|
200
200
|
* semantics.
|
|
201
201
|
* - `'tooltip'` — text content, hover / keyboard-focus trigger,
|
|
202
|
-
* `role="tooltip"`, `aria-describedby` on the host.
|
|
202
|
+
* `role="tooltip"`, `aria-describedby` on the host. A button or link host
|
|
203
|
+
* with no accessible name (no text, `aria-label`, `aria-labelledby` or
|
|
204
|
+
* `title`) is named by the text instead, through `aria-label`, and gets no
|
|
205
|
+
* `aria-describedby`. Your own `aria-label` always wins; when it equals the
|
|
206
|
+
* text, the host is not described by it a second time.
|
|
203
207
|
*/
|
|
204
208
|
readonly mode: import("@angular/core").InputSignal<"popover" | "tooltip">;
|
|
205
209
|
/**
|
|
@@ -310,7 +314,18 @@ export declare class WrPopover {
|
|
|
310
314
|
private openedByKeyboard;
|
|
311
315
|
private showTimer;
|
|
312
316
|
private hideTimer;
|
|
317
|
+
/** The `aria-label` this directive wrote on a host that had no name. */
|
|
318
|
+
private writtenName;
|
|
319
|
+
/** Whether the tooltip text is the host's accessible name, so it must not describe it too. */
|
|
320
|
+
protected readonly namesHost: import("@angular/core").WritableSignal<boolean>;
|
|
321
|
+
private readonly onServer;
|
|
313
322
|
constructor();
|
|
323
|
+
/**
|
|
324
|
+
* The first name, on the server too, where no render hook runs. A view hook
|
|
325
|
+
* rather than an `effect()`: effects run before host bindings, and `<wr-btn>`
|
|
326
|
+
* gets its `role` from one.
|
|
327
|
+
*/
|
|
328
|
+
ngAfterViewInit(): void;
|
|
314
329
|
/** Open the panel. Does nothing while the trigger is disabled. */
|
|
315
330
|
open(): void;
|
|
316
331
|
close(): void;
|
|
@@ -371,6 +386,15 @@ export declare class WrPopover {
|
|
|
371
386
|
* app, where the CDK never expires an origin at all.
|
|
372
387
|
*/
|
|
373
388
|
private fromNavigationKey;
|
|
389
|
+
/**
|
|
390
|
+
* Names a button or link that has no accessible name with the tooltip text,
|
|
391
|
+
* and records whether that text is the host's name either way.
|
|
392
|
+
*
|
|
393
|
+
* A tooltip that only describes leaves an icon-only control unnamed, and one
|
|
394
|
+
* that repeats the name is read twice. An `aria-label` this did not write is
|
|
395
|
+
* the consumer's and is never replaced.
|
|
396
|
+
*/
|
|
397
|
+
private syncName;
|
|
374
398
|
private scheduleShow;
|
|
375
399
|
private scheduleHide;
|
|
376
400
|
private clearTimers;
|