ngwr 16.6.0 → 16.7.1
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/avatar/styles/_index.scss +39 -0
- package/button/styles/_index.scss +45 -2
- package/checkbox/styles/_index.scss +4 -0
- package/copy-value/styles/_index.scss +4 -0
- package/dropdown/styles/_index.scss +17 -0
- package/fesm2022/ngwr-affix.mjs +3 -3
- package/fesm2022/ngwr-alert.mjs +3 -3
- package/fesm2022/ngwr-anchor.mjs +3 -3
- package/fesm2022/ngwr-animations-aurora.mjs +3 -3
- package/fesm2022/ngwr-animations-blur-reveal.mjs +3 -3
- package/fesm2022/ngwr-animations-click-sparks.mjs +3 -3
- package/fesm2022/ngwr-animations-confetti.mjs +3 -3
- package/fesm2022/ngwr-animations-decode.mjs +3 -3
- package/fesm2022/ngwr-animations-destruct.mjs +3 -3
- package/fesm2022/ngwr-animations-dot-grid.mjs +3 -3
- package/fesm2022/ngwr-animations-falling-letters.mjs +3 -3
- package/fesm2022/ngwr-animations-flow-lines.mjs +3 -3
- package/fesm2022/ngwr-animations-fluid-cursor.mjs +3 -3
- package/fesm2022/ngwr-animations-glitch.mjs +3 -3
- package/fesm2022/ngwr-animations-glow-border.mjs +3 -3
- package/fesm2022/ngwr-animations-gradient-flow.mjs +3 -3
- package/fesm2022/ngwr-animations-marquee.mjs +4 -3
- package/fesm2022/ngwr-animations-marquee.mjs.map +1 -1
- package/fesm2022/ngwr-animations-orbit.mjs +3 -3
- package/fesm2022/ngwr-animations-reveal.mjs +3 -3
- package/fesm2022/ngwr-animations-ripple-grid.mjs +3 -3
- package/fesm2022/ngwr-animations-rotate-reveal.mjs +3 -3
- package/fesm2022/ngwr-animations-shimmer.mjs +3 -3
- package/fesm2022/ngwr-animations-spotlight.mjs +3 -3
- package/fesm2022/ngwr-animations-thread-lines.mjs +3 -3
- package/fesm2022/ngwr-animations-tilt.mjs +3 -3
- package/fesm2022/ngwr-animations-typewriter.mjs +3 -3
- package/fesm2022/ngwr-avatar.mjs +171 -6
- package/fesm2022/ngwr-avatar.mjs.map +1 -1
- package/fesm2022/ngwr-back-top.mjs +3 -3
- package/fesm2022/ngwr-badge.mjs +6 -6
- package/fesm2022/ngwr-breadcrumbs.mjs +9 -8
- package/fesm2022/ngwr-breadcrumbs.mjs.map +1 -1
- package/fesm2022/ngwr-burger.mjs +3 -3
- package/fesm2022/ngwr-button.mjs +26 -6
- package/fesm2022/ngwr-button.mjs.map +1 -1
- package/fesm2022/ngwr-calendar.mjs +3 -3
- package/fesm2022/ngwr-card.mjs +9 -9
- package/fesm2022/ngwr-carousel.mjs +6 -6
- package/fesm2022/ngwr-cascader.mjs +5 -5
- package/fesm2022/ngwr-cascader.mjs.map +1 -1
- package/fesm2022/ngwr-charts-bar-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-boxplot-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-bullet-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-calendar-heatmap.mjs +3 -3
- package/fesm2022/ngwr-charts-candlestick-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-chart-legend.mjs +9 -9
- package/fesm2022/ngwr-charts-core.mjs +6 -6
- package/fesm2022/ngwr-charts-donut-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-funnel-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-gauge.mjs +3 -3
- package/fesm2022/ngwr-charts-heatmap-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-line-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-meter-group.mjs +3 -3
- package/fesm2022/ngwr-charts-radar-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-scatter-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-sparkline.mjs +3 -3
- package/fesm2022/ngwr-charts-treemap-chart.mjs +3 -3
- package/fesm2022/ngwr-charts-waterfall-chart.mjs +3 -3
- package/fesm2022/ngwr-checkbox.mjs +6 -6
- package/fesm2022/ngwr-clipboard.mjs +3 -3
- package/fesm2022/ngwr-collapse.mjs +9 -9
- package/fesm2022/ngwr-color-picker.mjs +6 -6
- package/fesm2022/ngwr-command-palette.mjs +3 -3
- package/fesm2022/ngwr-comment.mjs +7 -6
- package/fesm2022/ngwr-comment.mjs.map +1 -1
- package/fesm2022/ngwr-compare.mjs +3 -3
- package/fesm2022/ngwr-context-menu.mjs +12 -12
- package/fesm2022/ngwr-cookie.mjs +3 -3
- package/fesm2022/ngwr-copy-value.mjs +3 -3
- package/fesm2022/ngwr-counter.mjs +6 -6
- package/fesm2022/ngwr-date-picker-testing.mjs +35 -0
- package/fesm2022/ngwr-date-picker-testing.mjs.map +1 -1
- package/fesm2022/ngwr-date-picker.mjs +103 -53
- package/fesm2022/ngwr-date-picker.mjs.map +1 -1
- package/fesm2022/ngwr-date-stamp.mjs +3 -3
- package/fesm2022/ngwr-date.mjs +40 -16
- package/fesm2022/ngwr-date.mjs.map +1 -1
- package/fesm2022/ngwr-density.mjs +6 -6
- package/fesm2022/ngwr-descriptions.mjs +6 -6
- package/fesm2022/ngwr-dialog.mjs +19 -18
- package/fesm2022/ngwr-dialog.mjs.map +1 -1
- package/fesm2022/ngwr-directives.mjs +181 -18
- package/fesm2022/ngwr-directives.mjs.map +1 -1
- package/fesm2022/ngwr-divider.mjs +3 -3
- package/fesm2022/ngwr-drawer.mjs +18 -18
- package/fesm2022/ngwr-dropdown-testing.mjs +5 -1
- package/fesm2022/ngwr-dropdown-testing.mjs.map +1 -1
- package/fesm2022/ngwr-dropdown.mjs +59 -16
- package/fesm2022/ngwr-dropdown.mjs.map +1 -1
- package/fesm2022/ngwr-editor.mjs +6 -5
- package/fesm2022/ngwr-editor.mjs.map +1 -1
- package/fesm2022/ngwr-empty.mjs +3 -3
- package/fesm2022/ngwr-event-calendar.mjs +7 -6
- package/fesm2022/ngwr-event-calendar.mjs.map +1 -1
- package/fesm2022/ngwr-file-upload-testing.mjs +5 -0
- package/fesm2022/ngwr-file-upload-testing.mjs.map +1 -1
- package/fesm2022/ngwr-file-upload.mjs +68 -13
- package/fesm2022/ngwr-file-upload.mjs.map +1 -1
- package/fesm2022/ngwr-form.mjs +18 -16
- package/fesm2022/ngwr-form.mjs.map +1 -1
- package/fesm2022/ngwr-graph-testing.mjs +30 -0
- package/fesm2022/ngwr-graph-testing.mjs.map +1 -1
- package/fesm2022/ngwr-graph.mjs +100 -11
- package/fesm2022/ngwr-graph.mjs.map +1 -1
- package/fesm2022/ngwr-hotkey.mjs +6 -6
- package/fesm2022/ngwr-i18n-ar.mjs +6 -2
- package/fesm2022/ngwr-i18n-ar.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-cs.mjs +6 -2
- package/fesm2022/ngwr-i18n-cs.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-de.mjs +6 -2
- package/fesm2022/ngwr-i18n-de.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-en.mjs +6 -2
- package/fesm2022/ngwr-i18n-en.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-es.mjs +6 -2
- package/fesm2022/ngwr-i18n-es.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-fr.mjs +6 -2
- package/fesm2022/ngwr-i18n-fr.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-he.mjs +6 -2
- package/fesm2022/ngwr-i18n-he.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-hi.mjs +6 -2
- package/fesm2022/ngwr-i18n-hi.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-id.mjs +6 -2
- package/fesm2022/ngwr-i18n-id.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-it.mjs +6 -2
- package/fesm2022/ngwr-i18n-it.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-ja.mjs +6 -2
- package/fesm2022/ngwr-i18n-ja.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-kk.mjs +520 -0
- package/fesm2022/ngwr-i18n-kk.mjs.map +1 -0
- package/fesm2022/ngwr-i18n-ko.mjs +6 -2
- package/fesm2022/ngwr-i18n-ko.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-nl.mjs +6 -2
- package/fesm2022/ngwr-i18n-nl.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-pl.mjs +6 -2
- package/fesm2022/ngwr-i18n-pl.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-pt.mjs +6 -2
- package/fesm2022/ngwr-i18n-pt.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-ru.mjs +6 -2
- package/fesm2022/ngwr-i18n-ru.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-sv.mjs +6 -2
- package/fesm2022/ngwr-i18n-sv.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-tr.mjs +6 -2
- package/fesm2022/ngwr-i18n-tr.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-uk.mjs +6 -2
- package/fesm2022/ngwr-i18n-uk.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-vi.mjs +6 -2
- package/fesm2022/ngwr-i18n-vi.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-zh-tw.mjs +6 -2
- package/fesm2022/ngwr-i18n-zh-tw.mjs.map +1 -1
- package/fesm2022/ngwr-i18n-zh.mjs +6 -2
- package/fesm2022/ngwr-i18n-zh.mjs.map +1 -1
- package/fesm2022/ngwr-i18n.mjs +9 -9
- package/fesm2022/ngwr-icon.mjs +6 -6
- package/fesm2022/ngwr-image-cropper.mjs +8 -4
- package/fesm2022/ngwr-image-cropper.mjs.map +1 -1
- package/fesm2022/ngwr-input-number.mjs +3 -3
- package/fesm2022/ngwr-input-otp.mjs +3 -3
- package/fesm2022/ngwr-input.mjs +15 -15
- package/fesm2022/ngwr-keyboard.mjs +3 -3
- package/fesm2022/ngwr-knob.mjs +3 -3
- package/fesm2022/ngwr-layout.mjs +15 -15
- package/fesm2022/ngwr-lightbox.mjs +8 -8
- package/fesm2022/ngwr-lightbox.mjs.map +1 -1
- package/fesm2022/ngwr-list.mjs +8 -8
- package/fesm2022/ngwr-list.mjs.map +1 -1
- package/fesm2022/ngwr-load-state.mjs +16 -15
- package/fesm2022/ngwr-load-state.mjs.map +1 -1
- package/fesm2022/ngwr-loading-bar.mjs +6 -6
- package/fesm2022/ngwr-mention.mjs +6 -6
- package/fesm2022/ngwr-meta.mjs +6 -6
- package/fesm2022/ngwr-overlay.mjs +9 -9
- package/fesm2022/ngwr-page-header.mjs +3 -3
- package/fesm2022/ngwr-pagination-testing.mjs +3 -0
- package/fesm2022/ngwr-pagination-testing.mjs.map +1 -1
- package/fesm2022/ngwr-pagination.mjs +32 -5
- package/fesm2022/ngwr-pagination.mjs.map +1 -1
- package/fesm2022/ngwr-pipes.mjs +27 -27
- package/fesm2022/ngwr-platform.mjs +9 -9
- package/fesm2022/ngwr-popconfirm.mjs +7 -6
- package/fesm2022/ngwr-popconfirm.mjs.map +1 -1
- package/fesm2022/ngwr-popover.mjs +126 -16
- package/fesm2022/ngwr-popover.mjs.map +1 -1
- package/fesm2022/ngwr-progress.mjs +75 -10
- package/fesm2022/ngwr-progress.mjs.map +1 -1
- package/fesm2022/ngwr-pull-to-refresh.mjs +3 -3
- package/fesm2022/ngwr-qr.mjs +3 -3
- package/fesm2022/ngwr-radio.mjs +6 -6
- package/fesm2022/ngwr-rating.mjs +3 -3
- package/fesm2022/ngwr-resizable.mjs +3 -3
- package/fesm2022/ngwr-result.mjs +12 -12
- package/fesm2022/ngwr-schema-form.mjs +10 -6
- package/fesm2022/ngwr-schema-form.mjs.map +1 -1
- package/fesm2022/ngwr-scroll.mjs +255 -7
- package/fesm2022/ngwr-scroll.mjs.map +1 -1
- package/fesm2022/ngwr-segmented.mjs +3 -3
- package/fesm2022/ngwr-select.mjs +28 -19
- package/fesm2022/ngwr-select.mjs.map +1 -1
- package/fesm2022/ngwr-sidebar-testing.mjs +17 -1
- package/fesm2022/ngwr-sidebar-testing.mjs.map +1 -1
- package/fesm2022/ngwr-sidebar.mjs +66 -11
- package/fesm2022/ngwr-sidebar.mjs.map +1 -1
- package/fesm2022/ngwr-skeleton.mjs +3 -3
- package/fesm2022/ngwr-slider.mjs +3 -3
- package/fesm2022/ngwr-sortable-list.mjs +11 -11
- package/fesm2022/ngwr-sortable-list.mjs.map +1 -1
- package/fesm2022/ngwr-speed-dial.mjs +3 -3
- package/fesm2022/ngwr-spinner.mjs +3 -3
- package/fesm2022/ngwr-splitter.mjs +3 -3
- package/fesm2022/ngwr-statistic.mjs +9 -9
- package/fesm2022/ngwr-stepper.mjs +6 -6
- package/fesm2022/ngwr-storage.mjs +3 -3
- package/fesm2022/ngwr-switch.mjs +3 -3
- package/fesm2022/ngwr-table-router.mjs +89 -0
- package/fesm2022/ngwr-table-router.mjs.map +1 -0
- package/fesm2022/ngwr-table-testing.mjs +5 -0
- package/fesm2022/ngwr-table-testing.mjs.map +1 -1
- package/fesm2022/ngwr-table.mjs +282 -43
- package/fesm2022/ngwr-table.mjs.map +1 -1
- package/fesm2022/ngwr-tabs-router.mjs +11 -7
- package/fesm2022/ngwr-tabs-router.mjs.map +1 -1
- package/fesm2022/ngwr-tabs-testing.mjs +8 -1
- package/fesm2022/ngwr-tabs-testing.mjs.map +1 -1
- package/fesm2022/ngwr-tabs.mjs +60 -10
- package/fesm2022/ngwr-tabs.mjs.map +1 -1
- package/fesm2022/ngwr-textarea.mjs +3 -3
- package/fesm2022/ngwr-theme.mjs +3 -3
- package/fesm2022/ngwr-timeline.mjs +6 -6
- package/fesm2022/ngwr-toast.mjs +15 -15
- package/fesm2022/ngwr-toolbar.mjs +3 -3
- package/fesm2022/ngwr-tour.mjs +7 -6
- package/fesm2022/ngwr-tour.mjs.map +1 -1
- package/fesm2022/ngwr-transfer.mjs +4 -3
- package/fesm2022/ngwr-transfer.mjs.map +1 -1
- package/fesm2022/ngwr-tree.mjs +3 -3
- package/fesm2022/ngwr-typography.mjs +3 -3
- package/fesm2022/ngwr-utils-router.mjs +3 -3
- package/fesm2022/ngwr-utils.mjs +30 -2
- package/fesm2022/ngwr-utils.mjs.map +1 -1
- package/fesm2022/ngwr-version.mjs +1 -1
- package/fesm2022/ngwr-version.mjs.map +1 -1
- package/fesm2022/ngwr-virtual-scroll.mjs +3 -3
- package/fesm2022/ngwr-window.mjs +18 -13
- package/fesm2022/ngwr-window.mjs.map +1 -1
- package/file-upload/styles/_index.scss +16 -0
- package/graph/styles/_index.scss +48 -0
- package/i18n/ar.json +4 -2
- package/i18n/cs.json +4 -2
- package/i18n/de.json +4 -2
- package/i18n/en.json +4 -2
- package/i18n/es.json +4 -2
- package/i18n/fr.json +4 -2
- package/i18n/he.json +4 -2
- package/i18n/hi.json +4 -2
- package/i18n/id.json +4 -2
- package/i18n/it.json +4 -2
- package/i18n/ja.json +4 -2
- package/i18n/kk.json +567 -0
- package/i18n/ko.json +4 -2
- package/i18n/nl.json +4 -2
- package/i18n/pl.json +4 -2
- package/i18n/pt.json +4 -2
- package/i18n/ru.json +4 -2
- package/i18n/sv.json +4 -2
- package/i18n/tr.json +4 -2
- package/i18n/uk.json +4 -2
- package/i18n/vi.json +4 -2
- package/i18n/zh-TW.json +4 -2
- package/i18n/zh.json +4 -2
- package/llms-full.txt +29 -18
- package/llms.txt +4 -1
- package/package.json +15 -7
- package/pagination/styles/_index.scss +6 -0
- package/popover/styles/_index.scss +4 -2
- package/progress/styles/_index.scss +64 -0
- package/radio/styles/_index.scss +4 -0
- package/schematics/use/symbol-map.json +5 -0
- package/sidebar/styles/_index.scss +58 -6
- package/skills/ngwr/SKILL.md +7 -6
- package/skills/ngwr/references/catalog.md +6 -4
- package/switch/styles/_index.scss +4 -0
- package/table/styles/_index.scss +128 -32
- package/tabs/styles/_index.scss +9 -0
- package/theme/styles/_focus.scss +3 -1
- package/tour/styles/_index.scss +3 -2
- package/types/ngwr-avatar.d.ts +39 -0
- package/types/ngwr-button.d.ts +12 -0
- package/types/ngwr-date-picker-testing.d.ts +22 -0
- package/types/ngwr-date-picker.d.ts +84 -17
- package/types/ngwr-date.d.ts +51 -0
- package/types/ngwr-directives.d.ts +45 -0
- package/types/ngwr-dropdown-testing.d.ts +8 -1
- package/types/ngwr-dropdown.d.ts +29 -0
- package/types/ngwr-file-upload-testing.d.ts +10 -0
- package/types/ngwr-file-upload.d.ts +55 -1
- package/types/ngwr-form.d.ts +3 -1
- package/types/ngwr-graph-testing.d.ts +28 -1
- package/types/ngwr-graph.d.ts +53 -3
- package/types/ngwr-i18n-kk.d.ts +3 -0
- package/types/ngwr-image-cropper.d.ts +6 -0
- package/types/ngwr-pagination-testing.d.ts +8 -0
- package/types/ngwr-pagination.d.ts +16 -0
- package/types/ngwr-popover.d.ts +39 -0
- package/types/ngwr-progress.d.ts +63 -1
- package/types/ngwr-scroll.d.ts +95 -0
- package/types/ngwr-select.d.ts +31 -12
- package/types/ngwr-sidebar-testing.d.ts +21 -7
- package/types/ngwr-sidebar.d.ts +66 -4
- package/types/ngwr-table-router.d.ts +49 -0
- package/types/ngwr-table-testing.d.ts +7 -0
- package/types/ngwr-table.d.ts +185 -6
- package/types/ngwr-tabs-router.d.ts +4 -5
- package/types/ngwr-tabs-testing.d.ts +5 -1
- package/types/ngwr-tabs.d.ts +34 -1
- package/types/ngwr-utils.d.ts +13 -0
- package/types/ngwr-version.d.ts +1 -1
|
@@ -0,0 +1,49 @@
|
|
|
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
|
+
*/
|
|
7
|
+
import * as i0 from "@angular/core";
|
|
8
|
+
import { WrTableRoutingAdapter } from "ngwr/table";
|
|
9
|
+
/**
|
|
10
|
+
* Router support for the row links of `<wr-table>`. Add it to the `imports` of
|
|
11
|
+
* the component that declares the table, and `wrTableRouting` to the table:
|
|
12
|
+
*
|
|
13
|
+
* @example
|
|
14
|
+
* ```ts
|
|
15
|
+
* import { WrTable } from 'ngwr/table';
|
|
16
|
+
* import { WrTableRouting } from 'ngwr/table/router';
|
|
17
|
+
*
|
|
18
|
+
* @Component({ imports: [WrTable, WrTableRouting], template: `
|
|
19
|
+
* <wr-table wrTableRouting [columns]="columns" [items]="orders" [rowLink]="orderLink" />
|
|
20
|
+
* ` })
|
|
21
|
+
* export class OrdersPage {
|
|
22
|
+
* protected readonly orderLink = (order: Order) => ['/orders', order.id];
|
|
23
|
+
* }
|
|
24
|
+
* ```
|
|
25
|
+
*
|
|
26
|
+
* `rowLink` then returns what `routerLink` takes: a URL string or an array of
|
|
27
|
+
* commands, relative to the route of the component that declares the table
|
|
28
|
+
* unless it starts with `/`. A plain click navigates in the app; a middle
|
|
29
|
+
* click or a click with a modifier stays the browser's, on a real href. A
|
|
30
|
+
* string with a scheme or a host of its own (`https://…`, `mailto:…`, `//…`)
|
|
31
|
+
* stays a plain link.
|
|
32
|
+
*
|
|
33
|
+
* A separate entry point, so a table that links nowhere does not carry
|
|
34
|
+
* `@angular/router`; a directive rather than a provider function, so a
|
|
35
|
+
* relative link resolves against the declaring component's route. Both for
|
|
36
|
+
* the reasons `WrTabsRouting` gives.
|
|
37
|
+
*/
|
|
38
|
+
export declare class WrTableRouting implements WrTableRoutingAdapter {
|
|
39
|
+
private readonly router;
|
|
40
|
+
private readonly locationStrategy;
|
|
41
|
+
private readonly route;
|
|
42
|
+
/** The current URL as a signal: a relative link's target moves when the route does. */
|
|
43
|
+
private readonly url;
|
|
44
|
+
href(link: string | readonly unknown[]): string;
|
|
45
|
+
navigate(link: string | readonly unknown[], event: MouseEvent): void;
|
|
46
|
+
private tree;
|
|
47
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<WrTableRouting, never>;
|
|
48
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<WrTableRouting, "[wrTableRouting]", ["wrTableRouting"], {}, {}, never, never, true, never>;
|
|
49
|
+
}
|
|
@@ -240,6 +240,7 @@ export declare class WrTableRowHarness extends ContentContainerComponentHarness
|
|
|
240
240
|
* that for a control would report every leaf as expandable.
|
|
241
241
|
*/
|
|
242
242
|
private readonly disclosure;
|
|
243
|
+
private readonly rowLink;
|
|
243
244
|
/** The row's data cells, in DOM order. The lead control cells are not cells. */
|
|
244
245
|
getCells(filters?: WrTableCellHarnessFilters): Promise<WrTableCellHarness[]>;
|
|
245
246
|
/** The text of every data cell, in DOM order. */
|
|
@@ -270,6 +271,12 @@ export declare class WrTableRowHarness extends ContentContainerComponentHarness
|
|
|
270
271
|
isExpanded(): Promise<boolean>;
|
|
271
272
|
/** Open or close the row. Throws when it has nothing to open. */
|
|
272
273
|
toggleExpand(): Promise<void>;
|
|
274
|
+
/**
|
|
275
|
+
* The href of the row's link, or `null` for a row that has none: the table
|
|
276
|
+
* sets no `rowLink`, or it returned `null` for this row. As rendered, so a
|
|
277
|
+
* routed link reads the way the browser would open it.
|
|
278
|
+
*/
|
|
279
|
+
getLink(): Promise<string | null>;
|
|
273
280
|
/**
|
|
274
281
|
* The row's depth as the table announces it — 1-based `aria-level`, `null` in a
|
|
275
282
|
* flat table, where depth is not a thing that exists.
|
package/types/ngwr-table.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
|
-
import { TemplateRef, WritableSignal } from "@angular/core";
|
|
2
|
+
import { InjectionToken, TemplateRef, WritableSignal } from "@angular/core";
|
|
3
3
|
import { WrClassInput, WrSafeAny } from "ngwr/utils";
|
|
4
4
|
import { WrPaginationSize } from "ngwr/pagination";
|
|
5
5
|
import { CdkDragDrop, CdkDragMove, CdkDragSortEvent, CdkDragStart } from "@angular/cdk/drag-drop";
|
|
@@ -84,6 +84,38 @@ interface WrTableRowClick<T extends WrTableRow = WrTableRow> {
|
|
|
84
84
|
/** The click itself, for its modifier keys. */
|
|
85
85
|
readonly event: MouseEvent;
|
|
86
86
|
}
|
|
87
|
+
/**
|
|
88
|
+
* Where a body row leads: an href, or `null` for a row that leads nowhere.
|
|
89
|
+
*
|
|
90
|
+
* With `WrTableRouting` from `ngwr/table/router` on the table the value is a
|
|
91
|
+
* router link instead, a URL string or an array of commands, the two forms
|
|
92
|
+
* `routerLink` takes. An array needs the adapter: without it the row gets no
|
|
93
|
+
* link.
|
|
94
|
+
*
|
|
95
|
+
* It runs for every rendered row when the rows, the function or a signal it
|
|
96
|
+
* reads change: keep it a pure read of the row.
|
|
97
|
+
*/
|
|
98
|
+
type WrTableRowLink<T extends WrTableRow = WrTableRow> = (row: T) => string | readonly unknown[] | null | undefined;
|
|
99
|
+
/**
|
|
100
|
+
* @license
|
|
101
|
+
*
|
|
102
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
103
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
104
|
+
*/
|
|
105
|
+
/**
|
|
106
|
+
* What `wr-table` asks of a router for its row links. `WrTableRouting` from
|
|
107
|
+
* `ngwr/table/router` implements it over `@angular/router`, which keeps the
|
|
108
|
+
* router out of `ngwr/table`.
|
|
109
|
+
*/
|
|
110
|
+
interface WrTableRoutingAdapter {
|
|
111
|
+
/** The href a row link renders for a `rowLink` value. */
|
|
112
|
+
href(link: string | readonly unknown[]): string;
|
|
113
|
+
/**
|
|
114
|
+
* Handle a click on a row link. A modified or non-primary click is left to
|
|
115
|
+
* the browser, so ctrl/cmd-click still opens the row in a new tab.
|
|
116
|
+
*/
|
|
117
|
+
navigate(link: string | readonly unknown[], event: MouseEvent): void;
|
|
118
|
+
}
|
|
87
119
|
/**
|
|
88
120
|
* @license
|
|
89
121
|
*
|
|
@@ -240,6 +272,11 @@ interface WrTableColumn<T extends WrTableRow = WrTableRow> {
|
|
|
240
272
|
* `title` (an icon column) it is the column's name.
|
|
241
273
|
*/
|
|
242
274
|
readonly headerHint?: string;
|
|
275
|
+
/**
|
|
276
|
+
* `false` keeps the column out of the table's `search`. A column takes part
|
|
277
|
+
* by default, through its `format` or its value; an `actions` column never does.
|
|
278
|
+
*/
|
|
279
|
+
readonly searchable?: boolean;
|
|
243
280
|
/** Show a clickable sort indicator in the header. */
|
|
244
281
|
readonly sortable?: boolean;
|
|
245
282
|
/** When non-empty, shows a filter dropdown in the header. */
|
|
@@ -489,7 +526,8 @@ type WrTableLoadingMode = 'auto' | 'overlay' | 'bar';
|
|
|
489
526
|
*/
|
|
490
527
|
interface WrTableSelectionContext<T extends WrTableRow = WrTableRow> {
|
|
491
528
|
/**
|
|
492
|
-
* The selected rows the table holds, in `items` order
|
|
529
|
+
* The selected rows the table holds, in `items` order, including the ones a
|
|
530
|
+
* `search` hides: the same set `count` counts. In server mode
|
|
493
531
|
* (`total` set) that is the selected rows of the current page: a key
|
|
494
532
|
* selected on another page is counted and is not here.
|
|
495
533
|
*/
|
|
@@ -504,6 +542,19 @@ interface WrTableSelectionContext<T extends WrTableRow = WrTableRow> {
|
|
|
504
542
|
*/
|
|
505
543
|
readonly scope: 'page' | 'all';
|
|
506
544
|
}
|
|
545
|
+
/**
|
|
546
|
+
* @license
|
|
547
|
+
*
|
|
548
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
549
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
550
|
+
*/
|
|
551
|
+
/**
|
|
552
|
+
* How tightly `<wr-table>` pads its cells.
|
|
553
|
+
*
|
|
554
|
+
* - `'md'` - the default padding
|
|
555
|
+
* - `'sm'` - compact cells, for a dense table
|
|
556
|
+
*/
|
|
557
|
+
type WrTableSize = 'sm' | 'md';
|
|
507
558
|
/**
|
|
508
559
|
* Everything a reader can change about a `<wr-table>`, in one object: what
|
|
509
560
|
* `(stateChange)` emits and `[state]` restores. It holds plain data, so a
|
|
@@ -577,6 +628,8 @@ interface CellColumn<T extends WrTableRow> {
|
|
|
577
628
|
readonly actions: boolean;
|
|
578
629
|
/** Whether its cell names the row (see `labelColumnKey`). */
|
|
579
630
|
readonly label: boolean;
|
|
631
|
+
/** Whether its cell holds the row's link (see `linkColumnKey`). */
|
|
632
|
+
readonly link: boolean;
|
|
580
633
|
/** Whether its cell carries the tree indent and toggle. */
|
|
581
634
|
readonly tree: boolean;
|
|
582
635
|
readonly template: TemplateRef<WrTableCellContext> | undefined;
|
|
@@ -594,6 +647,11 @@ interface CellEdit {
|
|
|
594
647
|
readonly pending: WritableSignal<unknown>;
|
|
595
648
|
readonly context: WrTableEditCellContext;
|
|
596
649
|
}
|
|
650
|
+
/** A row's link as rendered, and the `rowLink` value a routed one came from. */
|
|
651
|
+
interface RowLink {
|
|
652
|
+
readonly href: string;
|
|
653
|
+
readonly routed: string | readonly unknown[] | null;
|
|
654
|
+
}
|
|
597
655
|
/**
|
|
598
656
|
* Data table with sortable / filterable headers and custom cell templates.
|
|
599
657
|
*
|
|
@@ -641,6 +699,37 @@ export declare class WrTable<T extends WrTableRow = WrTableRow> {
|
|
|
641
699
|
* One cast at the boundary: the INPUT is wide so any object shape binds, while
|
|
642
700
|
* the body keeps indexing rows the way it always has.
|
|
643
701
|
*/
|
|
702
|
+
private readonly source;
|
|
703
|
+
/**
|
|
704
|
+
* Client-side text search. A row stays when the text some searchable column
|
|
705
|
+
* shows contains the query, ignoring case and accents: the column's `format`
|
|
706
|
+
* over the value, else the value as text. A missing value shows nothing, so
|
|
707
|
+
* its `empty` placeholder is not searched. Columns that take part: the ones
|
|
708
|
+
* on screen, less `actions` columns and `searchable: false`. An empty or
|
|
709
|
+
* blank query is no search.
|
|
710
|
+
*
|
|
711
|
+
* The table filters nothing else itself, so a search runs over whatever
|
|
712
|
+
* `items` holds: filter and sort `items` as before, the search narrows the
|
|
713
|
+
* result. It comes before paging, so the pager counts the matches and the
|
|
714
|
+
* page returns to 1 when the query changes, and `toCsv()`, the summary row
|
|
715
|
+
* and the select-all scope see the matching rows only. In tree mode a parent
|
|
716
|
+
* stays while it or any descendant matches and shows only the children that
|
|
717
|
+
* stay; it keeps its open state, so a parent kept for a deep match may need
|
|
718
|
+
* opening. Server mode (`total` set) holds one page and ignores it.
|
|
719
|
+
* A selection survives a search: rows it hides stay selected, and the count,
|
|
720
|
+
* the bar's `$implicit` and `toCsv({ selectedOnly })` all use the whole selection.
|
|
721
|
+
* @default ''
|
|
722
|
+
*/
|
|
723
|
+
readonly search: import("@angular/core").InputSignal<string>;
|
|
724
|
+
/**
|
|
725
|
+
* The columns the search reads, with the folded text of each cell per row,
|
|
726
|
+
* so a new query only re-runs `includes`. A new `items` array or column list
|
|
727
|
+
* starts an empty cache: `format` may read any field of its row, so only a
|
|
728
|
+
* new list says what a cell shows may have changed.
|
|
729
|
+
*/
|
|
730
|
+
private readonly searchColumns;
|
|
731
|
+
/** The rows after the search, plus the kept children per parent in tree mode. */
|
|
732
|
+
private readonly searched;
|
|
644
733
|
private readonly rows;
|
|
645
734
|
/** Mark the table as loading; `loadingMode` picks how it shows. @default false */
|
|
646
735
|
readonly loading: import("@angular/core").InputSignalWithTransform<boolean, any>;
|
|
@@ -954,10 +1043,57 @@ export declare class WrTable<T extends WrTableRow = WrTableRow> {
|
|
|
954
1043
|
*
|
|
955
1044
|
* Pointer only: a row takes no focus and no key for it, so give the same
|
|
956
1045
|
* action a control of its own in the row (a link or a button in a cell) for
|
|
957
|
-
* keyboard and screen reader users
|
|
958
|
-
*
|
|
1046
|
+
* keyboard and screen reader users, or use `rowLink` when the row leads to a
|
|
1047
|
+
* URL. The table adds no cursor either: style `.wr-table__tr--clickable`.
|
|
1048
|
+
*
|
|
1049
|
+
* While it is bound the rows wear `wr-table__tr--clickable` and tint on
|
|
1050
|
+
* hover. A row with a `rowLink` does not fire it for a click that follows
|
|
1051
|
+
* the link.
|
|
959
1052
|
*/
|
|
960
1053
|
readonly rowClick: import("@angular/core").OutputEmitterRef<WrTableRowClick<T>>;
|
|
1054
|
+
/**
|
|
1055
|
+
* Whether anything listens to `rowClick`. Angular has no public read for
|
|
1056
|
+
* it, so this looks at the emitter's own list, and `table-row-link.spec.ts`
|
|
1057
|
+
* holds it across Angular bumps.
|
|
1058
|
+
*/
|
|
1059
|
+
protected rowClickBound(): boolean;
|
|
1060
|
+
/**
|
|
1061
|
+
* Makes a row a link: a function from the row to its href, or to `null` for
|
|
1062
|
+
* a row that leads nowhere. Each linked row renders one real `<a>` laid
|
|
1063
|
+
* under its cells, so Enter, middle click, ctrl / cmd click and "copy link"
|
|
1064
|
+
* work anywhere on the row, and the row is one tab stop.
|
|
1065
|
+
*
|
|
1066
|
+
* The link is named by the row's label cell: the tree column in tree mode,
|
|
1067
|
+
* else the first column. Controls in the row stay their own: the same list
|
|
1068
|
+
* `rowClick` skips, with `wrTableIgnoreRowClick` for anything else.
|
|
1069
|
+
*
|
|
1070
|
+
* A plain href loads the page. In a routed app add `WrTableRouting` from
|
|
1071
|
+
* `ngwr/table/router` to the table, and the value becomes a router link: a
|
|
1072
|
+
* URL string or an array of commands.
|
|
1073
|
+
*
|
|
1074
|
+
* Linked rows wear `wr-table__tr--link` and tint on hover.
|
|
1075
|
+
*
|
|
1076
|
+
* @example
|
|
1077
|
+
* ```html
|
|
1078
|
+
* <wr-table [columns]="columns" [items]="orders" [rowLink]="orderLink" />
|
|
1079
|
+
* ```
|
|
1080
|
+
* ```ts
|
|
1081
|
+
* protected readonly orderLink = (order: Order) => `/orders/${order.id}`;
|
|
1082
|
+
* ```
|
|
1083
|
+
* @default null
|
|
1084
|
+
*/
|
|
1085
|
+
readonly rowLink: import("@angular/core").InputSignal<WrTableRowLink<T> | null>;
|
|
1086
|
+
/** The routing adapter, when `WrTableRouting` from `ngwr/table/router` is on the table. */
|
|
1087
|
+
private readonly routing;
|
|
1088
|
+
private warnedNoRouting;
|
|
1089
|
+
/** The link of every rendered row that has one, so a virtualized body resolves its window only. */
|
|
1090
|
+
protected readonly rowLinks: import("@angular/core").Signal<ReadonlyMap<Record<string, unknown>, RowLink>>;
|
|
1091
|
+
/**
|
|
1092
|
+
* The column whose cell holds the row's link: the first one that is not
|
|
1093
|
+
* pinned, since a pinned cell is sticky and would hold the stretched link
|
|
1094
|
+
* inside its own box. The label column when every column is pinned.
|
|
1095
|
+
*/
|
|
1096
|
+
protected readonly linkColumnKey: import("@angular/core").Signal<string | null>;
|
|
961
1097
|
protected onBodyClick(event: MouseEvent): void;
|
|
962
1098
|
/**
|
|
963
1099
|
* Rows per page. Set to `0` (default) to disable client-side pagination
|
|
@@ -1197,6 +1333,14 @@ export declare class WrTable<T extends WrTableRow = WrTableRow> {
|
|
|
1197
1333
|
* @default 'auto'
|
|
1198
1334
|
*/
|
|
1199
1335
|
readonly layout: import("@angular/core").InputSignal<WrTableLayout>;
|
|
1336
|
+
/**
|
|
1337
|
+
* How tightly the cells are padded. `'sm'` is the compact table: it sets
|
|
1338
|
+
* `--wr-table-cell-padding-y` and `-x` one notch tighter, for header, body
|
|
1339
|
+
* and footer cells alike. The app's density still multiplies both, so `sm`
|
|
1340
|
+
* is relative to it. Card mode keeps its own padding.
|
|
1341
|
+
* @default 'md'
|
|
1342
|
+
*/
|
|
1343
|
+
readonly size: import("@angular/core").InputSignal<WrTableSize>;
|
|
1200
1344
|
/**
|
|
1201
1345
|
* A column's name for its controls: the title, the hint after it, or the hint
|
|
1202
1346
|
* alone under an empty title.
|
|
@@ -1216,7 +1360,7 @@ export declare class WrTable<T extends WrTableRow = WrTableRow> {
|
|
|
1216
1360
|
private readonly modality;
|
|
1217
1361
|
private onTipTarget;
|
|
1218
1362
|
/** The row's class with the consumer's own, resolved through the `rowClass` predicate. */
|
|
1219
|
-
protected rowClasses(row: Record<string, unknown>, index: number): string;
|
|
1363
|
+
protected rowClasses(row: Record<string, unknown>, index: number, linked: boolean): string;
|
|
1220
1364
|
private readonly resizeWidths;
|
|
1221
1365
|
private resizeKey;
|
|
1222
1366
|
private resizeStartX;
|
|
@@ -1264,6 +1408,14 @@ export declare class WrTable<T extends WrTableRow = WrTableRow> {
|
|
|
1264
1408
|
private readonly viewportPx;
|
|
1265
1409
|
/** Measured first-row height (px) when `rowHeight` is auto; 0 until measured. */
|
|
1266
1410
|
private readonly measuredRowPx;
|
|
1411
|
+
/** True for the render that measures a row after a size change. */
|
|
1412
|
+
protected readonly remeasuring: WritableSignal<boolean>;
|
|
1413
|
+
/**
|
|
1414
|
+
* `--wr-table-row-h` on a virtualized table, once a height is known: a given
|
|
1415
|
+
* `rowHeight` or a measured one. Unset while measuring, so a row is measured at
|
|
1416
|
+
* its own height and not at the fallback or at an older measure.
|
|
1417
|
+
*/
|
|
1418
|
+
protected readonly rowHeightVar: import("@angular/core").Signal<number | null>;
|
|
1267
1419
|
/** Fixed layout forced ON by virtualization (distinct from the resize latch). */
|
|
1268
1420
|
private readonly virtualFixed;
|
|
1269
1421
|
/** `virtualScroll` requested AND the data shape is safe to window. SSR-deterministic. */
|
|
@@ -1615,6 +1767,12 @@ export declare class WrTable<T extends WrTableRow = WrTableRow> {
|
|
|
1615
1767
|
* say nothing the arrow does not.
|
|
1616
1768
|
*/
|
|
1617
1769
|
protected sortOrderFor(key: string): number | null;
|
|
1770
|
+
/**
|
|
1771
|
+
* A click anywhere in a sortable header cell sorts, as a click on its sort
|
|
1772
|
+
* button does. A control in the cell keeps its own click: the sort button
|
|
1773
|
+
* (which cycles by itself), the filter trigger, the resize handle.
|
|
1774
|
+
*/
|
|
1775
|
+
protected onHeaderClick(event: MouseEvent, key: string, sortable: boolean | undefined): void;
|
|
1618
1776
|
protected cycleSort(key: string): void;
|
|
1619
1777
|
protected onFilter(key: string, items: readonly WrTableFilterItem[]): void;
|
|
1620
1778
|
protected cellContext(item: Record<string, unknown>, col: CellColumn<T>): WrTableCellContext;
|
|
@@ -1636,6 +1794,11 @@ export declare class WrTable<T extends WrTableRow = WrTableRow> {
|
|
|
1636
1794
|
"required": false;
|
|
1637
1795
|
"isSignal": true;
|
|
1638
1796
|
};
|
|
1797
|
+
"search": {
|
|
1798
|
+
"alias": "search";
|
|
1799
|
+
"required": false;
|
|
1800
|
+
"isSignal": true;
|
|
1801
|
+
};
|
|
1639
1802
|
"loading": {
|
|
1640
1803
|
"alias": "loading";
|
|
1641
1804
|
"required": false;
|
|
@@ -1801,6 +1964,11 @@ export declare class WrTable<T extends WrTableRow = WrTableRow> {
|
|
|
1801
1964
|
"required": false;
|
|
1802
1965
|
"isSignal": true;
|
|
1803
1966
|
};
|
|
1967
|
+
"rowLink": {
|
|
1968
|
+
"alias": "rowLink";
|
|
1969
|
+
"required": false;
|
|
1970
|
+
"isSignal": true;
|
|
1971
|
+
};
|
|
1804
1972
|
"pageSize": {
|
|
1805
1973
|
"alias": "pageSize";
|
|
1806
1974
|
"required": false;
|
|
@@ -1861,6 +2029,11 @@ export declare class WrTable<T extends WrTableRow = WrTableRow> {
|
|
|
1861
2029
|
"required": false;
|
|
1862
2030
|
"isSignal": true;
|
|
1863
2031
|
};
|
|
2032
|
+
"size": {
|
|
2033
|
+
"alias": "size";
|
|
2034
|
+
"required": false;
|
|
2035
|
+
"isSignal": true;
|
|
2036
|
+
};
|
|
1864
2037
|
"editable": {
|
|
1865
2038
|
"alias": "editable";
|
|
1866
2039
|
"required": false;
|
|
@@ -2298,4 +2471,10 @@ export declare function wrReadField<T>(item: T, key: string): string | number;
|
|
|
2298
2471
|
* @param accessor Reads the value of a key; defaults to `wrReadField`.
|
|
2299
2472
|
*/
|
|
2300
2473
|
export declare function wrSortRows<T>(rows: readonly T[], sort: readonly WrTableSortState[], accessor?: WrTableSortAccessor<T>): readonly T[];
|
|
2301
|
-
|
|
2474
|
+
/**
|
|
2475
|
+
* Token a `<wr-table>` reads to send its row links through a router. Provided
|
|
2476
|
+
* by the `WrTableRouting` directive from `ngwr/table/router`; absent by
|
|
2477
|
+
* default, which keeps `@angular/router` out of a table that links nowhere.
|
|
2478
|
+
*/
|
|
2479
|
+
export declare const WR_TABLE_ROUTING: InjectionToken<WrTableRoutingAdapter>;
|
|
2480
|
+
export type { WrTableCellContext, WrTableCellEdit, WrTableChooserColumn, WrTableColumn, WrTableColumnAlign, WrTableColumns, WrTableCsvOptions, WrTableEditCellContext, WrTableEditable, WrTableExpandContext, WrTableFilterChange, WrTableFilterItem, WrTableGroupContext, WrTableLayout, WrTableLoadingMode, WrTableRoutingAdapter, WrTableRow, WrTableRowClass, WrTableRowClick, WrTableRowLink, WrTableSelectionContext, WrTableSize, WrTableSortAccessor, WrTableSortDirection, WrTableSortState, WrTableState, WrTableSummary, WrTableSummaryContext, WrTableTruncate };
|
|
@@ -54,15 +54,14 @@ export declare class WrTabsRouting implements WrTabsRoutingAdapter {
|
|
|
54
54
|
private readonly locationStrategy;
|
|
55
55
|
private readonly route;
|
|
56
56
|
/**
|
|
57
|
-
* The current URL, as a signal, so `href()`
|
|
58
|
-
*
|
|
59
|
-
*
|
|
60
|
-
* and its target moves when the route does — which is why `RouterLink`
|
|
57
|
+
* The current URL, as a signal, so `href()` is reactive to navigation when
|
|
58
|
+
* read from a computed: a RELATIVE link is resolved against the active route
|
|
59
|
+
* and its target moves when the route does, which is why `RouterLink`
|
|
61
60
|
* recomputes its own href on every navigation too.
|
|
62
61
|
*/
|
|
63
62
|
private readonly url;
|
|
64
63
|
href(commands: string | readonly string[]): string;
|
|
65
|
-
isActive(commands: string | readonly string[]): boolean;
|
|
64
|
+
isActive(commands: string | readonly string[], exact?: boolean): boolean;
|
|
66
65
|
navigate(commands: string | readonly string[], event: MouseEvent): void;
|
|
67
66
|
private tree;
|
|
68
67
|
static ɵfac: i0.ɵɵFactoryDeclaration<WrTabsRouting, never>;
|
|
@@ -79,8 +79,12 @@ export declare class WrTabHarness extends ContentContainerComponentHarness {
|
|
|
79
79
|
static hostSelector: string;
|
|
80
80
|
/** Build a predicate that narrows the query — pass to `getHarness` / `getAllHarnesses`. */
|
|
81
81
|
static with(options?: WrTabHarnessFilters): HarnessPredicate<WrTabHarness>;
|
|
82
|
-
/** The tab's visible label, trimmed — the `<wr-tab>`'s `title`. */
|
|
82
|
+
/** The tab's visible label, trimmed — the `<wr-tab>`'s `title`. The count is not part of it. */
|
|
83
83
|
getLabel(): Promise<string>;
|
|
84
|
+
/** The count shown after the label, or `null` while the tab has none. */
|
|
85
|
+
getCount(): Promise<number | null>;
|
|
86
|
+
/** The accessible name the header announces: the label, plus the count when it has one ("Inbox, 3"). */
|
|
87
|
+
getAccessibleName(): Promise<string>;
|
|
84
88
|
/**
|
|
85
89
|
* The header's own id, which is what the panel points back at with
|
|
86
90
|
* `aria-labelledby` — the tab is the panel's accessible name.
|
package/types/ngwr-tabs.d.ts
CHANGED
|
@@ -21,6 +21,22 @@ export declare class WrTab {
|
|
|
21
21
|
readonly key: import("@angular/core").InputSignal<string>;
|
|
22
22
|
/** Router target — when set, the tab becomes a `[routerLink]` link. */
|
|
23
23
|
readonly routerLink: import("@angular/core").InputSignal<string | readonly string[] | null>;
|
|
24
|
+
/**
|
|
25
|
+
* Router tab only: select it on its own path, not on the paths below it, so an
|
|
26
|
+
* "Overview" tab at `/project/42` is not selected on `/project/42/settings`.
|
|
27
|
+
* Query params, fragment and matrix params are matched as without it.
|
|
28
|
+
*
|
|
29
|
+
* @default false
|
|
30
|
+
*/
|
|
31
|
+
readonly exact: import("@angular/core").InputSignalWithTransform<boolean, any>;
|
|
32
|
+
/**
|
|
33
|
+
* A count after the label, as a small badge: unread messages, results. `null`
|
|
34
|
+
* (default) shows nothing, `0` shows `0`. The tab's accessible name becomes
|
|
35
|
+
* the label and the count, "Inbox, 3".
|
|
36
|
+
*
|
|
37
|
+
* @default null
|
|
38
|
+
*/
|
|
39
|
+
readonly count: import("@angular/core").InputSignal<number | null>;
|
|
24
40
|
/** Disable the tab. */
|
|
25
41
|
readonly disabled: import("@angular/core").InputSignalWithTransform<boolean, any>;
|
|
26
42
|
/** Tab content template; portaled into the parent's panel area. @internal */
|
|
@@ -35,6 +51,12 @@ export declare class WrTab {
|
|
|
35
51
|
* resolves `WR_TABS` above.
|
|
36
52
|
*/
|
|
37
53
|
private readonly routing;
|
|
54
|
+
/**
|
|
55
|
+
* The header's `aria-label`: the title with the count after it, or `null` while
|
|
56
|
+
* there is no count and the visible label is the name already.
|
|
57
|
+
* @internal
|
|
58
|
+
*/
|
|
59
|
+
readonly accessibleName: import("@angular/core").Signal<string | null>;
|
|
38
60
|
protected readonly isRouter: import("@angular/core").Signal<boolean>;
|
|
39
61
|
/**
|
|
40
62
|
* Resolved href for a router tab — `null` for a content tab, and for a
|
|
@@ -69,6 +91,16 @@ export declare class WrTab {
|
|
|
69
91
|
"required": false;
|
|
70
92
|
"isSignal": true;
|
|
71
93
|
};
|
|
94
|
+
"exact": {
|
|
95
|
+
"alias": "exact";
|
|
96
|
+
"required": false;
|
|
97
|
+
"isSignal": true;
|
|
98
|
+
};
|
|
99
|
+
"count": {
|
|
100
|
+
"alias": "count";
|
|
101
|
+
"required": false;
|
|
102
|
+
"isSignal": true;
|
|
103
|
+
};
|
|
72
104
|
"disabled": {
|
|
73
105
|
"alias": "disabled";
|
|
74
106
|
"required": false;
|
|
@@ -126,8 +158,9 @@ interface WrTabsRoutingAdapter {
|
|
|
126
158
|
/**
|
|
127
159
|
* Whether the current URL selects this tab. Matched the way `routerLinkActive`
|
|
128
160
|
* matches without `[routerLinkActiveOptions]`: a path prefix, not an exact URL.
|
|
161
|
+
* With `exact`, only the tab's own path counts, not the paths below it.
|
|
129
162
|
*/
|
|
130
|
-
isActive(commands: string | readonly string[]): boolean;
|
|
163
|
+
isActive(commands: string | readonly string[], exact?: boolean): boolean;
|
|
131
164
|
/**
|
|
132
165
|
* Handle a click on a tab anchor. A modified or non-primary click is left to
|
|
133
166
|
* the browser, so ctrl/cmd-click still opens the tab in a new window.
|
package/types/ngwr-utils.d.ts
CHANGED
|
@@ -457,6 +457,19 @@ export declare function wrContentDispositionFileName(header: string | null | und
|
|
|
457
457
|
* @param fileName - The name the browser offers in its save dialog.
|
|
458
458
|
*/
|
|
459
459
|
export declare function wrDownloadBlob(blob: Blob, fileName: string): void;
|
|
460
|
+
/**
|
|
461
|
+
* @license
|
|
462
|
+
*
|
|
463
|
+
* Use of this source code is governed by an MIT-style license that can be
|
|
464
|
+
* found in the LICENSE file at https://github.com/thekhegay/ngwr/blob/main/LICENSE
|
|
465
|
+
*/
|
|
466
|
+
/**
|
|
467
|
+
* `name` with the extension of the MIME `type`. An image extension the name
|
|
468
|
+
* already carries is replaced; anything else after a dot is part of the name
|
|
469
|
+
* (`photo.v2`, `John.Smith`), so the extension is appended. A type with no
|
|
470
|
+
* known extension leaves `name` as it is.
|
|
471
|
+
*/
|
|
472
|
+
export declare function wrFileNameForType(name: string, type: string): string;
|
|
460
473
|
/**
|
|
461
474
|
* @license
|
|
462
475
|
*
|
package/types/ngwr-version.d.ts
CHANGED
|
@@ -15,7 +15,7 @@ import { InjectionToken } from "@angular/core";
|
|
|
15
15
|
* Distinct from `Version` exported by `@angular/core`, which reports the
|
|
16
16
|
* loaded Angular runtime version (e.g. `'22.0.0'`), not ngwr's.
|
|
17
17
|
*/
|
|
18
|
-
export declare const NGWR_VERSION = "16.
|
|
18
|
+
export declare const NGWR_VERSION = "16.7.1";
|
|
19
19
|
/**
|
|
20
20
|
* Injection token holding the ngwr library version string.
|
|
21
21
|
*
|