@skyux/pages 11.11.2 → 11.13.0

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.
@@ -539,39 +539,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
539
539
  args: [{ selector: 'sky-page-header-details', template: "<ng-content />\n", styles: [":host{display:block}:host:not(:empty){margin-top:var(--sky-margin-stacked-sm)}\n"] }]
540
540
  }] });
541
541
 
542
- let parentLink;
543
542
  /**
544
543
  * Displays page heading's contents using spacing that corresponds to the parent page's layout
545
544
  */
546
545
  class SkyPageHeaderComponent {
547
- #elementRef = inject(ElementRef);
548
- #mediaQueryService = inject(SkyResizeObserverMediaQueryService);
549
- ngOnInit() {
550
- this.#mediaQueryService.observe(this.#elementRef, {
551
- updateResponsiveClasses: true,
552
- });
553
- }
554
- ngOnDestroy() {
555
- this.#mediaQueryService.unobserve();
556
- }
557
546
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyPageHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
558
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: SkyPageHeaderComponent, selector: "sky-page-header", inputs: { parentLink: "parentLink", pageTitle: "pageTitle" }, providers: [
559
- SkyResizeObserverMediaQueryService,
560
- {
561
- provide: SkyMediaQueryService,
562
- useExisting: SkyResizeObserverMediaQueryService,
563
- },
564
- ], ngImport: i0, template: "<div class=\"sky-page-header\">\n <ng-content select=\"sky-page-header-alerts\" />\n <div class=\"sky-page-header-info\">\n <ng-content select=\"sky-page-header-avatar\" />\n <div class=\"sky-page-header-text-and-content\">\n <h1 class=\"sky-page-header-text\">\n @if (parentLink) {\n <span class=\"sky-page-header-parent-link-wrapper\">\n @if (parentLink.permalink?.route; as permalinkRoute) {\n <a\n class=\"sky-font-heading-1 sky-page-header-parent-link\"\n [skyAppLink]=\"permalinkRoute.commands\"\n [queryParams]=\"permalinkRoute.extras?.queryParams\"\n [queryParamsHandling]=\"\n permalinkRoute.extras?.queryParamsHandling\n \"\n [fragment]=\"permalinkRoute.extras?.fragment\"\n [preserveFragment]=\"permalinkRoute.extras?.preserveFragment\"\n [skipLocationChange]=\"permalinkRoute.extras?.skipLocationChange\"\n [replaceUrl]=\"permalinkRoute.extras?.replaceUrl\"\n [state]=\"permalinkRoute.extras?.state\"\n >{{ parentLink.label }}</a\n >\n } @else if (parentLink.permalink?.url) {\n <a\n class=\"sky-font-heading-1 sky-page-header-parent-link\"\n [skyHref]=\"parentLink.permalink.url\"\n >{{ parentLink.label }}</a\n >\n }\n <span class=\"sky-page-header-chevron\">\n <sky-icon icon=\"chevron-right\" />\n </span>\n </span>\n <wbr />\n }\n <span class=\"sky-page-header-page-title sky-font-heading-1\">\n {{ pageTitle }}\n </span>\n </h1>\n <div class=\"sky-page-header-content\">\n <ng-content select=\"sky-page-header-details\" />\n <ng-content select=\"sky-page-header-actions\" />\n </div>\n </div>\n </div>\n</div>\n", styles: [":host{flex-grow:var(--sky-layout-host-header-flex-grow, 0);display:block}.sky-page-header{margin:var(--sky-layout-host-header-spacing, 0)}.sky-page-header-info{display:flex}.sky-page-header-text{margin:0}.sky-page-header-page-title,.sky-page-header-parent-link-wrapper{display:inline-block;block-size:fit-content}.sky-page-header-parent-link{color:#0974a1}.sky-page-header-chevron{font-size:16px;margin:0 10px}.sky-page-header-chevron,.sky-page-header-parent-link,.sky-page-header-page-title{vertical-align:middle}.sky-page-header-content:empty{display:none}:host-context(.sky-theme-modern) .sky-page-header-parent-link{color:#1870b8}.sky-theme-modern .sky-page-header-parent-link{color:#1870b8}:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-page-header-parent-link{color:#009cd1}.sky-theme-modern.sky-theme-mode-dark .sky-page-header-parent-link{color:#009cd1}\n"], dependencies: [{ kind: "directive", type: i2.λ3, selector: "[skyAppLink]", inputs: ["skyAppLink"] }, { kind: "component", type: i4.λ1, selector: "sky-icon", inputs: ["icon", "iconName", "iconType", "size", "fixedWidth", "variant"] }, { kind: "directive", type: i2.λ1, selector: "[skyHref]", inputs: ["skyHref", "queryParams", "skyHrefElse"], outputs: ["skyHrefChange"] }] }); }
547
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: SkyPageHeaderComponent, selector: "sky-page-header", inputs: { parentLink: "parentLink", pageTitle: "pageTitle" }, ngImport: i0, template: "<div class=\"sky-page-header\">\n <ng-content select=\"sky-page-header-alerts\" />\n <div class=\"sky-page-header-info\">\n <ng-content select=\"sky-page-header-avatar\" />\n <div class=\"sky-page-header-text-and-content\">\n <h1 class=\"sky-page-header-text\">\n @if (parentLink) {\n <span class=\"sky-page-header-parent-link-wrapper\">\n @if (parentLink.permalink?.route; as permalinkRoute) {\n <a\n class=\"sky-font-heading-1 sky-page-header-parent-link\"\n [skyAppLink]=\"permalinkRoute.commands\"\n [queryParams]=\"permalinkRoute.extras?.queryParams\"\n [queryParamsHandling]=\"\n permalinkRoute.extras?.queryParamsHandling\n \"\n [fragment]=\"permalinkRoute.extras?.fragment\"\n [preserveFragment]=\"permalinkRoute.extras?.preserveFragment\"\n [skipLocationChange]=\"permalinkRoute.extras?.skipLocationChange\"\n [replaceUrl]=\"permalinkRoute.extras?.replaceUrl\"\n [state]=\"permalinkRoute.extras?.state\"\n >{{ parentLink.label }}</a\n >\n } @else if (parentLink.permalink?.url) {\n <a\n class=\"sky-font-heading-1 sky-page-header-parent-link\"\n [skyHref]=\"parentLink.permalink.url\"\n >{{ parentLink.label }}</a\n >\n }\n <span class=\"sky-page-header-chevron\">\n <sky-icon icon=\"chevron-right\" />\n </span>\n </span>\n <wbr />\n }\n <span class=\"sky-page-header-page-title sky-font-heading-1\">\n {{ pageTitle }}\n </span>\n </h1>\n <div class=\"sky-page-header-content\">\n <ng-content select=\"sky-page-header-details\" />\n <ng-content select=\"sky-page-header-actions\" />\n </div>\n </div>\n </div>\n</div>\n", styles: [":host{flex-grow:var(--sky-layout-host-header-flex-grow, 0);display:block}.sky-page-header{margin:var(--sky-layout-host-header-spacing, 0)}.sky-page-header-info{display:flex}.sky-page-header-text{margin:0}.sky-page-header-page-title,.sky-page-header-parent-link-wrapper{display:inline-block;block-size:fit-content}.sky-page-header-parent-link{color:#0974a1}.sky-page-header-chevron{font-size:16px;margin:0 10px}.sky-page-header-chevron,.sky-page-header-parent-link,.sky-page-header-page-title{vertical-align:middle}.sky-page-header-content:empty{display:none}:host-context(.sky-theme-modern) .sky-page-header-parent-link{color:#1870b8}.sky-theme-modern .sky-page-header-parent-link{color:#1870b8}:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-page-header-parent-link{color:#009cd1}.sky-theme-modern.sky-theme-mode-dark .sky-page-header-parent-link{color:#009cd1}\n"], dependencies: [{ kind: "directive", type: i2.λ3, selector: "[skyAppLink]", inputs: ["skyAppLink"] }, { kind: "component", type: i4.λ1, selector: "sky-icon", inputs: ["icon", "iconName", "iconType", "size", "fixedWidth", "variant"] }, { kind: "directive", type: i2.λ1, selector: "[skyHref]", inputs: ["skyHref", "queryParams", "skyHrefElse"], outputs: ["skyHrefChange"] }] }); }
565
548
  }
