@ds-mo/ui 14.6.0 → 14.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/.package-ready.json +1 -1
- package/dist/agent-patterns.json +6 -6
- package/dist/agent.json +49 -19
- package/dist/angular/ds-menu.d.ts +7 -1
- package/dist/angular/ds-menu.js +5 -2
- package/dist/angular/ds-table.d.ts +4 -1
- package/dist/angular/ds-table.js +7 -4
- package/dist/components/ds-agent-questionnaire.js +1 -1
- package/dist/components/ds-agent-response.js +1 -1
- package/dist/components/ds-banner.js +1 -1
- package/dist/components/ds-bar-nav.js +1 -1
- package/dist/components/ds-bar-title.js +1 -1
- package/dist/components/ds-bar-workflow.js +1 -1
- package/dist/components/ds-bar-workflow.js.map +1 -1
- package/dist/components/ds-button-unfilled.js +1 -1
- package/dist/components/ds-card-chart.js +1 -1
- package/dist/components/ds-card-setting.js +1 -1
- package/dist/components/ds-code-block.js +1 -1
- package/dist/components/ds-conversation-list-item.js +1 -1
- package/dist/components/ds-conversation-list-item.js.map +1 -1
- package/dist/components/ds-filter-menu.js +1 -1
- package/dist/components/ds-filter-menu.js.map +1 -1
- package/dist/components/ds-input.js +1 -1
- package/dist/components/ds-markdown.js +1 -1
- package/dist/components/ds-menu.js +1 -1
- package/dist/components/ds-message-actions.js +1 -1
- package/dist/components/ds-message-composer.js +1 -1
- package/dist/components/ds-message-scroller.js +1 -1
- package/dist/components/ds-mobile-header.js +1 -1
- package/dist/components/ds-mobile-section-switcher.js +1 -1
- package/dist/components/ds-mobile-sheet-nav.js +1 -1
- package/dist/components/ds-modal.js +1 -1
- package/dist/components/ds-pagination.js +1 -1
- package/dist/components/ds-panel-nav.js +1 -1
- package/dist/components/ds-panel-tool-header.js +1 -1
- package/dist/components/ds-panel-tool-search.js +1 -1
- package/dist/components/ds-panel-tools.js +1 -1
- package/dist/components/ds-select.js +1 -1
- package/dist/components/ds-shell-app.js +1 -1
- package/dist/components/ds-shell-tools.js +1 -1
- package/dist/components/ds-table.js +1 -1
- package/dist/components/ds-table.js.map +1 -1
- package/dist/components/ds-toast.js +1 -1
- package/dist/components/{p-BGQUiJuJ.js → p--VFa9x3k.js} +2 -2
- package/dist/components/{p-C7-ylLcB.js → p-B5um-ps9.js} +2 -2
- package/dist/components/{p-K_vg9Eng.js → p-BAebDW3a.js} +2 -2
- package/dist/components/p-BKWgofxz.js +2 -0
- package/dist/components/p-BKWgofxz.js.map +1 -0
- package/dist/components/{p-DL12lNtv.js → p-BmqfTAXM.js} +2 -2
- package/dist/components/{p-CDEME0Uc.js → p-C-L4InQ0.js} +2 -2
- package/dist/components/{p-BykcjUd6.js → p-C1jsgfeh.js} +2 -2
- package/dist/components/{p-BFDKKBYh.js → p-CoQSB3tl.js} +2 -2
- package/dist/components/{p-DJ-n-gyr.js → p-CvwtYbmh.js} +2 -2
- package/dist/components/{p-os90t2-f.js → p-D5VglrfF.js} +2 -2
- package/dist/components/{p-BX-R5EhL.js → p-D5bPuNiF.js} +2 -2
- package/dist/components/{p-CCpJcSTE.js → p-DOC4RaAy.js} +2 -2
- package/dist/components/{p-C5230yJY.js → p-DQUxg6Si.js} +2 -2
- package/dist/components/{p-DTf90AyI.js → p-bQm3gfr1.js} +2 -2
- package/dist/components/{p-CTTDiW33.js → p-c_5SXjwx.js} +2 -2
- package/dist/components/p-c_5SXjwx.js.map +1 -0
- package/dist/components/p-mLRtp5A4.js +2 -0
- package/dist/components/{p-3r4TfcZX.js.map → p-mLRtp5A4.js.map} +1 -1
- package/dist/docs/components.json +154 -3
- package/dist/mcp-data/registry/button-unfilled.json +6 -6
- package/dist/mcp-data/registry/menu.json +40 -12
- package/dist/mcp-data/registry/registry.json +48 -18
- package/dist/mcp-data/registry/table.json +81 -9
- package/dist/react/ds-menu.d.ts +2 -1
- package/dist/react/ds-menu.js +2 -1
- package/dist/react/ds-table.d.ts +2 -1
- package/dist/react/ds-table.js +2 -1
- package/dist/styles/table.css +22 -1
- package/dist/types/components/ButtonUnfilled/ButtonUnfilled.d.ts +4 -2
- package/dist/types/components/Menu/Menu.d.ts +18 -1
- package/dist/types/components/Menu/menu-reorder.d.ts +21 -0
- package/dist/types/components/Menu/menu-types.d.ts +12 -0
- package/dist/types/components/Table/Table.d.ts +28 -1
- package/dist/types/components/Table/index.d.ts +1 -1
- package/dist/types/components/Table/table-column-customizer.d.ts +33 -0
- package/dist/types/components/Table/table-types.d.ts +5 -0
- package/dist/types/components.d.ts +44 -6
- package/package.json +1 -1
- package/dist/components/p-3r4TfcZX.js +0 -2
- package/dist/components/p-CRi7P5gQ.js +0 -2
- package/dist/components/p-CRi7P5gQ.js.map +0 -1
- package/dist/components/p-CTTDiW33.js.map +0 -1
- /package/dist/components/{p-BGQUiJuJ.js.map → p--VFa9x3k.js.map} +0 -0
- /package/dist/components/{p-C7-ylLcB.js.map → p-B5um-ps9.js.map} +0 -0
- /package/dist/components/{p-K_vg9Eng.js.map → p-BAebDW3a.js.map} +0 -0
- /package/dist/components/{p-DL12lNtv.js.map → p-BmqfTAXM.js.map} +0 -0
- /package/dist/components/{p-CDEME0Uc.js.map → p-C-L4InQ0.js.map} +0 -0
- /package/dist/components/{p-BykcjUd6.js.map → p-C1jsgfeh.js.map} +0 -0
- /package/dist/components/{p-BFDKKBYh.js.map → p-CoQSB3tl.js.map} +0 -0
- /package/dist/components/{p-DJ-n-gyr.js.map → p-CvwtYbmh.js.map} +0 -0
- /package/dist/components/{p-os90t2-f.js.map → p-D5VglrfF.js.map} +0 -0
- /package/dist/components/{p-BX-R5EhL.js.map → p-D5bPuNiF.js.map} +0 -0
- /package/dist/components/{p-CCpJcSTE.js.map → p-DOC4RaAy.js.map} +0 -0
- /package/dist/components/{p-C5230yJY.js.map → p-DQUxg6Si.js.map} +0 -0
- /package/dist/components/{p-DTf90AyI.js.map → p-bQm3gfr1.js.map} +0 -0
package/dist/react/ds-menu.d.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Changes to this file may cause incorrect behavior and will be lost if the code is regenerated.
|
|
4
4
|
*/
|
|
5
5
|
import type { EventName, StencilReactComponent } from './react-runtime.js';
|
|
6
|
-
import { type DsMenuCustomEvent, type MenuItemData } from "@ds-mo/ui";
|
|
6
|
+
import { type DsMenuCustomEvent, type MenuItemData, type MenuReorderDetail } from "@ds-mo/ui";
|
|
7
7
|
import type { Components } from "@ds-mo/ui/dist/components";
|
|
8
8
|
import { DsMenu as DsMenuElement } from "@ds-mo/ui/dist/components/ds-menu.js";
|
|
9
9
|
export type DsMenuEvents = {
|
|
@@ -11,5 +11,6 @@ export type DsMenuEvents = {
|
|
|
11
11
|
onDsAfterClose: EventName<DsMenuCustomEvent<void>>;
|
|
12
12
|
onDsSelect: EventName<DsMenuCustomEvent<MenuItemData>>;
|
|
13
13
|
onDsSwatchSelect: EventName<DsMenuCustomEvent<string>>;
|
|
14
|
+
onDsReorder: EventName<DsMenuCustomEvent<MenuReorderDetail>>;
|
|
14
15
|
};
|
|
15
16
|
export declare const DsMenu: StencilReactComponent<DsMenuElement, DsMenuEvents, Components.DsMenu>;
|
package/dist/react/ds-menu.js
CHANGED
|
@@ -11,7 +11,8 @@ export const DsMenu = /*@__PURE__*/ createComponent({
|
|
|
11
11
|
onDsClose: 'dsClose',
|
|
12
12
|
onDsAfterClose: 'dsAfterClose',
|
|
13
13
|
onDsSelect: 'dsSelect',
|
|
14
|
-
onDsSwatchSelect: 'dsSwatchSelect'
|
|
14
|
+
onDsSwatchSelect: 'dsSwatchSelect',
|
|
15
|
+
onDsReorder: 'dsReorder'
|
|
15
16
|
},
|
|
16
17
|
defineCustomElement: defineDsMenu
|
|
17
18
|
});
|
package/dist/react/ds-table.d.ts
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Changes to this file may cause incorrect behavior and will be lost if the code is regenerated.
|
|
4
4
|
*/
|
|
5
5
|
import type { EventName, StencilReactComponent } from './react-runtime.js';
|
|
6
|
-
import { type DsTableCustomEvent, type PaginationChangeDetail, type TableCellActionDetail, type TableGroupCollapseChangeDetail, type TableGroupLoadMoreDetail, type TableLoadMoreDetail, type TableRowActivateDetail, type TableSelectionChangeDetail, type TableSortChangeDetail } from "@ds-mo/ui";
|
|
6
|
+
import { type DsTableCustomEvent, type PaginationChangeDetail, type TableCellActionDetail, type TableColumnsConfigChangeDetail, type TableGroupCollapseChangeDetail, type TableGroupLoadMoreDetail, type TableLoadMoreDetail, type TableRowActivateDetail, type TableSelectionChangeDetail, type TableSortChangeDetail } from "@ds-mo/ui";
|
|
7
7
|
import type { Components } from "@ds-mo/ui/dist/components";
|
|
8
8
|
import { DsTable as DsTableElement } from "@ds-mo/ui/dist/components/ds-table.js";
|
|
9
9
|
export type DsTableEvents = {
|
|
@@ -15,5 +15,6 @@ export type DsTableEvents = {
|
|
|
15
15
|
onDsPaginationChange: EventName<DsTableCustomEvent<PaginationChangeDetail>>;
|
|
16
16
|
onDsCellAction: EventName<DsTableCustomEvent<TableCellActionDetail>>;
|
|
17
17
|
onDsRowActivate: EventName<DsTableCustomEvent<TableRowActivateDetail>>;
|
|
18
|
+
onDsColumnsConfigChange: EventName<DsTableCustomEvent<TableColumnsConfigChangeDetail>>;
|
|
18
19
|
};
|
|
19
20
|
export declare const DsTable: StencilReactComponent<DsTableElement, DsTableEvents, Components.DsTable, 'caption'>;
|
package/dist/react/ds-table.js
CHANGED
|
@@ -15,7 +15,8 @@ export const DsTable = /*@__PURE__*/ createComponent({
|
|
|
15
15
|
onDsGroupLoadMore: 'dsGroupLoadMore',
|
|
16
16
|
onDsPaginationChange: 'dsPaginationChange',
|
|
17
17
|
onDsCellAction: 'dsCellAction',
|
|
18
|
-
onDsRowActivate: 'dsRowActivate'
|
|
18
|
+
onDsRowActivate: 'dsRowActivate',
|
|
19
|
+
onDsColumnsConfigChange: 'dsColumnsConfigChange'
|
|
19
20
|
},
|
|
20
21
|
defineCustomElement: defineDsTable
|
|
21
22
|
});
|
package/dist/styles/table.css
CHANGED
|
@@ -285,7 +285,28 @@
|
|
|
285
285
|
max-inline-size: 100%;
|
|
286
286
|
}
|
|
287
287
|
|
|
288
|
-
:where(.ds-table__caption-content
|
|
288
|
+
:where(.ds-table__caption-content--trailing) {
|
|
289
|
+
grid-template-columns: minmax(0, 1fr) auto;
|
|
290
|
+
column-gap: var(--dimension-space-100);
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
:where(.ds-table__caption-trailing) {
|
|
294
|
+
display: flex;
|
|
295
|
+
align-items: center;
|
|
296
|
+
flex: 0 0 auto;
|
|
297
|
+
min-inline-size: 0;
|
|
298
|
+
gap: var(--dimension-space-100);
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
:where(.ds-table__caption-leading) {
|
|
302
|
+
display: grid;
|
|
303
|
+
grid-template-columns: minmax(0, 1fr);
|
|
304
|
+
align-items: center;
|
|
305
|
+
min-inline-size: 0;
|
|
306
|
+
max-inline-size: 100%;
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
:where(.ds-table__caption-leading > slot) {
|
|
289
310
|
display: contents;
|
|
290
311
|
}
|
|
291
312
|
|
|
@@ -76,8 +76,10 @@ export declare class ButtonUnfilled {
|
|
|
76
76
|
*
|
|
77
77
|
* - `label` / `icon-label` — the action *has* a menu; a trailing chevron carries
|
|
78
78
|
* the affordance.
|
|
79
|
-
* - `icon` — the button *is* a menu,
|
|
80
|
-
*
|
|
79
|
+
* - `icon` — the button *is* a menu. No chevron is added, so the glyph must
|
|
80
|
+
* convey the menu on its own. Use `Ellipses` for generic more-options;
|
|
81
|
+
* use a specific icon when the menu has a named purpose, such as
|
|
82
|
+
* `Preferences` for Customize table.
|
|
81
83
|
*
|
|
82
84
|
* Use `haspopup` directly for non-menu popups.
|
|
83
85
|
*/
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { EventEmitter } from '../../stencil-public-runtime';
|
|
2
2
|
import { type ChoicePopupAnchorAlignment, type ControlSize } from '../../utils';
|
|
3
3
|
import type { MenuAlign, MenuSide } from './menu-position';
|
|
4
|
-
import { type MenuItemData, type MenuSection } from './menu-types';
|
|
4
|
+
import { type MenuItemData, type MenuReorderDetail, type MenuSection } from './menu-types';
|
|
5
5
|
export type MenuSelectionMode = 'none' | 'single';
|
|
6
6
|
export type MenuSize = ControlSize;
|
|
7
7
|
export declare class Menu {
|
|
@@ -38,15 +38,22 @@ export declare class Menu {
|
|
|
38
38
|
private focusedIndex;
|
|
39
39
|
private positionReady;
|
|
40
40
|
private focusRingVisible;
|
|
41
|
+
private reorderFromFlat;
|
|
42
|
+
private reorderInsertBefore;
|
|
43
|
+
private reorderAnnouncement;
|
|
41
44
|
dsClose: EventEmitter<void>;
|
|
42
45
|
/** Emitted after the popup's exit motion is complete and its rendered content is removed. */
|
|
43
46
|
dsAfterClose: EventEmitter<void>;
|
|
44
47
|
dsSelect: EventEmitter<MenuItemData>;
|
|
45
48
|
/** Emitted when a generic `swatch-picker` section option is chosen. */
|
|
46
49
|
dsSwatchSelect: EventEmitter<string>;
|
|
50
|
+
/** Emitted after a pointer drop or keyboard move; Menu never mutates item order. */
|
|
51
|
+
dsReorder: EventEmitter<MenuReorderDetail>;
|
|
47
52
|
private clickOutsideHandler;
|
|
48
53
|
private closeTimer;
|
|
49
54
|
private positionReadyCallback;
|
|
55
|
+
private suppressItemClick;
|
|
56
|
+
private reorderPointer;
|
|
50
57
|
/**
|
|
51
58
|
* Anchored placement. The choice-cell measurement stays here on purpose: the
|
|
52
59
|
* inner-cell align offset and the `--dimension-menu-width-xs` floor are Menu
|
|
@@ -95,6 +102,16 @@ export declare class Menu {
|
|
|
95
102
|
private focusItem;
|
|
96
103
|
private handleItemClick;
|
|
97
104
|
private handleSwatchSelect;
|
|
105
|
+
private handleReorderKey;
|
|
106
|
+
private emitReorder;
|
|
107
|
+
private flatIndexFor;
|
|
108
|
+
private announceReorder;
|
|
109
|
+
private onReorderPointerDown;
|
|
110
|
+
private onReorderPointerMove;
|
|
111
|
+
private onReorderPointerUp;
|
|
112
|
+
private onReorderPointerCancel;
|
|
113
|
+
private resolveReorderInsertBefore;
|
|
114
|
+
private clearReorderPointer;
|
|
98
115
|
render(): any;
|
|
99
116
|
}
|
|
100
117
|
//# sourceMappingURL=Menu.d.ts.map
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { type MenuItemData, type MenuReorderDetail, type MenuSection } from './menu-types';
|
|
2
|
+
export interface MenuReorderRange {
|
|
3
|
+
start: number;
|
|
4
|
+
end: number;
|
|
5
|
+
}
|
|
6
|
+
/** Contiguous reorderable run containing `index`, or null when that row cannot move. */
|
|
7
|
+
export declare function menuReorderableRange(items: readonly MenuItemData[], index: number): MenuReorderRange | null;
|
|
8
|
+
/**
|
|
9
|
+
* Move a reorderable row so it would be inserted before `insertBefore`.
|
|
10
|
+
* `insertBefore` is clamped to the contiguous reorderable run.
|
|
11
|
+
*/
|
|
12
|
+
export declare function moveReorderableMenuItemBefore(items: readonly MenuItemData[], fromIndex: number, insertBefore: number): MenuItemData[] | null;
|
|
13
|
+
/** Keyboard step: move one slot within the reorderable run. */
|
|
14
|
+
export declare function moveReorderableMenuItemBy(items: readonly MenuItemData[], fromIndex: number, offset: number): MenuItemData[] | null;
|
|
15
|
+
export declare function locateMenuItem(sections: readonly MenuSection[], flatIndex: number): {
|
|
16
|
+
sectionIndex: number;
|
|
17
|
+
itemIndex: number;
|
|
18
|
+
items: MenuItemData[];
|
|
19
|
+
} | null;
|
|
20
|
+
export declare function createMenuReorderDetail(items: MenuItemData[], fromIndex: number, nextItems: MenuItemData[], sectionIndex: number): MenuReorderDetail | null;
|
|
21
|
+
//# sourceMappingURL=menu-reorder.d.ts.map
|
|
@@ -12,6 +12,8 @@ export interface MenuItemData {
|
|
|
12
12
|
label: string;
|
|
13
13
|
value?: string;
|
|
14
14
|
subtext?: string;
|
|
15
|
+
/** Leading decorative icon. Ignored when `reorderable` is true. */
|
|
16
|
+
icon?: string;
|
|
15
17
|
/** Show a supplemental brand notification dot. */
|
|
16
18
|
dot?: boolean;
|
|
17
19
|
/** Show a non-interactive tag at the trailing edge of the row. */
|
|
@@ -22,6 +24,16 @@ export interface MenuItemData {
|
|
|
22
24
|
/** Render a compact switch indicator; the menu row owns interaction. */
|
|
23
25
|
showSwitch?: boolean;
|
|
24
26
|
switchValue?: boolean;
|
|
27
|
+
/** Prefix a drag handle and allow pointer and keyboard reorder within the contiguous reorderable run. */
|
|
28
|
+
reorderable?: boolean;
|
|
29
|
+
}
|
|
30
|
+
/** Next section item order after a pointer or keyboard reorder. */
|
|
31
|
+
export interface MenuReorderDetail {
|
|
32
|
+
item: MenuItemData;
|
|
33
|
+
fromIndex: number;
|
|
34
|
+
toIndex: number;
|
|
35
|
+
sectionIndex: number;
|
|
36
|
+
items: MenuItemData[];
|
|
25
37
|
}
|
|
26
38
|
export interface MenuItemsSection {
|
|
27
39
|
header?: string;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { EventEmitter } from '../../stencil-public-runtime';
|
|
2
2
|
import type { PaginationChangeDetail } from '../Pagination/pagination-types';
|
|
3
|
-
import type { TableCaptionVisibility, TableCellActionDetail, TableColumn, TableDataMode, TableGroup, TableGroupCollapseChangeDetail, TableGroupLoadMoreDetail, TableGroupingState, TableLoadMoreDetail, TableLoadMoreMode, TablePaginationState, TableRow, TableRowActivateDetail, TableSelectionChangeDetail, TableSelectionMode, TableSortChangeDetail, TableSortState } from './table-types';
|
|
3
|
+
import type { TableCaptionVisibility, TableCellActionDetail, TableColumn, TableColumnsConfigChangeDetail, TableDataMode, TableGroup, TableGroupCollapseChangeDetail, TableGroupLoadMoreDetail, TableGroupingState, TableLoadMoreDetail, TableLoadMoreMode, TablePaginationState, TableRow, TableRowActivateDetail, TableSelectionChangeDetail, TableSelectionMode, TableSortChangeDetail, TableSortState } from './table-types';
|
|
4
4
|
export declare class Table {
|
|
5
5
|
el: HTMLElement;
|
|
6
6
|
/** Stable column definitions. Assign through JavaScript. */
|
|
@@ -19,6 +19,16 @@ export declare class Table {
|
|
|
19
19
|
caption: string;
|
|
20
20
|
/** Shows a matching presentational title bar above the native table frame. */
|
|
21
21
|
captionVisibility: TableCaptionVisibility;
|
|
22
|
+
/**
|
|
23
|
+
* Opt in to the table-owned column customizer. The `columns` prop remains the
|
|
24
|
+
* catalog; hidden and ordered columns are controlled separately. The trigger
|
|
25
|
+
* opens the shared Menu of live show/hide switch rows.
|
|
26
|
+
*/
|
|
27
|
+
columnCustomizer: boolean;
|
|
28
|
+
/** Controlled hidden data-column identities. Action ids are ignored. */
|
|
29
|
+
hiddenColumnIds: string[];
|
|
30
|
+
/** Controlled data-column identities in display order. Omitted ids append in catalog order. */
|
|
31
|
+
columnOrder: string[];
|
|
22
32
|
/**
|
|
23
33
|
* Optional result summary footer. When both `displayedCount` and `totalCount`
|
|
24
34
|
* are finite numbers, the table shows “Displaying {displayed} of {total}”.
|
|
@@ -91,6 +101,7 @@ export declare class Table {
|
|
|
91
101
|
dsPaginationChange: EventEmitter<PaginationChangeDetail>;
|
|
92
102
|
dsCellAction: EventEmitter<TableCellActionDetail>;
|
|
93
103
|
dsRowActivate: EventEmitter<TableRowActivateDetail>;
|
|
104
|
+
dsColumnsConfigChange: EventEmitter<TableColumnsConfigChangeDetail>;
|
|
94
105
|
private overflowStart;
|
|
95
106
|
private overflowEnd;
|
|
96
107
|
private scrollable;
|
|
@@ -102,7 +113,10 @@ export declare class Table {
|
|
|
102
113
|
private actionMenu;
|
|
103
114
|
private actionMenuInitialFocusVisible;
|
|
104
115
|
private truncateTooltipLabel;
|
|
116
|
+
private columnCustomizerOpen;
|
|
117
|
+
private columnCustomizerInitialFocusVisible;
|
|
105
118
|
private readonly actionMenuElementId;
|
|
119
|
+
private readonly columnCustomizerElementId;
|
|
106
120
|
private truncateTooltipEl?;
|
|
107
121
|
private truncateAnchor;
|
|
108
122
|
private truncateTooltipBound;
|
|
@@ -149,9 +163,13 @@ export declare class Table {
|
|
|
149
163
|
handleLoadingMoreChange(loading: boolean): void;
|
|
150
164
|
handleLoadMoreErrorChange(error: string | undefined): void;
|
|
151
165
|
handleHasMoreChange(hasMore: boolean, hadMore: boolean): void;
|
|
166
|
+
handleColumnCustomizerAvailability(): void;
|
|
152
167
|
private get grouped();
|
|
153
168
|
private get hasIncrementalState();
|
|
154
169
|
private get selectable();
|
|
170
|
+
private get visibleColumns();
|
|
171
|
+
private get showsColumnCustomizer();
|
|
172
|
+
private get showsCaptionTrailing();
|
|
155
173
|
private get documentStickyHeader();
|
|
156
174
|
private get fixedHeight();
|
|
157
175
|
private get boundedComposition();
|
|
@@ -217,6 +235,15 @@ export declare class Table {
|
|
|
217
235
|
private get hasResultFooter();
|
|
218
236
|
private renderResultFooter;
|
|
219
237
|
private renderCaptionBar;
|
|
238
|
+
private renderCaptionTrailing;
|
|
239
|
+
private renderColumnCustomizerTrigger;
|
|
240
|
+
private renderColumnCustomizerMenu;
|
|
241
|
+
private toggleColumnCustomizer;
|
|
242
|
+
private openColumnCustomizer;
|
|
243
|
+
private closeColumnCustomizer;
|
|
244
|
+
private emitColumnsConfigChange;
|
|
245
|
+
private handleColumnCustomizerReorder;
|
|
246
|
+
private handleColumnCustomizerSelect;
|
|
220
247
|
render(): any;
|
|
221
248
|
}
|
|
222
249
|
//# sourceMappingURL=Table.d.ts.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export type { TableCaptionVisibility, TableCellAlign, TableCellAction, TableCellActionDetail, TableCellActionDivider, TableCellActionMenuEntry, TableCellActionMenuItem, TableCellBlank, TableCellEmpty, TableCellLinkTarget, TableCellIcon, TableCellIconText, TableCellImage, TableCellImageTracks, TableCellPrimaryText, TableCellSkeleton, TableCellText, TableCellTextRun, TableCellTextTrack, TableCellTag, TableCellTagVariant, TableCellValue, TableSkeletonWidth, TableColumn, TableColumnSticky, TableColumnWidth, TableDataMode, TableGroup, TableGroupCollapseChangeDetail, TableGroupLoadMoreDetail, TableGroupIntent, TableHeaderSegment, TableGroupingState, TableLoadMoreDetail, TableLoadMoreMode, TableLoadMoreReason, TablePaginationState, TableRow, TableRowActivateDetail, TableSelectionChangeDetail, TableSelectionMode, TableSortChangeDetail, TableSortDirection, TableSortState, } from './table-types';
|
|
1
|
+
export type { TableCaptionVisibility, TableCellAlign, TableCellAction, TableCellActionDetail, TableCellActionDivider, TableCellActionMenuEntry, TableCellActionMenuItem, TableCellBlank, TableCellEmpty, TableCellLinkTarget, TableCellIcon, TableCellIconText, TableCellImage, TableCellImageTracks, TableCellPrimaryText, TableCellSkeleton, TableCellText, TableCellTextRun, TableCellTextTrack, TableCellTag, TableCellTagVariant, TableCellValue, TableSkeletonWidth, TableColumn, TableColumnsConfigChangeDetail, TableColumnSticky, TableColumnWidth, TableDataMode, TableGroup, TableGroupCollapseChangeDetail, TableGroupLoadMoreDetail, TableGroupIntent, TableHeaderSegment, TableGroupingState, TableLoadMoreDetail, TableLoadMoreMode, TableLoadMoreReason, TablePaginationState, TableRow, TableRowActivateDetail, TableSelectionChangeDetail, TableSelectionMode, TableSortChangeDetail, TableSortDirection, TableSortState, } from './table-types';
|
|
2
2
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import type { MenuItemData } from '../Menu/menu-types';
|
|
2
|
+
import type { TableColumn } from './table-types';
|
|
3
|
+
export declare function nextTableColumnCustomizerElementId(): string;
|
|
4
|
+
export declare function isTableActionColumn(column: TableColumn): boolean;
|
|
5
|
+
export declare function tableColumnCustomizerLabel(column: TableColumn): string;
|
|
6
|
+
export declare function tableDataColumns(columns: TableColumn[]): TableColumn[];
|
|
7
|
+
/** Data-column ids in display order. Unknown, duplicate, and action ids are ignored. */
|
|
8
|
+
export declare function resolveTableColumnOrder(columns: TableColumn[], columnOrder: string[] | undefined): string[];
|
|
9
|
+
/**
|
|
10
|
+
* Hidden data-column ids. Action and unknown ids are dropped. At least one data
|
|
11
|
+
* column remains visible when the catalog has any data columns.
|
|
12
|
+
*/
|
|
13
|
+
export declare function resolveTableHiddenColumnIds(columns: TableColumn[], hiddenColumnIds: string[] | undefined): string[];
|
|
14
|
+
export declare function resolveTableVisibleColumns(columns: TableColumn[], options?: {
|
|
15
|
+
columnCustomizer?: boolean;
|
|
16
|
+
hiddenColumnIds?: string[];
|
|
17
|
+
columnOrder?: string[];
|
|
18
|
+
}): TableColumn[];
|
|
19
|
+
export declare function canToggleTableColumnHidden(columns: TableColumn[], hiddenColumnIds: string[] | undefined, columnId: string): boolean;
|
|
20
|
+
export declare function toggleTableColumnHidden(columns: TableColumn[], hiddenColumnIds: string[] | undefined, columnId: string): string[];
|
|
21
|
+
export declare function moveTableColumnOrder(order: string[], fromId: string, toId: string): string[];
|
|
22
|
+
export declare function moveTableColumnInOrder(order: string[], columnId: string, offset: number): string[];
|
|
23
|
+
export interface TableColumnCustomizerItem {
|
|
24
|
+
column: TableColumn;
|
|
25
|
+
label: string;
|
|
26
|
+
visible: boolean;
|
|
27
|
+
hideable: boolean;
|
|
28
|
+
reorderable: boolean;
|
|
29
|
+
}
|
|
30
|
+
export declare function tableColumnCustomizerItems(columns: TableColumn[], hiddenColumnIds: string[] | undefined, columnOrder: string[] | undefined): TableColumnCustomizerItem[];
|
|
31
|
+
/** Menu switch rows for the table-owned column customizer. */
|
|
32
|
+
export declare function tableColumnCustomizerMenuItems(columns: TableColumn[], hiddenColumnIds: string[] | undefined, columnOrder: string[] | undefined): MenuItemData[];
|
|
33
|
+
//# sourceMappingURL=table-column-customizer.d.ts.map
|
|
@@ -340,6 +340,11 @@ export interface TableGroupCollapseChangeDetail {
|
|
|
340
340
|
export interface TableRowActivateDetail {
|
|
341
341
|
rowId: string;
|
|
342
342
|
}
|
|
343
|
+
/** Controlled show/hide and data-column order for the table-owned customizer. */
|
|
344
|
+
export interface TableColumnsConfigChangeDetail {
|
|
345
|
+
hiddenColumnIds: string[];
|
|
346
|
+
columnOrder: string[];
|
|
347
|
+
}
|
|
343
348
|
/** Controlled top-level pagination state. Rows or groups contain only the active page. */
|
|
344
349
|
export interface TablePaginationState extends PaginationState {
|
|
345
350
|
/** Change to request one fresh fitted-capacity snapshot for the current query shape. */
|
|
@@ -35,7 +35,7 @@ import { AnchoredAlign, AnchoredSide } from "./utils/anchored-position";
|
|
|
35
35
|
import { IconColor as IconColor1, IconSize } from "./components/Icon/Icon";
|
|
36
36
|
import { InputSize, InputType, InputWidth } from "./components/Input/Input";
|
|
37
37
|
import { LoaderColor, LoaderSize } from "./components/Loader/Loader";
|
|
38
|
-
import { MenuItemData, MenuSection } from "./components/Menu/menu-types";
|
|
38
|
+
import { MenuItemData, MenuReorderDetail, MenuSection } from "./components/Menu/menu-types";
|
|
39
39
|
import { MenuSelectionMode, MenuSize } from "./components/Menu/Menu";
|
|
40
40
|
import { MenuAlign, MenuSide } from "./components/Menu/menu-position";
|
|
41
41
|
import { ChoicePopupAnchorAlignment, ControlInsetDepth as ControlInsetDepth1 } from "./utils";
|
|
@@ -64,7 +64,7 @@ import { SliderOrientation, SliderSize, SliderThumbAlignment, SliderValue } from
|
|
|
64
64
|
import { SwatchPickerOption, SwatchPickerSection } from "./components/SwatchPicker/swatch-picker-types";
|
|
65
65
|
import { SwitchSize } from "./components/Switch/Switch";
|
|
66
66
|
import { TabBackground, TabGroupSize as TabGroupSize1, TabGroupWidth } from "./components/TabGroup/TabGroup";
|
|
67
|
-
import { TableCaptionVisibility, TableCellActionDetail, TableColumn, TableDataMode, TableGroup, TableGroupCollapseChangeDetail, TableGroupingState, TableGroupLoadMoreDetail, TableLoadMoreDetail, TableLoadMoreMode, TablePaginationState, TableRow, TableRowActivateDetail, TableSelectionChangeDetail, TableSelectionMode, TableSortChangeDetail, TableSortState } from "./components/Table/table-types";
|
|
67
|
+
import { TableCaptionVisibility, TableCellActionDetail, TableColumn, TableColumnsConfigChangeDetail, TableDataMode, TableGroup, TableGroupCollapseChangeDetail, TableGroupingState, TableGroupLoadMoreDetail, TableLoadMoreDetail, TableLoadMoreMode, TablePaginationState, TableRow, TableRowActivateDetail, TableSelectionChangeDetail, TableSelectionMode, TableSortChangeDetail, TableSortState } from "./components/Table/table-types";
|
|
68
68
|
import { TagContrast, TagIntent, TagSize } from "./components/Tag/Tag";
|
|
69
69
|
import { ToastActionEventDetail, ToastCloseEventDetail, ToastEventDetail, ToastManager, ToastSwipeDirection } from "./toast";
|
|
70
70
|
import { TooltipAlign, TooltipSide, TooltipSize } from "./components/Tooltip/Tooltip";
|
|
@@ -99,7 +99,7 @@ export { AnchoredAlign, AnchoredSide } from "./utils/anchored-position";
|
|
|
99
99
|
export { IconColor as IconColor1, IconSize } from "./components/Icon/Icon";
|
|
100
100
|
export { InputSize, InputType, InputWidth } from "./components/Input/Input";
|
|
101
101
|
export { LoaderColor, LoaderSize } from "./components/Loader/Loader";
|
|
102
|
-
export { MenuItemData, MenuSection } from "./components/Menu/menu-types";
|
|
102
|
+
export { MenuItemData, MenuReorderDetail, MenuSection } from "./components/Menu/menu-types";
|
|
103
103
|
export { MenuSelectionMode, MenuSize } from "./components/Menu/Menu";
|
|
104
104
|
export { MenuAlign, MenuSide } from "./components/Menu/menu-position";
|
|
105
105
|
export { ChoicePopupAnchorAlignment, ControlInsetDepth as ControlInsetDepth1 } from "./utils";
|
|
@@ -128,7 +128,7 @@ export { SliderOrientation, SliderSize, SliderThumbAlignment, SliderValue } from
|
|
|
128
128
|
export { SwatchPickerOption, SwatchPickerSection } from "./components/SwatchPicker/swatch-picker-types";
|
|
129
129
|
export { SwitchSize } from "./components/Switch/Switch";
|
|
130
130
|
export { TabBackground, TabGroupSize as TabGroupSize1, TabGroupWidth } from "./components/TabGroup/TabGroup";
|
|
131
|
-
export { TableCaptionVisibility, TableCellActionDetail, TableColumn, TableDataMode, TableGroup, TableGroupCollapseChangeDetail, TableGroupingState, TableGroupLoadMoreDetail, TableLoadMoreDetail, TableLoadMoreMode, TablePaginationState, TableRow, TableRowActivateDetail, TableSelectionChangeDetail, TableSelectionMode, TableSortChangeDetail, TableSortState } from "./components/Table/table-types";
|
|
131
|
+
export { TableCaptionVisibility, TableCellActionDetail, TableColumn, TableColumnsConfigChangeDetail, TableDataMode, TableGroup, TableGroupCollapseChangeDetail, TableGroupingState, TableGroupLoadMoreDetail, TableLoadMoreDetail, TableLoadMoreMode, TablePaginationState, TableRow, TableRowActivateDetail, TableSelectionChangeDetail, TableSelectionMode, TableSortChangeDetail, TableSortState } from "./components/Table/table-types";
|
|
132
132
|
export { TagContrast, TagIntent, TagSize } from "./components/Tag/Tag";
|
|
133
133
|
export { ToastActionEventDetail, ToastCloseEventDetail, ToastEventDetail, ToastManager, ToastSwipeDirection } from "./toast";
|
|
134
134
|
export { TooltipAlign, TooltipSide, TooltipSize } from "./components/Tooltip/Tooltip";
|
|
@@ -690,7 +690,7 @@ export namespace Components {
|
|
|
690
690
|
*/
|
|
691
691
|
"hasBorder": boolean;
|
|
692
692
|
/**
|
|
693
|
-
* Mark the button as a Menu trigger. Implies `aria-haspopup="menu"` and covers both menu-button shapes: - `label` / `icon-label` — the action *has* a menu; a trailing chevron carries the affordance. - `icon` — the button *is* a menu
|
|
693
|
+
* Mark the button as a Menu trigger. Implies `aria-haspopup="menu"` and covers both menu-button shapes: - `label` / `icon-label` — the action *has* a menu; a trailing chevron carries the affordance. - `icon` — the button *is* a menu. No chevron is added, so the glyph must convey the menu on its own. Use `Ellipses` for generic more-options; use a specific icon when the menu has a named purpose, such as `Preferences` for Customize table. Use `haspopup` directly for non-menu popups.
|
|
694
694
|
* @default false
|
|
695
695
|
*/
|
|
696
696
|
"hasMenu": boolean;
|
|
@@ -2859,6 +2859,16 @@ export namespace Components {
|
|
|
2859
2859
|
* @default []
|
|
2860
2860
|
*/
|
|
2861
2861
|
"collapsedGroupIds": string[];
|
|
2862
|
+
/**
|
|
2863
|
+
* Opt in to the table-owned column customizer. The `columns` prop remains the catalog; hidden and ordered columns are controlled separately. The trigger opens the shared Menu of live show/hide switch rows.
|
|
2864
|
+
* @default false
|
|
2865
|
+
*/
|
|
2866
|
+
"columnCustomizer": boolean;
|
|
2867
|
+
/**
|
|
2868
|
+
* Controlled data-column identities in display order. Omitted ids append in catalog order.
|
|
2869
|
+
* @default []
|
|
2870
|
+
*/
|
|
2871
|
+
"columnOrder": string[];
|
|
2862
2872
|
/**
|
|
2863
2873
|
* Stable column definitions. Assign through JavaScript.
|
|
2864
2874
|
* @default []
|
|
@@ -2954,6 +2964,11 @@ export namespace Components {
|
|
|
2954
2964
|
* Fixed height for the complete header, table frame, and footer composition.
|
|
2955
2965
|
*/
|
|
2956
2966
|
"height": string | number | undefined;
|
|
2967
|
+
/**
|
|
2968
|
+
* Controlled hidden data-column identities. Action ids are ignored.
|
|
2969
|
+
* @default []
|
|
2970
|
+
*/
|
|
2971
|
+
"hiddenColumnIds": string[];
|
|
2957
2972
|
/**
|
|
2958
2973
|
* Reset key for a new query/group/sort dataset.
|
|
2959
2974
|
* @default 'default'
|
|
@@ -3982,6 +3997,7 @@ declare global {
|
|
|
3982
3997
|
"dsAfterClose": void;
|
|
3983
3998
|
"dsSelect": MenuItemData;
|
|
3984
3999
|
"dsSwatchSelect": string;
|
|
4000
|
+
"dsReorder": MenuReorderDetail;
|
|
3985
4001
|
}
|
|
3986
4002
|
interface HTMLDsMenuElement extends Components.DsMenu, HTMLStencilElement {
|
|
3987
4003
|
addEventListener<K extends keyof HTMLDsMenuElementEventMap>(type: K, listener: (this: HTMLDsMenuElement, ev: DsMenuCustomEvent<HTMLDsMenuElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
|
|
@@ -4484,6 +4500,7 @@ declare global {
|
|
|
4484
4500
|
"dsPaginationChange": PaginationChangeDetail;
|
|
4485
4501
|
"dsCellAction": TableCellActionDetail;
|
|
4486
4502
|
"dsRowActivate": TableRowActivateDetail;
|
|
4503
|
+
"dsColumnsConfigChange": TableColumnsConfigChangeDetail;
|
|
4487
4504
|
}
|
|
4488
4505
|
interface HTMLDsTableElement extends Components.DsTable, HTMLStencilElement {
|
|
4489
4506
|
addEventListener<K extends keyof HTMLDsTableElementEventMap>(type: K, listener: (this: HTMLDsTableElement, ev: DsTableCustomEvent<HTMLDsTableElementEventMap[K]>) => any, options?: boolean | AddEventListenerOptions): void;
|
|
@@ -5262,7 +5279,7 @@ declare namespace LocalJSX {
|
|
|
5262
5279
|
*/
|
|
5263
5280
|
"hasBorder"?: boolean;
|
|
5264
5281
|
/**
|
|
5265
|
-
* Mark the button as a Menu trigger. Implies `aria-haspopup="menu"` and covers both menu-button shapes: - `label` / `icon-label` — the action *has* a menu; a trailing chevron carries the affordance. - `icon` — the button *is* a menu
|
|
5282
|
+
* Mark the button as a Menu trigger. Implies `aria-haspopup="menu"` and covers both menu-button shapes: - `label` / `icon-label` — the action *has* a menu; a trailing chevron carries the affordance. - `icon` — the button *is* a menu. No chevron is added, so the glyph must convey the menu on its own. Use `Ellipses` for generic more-options; use a specific icon when the menu has a named purpose, such as `Preferences` for Customize table. Use `haspopup` directly for non-menu popups.
|
|
5266
5283
|
* @default false
|
|
5267
5284
|
*/
|
|
5268
5285
|
"hasMenu"?: boolean;
|
|
@@ -6105,6 +6122,10 @@ declare namespace LocalJSX {
|
|
|
6105
6122
|
*/
|
|
6106
6123
|
"onDsAfterClose"?: (event: DsMenuCustomEvent<void>) => void;
|
|
6107
6124
|
"onDsClose"?: (event: DsMenuCustomEvent<void>) => void;
|
|
6125
|
+
/**
|
|
6126
|
+
* Emitted after a pointer drop or keyboard move; Menu never mutates item order.
|
|
6127
|
+
*/
|
|
6128
|
+
"onDsReorder"?: (event: DsMenuCustomEvent<MenuReorderDetail>) => void;
|
|
6108
6129
|
"onDsSelect"?: (event: DsMenuCustomEvent<MenuItemData>) => void;
|
|
6109
6130
|
/**
|
|
6110
6131
|
* Emitted when a generic `swatch-picker` section option is chosen.
|
|
@@ -7645,6 +7666,16 @@ declare namespace LocalJSX {
|
|
|
7645
7666
|
* @default []
|
|
7646
7667
|
*/
|
|
7647
7668
|
"collapsedGroupIds"?: string[];
|
|
7669
|
+
/**
|
|
7670
|
+
* Opt in to the table-owned column customizer. The `columns` prop remains the catalog; hidden and ordered columns are controlled separately. The trigger opens the shared Menu of live show/hide switch rows.
|
|
7671
|
+
* @default false
|
|
7672
|
+
*/
|
|
7673
|
+
"columnCustomizer"?: boolean;
|
|
7674
|
+
/**
|
|
7675
|
+
* Controlled data-column identities in display order. Omitted ids append in catalog order.
|
|
7676
|
+
* @default []
|
|
7677
|
+
*/
|
|
7678
|
+
"columnOrder"?: string[];
|
|
7648
7679
|
/**
|
|
7649
7680
|
* Stable column definitions. Assign through JavaScript.
|
|
7650
7681
|
* @default []
|
|
@@ -7740,6 +7771,11 @@ declare namespace LocalJSX {
|
|
|
7740
7771
|
* Fixed height for the complete header, table frame, and footer composition.
|
|
7741
7772
|
*/
|
|
7742
7773
|
"height"?: string | number | undefined;
|
|
7774
|
+
/**
|
|
7775
|
+
* Controlled hidden data-column identities. Action ids are ignored.
|
|
7776
|
+
* @default []
|
|
7777
|
+
*/
|
|
7778
|
+
"hiddenColumnIds"?: string[];
|
|
7743
7779
|
/**
|
|
7744
7780
|
* Reset key for a new query/group/sort dataset.
|
|
7745
7781
|
* @default 'default'
|
|
@@ -7777,6 +7813,7 @@ declare namespace LocalJSX {
|
|
|
7777
7813
|
*/
|
|
7778
7814
|
"maxHeight"?: string | number | undefined;
|
|
7779
7815
|
"onDsCellAction"?: (event: DsTableCustomEvent<TableCellActionDetail>) => void;
|
|
7816
|
+
"onDsColumnsConfigChange"?: (event: DsTableCustomEvent<TableColumnsConfigChangeDetail>) => void;
|
|
7780
7817
|
"onDsGroupCollapseChange"?: (event: DsTableCustomEvent<TableGroupCollapseChangeDetail>) => void;
|
|
7781
7818
|
"onDsGroupLoadMore"?: (event: DsTableCustomEvent<TableGroupLoadMoreDetail>) => void;
|
|
7782
7819
|
"onDsLoadMore"?: (event: DsTableCustomEvent<TableLoadMoreDetail>) => void;
|
|
@@ -8752,6 +8789,7 @@ declare namespace LocalJSX {
|
|
|
8752
8789
|
interface DsTableAttributes {
|
|
8753
8790
|
"caption": string;
|
|
8754
8791
|
"captionVisibility": TableCaptionVisibility;
|
|
8792
|
+
"columnCustomizer": boolean;
|
|
8755
8793
|
"displayedCount": number | undefined;
|
|
8756
8794
|
"totalCount": number | undefined;
|
|
8757
8795
|
"resultSummaryLabel": string;
|