@truenas/ui-components 0.1.16 → 0.1.17

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": "@truenas/ui-components",
3
- "version": "0.1.16",
3
+ "version": "0.1.17",
4
4
  "publishConfig": {
5
5
  "registry": "https://registry.npmjs.org",
6
6
  "access": "public"
@@ -3302,6 +3302,98 @@ declare class TnConfirmDialogComponent {
3302
3302
  static ɵcmp: _angular_core.ɵɵComponentDeclaration<TnConfirmDialogComponent, "tn-confirm-dialog", never, {}, {}, never, never, true, never>;
3303
3303
  }
3304
3304
 
3305
+ /**
3306
+ * Directive to mark an element as a side-panel footer action.
3307
+ *
3308
+ * @example
3309
+ * ```html
3310
+ * <tn-side-panel [(open)]="isOpen" title="Edit">
3311
+ * <tn-button tnSidePanelAction label="Save" />
3312
+ * </tn-side-panel>
3313
+ * ```
3314
+ */
3315
+ declare class TnSidePanelActionDirective {
3316
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<TnSidePanelActionDirective, never>;
3317
+ static ɵdir: _angular_core.ɵɵDirectiveDeclaration<TnSidePanelActionDirective, "[tnSidePanelAction]", never, {}, {}, never, never, true, never>;
3318
+ }
3319
+ /**
3320
+ * Directive to mark an element as a side-panel header action.
3321
+ *
3322
+ * @example
3323
+ * ```html
3324
+ * <tn-side-panel [(open)]="isOpen" title="Edit">
3325
+ * <tn-icon-button tnSidePanelHeaderAction name="fullscreen" />
3326
+ * Content here
3327
+ * </tn-side-panel>
3328
+ * ```
3329
+ */
3330
+ declare class TnSidePanelHeaderActionDirective {
3331
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<TnSidePanelHeaderActionDirective, never>;
3332
+ static ɵdir: _angular_core.ɵɵDirectiveDeclaration<TnSidePanelHeaderActionDirective, "[tnSidePanelHeaderAction]", never, {}, {}, never, never, true, never>;
3333
+ }
3334
+ declare class TnSidePanelComponent implements OnDestroy {
3335
+ private iconRegistry;
3336
+ private document;
3337
+ private overlayRef;
3338
+ protected initialized: _angular_core.WritableSignal<boolean>;
3339
+ open: _angular_core.ModelSignal<boolean>;
3340
+ title: _angular_core.InputSignal<string>;
3341
+ width: _angular_core.InputSignal<string>;
3342
+ hasBackdrop: _angular_core.InputSignal<boolean>;
3343
+ closeOnBackdropClick: _angular_core.InputSignal<boolean>;
3344
+ closeOnEscape: _angular_core.InputSignal<boolean>;
3345
+ opened: _angular_core.OutputEmitterRef<void>;
3346
+ closed: _angular_core.OutputEmitterRef<void>;
3347
+ private actionContent;
3348
+ protected hasActions: _angular_core.Signal<boolean>;
3349
+ readonly panelId: string;
3350
+ readonly titleId: string;
3351
+ private previouslyFocusedElement;
3352
+ constructor();
3353
+ ngOnDestroy(): void;
3354
+ protected dismiss(): void;
3355
+ protected onBackdropClick(): void;
3356
+ protected onKeydown(event: KeyboardEvent): void;
3357
+ protected onTransitionEnd(event: TransitionEvent): void;
3358
+ private restoreFocus;
3359
+ private registerMdiIcons;
3360
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<TnSidePanelComponent, never>;
3361
+ static ɵcmp: _angular_core.ɵɵComponentDeclaration<TnSidePanelComponent, "tn-side-panel", never, { "open": { "alias": "open"; "required": false; "isSignal": true; }; "title": { "alias": "title"; "required": false; "isSignal": true; }; "width": { "alias": "width"; "required": false; "isSignal": true; }; "hasBackdrop": { "alias": "hasBackdrop"; "required": false; "isSignal": true; }; "closeOnBackdropClick": { "alias": "closeOnBackdropClick"; "required": false; "isSignal": true; }; "closeOnEscape": { "alias": "closeOnEscape"; "required": false; "isSignal": true; }; }, { "open": "openChange"; "opened": "opened"; "closed": "closed"; }, ["actionContent"], ["[tnSidePanelHeaderAction]", "*", "[tnSidePanelAction]"], true, never>;
3362
+ }
3363
+
3364
+ interface SidePanelHarnessFilters extends BaseHarnessFilters {
3365
+ /** Filter by title text. */
3366
+ title?: string | RegExp;
3367
+ }
3368
+ /**
3369
+ * Harness for interacting with `TnSidePanelComponent` in tests.
3370
+ *
3371
+ * @example
3372
+ * ```typescript
3373
+ * const panel = await loader.getHarness(TnSidePanelHarness);
3374
+ * expect(await panel.isOpen()).toBe(true);
3375
+ * expect(await panel.getTitle()).toBe('Edit User');
3376
+ * await panel.dismiss();
3377
+ * ```
3378
+ */
3379
+ declare class TnSidePanelHarness extends ComponentHarness {
3380
+ static hostSelector: string;
3381
+ static with(options?: SidePanelHarnessFilters): HarnessPredicate<TnSidePanelHarness>;
3382
+ /**
3383
+ * Locate the overlay wrapper, which may be portaled to document.body.
3384
+ * Uses the data-tn-panel attribute to correlate the host with its overlay.
3385
+ */
3386
+ private getOverlay;
3387
+ /** Get the panel title text. */
3388
+ getTitle(): Promise<string>;
3389
+ /** Whether the panel is currently open. */
3390
+ isOpen(): Promise<boolean>;
3391
+ /** Click the dismiss button to close the panel. */
3392
+ dismiss(): Promise<void>;
3393
+ /** Get the text content of the scrollable body area. */
3394
+ getContentText(): Promise<string>;
3395
+ }
3396
+
3305
3397
  declare class TnStepComponent {
3306
3398
  label: _angular_core.InputSignal<string>;
3307
3399
  icon: _angular_core.InputSignal<string | undefined>;
@@ -3737,5 +3829,5 @@ declare const TN_THEME_DEFINITIONS: readonly TnThemeDefinition[];
3737
3829
  */
3738
3830
  declare const THEME_MAP: Map<TnTheme, TnThemeDefinition>;
3739
3831
 
3740
- export { CommonShortcuts, DEFAULT_THEME, DiskIconComponent, DiskType, FileSizePipe, InputType, LinuxModifierKeys, LinuxShortcuts, ModifierKeys, QuickShortcuts, ShortcutBuilder, StripMntPrefixPipe, THEME_MAP, THEME_STORAGE_KEY, TN_THEME_DEFINITIONS, TnBannerActionDirective, TnBannerComponent, TnBannerHarness, TnBrandedSpinnerComponent, TnButtonComponent, TnButtonHarness, TnButtonToggleComponent, TnButtonToggleGroupComponent, TnCalendarComponent, TnCalendarHeaderComponent, TnCardComponent, TnCellDefDirective, TnCheckboxComponent, TnChipComponent, TnConfirmDialogComponent, TnDateInputComponent, TnDateRangeInputComponent, TnDialog, TnDialogShellComponent, TnDividerComponent, TnDividerDirective, TnExpansionPanelComponent, TnFilePickerComponent, TnFilePickerPopupComponent, TnFormFieldComponent, TnHeaderCellDefDirective, TnIconButtonComponent, TnIconButtonHarness, TnIconComponent, TnIconHarness, TnIconRegistryService, TnIconTesting, TnInputComponent, TnInputDirective, TnInputHarness, TnKeyboardShortcutComponent, TnKeyboardShortcutService, TnListAvatarDirective, TnListComponent, TnListIconDirective, TnListItemComponent, TnListItemLineDirective, TnListItemPrimaryDirective, TnListItemSecondaryDirective, TnListItemTitleDirective, TnListItemTrailingDirective, TnListOptionComponent, TnListSubheaderComponent, TnMenuComponent, TnMenuTriggerDirective, TnMonthViewComponent, TnMultiYearViewComponent, TnNestedTreeNodeComponent, TnParticleProgressBarComponent, TnProgressBarComponent, TnRadioComponent, TnSelectComponent, TnSelectHarness, TnSelectionListComponent, TnSlideToggleComponent, TnSliderComponent, TnSliderThumbDirective, TnSliderWithLabelDirective, TnSpinnerComponent, TnSpriteLoaderService, TnStepComponent, TnStepperComponent, TnTabComponent, TnTabHarness, TnTabPanelComponent, TnTabPanelHarness, TnTableColumnDirective, TnTableComponent, TnTabsComponent, TnTabsHarness, TnTheme, TnThemeService, TnTimeInputComponent, TnTooltipComponent, TnTooltipDirective, TnTreeComponent, TnTreeFlatDataSource, TnTreeFlattener, TnTreeNodeComponent, TnTreeNodeOutletDirective, TruncatePathPipe, WindowsModifierKeys, WindowsShortcuts, createLucideLibrary, createShortcut, defaultSpriteBasePath, defaultSpriteConfigPath, libIconMarker, registerLucideIcons, setupLucideIntegration, tnIconMarker };
3741
- export type { BannerHarnessFilters, ButtonHarnessFilters, CalendarCell, ChipColor, CreateFolderEvent, DateRange, FilePickerCallbacks, FilePickerError, FilePickerMode, FileSystemItem, IconButtonHarnessFilters, IconHarnessFilters, IconLibrary, IconLibraryType, IconResult, IconSize, IconSource, IconTestingMockOverrides, InputHarnessFilters, KeyCombination, LabelType, LucideIconOptions, MockIconRegistry, MockSpriteLoader, PathSegment, PlatformType, ProgressBarMode, ResolvedIcon, SelectHarnessFilters, ShortcutHandler, SlideToggleColor, SpinnerMode, SpriteConfig, TabChangeEvent, TabHarnessFilters, TabPanelHarnessFilters, TabsHarnessFilters, TnBannerType, TnButtonToggleType, TnCardAction, TnCardControl, TnCardFooterLink, TnCardHeaderStatus, TnConfirmDialogData, TnDialogDefaults, TnDialogOpenTarget, TnFlatTreeNode, TnMenuItem, TnSelectOption, TnSelectOptionGroup, TnSelectionChange, TnTableDataSource, TnThemeDefinition, TooltipPosition, YearCell };
3832
+ export { CommonShortcuts, DEFAULT_THEME, DiskIconComponent, DiskType, FileSizePipe, InputType, LinuxModifierKeys, LinuxShortcuts, ModifierKeys, QuickShortcuts, ShortcutBuilder, StripMntPrefixPipe, THEME_MAP, THEME_STORAGE_KEY, TN_THEME_DEFINITIONS, TnBannerActionDirective, TnBannerComponent, TnBannerHarness, TnBrandedSpinnerComponent, TnButtonComponent, TnButtonHarness, TnButtonToggleComponent, TnButtonToggleGroupComponent, TnCalendarComponent, TnCalendarHeaderComponent, TnCardComponent, TnCellDefDirective, TnCheckboxComponent, TnChipComponent, TnConfirmDialogComponent, TnDateInputComponent, TnDateRangeInputComponent, TnDialog, TnDialogShellComponent, TnDividerComponent, TnDividerDirective, TnExpansionPanelComponent, TnFilePickerComponent, TnFilePickerPopupComponent, TnFormFieldComponent, TnHeaderCellDefDirective, TnIconButtonComponent, TnIconButtonHarness, TnIconComponent, TnIconHarness, TnIconRegistryService, TnIconTesting, TnInputComponent, TnInputDirective, TnInputHarness, TnKeyboardShortcutComponent, TnKeyboardShortcutService, TnListAvatarDirective, TnListComponent, TnListIconDirective, TnListItemComponent, TnListItemLineDirective, TnListItemPrimaryDirective, TnListItemSecondaryDirective, TnListItemTitleDirective, TnListItemTrailingDirective, TnListOptionComponent, TnListSubheaderComponent, TnMenuComponent, TnMenuTriggerDirective, TnMonthViewComponent, TnMultiYearViewComponent, TnNestedTreeNodeComponent, TnParticleProgressBarComponent, TnProgressBarComponent, TnRadioComponent, TnSelectComponent, TnSelectHarness, TnSelectionListComponent, TnSidePanelActionDirective, TnSidePanelComponent, TnSidePanelHarness, TnSidePanelHeaderActionDirective, TnSlideToggleComponent, TnSliderComponent, TnSliderThumbDirective, TnSliderWithLabelDirective, TnSpinnerComponent, TnSpriteLoaderService, TnStepComponent, TnStepperComponent, TnTabComponent, TnTabHarness, TnTabPanelComponent, TnTabPanelHarness, TnTableColumnDirective, TnTableComponent, TnTabsComponent, TnTabsHarness, TnTheme, TnThemeService, TnTimeInputComponent, TnTooltipComponent, TnTooltipDirective, TnTreeComponent, TnTreeFlatDataSource, TnTreeFlattener, TnTreeNodeComponent, TnTreeNodeOutletDirective, TruncatePathPipe, WindowsModifierKeys, WindowsShortcuts, createLucideLibrary, createShortcut, defaultSpriteBasePath, defaultSpriteConfigPath, libIconMarker, registerLucideIcons, setupLucideIntegration, tnIconMarker };
3833
+ export type { BannerHarnessFilters, ButtonHarnessFilters, CalendarCell, ChipColor, CreateFolderEvent, DateRange, FilePickerCallbacks, FilePickerError, FilePickerMode, FileSystemItem, IconButtonHarnessFilters, IconHarnessFilters, IconLibrary, IconLibraryType, IconResult, IconSize, IconSource, IconTestingMockOverrides, InputHarnessFilters, KeyCombination, LabelType, LucideIconOptions, MockIconRegistry, MockSpriteLoader, PathSegment, PlatformType, ProgressBarMode, ResolvedIcon, SelectHarnessFilters, ShortcutHandler, SidePanelHarnessFilters, SlideToggleColor, SpinnerMode, SpriteConfig, TabChangeEvent, TabHarnessFilters, TabPanelHarnessFilters, TabsHarnessFilters, TnBannerType, TnButtonToggleType, TnCardAction, TnCardControl, TnCardFooterLink, TnCardHeaderStatus, TnConfirmDialogData, TnDialogDefaults, TnDialogOpenTarget, TnFlatTreeNode, TnMenuItem, TnSelectOption, TnSelectOptionGroup, TnSelectionChange, TnTableDataSource, TnThemeDefinition, TooltipPosition, YearCell };