566
549
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyPageHeaderComponent, decorators: [{
567
550
  type: Component,
568
- args: [{ selector: 'sky-page-header', providers: [
569
- SkyResizeObserverMediaQueryService,
570
- {
571
- provide: SkyMediaQueryService,
572
- useExisting: SkyResizeObserverMediaQueryService,
573
- },
574
- ], template: "<div class=\"sky-page-header\">\n <ng-content select=\"sky-page-header-alerts\" />\n <div class=\"sky-page-header-info\">\n <ng-content select=\"sky-page-header-avatar\" />\n <div class=\"sky-page-header-text-and-content\">\n <h1 class=\"sky-page-header-text\">\n @if (parentLink) {\n <span class=\"sky-page-header-parent-link-wrapper\">\n @if (parentLink.permalink?.route; as permalinkRoute) {\n <a\n class=\"sky-font-heading-1 sky-page-header-parent-link\"\n [skyAppLink]=\"permalinkRoute.commands\"\n [queryParams]=\"permalinkRoute.extras?.queryParams\"\n [queryParamsHandling]=\"\n permalinkRoute.extras?.queryParamsHandling\n \"\n [fragment]=\"permalinkRoute.extras?.fragment\"\n [preserveFragment]=\"permalinkRoute.extras?.preserveFragment\"\n [skipLocationChange]=\"permalinkRoute.extras?.skipLocationChange\"\n [replaceUrl]=\"permalinkRoute.extras?.replaceUrl\"\n [state]=\"permalinkRoute.extras?.state\"\n >{{ parentLink.label }}</a\n >\n } @else if (parentLink.permalink?.url) {\n <a\n class=\"sky-font-heading-1 sky-page-header-parent-link\"\n [skyHref]=\"parentLink.permalink.url\"\n >{{ parentLink.label }}</a\n >\n }\n <span class=\"sky-page-header-chevron\">\n <sky-icon icon=\"chevron-right\" />\n </span>\n </span>\n <wbr />\n }\n <span class=\"sky-page-header-page-title sky-font-heading-1\">\n {{ pageTitle }}\n </span>\n </h1>\n <div class=\"sky-page-header-content\">\n <ng-content select=\"sky-page-header-details\" />\n <ng-content select=\"sky-page-header-actions\" />\n </div>\n </div>\n </div>\n</div>\n", styles: [":host{flex-grow:var(--sky-layout-host-header-flex-grow, 0);display:block}.sky-page-header{margin:var(--sky-layout-host-header-spacing, 0)}.sky-page-header-info{display:flex}.sky-page-header-text{margin:0}.sky-page-header-page-title,.sky-page-header-parent-link-wrapper{display:inline-block;block-size:fit-content}.sky-page-header-parent-link{color:#0974a1}.sky-page-header-chevron{font-size:16px;margin:0 10px}.sky-page-header-chevron,.sky-page-header-parent-link,.sky-page-header-page-title{vertical-align:middle}.sky-page-header-content:empty{display:none}:host-context(.sky-theme-modern) .sky-page-header-parent-link{color:#1870b8}.sky-theme-modern .sky-page-header-parent-link{color:#1870b8}:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-page-header-parent-link{color:#009cd1}.sky-theme-modern.sky-theme-mode-dark .sky-page-header-parent-link{color:#009cd1}\n"] }]
551
+ args: [{ selector: 'sky-page-header', template: "<div class=\"sky-page-header\">\n <ng-content select=\"sky-page-header-alerts\" />\n <div class=\"sky-page-header-info\">\n <ng-content select=\"sky-page-header-avatar\" />\n <div class=\"sky-page-header-text-and-content\">\n <h1 class=\"sky-page-header-text\">\n @if (parentLink) {\n <span class=\"sky-page-header-parent-link-wrapper\">\n @if (parentLink.permalink?.route; as permalinkRoute) {\n <a\n class=\"sky-font-heading-1 sky-page-header-parent-link\"\n [skyAppLink]=\"permalinkRoute.commands\"\n [queryParams]=\"permalinkRoute.extras?.queryParams\"\n [queryParamsHandling]=\"\n permalinkRoute.extras?.queryParamsHandling\n \"\n [fragment]=\"permalinkRoute.extras?.fragment\"\n [preserveFragment]=\"permalinkRoute.extras?.preserveFragment\"\n [skipLocationChange]=\"permalinkRoute.extras?.skipLocationChange\"\n [replaceUrl]=\"permalinkRoute.extras?.replaceUrl\"\n [state]=\"permalinkRoute.extras?.state\"\n >{{ parentLink.label }}</a\n >\n } @else if (parentLink.permalink?.url) {\n <a\n class=\"sky-font-heading-1 sky-page-header-parent-link\"\n [skyHref]=\"parentLink.permalink.url\"\n >{{ parentLink.label }}</a\n >\n }\n <span class=\"sky-page-header-chevron\">\n <sky-icon icon=\"chevron-right\" />\n </span>\n </span>\n <wbr />\n }\n <span class=\"sky-page-header-page-title sky-font-heading-1\">\n {{ pageTitle }}\n </span>\n </h1>\n <div class=\"sky-page-header-content\">\n <ng-content select=\"sky-page-header-details\" />\n <ng-content select=\"sky-page-header-actions\" />\n </div>\n </div>\n </div>\n</div>\n", styles: [":host{flex-grow:var(--sky-layout-host-header-flex-grow, 0);display:block}.sky-page-header{margin:var(--sky-layout-host-header-spacing, 0)}.sky-page-header-info{display:flex}.sky-page-header-text{margin:0}.sky-page-header-page-title,.sky-page-header-parent-link-wrapper{display:inline-block;block-size:fit-content}.sky-page-header-parent-link{color:#0974a1}.sky-page-header-chevron{font-size:16px;margin:0 10px}.sky-page-header-chevron,.sky-page-header-parent-link,.sky-page-header-page-title{vertical-align:middle}.sky-page-header-content:empty{display:none}:host-context(.sky-theme-modern) .sky-page-header-parent-link{color:#1870b8}.sky-theme-modern .sky-page-header-parent-link{color:#1870b8}:host-context(.sky-theme-modern.sky-theme-mode-dark) .sky-page-header-parent-link{color:#009cd1}.sky-theme-modern.sky-theme-mode-dark .sky-page-header-parent-link{color:#009cd1}\n"] }]
575
552
  }], propDecorators: { parentLink: [{
576
553
  type: Input
577
554
  }], pageTitle: [{
@@ -626,182 +603,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
626
603
  }]
627
604
  }] });
