@shival99/z-ui 2.6.0 → 2.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shival99/z-ui",
3
- "version": "2.6.0",
3
+ "version": "2.6.1",
4
4
  "description": "Z-UI: Modern Angular UI Component Library - A comprehensive, high-performance design system built with Angular 22, featuring 45+ customizable components with dark mode, accessibility, and enterprise-ready features.",
5
5
  "keywords": [
6
6
  "angular",
@@ -24,7 +24,8 @@ declare const zEditorVariants: (props?: ({
24
24
  type ZEditorVariants = VariantProps<typeof zEditorVariants>;
25
25
  type ZEditorSize = 'sm' | 'default' | 'lg';
26
26
  type ZEditorContentType = 'html' | 'json' | 'markdown';
27
- type ZEditorToolbarCommand = 'bold' | 'italic' | 'underline' | 'strike' | 'code' | 'blockStyle' | 'heading1' | 'heading2' | 'heading3' | 'heading4' | 'small' | 'paragraph' | 'bulletList' | 'orderedList' | 'blockquote' | 'codeBlock' | 'horizontalRule' | 'link' | 'image' | 'emoji' | 'textColor' | 'backgroundColor' | 'align' | 'alignLeft' | 'alignCenter' | 'alignRight' | 'alignJustify' | 'undo' | 'redo' | 'clearFormatting';
27
+ type ZEditorLineHeight = '1' | '1.15' | '1.5' | '1.75' | '2';
28
+ type ZEditorToolbarCommand = 'bold' | 'italic' | 'underline' | 'strike' | 'code' | 'blockStyle' | 'heading1' | 'heading2' | 'heading3' | 'heading4' | 'small' | 'paragraph' | 'bulletList' | 'orderedList' | 'blockquote' | 'codeBlock' | 'lineHeight' | 'horizontalRule' | 'link' | 'image' | 'emoji' | 'textColor' | 'backgroundColor' | 'align' | 'alignLeft' | 'alignCenter' | 'alignRight' | 'alignJustify' | 'undo' | 'redo' | 'clearFormatting';
28
29
  interface ZEditorToolbarItem {
29
30
  id: ZEditorToolbarCommand;
30
31
  icon: ZIcon;
@@ -166,6 +167,7 @@ declare class ZEditorComponent implements OnInit, ControlValueAccessor {
166
167
  protected readonly linkValidators: ZInputValidator[];
167
168
  protected readonly textColorSwatches: readonly string[];
168
169
  protected readonly backgroundColorSwatches: readonly string[];
170
+ protected readonly lineHeightOptions: readonly ZEditorLineHeight[];
169
171
  protected readonly slashCommands: readonly ZEditorSlashCommandItem[];
170
172
  protected readonly blockStyleOptions: readonly {
171
173
  command: Extract<ZEditorToolbarCommand, 'paragraph' | 'heading1' | 'heading2' | 'heading3' | 'heading4'>;
@@ -195,6 +197,7 @@ declare class ZEditorComponent implements OnInit, ControlValueAccessor {
195
197
  private _alignPopoverControl;
196
198
  private _textColorPopoverControl;
197
199
  private _backgroundColorPopoverControl;
200
+ private _lineHeightPopoverControl;
198
201
  private _slashMenuPopoverControl;
199
202
  private _dismissedSlashMenu;
200
203
  private _linkPopoverControl;
@@ -223,6 +226,7 @@ declare class ZEditorComponent implements OnInit, ControlValueAccessor {
223
226
  protected readonly activeAlign: _angular_core.Signal<"alignLeft" | "alignCenter" | "alignRight" | "alignJustify">;
224
227
  protected readonly activeAlignLabel: _angular_core.Signal<string>;
225
228
  protected readonly activeAlignIcon: _angular_core.Signal<ZIcon>;
229
+ protected readonly activeLineHeight: _angular_core.Signal<ZEditorLineHeight | null>;
226
230
  protected readonly filteredSlashCommands: _angular_core.Signal<ZEditorSlashCommandViewItem[]>;
227
231
  protected readonly canApplyLink: _angular_core.Signal<boolean>;
228
232
  protected readonly effectivePlaceholder: _angular_core.Signal<string>;
@@ -275,12 +279,14 @@ declare class ZEditorComponent implements OnInit, ControlValueAccessor {
275
279
  protected applySlashCommand(item: ZEditorSlashCommandItem): void;
276
280
  protected applyBlockStyle(command: Extract<ZEditorToolbarCommand, 'paragraph' | 'heading1' | 'heading2' | 'heading3' | 'heading4'>, closePopover?: () => void): void;
277
281
  protected applyAlign(command: Extract<ZEditorToolbarCommand, 'alignLeft' | 'alignCenter' | 'alignRight' | 'alignJustify'>, closePopover?: () => void): void;
282
+ protected applyLineHeight(value: ZEditorLineHeight, closePopover?: () => void): void;
278
283
  protected insertEmoji(emoji: string): void;
279
284
  protected setEmojiCategory(categoryId: string): void;
280
285
  protected onEmojiPopoverControl(control: ZPopoverControl): void;
281
286
  protected onEmojiPopoverShow(): void;
282
287
  protected onBlockStylePopoverControl(control: ZPopoverControl): void;
283
288
  protected onAlignPopoverControl(control: ZPopoverControl): void;
289
+ protected onLineHeightPopoverControl(control: ZPopoverControl): void;
284
290
  protected onTextColorPopoverControl(control: ZPopoverControl): void;
285
291
  protected onBackgroundColorPopoverControl(control: ZPopoverControl): void;
286
292
  protected onSlashMenuPopoverControl(control: ZPopoverControl): void;
@@ -325,6 +331,7 @@ declare class ZEditorComponent implements OnInit, ControlValueAccessor {
325
331
  private _getActiveBlockStyle;
326
332
  private _getActiveAlign;
327
333
  private _getActiveAlignFromEditor;
334
+ private _getActiveLineHeight;
328
335
  private _createImageExtension;
329
336
  private static _getImageAlignStyle;
330
337
  private _placeholderConfig;
@@ -336,4 +343,4 @@ declare class ZEditorComponent implements OnInit, ControlValueAccessor {
336
343
  declare const Z_EDITOR_DEFAULT_TOOLBAR: readonly ZEditorToolbarItem[];
337
344
 
338
345
  export { ZEditorComponent, Z_EDITOR_DEFAULT_TOOLBAR, zEditorVariants };
339
- export type { ZEditorContentType, ZEditorControl, ZEditorResolvedToolbarItem, ZEditorSize, ZEditorTipTapOptions, ZEditorToolbarCommand, ZEditorToolbarItem, ZEditorValidator, ZEditorVariants };
346
+ export type { ZEditorContentType, ZEditorControl, ZEditorLineHeight, ZEditorResolvedToolbarItem, ZEditorSize, ZEditorTipTapOptions, ZEditorToolbarCommand, ZEditorToolbarItem, ZEditorValidator, ZEditorVariants };
@@ -35,7 +35,7 @@ import * as _shival99_z_ui_components_z_table from '@shival99/z-ui/components/z-
35
35
  */
36
36
 
37
37
  /** Z-UI's backwards-compatible physical pinning contract. */
38
- interface ColumnPinningState {
38
+ interface ZColumnPinningState {
39
39
  left?: string[];
40
40
  right?: string[];
41
41
  }
@@ -60,6 +60,7 @@ interface ZTableIconPart {
60
60
  strokeWidth?: number;
61
61
  }
62
62
  type ZTableAlign = 'left' | 'center' | 'right';
63
+ type ZTableVerticalAlign = 'top' | 'middle' | 'bottom';
63
64
  type ZTableBodyContentType = 'default' | 'tag';
64
65
  type ZTableColumnType = 'data' | 'select' | 'expand' | 'rowDrag' | 'rowPin' | 'actions';
65
66
  type ZTableTagColor = ZTagColor;
@@ -328,6 +329,12 @@ interface ZTableBodyColumnConfig<T> {
328
329
  class?: string | ((info: CellContext<T, unknown>) => string);
329
330
  style?: Record<string, string> | ((info: CellContext<T, unknown>) => Record<string, string>);
330
331
  align?: ZTableAlign;
332
+ /**
333
+ * Vertical alignment of the cell's content. Defaults to 'top' when the cell has an active
334
+ * rowSpan (merging multiple rows) so tall merged cells stay readable, and to the browser's
335
+ * normal 'middle' otherwise. Set explicitly to center content in a merged cell instead.
336
+ */
337
+ verticalAlign?: ZTableVerticalAlign | ((info: CellContext<T, unknown>) => ZTableVerticalAlign);
331
338
  /** Static rowSpan or function returning 0 to hide the cell (merged into neighbor) */
332
339
  rowSpan?: number | ((info: CellContext<T, unknown>) => number);
333
340
  colSpan?: number | ((info: CellContext<T, unknown>) => number);
@@ -813,7 +820,7 @@ interface ZTableCellEditChange<T> extends ZTableChangeEventBase {
813
820
  type ZTableChangeEvent<T> = ZTablePageChange | ZTableSortChange | ZTableFilterChange | ZTableSearchChange | ZTableSelectChange | ZTableExpandChange | ZTableGroupingChange | ZTableGroupExpandChange | ZTableRowSelectChange<T> | ZTableRowSelectAllChange<T> | ZTableRowExpandChange<T> | ZTableRowDragChange<T> | ZTableRowInsertChange<T> | ZTableRowDeleteChange<T> | ZTableRowCopyChange<T> | ZTableRowPasteChange<T> | ZTableRowMoveChange<T> | ZTableCellClickChange<T> | ZTableCellEditChange<T> | ZTableActionChange<T> | ZTableBulkActionChange<T>;
814
821
  /** Initial table state — applied on first render, before any cached config is loaded */
815
822
  interface ZTableInitialState {
816
- columnPinning?: ColumnPinningState;
823
+ columnPinning?: ZColumnPinningState;
817
824
  rowPinning?: RowPinningState;
818
825
  sorting?: SortingState;
819
826
  columnFilters?: ColumnFiltersState;
@@ -1161,7 +1168,7 @@ declare class ZTableComponent<T> implements AfterViewInit {
1161
1168
  protected readonly expandedRowTemplate: _angular_core.Signal<TemplateRef<unknown> | undefined>;
1162
1169
  protected readonly virtualRowElements: _angular_core.Signal<readonly ElementRef<HTMLDivElement>[]>;
1163
1170
  protected readonly groupRowElements: _angular_core.Signal<readonly ElementRef<HTMLTableRowElement>[]>;
1164
- protected readonly columnPinning: _angular_core.WritableSignal<ColumnPinningState>;
1171
+ protected readonly columnPinning: _angular_core.WritableSignal<ZColumnPinningState>;
1165
1172
  protected readonly columnVisibility: _angular_core.WritableSignal<ColumnVisibilityState>;
1166
1173
  protected readonly columnOrder: _angular_core.WritableSignal<ColumnOrderState>;
1167
1174
  protected readonly expanded: _angular_core.WritableSignal<ExpandedState>;
@@ -1239,6 +1246,10 @@ declare class ZTableComponent<T> implements AfterViewInit {
1239
1246
  protected readonly showHorizontalBorder: _angular_core.WritableSignal<boolean>;
1240
1247
  protected readonly showVerticalBorder: _angular_core.WritableSignal<boolean>;
1241
1248
  protected readonly showHeaderFooterShadow: _angular_core.WritableSignal<boolean>;
1249
+ /** True when the body viewport is at its top boundary. */
1250
+ protected readonly isBodyAtTop: _angular_core.WritableSignal<boolean>;
1251
+ /** True when the body viewport is at its bottom boundary. */
1252
+ protected readonly isBodyAtBottom: _angular_core.WritableSignal<boolean>;
1242
1253
  protected readonly bulkBarMounted: _angular_core.WritableSignal<boolean>;
1243
1254
  protected readonly bulkBarClosing: _angular_core.WritableSignal<boolean>;
1244
1255
  protected readonly bulkBarConfig: _angular_core.WritableSignal<ZTableBulkActionOptions<T> | null>;
@@ -2168,7 +2179,7 @@ declare class ZTableFilterComponent<T> {
2168
2179
  protected readonly filterBadgeCount: _angular_core.Signal<number>;
2169
2180
  protected readonly hasFilterValue: _angular_core.Signal<boolean>;
2170
2181
  protected readonly isActive: _angular_core.Signal<boolean>;
2171
- protected readonly draftSortValue: _angular_core.Signal<"none" | "asc" | "desc">;
2182
+ protected readonly draftSortValue: _angular_core.Signal<"asc" | "desc" | "none">;
2172
2183
  protected readonly rangeMinValue: _angular_core.Signal<any>;
2173
2184
  protected readonly rangeMaxValue: _angular_core.Signal<any>;
2174
2185
  protected readonly dateValue: _angular_core.Signal<Date | null>;
@@ -2240,7 +2251,7 @@ declare class ZTableActionsComponent<T = unknown> {
2240
2251
  readonly zConfig: _angular_core.InputSignal<ZTableActionColumnConfig<T>>;
2241
2252
  readonly zRow: _angular_core.InputSignal<T>;
2242
2253
  readonly zRowId: _angular_core.InputSignal<string>;
2243
- readonly zDropdownButtonSize: _angular_core.InputSignal<"sm" | "default" | "lg" | "xs" | "xl" | null | undefined>;
2254
+ readonly zDropdownButtonSize: _angular_core.InputSignal<"default" | "sm" | "lg" | "xs" | "xl" | null | undefined>;
2244
2255
  readonly zActionClick: _angular_core.OutputEmitterRef<ZTableActionClickEvent<T>>;
2245
2256
  protected readonly allActions: _angular_core.Signal<ZTableActionItem<T>[]>;
2246
2257
  protected readonly shouldShowAsButtons: _angular_core.Signal<boolean>;
@@ -2340,6 +2351,7 @@ declare const getBodyConfig: <T>(col: ZTableColumnConfig<T> | undefined, ctx?: C
2340
2351
  class: string | undefined;
2341
2352
  style: Record<string, string> | undefined;
2342
2353
  align: string | undefined;
2354
+ verticalAlign: ZTableVerticalAlign | undefined;
2343
2355
  rowSpan: number | undefined;
2344
2356
  colSpan: number | undefined;
2345
2357
  contentClass: string | undefined;
@@ -2353,6 +2365,7 @@ declare const getBodyConfig: <T>(col: ZTableColumnConfig<T> | undefined, ctx?: C
2353
2365
  class: string | ((info: CellContext<T, unknown>) => string) | undefined;
2354
2366
  style: Record<string, string> | undefined;
2355
2367
  align: ZTableAlign | undefined;
2368
+ verticalAlign: ZTableVerticalAlign | ((info: CellContext<T, unknown>) => ZTableVerticalAlign) | undefined;
2356
2369
  rowSpan: number | undefined;
2357
2370
  colSpan: number | undefined;
2358
2371
  contentClass: string | ((info: CellContext<T, unknown>) => string) | undefined;
@@ -2397,4 +2410,4 @@ declare const findColumnConfig: <T>(columnId: string, columns: ZTableColumnConfi
2397
2410
  declare function columnConfigToColumnDef<T>(config: ZTableColumnConfig<T>): ColumnDef<T>;
2398
2411
 
2399
2412
  export { ZTableActionsComponent, ZTableComponent, ZTableEditCellComponent, ZTableFilterComponent, ZTableIconTextComponent, columnConfigToColumnDef, findColumnConfig, getBodyConfig, getFooterConfig, getHeaderConfig, isBodyConfig, isFooterConfig, isHeaderConfig };
2400
- export type { Cell, CellContext, Column, ColumnDef, Header, HeaderContext, Row, Table, ZTableActionBodyConfig, ZTableActionClickEvent, ZTableActionColumnConfig, ZTableActionItem, ZTableActionList, ZTableAdvancedFilterType, ZTableBodyContentType, ZTableBulkActionClickEvent, ZTableBulkActionConfig, ZTableBulkActionContext, ZTableBulkActionHandlerContext, ZTableBulkActionItem, ZTableBulkActionList, ZTableBulkActionOptions, ZTableBulkActionViewItem, ZTableCellEditChange, ZTableCellEditEvent, ZTableChangeEvent, ZTableColumn, ZTableColumnConfig, ZTableConfig, ZTableControl, ZTableEditCellChangeEvent, ZTableEditConfig, ZTableEditContentConfig, ZTableEditContentType, ZTableEditSize, ZTableEditType, ZTableExcelExportConfig, ZTableExcelExportContext, ZTableExcelExportScope, ZTableFilterChangeEvent, ZTableFilterCondition, ZTableFilterConfig, ZTableFilterJoinOperator, ZTableFilterOperator, ZTableFilterOptionSource, ZTableFilterUi, ZTableFilterValueType, ZTableGroupExpandChange, ZTableGroupExpandEvent, ZTableGroupingConfig, ZTableGroupingMode, ZTablePageChangeEvent, ZTablePaginationConfig, ZTableRowCopyChange, ZTableRowCopyEvent, ZTableRowDeleteChange, ZTableRowDeleteEvent, ZTableRowExpandEvent, ZTableRowInsertChange, ZTableRowInsertEvent, ZTableRowInsertPosition, ZTableRowMoveChange, ZTableRowMoveDirection, ZTableRowMoveEvent, ZTableRowPasteChange, ZTableRowPasteEvent, ZTableRowSelectEvent, ZTableSearchChangeEvent, ZTableSearchConfig, ZTableServerGroup, ZTableSortChangeEvent, ZTableSortConfig, ZTableTagColor };
2413
+ export type { Cell, CellContext, Column, ColumnDef, Header, HeaderContext, Row, Table, ZTableActionBodyConfig, ZTableActionClickEvent, ZTableActionColumnConfig, ZTableActionItem, ZTableActionList, ZTableAdvancedFilterType, ZTableBodyContentType, ZTableBulkActionClickEvent, ZTableBulkActionConfig, ZTableBulkActionContext, ZTableBulkActionHandlerContext, ZTableBulkActionItem, ZTableBulkActionList, ZTableBulkActionOptions, ZTableBulkActionViewItem, ZTableCellEditChange, ZTableCellEditEvent, ZTableChangeEvent, ZTableColumn, ZTableColumnConfig, ZTableConfig, ZTableControl, ZTableEditCellChangeEvent, ZTableEditConfig, ZTableEditContentConfig, ZTableEditContentType, ZTableEditSize, ZTableEditType, ZTableExcelExportConfig, ZTableExcelExportContext, ZTableExcelExportScope, ZTableFilterChangeEvent, ZTableFilterCondition, ZTableFilterConfig, ZTableFilterJoinOperator, ZTableFilterOperator, ZTableFilterOptionSource, ZTableFilterUi, ZTableFilterValueType, ZTableGroupExpandChange, ZTableGroupExpandEvent, ZTableGroupingConfig, ZTableGroupingMode, ZTablePageChangeEvent, ZTablePaginationConfig, ZTableRowCopyChange, ZTableRowCopyEvent, ZTableRowDeleteChange, ZTableRowDeleteEvent, ZTableRowExpandEvent, ZTableRowInsertChange, ZTableRowInsertEvent, ZTableRowInsertPosition, ZTableRowMoveChange, ZTableRowMoveDirection, ZTableRowMoveEvent, ZTableRowPasteChange, ZTableRowPasteEvent, ZTableRowSelectEvent, ZTableSearchChangeEvent, ZTableSearchConfig, ZTableServerGroup, ZTableSortChangeEvent, ZTableSortConfig, ZTableTagColor, ZTableVerticalAlign };