novo-elements 13.2.0-next.2 → 13.2.0-next.4
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/elements/card/Card.scss +60 -7
- package/elements/card/CardContent.scss +3 -0
- package/elements/card/CardHeader.scss +23 -0
- package/elements/card/index.d.ts +5 -3
- package/elements/common/index.d.ts +14 -4
- package/elements/dropdown/Dropdown.scss +0 -1
- package/elements/list/list-item-content.scss +13 -4
- package/fesm2022/novo-elements-elements-card.mjs +27 -21
- package/fesm2022/novo-elements-elements-card.mjs.map +1 -1
- package/fesm2022/novo-elements-elements-common.mjs +45 -14
- package/fesm2022/novo-elements-elements-common.mjs.map +1 -1
- package/fesm2022/novo-elements-elements-dropdown.mjs +2 -2
- package/fesm2022/novo-elements-elements-dropdown.mjs.map +1 -1
- package/fesm2022/novo-elements-elements-list.mjs +2 -2
- package/fesm2022/novo-elements-elements-list.mjs.map +1 -1
- package/package.json +1 -1
- package/styles/themes/bh2026.scss +7 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"novo-elements-elements-card.mjs","sources":["../../../projects/novo-elements/src/elements/card/Card.ts","../../../projects/novo-elements/src/elements/card/Card.module.ts","../../../projects/novo-elements/src/elements/card/novo-elements-elements-card.ts"],"sourcesContent":["// NG2\nimport { Component, EventEmitter, HostBinding, Input, OnChanges, OnInit, Output, SimpleChanges } from '@angular/core';\n// APP\nimport { NovoLabelService } from 'novo-elements/services';\nimport { BooleanInput } from 'novo-elements/utils';\n\n@Component({\n selector: 'novo-card-actions',\n template: '<ng-content></ng-content>',\n standalone: false,\n})\nexport class CardActionsElement {}\n\n/**\n * Content of a card, needed as it's used as a selector in the API.\n */\n@Component({\n selector: 'novo-card-content, [novo-card-content], [novoCardContent]',\n host: { class: 'novo-card-content', '[class.condensed]': 'condensed' },\n template: '<ng-content></ng-content>',\n styleUrls: ['./CardContent.scss'],\n standalone: false,\n})\nexport class CardContentElement {\n @Input() @BooleanInput() condensed: boolean = false;\n}\n\n/**\n * Content of a card, needed as it's used as a selector in the API.\n */\n@Component({\n selector: 'novo-card-header, [novo-card-header], [novoCardHeader]',\n host: { class: 'novo-card-header' },\n template: `\n <ng-content select=\"novo-avatar, [novo-avatar], novo-icon\"></ng-content>\n <div class=\"novo-card-header-text\">\n <ng-content select=\"novo-title, [novo-title], novo-text, novo-label, novo-caption\"></ng-content>\n </div>\n <ng-content></ng-content>\n <div class=\"novo-card-header-actions\">\n <ng-content select=\"novo-action\"></ng-content>\n </div>\n `,\n styleUrls: ['./CardHeader.scss'],\n standalone: false,\n})\nexport class CardHeaderElement {}\n\n@Component({\n selector: 'novo-card-footer, [novo-card-footer], [novoCardFooter]',\n host: { class: 'novo-card-footer' },\n template: '<ng-content></ng-content>',\n styleUrls: ['./CardFooter.scss'],\n standalone: false,\n})\nexport class CardFooterElement {}\n\n@Component({\n selector: 'novo-card',\n host: {\n class: 'novo-card',\n '[attr.data-automation-id]': 'cardAutomationId',\n '[class.loading]': 'loading || config.loading',\n },\n template: `\n <!--Loading-->\n <div class=\"card-loading-container\" *ngIf=\"loading || config.loading\">\n <novo-loading theme=\"line\" [attr.data-automation-id]=\"cardAutomationId + '-loading'\"></novo-loading>\n </div>\n <!--Card Header-->\n <header *ngIf=\"title || config.title\">\n <div class=\"title\">\n <!--Grabber Icon-->\n <novo-icon\n *ngIf=\"move || config.move\"\n tooltip=\"{{ labels.move }}\"\n tooltipPosition=\"bottom-right\"\n [attr.data-automation-id]=\"cardAutomationId + '-move'\"\n >move</novo-icon\n >\n <!--Card Title-->\n <h3 [attr.data-automation-id]=\"cardAutomationId + '-title'\">\n <span [tooltip]=\"iconTooltip\" tooltipPosition=\"right\"><i *ngIf=\"icon\" [ngClass]=\"iconClass\"></i></span>\n {{ title || config.title }}\n </h3>\n </div>\n <!--Card Actions-->\n <div class=\"actions\" [attr.data-automation-id]=\"cardAutomationId + '-actions'\">\n <ng-content select=\"novo-card-actions\"></ng-content>\n <novo-button\n theme=\"icon\"\n icon=\"refresh\"\n (click)=\"toggleRefresh()\"\n *ngIf=\"refresh || config.refresh\"\n [attr.data-automation-id]=\"cardAutomationId + '-refresh'\"\n tooltip=\"{{ labels.refresh }}\"\n tooltipPosition=\"bottom-left\"\n ></novo-button>\n\n <novo-button\n theme=\"icon\"\n icon=\"close-o\"\n (click)=\"toggleClose()\"\n *ngIf=\"close || config.close\"\n [attr.data-automation-id]=\"cardAutomationId + '-close'\"\n tooltip=\"{{ labels.close }}\"\n tooltipPosition=\"bottom-left\"\n ></novo-button>\n </div>\n </header>\n <!--Content (transcluded)-->\n <ng-content *ngIf=\"!(loading || config.loading) && !(message || config.message)\"></ng-content>\n <!--Error/Empty Message-->\n <p\n class=\"card-message\"\n *ngIf=\"!(loading || config.loading) && (message || config.message)\"\n [attr.data-automation-id]=\"cardAutomationId + '-message'\"\n >\n <i *ngIf=\"messageIconClass\" [ngClass]=\"messageIconClass\"></i> <span [innerHtml]=\"message || config.message\"></span>\n </p>\n <!--Card Footer-->\n <ng-content\n *ngIf=\"!(loading || config.loading) && !(message || config.message)\"\n select=\"footer,novo-card-footer,[novo-card-footer],[novoCardFooter]\"\n ></ng-content>\n `,\n styleUrls: ['./Card.scss'],\n standalone: false,\n})\nexport class CardElement implements OnChanges, OnInit {\n @Input()\n padding: boolean = true;\n @Input()\n config: any = {};\n @Input()\n title: string;\n @Input()\n message: string;\n @Input()\n messageIcon: string;\n @Input()\n icon: string;\n @Input()\n iconTooltip: string;\n @Input()\n refresh: boolean;\n @Input()\n close: boolean;\n @Input()\n move: boolean;\n @Input()\n loading: boolean;\n\n @Input()\n @BooleanInput()\n @HostBinding('class.novo-card-inline')\n inline: boolean;\n\n @Input()\n inset: string = 'none';\n @HostBinding('class')\n get hbInset() {\n return `novo-card-inset-${this.inset}`;\n }\n\n @Output()\n onClose: EventEmitter<void> = new EventEmitter();\n @Output()\n onRefresh: EventEmitter<void> = new EventEmitter();\n\n cardAutomationId: string;\n labels: NovoLabelService;\n iconClass: string | null;\n messageIconClass: string;\n\n constructor(labels: NovoLabelService) {\n this.labels = labels;\n }\n\n ngOnInit() {\n this.config = this.config || {};\n }\n\n ngOnChanges(changes?: SimpleChanges) {\n this.config = this.config || {};\n this.cardAutomationId = `${(this.title || this.config.title || 'no-title').trim().toLowerCase().replace(/\\s/g, '-')}-card`;\n\n const newIcon: string = this.icon || this.config.icon;\n const newMessageIcon: string = this.messageIcon || this.config.messageIcon;\n this.iconClass = newIcon ? `bhi-${newIcon}` : null;\n this.messageIconClass = newMessageIcon ? `bhi-${newMessageIcon}` : null;\n }\n\n toggleClose() {\n if (!this.config.onClose) {\n this.onClose.next();\n } else {\n this.config.onClose();\n }\n }\n\n toggleRefresh() {\n if (!this.config.onRefresh) {\n this.onRefresh.next();\n } else {\n this.config.onRefresh();\n }\n }\n}\n","// NG2\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n// APP\nimport { NovoButtonModule } from 'novo-elements/elements/button';\nimport { NovoIconModule } from 'novo-elements/elements/icon';\nimport { NovoLoadingModule } from 'novo-elements/elements/loading';\nimport { NovoTooltipModule } from 'novo-elements/elements/tooltip';\nimport { CardActionsElement, CardContentElement, CardElement, CardFooterElement, CardHeaderElement } from './Card';\n\n@NgModule({\n imports: [CommonModule, NovoIconModule, NovoButtonModule, NovoLoadingModule, NovoTooltipModule],\n declarations: [CardElement, CardActionsElement, CardContentElement, CardHeaderElement, CardFooterElement],\n exports: [CardElement, CardActionsElement, CardContentElement, CardHeaderElement, CardFooterElement],\n})\nexport class NovoCardModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;MAWa,kBAAkB,CAAA;+GAAlB,kBAAkB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAlB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,C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AA,CAAA,QAAA,EAAA,CAAA,CAAA;AAAd,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,cAAc,EAAA,YAAA,EAAA,CAHV,WAAW,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,iBAAiB,CAAA,EAAA,OAAA,EAAA,CAD9F,YAAY,EAAE,cAAc,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,iBAAiB,CAAA,EAAA,OAAA,EAAA,CAEpF,WAAW,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,iBAAiB,CAAA,EAAA,CAAA,CAAA;gHAExF,cAAc,EAAA,OAAA,EAAA,CAJf,YAAY,EAAE,cAAc,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,iBAAiB,CAAA,EAAA,CAAA,CAAA;;4FAInF,cAAc,EAAA,UAAA,EAAA,CAAA;kBAL1B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,YAAY,EAAE,cAAc,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,iBAAiB,CAAC;oBAC/F,YAAY,EAAE,CAAC,WAAW,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,iBAAiB,CAAC;oBACzG,OAAO,EAAE,CAAC,WAAW,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,iBAAiB,CAAC;AACrG,iBAAA;;;ACdD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"novo-elements-elements-card.mjs","sources":["../../../projects/novo-elements/src/elements/card/Card.ts","../../../projects/novo-elements/src/elements/card/Card.module.ts","../../../projects/novo-elements/src/elements/card/novo-elements-elements-card.ts"],"sourcesContent":["// NG2\nimport { Component, EventEmitter, HostBinding, Input, OnChanges, OnInit, Output, SimpleChanges } from '@angular/core';\n// APP\nimport { NovoLabelService } from 'novo-elements/services';\nimport { BooleanInput } from 'novo-elements/utils';\n\n@Component({\n selector: 'novo-card-actions',\n template: '<ng-content></ng-content>',\n standalone: false,\n})\nexport class CardActionsElement {}\n\n/**\n * Content of a card, needed as it's used as a selector in the API.\n */\n@Component({\n selector: 'novo-card-content, [novo-card-content], [novoCardContent]',\n host: { class: 'novo-card-content', '[class.condensed]': 'condensed' },\n template: '<ng-content></ng-content>',\n styleUrls: ['./CardContent.scss'],\n standalone: false,\n})\nexport class CardContentElement {\n @Input() @BooleanInput() condensed: boolean = false;\n}\n\n/**\n * Content of a card, needed as it's used as a selector in the API.\n */\n@Component({\n selector: 'novo-card-header, [novo-card-header], [novoCardHeader]',\n host: { class: 'novo-card-header' },\n template: `\n <ng-content select=\"novo-avatar, [novo-avatar], novo-icon\"></ng-content>\n <div class=\"novo-card-header-text\">\n <ng-content select=\"novo-title, [novo-title], novo-text, novo-label, novo-caption\"></ng-content>\n </div>\n <ng-content></ng-content>\n <div class=\"novo-card-header-actions\">\n <ng-content select=\"novo-action\"></ng-content>\n </div>\n `,\n styleUrls: ['./CardHeader.scss'],\n standalone: false,\n})\nexport class CardHeaderElement {}\n\n@Component({\n selector: 'novo-card-footer, [novo-card-footer], [novoCardFooter]',\n host: { class: 'novo-card-footer' },\n template: '<ng-content></ng-content>',\n styleUrls: ['./CardFooter.scss'],\n standalone: false,\n})\nexport class CardFooterElement {}\n\n@Component({\n selector: 'novo-card',\n host: {\n class: 'novo-card',\n '[attr.data-automation-id]': 'cardAutomationId',\n '[class.loading]': 'loading || config.loading',\n },\n template: `\n <!--Loading-->\n <div class=\"card-loading-container\" *ngIf=\"loading || config.loading\">\n <novo-loading theme=\"line\" [attr.data-automation-id]=\"cardAutomationId + '-loading'\"></novo-loading>\n </div>\n <!--Card Header-->\n <header *ngIf=\"title || config.title\">\n <div class=\"title\">\n <!--Grabber Icon-->\n <novo-icon\n *ngIf=\"move || config.move\"\n tooltip=\"{{ labels.move }}\"\n tooltipPosition=\"bottom-right\"\n class=\"card-move-handle\"\n [attr.data-automation-id]=\"cardAutomationId + '-move'\"\n >move</novo-icon\n >\n <!--Card Title-->\n <h3 [attr.data-automation-id]=\"cardAutomationId + '-title'\">\n <span [tooltip]=\"iconTooltip\" tooltipPosition=\"right\"><i *ngIf=\"iconClass\" class=\"card-flag-icon\" [ngClass]=\"iconClass\"></i></span><!--\n --><span class=\"novo-card-header-text\">{{ title || config.title }}</span>\n </h3>\n </div>\n <!--Card Actions-->\n <div class=\"actions\" [attr.data-automation-id]=\"cardAutomationId + '-actions'\">\n <ng-content select=\"novo-card-actions\"></ng-content>\n <novo-button\n theme=\"icon\"\n [icon]=\"'refresh-o' | ifBh2026Theme : 'refresh'\"\n (click)=\"toggleRefresh()\"\n *ngIf=\"refresh || config.refresh\"\n [attr.data-automation-id]=\"cardAutomationId + '-refresh'\"\n tooltip=\"{{ labels.refresh }}\"\n tooltipPosition=\"bottom-left\"\n ></novo-button>\n\n <novo-button\n theme=\"icon\"\n [icon]=\"'x' | ifBh2026Theme : 'close-o'\"\n (click)=\"toggleClose()\"\n *ngIf=\"close || config.close\"\n [attr.data-automation-id]=\"cardAutomationId + '-close'\"\n tooltip=\"{{ labels.close }}\"\n tooltipPosition=\"bottom-left\"\n ></novo-button>\n </div>\n </header>\n <!--Content (transcluded)-->\n <ng-content *ngIf=\"!(loading || config.loading) && !(message || config.message)\"></ng-content>\n <!--Error/Empty Message-->\n <p\n class=\"card-message\"\n *ngIf=\"!(loading || config.loading) && (message || config.message)\"\n [attr.data-automation-id]=\"cardAutomationId + '-message'\"\n >\n <i *ngIf=\"messageIconClass\" [ngClass]=\"messageIconClass\"></i> <span [innerHtml]=\"message || config.message\"></span>\n </p>\n <!--Card Footer-->\n <ng-content\n *ngIf=\"!(loading || config.loading) && !(message || config.message)\"\n select=\"footer,novo-card-footer,[novo-card-footer],[novoCardFooter]\"\n ></ng-content>\n `,\n styleUrls: ['./Card.scss'],\n standalone: false,\n})\nexport class CardElement implements OnChanges, OnInit {\n @Input()\n padding: boolean = true;\n @Input()\n config: any = {};\n @Input()\n title: string;\n @Input()\n message: string;\n @Input()\n messageIcon: string;\n @Input()\n icon: string;\n // A feature for the 2026 styles that lets a card icon match either the icon default color (auto) or the --page-entity-color css variable\n @Input()\n iconColorClass: 'icon-color-auto' | 'icon-color-parent' | undefined;\n @Input()\n iconTooltip: string;\n @Input()\n refresh: boolean;\n @Input()\n close: boolean;\n @Input()\n move: boolean;\n @Input()\n loading: boolean;\n\n @Input()\n @BooleanInput()\n @HostBinding('class.novo-card-inline')\n inline: boolean;\n\n @Input()\n inset: string = 'none';\n\n @HostBinding('class')\n get cardClass() {\n return `${this.iconColorClass || ''} novo-card-inset-${this.inset}`;\n }\n\n @Output()\n onClose: EventEmitter<void> = new EventEmitter();\n @Output()\n onRefresh: EventEmitter<void> = new EventEmitter();\n\n cardAutomationId: string;\n labels: NovoLabelService;\n iconClass: string | null;\n messageIconClass: string;\n\n constructor(labels: NovoLabelService) {\n this.labels = labels;\n }\n\n ngOnInit() {\n this.config = this.config || {};\n }\n\n ngOnChanges(changes?: SimpleChanges) {\n this.config = this.config || {};\n this.cardAutomationId = `${(this.title || this.config.title || 'no-title').trim().toLowerCase().replace(/\\s/g, '-')}-card`;\n\n const newIcon: string = this.icon || this.config.icon;\n const newMessageIcon: string = this.messageIcon || this.config.messageIcon;\n this.iconClass = newIcon ? `bhi-${newIcon}` : null;\n this.messageIconClass = newMessageIcon ? `bhi-${newMessageIcon}` : null;\n }\n\n toggleClose() {\n if (!this.config.onClose) {\n this.onClose.next();\n } else {\n this.config.onClose();\n }\n }\n\n toggleRefresh() {\n if (!this.config.onRefresh) {\n this.onRefresh.next();\n } else {\n this.config.onRefresh();\n }\n }\n}\n","// NG2\nimport { CommonModule } from '@angular/common';\nimport { NgModule } from '@angular/core';\n// APP\nimport { NovoButtonModule } from 'novo-elements/elements/button';\nimport { NovoIconModule } from 'novo-elements/elements/icon';\nimport { NovoLoadingModule } from 'novo-elements/elements/loading';\nimport { NovoTooltipModule } from 'novo-elements/elements/tooltip';\nimport { NovoCommonModule } from 'novo-elements/elements/common';\nimport { CardActionsElement, CardContentElement, CardElement, CardFooterElement, CardHeaderElement } from './Card';\n\n@NgModule({\n imports: [CommonModule, NovoIconModule, NovoButtonModule, NovoLoadingModule, NovoTooltipModule, NovoCommonModule],\n declarations: [CardElement, CardActionsElement, CardContentElement, CardHeaderElement, CardFooterElement],\n exports: [CardElement, CardActionsElement, CardContentElement, CardHeaderElement, CardFooterElement],\n})\nexport class NovoCardModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;MAWa,kBAAkB,CAAA;+GAAlB,kBAAkB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAlB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,kBAAkB,8EAHjB,2BAA2B,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,CAAA;;4FAG5B,kBAAkB,EAAA,UAAA,EAAA,CAAA;kBAL9B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACP,oBAAA,QAAQ,EAAE,mBAAmB;AAC7B,oBAAA,QAAQ,EAAE,2BAA2B;AACrC,oBAAA,UAAU,EAAE,KAAK;AACpB,iBAAA;;AAGD;;AAEG;MAQU,kBAAkB,CAAA;AAP/B,IAAA,WAAA,GAAA;QAQ2B,IAAA,CAAA,SAAS,GAAY,KAAK;AACpD,IAAA;+GAFY,kBAAkB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAlB,IAAA,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AE,iBAAiB,CAAA,EAAA,OAAA,EAAA,CAD9F,YAAY,EAAE,cAAc,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,gBAAgB,CAAA,EAAA,OAAA,EAAA,CAEtG,WAAW,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,iBAAiB,CAAA,EAAA,CAAA,CAAA;gHAExF,cAAc,EAAA,OAAA,EAAA,CAJf,YAAY,EAAE,cAAc,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,gBAAgB,CAAA,EAAA,CAAA,CAAA;;4FAIrG,cAAc,EAAA,UAAA,EAAA,CAAA;kBAL1B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,cAAc,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,gBAAgB,CAAC;oBACjH,YAAY,EAAE,CAAC,WAAW,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,iBAAiB,CAAC;oBACzG,OAAO,EAAE,CAAC,WAAW,EAAE,kBAAkB,EAAE,kBAAkB,EAAE,iBAAiB,EAAE,iBAAiB,CAAC;AACrG,iBAAA;;;ACfD;;AAEG;;;;"}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import * as i1 from '@angular/common';
|
|
2
2
|
import { CommonModule } from '@angular/common';
|
|
3
3
|
import * as i0 from '@angular/core';
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
4
|
+
import { signal, inject, DOCUMENT, computed, Injectable, HostBinding, Input, Directive, Host, Optional, Inject, ChangeDetectionStrategy, ViewEncapsulation, Component, NgModule, InjectionToken, EventEmitter, Output, input, Pipe, DestroyRef, TemplateRef, ViewChild } from '@angular/core';
|
|
5
|
+
import { toObservable, takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
6
|
+
import { map, of, Subject, fromEvent, merge } from 'rxjs';
|
|
6
7
|
import { spacing } from 'novo-design-tokens';
|
|
7
8
|
import { BooleanInput, Helpers } from 'novo-elements/utils';
|
|
8
9
|
import { ANIMATION_MODULE_TYPE } from '@angular/platform-browser/animations';
|
|
@@ -11,7 +12,6 @@ import { hasModifierKey } from '@angular/cdk/keycodes';
|
|
|
11
12
|
import * as i1$1 from '@angular/cdk/overlay';
|
|
12
13
|
import { OverlayContainer, OverlayConfig, OverlayModule } from '@angular/cdk/overlay';
|
|
13
14
|
import { TemplatePortal } from '@angular/cdk/portal';
|
|
14
|
-
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
15
15
|
import { filter, first, switchMap } from 'rxjs/operators';
|
|
16
16
|
import { ScrollingModule } from '@angular/cdk/scrolling';
|
|
17
17
|
import { FormsModule } from '@angular/forms';
|
|
@@ -41,15 +41,24 @@ class NovoThemeOptions {
|
|
|
41
41
|
class NovoTheme {
|
|
42
42
|
constructor() {
|
|
43
43
|
this._defaultTheme = { themeName: DEFAULT_THEME };
|
|
44
|
-
this.
|
|
44
|
+
this._currentTheme = signal(undefined, ...(ngDevMode ? [{ debugName: "_currentTheme" }] : []));
|
|
45
|
+
this.currentTheme = this._currentTheme.asReadonly();
|
|
46
|
+
this.onThemeChange = toObservable(this._currentTheme).pipe(map(theme => ({
|
|
47
|
+
themeName: theme?.themeName,
|
|
48
|
+
options: theme,
|
|
49
|
+
})));
|
|
50
|
+
this.document = inject(DOCUMENT);
|
|
51
|
+
this.isBh2026 = computed(() => {
|
|
52
|
+
return this.currentTheme()?.themeName?.includes('bh2026');
|
|
53
|
+
}, ...(ngDevMode ? [{ debugName: "isBh2026" }] : []));
|
|
45
54
|
}
|
|
46
55
|
/** Name of the theme being used. defaults to `bh2022-light`. */
|
|
47
56
|
get themeName() {
|
|
48
|
-
return this._currentTheme?.themeName || this._defaultTheme.themeName;
|
|
57
|
+
return this._currentTheme()?.themeName || this._defaultTheme.themeName;
|
|
49
58
|
}
|
|
50
59
|
set themeName(value) {
|
|
51
|
-
|
|
52
|
-
this.changeTheme(
|
|
60
|
+
const newTheme = { themeName: value };
|
|
61
|
+
this.changeTheme(newTheme);
|
|
53
62
|
}
|
|
54
63
|
use(options) {
|
|
55
64
|
// future: don't change the theme if the theme given is already selected
|
|
@@ -61,15 +70,14 @@ class NovoTheme {
|
|
|
61
70
|
* Changes the current theme
|
|
62
71
|
*/
|
|
63
72
|
changeTheme(theme) {
|
|
64
|
-
this._currentTheme
|
|
73
|
+
this._currentTheme.set(theme);
|
|
65
74
|
this.applyThemeToDom(theme.themeName);
|
|
66
|
-
this.onThemeChange.emit({ themeName: theme.themeName, options: theme });
|
|
67
75
|
}
|
|
68
76
|
applyThemeToDom(themeName) {
|
|
69
|
-
if (typeof document === 'undefined' || !document.documentElement) {
|
|
77
|
+
if (typeof this.document === 'undefined' || !this.document.documentElement) {
|
|
70
78
|
return;
|
|
71
79
|
}
|
|
72
|
-
const root = document.documentElement;
|
|
80
|
+
const root = this.document.documentElement;
|
|
73
81
|
const normalized = normalizeThemeName(themeName);
|
|
74
82
|
const generation = normalized.split('-')[0];
|
|
75
83
|
root.classList.toggle('theme-dark', normalized.endsWith('-dark'));
|
|
@@ -1534,6 +1542,25 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
|
|
|
1534
1542
|
}, standalone: false, styles: [":host{display:block;font-weight:500;line-height:1.5;color:var(--text-main, #3d464d);white-space:nowrap;text-overflow:ellipsis;font-size:var(--font-size-title);transition:color .2s ease-out,opacity .2s ease-out;vertical-align:middle}:host.text-capitalize{text-transform:capitalize}:host.text-uppercase{text-transform:uppercase}:host.text-nowrap{white-space:nowrap}:host.text-ellipsis{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}:host.text-size-default{font-size:inherit}:host.text-size-body{font-size:var(--font-size-body)}:host.text-size-xs{font-size:var(--font-size-xs)}:host.text-size-sm{font-size:var(--font-size-sm)}:host.text-size-md{font-size:var(--font-size-md)}:host.text-size-lg{font-size:var(--font-size-lg)}:host.text-size-xl{font-size:var(--font-size-xl)}:host.text-size-2xl{font-size:var(--font-size-2xl)}:host.text-size-3xl{font-size:var(--font-size-3xl)}:host.text-size-smaller{font-size:.8em}:host.text-size-larger{font-size:1.2em}:host.text-color-black{color:var(--color-black)}:host.text-color-white{color:var(--color-white)}:host.text-color-gray{color:var(--color-gray)}:host.text-color-grey{color:var(--color-grey)}:host.text-color-offWhite{color:var(--color-off-white)}:host.text-color-bright{color:var(--color-bright)}:host.text-color-light{color:var(--color-light)}:host.text-color-neutral{color:var(--color-neutral)}:host.text-color-dark{color:var(--color-dark)}:host.text-color-orange{color:var(--color-orange)}:host.text-color-navigation{color:var(--color-navigation)}:host.text-color-skyBlue{color:var(--color-sky-blue)}:host.text-color-steel{color:var(--color-steel)}:host.text-color-metal{color:var(--color-metal)}:host.text-color-sand{color:var(--color-sand)}:host.text-color-silver{color:var(--color-silver)}:host.text-color-stone{color:var(--color-stone)}:host.text-color-ash{color:var(--color-ash)}:host.text-color-anonymous{color:var(--color-anonymous)}:host.text-color-slate{color:var(--color-slate)}:host.text-color-onyx{color:var(--color-onyx)}:host.text-color-charcoal{color:var(--color-charcoal)}:host.text-color-moonlight{color:var(--color-moonlight)}:host.text-color-midnight{color:var(--color-midnight)}:host.text-color-darkness{color:var(--color-darkness)}:host.text-color-navy{color:var(--color-navy)}:host.text-color-aqua{color:var(--color-aqua)}:host.text-color-ocean{color:var(--color-ocean)}:host.text-color-mint{color:var(--color-mint)}:host.text-color-grass{color:var(--color-grass)}:host.text-color-sunflower{color:var(--color-sunflower)}:host.text-color-bittersweet{color:var(--color-bittersweet)}:host.text-color-grapefruit{color:var(--color-grapefruit)}:host.text-color-carnation{color:var(--color-carnation)}:host.text-color-lavender{color:var(--color-lavender)}:host.text-color-mountain{color:var(--color-mountain)}:host.text-color-info{color:var(--color-info)}:host.text-color-positive{color:var(--color-positive)}:host.text-color-success{color:var(--color-success)}:host.text-color-negative{color:var(--color-negative)}:host.text-color-danger{color:var(--color-danger)}:host.text-color-error{color:var(--color-error)}:host.text-color-warning{color:var(--color-warning)}:host.text-color-empty{color:var(--color-empty)}:host.text-color-disabled{color:var(--color-disabled)}:host.text-color-background{color:var(--color-background)}:host.text-color-backgroundDark{color:var(--color-background-dark)}:host.text-color-border{color:var(--color-border)}:host.text-color-border2{color:var(--color-border2)}:host.text-color-text{color:var(--color-text)}:host.text-color-presentation{color:var(--color-presentation)}:host.text-color-bullhorn{color:var(--color-bullhorn)}:host.text-color-pulse{color:var(--color-pulse)}:host.text-color-fastFind{color:var(--color-fast-find)}:host.text-color-toast{color:var(--color-toast)}:host.text-color-company{color:var(--color-company)}:host.text-color-candidate{color:var(--color-candidate)}:host.text-color-lead{color:var(--color-lead)}:host.text-color-contact{color:var(--color-contact)}:host.text-color-clientcontact{color:var(--color-clientcontact)}:host.text-color-opportunity{color:var(--color-opportunity)}:host.text-color-job{color:var(--color-job)}:host.text-color-joborder{color:var(--color-joborder)}:host.text-color-submission{color:var(--color-submission)}:host.text-color-sendout{color:var(--color-sendout)}:host.text-color-placement{color:var(--color-placement)}:host.text-color-note{color:var(--color-note)}:host.text-color-contract{color:var(--color-contract)}:host.text-color-task{color:var(--color-task)}:host.text-color-jobCode{color:var(--color-job-code)}:host.text-color-earnCode{color:var(--color-earn-code)}:host.text-color-invoiceStatement{color:var(--color-invoice-statement)}:host.text-color-billableCharge{color:var(--color-billable-charge)}:host.text-color-payableCharge{color:var(--color-payable-charge)}:host.text-color-user{color:var(--color-user)}:host.text-color-corporateUser{color:var(--color-corporate-user)}:host.text-color-distributionList{color:var(--color-distribution-list)}:host.text-color-credential{color:var(--color-credential)}:host.text-color-person{color:var(--color-person)}:host.margin-before{margin-top:.4rem}:host.margin-after{margin-bottom:.8rem}:host.text-length-small{max-width:40ch}:host.text-length-medium{max-width:55ch}:host.text-length-large{max-width:70ch}:host.text-weight-hairline{font-weight:var(--font-weight-hairline)}:host.text-weight-thin{font-weight:var(--font-weight-thin)}:host.text-weight-light{font-weight:var(--font-weight-light)}:host.text-weight-normal{font-weight:var(--font-weight-normal)}:host.text-weight-medium{font-weight:var(--font-weight-medium)}:host.text-weight-semibold{font-weight:var(--font-weight-semibold)}:host.text-weight-bold{font-weight:var(--font-weight-bold)}:host.text-weight-extrabold{font-weight:var(--font-weight-extrabold)}:host.text-weight-heavy{font-weight:var(--font-weight-heavy)}:host.text-weight-lighter{font-weight:lighter}:host.text-weight-bolder{font-weight:bolder}\n"] }]
|
|
1535
1543
|
}] });
|
|
1536
1544
|
|
|
1545
|
+
class If2026ThemePipe {
|
|
1546
|
+
constructor() {
|
|
1547
|
+
this.theme = inject(NovoTheme);
|
|
1548
|
+
}
|
|
1549
|
+
transform(value, elseVal = undefined) {
|
|
1550
|
+
return this.theme.isBh2026() ? value : elseVal;
|
|
1551
|
+
}
|
|
1552
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: If2026ThemePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
|
|
1553
|
+
static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "20.3.19", ngImport: i0, type: If2026ThemePipe, isStandalone: false, name: "ifBh2026Theme", pure: false }); }
|
|
1554
|
+
}
|
|
1555
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: If2026ThemePipe, decorators: [{
|
|
1556
|
+
type: Pipe,
|
|
1557
|
+
args: [{
|
|
1558
|
+
name: 'ifBh2026Theme',
|
|
1559
|
+
standalone: false,
|
|
1560
|
+
pure: false,
|
|
1561
|
+
}]
|
|
1562
|
+
}] });
|
|
1563
|
+
|
|
1537
1564
|
class NovoCommonModule {
|
|
1538
1565
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NovoCommonModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
1539
1566
|
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.19", ngImport: i0, type: NovoCommonModule, declarations: [NovoTemplate,
|
|
@@ -1553,7 +1580,8 @@ class NovoCommonModule {
|
|
|
1553
1580
|
FlexDirective,
|
|
1554
1581
|
ThemeColorDirective,
|
|
1555
1582
|
SwitchCasesDirective,
|
|
1556
|
-
VisibleDirective
|
|
1583
|
+
VisibleDirective,
|
|
1584
|
+
If2026ThemePipe], imports: [CommonModule, NovoOptionModule], exports: [NovoTemplate,
|
|
1557
1585
|
NovoText,
|
|
1558
1586
|
NovoTitle,
|
|
1559
1587
|
NovoCaption,
|
|
@@ -1570,7 +1598,8 @@ class NovoCommonModule {
|
|
|
1570
1598
|
FlexDirective,
|
|
1571
1599
|
ThemeColorDirective,
|
|
1572
1600
|
SwitchCasesDirective,
|
|
1573
|
-
VisibleDirective
|
|
1601
|
+
VisibleDirective,
|
|
1602
|
+
If2026ThemePipe] }); }
|
|
1574
1603
|
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NovoCommonModule, imports: [CommonModule, NovoOptionModule] }); }
|
|
1575
1604
|
}
|
|
1576
1605
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImport: i0, type: NovoCommonModule, decorators: [{
|
|
@@ -1596,6 +1625,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
|
|
|
1596
1625
|
ThemeColorDirective,
|
|
1597
1626
|
SwitchCasesDirective,
|
|
1598
1627
|
VisibleDirective,
|
|
1628
|
+
If2026ThemePipe,
|
|
1599
1629
|
],
|
|
1600
1630
|
declarations: [
|
|
1601
1631
|
NovoTemplate,
|
|
@@ -1616,6 +1646,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
|
|
|
1616
1646
|
ThemeColorDirective,
|
|
1617
1647
|
SwitchCasesDirective,
|
|
1618
1648
|
VisibleDirective,
|
|
1649
|
+
If2026ThemePipe,
|
|
1619
1650
|
],
|
|
1620
1651
|
}]
|
|
1621
1652
|
}] });
|
|
@@ -2149,5 +2180,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.19", ngImpo
|
|
|
2149
2180
|
* Generated bundle index. Do not edit.
|
|
2150
2181
|
*/
|
|
2151
2182
|
|
|
2152
|
-
export { AccentColorDirective, BackgroundColorDirective, BorderDirective, DEFAULT_THEME, ErrorStateMatcher, FillColorDirective, FlexDirective, GapDirective, MarginDirective, NOVO_OPTGROUP, NOVO_OPTION_PARENT_COMPONENT, NOVO_OVERLAY_CONTAINER, NovoBaseTextElement, NovoCaption, NovoCommonModule, NovoLabel, NovoLink, NovoOptgroup, NovoOptgroupBase, NovoOptgroupMixinBase, NovoOption, NovoOptionBase, NovoOptionModule, NovoOptionSelectionChange, NovoOverlayModule, NovoOverlayTemplateComponent, NovoPseudoCheckbox, NovoPseudoCheckboxModule, NovoTemplate, NovoText, NovoTheme, NovoThemeOptions, NovoTitle, PaddingDirective, ShowOnDirtyErrorStateMatcher, SwitchCasesDirective, TextColorDirective, ThemeColorDirective, VisibleDirective, _countGroupLabelsBeforeOption, _getOptionScrollPosition, getSpacingToken, mixinColor, mixinDisabled, mixinErrorState, mixinOverlay, mixinRequired, mixinSize, mixinTabIndex, normalizeThemeName };
|
|
2183
|
+
export { AccentColorDirective, BackgroundColorDirective, BorderDirective, DEFAULT_THEME, ErrorStateMatcher, FillColorDirective, FlexDirective, GapDirective, If2026ThemePipe, MarginDirective, NOVO_OPTGROUP, NOVO_OPTION_PARENT_COMPONENT, NOVO_OVERLAY_CONTAINER, NovoBaseTextElement, NovoCaption, NovoCommonModule, NovoLabel, NovoLink, NovoOptgroup, NovoOptgroupBase, NovoOptgroupMixinBase, NovoOption, NovoOptionBase, NovoOptionModule, NovoOptionSelectionChange, NovoOverlayModule, NovoOverlayTemplateComponent, NovoPseudoCheckbox, NovoPseudoCheckboxModule, NovoTemplate, NovoText, NovoTheme, NovoThemeOptions, NovoTitle, PaddingDirective, ShowOnDirtyErrorStateMatcher, SwitchCasesDirective, TextColorDirective, ThemeColorDirective, VisibleDirective, _countGroupLabelsBeforeOption, _getOptionScrollPosition, getSpacingToken, mixinColor, mixinDisabled, mixinErrorState, mixinOverlay, mixinRequired, mixinSize, mixinTabIndex, normalizeThemeName };
|
|
2153
2184
|
//# sourceMappingURL=novo-elements-elements-common.mjs.map
|