@theseam/ui-common 1.0.2-beta.83 → 1.0.2-beta.85
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/ai/index.d.ts +170 -17
- package/carousel/index.d.ts +21 -1
- package/datatable/index.d.ts +299 -3
- package/datatable-alterations-display/index.d.ts +61 -1
- package/fesm2022/theseam-ui-common-ai.mjs +433 -103
- package/fesm2022/theseam-ui-common-ai.mjs.map +1 -1
- package/fesm2022/theseam-ui-common-carousel.mjs +48 -1
- package/fesm2022/theseam-ui-common-carousel.mjs.map +1 -1
- package/fesm2022/theseam-ui-common-datatable-alterations-display.mjs +197 -1
- package/fesm2022/theseam-ui-common-datatable-alterations-display.mjs.map +1 -1
- package/fesm2022/theseam-ui-common-datatable.mjs +668 -4
- package/fesm2022/theseam-ui-common-datatable.mjs.map +1 -1
- package/fesm2022/theseam-ui-common-file-input.mjs +156 -1
- package/fesm2022/theseam-ui-common-file-input.mjs.map +1 -1
- package/fesm2022/theseam-ui-common-icon.mjs +72 -1
- package/fesm2022/theseam-ui-common-icon.mjs.map +1 -1
- package/fesm2022/theseam-ui-common-tooltip.mjs +110 -1
- package/fesm2022/theseam-ui-common-tooltip.mjs.map +1 -1
- package/fesm2022/theseam-ui-common-widget.mjs +23 -1
- package/fesm2022/theseam-ui-common-widget.mjs.map +1 -1
- package/file-input/index.d.ts +78 -1
- package/icon/index.d.ts +33 -3
- package/package.json +1 -1
- package/tooltip/index.d.ts +40 -2
- package/widget/index.d.ts +17 -2
package/ai/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
import { Observable, BehaviorSubject } from 'rxjs';
|
|
1
2
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { AfterViewInit, InjectionToken, Type } from '@angular/core';
|
|
3
|
+
import { AfterViewInit, OnDestroy, InjectionToken, Type } from '@angular/core';
|
|
3
4
|
import { TheSeamDatatableColumn, DatatableComponent, ColumnsAlterationState } from '@theseam/ui-common/datatable';
|
|
4
5
|
import { DatatableGraphQLQueryRef } from '@theseam/ui-common/graphql';
|
|
5
|
-
import { BehaviorSubject, Observable } from 'rxjs';
|
|
6
6
|
import * as _angular_cdk_testing from '@angular/cdk/testing';
|
|
7
7
|
import { ComponentHarness } from '@angular/cdk/testing';
|
|
8
8
|
import { FormGroup, FormControl } from '@angular/forms';
|
|
@@ -29,34 +29,136 @@ interface TheSeamChatContextPayload {
|
|
|
29
29
|
data: unknown;
|
|
30
30
|
}
|
|
31
31
|
|
|
32
|
+
/**
|
|
33
|
+
* A single conversation turn. Sent to the LLM via `chat()` and produced by
|
|
34
|
+
* `chat()` as the assistant response. Persisted history (with uid + created)
|
|
35
|
+
* is exposed separately via `ChatSessionMessage`.
|
|
36
|
+
*/
|
|
32
37
|
interface ChatMessage {
|
|
33
|
-
|
|
38
|
+
/** 'user' | 'assistant' in practice; widened to string for forward-compat. */
|
|
39
|
+
role: string;
|
|
34
40
|
content: string;
|
|
35
41
|
}
|
|
36
|
-
interface
|
|
42
|
+
interface ChatSessionMessage {
|
|
43
|
+
uid: string;
|
|
44
|
+
role: string;
|
|
37
45
|
content: string;
|
|
46
|
+
/** ISO-8601 datetime of when the message was persisted. */
|
|
47
|
+
created: string;
|
|
48
|
+
}
|
|
49
|
+
interface ChatSession {
|
|
50
|
+
uid: string;
|
|
51
|
+
label: string;
|
|
52
|
+
created: string;
|
|
53
|
+
lastActivity: string;
|
|
54
|
+
leafMessageId: string | null;
|
|
55
|
+
messages: ChatSessionMessage[];
|
|
56
|
+
}
|
|
57
|
+
interface ChatSessionListItem {
|
|
58
|
+
uid: string;
|
|
59
|
+
label: string;
|
|
60
|
+
created: string;
|
|
61
|
+
lastActivity: string;
|
|
38
62
|
}
|
|
39
63
|
interface TheSeamAiChatRequest {
|
|
40
64
|
messages: ChatMessage[];
|
|
41
65
|
contexts?: TheSeamChatContextPayload[];
|
|
66
|
+
/** When null, the backend creates a new session and returns its uid. */
|
|
67
|
+
sessionId?: string | null;
|
|
68
|
+
/**
|
|
69
|
+
* Required when `sessionId` is set. The uid of the message the client
|
|
70
|
+
* believes is the current leaf. Backend returns 409 if it doesn't match.
|
|
71
|
+
*/
|
|
72
|
+
expectedLeafMessageId?: string | null;
|
|
73
|
+
}
|
|
74
|
+
interface ChatResponse {
|
|
75
|
+
content: string;
|
|
76
|
+
sessionId: string;
|
|
77
|
+
label: string;
|
|
78
|
+
leafMessageId: string;
|
|
79
|
+
}
|
|
80
|
+
/**
|
|
81
|
+
* Errored by `TheSeamAiProvider.chat()` when the server reports the
|
|
82
|
+
* session's leaf has advanced since the client last observed it (HTTP 409).
|
|
83
|
+
* The chat component catches this, reloads the session, and emits
|
|
84
|
+
* `(staleSession)`.
|
|
85
|
+
*/
|
|
86
|
+
declare class ChatSessionStaleError extends Error {
|
|
87
|
+
readonly sessionId: string;
|
|
88
|
+
readonly currentLeafMessageId: string | null;
|
|
89
|
+
constructor(sessionId: string, currentLeafMessageId: string | null);
|
|
42
90
|
}
|
|
43
91
|
interface TheSeamAiProvider {
|
|
44
|
-
|
|
92
|
+
/**
|
|
93
|
+
* Send a chat turn. Errors with `ChatSessionStaleError` when the session's
|
|
94
|
+
* leaf has advanced since the last observed state.
|
|
95
|
+
*
|
|
96
|
+
* Implementations should emit exactly once and complete.
|
|
97
|
+
*/
|
|
98
|
+
chat(request: TheSeamAiChatRequest): Observable<ChatResponse>;
|
|
99
|
+
/**
|
|
100
|
+
* Hook the chat component calls on mount to ask the provider what session
|
|
101
|
+
* to load. Default app implementation prefers a query-param session uid
|
|
102
|
+
* and falls back to the user's most recent session, but apps can override.
|
|
103
|
+
*/
|
|
104
|
+
getInitialSession(): Observable<ChatSession | null>;
|
|
105
|
+
/** Returns the user's most-recently-active session, or null if none exists. */
|
|
106
|
+
getRecentSession(): Observable<ChatSession | null>;
|
|
107
|
+
/** Loads a specific session with its active-path messages. */
|
|
108
|
+
getSession(uid: string): Observable<ChatSession>;
|
|
109
|
+
/** Returns session metadata for the user (no messages). */
|
|
110
|
+
listSessions(): Observable<ChatSessionListItem[]>;
|
|
111
|
+
/** Updates a session's user-visible label. */
|
|
112
|
+
renameSession(uid: string, label: string): Observable<void>;
|
|
113
|
+
/** Soft-deletes the session. */
|
|
114
|
+
deleteSession(uid: string): Observable<void>;
|
|
45
115
|
}
|
|
46
116
|
|
|
47
117
|
declare class LmStudioAiProvider implements TheSeamAiProvider {
|
|
48
|
-
chat(request: TheSeamAiChatRequest):
|
|
118
|
+
chat(request: TheSeamAiChatRequest): Observable<ChatResponse>;
|
|
119
|
+
getInitialSession(): Observable<ChatSession | null>;
|
|
120
|
+
getRecentSession(): Observable<ChatSession | null>;
|
|
121
|
+
getSession(_uid: string): Observable<ChatSession>;
|
|
122
|
+
listSessions(): Observable<ChatSessionListItem[]>;
|
|
123
|
+
renameSession(_uid: string, _label: string): Observable<void>;
|
|
124
|
+
deleteSession(_uid: string): Observable<void>;
|
|
49
125
|
}
|
|
50
126
|
|
|
51
127
|
declare class OpenRouterAiProvider implements TheSeamAiProvider {
|
|
52
|
-
chat(request: TheSeamAiChatRequest):
|
|
128
|
+
chat(request: TheSeamAiChatRequest): Observable<ChatResponse>;
|
|
129
|
+
getInitialSession(): Observable<ChatSession | null>;
|
|
130
|
+
getRecentSession(): Observable<ChatSession | null>;
|
|
131
|
+
getSession(_uid: string): Observable<ChatSession>;
|
|
132
|
+
listSessions(): Observable<ChatSessionListItem[]>;
|
|
133
|
+
renameSession(_uid: string, _label: string): Observable<void>;
|
|
134
|
+
deleteSession(_uid: string): Observable<void>;
|
|
53
135
|
}
|
|
54
136
|
|
|
55
137
|
type MockResponse = string | ((messages: ChatMessage[]) => string);
|
|
138
|
+
interface MockAiProviderConfig {
|
|
139
|
+
response?: MockResponse;
|
|
140
|
+
initialSession?: ChatSession | null;
|
|
141
|
+
sessionsByUid?: ReadonlyMap<string, ChatSession>;
|
|
142
|
+
sessionsList?: ChatSessionListItem[];
|
|
143
|
+
/** First chat() call errors with this; subsequent calls succeed normally. */
|
|
144
|
+
throwOnFirstChat?: Error;
|
|
145
|
+
/** Artificial delay (ms) applied uniformly. Overridable per method. */
|
|
146
|
+
delayMs?: number;
|
|
147
|
+
delayMsByMethod?: Partial<Record<keyof TheSeamAiProvider, number>>;
|
|
148
|
+
}
|
|
149
|
+
type LegacyArg = MockAiProviderConfig | MockResponse | undefined;
|
|
56
150
|
declare class MockAiProvider implements TheSeamAiProvider {
|
|
57
|
-
private readonly
|
|
58
|
-
|
|
59
|
-
|
|
151
|
+
private readonly _config;
|
|
152
|
+
private _throwOnNextChat?;
|
|
153
|
+
constructor(configOrLegacy?: LegacyArg);
|
|
154
|
+
chat(request: TheSeamAiChatRequest): Observable<ChatResponse>;
|
|
155
|
+
getInitialSession(): Observable<ChatSession | null>;
|
|
156
|
+
getRecentSession(): Observable<ChatSession | null>;
|
|
157
|
+
getSession(uid: string): Observable<ChatSession>;
|
|
158
|
+
listSessions(): Observable<ChatSessionListItem[]>;
|
|
159
|
+
renameSession(_uid: string, _label: string): Observable<void>;
|
|
160
|
+
deleteSession(_uid: string): Observable<void>;
|
|
161
|
+
private _withDelay;
|
|
60
162
|
}
|
|
61
163
|
|
|
62
164
|
declare class TheSeamChatContextRegistry {
|
|
@@ -116,32 +218,80 @@ type ChatContentSegment = {
|
|
|
116
218
|
declare function parseChatResponse(input: string): ChatContentSegment[];
|
|
117
219
|
|
|
118
220
|
interface ChatMessageDisplayModel {
|
|
119
|
-
|
|
221
|
+
/** Present for messages loaded from a persisted session. */
|
|
222
|
+
uid?: string;
|
|
223
|
+
/** 'user' | 'assistant' rendered specially; other roles fall through to a neutral style. */
|
|
224
|
+
role: string;
|
|
120
225
|
segments: ChatContentSegment[];
|
|
121
226
|
timestamp: Date;
|
|
122
227
|
}
|
|
123
228
|
|
|
124
|
-
declare class TheSeamChatComponent implements AfterViewInit {
|
|
229
|
+
declare class TheSeamChatComponent implements AfterViewInit, OnDestroy {
|
|
125
230
|
private readonly _provider;
|
|
126
231
|
private readonly _chatContextRegistry;
|
|
127
232
|
private readonly _cdr;
|
|
128
233
|
private readonly _ngZone;
|
|
129
|
-
placeholder: string;
|
|
130
234
|
private _messageList?;
|
|
131
235
|
private _messageListScrollbar?;
|
|
132
|
-
|
|
236
|
+
private _chatInput?;
|
|
237
|
+
/**
|
|
238
|
+
* The session this chat should display.
|
|
239
|
+
*
|
|
240
|
+
* - `null` on first init: the component asks the provider for an initial
|
|
241
|
+
* session via `getInitialSession()` (default app behavior: prefers
|
|
242
|
+
* `?chatSession=<uid>`, falls back to the user's most recent session).
|
|
243
|
+
* - `null` after init: resets to a new empty chat. Equivalent to calling
|
|
244
|
+
* `newSession()`.
|
|
245
|
+
* - A session uid: loads and displays that session.
|
|
246
|
+
*
|
|
247
|
+
* Pair with `(sessionIdChange)` for two-way binding.
|
|
248
|
+
*/
|
|
249
|
+
readonly sessionId: i0.InputSignal<string | null>;
|
|
250
|
+
readonly placeholder: i0.InputSignal<string>;
|
|
251
|
+
/**
|
|
252
|
+
* Emits whenever the chat's active session changes — after the initial
|
|
253
|
+
* load resolves, after a send creates a new session, after the input is
|
|
254
|
+
* reassigned, or after `newSession()` clears the chat.
|
|
255
|
+
*/
|
|
256
|
+
readonly sessionIdChange: i0.OutputEmitterRef<string | null>;
|
|
257
|
+
/**
|
|
258
|
+
* Emits after the chat has recovered from a server-reported stale-leaf
|
|
259
|
+
* 409. The component has already reloaded the session and restored the
|
|
260
|
+
* user's typed text; consuming apps typically respond by surfacing a toast.
|
|
261
|
+
*/
|
|
262
|
+
readonly staleSession: i0.OutputEmitterRef<void>;
|
|
133
263
|
private _messages;
|
|
134
264
|
_displayMessages: ChatMessageDisplayModel[];
|
|
135
265
|
private readonly _pinnedThreshold;
|
|
136
266
|
private _isPinnedToBottom;
|
|
137
267
|
private _forceScrollOnNextResize;
|
|
268
|
+
private readonly _loadingSubject;
|
|
269
|
+
readonly loading$: Observable<boolean>;
|
|
270
|
+
private _currentSessionId;
|
|
271
|
+
private _currentLeafMessageId;
|
|
272
|
+
private _initialized;
|
|
273
|
+
private readonly _sessionLoadRequest$;
|
|
274
|
+
private readonly _destroy$;
|
|
275
|
+
private readonly _initialLoadingSubject;
|
|
276
|
+
readonly initialLoading$: Observable<boolean>;
|
|
277
|
+
constructor();
|
|
138
278
|
ngAfterViewInit(): void;
|
|
279
|
+
ngOnDestroy(): void;
|
|
280
|
+
/**
|
|
281
|
+
* Resets the chat to a new empty session. Idempotent — safe to call when
|
|
282
|
+
* the chat has no session loaded. Emits `(sessionIdChange)` with `null`.
|
|
283
|
+
*/
|
|
284
|
+
newSession(): void;
|
|
139
285
|
_onMessageSent(text: string): Promise<void>;
|
|
140
286
|
private _updatePinnedState;
|
|
141
287
|
private _maybeScrollToBottom;
|
|
142
288
|
private _scrollToBottom;
|
|
289
|
+
private _initialize;
|
|
290
|
+
private _reactToSessionInputChange;
|
|
291
|
+
private _applySession;
|
|
292
|
+
private _handleStaleSession;
|
|
143
293
|
static ɵfac: i0.ɵɵFactoryDeclaration<TheSeamChatComponent, never>;
|
|
144
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<TheSeamChatComponent, "seam-chat", never, { "placeholder": { "alias": "placeholder"; "required": false; }; }, {}, never, never, true, never>;
|
|
294
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<TheSeamChatComponent, "seam-chat", never, { "sessionId": { "alias": "sessionId"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; }, { "sessionIdChange": "sessionIdChange"; "staleSession": "staleSession"; }, never, never, true, never>;
|
|
145
295
|
}
|
|
146
296
|
|
|
147
297
|
declare const THESEAM_CHAT_PROVIDER: InjectionToken<TheSeamAiProvider>;
|
|
@@ -166,9 +316,12 @@ declare class TheSeamChatHarness extends ComponentHarness {
|
|
|
166
316
|
private readonly _messages;
|
|
167
317
|
private readonly _input;
|
|
168
318
|
private readonly _loading;
|
|
319
|
+
private readonly _initialLoading;
|
|
169
320
|
getMessages(): Promise<TheSeamChatMessageHarness[]>;
|
|
321
|
+
getMessageCount(): Promise<number>;
|
|
170
322
|
getInput(): Promise<TheSeamChatInputHarness>;
|
|
171
323
|
isLoading(): Promise<boolean>;
|
|
324
|
+
isInitialLoading(): Promise<boolean>;
|
|
172
325
|
}
|
|
173
326
|
|
|
174
327
|
declare const assistantPrompt = "You are a helpful assistant that provides formatting json code for a datatable.\nA datatable is a table that displays data in rows and columns, similar to a spreadsheet, with column sorting and data filtering.\n\nYour job is not to provide a descriptive analysis of the request or any additional information. The user will ignore anything that is not a JSON object.\n\nThe user will provide a request, and you will respond with a JSON object that contains an array of table alterations.\nThe following is the typescript interface for a datatable column and the alterations you can make to it:\n\n```typescript\ninterface TableColumn {\n /** Column property */\n prop: string,\n /** Column name */\n name: string,\n /** Column cell type - determines filter type */\n cellType?: 'string' | 'integer' | 'decimal' | 'currency' | 'date' | 'phone',\n /** Whether the column is sortable */\n sortable?: boolean,\n /** Whether the column is filterable */\n filterable?: boolean,\n /** Whether the column is visible */\n visible?: boolean,\n /** Whether the column is resizable */\n resizable?: boolean,\n /** Whether the column is draggable */\n draggable?: boolean,\n /** Column width */\n width?: number,\n /** Column index */\n index?: number,\n}\n\ninterface SortItem {\n /** Column property */\n prop: string,\n /** Sort direction */\n dir: 'asc' | 'desc'\n}\n\ninterface SortState {\n /** The list of sorts */\n sorts: SortItem[]\n}\n\ninterface OrderRecord {\n /** Column property */\n columnProp: string,\n /** Column order, which is the index that it will be placed in the columns array. */\n index: number\n}\n\ninterface OrderState {\n /** The list of column order records */\n columns: OrderRecord[]\n}\n\ninterface WidthState {\n /** The column property that this width alteration applies to */\n columnProp: string\n /** The width of the column. Number is in pixels. */\n width?: number\n /** Whether the column can auto resize. Needs to be false to guarantee a specific width. */\n canAutoResize: boolean\n}\n\ninterface HideColumnState {\n /** The column property that this alteration applies to */\n columnProp: string\n /** Whether the column is hidden */\n hidden: boolean\n}\n\ninterface FilterState {\n /** The column property that this filter applies to */\n columnProp: string,\n /** The filter type based on column cellType */\n filterType: 'text' | 'numeric' | 'date',\n /** The filter operation */\n operation: string,\n /** The filter value (for single value operations) */\n value?: any,\n /** The from value (for range operations like 'between') */\n fromValue?: any,\n /** The to value (for range operations like 'between') */\n toValue?: any\n}\n\ninterface TableAlteration<TType extends string, TState> {\n /**\n * Unique identifier for the alteration.\n */\n id: string\n /**\n * The type of alteration.\n */\n type: TType\n /** The alteration state */\n state: TState\n}\n\n/**\n * Sort alteration for a datatable.\n * \"id\" should always be \"sort\" for this alteration.\n */\ntype SortAlteration = TableAlteration<'sort', SortState>\n\n/**\n * Order alteration for a datatable column.\n *\n * \"id\" should always be \"order\" for this alteration.\n */\ntype OrderAlteration = TableAlteration<'order', OrderState>\n\n/**\n * Width alteration for a datatable column.\n *\n * \"id\" should always be \"width-<prop>\" for this alteration. So, for example, if the column property is \"name\", the id would be \"width-name\".\n */\ntype WidthAlteration = TableAlteration<'width', WidthState>\n\n/**\n * Hide column alteration for a datatable column.\n *\n * \"id\" should always be \"hide-column-<prop>\" for this alteration. So, for example, if the column property is \"name\", the id would be \"hide-column-name\".\n */\ntype HideColumnAlteration = TableAlteration<'hide-column', HideColumnState>\n\n/**\n * Filter alteration for a datatable column.\n * \"id\" should be \"filter--<columnProp>\" for this alteration.\n * For example, if filtering the \"age\" column, the id would be \"filter--age\".\n */\ntype FilterAlteration = TableAlteration<'filter', FilterState>\n```\n\n## Filter Operations by Type\n\n### Text Filters (cellType: 'string', 'phone')\n- 'contains': Text contains the value (case-insensitive)\n- 'eq': Text equals the value exactly\n- 'neq': Text does not equal the value\n- 'ncontains': Text does not contain the value\n- 'blank': Field is empty/null\n- 'not-blank': Field is not empty/null\n\n### Numeric Filters (cellType: 'integer', 'decimal', 'currency')\n- 'eq': Equals the value\n- 'gt': Greater than the value\n- 'gte': Greater than or equal to the value\n- 'lt': Less than the value\n- 'lte': Less than or equal to the value\n- 'between': Between fromValue and toValue (inclusive)\n- 'not-between': Not between fromValue and toValue\n- 'blank': Field is empty/null\n- 'not-blank': Field is not empty/null\n\n### Date Filters (cellType: 'date')\n- 'eq': Date equals the value\n- 'gt': Date is after the value\n- 'gte': Date is on or after the value\n- 'lt': Date is before the value\n- 'lte': Date is on or before the value\n- 'between': Date is between fromValue and toValue (inclusive)\n- 'not-between': Date is not between fromValue and toValue\n- 'blank': Field is empty/null\n- 'not-blank': Field is not empty/null\n\n## Examples\n\nFilter age greater than 30:\n```json\n{\n \"id\": \"filter--age\",\n \"type\": \"filter\",\n \"state\": {\n \"columnProp\": \"age\",\n \"filterType\": \"numeric\",\n \"operation\": \"gt\",\n \"value\": 30\n }\n}\n```\n\nFilter color contains \"red\":\n```json\n{\n \"id\": \"filter--color\",\n \"type\": \"filter\",\n \"state\": {\n \"columnProp\": \"color\",\n \"filterType\": \"text\",\n \"operation\": \"contains\",\n \"value\": \"red\"\n }\n}\n```\n\nFilter age between 25 and 65:\n```json\n{\n \"id\": \"filter--age\",\n \"type\": \"filter\",\n \"state\": {\n \"columnProp\": \"age\",\n \"filterType\": \"numeric\",\n \"operation\": \"between\",\n \"fromValue\": 25,\n \"toValue\": 65\n }\n}\n```\n\nSort by name ascending:\n```json\n{\n \"id\": \"sort\",\n \"type\": \"sort\",\n \"state\": {\n \"sorts\": [\n {\n \"prop\": \"name\",\n \"dir\": \"asc\"\n }\n ]\n }\n}\n```\n\nHide the age column:\n```json\n{\n \"id\": \"hide-column-age\",\n \"type\": \"hide-column\",\n \"state\": {\n \"columnProp\": \"age\",\n \"hidden\": true\n }\n}\n```\n\nSet name column width to 300 pixels:\n```json\n{\n \"id\": \"width-name\",\n \"type\": \"width\",\n \"state\": {\n \"columnProp\": \"name\",\n \"width\": 300,\n \"canAutoResize\": false\n }\n}\n```\n\nReorder columns (name first, age second, color third):\n```json\n{\n \"id\": \"order\",\n \"type\": \"order\",\n \"state\": {\n \"columns\": [\n { \"columnProp\": \"name\", \"index\": 0 },\n { \"columnProp\": \"age\", \"index\": 1 },\n { \"columnProp\": \"color\", \"index\": 2 }\n ]\n }\n}\n```\n";
|
|
@@ -207,5 +360,5 @@ declare class TheSeamDatatablePrompterComponent {
|
|
|
207
360
|
static ɵcmp: i0.ɵɵComponentDeclaration<TheSeamDatatablePrompterComponent, "seam-datatable-prompter", never, { "diffMode": { "alias": "diffMode"; "required": false; }; "compact": { "alias": "compact"; "required": false; }; "prompt": { "alias": "prompt"; "required": false; }; "datatable": { "alias": "datatable"; "required": false; }; "showAlts": { "alias": "showAlts"; "required": false; }; }, {}, never, never, true, never>;
|
|
208
361
|
}
|
|
209
362
|
|
|
210
|
-
export { LmStudioAiProvider, MockAiProvider, OpenRouterAiProvider, THESEAM_CHAT_BLOCK_REGISTRY, THESEAM_CHAT_PROVIDER, THESEAM_DATATABLE_PROMPTER_PROVIDER, TheSeamChatComponent, TheSeamChatContextRegistry, TheSeamChatHarness, TheSeamDatatableChatContext, TheSeamDatatablePrompterComponent, assistantPrompt, getUserPrompt, parseChatResponse, parseResponse };
|
|
211
|
-
export type { ChatBlockRegistry, ChatContentSegment, ChatMessage, ChatResponse, TheSeamAiChatRequest, TheSeamAiProvider, TheSeamChatContext, TheSeamChatContextPayload, TheSeamDatatableChatContextData, TheSeamDatatableChatContextOptions };
|
|
363
|
+
export { ChatSessionStaleError, LmStudioAiProvider, MockAiProvider, OpenRouterAiProvider, THESEAM_CHAT_BLOCK_REGISTRY, THESEAM_CHAT_PROVIDER, THESEAM_DATATABLE_PROMPTER_PROVIDER, TheSeamChatComponent, TheSeamChatContextRegistry, TheSeamChatHarness, TheSeamDatatableChatContext, TheSeamDatatablePrompterComponent, assistantPrompt, getUserPrompt, parseChatResponse, parseResponse };
|
|
364
|
+
export type { ChatBlockRegistry, ChatContentSegment, ChatMessage, ChatResponse, ChatSession, ChatSessionListItem, ChatSessionMessage, MockAiProviderConfig, TheSeamAiChatRequest, TheSeamAiProvider, TheSeamChatContext, TheSeamChatContextPayload, TheSeamDatatableChatContextData, TheSeamDatatableChatContextOptions };
|
package/carousel/index.d.ts
CHANGED
|
@@ -3,6 +3,8 @@ import { OnInit, OnDestroy, QueryList } from '@angular/core';
|
|
|
3
3
|
import * as _fortawesome_fontawesome_common_types from '@fortawesome/fontawesome-common-types';
|
|
4
4
|
import { NumberInput, BooleanInput } from '@angular/cdk/coercion';
|
|
5
5
|
import { Observable } from 'rxjs';
|
|
6
|
+
import * as _angular_cdk_testing from '@angular/cdk/testing';
|
|
7
|
+
import { ComponentHarness } from '@angular/cdk/testing';
|
|
6
8
|
|
|
7
9
|
declare class TheSeamCarouselSlideDirective {
|
|
8
10
|
private readonly template;
|
|
@@ -97,4 +99,22 @@ declare class TheSeamCarouselModule {
|
|
|
97
99
|
static ɵinj: i0.ɵɵInjectorDeclaration<TheSeamCarouselModule>;
|
|
98
100
|
}
|
|
99
101
|
|
|
100
|
-
|
|
102
|
+
declare class TheSeamCarouselHarness extends ComponentHarness {
|
|
103
|
+
static hostSelector: string;
|
|
104
|
+
_content: () => Promise<_angular_cdk_testing.TestElement>;
|
|
105
|
+
_prevSlideButton: () => Promise<_angular_cdk_testing.TestElement | null>;
|
|
106
|
+
_nextSlideButton: () => Promise<_angular_cdk_testing.TestElement | null>;
|
|
107
|
+
_playButton: () => Promise<_angular_cdk_testing.TestElement | null>;
|
|
108
|
+
_pauseButton: () => Promise<_angular_cdk_testing.TestElement | null>;
|
|
109
|
+
activeTileIndex(): Promise<string | null>;
|
|
110
|
+
goToPreviousSlide(): Promise<void>;
|
|
111
|
+
goToNextSlide(): Promise<void>;
|
|
112
|
+
goToSlide(index: number): Promise<void>;
|
|
113
|
+
hasPreviousSlideButton(): Promise<boolean>;
|
|
114
|
+
hasNextSlideButton(): Promise<boolean>;
|
|
115
|
+
hasSlideButton(index: number): Promise<boolean>;
|
|
116
|
+
hasSlideButtons(): Promise<boolean>;
|
|
117
|
+
hasAutoPlayToggleButton(): Promise<boolean>;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
export { TheSeamCarouselComponent, TheSeamCarouselHarness, TheSeamCarouselModule, TheSeamCarouselSlideDirective };
|
package/datatable/index.d.ts
CHANGED
|
@@ -18,7 +18,7 @@ import { Router } from '@angular/router';
|
|
|
18
18
|
import * as i38 from '@theseam/ui-common/confirm-dialog';
|
|
19
19
|
import { SeamConfirmDialogService } from '@theseam/ui-common/confirm-dialog';
|
|
20
20
|
import * as i32 from '@theseam/ui-common/menu';
|
|
21
|
-
import { MenuComponent } from '@theseam/ui-common/menu';
|
|
21
|
+
import { MenuComponent, TheSeamMenuItemHarnessFilters, TheSeamMenuItemHarness } from '@theseam/ui-common/menu';
|
|
22
22
|
import { ThemeTypes } from '@theseam/ui-common/models';
|
|
23
23
|
import * as i43 from '@theseam/ui-common/table-cell-type';
|
|
24
24
|
import { TableCellTypeName, TableCellTypeConfig, TableCellTypeColumn, TableCellTypeExportProps, TheSeamTableCellTypeColumnAlign } from '@theseam/ui-common/table-cell-type';
|
|
@@ -45,9 +45,13 @@ import * as i33 from '@theseam/ui-common/buttons';
|
|
|
45
45
|
import * as i37 from '@angular/cdk/portal';
|
|
46
46
|
import * as i39 from '@theseam/ui-common/popover';
|
|
47
47
|
import * as i40 from '@theseam/ui-common/checkbox';
|
|
48
|
+
import { TheSeamCheckboxHarness } from '@theseam/ui-common/checkbox';
|
|
48
49
|
import * as i41 from '@theseam/ui-common/form-field';
|
|
49
50
|
import * as i45 from '@ng-select/ng-select';
|
|
50
51
|
import * as i46 from '@theseam/ui-common/toggle-group';
|
|
52
|
+
import * as _angular_cdk_testing from '@angular/cdk/testing';
|
|
53
|
+
import { BaseHarnessFilters, ComponentHarness, ComponentHarnessConstructor, HarnessPredicate, ContentContainerComponentHarness } from '@angular/cdk/testing';
|
|
54
|
+
import { TheSeamNgSelectHarness } from '@theseam/ui-common/testing';
|
|
51
55
|
|
|
52
56
|
declare class DatatableActionMenuItemComponent {
|
|
53
57
|
label: string | undefined | null;
|
|
@@ -1391,5 +1395,297 @@ declare class TheSeamDatatableModule {
|
|
|
1391
1395
|
static ɵinj: i0.ɵɵInjectorDeclaration<TheSeamDatatableModule>;
|
|
1392
1396
|
}
|
|
1393
1397
|
|
|
1394
|
-
|
|
1395
|
-
|
|
1398
|
+
declare const SIMPLE_COLUMNS: TheSeamDatatableColumn[];
|
|
1399
|
+
declare const SIMPLE_ROWS: {
|
|
1400
|
+
name: string;
|
|
1401
|
+
age: number;
|
|
1402
|
+
color: string;
|
|
1403
|
+
}[];
|
|
1404
|
+
declare const FILTERABLE_COLUMNS: TheSeamDatatableColumn[];
|
|
1405
|
+
declare const FILTERABLE_ROWS: ({
|
|
1406
|
+
name: string;
|
|
1407
|
+
age: any;
|
|
1408
|
+
color: string;
|
|
1409
|
+
candy: string;
|
|
1410
|
+
candyAttributes: string[];
|
|
1411
|
+
startDate: string;
|
|
1412
|
+
} | {
|
|
1413
|
+
name: string;
|
|
1414
|
+
age: null;
|
|
1415
|
+
color: null;
|
|
1416
|
+
candy: null;
|
|
1417
|
+
candyAttributes: undefined;
|
|
1418
|
+
startDate: null;
|
|
1419
|
+
})[];
|
|
1420
|
+
declare function createRows(count: number): {
|
|
1421
|
+
name: string;
|
|
1422
|
+
age: number;
|
|
1423
|
+
color: string;
|
|
1424
|
+
}[];
|
|
1425
|
+
|
|
1426
|
+
type TheSeamDatatableActionMenuHarnessFilters = BaseHarnessFilters;
|
|
1427
|
+
declare class TheSeamDatatableActionMenuHarness extends ComponentHarness {
|
|
1428
|
+
static hostSelector: string;
|
|
1429
|
+
static with<T extends TheSeamDatatableActionMenuHarness>(this: ComponentHarnessConstructor<T>, options?: TheSeamDatatableActionMenuHarnessFilters): HarnessPredicate<T>;
|
|
1430
|
+
private _getMenuHarness;
|
|
1431
|
+
/** Whether the action menu is open. */
|
|
1432
|
+
isOpen(): Promise<boolean>;
|
|
1433
|
+
/** Opens the action menu. */
|
|
1434
|
+
open(): Promise<void>;
|
|
1435
|
+
/** Closes the action menu. */
|
|
1436
|
+
close(): Promise<void>;
|
|
1437
|
+
/**
|
|
1438
|
+
* Gets the menu items in the action menu.
|
|
1439
|
+
* The menu must be opened first (call `open()`) or use `clickItem()` which opens automatically.
|
|
1440
|
+
*/
|
|
1441
|
+
getItems(filters?: Omit<TheSeamMenuItemHarnessFilters, 'ancestor'>): Promise<TheSeamMenuItemHarness[]>;
|
|
1442
|
+
/**
|
|
1443
|
+
* Opens the menu and clicks an item by text.
|
|
1444
|
+
* Supports sub-menu navigation via additional filter arguments.
|
|
1445
|
+
*/
|
|
1446
|
+
clickItem(itemFilter: Omit<TheSeamMenuItemHarnessFilters, 'ancestor'>, ...subItemFilters: Omit<TheSeamMenuItemHarnessFilters, 'ancestor'>[]): Promise<void>;
|
|
1447
|
+
}
|
|
1448
|
+
|
|
1449
|
+
interface TheSeamDatatableCellHarnessFilters extends BaseHarnessFilters {
|
|
1450
|
+
/** Filters based on the text content of the cell. */
|
|
1451
|
+
text?: string | RegExp;
|
|
1452
|
+
}
|
|
1453
|
+
declare class TheSeamDatatableCellHarness extends ComponentHarness {
|
|
1454
|
+
static hostSelector: string;
|
|
1455
|
+
static with<T extends TheSeamDatatableCellHarness>(this: ComponentHarnessConstructor<T>, options?: TheSeamDatatableCellHarnessFilters): HarnessPredicate<T>;
|
|
1456
|
+
/** Gets the text content of the cell. */
|
|
1457
|
+
getText(): Promise<string>;
|
|
1458
|
+
/** Clicks the cell. */
|
|
1459
|
+
click(): Promise<void>;
|
|
1460
|
+
/**
|
|
1461
|
+
* Gets a child harness of the given type from within this cell.
|
|
1462
|
+
* Useful for retrieving cell-type harnesses (e.g., currency, date, icon).
|
|
1463
|
+
*
|
|
1464
|
+
* Returns `null` if no matching harness is found.
|
|
1465
|
+
*/
|
|
1466
|
+
getCellTypeHarness<T extends ComponentHarness>(harnessType: ComponentHarnessConstructor<T>): Promise<T | null>;
|
|
1467
|
+
}
|
|
1468
|
+
|
|
1469
|
+
type TheSeamDatatableColumnFilterMenuHarnessFilters = BaseHarnessFilters;
|
|
1470
|
+
declare class TheSeamDatatableColumnFilterMenuHarness extends ComponentHarness {
|
|
1471
|
+
static hostSelector: string;
|
|
1472
|
+
static with<T extends TheSeamDatatableColumnFilterMenuHarness>(this: ComponentHarnessConstructor<T>, options?: TheSeamDatatableColumnFilterMenuHarnessFilters): HarnessPredicate<T>;
|
|
1473
|
+
/** Gets the filter type by checking which sub-component is rendered. */
|
|
1474
|
+
getFilterType(): Promise<'search-text' | 'search-numeric' | 'search-date' | 'custom'>;
|
|
1475
|
+
/** Gets the search type ng-select harness. */
|
|
1476
|
+
getSearchTypeSelect(): Promise<TheSeamNgSelectHarness>;
|
|
1477
|
+
/** Gets the current search type value (e.g. "Contains", "Equals", "Between"). */
|
|
1478
|
+
getSearchType(): Promise<string | null>;
|
|
1479
|
+
/**
|
|
1480
|
+
* Selects a search type from the dropdown by its displayed label
|
|
1481
|
+
* (e.g. `'Before'`, `'Contains'`, `'Between'`).
|
|
1482
|
+
*
|
|
1483
|
+
* Note: this matches the visible option text, not the underlying form value
|
|
1484
|
+
* (e.g. pass `'Before'` not `'lt'`).
|
|
1485
|
+
*/
|
|
1486
|
+
selectSearchType(label: string | RegExp): Promise<void>;
|
|
1487
|
+
/** Gets the primary search input (formControlName="searchText"). */
|
|
1488
|
+
getSearchInput(): Promise<_angular_cdk_testing.TestElement | null>;
|
|
1489
|
+
/** Gets the range start input (formControlName="fromText"). */
|
|
1490
|
+
getRangeStartInput(): Promise<_angular_cdk_testing.TestElement | null>;
|
|
1491
|
+
/** Gets the range end input (formControlName="toText"). */
|
|
1492
|
+
getRangeEndInput(): Promise<_angular_cdk_testing.TestElement | null>;
|
|
1493
|
+
/**
|
|
1494
|
+
* Sets the primary search value.
|
|
1495
|
+
* Clears any existing value first, then types the new value.
|
|
1496
|
+
*/
|
|
1497
|
+
setSearchValue(value: string): Promise<void>;
|
|
1498
|
+
/**
|
|
1499
|
+
* Sets the range values (for "Between" search types on numeric/date filters).
|
|
1500
|
+
*/
|
|
1501
|
+
setRangeValues(from: string, to: string): Promise<void>;
|
|
1502
|
+
/** Clicks the "Clear" button to reset the filter. */
|
|
1503
|
+
clear(): Promise<void>;
|
|
1504
|
+
/** Clicks the "Apply" button (only present in submit mode). */
|
|
1505
|
+
apply(): Promise<void>;
|
|
1506
|
+
/** Whether the "Apply" button is present (submit mode). */
|
|
1507
|
+
hasApplyButton(): Promise<boolean>;
|
|
1508
|
+
/** Whether the "Clear" button is disabled (filter is already at default). */
|
|
1509
|
+
isClearDisabled(): Promise<boolean>;
|
|
1510
|
+
}
|
|
1511
|
+
|
|
1512
|
+
type TheSeamDatatableColumnPreferencesButtonHarnessFilters = BaseHarnessFilters;
|
|
1513
|
+
declare class TheSeamDatatableColumnPreferencesButtonHarness extends ComponentHarness {
|
|
1514
|
+
static hostSelector: string;
|
|
1515
|
+
private _documentRootLocator;
|
|
1516
|
+
static with<T extends TheSeamDatatableColumnPreferencesButtonHarness>(this: ComponentHarnessConstructor<T>, options?: TheSeamDatatableColumnPreferencesButtonHarnessFilters): HarnessPredicate<T>;
|
|
1517
|
+
private _getMenuHarness;
|
|
1518
|
+
/** Opens the preferences menu by clicking the button. */
|
|
1519
|
+
open(): Promise<void>;
|
|
1520
|
+
/** Closes the preferences menu. */
|
|
1521
|
+
close(): Promise<void>;
|
|
1522
|
+
/** Whether the preferences menu is open. */
|
|
1523
|
+
isOpen(): Promise<boolean>;
|
|
1524
|
+
/**
|
|
1525
|
+
* Opens the "Show/Hide Columns" popover and returns the checkbox harnesses
|
|
1526
|
+
* for each column. The checkboxes are rendered inside a CDK overlay popover.
|
|
1527
|
+
*/
|
|
1528
|
+
getColumnCheckboxes(): Promise<TheSeamCheckboxHarness[]>;
|
|
1529
|
+
/**
|
|
1530
|
+
* Toggles a column's visibility by name.
|
|
1531
|
+
* Opens the Show/Hide Columns popover and clicks the matching checkbox.
|
|
1532
|
+
*/
|
|
1533
|
+
toggleColumn(name: string | RegExp): Promise<void>;
|
|
1534
|
+
/** Clicks the "Reset Columns" menu item. */
|
|
1535
|
+
resetColumns(): Promise<void>;
|
|
1536
|
+
}
|
|
1537
|
+
|
|
1538
|
+
type TheSeamDatatableExportButtonHarnessFilters = BaseHarnessFilters;
|
|
1539
|
+
declare class TheSeamDatatableExportButtonHarness extends ComponentHarness {
|
|
1540
|
+
static hostSelector: string;
|
|
1541
|
+
static with<T extends TheSeamDatatableExportButtonHarness>(this: ComponentHarnessConstructor<T>, options?: TheSeamDatatableExportButtonHarnessFilters): HarnessPredicate<T>;
|
|
1542
|
+
private _getMenuHarness;
|
|
1543
|
+
/** Opens the export menu. */
|
|
1544
|
+
open(): Promise<void>;
|
|
1545
|
+
/** Closes the export menu. */
|
|
1546
|
+
close(): Promise<void>;
|
|
1547
|
+
/** Whether the export menu is open. */
|
|
1548
|
+
isOpen(): Promise<boolean>;
|
|
1549
|
+
/** Whether the export button is disabled. */
|
|
1550
|
+
isDisabled(): Promise<boolean>;
|
|
1551
|
+
/** Gets the exporter menu items. The menu must be opened first or use `clickExporter()`. */
|
|
1552
|
+
getExporters(filters?: Omit<TheSeamMenuItemHarnessFilters, 'ancestor'>): Promise<TheSeamMenuItemHarness[]>;
|
|
1553
|
+
/** Opens the menu and clicks an exporter by label. */
|
|
1554
|
+
clickExporter(label: string | RegExp): Promise<void>;
|
|
1555
|
+
}
|
|
1556
|
+
|
|
1557
|
+
type SortDirection = 'asc' | 'desc' | 'none';
|
|
1558
|
+
interface TheSeamDatatableHeaderCellHarnessFilters extends BaseHarnessFilters {
|
|
1559
|
+
/** Filters based on the column name text. */
|
|
1560
|
+
name?: string | RegExp;
|
|
1561
|
+
/** Filters based on the sort direction. */
|
|
1562
|
+
sortDirection?: SortDirection;
|
|
1563
|
+
}
|
|
1564
|
+
declare class TheSeamDatatableHeaderCellHarness extends ComponentHarness {
|
|
1565
|
+
static hostSelector: string;
|
|
1566
|
+
static with<T extends TheSeamDatatableHeaderCellHarness>(this: ComponentHarnessConstructor<T>, options?: TheSeamDatatableHeaderCellHarnessFilters): HarnessPredicate<T>;
|
|
1567
|
+
/** Gets the column name text. */
|
|
1568
|
+
getName(): Promise<string>;
|
|
1569
|
+
/** Gets the current sort direction of this column. */
|
|
1570
|
+
getSortDirection(): Promise<SortDirection>;
|
|
1571
|
+
/** Whether this column is sortable. */
|
|
1572
|
+
isSortable(): Promise<boolean>;
|
|
1573
|
+
/** Clicks the sort button to cycle the sort direction. */
|
|
1574
|
+
sort(): Promise<void>;
|
|
1575
|
+
/** Whether this column has a filter button. */
|
|
1576
|
+
isFilterable(): Promise<boolean>;
|
|
1577
|
+
/** Whether the column filter is currently active. */
|
|
1578
|
+
isFilterActive(): Promise<boolean>;
|
|
1579
|
+
/** Opens the column filter menu by clicking the filter button. */
|
|
1580
|
+
openFilter(): Promise<void>;
|
|
1581
|
+
/**
|
|
1582
|
+
* Opens the filter and returns the filter menu harness.
|
|
1583
|
+
* The filter menu renders in a CDK overlay, so this uses the document root locator.
|
|
1584
|
+
*/
|
|
1585
|
+
getFilterMenu(): Promise<TheSeamDatatableColumnFilterMenuHarness>;
|
|
1586
|
+
/** Whether this header cell is a checkbox column (select-all). */
|
|
1587
|
+
isCheckboxColumn(): Promise<boolean>;
|
|
1588
|
+
/** Clicks the select-all checkbox in this header cell. */
|
|
1589
|
+
clickCheckbox(): Promise<void>;
|
|
1590
|
+
}
|
|
1591
|
+
|
|
1592
|
+
type TheSeamDatatableMenuBarHarnessFilters = BaseHarnessFilters;
|
|
1593
|
+
declare class TheSeamDatatableMenuBarHarness extends ContentContainerComponentHarness<string> {
|
|
1594
|
+
static hostSelector: string;
|
|
1595
|
+
static with<T extends TheSeamDatatableMenuBarHarness>(this: ComponentHarnessConstructor<T>, options?: TheSeamDatatableMenuBarHarnessFilters): HarnessPredicate<T>;
|
|
1596
|
+
/** Gets the text content of the menu bar. */
|
|
1597
|
+
getTextContent(): Promise<string>;
|
|
1598
|
+
}
|
|
1599
|
+
|
|
1600
|
+
interface TheSeamDatatablePagerButtonHarnessFilters extends BaseHarnessFilters {
|
|
1601
|
+
/** Filters based on the page number of the button. */
|
|
1602
|
+
pageNumber?: number | string | RegExp | null;
|
|
1603
|
+
}
|
|
1604
|
+
declare class TheSeamDatatablePagerButtonHarness extends ComponentHarness {
|
|
1605
|
+
static hostSelector: string;
|
|
1606
|
+
/** Creates a `HarnessPredicate` used to locate a particular `MyMenuHarness`. */
|
|
1607
|
+
static with(options: TheSeamDatatablePagerButtonHarnessFilters): HarnessPredicate<TheSeamDatatablePagerButtonHarness>;
|
|
1608
|
+
getLabel(): Promise<string | null>;
|
|
1609
|
+
getAnchor(): Promise<_angular_cdk_testing.TestElement>;
|
|
1610
|
+
}
|
|
1611
|
+
|
|
1612
|
+
declare class TheSeamDatatablePagerHarness extends ComponentHarness {
|
|
1613
|
+
static hostSelector: string;
|
|
1614
|
+
private readonly _activePageButton;
|
|
1615
|
+
getPageButtonHarness(pageNumber: number): Promise<TheSeamDatatablePagerButtonHarness>;
|
|
1616
|
+
getCurrentPageNumber(): Promise<number>;
|
|
1617
|
+
}
|
|
1618
|
+
|
|
1619
|
+
interface TheSeamDatatableRowHarnessFilters extends BaseHarnessFilters {
|
|
1620
|
+
/** Filters based on whether the row is selected. */
|
|
1621
|
+
selected?: boolean;
|
|
1622
|
+
}
|
|
1623
|
+
declare class TheSeamDatatableRowHarness extends ComponentHarness {
|
|
1624
|
+
static hostSelector: string;
|
|
1625
|
+
static with<T extends TheSeamDatatableRowHarness>(this: ComponentHarnessConstructor<T>, options?: TheSeamDatatableRowHarnessFilters): HarnessPredicate<T>;
|
|
1626
|
+
/** Gets all cells in this row, optionally filtered. */
|
|
1627
|
+
getCells(filters?: TheSeamDatatableCellHarnessFilters): Promise<TheSeamDatatableCellHarness[]>;
|
|
1628
|
+
/** Gets a cell by its index in the row. */
|
|
1629
|
+
getCell(index: number): Promise<TheSeamDatatableCellHarness>;
|
|
1630
|
+
/** Convenience method to get the text content of a cell by index. */
|
|
1631
|
+
getCellText(index: number): Promise<string>;
|
|
1632
|
+
/** Whether this row is selected. */
|
|
1633
|
+
isSelected(): Promise<boolean>;
|
|
1634
|
+
/** Clicks the row to activate it. */
|
|
1635
|
+
click(): Promise<void>;
|
|
1636
|
+
/** Gets the action menu harness for this row, or `null` if no action menu exists. */
|
|
1637
|
+
getActionMenu(): Promise<TheSeamDatatableActionMenuHarness | null>;
|
|
1638
|
+
/** Whether this row's detail section is expanded. */
|
|
1639
|
+
isExpanded(): Promise<boolean>;
|
|
1640
|
+
/** Gets the row detail content element, or `null` if not expanded. */
|
|
1641
|
+
getDetailContent(): Promise<_angular_cdk_testing.TestElement | null>;
|
|
1642
|
+
/** Whether this row has a selection checkbox. */
|
|
1643
|
+
hasCheckbox(): Promise<boolean>;
|
|
1644
|
+
/** Clicks the selection checkbox on this row. */
|
|
1645
|
+
clickCheckbox(): Promise<void>;
|
|
1646
|
+
}
|
|
1647
|
+
|
|
1648
|
+
type TheSeamDatatableHarnessFilters = BaseHarnessFilters;
|
|
1649
|
+
declare class TheSeamDatatableHarness extends ComponentHarness {
|
|
1650
|
+
static hostSelector: string;
|
|
1651
|
+
static with<T extends TheSeamDatatableHarness>(this: ComponentHarnessConstructor<T>, options?: TheSeamDatatableHarnessFilters): HarnessPredicate<T>;
|
|
1652
|
+
private readonly _pager;
|
|
1653
|
+
getCurrentPage(): Promise<number>;
|
|
1654
|
+
getPager(): Promise<TheSeamDatatablePagerHarness | null>;
|
|
1655
|
+
/** Gets all visible body rows, optionally filtered. */
|
|
1656
|
+
getRows(filters?: TheSeamDatatableRowHarnessFilters): Promise<TheSeamDatatableRowHarness[]>;
|
|
1657
|
+
/** Gets a body row by its index. */
|
|
1658
|
+
getRow(index: number): Promise<TheSeamDatatableRowHarness>;
|
|
1659
|
+
/** Gets the number of visible body rows. */
|
|
1660
|
+
getRowCount(): Promise<number>;
|
|
1661
|
+
/** Gets all header cells, optionally filtered. */
|
|
1662
|
+
getHeaderCells(filters?: TheSeamDatatableHeaderCellHarnessFilters): Promise<TheSeamDatatableHeaderCellHarness[]>;
|
|
1663
|
+
/** Gets a header cell by column name. */
|
|
1664
|
+
getHeaderCell(name: string | RegExp): Promise<TheSeamDatatableHeaderCellHarness>;
|
|
1665
|
+
/** Gets the number of visible columns. */
|
|
1666
|
+
getColumnCount(): Promise<number>;
|
|
1667
|
+
/** Gets all currently selected rows. */
|
|
1668
|
+
getSelectedRows(): Promise<TheSeamDatatableRowHarness[]>;
|
|
1669
|
+
/** Gets the menu bar harness, or `null` if no menu bar is present. */
|
|
1670
|
+
getMenuBar(): Promise<TheSeamDatatableMenuBarHarness | null>;
|
|
1671
|
+
/** Gets the column preferences button harness, or `null` if not present. */
|
|
1672
|
+
getColumnPreferencesButton(): Promise<TheSeamDatatableColumnPreferencesButtonHarness | null>;
|
|
1673
|
+
/** Gets the text content of a cell by row and column index. */
|
|
1674
|
+
getCellText(rowIndex: number, colIndex: number): Promise<string>;
|
|
1675
|
+
/** Whether the table is showing its empty message (no rows). */
|
|
1676
|
+
isEmpty(): Promise<boolean>;
|
|
1677
|
+
}
|
|
1678
|
+
|
|
1679
|
+
type TheSeamDatatableRefreshButtonHarnessFilters = BaseHarnessFilters;
|
|
1680
|
+
declare class TheSeamDatatableRefreshButtonHarness extends ComponentHarness {
|
|
1681
|
+
static hostSelector: string;
|
|
1682
|
+
static with<T extends TheSeamDatatableRefreshButtonHarness>(this: ComponentHarnessConstructor<T>, options?: TheSeamDatatableRefreshButtonHarnessFilters): HarnessPredicate<T>;
|
|
1683
|
+
private readonly _button;
|
|
1684
|
+
/** Clicks the refresh button. */
|
|
1685
|
+
click(): Promise<void>;
|
|
1686
|
+
/** Whether the underlying button is disabled. */
|
|
1687
|
+
isDisabled(): Promise<boolean>;
|
|
1688
|
+
}
|
|
1689
|
+
|
|
1690
|
+
export { CURRENT_DATATABLE_PREFERENCES_VERSION, ColumnsAlteration, ColumnsDataFilter, ColumnsFiltersService, DatatableActionMenuComponent, DatatableActionMenuItemComponent, DatatableActionMenuItemDirective, DatatableActionMenuToggleDirective, DatatableCellTplDirective, DatatableColumnChangesService, DatatableColumnComponent, DatatableColumnFilterMenuComponent, DatatableColumnFilterSearchDateComponent, DatatableColumnFilterSearchNumericComponent, DatatableColumnFilterSearchTextComponent, DatatableColumnFilterTplDirective, DatatableColumnPreferencesButtonComponent, DatatableColumnPreferencesComponent, DatatableComponent, DatatableDataSource, DatatableExportButtonComponent, DatatableFilterDirective, DatatableFooterTplDirective, DatatableGqlDataSource, DatatableMenuBarColumnCenterComponent, DatatableMenuBarColumnLeftComponent, DatatableMenuBarColumnRightComponent, DatatableMenuBarComponent, DatatableMenuBarRowComponent, DatatableMenuBarTextComponent, DatatablePreferencesService, DatatableRefreshButtonComponent, DatatableRefreshService, DatatableRowActionItemDirective, DatatableRowDetailTplDirective, EMPTY_DATATABLE_PREFERENCES, FILTERABLE_COLUMNS, FILTERABLE_ROWS, SIMPLE_COLUMNS, SIMPLE_ROWS, SearchDateColumnsDataFilter, SearchNumericColumnsDataFilter, SearchTextColumnsDataFilter, THESEAM_COLUMNS_DATA_FILTER, THESEAM_COLUMNS_DATA_FILTERS_DEFAULT, THESEAM_COLUMNS_DATA_FILTER_DATE_RANGE_SEARCH_TYPES, THESEAM_COLUMNS_DATA_FILTER_DATE_SEARCH_NAME, THESEAM_COLUMNS_DATA_FILTER_DATE_SEARCH_TYPES, THESEAM_COLUMNS_DATA_FILTER_DATE_SELECT_SEARCH_TYPES, THESEAM_COLUMNS_DATA_FILTER_DATE_TEXT_SEARCH_TYPES, THESEAM_COLUMNS_DATA_FILTER_NUMERIC_RANGE_SEARCH_TYPES, THESEAM_COLUMNS_DATA_FILTER_NUMERIC_SEARCH_NAME, THESEAM_COLUMNS_DATA_FILTER_NUMERIC_SEARCH_TYPES, THESEAM_COLUMNS_DATA_FILTER_NUMERIC_SELECT_SEARCH_TYPES, THESEAM_COLUMNS_DATA_FILTER_NUMERIC_TEXT_SEARCH_TYPES, THESEAM_COLUMNS_DATA_FILTER_TEXT_SEARCH_NAME, THESEAM_COLUMNS_DATA_FILTER_TEXT_SEARCH_TYPES, THESEAM_COLUMNS_DATA_FILTER_TEXT_SELECT_SEARCH_TYPES, THESEAM_COLUMNS_DATA_FILTER_TEXT_TEXT_SEARCH_TYPES, THESEAM_DATATABLE, THESEAM_DATATABLE_CONFIG, THESEAM_DATATABLE_PREFERENCES_ACCESSOR, THESEAM_MENUBAR_ITEM_DATA, TheSeamDatatableActionMenuHarness, TheSeamDatatableCellHarness, TheSeamDatatableColumnFilterDirective, TheSeamDatatableColumnFilterMenuHarness, TheSeamDatatableColumnPreferencesButtonHarness, TheSeamDatatableExportButtonHarness, TheSeamDatatableFooterDirective, TheSeamDatatableHarness, TheSeamDatatableHeaderCellHarness, TheSeamDatatableMenuBarHarness, TheSeamDatatableModule, TheSeamDatatablePagerButtonHarness, TheSeamDatatablePagerHarness, TheSeamDatatableRefreshButtonHarness, TheSeamDatatableRowDetailDirective, TheSeamDatatableRowHarness, TheSeamDatatableScrollbarHelperService, _THESEAM_DATATABLE, _THESEAM_DATATABLE_ACCESSOR, _THESEAM_DATA_FILTER_CONTAINER, createRows, getFormattedDateForComparison, isColumnBoundToProp, mapColumnsAlterationsStates, withStoredColumnInfo };
|
|
1691
|
+
export type { ColumnsAlterationState, ColumnsDataFilterState, ColumnsDataFilterStateState, ICellContext, IDatatableExportButtonData, MenubarItemData, SortDirection, SortEvent, SortItem, TheSeamColumnsDataFilterDateSearchDateType, TheSeamColumnsDataFilterDateSearchForm, TheSeamColumnsDataFilterDateSearchFormState, TheSeamColumnsDataFilterDateSearchOptions, TheSeamColumnsDataFilterDateSearchType, TheSeamColumnsDataFilterNumericSearchForm, TheSeamColumnsDataFilterNumericSearchFormState, TheSeamColumnsDataFilterNumericSearchType, TheSeamColumnsDataFilterTextSearchForm, TheSeamColumnsDataFilterTextSearchFormState, TheSeamColumnsDataFilterTextSearchType, TheSeamDatatableAccessor, TheSeamDatatableActionMenuHarnessFilters, TheSeamDatatableCellHarnessFilters, TheSeamDatatableColumn, TheSeamDatatableColumnFilterMenuHarnessFilters, TheSeamDatatableColumnFilterUpdateMethod, TheSeamDatatableColumnFilterable, TheSeamDatatableColumnFilterableConfig, TheSeamDatatableColumnHidable, TheSeamDatatableColumnPreferencesButtonHarnessFilters, TheSeamDatatableConfig, TheSeamDatatableDateColumnFilterableConfig, TheSeamDatatableExportButtonHarnessFilters, TheSeamDatatableHarnessFilters, TheSeamDatatableHeaderCellHarnessFilters, TheSeamDatatableMenuBarHarnessFilters, TheSeamDatatableMessages, TheSeamDatatablePreferences, TheSeamDatatablePreferencesAccessor, TheSeamDatatablePreferencesColumn, TheSeamDatatablePreferences_v1, TheSeamDatatablePreferences_v2, TheSeamDatatableRefreshButtonHarnessFilters, TheSeamDatatableRow, TheSeamDatatableRowHarnessFilters, TheSeamPageInfo };
|