628
605
 
629
- /**
630
- * Displays buttons after the page title.
631
- *
632
- * Example:
633
- *
634
- * ```html
635
- * <a class="sky-btn sky-btn-default" href="path/to/new">New</a>
636
- * ```
637
- */
638
- class SkyActionHubButtonsComponent {
639
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubButtonsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
640
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: SkyActionHubButtonsComponent, selector: "sky-action-hub-buttons", ngImport: i0, template: "<ng-content />\n", styles: [":host{display:block}:host:not(:empty){margin-bottom:var(--sky-margin-stacked-xl)}\n"] }); }
641
- }
642
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubButtonsComponent, decorators: [{
643
- type: Component,
644
- args: [{ selector: 'sky-action-hub-buttons', template: "<ng-content />\n", styles: [":host{display:block}:host:not(:empty){margin-bottom:var(--sky-margin-stacked-xl)}\n"] }]
645
- }] });
646
-
647
- /**
648
- * Displays additional content after the action items.
649
- */
650
- class SkyActionHubContentComponent {
651
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
652
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: SkyActionHubContentComponent, selector: "sky-action-hub-content", ngImport: i0, template: "<ng-content />\n" }); }
653
- }
654
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubContentComponent, decorators: [{
655
- type: Component,
656
- args: [{ selector: 'sky-action-hub-content', template: "<ng-content />\n" }]
657
- }] });
658
-
659
- class SkyActionHubRelatedLinksSortPipe {
660
- transform(relatedLinks) {
661
- if (relatedLinks === 'loading') {
662
- return 'loading';
663
- }
664
- if (!relatedLinks || relatedLinks.length === 0) {
665
- return [];
666
- }
667
- return relatedLinks.slice(0).sort((a, b) => {
668
- const aLabel = a.label.trim().toUpperCase();
669
- const bLabel = b.label.trim().toUpperCase();
670
- if (aLabel === bLabel) {
671
- return 0;
672
- }
673
- return aLabel < bLabel ? -1 : 1;
674
- });
675
- }
676
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubRelatedLinksSortPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
677
- static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubRelatedLinksSortPipe, name: "skyActionHubRelatedLinksSort" }); }
678
- }
679
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubRelatedLinksSortPipe, decorators: [{
680
- type: Pipe,
681
- args: [{
682
- name: 'skyActionHubRelatedLinksSort',
683
- }]
684
- }] });
685
-
686
- /**
687
- * Creates an action hub to direct user attention to important
688
- * actions and provide quick access to common tasks.
689
- */
690
- class SkyActionHubComponent {
691
- constructor() {
692
- /**
693
- * The list of recently accessed links, or `"loading"` to display a wait indicator.
694
- */
695
- this.recentLinks = [];
696
- /**
697
- * The list of related links, or `"loading"` to display a wait indicator.
698
- */
699
- this.relatedLinks = [];
700
- /**
701
- * The list of settings with modal parameters, or `"loading"` to display a wait indicator.
702
- */
703
- this.settingsLinks = [];
704
- /**
705
- * The page title.
706
- * @default ""
707
- */
708
- this.title = '';
709
- this.needsAttentionArray = [];
710
- }
711
- /**
712
- * The list of actions that users must perform based on business requirements or best practices, or `"loading"` to display a wait indicator.
713
- */
714
- set needsAttention(value) {
715
- this.#_needsAttention = value;
716
- this.needsAttentionArray = Array.isArray(value) ? value : [];
717
- }
718
- get needsAttention() {
719
- return this.#_needsAttention;
720
- }
721
- #_needsAttention;
722
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
723
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: SkyActionHubComponent, selector: "sky-action-hub", inputs: { needsAttention: "needsAttention", parentLink: "parentLink", recentLinks: "recentLinks", relatedLinks: "relatedLinks", settingsLinks: "settingsLinks", title: "title" }, ngImport: i0, template: "<sky-fluid-grid [disableMargin]=\"true\">\n <sky-row>\n <sky-column>\n <sky-page-header [pageTitle]=\"title\" [parentLink]=\"parentLink\" />\n </sky-column>\n </sky-row>\n <sky-row>\n <sky-column [screenLarge]=\"9\" [screenXSmall]=\"12\">\n <div class=\"sky-margin-stacked-xl\">\n <ng-content select=\"sky-action-hub-buttons\" />\n </div>\n\n <div class=\"sky-margin-stacked-xl\">\n <sky-wait [isWaiting]=\"needsAttention === 'loading'\" />\n @if (needsAttention !== 'loading') {\n <sky-needs-attention [items]=\"needsAttentionArray\" />\n }\n </div>\n\n <div class=\"sky-margin-stacked-xl\">\n <ng-content select=\"sky-action-hub-content\" />\n </div>\n </sky-column>\n <sky-column [screenLarge]=\"3\" [screenXSmall]=\"12\">\n <sky-link-list\n [links]=\"relatedLinks | skyActionHubRelatedLinksSort\"\n [headingText]=\"'sky_action_hub_related_links' | skyLibResources\"\n />\n <sky-link-list-recently-accessed [recentLinks]=\"recentLinks\" />\n <sky-modal-link-list\n [links]=\"settingsLinks\"\n [title]=\"'sky_action_hub_settings_links' | skyLibResources\"\n />\n </sky-column>\n </sky-row>\n</sky-fluid-grid>\n", styles: [":host{display:block;margin:var(--sky-padding-even-xl)}[aria-busy=true]{display:block;min-height:60px;margin-bottom:var(--sky-margin-stacked-xl)}sky-page-header{margin:0 0 var(--sky-margin-stacked-lg) 0}.sky-margin-stacked-xl:empty{margin-bottom:0}\n"], dependencies: [{ kind: "component", type: i3$1.λ23, selector: "sky-row", inputs: ["reverseColumnOrder"] }, { kind: "component", type: i3$1.λ24, selector: "sky-column", inputs: ["screenXSmall", "screenSmall", "screenMedium", "screenLarge"] }, { kind: "component", type: i3$1.λ22, selector: "sky-fluid-grid", inputs: ["disableMargin", "gutterSize"] }, { kind: "component", type: SkyLinkListComponent, selector: "sky-link-list", inputs: ["headingText", "links"] }, { kind: "component", type: SkyLinkListRecentlyAccessedComponent, selector: "sky-link-list-recently-accessed", inputs: ["recentLinks"] }, { kind: "component", type: SkyModalLinkListComponent, selector: "sky-modal-link-list", inputs: ["links", "title"] }, { kind: "component", type: SkyNeedsAttentionComponent, selector: "sky-needs-attention", inputs: ["items"] }, { kind: "component", type: SkyPageHeaderComponent, selector: "sky-page-header", inputs: ["parentLink", "pageTitle"] }, { kind: "component", type: i3.λ14, selector: "sky-wait", inputs: ["ariaLabel", "isWaiting", "isFullPage", "isNonBlocking", "screenReaderCompletedText"] }, { kind: "pipe", type: i1.SkyLibResourcesPipe, name: "skyLibResources" }, { kind: "pipe", type: SkyActionHubRelatedLinksSortPipe, name: "skyActionHubRelatedLinksSort" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
724
- }
725
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubComponent, decorators: [{
726
- type: Component,
727
- args: [{ selector: 'sky-action-hub', changeDetection: ChangeDetectionStrategy.OnPush, template: "<sky-fluid-grid [disableMargin]=\"true\">\n <sky-row>\n <sky-column>\n <sky-page-header [pageTitle]=\"title\" [parentLink]=\"parentLink\" />\n </sky-column>\n </sky-row>\n <sky-row>\n <sky-column [screenLarge]=\"9\" [screenXSmall]=\"12\">\n <div class=\"sky-margin-stacked-xl\">\n <ng-content select=\"sky-action-hub-buttons\" />\n </div>\n\n <div class=\"sky-margin-stacked-xl\">\n <sky-wait [isWaiting]=\"needsAttention === 'loading'\" />\n @if (needsAttention !== 'loading') {\n <sky-needs-attention [items]=\"needsAttentionArray\" />\n }\n </div>\n\n <div class=\"sky-margin-stacked-xl\">\n <ng-content select=\"sky-action-hub-content\" />\n </div>\n </sky-column>\n <sky-column [screenLarge]=\"3\" [screenXSmall]=\"12\">\n <sky-link-list\n [links]=\"relatedLinks | skyActionHubRelatedLinksSort\"\n [headingText]=\"'sky_action_hub_related_links' | skyLibResources\"\n />\n <sky-link-list-recently-accessed [recentLinks]=\"recentLinks\" />\n <sky-modal-link-list\n [links]=\"settingsLinks\"\n [title]=\"'sky_action_hub_settings_links' | skyLibResources\"\n />\n </sky-column>\n </sky-row>\n</sky-fluid-grid>\n", styles: [":host{display:block;margin:var(--sky-padding-even-xl)}[aria-busy=true]{display:block;min-height:60px;margin-bottom:var(--sky-margin-stacked-xl)}sky-page-header{margin:0 0 var(--sky-margin-stacked-lg) 0}.sky-margin-stacked-xl:empty{margin-bottom:0}\n"] }]
728
- }], propDecorators: { needsAttention: [{
729
- type: Input
730
- }], parentLink: [{
731
- type: Input
732
- }], recentLinks: [{
733
- type: Input
734
- }], relatedLinks: [{
735
- type: Input
736
- }], settingsLinks: [{
737
- type: Input
738
- }], title: [{
739
- type: Input
740
- }] } });
741
-
742
- class SkyActionHubModule {
743
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
744
- static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubModule, declarations: [SkyActionHubButtonsComponent,
745
- SkyActionHubComponent,
746
- SkyActionHubContentComponent,
747
- SkyActionHubRelatedLinksSortPipe], imports: [SkyActionHubRecentLinksResolvePipe,
748
- SkyBoxModule,
749
- SkyFluidGridModule,
750
- SkyLinkListModule,
751
- SkyModalLinkListModule,
752
- SkyNeedsAttentionModule,
753
- SkyPageHeaderModule,
754
- SkyPagesResourcesModule,
755
- SkyThemeModule,
756
- SkyWaitModule], exports: [SkyActionHubButtonsComponent,
757
- SkyActionHubComponent,
758
- SkyActionHubContentComponent] }); }
759
- static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubModule, imports: [SkyBoxModule,
760
- SkyFluidGridModule,
761
- SkyLinkListModule,
762
- SkyModalLinkListModule,
763
- SkyNeedsAttentionModule,
764
- SkyPageHeaderModule,
765
- SkyPagesResourcesModule,
766
- SkyThemeModule,
767
- SkyWaitModule] }); }
768
- }
769
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubModule, decorators: [{
770
- type: NgModule,
771
- args: [{
772
- imports: [
773
- SkyActionHubRecentLinksResolvePipe,
774
- SkyBoxModule,
775
- SkyFluidGridModule,
776
- SkyLinkListModule,
777
- SkyModalLinkListModule,
778
- SkyNeedsAttentionModule,
779
- SkyPageHeaderModule,
780
- SkyPagesResourcesModule,
781
- SkyThemeModule,
782
- SkyWaitModule,
783
- ],
784
- declarations: [
785
- SkyActionHubButtonsComponent,
786
- SkyActionHubComponent,
787
- SkyActionHubContentComponent,
788
- SkyActionHubRelatedLinksSortPipe,
789
- ],
790
- exports: [
791
- SkyActionHubButtonsComponent,
792
- SkyActionHubComponent,
793
- SkyActionHubContentComponent,
794
- ],
795
- }]
796
- }] });
797
-
798
606
  /**
799
607
  * Displays page contents using spacing that corresponds to the parent
800
608
  * page's layout.
801
609
  */
