@epam/ai-dial-catalog 1.1.0-dev.49 → 1.1.0-dev.491
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/components/AppIdentity/AppIdentity.d.ts +9 -14
- package/components/AppIdentity/AppIdentity.d.ts.map +1 -1
- package/components/CardGrid/Card.d.ts.map +1 -1
- package/components/CardGrid/CardGrid.d.ts.map +1 -1
- package/components/CardGrid/CardRowRenderer.d.ts.map +1 -1
- package/components/CardTag/CardTag.d.ts +25 -0
- package/components/CardTag/CardTag.d.ts.map +1 -0
- package/components/Catalog/Catalog.d.ts.map +1 -1
- package/components/Catalog/CreateButton.d.ts +2 -2
- package/components/Catalog/CreateButton.d.ts.map +1 -1
- package/components/CredentialsBadge/CredentialsBadge.d.ts +12 -5
- package/components/CredentialsBadge/CredentialsBadge.d.ts.map +1 -1
- package/components/Details/ApiDetails.d.ts +6 -2
- package/components/Details/ApiDetails.d.ts.map +1 -1
- package/components/Details/ConfirmationView/ConfirmationFooter.d.ts +29 -0
- package/components/Details/ConfirmationView/ConfirmationFooter.d.ts.map +1 -0
- package/components/Details/ConfirmationView/ConfirmationView.d.ts +28 -0
- package/components/Details/ConfirmationView/ConfirmationView.d.ts.map +1 -0
- package/components/Details/Credentials/CredentialsBanner/CredentialsBanner.d.ts +16 -0
- package/components/Details/Credentials/CredentialsBanner/CredentialsBanner.d.ts.map +1 -0
- package/components/Details/Credentials/CredentialsIdentityIcon/CredentialsIdentityIcon.d.ts +29 -0
- package/components/Details/Credentials/CredentialsIdentityIcon/CredentialsIdentityIcon.d.ts.map +1 -0
- package/components/Details/Credentials/CredentialsInfoCard/CredentialsInfoCard.d.ts +20 -0
- package/components/Details/Credentials/CredentialsInfoCard/CredentialsInfoCard.d.ts.map +1 -0
- package/components/Details/Credentials/CredentialsManagementPanel/CredentialsManagementPanel.d.ts +31 -0
- package/components/Details/Credentials/CredentialsManagementPanel/CredentialsManagementPanel.d.ts.map +1 -0
- package/components/Details/DetailsPanel.d.ts.map +1 -1
- package/components/Details/Header/CredentialsApiKeyOverlay/CredentialsApiKeyOverlay.d.ts +34 -0
- package/components/Details/Header/CredentialsApiKeyOverlay/CredentialsApiKeyOverlay.d.ts.map +1 -0
- package/components/Details/Header/Header.d.ts +99 -19
- package/components/Details/Header/Header.d.ts.map +1 -1
- package/components/Details/Header/ShareButton/ShareButton.d.ts.map +1 -1
- package/components/Details/TabsContent/About.d.ts +3 -2
- package/components/Details/TabsContent/About.d.ts.map +1 -1
- package/components/Details/TabsContent/Content.d.ts +53 -0
- package/components/Details/TabsContent/Content.d.ts.map +1 -0
- package/components/Details/TabsContent/ContentFileTree/ContentFileTree.d.ts +28 -0
- package/components/Details/TabsContent/ContentFileTree/ContentFileTree.d.ts.map +1 -0
- package/components/Details/TabsContent/DataGrid/DataGrid.d.ts +1 -1
- package/components/Details/TabsContent/DataGrid/DataGrid.d.ts.map +1 -1
- package/components/Details/TabsContent/Limits/LimitGroupSection.d.ts +11 -0
- package/components/Details/TabsContent/Limits/LimitGroupSection.d.ts.map +1 -0
- package/components/Details/TabsContent/Limits/LimitRow.d.ts +10 -0
- package/components/Details/TabsContent/Limits/LimitRow.d.ts.map +1 -0
- package/components/Details/TabsContent/Limits/Limits.d.ts +5 -0
- package/components/Details/TabsContent/Limits/Limits.d.ts.map +1 -0
- package/components/Favorites/FavoriteCard.d.ts +9 -4
- package/components/Favorites/FavoriteCard.d.ts.map +1 -1
- package/components/Favorites/Favorites.d.ts.map +1 -1
- package/components/Filter/Filter.d.ts +35 -2
- package/components/Filter/Filter.d.ts.map +1 -1
- package/components/InfoCard/InfoCard.d.ts +15 -0
- package/components/InfoCard/InfoCard.d.ts.map +1 -0
- package/components/ListView/ListView.d.ts +1 -1
- package/components/ListView/ListView.d.ts.map +1 -1
- package/components/ListView/Renders/EntityTypeCellRenderer.d.ts.map +1 -1
- package/components/ListView/Renders/FolderCellRenderer.d.ts +4 -1
- package/components/ListView/Renders/FolderCellRenderer.d.ts.map +1 -1
- package/components/ListView/Renders/NameCellRenderer.d.ts.map +1 -1
- package/components/ListView/Renders/StarCellRenderer.d.ts.map +1 -1
- package/components/ListView/columns.d.ts +19 -2
- package/components/ListView/columns.d.ts.map +1 -1
- package/components/StarToggleButton/StarToggleButton.d.ts +2 -0
- package/components/StarToggleButton/StarToggleButton.d.ts.map +1 -1
- package/components/TableView/TableView.d.ts +20 -0
- package/components/TableView/TableView.d.ts.map +1 -1
- package/components/Toolbar/Rows/TitleRow.d.ts +8 -4
- package/components/Toolbar/Rows/TitleRow.d.ts.map +1 -1
- package/components/Toolbar/Toolbar.d.ts.map +1 -1
- package/components/TopicTag/TopicTag.d.ts +11 -0
- package/components/TopicTag/TopicTag.d.ts.map +1 -1
- package/constants/virtual-grid.d.ts +7 -2
- package/constants/virtual-grid.d.ts.map +1 -1
- package/entry-points/mapping.d.ts +16 -0
- package/entry-points/mapping.d.ts.map +1 -0
- package/index.css +1 -1
- package/index.d.ts +25 -42
- package/index.d.ts.map +1 -1
- package/index.js +3167 -28614
- package/mapping-FVCFAmAc.js +64 -0
- package/mapping.js +2 -0
- package/models/app-identity-styles.d.ts +28 -0
- package/models/app-identity-styles.d.ts.map +1 -0
- package/models/card-props.d.ts +24 -15
- package/models/card-props.d.ts.map +1 -1
- package/models/card-row-data.d.ts +8 -1
- package/models/card-row-data.d.ts.map +1 -1
- package/models/catalog-item-credentials.d.ts +4 -0
- package/models/catalog-item-credentials.d.ts.map +1 -1
- package/models/catalog-item.d.ts +3 -6
- package/models/catalog-item.d.ts.map +1 -1
- package/models/catalog-props.d.ts +214 -38
- package/models/catalog-props.d.ts.map +1 -1
- package/models/catalog-styles.d.ts +11 -35
- package/models/catalog-styles.d.ts.map +1 -1
- package/models/favorites.d.ts +24 -8
- package/models/favorites.d.ts.map +1 -1
- package/models/grid-context.d.ts +6 -1
- package/models/grid-context.d.ts.map +1 -1
- package/models/grid-props.d.ts +23 -1
- package/models/grid-props.d.ts.map +1 -1
- package/models/item-details-data.d.ts +94 -4
- package/models/item-details-data.d.ts.map +1 -1
- package/models/item-details-props.d.ts +462 -60
- package/models/item-details-props.d.ts.map +1 -1
- package/models/limits-props.d.ts +62 -0
- package/models/limits-props.d.ts.map +1 -0
- package/models/list-props.d.ts +41 -6
- package/models/list-props.d.ts.map +1 -1
- package/models/toolbar-props.d.ts +22 -22
- package/models/toolbar-props.d.ts.map +1 -1
- package/package.json +19 -9
- package/types/catalog-content-type.d.ts +13 -0
- package/types/catalog-content-type.d.ts.map +1 -0
- package/types/deployment-icon-size.d.ts +5 -0
- package/types/deployment-icon-size.d.ts.map +1 -0
- package/types/detail-tab.d.ts +4 -1
- package/types/detail-tab.d.ts.map +1 -1
- package/types/details-confirmation.d.ts +28 -0
- package/types/details-confirmation.d.ts.map +1 -0
- package/types/recipients-count.d.ts +12 -0
- package/types/recipients-count.d.ts.map +1 -0
- package/types/toolset-auth.d.ts +9 -0
- package/types/toolset-auth.d.ts.map +1 -1
- package/types/view-mode.d.ts +1 -1
- package/types/view-mode.d.ts.map +1 -1
- package/utils/catalog-content-tree.d.ts +8 -0
- package/utils/catalog-content-tree.d.ts.map +1 -0
- package/utils/catalog-filter.d.ts +9 -1
- package/utils/catalog-filter.d.ts.map +1 -1
- package/utils/catalog-tabs.d.ts +2 -2
- package/utils/catalog-tabs.d.ts.map +1 -1
- package/utils/scroll-window.d.ts +19 -0
- package/utils/scroll-window.d.ts.map +1 -0
- package/utils/styles.d.ts +0 -3
- package/utils/styles.d.ts.map +1 -1
- package/utils/toolset-credentials.d.ts +3 -1
- package/utils/toolset-credentials.d.ts.map +1 -1
- package/utils/usage-limits.d.ts +12 -0
- package/utils/usage-limits.d.ts.map +1 -0
- package/utils/use-scroll-virtualizer.d.ts +16 -2
- package/utils/use-scroll-virtualizer.d.ts.map +1 -1
- package/components/Details/Credentials/CredentialsSection.d.ts +0 -21
- package/components/Details/Credentials/CredentialsSection.d.ts.map +0 -1
- package/components/Details/Header/ConnectButton/ConnectButton.d.ts +0 -25
- package/components/Details/Header/ConnectButton/ConnectButton.d.ts.map +0 -1
- package/components/Details/Header/DeleteButton/DeleteButton.d.ts +0 -25
- package/components/Details/Header/DeleteButton/DeleteButton.d.ts.map +0 -1
- package/components/Details/Summary/Limits.d.ts +0 -18
- package/components/Details/Summary/Limits.d.ts.map +0 -1
- package/components/Details/Summary/Summary.d.ts +0 -12
- package/components/Details/Summary/Summary.d.ts.map +0 -1
- package/components/Details/TabsContent/Limits.d.ts +0 -14
- package/components/Details/TabsContent/Limits.d.ts.map +0 -1
- package/components/EntityHeader/EntityHeader.d.ts +0 -32
- package/components/EntityHeader/EntityHeader.d.ts.map +0 -1
- package/components/EntityTypeLabel/EntityTypeLabel.d.ts +0 -16
- package/components/EntityTypeLabel/EntityTypeLabel.d.ts.map +0 -1
- package/components/FeaturedChip/FeaturedChip.d.ts +0 -11
- package/components/FeaturedChip/FeaturedChip.d.ts.map +0 -1
- package/components/FolderPath/FolderPath.d.ts +0 -22
- package/components/FolderPath/FolderPath.d.ts.map +0 -1
- package/components/ItemHeader/ItemHeader.d.ts +0 -15
- package/components/ItemHeader/ItemHeader.d.ts.map +0 -1
- package/components/PublishFoldersTree/PublishFoldersTree.d.ts +0 -63
- package/components/PublishFoldersTree/PublishFoldersTree.d.ts.map +0 -1
- package/components/PublishHistoryList/PublishHistoryList.d.ts +0 -35
- package/components/PublishHistoryList/PublishHistoryList.d.ts.map +0 -1
- package/components/PublishPanel/PublishFooter.d.ts +0 -32
- package/components/PublishPanel/PublishFooter.d.ts.map +0 -1
- package/components/PublishPanel/PublishPanel.d.ts +0 -104
- package/components/PublishPanel/PublishPanel.d.ts.map +0 -1
- package/components/PublishPanel/StandalonePublishPanel.d.ts +0 -71
- package/components/PublishPanel/StandalonePublishPanel.d.ts.map +0 -1
- package/components/SearchBar/SearchBar.d.ts +0 -25
- package/components/SearchBar/SearchBar.d.ts.map +0 -1
- package/constants/catalog-defaults.d.ts +0 -4
- package/constants/catalog-defaults.d.ts.map +0 -1
- package/constants/entity-colors.d.ts +0 -6
- package/constants/entity-colors.d.ts.map +0 -1
- package/models/entity-summary.d.ts +0 -23
- package/models/entity-summary.d.ts.map +0 -1
- package/models/publish.d.ts +0 -89
- package/models/publish.d.ts.map +0 -1
- package/models/sort.d.ts +0 -8
- package/models/sort.d.ts.map +0 -1
- package/types/entity-tag.d.ts +0 -9
- package/types/entity-tag.d.ts.map +0 -1
- package/types/entity-type.d.ts +0 -8
- package/types/entity-type.d.ts.map +0 -1
- package/utils/format-published-date.d.ts +0 -8
- package/utils/format-published-date.d.ts.map +0 -1
- package/utils/parse-about-content.d.ts +0 -22
- package/utils/parse-about-content.d.ts.map +0 -1
- package/utils/publish-folder-tree.d.ts +0 -32
- package/utils/publish-folder-tree.d.ts.map +0 -1
- package/utils/publish-state.d.ts +0 -4
- package/utils/publish-state.d.ts.map +0 -1
- package/utils/use-publish-flow.d.ts +0 -71
- package/utils/use-publish-flow.d.ts.map +0 -1
|
@@ -1,31 +1,15 @@
|
|
|
1
|
+
import { CatalogEntityType } from '@epam/ai-dial-chat-shared';
|
|
2
|
+
import { PublicationRule, PublishFolderNode, PublishFooterLabels, PublishHistoryEntry, PublishPanelLabels } from '@epam/ai-dial-publish-panel';
|
|
3
|
+
import { DropdownItem, TabModel } from '@epam/ai-dial-ui-kit';
|
|
1
4
|
import { ReactNode } from 'react';
|
|
2
|
-
import {
|
|
3
|
-
import { PublishPanelTexts } from '../components/PublishPanel/PublishPanel';
|
|
4
|
-
import { CatalogEntityType } from '../types/entity-type';
|
|
5
|
+
import { ListViewColumnVisibility } from '../components/ListView/columns';
|
|
5
6
|
import { CatalogSortKey } from '../types/sort';
|
|
6
7
|
import { CredentialsLevel } from '../types/toolset-auth';
|
|
7
8
|
import { CatalogViewMode } from '../types/view-mode';
|
|
8
9
|
import { CatalogItem } from './catalog-item';
|
|
9
10
|
import { CatalogStyles } from './catalog-styles';
|
|
10
|
-
import { CatalogItemDetailsFetchResult } from './item-details-data';
|
|
11
|
+
import { CatalogContentFilePreview, CatalogItemDetailsFetchResult } from './item-details-data';
|
|
11
12
|
import { ItemDetailsTexts } from './item-details-props';
|
|
12
|
-
import { PublishFolderNode, PublishHistoryEntry } from './publish';
|
|
13
|
-
/** A single option in the Create dropdown. */
|
|
14
|
-
export interface CreateOption {
|
|
15
|
-
/** Display label shown in the dropdown menu. */
|
|
16
|
-
label: string;
|
|
17
|
-
/** Short description shown below the label (single line, truncated). */
|
|
18
|
-
description?: string;
|
|
19
|
-
/** Leading icon rendered inside a tinted 32 px square. */
|
|
20
|
-
icon?: ReactNode;
|
|
21
|
-
/**
|
|
22
|
-
* Tailwind classes applied to the icon container — controls background tint
|
|
23
|
-
* and icon colour. Example: `'bg-accent-secondary-alpha text-accent-secondary'`.
|
|
24
|
-
*/
|
|
25
|
-
iconContainerClassName?: string;
|
|
26
|
-
/** Called when this option is selected. */
|
|
27
|
-
onClick: () => void;
|
|
28
|
-
}
|
|
29
13
|
/** Text labels used by the `Catalog` surface. */
|
|
30
14
|
export interface CatalogTitles {
|
|
31
15
|
/** Page heading. Default: 'Catalog'. */
|
|
@@ -43,6 +27,8 @@ export interface CatalogTitles {
|
|
|
43
27
|
* Default: (q) => `No results for "${q}"`.
|
|
44
28
|
*/
|
|
45
29
|
noResultsTitle?: (query: string) => string;
|
|
30
|
+
/** The sort control's own name, prepended to its accessible name. Default: 'Sort'. */
|
|
31
|
+
sortLabel?: string;
|
|
46
32
|
/** Label for the "Recently Updated" sort option. Default: 'Recently Updated'. */
|
|
47
33
|
sortRecentlyUpdatedLabel?: string;
|
|
48
34
|
/** Label for the "Newest" sort option. Default: 'Newest'. */
|
|
@@ -55,12 +41,15 @@ export interface CatalogTitles {
|
|
|
55
41
|
gridViewLabel?: string;
|
|
56
42
|
/** Accessible label for switching to list view. Default: 'List view'. */
|
|
57
43
|
listViewLabel?: string;
|
|
44
|
+
/** Accessible label naming the grid/list view toggle group. Default: 'View mode'. */
|
|
45
|
+
viewToggleLabel?: string;
|
|
58
46
|
/** ARIA label for the page/grid. Default: 'Catalog'. */
|
|
59
47
|
ariaLabel?: string;
|
|
60
48
|
/**
|
|
61
49
|
* Display labels for entity-type filter tabs. Only types present in `items`
|
|
62
|
-
* are shown
|
|
63
|
-
*
|
|
50
|
+
* are shown, and the row is hidden entirely when fewer than two types are
|
|
51
|
+
* present. Defaults: Model → 'Models', Agent → 'Agents',
|
|
52
|
+
* Toolset → 'Toolsets', Skill → 'Skills', Prompt → 'Prompts'.
|
|
64
53
|
*/
|
|
65
54
|
tabLabels?: Partial<Record<CatalogEntityType, string>>;
|
|
66
55
|
/** Label for the filter button when nothing is filtered. Default: 'From'. */
|
|
@@ -72,18 +61,69 @@ export interface CatalogTitles {
|
|
|
72
61
|
}
|
|
73
62
|
/** Props for Catalog. */
|
|
74
63
|
export interface CatalogProps {
|
|
75
|
-
/**
|
|
64
|
+
/**
|
|
65
|
+
* Items to display in the Browse section's grid/list. Also drives the
|
|
66
|
+
* default entity-type tabs and Topics filter options when `tabs`/
|
|
67
|
+
* `topicOptions` are omitted.
|
|
68
|
+
*/
|
|
76
69
|
items: CatalogItem[];
|
|
70
|
+
/**
|
|
71
|
+
* Externally-controlled entity-type tab list. When omitted, `Catalog`
|
|
72
|
+
* derives tabs internally from `items` via `buildCatalogTabs`. Fewer than
|
|
73
|
+
* two tabs renders no tab row.
|
|
74
|
+
*
|
|
75
|
+
* Lets a host compute tabs from a wider item set than `items` — e.g. so a
|
|
76
|
+
* host that narrows `items` for grid display (by a category-tree
|
|
77
|
+
* selection) doesn't lose a tab for a type with zero matches in that
|
|
78
|
+
* narrowed set.
|
|
79
|
+
*/
|
|
80
|
+
tabs?: TabModel[];
|
|
81
|
+
/**
|
|
82
|
+
* Externally-controlled set of available Topics filter options. When
|
|
83
|
+
* omitted, `Catalog` derives them internally from `items` via
|
|
84
|
+
* `getTopicOptions`.
|
|
85
|
+
*
|
|
86
|
+
* Lets a host compute the option set from a wider item set than `items`,
|
|
87
|
+
* for the same reason as `tabs`.
|
|
88
|
+
*/
|
|
89
|
+
topicOptions?: Set<string>;
|
|
77
90
|
/** Items to display in the Favorites section. */
|
|
78
91
|
favorites: CatalogItem[];
|
|
79
92
|
/** Grouped text labels for headings and actions. */
|
|
80
93
|
titles?: CatalogTitles;
|
|
94
|
+
/**
|
|
95
|
+
* Renders in place of the Browse section's heading (`titles.browseTitle`)
|
|
96
|
+
* when supplied, e.g. so a host can render a clickable breadcrumb instead
|
|
97
|
+
* of a plain text label. The item count normally shown next to the heading
|
|
98
|
+
* is not rendered alongside it — include it in the supplied node if needed.
|
|
99
|
+
*/
|
|
100
|
+
browseHeaderRenderer?: ReactNode;
|
|
81
101
|
/** Whether catalog data is loading (reserved for future loading state). */
|
|
82
102
|
isLoading?: boolean;
|
|
83
103
|
/** Error to display if data loading failed (reserved for future error state). */
|
|
84
104
|
error?: Error | null;
|
|
85
105
|
/** Called when any item's star is toggled. */
|
|
86
106
|
onToggleFavorite?: (id: string, isStarred: boolean) => void;
|
|
107
|
+
/**
|
|
108
|
+
* Additional caller-supplied rule for whether the favorite star is shown for
|
|
109
|
+
* an item, in the browse grid, the list view, the favorites strip, and the
|
|
110
|
+
* details panel. Returning `false` hides the star everywhere and makes the
|
|
111
|
+
* item non-favoritable. Defaults to **visible** when omitted, so a predicate
|
|
112
|
+
* can only ever narrow visibility, never widen it.
|
|
113
|
+
*/
|
|
114
|
+
isFavoriteVisible?: (item: CatalogItem) => boolean;
|
|
115
|
+
/**
|
|
116
|
+
* Per-column overrides for whether an optional `ListView` column (`folder`,
|
|
117
|
+
* `tags`, `favorite`) renders for the active tab, given its entity type.
|
|
118
|
+
* Independent of `isFavoriteVisible` (which only gates the star on
|
|
119
|
+
* individual rows, in the browse grid and cards too, not the column).
|
|
120
|
+
* Replaces that column's built-in default rule — e.g. `folder` normally
|
|
121
|
+
* hides for `CatalogEntityType.Model`; columns omitted from this map keep
|
|
122
|
+
* their default. `favorite` is additionally combined (AND) with
|
|
123
|
+
* `isReadonly`. No effect on the Browse grid/cards, only the list view's
|
|
124
|
+
* table.
|
|
125
|
+
*/
|
|
126
|
+
columnVisibility?: ListViewColumnVisibility;
|
|
87
127
|
/** Called when the "Use in chat" button is clicked in the details panel. */
|
|
88
128
|
onUseInChat?: (item: CatalogItem) => void;
|
|
89
129
|
/** Controls whether the primary action button is shown for an item. */
|
|
@@ -92,6 +132,12 @@ export interface CatalogProps {
|
|
|
92
132
|
onShare?: (item: CatalogItem) => void;
|
|
93
133
|
/** Controls whether the "Publish" action is shown for an item. */
|
|
94
134
|
isPublishVisible?: (item: CatalogItem) => boolean;
|
|
135
|
+
/**
|
|
136
|
+
* Resolves whether whichever of "Publish"/"Unpublish" applies renders as its
|
|
137
|
+
* own button in the details header rather than an entry in its "Manage"
|
|
138
|
+
* menu. Defaults to `false` — the menu entry.
|
|
139
|
+
*/
|
|
140
|
+
isPublishPrimary?: (item: CatalogItem) => boolean;
|
|
95
141
|
/** Resolves previously published versions for an item, most recent first. */
|
|
96
142
|
getPublishHistory?: (item: CatalogItem) => Promise<PublishHistoryEntry[]>;
|
|
97
143
|
/** Root-level destination folder nodes offered by the publish flow. */
|
|
@@ -108,16 +154,70 @@ export interface CatalogProps {
|
|
|
108
154
|
publishLoadingPaths?: Set<string>;
|
|
109
155
|
/** Resolves whether the current user can publish to a given folder path. */
|
|
110
156
|
hasPublishWriteAccess?: (folderPath: string[]) => boolean;
|
|
111
|
-
/**
|
|
112
|
-
|
|
157
|
+
/**
|
|
158
|
+
* Initial value for the publish flow's display-author field, and the value
|
|
159
|
+
* it returns to on reset. Resolved by the host from the signed-in user's
|
|
160
|
+
* display name; the catalog library holds no notion of a session.
|
|
161
|
+
*/
|
|
162
|
+
publishDefaultAuthor?: string;
|
|
163
|
+
/** Called with the destination folder path, current access rules, and trimmed display author when the user confirms publish/update. */
|
|
164
|
+
onPublish?: (item: CatalogItem, folderPath: string[], rules: PublicationRule[], author: string) => Promise<void>;
|
|
113
165
|
/** Called after a successful publish; use this to surface a success notification. */
|
|
114
166
|
onPublishSuccess?: (item: CatalogItem, folderPath: string[]) => void;
|
|
167
|
+
/** Called with the rejection reason when a publish request fails; use this to surface an error notification. */
|
|
168
|
+
onPublishError?: (item: CatalogItem, folderPath: string[], error: unknown) => void;
|
|
115
169
|
/** Called when the user confirms a new folder name in the publish flow. */
|
|
116
170
|
onCreatePublishFolder?: (parentPath: string[], name: string) => void;
|
|
117
171
|
/** Text overrides forwarded to the publish flow. */
|
|
118
|
-
|
|
172
|
+
publishLabels?: PublishPanelLabels & PublishFooterLabels;
|
|
173
|
+
/** Options offered in the access-rules editor's source picker. Defaults to `[]` when absent. */
|
|
174
|
+
ruleSourceOptions?: string[];
|
|
175
|
+
/**
|
|
176
|
+
* Resolves the access rules already configured for a destination folder,
|
|
177
|
+
* called whenever the selected folder changes. The result fully replaces
|
|
178
|
+
* the rules editor's contents. Omit to skip pre-filling entirely.
|
|
179
|
+
*/
|
|
180
|
+
onFetchExistingRules?: (folderPath: string[]) => Promise<PublicationRule[]>;
|
|
119
181
|
/** Called when the "Edit" button is clicked in the details panel. Shown only when the item's `isEditable` is `true`. */
|
|
120
182
|
onEdit?: (item: CatalogItem) => void;
|
|
183
|
+
/**
|
|
184
|
+
* Called when the "Download" action is clicked in the details panel, with no
|
|
185
|
+
* confirmation step. When "Download" renders in the Manage menu (see
|
|
186
|
+
* `isDownloadPrimary`), the panel does not await the result or show a
|
|
187
|
+
* pending state, so the host owns any progress and failure feedback. When
|
|
188
|
+
* "Download" is the primary action, the panel awaits this call and shows a
|
|
189
|
+
* pending/disabled state for its duration.
|
|
190
|
+
*/
|
|
191
|
+
onDownload?: (item: CatalogItem) => Promise<void> | void;
|
|
192
|
+
/**
|
|
193
|
+
* Narrows which items offer the "Download" action. Defaults to `true`
|
|
194
|
+
* (visible for every item) whenever `onDownload` is supplied.
|
|
195
|
+
*/
|
|
196
|
+
isDownloadVisible?: (item: CatalogItem) => boolean;
|
|
197
|
+
/**
|
|
198
|
+
* Resolves whether an item's Download action renders as the primary action
|
|
199
|
+
* instead of a Manage-menu entry. Defaults to
|
|
200
|
+
* `item.type === CatalogEntityType.Skill`.
|
|
201
|
+
*/
|
|
202
|
+
isDownloadPrimary?: (item: CatalogItem) => boolean;
|
|
203
|
+
/**
|
|
204
|
+
* Resolves the text of a file picked in the details panel's Content tab,
|
|
205
|
+
* given its opaque `id`. The panel shows a loading state while it is
|
|
206
|
+
* pending and renders the resolved text as the body. Superseded by
|
|
207
|
+
* `onLoadContentFilePreview` for a given pick when both are supplied.
|
|
208
|
+
*/
|
|
209
|
+
onLoadContentFile?: (fileId: string) => Promise<string | undefined>;
|
|
210
|
+
/**
|
|
211
|
+
* Resolves a picked file's typed preview, given its opaque `id`. Takes
|
|
212
|
+
* precedence over `onLoadContentFile` when both are supplied.
|
|
213
|
+
*/
|
|
214
|
+
onLoadContentFilePreview?: (fileId: string) => Promise<CatalogContentFilePreview | undefined>;
|
|
215
|
+
/**
|
|
216
|
+
* Renders a picked file through a host-owned preview surface. Takes
|
|
217
|
+
* precedence over both loading callbacks, while the catalog continues to
|
|
218
|
+
* own selection and passes the opaque file id and resolved basename only.
|
|
219
|
+
*/
|
|
220
|
+
renderContentFilePreview?: (fileId: string, fileName: string) => ReactNode;
|
|
121
221
|
/**
|
|
122
222
|
* Called immediately when the "Delete" button in the details panel is
|
|
123
223
|
* clicked, with no confirmation step. Shown only when the item's `isMyApp`
|
|
@@ -125,6 +225,56 @@ export interface CatalogProps {
|
|
|
125
225
|
* promise; the button shows a disabled state while pending.
|
|
126
226
|
*/
|
|
127
227
|
onDelete?: (item: CatalogItem) => Promise<void> | void;
|
|
228
|
+
/**
|
|
229
|
+
* Called when removal is confirmed via the details panel's confirmation
|
|
230
|
+
* popup, for an item shared with the current user (`sharedWithMe: true`).
|
|
231
|
+
* May return a promise; the popup shows a loading state and prevents
|
|
232
|
+
* duplicate submission while pending.
|
|
233
|
+
*/
|
|
234
|
+
onUnshare?: (item: CatalogItem) => Promise<void> | void;
|
|
235
|
+
/**
|
|
236
|
+
* Narrows where the "Remove from My List" action is offered, on top of the
|
|
237
|
+
* built-in `sharedWithMe`/`isMyApp` rule. Use it to declare that unsharing
|
|
238
|
+
* is unsupported for a kind of item. Defaults to `true` (visible) when
|
|
239
|
+
* absent.
|
|
240
|
+
*/
|
|
241
|
+
isUnshareVisible?: (item: CatalogItem) => boolean;
|
|
242
|
+
/**
|
|
243
|
+
* Called when revocation is confirmed via the details panel's confirmation
|
|
244
|
+
* step, for an item the current user owns (`isMyApp: true`), removing every
|
|
245
|
+
* recipient's shared access at once. May return a promise; the confirmation
|
|
246
|
+
* shows a loading state and prevents duplicate submission while pending.
|
|
247
|
+
*/
|
|
248
|
+
onRevokeShare?: (item: CatalogItem) => Promise<void> | void;
|
|
249
|
+
/**
|
|
250
|
+
* Resolves how many users currently hold shared access to an owned item.
|
|
251
|
+
* Called when the owner opens the details panel's Manage menu, so "Revoke
|
|
252
|
+
* access" is gated and labelled on a count that is never stale. `0` hides
|
|
253
|
+
* the action; `undefined` (or a rejection) leaves it reachable without a
|
|
254
|
+
* count. Omit to offer the action for every owned item.
|
|
255
|
+
*/
|
|
256
|
+
onFetchRecipientsCount?: (item: CatalogItem) => Promise<number | undefined>;
|
|
257
|
+
/**
|
|
258
|
+
* Narrows where the "Revoke access" action is offered, on top of the
|
|
259
|
+
* built-in `isMyApp` rule and the recipient count. Use it to declare that
|
|
260
|
+
* revoking is unsupported for a kind of item. Defaults to `true` (visible)
|
|
261
|
+
* when absent.
|
|
262
|
+
*/
|
|
263
|
+
isRevokeShareVisible?: (item: CatalogItem) => boolean;
|
|
264
|
+
/**
|
|
265
|
+
* Called when unpublish is confirmed via the details panel's confirmation
|
|
266
|
+
* step, with the published folder's path segments. May return a promise;
|
|
267
|
+
* the confirmation shows a loading state and prevents duplicate submission
|
|
268
|
+
* while pending. The published copy survives until an administrator
|
|
269
|
+
* approves, so the panel stays open and the item stays visible.
|
|
270
|
+
*/
|
|
271
|
+
onUnpublish?: (item: CatalogItem, folderPath: string[]) => Promise<void> | void;
|
|
272
|
+
/**
|
|
273
|
+
* Narrows where the "Unpublish" action is offered, on top of the presence
|
|
274
|
+
* of `onUnpublish` and at least one resolved `getPublishHistory` entry.
|
|
275
|
+
* Defaults to `true` (visible) when absent.
|
|
276
|
+
*/
|
|
277
|
+
isUnpublishVisible?: (item: CatalogItem) => boolean;
|
|
128
278
|
/**
|
|
129
279
|
* Renders the Share popover content anchored to the Share button in the
|
|
130
280
|
* details panel. When provided, clicking Share opens this popover instead
|
|
@@ -138,16 +288,11 @@ export interface CatalogProps {
|
|
|
138
288
|
*/
|
|
139
289
|
isShareVisible?: (item: CatalogItem) => boolean;
|
|
140
290
|
/**
|
|
141
|
-
*
|
|
142
|
-
*
|
|
143
|
-
*
|
|
291
|
+
* Resolves whether "Share" renders as its own button in the details header
|
|
292
|
+
* rather than an entry in its "Manage" menu. Defaults to `true` — the
|
|
293
|
+
* button. Returning `false` moves it into the menu, beside "Delete".
|
|
144
294
|
*/
|
|
145
|
-
|
|
146
|
-
/**
|
|
147
|
-
* Controls whether the "Connect" action is shown for an item. When absent,
|
|
148
|
-
* the Connect button is never shown.
|
|
149
|
-
*/
|
|
150
|
-
isConnectVisible?: (item: CatalogItem) => boolean;
|
|
295
|
+
isSharePrimary?: (item: CatalogItem) => boolean;
|
|
151
296
|
/**
|
|
152
297
|
* Called when the credentials login form is submitted in the details
|
|
153
298
|
* panel, for the given credentials `level` (`USER` or `GLOBAL`). May
|
|
@@ -177,15 +322,33 @@ export interface CatalogProps {
|
|
|
177
322
|
* Dropdown options for the Create button. When provided, the button opens a
|
|
178
323
|
* menu instead of calling `onCreateClick` directly.
|
|
179
324
|
*/
|
|
180
|
-
createOptions?:
|
|
325
|
+
createOptions?: DropdownItem[];
|
|
181
326
|
/** Called when the Create button is clicked (used when `createOptions` is absent). */
|
|
182
327
|
onCreateClick?: () => void;
|
|
183
328
|
/** Hides the "Create" button entirely, e.g. when rendering as a read-only picker. Default: false. */
|
|
184
329
|
hideCreateButton?: boolean;
|
|
330
|
+
/**
|
|
331
|
+
* Renders the whole catalog as a read-only browsing surface. Browse cards
|
|
332
|
+
* lose their favorite star, footer divider, and "Featured" tag; the list
|
|
333
|
+
* view loses its "Favorite" column; the "Create" button and the favorites
|
|
334
|
+
* strip are not rendered; and the details panel withholds its favorite star
|
|
335
|
+
* and every mutating action (Share, Publish/Unpublish, Edit, Delete,
|
|
336
|
+
* "Remove from My List", "Revoke access", and the credentials Log in / Log
|
|
337
|
+
* out / manage button). The non-mutating actions — the primary "Use in
|
|
338
|
+
* chat" and Download — still render. Default: false.
|
|
339
|
+
*/
|
|
340
|
+
isReadonly?: boolean;
|
|
185
341
|
/** Hides the page heading (title row), e.g. when the host renders its own title outside the catalog. Default: false. */
|
|
186
342
|
hidePageTitle?: boolean;
|
|
187
|
-
/** Initial Browse view mode (grid
|
|
343
|
+
/** Initial Browse view mode (`Grid` renders the card grid, `Cards` the list view). Default: `CatalogViewMode.Grid`. */
|
|
188
344
|
initialViewMode?: CatalogViewMode;
|
|
345
|
+
/**
|
|
346
|
+
* Lets the Browse content (card grid and list view) span the full width of
|
|
347
|
+
* its container instead of sitting in a centered, 1180 px-wide column with
|
|
348
|
+
* empty gutters on wide screens. The 32 px side padding is kept either way,
|
|
349
|
+
* and the wider container yields more card columns. Default: false.
|
|
350
|
+
*/
|
|
351
|
+
isFullWidth?: boolean;
|
|
189
352
|
/** ID of an item to visually mark as selected (border, tint, and checkmark) in the Browse grid. */
|
|
190
353
|
selectedItemId?: string;
|
|
191
354
|
/**
|
|
@@ -203,6 +366,11 @@ export interface CatalogProps {
|
|
|
203
366
|
styles?: CatalogStyles;
|
|
204
367
|
/** Text overrides forwarded to the item details panel. */
|
|
205
368
|
detailsTexts?: ItemDetailsTexts;
|
|
369
|
+
/**
|
|
370
|
+
* Footer note forwarded to the item details panel's Limits tab, e.g. a
|
|
371
|
+
* link to a full usage-limits page. Omitted (the default) hides the footer.
|
|
372
|
+
*/
|
|
373
|
+
detailsLimitsFooterNote?: ReactNode;
|
|
206
374
|
/**
|
|
207
375
|
* Externally-controlled active sort key. When omitted, `Catalog` manages
|
|
208
376
|
* its own sort state internally, defaulting to `CatalogSortKey.RecentlyUpdated`.
|
|
@@ -225,5 +393,13 @@ export interface CatalogProps {
|
|
|
225
393
|
isMyAppsActive?: boolean;
|
|
226
394
|
/** Called when the user toggles the "My Apps" filter; required to control `isMyAppsActive`. */
|
|
227
395
|
onMyAppsActiveChange?: (isActive: boolean) => void;
|
|
396
|
+
/**
|
|
397
|
+
* Externally-controlled active entity-type tab id. When omitted, `Catalog`
|
|
398
|
+
* manages its own tab state internally, defaulting to the first tab
|
|
399
|
+
* returned by `buildCatalogTabs`.
|
|
400
|
+
*/
|
|
401
|
+
activeTab?: string;
|
|
402
|
+
/** Called when the user switches tabs; required to control `activeTab`. */
|
|
403
|
+
onActiveTabChange?: (tabId: string) => void;
|
|
228
404
|
}
|
|
229
405
|
//# sourceMappingURL=catalog-props.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"catalog-props.d.ts","sourceRoot":"","sources":["../../src/models/catalog-props.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"catalog-props.d.ts","sourceRoot":"","sources":["../../src/models/catalog-props.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AACnE,OAAO,KAAK,EACV,eAAe,EACf,iBAAiB,EACjB,mBAAmB,EACnB,mBAAmB,EACnB,kBAAkB,EACnB,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,YAAY,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAC9D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,gCAAgC,CAAC;AAC/E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;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AC,EAAE,CAAC,QAAQ,EAAE,OAAO,KAAK,IAAI,CAAC;IACnD;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,2EAA2E;IAC3E,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CAC7C"}
|
|
@@ -1,48 +1,24 @@
|
|
|
1
|
+
import { CSSProperties } from 'react';
|
|
1
2
|
/**
|
|
2
3
|
* Color overrides for the Catalog component.
|
|
3
4
|
* All values are applied as CSS custom properties with app theme fallbacks.
|
|
4
5
|
*/
|
|
5
6
|
export interface CatalogColors {
|
|
6
|
-
/** Root container background color. Fallback: `--bg-layer-
|
|
7
|
+
/** Root container background color. Fallback: `--bg-layer-base`. */
|
|
7
8
|
background?: string;
|
|
8
|
-
/** Primary text color. Fallback: `--text-primary`. */
|
|
9
|
-
text?: string;
|
|
10
|
-
/** Secondary text color (dates, metadata). Fallback: `--text-secondary`. */
|
|
11
|
-
textSecondary?: string;
|
|
12
|
-
/** Heading container border color. Fallback: `--stroke-secondary`. */
|
|
13
|
-
headingBorder?: string;
|
|
14
|
-
/** Heading container background color. Fallback: `--bg-layer-1`. */
|
|
15
|
-
headingBackground?: string;
|
|
16
9
|
/** Heading title text color. Fallback: `--text-primary`. */
|
|
17
10
|
headingTitleText?: string;
|
|
18
|
-
/** Content container background color. Fallback: `--bg-layer-1`. */
|
|
19
|
-
contentBackground?: string;
|
|
20
|
-
/** Section heading text color (Browse, Favorites titles). Fallback: `--text-primary`. */
|
|
21
|
-
sectionHeadingText?: string;
|
|
22
|
-
/** "No results" title text color. Fallback: `--text-primary`. */
|
|
23
|
-
noResultsTitleText?: string;
|
|
24
|
-
/** "No results" description text color. Fallback: `--text-secondary`. */
|
|
25
|
-
noResultsDescriptionText?: string;
|
|
26
|
-
/** Tab result-count text color. Fallback: `--text-secondary`. */
|
|
27
|
-
tabCountText?: string;
|
|
28
|
-
}
|
|
29
|
-
/**
|
|
30
|
-
* Typography overrides for the Catalog component.
|
|
31
|
-
* When a `fontClassName` is provided, individual font properties are ignored.
|
|
32
|
-
*/
|
|
33
|
-
export interface CatalogTypography {
|
|
34
|
-
/** Font family applied to the page heading. */
|
|
35
|
-
pageHeadingFontFamily?: string;
|
|
36
|
-
/** Font size applied to the page heading. */
|
|
37
|
-
pageHeadingFontSize?: string;
|
|
38
|
-
/** Font weight applied to the page heading. */
|
|
39
|
-
pageHeadingFontWeight?: string | number;
|
|
40
|
-
/** Line height applied to the page heading. */
|
|
41
|
-
pageHeadingLineHeight?: string;
|
|
42
11
|
/**
|
|
43
|
-
*
|
|
44
|
-
*
|
|
12
|
+
* Featured chip style override, applied to every "Featured" chip in the
|
|
13
|
+
* catalog (both the browse-grid cards and the item details header)
|
|
14
|
+
* regardless of entity type, merged over the chip's default per-entity-type
|
|
15
|
+
* colors, e.g. `{ backgroundColor, color, border }`.
|
|
45
16
|
*/
|
|
17
|
+
featuredChipStyle?: CSSProperties;
|
|
18
|
+
}
|
|
19
|
+
/** Typography overrides for the Catalog component. */
|
|
20
|
+
export interface CatalogTypography {
|
|
21
|
+
/** A single utility class applied to the page heading. Defaults to `'dial-display2-text'`. */
|
|
46
22
|
pageHeadingFontClassName?: string;
|
|
47
23
|
/** Typography class applied to tab text. Defaults to `'dial-body-text'`. */
|
|
48
24
|
tabClassName?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"catalog-styles.d.ts","sourceRoot":"","sources":["../../src/models/catalog-styles.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"catalog-styles.d.ts","sourceRoot":"","sources":["../../src/models/catalog-styles.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAE3C;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC5B,oEAAoE;IACpE,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,4DAA4D;IAC5D,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B;;;;;OAKG;IACH,iBAAiB,CAAC,EAAE,aAAa,CAAC;CACnC;AAED,sDAAsD;AACtD,MAAM,WAAW,iBAAiB;IAChC,8FAA8F;IAC9F,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC,4EAA4E;IAC5E,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,kFAAkF;AAClF,MAAM,WAAW,aAAa;IAC5B,6DAA6D;IAC7D,MAAM,CAAC,EAAE,aAAa,CAAC;IACvB,qDAAqD;IACrD,UAAU,CAAC,EAAE,iBAAiB,CAAC;CAChC"}
|
package/models/favorites.d.ts
CHANGED
|
@@ -1,21 +1,35 @@
|
|
|
1
1
|
import { CatalogItem } from './catalog-item';
|
|
2
2
|
/** Typography class overrides for `CatalogFavorites`. */
|
|
3
3
|
export interface FavoritesTypography {
|
|
4
|
-
/** Typography class for the section title. Default: `'dial-
|
|
4
|
+
/** Typography class for the section title. Default: `'dial-body-semi-text'`. */
|
|
5
5
|
titleClassName?: string;
|
|
6
|
-
/** Typography class for the total count. Default: `'dial-tiny-text'`. */
|
|
6
|
+
/** Typography class for the total count and the page counter. Default: `'dial-tiny-semi-text'`. */
|
|
7
7
|
countClassName?: string;
|
|
8
8
|
}
|
|
9
9
|
/** Color overrides for `CatalogFavorites`, applied via CSS custom properties. */
|
|
10
10
|
export interface FavoritesColors {
|
|
11
|
-
/** Base section background color. Fallback: `--bg-layer-2`. */
|
|
12
|
-
backgroundBase?: string;
|
|
13
|
-
/** Section bottom border color. Fallback: `--stroke-secondary`. */
|
|
14
|
-
border?: string;
|
|
15
11
|
/** Section title color. Fallback: `--text-primary`. */
|
|
16
12
|
titleText?: string;
|
|
17
|
-
/**
|
|
13
|
+
/** Total-count and page-counter text color. Fallback: `--text-secondary`. */
|
|
18
14
|
countText?: string;
|
|
15
|
+
/** Color of the checkmark icon on the selected favorite card. Fallback: `--text-accent`. */
|
|
16
|
+
selectedCheckIcon?: string;
|
|
17
|
+
/** Border color of the selected favorite card. Fallback: `--stroke-accent`. */
|
|
18
|
+
selectedCardBorder?: string;
|
|
19
|
+
/** Background color (tint) of the selected favorite card. Fallback: `--bg-control-accent-alpha-active`. */
|
|
20
|
+
selectedCardBackground?: string;
|
|
21
|
+
/** Icon color of the pagination arrows. Fallback: `--text-accent`. */
|
|
22
|
+
navButton?: string;
|
|
23
|
+
/** Icon color of a disabled pagination arrow. Fallback: `--stroke-secondary`. */
|
|
24
|
+
navButtonDisabled?: string;
|
|
25
|
+
/** Background of a pagination arrow on hover. Fallback: `--bg-control-accent-alpha-hover`. */
|
|
26
|
+
navButtonHoverBackground?: string;
|
|
27
|
+
/** Background of a pagination arrow while pressed. Fallback: `--bg-control-accent-alpha-active`. */
|
|
28
|
+
navButtonActiveBackground?: string;
|
|
29
|
+
/** Border color of the pagination control. Fallback: `--stroke-accent-alpha`. */
|
|
30
|
+
pageNavBorder?: string;
|
|
31
|
+
/** Background of the pagination control. Fallback: `--bg-control-accent-alpha`. */
|
|
32
|
+
pageNavBackground?: string;
|
|
19
33
|
}
|
|
20
34
|
/** Grouped style overrides for `CatalogFavorites`. */
|
|
21
35
|
export interface FavoritesStyles {
|
|
@@ -34,6 +48,8 @@ export interface FavoritesProps {
|
|
|
34
48
|
title?: string;
|
|
35
49
|
/** Called when a favorite card's star is toggled. */
|
|
36
50
|
onToggleFavorite?: (id: string, isStarred: boolean) => void;
|
|
51
|
+
/** Rule for whether the favorite star is shown on a favorite card; `false` hides it and makes the item non-favoritable. Defaults to visible when omitted. */
|
|
52
|
+
isFavoriteVisible?: (item: CatalogItem) => boolean;
|
|
37
53
|
/** Called when a favorite card body is clicked. Opens the details panel. */
|
|
38
54
|
onItemClick?: (item: CatalogItem) => void;
|
|
39
55
|
/** Grouped typography and color overrides for the section. */
|
|
@@ -52,7 +68,7 @@ export interface FavoritesProps {
|
|
|
52
68
|
removeFromFavoritesAriaLabel?: string;
|
|
53
69
|
/** ID of an item to visually mark as selected (border, tint, and checkmark). */
|
|
54
70
|
selectedItemId?: string;
|
|
55
|
-
/**
|
|
71
|
+
/** Accessible label for the logged-out warning icon on a favorited item's avatar, and the text shown in its hover tooltip. Default: `'Authorize to use this toolset.'`. */
|
|
56
72
|
credentialsBadgeLoggedOutLabel?: string;
|
|
57
73
|
}
|
|
58
74
|
//# sourceMappingURL=favorites.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"favorites.d.ts","sourceRoot":"","sources":["../../src/models/favorites.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,yDAAyD;AACzD,MAAM,WAAW,mBAAmB;IAClC,
|
|
1
|
+
{"version":3,"file":"favorites.d.ts","sourceRoot":"","sources":["../../src/models/favorites.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,yDAAyD;AACzD,MAAM,WAAW,mBAAmB;IAClC,gFAAgF;IAChF,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,mGAAmG;IACnG,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,iFAAiF;AACjF,MAAM,WAAW,eAAe;IAC9B,uDAAuD;IACvD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,6EAA6E;IAC7E,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,4FAA4F;IAC5F,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,+EAA+E;IAC/E,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,2GAA2G;IAC3G,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,sEAAsE;IACtE,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,iFAAiF;IACjF,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,8FAA8F;IAC9F,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC,oGAAoG;IACpG,yBAAyB,CAAC,EAAE,MAAM,CAAC;IACnC,iFAAiF;IACjF,aAAa,CA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
|
|
|
1
|
+
import { CatalogItem } from './catalog-item';
|
|
1
2
|
import { ListViewTypography } from './list-props';
|
|
2
3
|
/** ag-grid context shape passed to all cell renderers. */
|
|
3
4
|
export interface GridContext {
|
|
@@ -7,9 +8,13 @@ export interface GridContext {
|
|
|
7
8
|
typography: ListViewTypography;
|
|
8
9
|
/** Called when the star button is toggled in a row. */
|
|
9
10
|
onToggleFavorite?: (id: string, isStarred: boolean) => void;
|
|
11
|
+
/** Rule for whether the favorite star is shown on a row; `false` hides it. Defaults to visible when omitted. */
|
|
12
|
+
isFavoriteVisible?: (item: CatalogItem) => boolean;
|
|
10
13
|
/** ID of an item to visually mark as selected (border, tint, and checkmark). */
|
|
11
14
|
selectedItemId?: string;
|
|
12
|
-
/**
|
|
15
|
+
/** Accessible label for the logged-out warning icon on the entity avatar, and the text shown in its hover tooltip. */
|
|
13
16
|
credentialsBadgeLoggedOutLabel?: string;
|
|
17
|
+
/** Renders the list read-only: the "Favorite" column is dropped entirely. */
|
|
18
|
+
isReadonly?: boolean;
|
|
14
19
|
}
|
|
15
20
|
//# sourceMappingURL=grid-context.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"grid-context.d.ts","sourceRoot":"","sources":["../../src/models/grid-context.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAElD,0DAA0D;AAC1D,MAAM,WAAW,WAAW;IAC1B,sEAAsE;IACtE,WAAW,EAAE,MAAM,CAAC;IACpB,iDAAiD;IACjD,UAAU,EAAE,kBAAkB,CAAC;IAC/B,uDAAuD;IACvD,gBAAgB,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,SAAS,EAAE,OAAO,KAAK,IAAI,CAAC;IAC5D,gFAAgF;IAChF,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,
|
|
1
|
+
{"version":3,"file":"grid-context.d.ts","sourceRoot":"","sources":["../../src/models/grid-context.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAElD,0DAA0D;AAC1D,MAAM,WAAW,WAAW;IAC1B,sEAAsE;IACtE,WAAW,EAAE,MAAM,CAAC;IACpB,iDAAiD;IACjD,UAAU,EAAE,kBAAkB,CAAC;IAC/B,uDAAuD;IACvD,gBAAgB,CAAC,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,SAAS,EAAE,OAAO,KAAK,IAAI,CAAC;IAC5D,gHAAgH;IAChH,iBAAiB,CAAC,EAAE,CAAC,IAAI,EAAE,WAAW,KAAK,OAAO,CAAC;IACnD,gFAAgF;IAChF,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,sHAAsH;IACtH,8BAA8B,CAAC,EAAE,MAAM,CAAC;IACxC,6EAA6E;IAC7E,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB"}
|
package/models/grid-props.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { CSSProperties } from 'react';
|
|
1
2
|
import { CatalogItem } from './catalog-item';
|
|
2
3
|
/** Text overrides for `CardGrid` empty state. */
|
|
3
4
|
export interface CardGridTitles {
|
|
@@ -9,7 +10,7 @@ export interface CardGridTitles {
|
|
|
9
10
|
addToFavoritesAriaLabel?: string;
|
|
10
11
|
/** Accessible label for the star button when the item is already starred. Default: `'Remove from favorites'`. */
|
|
11
12
|
removeFromFavoritesAriaLabel?: string;
|
|
12
|
-
/**
|
|
13
|
+
/** Accessible label for the logged-out warning icon on card avatars, and the text shown in its hover tooltip. Default: `'Authorize to use this toolset.'`. */
|
|
13
14
|
credentialsBadgeLoggedOutLabel?: string;
|
|
14
15
|
}
|
|
15
16
|
/** Props for `CardGrid`. */
|
|
@@ -20,6 +21,12 @@ export interface CardGridProps {
|
|
|
20
21
|
query?: string;
|
|
21
22
|
/** Called when a card's star is toggled. */
|
|
22
23
|
onToggleFavorite?: (id: string, isStarred: boolean) => void;
|
|
24
|
+
/**
|
|
25
|
+
* Additional caller-supplied rule for whether the favorite star is shown on a
|
|
26
|
+
* card. Returning `false` hides the star and makes the item non-favoritable.
|
|
27
|
+
* Defaults to **visible** when omitted.
|
|
28
|
+
*/
|
|
29
|
+
isFavoriteVisible?: (item: CatalogItem) => boolean;
|
|
23
30
|
/** Grouped empty-state text overrides. */
|
|
24
31
|
titles?: CardGridTitles;
|
|
25
32
|
/** Called when a card body is clicked. */
|
|
@@ -28,5 +35,20 @@ export interface CardGridProps {
|
|
|
28
35
|
isLoading?: boolean;
|
|
29
36
|
/** ID of an item to visually mark as selected (border, tint, and checkmark). */
|
|
30
37
|
selectedItemId?: string;
|
|
38
|
+
/** Skeleton bar/shape color while loading. Defaults to `--cg-skeleton-color`. */
|
|
39
|
+
skeletonColor?: string;
|
|
40
|
+
/** Background color of a skeleton placeholder card. Fallback: `--bg-layer-raised`. */
|
|
41
|
+
skeletonCardBackground?: string;
|
|
42
|
+
/** Featured chip style override, merged over its default per-entity-type colors for every card, e.g. `{ backgroundColor, color, border }`. */
|
|
43
|
+
featuredChipStyle?: CSSProperties;
|
|
44
|
+
/** Renders every card read-only: no favorite star, no footer divider, and no "Featured" tag. Default: false. */
|
|
45
|
+
isReadonly?: boolean;
|
|
46
|
+
/**
|
|
47
|
+
* Set when the host renders the grid without the `CONTENT_MAX_WIDTH` column
|
|
48
|
+
* cap, so the first-paint column-count guess matches the real container
|
|
49
|
+
* width. Purely an estimate hint — the observed width always wins once the
|
|
50
|
+
* grid is measured. Default: false.
|
|
51
|
+
*/
|
|
52
|
+
isFullWidth?: boolean;
|
|
31
53
|
}
|
|
32
54
|
//# sourceMappingURL=grid-props.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"grid-props.d.ts","sourceRoot":"","sources":["../../src/models/grid-props.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC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