@testgorilla/tgo-ui 11.0.1 → 11.0.2
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/fesm2022/testgorilla-tgo-ui-components-infinite-scroll-table.mjs +103 -15
- package/fesm2022/testgorilla-tgo-ui-components-infinite-scroll-table.mjs.map +1 -1
- package/mcp/catalog.json +1 -1
- package/package.json +1 -1
- package/types/testgorilla-tgo-ui-components-infinite-scroll-table.d.ts +35 -5
package/package.json
CHANGED
|
@@ -156,8 +156,23 @@ declare class InfiniteScrollTableComponent<T> {
|
|
|
156
156
|
* the last — aligned between header and body regardless of browser/scrollbar behaviour.
|
|
157
157
|
*/
|
|
158
158
|
protected readonly scrollbarWidth: _angular_core.WritableSignal<number>;
|
|
159
|
+
/**
|
|
160
|
+
* Measured height (px) of the body viewport's horizontal scrollbar. When a short list also has a
|
|
161
|
+
* horizontal scrollbar, this is added to the viewport height so the scrollbar doesn't eat into the
|
|
162
|
+
* rows' vertical space and force a spurious vertical scrollbar. Mirrors `scrollbarWidth`.
|
|
163
|
+
*/
|
|
164
|
+
protected readonly hScrollbarHeight: _angular_core.WritableSignal<number>;
|
|
159
165
|
/** Guards `loadMore` to a single emission per approach to the end. */
|
|
160
166
|
private loadMoreArmed;
|
|
167
|
+
/** Pending frame for a deferred CDK viewport re-measure, so repeated triggers coalesce to one. */
|
|
168
|
+
private remeasureFrame;
|
|
169
|
+
/**
|
|
170
|
+
* True when the browser can drive the header via a CSS scroll timeline (see the SCSS): the header
|
|
171
|
+
* then tracks the body's horizontal scroll on the compositor, with no per-frame main-thread work.
|
|
172
|
+
* In that case the JS `scrollLeft` sync is skipped so the offset isn't applied twice; it stays as
|
|
173
|
+
* the fallback for browsers without scroll-driven animations.
|
|
174
|
+
*/
|
|
175
|
+
private readonly usesScrollTimelineHeaderSync;
|
|
161
176
|
protected readonly skeletonTheme: {
|
|
162
177
|
background: string;
|
|
163
178
|
'border-radius': string;
|
|
@@ -174,7 +189,12 @@ declare class InfiniteScrollTableComponent<T> {
|
|
|
174
189
|
protected readonly showEmptyState: _angular_core.Signal<boolean>;
|
|
175
190
|
protected readonly showErrorState: _angular_core.Signal<boolean>;
|
|
176
191
|
protected readonly showErrorFooter: _angular_core.Signal<boolean>;
|
|
177
|
-
/**
|
|
192
|
+
/**
|
|
193
|
+
* Viewport height shrinks to the content and is capped at `maxHeight` (CSS `min()` mixes units).
|
|
194
|
+
* When a horizontal scrollbar is present it reserves that scrollbar's measured height on top of the
|
|
195
|
+
* content, so a short list doesn't overflow and grow a spurious vertical scrollbar. Still capped at
|
|
196
|
+
* `maxHeight`.
|
|
197
|
+
*/
|
|
178
198
|
protected readonly viewportHeight: _angular_core.Signal<string>;
|
|
179
199
|
/** Screen-reader announcement for the busy states. */
|
|
180
200
|
protected readonly statusMessage: _angular_core.Signal<"Loading" | "Loading more rows" | "">;
|
|
@@ -183,11 +203,13 @@ declare class InfiniteScrollTableComponent<T> {
|
|
|
183
203
|
constructor();
|
|
184
204
|
protected getCellValue(item: T, key: string): unknown;
|
|
185
205
|
/**
|
|
186
|
-
*
|
|
187
|
-
* default.
|
|
188
|
-
*
|
|
206
|
+
* The single authoritative width for a column: its declared width, else its min-width, else the
|
|
207
|
+
* default. The template applies this identically as `flex-basis`, `min-width` AND `max-width` (with
|
|
208
|
+
* `flex-grow:0; flex-shrink:0; overflow:hidden`) to the header cell and every body cell, so a column
|
|
209
|
+
* is exactly this width in both containers — content is clipped and can never widen it. This is what
|
|
210
|
+
* keeps header and body columns aligned end-to-end regardless of cell content or horizontal scroll.
|
|
189
211
|
*/
|
|
190
|
-
protected
|
|
212
|
+
protected columnWidth(column: InfiniteScrollTableColumn<T>): string;
|
|
191
213
|
protected onRowClick(row: RenderRow<T>): void;
|
|
192
214
|
/**
|
|
193
215
|
* Whether a row should show the selected highlight. Mirrors `ui-table`: only when `selectable` is
|
|
@@ -203,6 +225,14 @@ declare class InfiniteScrollTableComponent<T> {
|
|
|
203
225
|
protected stickyStartOffset(column: InfiniteScrollTableColumn<T>): number | null;
|
|
204
226
|
/** Keyboard equivalent of a row click (Enter/Space) for the currently focused data row. */
|
|
205
227
|
protected onRowActivate(event: Event, row: RenderRow<T>): void;
|
|
228
|
+
/**
|
|
229
|
+
* Re-measure the CDK virtual viewport after its box may have changed. Deferred to the next frame so
|
|
230
|
+
* it reads the settled layout and never fires a "ResizeObserver loop limit exceeded" warning when
|
|
231
|
+
* driven from the ResizeObserver; repeated triggers coalesce to a single measure. The re-measure is
|
|
232
|
+
* what makes CDK recompute the rendered range to fill a viewport whose height grew at runtime.
|
|
233
|
+
*/
|
|
234
|
+
private scheduleViewportRemeasure;
|
|
235
|
+
private updateHeaderScrollMetric;
|
|
206
236
|
private onRetry;
|
|
207
237
|
/** Keep the header horizontally aligned with the body and update the sticky-shadow state. */
|
|
208
238
|
private syncHorizontalScroll;
|