802
610
  class SkyPageContentComponent {
803
611
  #elementRef = inject(ElementRef);
804
- #mediaQueryService = inject(SkyResizeObserverMediaQueryService);
612
+ #mediaQueryService = inject(SkyResizeObserverMediaQueryService, {
613
+ self: true,
614
+ });
805
615
  ngOnInit() {
806
616
  this.#mediaQueryService.observe(this.#elementRef, {
807
617
  updateResponsiveClasses: true,
@@ -900,6 +710,10 @@ class SkyPageComponent {
900
710
  this.#themeAdapter = inject(SkyPageThemeAdapterService);
901
711
  this.#layoutHostSvc = inject(SkyLayoutHostService);
902
712
  this.#helpSvc = inject(SkyHelpService, { optional: true });
713
+ this.#elementRef = inject(ElementRef);
714
+ this.#resizeObserverSvc = inject(SkyResizeObserverMediaQueryService, {
715
+ self: true,
716
+ });
903
717
  }
904
718
  /**
905
719
  * The page layout that applies spacing to the page header and content. Use the layout
@@ -924,6 +738,8 @@ class SkyPageComponent {
924
738
  #themeAdapter;
925
739
  #layoutHostSvc;
926
740
  #helpSvc;
741
+ #elementRef;
742
+ #resizeObserverSvc;
927
743
  ngOnInit() {
928
744
  this.#themeAdapter.addTheme();
929
745
  this.#layoutHostSvc.hostLayoutForChild
@@ -932,9 +748,11 @@ class SkyPageComponent {
932
748
  this.#layoutForChild = args.layout;
933
749
  this.#updateCssClass();
934
750
  });
751
+ this.#resizeObserverSvc.observe(this.#elementRef);
935
752
  }
936
753
  ngOnDestroy() {
937
754
  this.#themeAdapter.removeTheme();
755
+ this.#resizeObserverSvc.destroy();
938
756
  this.#ngUnsubscribe.next();
939
757
  this.#ngUnsubscribe.complete();
940
758
  this.#helpSvc?.updateHelp({ pageDefaultHelpKey: undefined });
@@ -949,14 +767,30 @@ class SkyPageComponent {
949
767
  this.cssClass = cssClass;
950
768
  }
951
769
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyPageComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
952
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: SkyPageComponent, selector: "sky-page", inputs: { layout: "layout", helpKey: "helpKey" }, host: { properties: { "class": "this.cssClass" } }, providers: [SkyPageThemeAdapterService, SkyLayoutHostService], ngImport: i0, template: `<ng-content />`, isInline: true }); }
770
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: SkyPageComponent, selector: "sky-page", inputs: { layout: "layout", helpKey: "helpKey" }, host: { properties: { "class": "this.cssClass" } }, providers: [
771
+ SkyPageThemeAdapterService,
772
+ SkyLayoutHostService,
773
+ SkyResizeObserverMediaQueryService,
774
+ {
775
+ provide: SkyMediaQueryService,
776
+ useExisting: SkyResizeObserverMediaQueryService,
777
+ },
778
+ ], ngImport: i0, template: `<ng-content />`, isInline: true }); }
953
779
  }
954
780
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyPageComponent, decorators: [{
955
781
  type: Component,
956
782
  args: [{
957
783
  selector: 'sky-page',
958
784
  template: `<ng-content />`,
959
- providers: [SkyPageThemeAdapterService, SkyLayoutHostService],
785
+ providers: [
786
+ SkyPageThemeAdapterService,
787
+ SkyLayoutHostService,
788
+ SkyResizeObserverMediaQueryService,
789
+ {
790
+ provide: SkyMediaQueryService,
791
+ useExisting: SkyResizeObserverMediaQueryService,
792
+ },
793
+ ],
960
794
  }]
961
795
  }], propDecorators: { layout: [{
962
796
  type: Input
@@ -1004,6 +838,178 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
1004
838
  }]
1005
839
  }] });
1006
840
 
841
+ /**
842
+ * Displays buttons after the page title.
843
+ *
844
+ * Example:
845
+ *
846
+ * ```html
847
+ * <a class="sky-btn sky-btn-default" href="path/to/new">New</a>
848
+ * ```
849
+ */
850
+ class SkyActionHubButtonsComponent {
851
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubButtonsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
852
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: SkyActionHubButtonsComponent, selector: "sky-action-hub-buttons", ngImport: i0, template: "<ng-content />\n", styles: [":host{display:block}\n"] }); }
853
+ }
854
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubButtonsComponent, decorators: [{
855
+ type: Component,
856
+ args: [{ selector: 'sky-action-hub-buttons', template: "<ng-content />\n", styles: [":host{display:block}\n"] }]
857
+ }] });
858
+
859
+ /**
860
+ * Displays additional content after the action items.
861
+ */
862
+ class SkyActionHubContentComponent {
863
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
864
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.8", type: SkyActionHubContentComponent, selector: "sky-action-hub-content", ngImport: i0, template: "<ng-content />\n" }); }
865
+ }
866
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubContentComponent, decorators: [{
867
+ type: Component,
868
+ args: [{ selector: 'sky-action-hub-content', template: "<ng-content />\n" }]
869
+ }] });
870
+
871
+ class SkyActionHubRelatedLinksSortPipe {
872
+ transform(relatedLinks) {
873
+ if (relatedLinks === 'loading') {
874
+ return 'loading';
875
+ }
876
+ if (!relatedLinks || relatedLinks.length === 0) {
877
+ return [];
878
+ }
879
+ return relatedLinks.slice(0).sort((a, b) => {
880
+ const aLabel = a.label.trim().toUpperCase();
881
+ const bLabel = b.label.trim().toUpperCase();
882
+ if (aLabel === bLabel) {
883
+ return 0;
884
+ }
885
+ return aLabel < bLabel ? -1 : 1;
886
+ });
887
+ }
888
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubRelatedLinksSortPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
889
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubRelatedLinksSortPipe, name: "skyActionHubRelatedLinksSort" }); }
890
+ }
891
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubRelatedLinksSortPipe, decorators: [{
892
+ type: Pipe,
893
+ args: [{
894
+ name: 'skyActionHubRelatedLinksSort',
895
+ }]
896
+ }] });
897
+
898
+ /**
899
+ * Creates an action hub to direct user attention to important
900
+ * actions and provide quick access to common tasks.
901
+ */
902
+ class SkyActionHubComponent {
903
+ constructor() {
904
+ /**
905
+ * The list of recently accessed links, or `"loading"` to display a wait indicator.
906
+ */
907
+ this.recentLinks = [];
908
+ /**
909
+ * The list of related links, or `"loading"` to display a wait indicator.
910
+ */
911
+ this.relatedLinks = [];
912
+ /**
913
+ * The list of settings with modal parameters, or `"loading"` to display a wait indicator.
914
+ */
915
+ this.settingsLinks = [];
916
+ /**
917
+ * The page title.
918
+ * @default ""
919
+ */
920
+ this.title = '';
921
+ this.needsAttentionArray = [];
922
+ }
923
+ /**
924
+ * The list of actions that users must perform based on business requirements or best practices, or `"loading"` to display a wait indicator.
925
+ */
926
+ set needsAttention(value) {
927
+ this.#_needsAttention = value;
928
+ this.needsAttentionArray = Array.isArray(value) ? value : [];
929
+ }
930
+ get needsAttention() {
931
+ return this.#_needsAttention;
932
+ }
933
+ #_needsAttention;
934
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
935
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: SkyActionHubComponent, selector: "sky-action-hub", inputs: { needsAttention: "needsAttention", parentLink: "parentLink", recentLinks: "recentLinks", relatedLinks: "relatedLinks", settingsLinks: "settingsLinks", title: "title" }, ngImport: i0, template: "<sky-page layout=\"blocks\">\n <sky-page-header [pageTitle]=\"title\" [parentLink]=\"parentLink\">\n <sky-page-header-actions>\n <div class=\"sky-margin-stacked-sm\">\n <ng-content select=\"sky-action-hub-buttons\" />\n </div>\n </sky-page-header-actions>\n </sky-page-header>\n <sky-page-content>\n <div class=\"sky-margin-stacked-xl\">\n <sky-wait [isWaiting]=\"needsAttention === 'loading'\" />\n @if (needsAttention !== 'loading') {\n <sky-needs-attention [items]=\"needsAttentionArray\" />\n }\n </div>\n\n <div class=\"sky-margin-stacked-xl\">\n <ng-content select=\"sky-action-hub-content\" />\n </div>\n </sky-page-content>\n <sky-page-links>\n <sky-link-list\n [links]=\"relatedLinks | skyActionHubRelatedLinksSort\"\n [headingText]=\"'sky_action_hub_related_links' | skyLibResources\"\n />\n <sky-link-list-recently-accessed [recentLinks]=\"recentLinks\" />\n <sky-modal-link-list\n [links]=\"settingsLinks\"\n [title]=\"'sky_action_hub_settings_links' | skyLibResources\"\n />\n </sky-page-links>\n</sky-page>\n", styles: [":host{display:block}\n"], dependencies: [{ kind: "component", type: SkyLinkListComponent, selector: "sky-link-list", inputs: ["headingText", "links"] }, { kind: "component", type: SkyLinkListRecentlyAccessedComponent, selector: "sky-link-list-recently-accessed", inputs: ["recentLinks"] }, { kind: "component", type: SkyModalLinkListComponent, selector: "sky-modal-link-list", inputs: ["links", "title"] }, { kind: "component", type: SkyNeedsAttentionComponent, selector: "sky-needs-attention", inputs: ["items"] }, { kind: "component", type: SkyPageHeaderActionsComponent, selector: "sky-page-header-actions" }, { kind: "component", type: SkyPageHeaderComponent, selector: "sky-page-header", inputs: ["parentLink", "pageTitle"] }, { kind: "component", type: i3.λ14, selector: "sky-wait", inputs: ["ariaLabel", "isWaiting", "isFullPage", "isNonBlocking", "screenReaderCompletedText"] }, { kind: "component", type: SkyPageComponent, selector: "sky-page", inputs: ["layout", "helpKey"] }, { kind: "component", type: SkyPageContentComponent, selector: "sky-page-content" }, { kind: "component", type: SkyPageLinksComponent, selector: "sky-page-links" }, { kind: "pipe", type: i1.SkyLibResourcesPipe, name: "skyLibResources" }, { kind: "pipe", type: SkyActionHubRelatedLinksSortPipe, name: "skyActionHubRelatedLinksSort" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
936
+ }
937
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubComponent, decorators: [{
938
+ type: Component,
939
+ args: [{ selector: 'sky-action-hub', changeDetection: ChangeDetectionStrategy.OnPush, template: "<sky-page layout=\"blocks\">\n <sky-page-header [pageTitle]=\"title\" [parentLink]=\"parentLink\">\n <sky-page-header-actions>\n <div class=\"sky-margin-stacked-sm\">\n <ng-content select=\"sky-action-hub-buttons\" />\n </div>\n </sky-page-header-actions>\n </sky-page-header>\n <sky-page-content>\n <div class=\"sky-margin-stacked-xl\">\n <sky-wait [isWaiting]=\"needsAttention === 'loading'\" />\n @if (needsAttention !== 'loading') {\n <sky-needs-attention [items]=\"needsAttentionArray\" />\n }\n </div>\n\n <div class=\"sky-margin-stacked-xl\">\n <ng-content select=\"sky-action-hub-content\" />\n </div>\n </sky-page-content>\n <sky-page-links>\n <sky-link-list\n [links]=\"relatedLinks | skyActionHubRelatedLinksSort\"\n [headingText]=\"'sky_action_hub_related_links' | skyLibResources\"\n />\n <sky-link-list-recently-accessed [recentLinks]=\"recentLinks\" />\n <sky-modal-link-list\n [links]=\"settingsLinks\"\n [title]=\"'sky_action_hub_settings_links' | skyLibResources\"\n />\n </sky-page-links>\n</sky-page>\n", styles: [":host{display:block}\n"] }]
940
+ }], propDecorators: { needsAttention: [{
941
+ type: Input
942
+ }], parentLink: [{
943
+ type: Input
944
+ }], recentLinks: [{
945
+ type: Input
946
+ }], relatedLinks: [{
947
+ type: Input
948
+ }], settingsLinks: [{
949
+ type: Input
950
+ }], title: [{
951
+ type: Input
952
+ }] } });
953
+
954
+ class SkyActionHubModule {
955
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
956
+ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubModule, declarations: [SkyActionHubButtonsComponent,
957
+ SkyActionHubComponent,
958
+ SkyActionHubContentComponent,
959
+ SkyActionHubRelatedLinksSortPipe], imports: [SkyActionHubRecentLinksResolvePipe,
960
+ SkyBoxModule,
961
+ SkyFluidGridModule,
962
+ SkyLinkListModule,
963
+ SkyModalLinkListModule,
964
+ SkyNeedsAttentionModule,
965
+ SkyPageHeaderModule,
966
+ SkyPagesResourcesModule,
967
+ SkyThemeModule,
968
+ SkyWaitModule,
969
+ SkyPageModule], exports: [SkyActionHubButtonsComponent,
970
+ SkyActionHubComponent,
971
+ SkyActionHubContentComponent] }); }
972
+ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubModule, imports: [SkyBoxModule,
973
+ SkyFluidGridModule,
974
+ SkyLinkListModule,
975
+ SkyModalLinkListModule,
976
+ SkyNeedsAttentionModule,
977
+ SkyPageHeaderModule,
978
+ SkyPagesResourcesModule,
979
+ SkyThemeModule,
980
+ SkyWaitModule,
981
+ SkyPageModule] }); }
982
+ }
983
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: SkyActionHubModule, decorators: [{
984
+ type: NgModule,
985
+ args: [{
986
+ imports: [
987
+ SkyActionHubRecentLinksResolvePipe,
988
+ SkyBoxModule,
989
+ SkyFluidGridModule,
990
+ SkyLinkListModule,
991
+ SkyModalLinkListModule,
992
+ SkyNeedsAttentionModule,
993
+ SkyPageHeaderModule,
994
+ SkyPagesResourcesModule,
995
+ SkyThemeModule,
996
+ SkyWaitModule,
997
+ SkyPageModule,
998
+ ],
999
+ declarations: [
1000
+ SkyActionHubButtonsComponent,
1001
+ SkyActionHubComponent,
1002
+ SkyActionHubContentComponent,
1003
+ SkyActionHubRelatedLinksSortPipe,
1004
+ ],
1005
+ exports: [
1006
+ SkyActionHubButtonsComponent,
1007
+ SkyActionHubComponent,
1008
+ SkyActionHubContentComponent,
1009
+ ],
1010
+ }]
1011
+ }] });
1012
+
1007
1013
  /**
1008
1014
  * Generated bundle index. Do not edit.
1009
1015
  */