@hestia-earth/ui-components 0.31.21 → 0.31.22
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.
|
@@ -12,7 +12,7 @@ import { catchError, map, debounceTime, distinctUntilChanged, tap, switchMap, me
|
|
|
12
12
|
import { of, zip, ReplaySubject, timer, combineLatest, pipe, fromEvent, EMPTY, animationFrameScheduler, Subject, forkJoin, from, merge as merge$1 } from 'rxjs';
|
|
13
13
|
import { HttpClient } from '@angular/common/http';
|
|
14
14
|
import get from 'lodash.get';
|
|
15
|
-
import { SCHEMA_VERSION, SchemaType, NodeType, TermTermType, productTermTermType, nestedSearchableKeys, EmissionMethodTier, isExpandable, sortKeysByType, isTypeNode, BlankNodesKey, impactAssessmentTermTermType, measurementTermTermType, emissionTermTermType, inputTermTermType, CycleFunctionalUnit, NonBlankNodesKey, jsonldPath, SiteSiteType, isTypeValid, typeToSchemaType, managementTermTermType } from '@hestia-earth/schema';
|
|
15
|
+
import { SCHEMA_VERSION, SchemaType, NodeType, TermTermType, productTermTermType, nestedSearchableKeys, EmissionMethodTier, isExpandable, sortKeysByType, isTypeNode, BlankNodesKey, impactAssessmentTermTermType, measurementTermTermType, emissionTermTermType, inputTermTermType, CycleFunctionalUnit, NonBlankNodesKey, jsonldPath, SiteSiteType, isTypeValid, isTypeBlankNode, typeToSchemaType, managementTermTermType } from '@hestia-earth/schema';
|
|
16
16
|
import merge from 'lodash.merge';
|
|
17
17
|
import Chart, { Chart as Chart$1 } from 'chart.js';
|
|
18
18
|
import { toPrecision, isEmpty, unique, monthsBefore, toDashCase, isUndefined, toComma, isNumber, keyToLabel, isEqual as isEqual$2, sum, diffInDays } from '@hestia-earth/utils';
|
|
@@ -6858,7 +6858,7 @@ class NodeLogsModelsComponent {
|
|
|
6858
6858
|
});
|
|
6859
6859
|
}
|
|
6860
6860
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.4", ngImport: i0, type: NodeLogsModelsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
6861
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.4", type: NodeLogsModelsComponent, isStandalone: true, selector: "he-node-logs-models", inputs: { node: { classPropertyName: "node", publicName: "node", isSignal: true, isRequired: true, transformFunction: null }, nodeKey: { classPropertyName: "nodeKey", publicName: "nodeKey", isSignal: true, isRequired: true, transformFunction: null }, originalValues: { classPropertyName: "originalValues", publicName: "originalValues", isSignal: true, isRequired: false, transformFunction: null }, recalculatedValues: { classPropertyName: "recalculatedValues", publicName: "recalculatedValues", isSignal: true, isRequired: false, transformFunction: null }, terms: { classPropertyName: "terms", publicName: "terms", isSignal: true, isRequired: false, transformFunction: null }, filterTermTypes: { classPropertyName: "filterTermTypes", publicName: "filterTermTypes", isSignal: true, isRequired: false, transformFunction: null }, filterTermTypesLabel: { classPropertyName: "filterTermTypesLabel", publicName: "filterTermTypesLabel", isSignal: true, isRequired: false, transformFunction: null }, logsKey: { classPropertyName: "logsKey", publicName: "logsKey", isSignal: true, isRequired: false, transformFunction: null }, noDataMessage: { classPropertyName: "noDataMessage", publicName: "noDataMessage", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@if (showOutdatedLogs() || isLatestVersion()) {\n <div class=\"is-px-3 is-pb-3\">\n @if (!isExternal && logsUrl()) {\n <div class=\"has-text-right is-mb-2\">\n <a class=\"is-size-7\" [href]=\"logsUrl()\" target=\"_blank\">\n <fa-icon [icon]=\"faExternalLinkAlt\" />\n <span class=\"pl-2\">Open Full Logs</span>\n </a>\n </div>\n }\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n <tr>\n <th class=\"width-auto has-border-right\">\n @if (enableFilterByTerm()) {\n <div class=\"field\">\n <div class=\"control is-expanded has-icons-right\">\n <input\n class=\"input search-input is-small\"\n [ngModel]=\"term()\"\n name=\"term\"\n placeholder=\"Select entry by name\"\n [ngbTypeahead]=\"suggestTerm\"\n [focusFirst]=\"true\"\n (focus)=\"typeaheadFocus($event)\"\n (selectItem)=\"term.set($event.item)\"\n container=\"body\"\n popupClass=\"is-small\" />\n <a class=\"icon is-small is-right\" [class.is-hidden]=\"!term()\" (click)=\"term.set('')\">\n <fa-icon [icon]=\"faTimes\" />\n </a>\n </div>\n </div>\n }\n </th>\n @if (isBlankNodes()) {\n <th>\n <span class=\"is-pr-1\">Units</span>\n <span>(per </span>\n <span>\n @switch (functionalUnit()) {\n @case (CycleFunctionalUnit['1 ha']) {\n hectare\n }\n @default {\n kg product\n }\n }\n </span>\n <span>)</span>\n </th>\n }\n <th>Original</th>\n <th>Recalculated</th>\n @if (isBlankNodes()) {\n <th>Difference</th>\n }\n @for (c of methodModelsCount() | times; track i; let i = $index) {\n <th>({{ i + 1 }})</th>\n }\n </tr>\n </thead>\n <tbody>\n @if (loading()) {\n <tr>\n <td class=\"has-text-centered\" colspan=\"6\">\n <div class=\"has-text-center py-3\">\n <fa-icon [icon]=\"faSpinner\" animation=\"spin\" size=\"lg\" />\n </div>\n </td>\n </tr>\n } @else if (blankNodes().length === 0) {\n <tr>\n <td class=\"has-text-centered\" colspan=\"6\">\n <span>{{ noDataMessage() || 'No original data was provided and no gap filling occurred.' }}</span>\n </td>\n </tr>\n }\n @for (blankNode of blankNodes(); track trackByBlankNode($index, blankNode)) {\n <tr [class.has-sub-rows]=\"blankNode.canOpen\" [class.is-open]=\"blankNode.isOpen\">\n <td\n class=\"width-auto has-border-right is-nowrap\"\n [attr.title]=\"$any(blankNode).term?.name || $any(blankNode).key\">\n @if (blankNode.canOpen) {\n <a class=\"is-inline-block is-align-top pr-2 open-node\" (click)=\"blankNode.isOpen = !blankNode.isOpen\">\n <fa-icon [icon]=\"blankNode.isOpen ? faAngleDown : faAngleRight\" />\n </a>\n }\n @if ($any(blankNode).term) {\n <he-node-link class=\"is-inline-block is-pre-wrap\" [node]=\"$any(blankNode).term\">\n <span [innerHtml]=\"$any(blankNode).term.name | compound: $any(blankNode).term.termType\"></span>\n </he-node-link>\n }\n @if ($any(blankNode).key) {\n @if (nodeKey() === 'completeness') {\n <a [href]=\"schemaBaseUrl + '/Completeness#' + $any(blankNode).key\" target=\"_blank\">\n <span>{{ $any(blankNode).key | keyToLabel }}</span>\n </a>\n }\n } @else {\n <span>{{ $any(blankNode).key }}</span>\n }\n </td>\n @if (isBlankNodes()) {\n <td>\n @if ($any(blankNode).term) {\n <span\n class=\"is-nowrap\"\n [innerHtml]=\"$any(blankNode).term.units | compound: $any(blankNode).term.termType\"></span>\n }\n </td>\n }\n <td>\n <ng-template #originalValueContent>\n <span>{{ $any(blankNode).originalValue | precision: 3 | default: '-' }}</span>\n </ng-template>\n\n @if (blankNode.allParallel) {\n @for (model of $any(blankNode).configModels[0]; track model.methodId) {\n <div>\n {{ $any(blankNode).originalValueByMethodId[model.methodId] | precision: 3 | default: '-' }}\n </div>\n }\n } @else {\n <span\n [class.trigger-popover]=\"!!$any(blankNode).original?.[0]?.methodModel\"\n [ngbPopover]=\"blankNodeOriginalValueDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n placement=\"left\"\n container=\"body\"\n [disablePopover]=\"!$any(blankNode).original?.[0]?.methodModel\"\n [popoverContext]=\"{ blankNode }\">\n <span pointer>\n {{ $any(blankNode).originalValue | precision: 3 | default: '-' }}\n </span>\n </span>\n }\n </td>\n <td>\n @if (!blankNode.isOriginal || blankNode.isRecalculated) {\n @if (blankNode.allParallel) {\n @for (model of $any(blankNode).configModels[0]; track model.methodId) {\n <div>\n {{ $any(blankNode).recalculatedValueByMethodId[model.methodId] | precision: 3 | default: '-' }}\n </div>\n }\n } @else {\n <span>{{ blankNode.recalculatedValue | precision: 3 | default: '-' }}</span>\n }\n } @else {\n not recalculated\n }\n </td>\n @if (isBlankNodes()) {\n <td class=\"is-nowrap\">\n @if (blankNode.allParallel) {\n @for (model of $any(blankNode).configModels[0]; track model.methodId) {\n <div>\n @if (\n $any(blankNode).originalValueByMethodId[model.methodId] !== null &&\n $any(blankNode).recalculatedValueByMethodId[model.methodId] !== null\n ) {\n <he-blank-node-value-delta\n [value]=\"$any(blankNode).recalculatedValueByMethodId[model.methodId]\"\n [originalValue]=\"\n $any(blankNode).originalValueByMethodId[model.methodId]\n \"></he-blank-node-value-delta>\n } @else {\n -\n }\n </div>\n }\n } @else {\n @if ($any(blankNode).original.length && blankNode.isRecalculated) {\n <he-blank-node-value-delta\n [value]=\"blankNode.recalculatedValue\"\n [originalValue]=\"$any(blankNode).originalValue\"></he-blank-node-value-delta>\n } @else {\n -\n }\n }\n </td>\n }\n <ng-container *ngTemplateOutlet=\"blankNodeModels; context: { data: blankNode }\" />\n </tr>\n @for (subValue of $any(blankNode).keys; track trackBySubValue(subValue)) {\n <tr\n [class.is-hidden]=\"!blankNode.isOpen\"\n [class.has-sub-rows]=\"$any(blankNode).subValues?.length\"\n [class.is-sub-row]=\"blankNode.canOpen\">\n <td class=\"width-auto has-border-right is-nowrap\">\n <span class=\"is-inline-block is-align-top pl-3 pr-1 field-node\">Field:</span>\n @if (blankNode.type) {\n <a\n class=\"is-inline-block is-pre-wrap\"\n [href]=\"schemaBaseUrl + '/' + blankNode.type + '#' + subValue.key\"\n target=\"_blank\"\n [title]=\"subValue.key\">\n <span>{{ subValue.key }}</span>\n </a>\n }\n @if (!blankNode.type) {\n <span class=\"is-inline-block is-align-top\">{{ subValue.key }}</span>\n }\n </td>\n @if (isBlankNodes()) {\n <td></td>\n }\n <td>\n @if (subValue.originalValue !== null) {\n <span>\n {{ subValue.originalValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n -\n }\n </td>\n <td>\n @if (subValue.isRecalculated || subValue.key === 'impactAssessment') {\n <span>\n {{ subValue.recalculatedValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n not recalculated\n }\n </td>\n @if (isBlankNodes()) {\n <td>-</td>\n }\n <ng-container *ngTemplateOutlet=\"blankNodeModels; context: { data: subValue }\" />\n </tr>\n }\n @for (subValue of $any(blankNode).subValues; track trackBySubValue(subValue)) {\n @let term = subValue.term || termById(subValue.id);\n <tr [class.is-hidden]=\"!blankNode.isOpen\" [class.is-sub-row]=\"blankNode.canOpen\">\n <td class=\"width-auto has-border-right\">\n <span class=\"is-inline-block is-align-top pl-3\">{{ subValue.key | keyToLabel }}</span>\n @if (subValue.id) {\n <span class=\"is-inline-block\" class=\"is-inline-block is-align-top pr-1\">:</span>\n @switch (subValue.key) {\n @case ('backgroundData') {\n <span class=\"is-inline-block\">{{ term?.name }}</span>\n }\n @default {\n <he-node-link class=\"is-block pl-4\" [node]=\"term\" [attr.title]=\"term?.name\">\n <span [innerHtml]=\"term?.name | compound\"></span>\n </he-node-link>\n }\n }\n }\n </td>\n @if (isBlankNodes()) {\n <td>\n @if (subValue.showUnits && $any(blankNode).term) {\n <span\n class=\"is-nowrap\"\n [innerHtml]=\"$any(blankNode).term.units | compound: $any(blankNode).term.termType\"></span>\n }\n </td>\n }\n <td>\n @if (subValue.originalValue !== null) {\n <span>\n {{ subValue.originalValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n -\n }\n </td>\n <td>\n @if (subValue.isRecalculated) {\n <span>\n {{ subValue.recalculatedValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n not recalculated\n }\n </td>\n @if (isBlankNodes()) {\n <td>-</td>\n }\n <ng-container *ngTemplateOutlet=\"blankNodeModels; context: { data: subValue }\" />\n </tr>\n }\n }\n </tbody>\n </table>\n </he-data-table>\n <div class=\"is-size-7 is-italic\">\n <div class=\"columns is-variable is-1 my-0\">\n <div class=\"column is-narrow\">\n <p>\n <a class=\"is-inline-block pr-2\" (click)=\"showLegend.set(!showLegend())\">\n <fa-icon [icon]=\"showLegend() ? faAngleDown : faAngleRight\" />\n </a>\n <span class=\"is-inline-block\">Legend:</span>\n </p>\n @if (showLegend()) {\n <ul class=\"content pl-2\">\n @for (status of LogStatus | keyvalue; track status.value) {\n @if (logIcon[status.value]) {\n <li class=\"has-text-{{ logColor[status.value] }}\">\n <fa-icon [icon]=\"logIcon[status.value]\" />\n <span class=\"pl-1\">{{ status.value }}</span>\n </li>\n }\n }\n </ul>\n }\n </div>\n @if (filteredType()) {\n <div class=\"column has-text-right\">\n <label class=\"is-inline-block checkbox\">\n <input\n type=\"checkbox\"\n class=\"selector\"\n [ngModel]=\"onlyRequired\"\n (change)=\"onlyRequired.set($event.target.checked)\"\n [disabled]=\"!!term()\" />\n <span class=\"ml-2\">\n Show only {{ filteredType() | pluralize }} included in the default HESTIA system boundary\n </span>\n </label>\n </div>\n }\n </div>\n </div>\n </div>\n} @else {\n <div class=\"is-3 has-text-centered\">\n <p class=\"is-mb-2\">\n <fa-icon class=\"is-pr-2\" [icon]=\"faExclamationTriangle\" />\n <span>These logs might be incorrect as the calculations are outdated.</span>\n </p>\n <p class=\"is-underlined is-size-7\"><a (click)=\"showOutdatedLogs.set(true)\">View logs anyway.</a></p>\n </div>\n}\n\n<ng-template #blankNodeOriginalValueDetails let-blankNode=\"blankNode\">\n <span class=\"is-pr-1\">The original value was reported using:</span>\n <he-node-link\n class=\"is-inline-block\"\n linkClass=\"is-dark\"\n [node]=\"$any(blankNode).original[0].methodModel\"\n [showExternalLink]=\"true\">\n <span>{{ $any(blankNode).original[0].methodModel.name }}</span>\n </he-node-link>\n</ng-template>\n\n<ng-template #blankNodeModels let-data=\"data\">\n <ng-template #notInSystemBoundary>\n <td [attr.colspan]=\"methodModelsCount()\">\n <span>Not in HESTIA system boundary</span>\n </td>\n </ng-template>\n\n @if (isSystemBoundary(data)) {\n @for (configModel of methodModelsCount() | times; track configModelIndex; let configModelIndex = $index) {\n <td class=\"blank-node-index-{{ configModelIndex }}\">\n @if (getModelsAt(data, configModelIndex); as models) {\n @if ($any(models) | isArray) {\n <div>\n @for (model of $any(models); track model.methodId) {\n <p>\n <ng-container *ngTemplateOutlet=\"blankNodeModel; context: { model, data }\" />\n </p>\n }\n </div>\n } @else {\n <ng-container *ngTemplateOutlet=\"blankNodeModel; context: { model: models, data }\" />\n }\n } @else {\n -\n }\n </td>\n }\n } @else {\n -\n }\n</ng-template>\n\n<ng-template #blankNodeModel let-model=\"model\" let-data=\"data\">\n <span\n class=\"is-nowrap\"\n [class.trigger-popover]=\"model.showLogs\"\n [ngbPopover]=\"logDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n triggers=\"manual\"\n #p=\"ngbPopover\"\n placement=\"left\"\n container=\"body\"\n (click)=\"p.isOpen() ? p.close() : model.showLogs ? p.open({ logs: model.logs }) : null\">\n <span class=\"is-capitalized\">{{ methodName(model) }}</span>\n @if (model.logs?.methodTier || model.model?.methodTier) {\n <span class=\"pl-1\">[{{ model.logs?.methodTier || model.model?.methodTier }}]</span>\n }\n\n <span\n class=\"pl-1 has-text-{{ logColor[model.status] }} trigger-popover\"\n [ngbPopover]=\"logStatusDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n triggers=\"manual\"\n #p1=\"ngbPopover\"\n placement=\"left\"\n container=\"body\"\n (click)=\"$event.stopPropagation(); p1.isOpen() ? p1.close() : p1.open({ model, data })\">\n <fa-icon [icon]=\"logIcon[model.status]\" />\n </span>\n\n @if (model.model) {\n <span class=\"pl-1\">\n (\n <ng-container *ngTemplateOutlet=\"docsLink; context: { $implicit: model.model }\" />\n )\n </span>\n }\n </span>\n</ng-template>\n\n<ng-template #logDetails let-logs=\"logs\">\n <he-node-logs-models-logs [logs]=\"logs\" />\n</ng-template>\n\n<ng-template #logStatusDetails let-model=\"model\" let-data=\"data\">\n <he-node-logs-models-logs-status [nodeType]=\"nodeType()\" [model]=\"model\" [data]=\"\" />\n</ng-template>\n\n<ng-template #docsLink let-model>\n <a [href]=\"model.apiDocsPath || model.docPath || model.path\" target=\"_blank\" (click)=\"$event.stopPropagation()\">\n <span>Docs</span>\n <fa-icon class=\"ml-1\" [icon]=\"faExternalLinkAlt\" size=\"sm\" />\n </a>\n</ng-template>\n", styles: [":host{display:block}::ng-deep .table{background-color:transparent}::ng-deep .table td he-node-link{width:190px}@media screen and (max-width: 768px){::ng-deep .table td he-node-link{width:150px}}::ng-deep .table td .open-node+he-node-link{width:170px}@media screen and (max-width: 768px){::ng-deep .table td .open-node+he-node-link{width:130px}}::ng-deep .table td.has-border-right{box-shadow:1px 0 #6c8093}::ng-deep .table .has-sub-rows.is-open>td:first-child:before,::ng-deep .table .is-sub-row>td:first-child:before{display:block;position:absolute;content:\" \";background-color:#6c809333;height:100%;width:1px;top:0;left:12px}::ng-deep .table .has-sub-rows.is-open>td:first-child:before{top:25px}::ng-deep .table .popover-body .table-container{max-height:260px;overflow-y:auto}\n"], dependencies: [{ kind: "pipe", type: KeyValuePipe, name: "keyvalue" }, { kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "component", type: DataTableComponent, selector: "he-data-table", inputs: ["minHeight", "maxHeight", "small"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: NgbTypeahead, selector: "input[ngbTypeahead]", inputs: ["autocomplete", "container", "editable", "focusFirst", "inputFormatter", "ngbTypeahead", "resultFormatter", "resultTemplate", "selectOnExact", "showHint", "placement", "popperOptions", "popupClass"], outputs: ["selectItem"], exportAs: ["ngbTypeahead"] }, { kind: "component", type: NodeLinkComponent, selector: "he-node-link", inputs: ["node", "showExternalLink", "linkClass"] }, { kind: "component", type: BlankNodeValueDeltaComponent, selector: "he-blank-node-value-delta", inputs: ["value", "originalValue", "displayType"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: NgbPopover, selector: "[ngbPopover]", inputs: ["animation", "autoClose", "ngbPopover", "popoverTitle", "placement", "popperOptions", "triggers", "positionTarget", "container", "disablePopover", "popoverClass", "popoverContext", "openDelay", "closeDelay"], outputs: ["shown", "hidden"], exportAs: ["ngbPopover"] }, { kind: "pipe", type: CompoundPipe, name: "compound" }, { kind: "pipe", type: DefaultPipe, name: "default" }, { kind: "pipe", type: PluralizePipe, name: "pluralize" }, { kind: "pipe", type: KeyToLabelPipe, name: "keyToLabel" }, { kind: "pipe", type: PrecisionPipe, name: "precision" }, { kind: "pipe", type: TimesPipe, name: "times" }, { kind: "pipe", type: IsArrayPipe, name: "isArray" }, { kind: "component", type: NodeLogsModelsLogsComponent, selector: "he-node-logs-models-logs", inputs: ["logs"] }, { kind: "component", type: NodeLogsModelsLogsStatusComponent, selector: "he-node-logs-models-logs-status", inputs: ["nodeType", "model", "data"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
6861
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.4", type: NodeLogsModelsComponent, isStandalone: true, selector: "he-node-logs-models", inputs: { node: { classPropertyName: "node", publicName: "node", isSignal: true, isRequired: true, transformFunction: null }, nodeKey: { classPropertyName: "nodeKey", publicName: "nodeKey", isSignal: true, isRequired: true, transformFunction: null }, originalValues: { classPropertyName: "originalValues", publicName: "originalValues", isSignal: true, isRequired: false, transformFunction: null }, recalculatedValues: { classPropertyName: "recalculatedValues", publicName: "recalculatedValues", isSignal: true, isRequired: false, transformFunction: null }, terms: { classPropertyName: "terms", publicName: "terms", isSignal: true, isRequired: false, transformFunction: null }, filterTermTypes: { classPropertyName: "filterTermTypes", publicName: "filterTermTypes", isSignal: true, isRequired: false, transformFunction: null }, filterTermTypesLabel: { classPropertyName: "filterTermTypesLabel", publicName: "filterTermTypesLabel", isSignal: true, isRequired: false, transformFunction: null }, logsKey: { classPropertyName: "logsKey", publicName: "logsKey", isSignal: true, isRequired: false, transformFunction: null }, noDataMessage: { classPropertyName: "noDataMessage", publicName: "noDataMessage", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@if (showOutdatedLogs() || isLatestVersion()) {\n <div class=\"is-px-3 is-pb-3\">\n @if (!isExternal && logsUrl()) {\n <div class=\"has-text-right is-mb-2\">\n <a class=\"is-size-7\" [href]=\"logsUrl()\" target=\"_blank\">\n <fa-icon [icon]=\"faExternalLinkAlt\" />\n <span class=\"pl-2\">Open Full Logs</span>\n </a>\n </div>\n }\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n <tr>\n <th class=\"width-auto has-border-right\">\n @if (enableFilterByTerm()) {\n <div class=\"field\">\n <div class=\"control is-expanded has-icons-right\">\n <input\n class=\"input search-input is-small\"\n [ngModel]=\"term()\"\n name=\"term\"\n placeholder=\"Select entry by name\"\n [ngbTypeahead]=\"suggestTerm\"\n [focusFirst]=\"true\"\n (focus)=\"typeaheadFocus($event)\"\n (selectItem)=\"term.set($event.item)\"\n container=\"body\"\n popupClass=\"is-small\" />\n <a class=\"icon is-small is-right\" [class.is-hidden]=\"!term()\" (click)=\"term.set('')\">\n <fa-icon [icon]=\"faTimes\" />\n </a>\n </div>\n </div>\n }\n </th>\n @if (isBlankNodes()) {\n <th>\n <span class=\"is-pr-1\">Units</span>\n <span>(per </span>\n <span>\n @switch (functionalUnit()) {\n @case (CycleFunctionalUnit['1 ha']) {\n hectare\n }\n @default {\n kg product\n }\n }\n </span>\n <span>)</span>\n </th>\n }\n <th>Original</th>\n <th>Recalculated</th>\n @if (isBlankNodes()) {\n <th>Difference</th>\n }\n @for (c of methodModelsCount() | times; track i; let i = $index) {\n <th>({{ i + 1 }})</th>\n }\n </tr>\n </thead>\n <tbody>\n @if (loading()) {\n <tr>\n <td class=\"has-text-centered\" colspan=\"6\">\n <div class=\"has-text-center py-3\">\n <fa-icon [icon]=\"faSpinner\" animation=\"spin\" size=\"lg\" />\n </div>\n </td>\n </tr>\n } @else if (blankNodes().length === 0) {\n <tr>\n <td class=\"has-text-centered\" colspan=\"6\">\n <span>{{ noDataMessage() || 'No original data was provided and no gap filling occurred.' }}</span>\n </td>\n </tr>\n }\n @for (blankNode of blankNodes(); track trackByBlankNode($index, blankNode)) {\n <tr [class.has-sub-rows]=\"blankNode.canOpen\" [class.is-open]=\"blankNode.isOpen\">\n <td\n class=\"width-auto has-border-right is-nowrap\"\n [attr.title]=\"$any(blankNode).term?.name || $any(blankNode).key\">\n @if (blankNode.canOpen) {\n <a class=\"is-inline-block is-align-top pr-2 open-node\" (click)=\"blankNode.isOpen = !blankNode.isOpen\">\n <fa-icon [icon]=\"blankNode.isOpen ? faAngleDown : faAngleRight\" />\n </a>\n }\n @if ($any(blankNode).term) {\n <he-node-link class=\"is-inline-block is-pre-wrap\" [node]=\"$any(blankNode).term\">\n <span [innerHtml]=\"$any(blankNode).term.name | compound: $any(blankNode).term.termType\"></span>\n </he-node-link>\n }\n @if ($any(blankNode).key) {\n @if (nodeKey() === 'completeness') {\n <a [href]=\"schemaBaseUrl + '/Completeness#' + $any(blankNode).key\" target=\"_blank\">\n <span>{{ $any(blankNode).key | keyToLabel }}</span>\n </a>\n }\n } @else {\n <span>{{ $any(blankNode).key }}</span>\n }\n </td>\n @if (isBlankNodes()) {\n <td>\n @if ($any(blankNode).term) {\n <span\n class=\"is-nowrap\"\n [innerHtml]=\"$any(blankNode).term.units | compound: $any(blankNode).term.termType\"></span>\n }\n </td>\n }\n <td>\n <ng-template #originalValueContent>\n <span>{{ $any(blankNode).originalValue | precision: 3 | default: '-' }}</span>\n </ng-template>\n\n @if (blankNode.allParallel) {\n @for (model of $any(blankNode).configModels[0]; track model.methodId) {\n <div>\n {{ $any(blankNode).originalValueByMethodId[model.methodId] | precision: 3 | default: '-' }}\n </div>\n }\n } @else {\n <span\n [class.trigger-popover]=\"!!$any(blankNode).original?.[0]?.methodModel\"\n [ngbPopover]=\"blankNodeOriginalValueDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n placement=\"bottom left right auto\"\n container=\"body\"\n [disablePopover]=\"!$any(blankNode).original?.[0]?.methodModel\"\n [popoverContext]=\"{ blankNode }\">\n <span pointer>\n {{ $any(blankNode).originalValue | precision: 3 | default: '-' }}\n </span>\n </span>\n }\n </td>\n <td>\n @if (!blankNode.isOriginal || blankNode.isRecalculated) {\n @if (blankNode.allParallel) {\n @for (model of $any(blankNode).configModels[0]; track model.methodId) {\n <div>\n {{ $any(blankNode).recalculatedValueByMethodId[model.methodId] | precision: 3 | default: '-' }}\n </div>\n }\n } @else {\n <span>{{ blankNode.recalculatedValue | precision: 3 | default: '-' }}</span>\n }\n } @else {\n not recalculated\n }\n </td>\n @if (isBlankNodes()) {\n <td class=\"is-nowrap\">\n @if (blankNode.allParallel) {\n @for (model of $any(blankNode).configModels[0]; track model.methodId) {\n <div>\n @if (\n $any(blankNode).originalValueByMethodId[model.methodId] !== null &&\n $any(blankNode).recalculatedValueByMethodId[model.methodId] !== null\n ) {\n <he-blank-node-value-delta\n [value]=\"$any(blankNode).recalculatedValueByMethodId[model.methodId]\"\n [originalValue]=\"\n $any(blankNode).originalValueByMethodId[model.methodId]\n \"></he-blank-node-value-delta>\n } @else {\n -\n }\n </div>\n }\n } @else {\n @if ($any(blankNode).original.length && blankNode.isRecalculated) {\n <he-blank-node-value-delta\n [value]=\"blankNode.recalculatedValue\"\n [originalValue]=\"$any(blankNode).originalValue\"></he-blank-node-value-delta>\n } @else {\n -\n }\n }\n </td>\n }\n <ng-container *ngTemplateOutlet=\"blankNodeModels; context: { data: blankNode }\" />\n </tr>\n @for (subValue of $any(blankNode).keys; track trackBySubValue(subValue)) {\n <tr\n [class.is-hidden]=\"!blankNode.isOpen\"\n [class.has-sub-rows]=\"$any(blankNode).subValues?.length\"\n [class.is-sub-row]=\"blankNode.canOpen\">\n <td class=\"width-auto has-border-right is-nowrap\">\n <span class=\"is-inline-block is-align-top pl-3 pr-1 field-node\">Field:</span>\n @if (blankNode.type) {\n <a\n class=\"is-inline-block is-pre-wrap\"\n [href]=\"schemaBaseUrl + '/' + blankNode.type + '#' + subValue.key\"\n target=\"_blank\"\n [title]=\"subValue.key\">\n <span>{{ subValue.key }}</span>\n </a>\n }\n @if (!blankNode.type) {\n <span class=\"is-inline-block is-align-top\">{{ subValue.key }}</span>\n }\n </td>\n @if (isBlankNodes()) {\n <td></td>\n }\n <td>\n @if (subValue.originalValue !== null) {\n <span>\n {{ subValue.originalValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n -\n }\n </td>\n <td>\n @if (subValue.isRecalculated || subValue.key === 'impactAssessment') {\n <span>\n {{ subValue.recalculatedValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n not recalculated\n }\n </td>\n @if (isBlankNodes()) {\n <td>-</td>\n }\n <ng-container *ngTemplateOutlet=\"blankNodeModels; context: { data: subValue }\" />\n </tr>\n }\n @for (subValue of $any(blankNode).subValues; track trackBySubValue(subValue)) {\n @let term = subValue.term || termById(subValue.id);\n <tr [class.is-hidden]=\"!blankNode.isOpen\" [class.is-sub-row]=\"blankNode.canOpen\">\n <td class=\"width-auto has-border-right\">\n <span class=\"is-inline-block is-align-top pl-3\">{{ subValue.key | keyToLabel }}</span>\n @if (subValue.id) {\n <span class=\"is-inline-block\" class=\"is-inline-block is-align-top pr-1\">:</span>\n @switch (subValue.key) {\n @case ('backgroundData') {\n <span class=\"is-inline-block\">{{ term?.name }}</span>\n }\n @default {\n <he-node-link class=\"is-block pl-4\" [node]=\"term\" [attr.title]=\"term?.name\">\n <span [innerHtml]=\"term?.name | compound\"></span>\n </he-node-link>\n }\n }\n }\n </td>\n @if (isBlankNodes()) {\n <td>\n @if (subValue.showUnits && $any(blankNode).term) {\n <span\n class=\"is-nowrap\"\n [innerHtml]=\"$any(blankNode).term.units | compound: $any(blankNode).term.termType\"></span>\n }\n </td>\n }\n <td>\n @if (subValue.originalValue !== null) {\n <span>\n {{ subValue.originalValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n -\n }\n </td>\n <td>\n @if (subValue.isRecalculated) {\n <span>\n {{ subValue.recalculatedValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n not recalculated\n }\n </td>\n @if (isBlankNodes()) {\n <td>-</td>\n }\n <ng-container *ngTemplateOutlet=\"blankNodeModels; context: { data: subValue }\" />\n </tr>\n }\n }\n </tbody>\n </table>\n </he-data-table>\n <div class=\"is-size-7 is-italic\">\n <div class=\"columns is-variable is-1 my-0\">\n <div class=\"column is-narrow\">\n <p>\n <a class=\"is-inline-block pr-2\" (click)=\"showLegend.set(!showLegend())\">\n <fa-icon [icon]=\"showLegend() ? faAngleDown : faAngleRight\" />\n </a>\n <span class=\"is-inline-block\">Legend:</span>\n </p>\n @if (showLegend()) {\n <ul class=\"content pl-2\">\n @for (status of LogStatus | keyvalue; track status.value) {\n @if (logIcon[status.value]) {\n <li class=\"has-text-{{ logColor[status.value] }}\">\n <fa-icon [icon]=\"logIcon[status.value]\" />\n <span class=\"pl-1\">{{ status.value }}</span>\n </li>\n }\n }\n </ul>\n }\n </div>\n @if (filteredType()) {\n <div class=\"column has-text-right\">\n <label class=\"is-inline-block checkbox\">\n <input\n type=\"checkbox\"\n class=\"selector\"\n [ngModel]=\"onlyRequired\"\n (change)=\"onlyRequired.set($event.target.checked)\"\n [disabled]=\"!!term()\" />\n <span class=\"ml-2\">\n Show only {{ filteredType() | pluralize }} included in the default HESTIA system boundary\n </span>\n </label>\n </div>\n }\n </div>\n </div>\n </div>\n} @else {\n <div class=\"is-3 has-text-centered\">\n <p class=\"is-mb-2\">\n <fa-icon class=\"is-pr-2\" [icon]=\"faExclamationTriangle\" />\n <span>These logs might be incorrect as the calculations are outdated.</span>\n </p>\n <p class=\"is-underlined is-size-7\"><a (click)=\"showOutdatedLogs.set(true)\">View logs anyway.</a></p>\n </div>\n}\n\n<ng-template #blankNodeOriginalValueDetails let-blankNode=\"blankNode\">\n <span class=\"is-pr-1\">The original value was reported using:</span>\n <he-node-link\n class=\"is-inline-block\"\n linkClass=\"is-dark\"\n [node]=\"$any(blankNode).original[0].methodModel\"\n [showExternalLink]=\"true\">\n <span>{{ $any(blankNode).original[0].methodModel.name }}</span>\n </he-node-link>\n</ng-template>\n\n<ng-template #blankNodeModels let-data=\"data\">\n <ng-template #notInSystemBoundary>\n <td [attr.colspan]=\"methodModelsCount()\">\n <span>Not in HESTIA system boundary</span>\n </td>\n </ng-template>\n\n @if (isSystemBoundary(data)) {\n @for (configModel of methodModelsCount() | times; track configModelIndex; let configModelIndex = $index) {\n <td class=\"blank-node-index-{{ configModelIndex }}\">\n @if (getModelsAt(data, configModelIndex); as models) {\n @if ($any(models) | isArray) {\n <div>\n @for (model of $any(models); track model.methodId) {\n <p>\n <ng-container *ngTemplateOutlet=\"blankNodeModel; context: { model, data }\" />\n </p>\n }\n </div>\n } @else {\n <ng-container *ngTemplateOutlet=\"blankNodeModel; context: { model: models, data }\" />\n }\n } @else {\n -\n }\n </td>\n }\n } @else {\n -\n }\n</ng-template>\n\n<ng-template #blankNodeModel let-model=\"model\" let-data=\"data\">\n <span\n class=\"is-nowrap\"\n [class.trigger-popover]=\"model.showLogs\"\n [ngbPopover]=\"logDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n triggers=\"manual\"\n #p=\"ngbPopover\"\n placement=\"bottom left right auto\"\n container=\"body\"\n (click)=\"p.isOpen() ? p.close() : model.showLogs ? p.open({ logs: model.logs }) : null\">\n <span class=\"is-capitalized\">{{ methodName(model) }}</span>\n @if (model.logs?.methodTier || model.model?.methodTier) {\n <span class=\"pl-1\">[{{ model.logs?.methodTier || model.model?.methodTier }}]</span>\n }\n\n <span\n class=\"pl-1 has-text-{{ logColor[model.status] }} trigger-popover\"\n [ngbPopover]=\"logStatusDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n triggers=\"manual\"\n #p1=\"ngbPopover\"\n placement=\"bottom left right auto\"\n container=\"body\"\n (click)=\"$event.stopPropagation(); p1.isOpen() ? p1.close() : p1.open({ model, data })\">\n <fa-icon [icon]=\"logIcon[model.status]\" />\n </span>\n\n @if (model.model) {\n <span class=\"pl-1\">\n (\n <ng-container *ngTemplateOutlet=\"docsLink; context: { $implicit: model.model }\" />\n )\n </span>\n }\n </span>\n</ng-template>\n\n<ng-template #logDetails let-logs=\"logs\">\n <he-node-logs-models-logs [logs]=\"logs\" />\n</ng-template>\n\n<ng-template #logStatusDetails let-model=\"model\" let-data=\"data\">\n <he-node-logs-models-logs-status [nodeType]=\"nodeType()\" [model]=\"model\" [data]=\"\" />\n</ng-template>\n\n<ng-template #docsLink let-model>\n <a [href]=\"model.apiDocsPath || model.docPath || model.path\" target=\"_blank\" (click)=\"$event.stopPropagation()\">\n <span>Docs</span>\n <fa-icon class=\"ml-1\" [icon]=\"faExternalLinkAlt\" size=\"sm\" />\n </a>\n</ng-template>\n", styles: [":host{display:block}::ng-deep .table{background-color:transparent}::ng-deep .table td he-node-link{width:190px}@media screen and (max-width: 768px){::ng-deep .table td he-node-link{width:150px}}::ng-deep .table td .open-node+he-node-link{width:170px}@media screen and (max-width: 768px){::ng-deep .table td .open-node+he-node-link{width:130px}}::ng-deep .table td.has-border-right{box-shadow:1px 0 #6c8093}::ng-deep .table .has-sub-rows.is-open>td:first-child:before,::ng-deep .table .is-sub-row>td:first-child:before{display:block;position:absolute;content:\" \";background-color:#6c809333;height:100%;width:1px;top:0;left:12px}::ng-deep .table .has-sub-rows.is-open>td:first-child:before{top:25px}::ng-deep .table .popover-body .table-container{max-height:260px;overflow-y:auto}\n"], dependencies: [{ kind: "pipe", type: KeyValuePipe, name: "keyvalue" }, { kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "component", type: DataTableComponent, selector: "he-data-table", inputs: ["minHeight", "maxHeight", "small"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: NgbTypeahead, selector: "input[ngbTypeahead]", inputs: ["autocomplete", "container", "editable", "focusFirst", "inputFormatter", "ngbTypeahead", "resultFormatter", "resultTemplate", "selectOnExact", "showHint", "placement", "popperOptions", "popupClass"], outputs: ["selectItem"], exportAs: ["ngbTypeahead"] }, { kind: "component", type: NodeLinkComponent, selector: "he-node-link", inputs: ["node", "showExternalLink", "linkClass"] }, { kind: "component", type: BlankNodeValueDeltaComponent, selector: "he-blank-node-value-delta", inputs: ["value", "originalValue", "displayType"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: NgbPopover, selector: "[ngbPopover]", inputs: ["animation", "autoClose", "ngbPopover", "popoverTitle", "placement", "popperOptions", "triggers", "positionTarget", "container", "disablePopover", "popoverClass", "popoverContext", "openDelay", "closeDelay"], outputs: ["shown", "hidden"], exportAs: ["ngbPopover"] }, { kind: "pipe", type: CompoundPipe, name: "compound" }, { kind: "pipe", type: DefaultPipe, name: "default" }, { kind: "pipe", type: PluralizePipe, name: "pluralize" }, { kind: "pipe", type: KeyToLabelPipe, name: "keyToLabel" }, { kind: "pipe", type: PrecisionPipe, name: "precision" }, { kind: "pipe", type: TimesPipe, name: "times" }, { kind: "pipe", type: IsArrayPipe, name: "isArray" }, { kind: "component", type: NodeLogsModelsLogsComponent, selector: "he-node-logs-models-logs", inputs: ["logs"] }, { kind: "component", type: NodeLogsModelsLogsStatusComponent, selector: "he-node-logs-models-logs-status", inputs: ["nodeType", "model", "data"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
6862
6862
|
}
|
|
6863
6863
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.4", ngImport: i0, type: NodeLogsModelsComponent, decorators: [{
|
|
6864
6864
|
type: Component$1,
|
|
@@ -6881,7 +6881,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.4", ngImpor
|
|
|
6881
6881
|
IsArrayPipe,
|
|
6882
6882
|
NodeLogsModelsLogsComponent,
|
|
6883
6883
|
NodeLogsModelsLogsStatusComponent
|
|
6884
|
-
], template: "@if (showOutdatedLogs() || isLatestVersion()) {\n <div class=\"is-px-3 is-pb-3\">\n @if (!isExternal && logsUrl()) {\n <div class=\"has-text-right is-mb-2\">\n <a class=\"is-size-7\" [href]=\"logsUrl()\" target=\"_blank\">\n <fa-icon [icon]=\"faExternalLinkAlt\" />\n <span class=\"pl-2\">Open Full Logs</span>\n </a>\n </div>\n }\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n <tr>\n <th class=\"width-auto has-border-right\">\n @if (enableFilterByTerm()) {\n <div class=\"field\">\n <div class=\"control is-expanded has-icons-right\">\n <input\n class=\"input search-input is-small\"\n [ngModel]=\"term()\"\n name=\"term\"\n placeholder=\"Select entry by name\"\n [ngbTypeahead]=\"suggestTerm\"\n [focusFirst]=\"true\"\n (focus)=\"typeaheadFocus($event)\"\n (selectItem)=\"term.set($event.item)\"\n container=\"body\"\n popupClass=\"is-small\" />\n <a class=\"icon is-small is-right\" [class.is-hidden]=\"!term()\" (click)=\"term.set('')\">\n <fa-icon [icon]=\"faTimes\" />\n </a>\n </div>\n </div>\n }\n </th>\n @if (isBlankNodes()) {\n <th>\n <span class=\"is-pr-1\">Units</span>\n <span>(per </span>\n <span>\n @switch (functionalUnit()) {\n @case (CycleFunctionalUnit['1 ha']) {\n hectare\n }\n @default {\n kg product\n }\n }\n </span>\n <span>)</span>\n </th>\n }\n <th>Original</th>\n <th>Recalculated</th>\n @if (isBlankNodes()) {\n <th>Difference</th>\n }\n @for (c of methodModelsCount() | times; track i; let i = $index) {\n <th>({{ i + 1 }})</th>\n }\n </tr>\n </thead>\n <tbody>\n @if (loading()) {\n <tr>\n <td class=\"has-text-centered\" colspan=\"6\">\n <div class=\"has-text-center py-3\">\n <fa-icon [icon]=\"faSpinner\" animation=\"spin\" size=\"lg\" />\n </div>\n </td>\n </tr>\n } @else if (blankNodes().length === 0) {\n <tr>\n <td class=\"has-text-centered\" colspan=\"6\">\n <span>{{ noDataMessage() || 'No original data was provided and no gap filling occurred.' }}</span>\n </td>\n </tr>\n }\n @for (blankNode of blankNodes(); track trackByBlankNode($index, blankNode)) {\n <tr [class.has-sub-rows]=\"blankNode.canOpen\" [class.is-open]=\"blankNode.isOpen\">\n <td\n class=\"width-auto has-border-right is-nowrap\"\n [attr.title]=\"$any(blankNode).term?.name || $any(blankNode).key\">\n @if (blankNode.canOpen) {\n <a class=\"is-inline-block is-align-top pr-2 open-node\" (click)=\"blankNode.isOpen = !blankNode.isOpen\">\n <fa-icon [icon]=\"blankNode.isOpen ? faAngleDown : faAngleRight\" />\n </a>\n }\n @if ($any(blankNode).term) {\n <he-node-link class=\"is-inline-block is-pre-wrap\" [node]=\"$any(blankNode).term\">\n <span [innerHtml]=\"$any(blankNode).term.name | compound: $any(blankNode).term.termType\"></span>\n </he-node-link>\n }\n @if ($any(blankNode).key) {\n @if (nodeKey() === 'completeness') {\n <a [href]=\"schemaBaseUrl + '/Completeness#' + $any(blankNode).key\" target=\"_blank\">\n <span>{{ $any(blankNode).key | keyToLabel }}</span>\n </a>\n }\n } @else {\n <span>{{ $any(blankNode).key }}</span>\n }\n </td>\n @if (isBlankNodes()) {\n <td>\n @if ($any(blankNode).term) {\n <span\n class=\"is-nowrap\"\n [innerHtml]=\"$any(blankNode).term.units | compound: $any(blankNode).term.termType\"></span>\n }\n </td>\n }\n <td>\n <ng-template #originalValueContent>\n <span>{{ $any(blankNode).originalValue | precision: 3 | default: '-' }}</span>\n </ng-template>\n\n @if (blankNode.allParallel) {\n @for (model of $any(blankNode).configModels[0]; track model.methodId) {\n <div>\n {{ $any(blankNode).originalValueByMethodId[model.methodId] | precision: 3 | default: '-' }}\n </div>\n }\n } @else {\n <span\n [class.trigger-popover]=\"!!$any(blankNode).original?.[0]?.methodModel\"\n [ngbPopover]=\"blankNodeOriginalValueDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n placement=\"left\"\n container=\"body\"\n [disablePopover]=\"!$any(blankNode).original?.[0]?.methodModel\"\n [popoverContext]=\"{ blankNode }\">\n <span pointer>\n {{ $any(blankNode).originalValue | precision: 3 | default: '-' }}\n </span>\n </span>\n }\n </td>\n <td>\n @if (!blankNode.isOriginal || blankNode.isRecalculated) {\n @if (blankNode.allParallel) {\n @for (model of $any(blankNode).configModels[0]; track model.methodId) {\n <div>\n {{ $any(blankNode).recalculatedValueByMethodId[model.methodId] | precision: 3 | default: '-' }}\n </div>\n }\n } @else {\n <span>{{ blankNode.recalculatedValue | precision: 3 | default: '-' }}</span>\n }\n } @else {\n not recalculated\n }\n </td>\n @if (isBlankNodes()) {\n <td class=\"is-nowrap\">\n @if (blankNode.allParallel) {\n @for (model of $any(blankNode).configModels[0]; track model.methodId) {\n <div>\n @if (\n $any(blankNode).originalValueByMethodId[model.methodId] !== null &&\n $any(blankNode).recalculatedValueByMethodId[model.methodId] !== null\n ) {\n <he-blank-node-value-delta\n [value]=\"$any(blankNode).recalculatedValueByMethodId[model.methodId]\"\n [originalValue]=\"\n $any(blankNode).originalValueByMethodId[model.methodId]\n \"></he-blank-node-value-delta>\n } @else {\n -\n }\n </div>\n }\n } @else {\n @if ($any(blankNode).original.length && blankNode.isRecalculated) {\n <he-blank-node-value-delta\n [value]=\"blankNode.recalculatedValue\"\n [originalValue]=\"$any(blankNode).originalValue\"></he-blank-node-value-delta>\n } @else {\n -\n }\n }\n </td>\n }\n <ng-container *ngTemplateOutlet=\"blankNodeModels; context: { data: blankNode }\" />\n </tr>\n @for (subValue of $any(blankNode).keys; track trackBySubValue(subValue)) {\n <tr\n [class.is-hidden]=\"!blankNode.isOpen\"\n [class.has-sub-rows]=\"$any(blankNode).subValues?.length\"\n [class.is-sub-row]=\"blankNode.canOpen\">\n <td class=\"width-auto has-border-right is-nowrap\">\n <span class=\"is-inline-block is-align-top pl-3 pr-1 field-node\">Field:</span>\n @if (blankNode.type) {\n <a\n class=\"is-inline-block is-pre-wrap\"\n [href]=\"schemaBaseUrl + '/' + blankNode.type + '#' + subValue.key\"\n target=\"_blank\"\n [title]=\"subValue.key\">\n <span>{{ subValue.key }}</span>\n </a>\n }\n @if (!blankNode.type) {\n <span class=\"is-inline-block is-align-top\">{{ subValue.key }}</span>\n }\n </td>\n @if (isBlankNodes()) {\n <td></td>\n }\n <td>\n @if (subValue.originalValue !== null) {\n <span>\n {{ subValue.originalValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n -\n }\n </td>\n <td>\n @if (subValue.isRecalculated || subValue.key === 'impactAssessment') {\n <span>\n {{ subValue.recalculatedValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n not recalculated\n }\n </td>\n @if (isBlankNodes()) {\n <td>-</td>\n }\n <ng-container *ngTemplateOutlet=\"blankNodeModels; context: { data: subValue }\" />\n </tr>\n }\n @for (subValue of $any(blankNode).subValues; track trackBySubValue(subValue)) {\n @let term = subValue.term || termById(subValue.id);\n <tr [class.is-hidden]=\"!blankNode.isOpen\" [class.is-sub-row]=\"blankNode.canOpen\">\n <td class=\"width-auto has-border-right\">\n <span class=\"is-inline-block is-align-top pl-3\">{{ subValue.key | keyToLabel }}</span>\n @if (subValue.id) {\n <span class=\"is-inline-block\" class=\"is-inline-block is-align-top pr-1\">:</span>\n @switch (subValue.key) {\n @case ('backgroundData') {\n <span class=\"is-inline-block\">{{ term?.name }}</span>\n }\n @default {\n <he-node-link class=\"is-block pl-4\" [node]=\"term\" [attr.title]=\"term?.name\">\n <span [innerHtml]=\"term?.name | compound\"></span>\n </he-node-link>\n }\n }\n }\n </td>\n @if (isBlankNodes()) {\n <td>\n @if (subValue.showUnits && $any(blankNode).term) {\n <span\n class=\"is-nowrap\"\n [innerHtml]=\"$any(blankNode).term.units | compound: $any(blankNode).term.termType\"></span>\n }\n </td>\n }\n <td>\n @if (subValue.originalValue !== null) {\n <span>\n {{ subValue.originalValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n -\n }\n </td>\n <td>\n @if (subValue.isRecalculated) {\n <span>\n {{ subValue.recalculatedValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n not recalculated\n }\n </td>\n @if (isBlankNodes()) {\n <td>-</td>\n }\n <ng-container *ngTemplateOutlet=\"blankNodeModels; context: { data: subValue }\" />\n </tr>\n }\n }\n </tbody>\n </table>\n </he-data-table>\n <div class=\"is-size-7 is-italic\">\n <div class=\"columns is-variable is-1 my-0\">\n <div class=\"column is-narrow\">\n <p>\n <a class=\"is-inline-block pr-2\" (click)=\"showLegend.set(!showLegend())\">\n <fa-icon [icon]=\"showLegend() ? faAngleDown : faAngleRight\" />\n </a>\n <span class=\"is-inline-block\">Legend:</span>\n </p>\n @if (showLegend()) {\n <ul class=\"content pl-2\">\n @for (status of LogStatus | keyvalue; track status.value) {\n @if (logIcon[status.value]) {\n <li class=\"has-text-{{ logColor[status.value] }}\">\n <fa-icon [icon]=\"logIcon[status.value]\" />\n <span class=\"pl-1\">{{ status.value }}</span>\n </li>\n }\n }\n </ul>\n }\n </div>\n @if (filteredType()) {\n <div class=\"column has-text-right\">\n <label class=\"is-inline-block checkbox\">\n <input\n type=\"checkbox\"\n class=\"selector\"\n [ngModel]=\"onlyRequired\"\n (change)=\"onlyRequired.set($event.target.checked)\"\n [disabled]=\"!!term()\" />\n <span class=\"ml-2\">\n Show only {{ filteredType() | pluralize }} included in the default HESTIA system boundary\n </span>\n </label>\n </div>\n }\n </div>\n </div>\n </div>\n} @else {\n <div class=\"is-3 has-text-centered\">\n <p class=\"is-mb-2\">\n <fa-icon class=\"is-pr-2\" [icon]=\"faExclamationTriangle\" />\n <span>These logs might be incorrect as the calculations are outdated.</span>\n </p>\n <p class=\"is-underlined is-size-7\"><a (click)=\"showOutdatedLogs.set(true)\">View logs anyway.</a></p>\n </div>\n}\n\n<ng-template #blankNodeOriginalValueDetails let-blankNode=\"blankNode\">\n <span class=\"is-pr-1\">The original value was reported using:</span>\n <he-node-link\n class=\"is-inline-block\"\n linkClass=\"is-dark\"\n [node]=\"$any(blankNode).original[0].methodModel\"\n [showExternalLink]=\"true\">\n <span>{{ $any(blankNode).original[0].methodModel.name }}</span>\n </he-node-link>\n</ng-template>\n\n<ng-template #blankNodeModels let-data=\"data\">\n <ng-template #notInSystemBoundary>\n <td [attr.colspan]=\"methodModelsCount()\">\n <span>Not in HESTIA system boundary</span>\n </td>\n </ng-template>\n\n @if (isSystemBoundary(data)) {\n @for (configModel of methodModelsCount() | times; track configModelIndex; let configModelIndex = $index) {\n <td class=\"blank-node-index-{{ configModelIndex }}\">\n @if (getModelsAt(data, configModelIndex); as models) {\n @if ($any(models) | isArray) {\n <div>\n @for (model of $any(models); track model.methodId) {\n <p>\n <ng-container *ngTemplateOutlet=\"blankNodeModel; context: { model, data }\" />\n </p>\n }\n </div>\n } @else {\n <ng-container *ngTemplateOutlet=\"blankNodeModel; context: { model: models, data }\" />\n }\n } @else {\n -\n }\n </td>\n }\n } @else {\n -\n }\n</ng-template>\n\n<ng-template #blankNodeModel let-model=\"model\" let-data=\"data\">\n <span\n class=\"is-nowrap\"\n [class.trigger-popover]=\"model.showLogs\"\n [ngbPopover]=\"logDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n triggers=\"manual\"\n #p=\"ngbPopover\"\n placement=\"left\"\n container=\"body\"\n (click)=\"p.isOpen() ? p.close() : model.showLogs ? p.open({ logs: model.logs }) : null\">\n <span class=\"is-capitalized\">{{ methodName(model) }}</span>\n @if (model.logs?.methodTier || model.model?.methodTier) {\n <span class=\"pl-1\">[{{ model.logs?.methodTier || model.model?.methodTier }}]</span>\n }\n\n <span\n class=\"pl-1 has-text-{{ logColor[model.status] }} trigger-popover\"\n [ngbPopover]=\"logStatusDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n triggers=\"manual\"\n #p1=\"ngbPopover\"\n placement=\"left\"\n container=\"body\"\n (click)=\"$event.stopPropagation(); p1.isOpen() ? p1.close() : p1.open({ model, data })\">\n <fa-icon [icon]=\"logIcon[model.status]\" />\n </span>\n\n @if (model.model) {\n <span class=\"pl-1\">\n (\n <ng-container *ngTemplateOutlet=\"docsLink; context: { $implicit: model.model }\" />\n )\n </span>\n }\n </span>\n</ng-template>\n\n<ng-template #logDetails let-logs=\"logs\">\n <he-node-logs-models-logs [logs]=\"logs\" />\n</ng-template>\n\n<ng-template #logStatusDetails let-model=\"model\" let-data=\"data\">\n <he-node-logs-models-logs-status [nodeType]=\"nodeType()\" [model]=\"model\" [data]=\"\" />\n</ng-template>\n\n<ng-template #docsLink let-model>\n <a [href]=\"model.apiDocsPath || model.docPath || model.path\" target=\"_blank\" (click)=\"$event.stopPropagation()\">\n <span>Docs</span>\n <fa-icon class=\"ml-1\" [icon]=\"faExternalLinkAlt\" size=\"sm\" />\n </a>\n</ng-template>\n", styles: [":host{display:block}::ng-deep .table{background-color:transparent}::ng-deep .table td he-node-link{width:190px}@media screen and (max-width: 768px){::ng-deep .table td he-node-link{width:150px}}::ng-deep .table td .open-node+he-node-link{width:170px}@media screen and (max-width: 768px){::ng-deep .table td .open-node+he-node-link{width:130px}}::ng-deep .table td.has-border-right{box-shadow:1px 0 #6c8093}::ng-deep .table .has-sub-rows.is-open>td:first-child:before,::ng-deep .table .is-sub-row>td:first-child:before{display:block;position:absolute;content:\" \";background-color:#6c809333;height:100%;width:1px;top:0;left:12px}::ng-deep .table .has-sub-rows.is-open>td:first-child:before{top:25px}::ng-deep .table .popover-body .table-container{max-height:260px;overflow-y:auto}\n"] }]
|
|
6884
|
+
], template: "@if (showOutdatedLogs() || isLatestVersion()) {\n <div class=\"is-px-3 is-pb-3\">\n @if (!isExternal && logsUrl()) {\n <div class=\"has-text-right is-mb-2\">\n <a class=\"is-size-7\" [href]=\"logsUrl()\" target=\"_blank\">\n <fa-icon [icon]=\"faExternalLinkAlt\" />\n <span class=\"pl-2\">Open Full Logs</span>\n </a>\n </div>\n }\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n <tr>\n <th class=\"width-auto has-border-right\">\n @if (enableFilterByTerm()) {\n <div class=\"field\">\n <div class=\"control is-expanded has-icons-right\">\n <input\n class=\"input search-input is-small\"\n [ngModel]=\"term()\"\n name=\"term\"\n placeholder=\"Select entry by name\"\n [ngbTypeahead]=\"suggestTerm\"\n [focusFirst]=\"true\"\n (focus)=\"typeaheadFocus($event)\"\n (selectItem)=\"term.set($event.item)\"\n container=\"body\"\n popupClass=\"is-small\" />\n <a class=\"icon is-small is-right\" [class.is-hidden]=\"!term()\" (click)=\"term.set('')\">\n <fa-icon [icon]=\"faTimes\" />\n </a>\n </div>\n </div>\n }\n </th>\n @if (isBlankNodes()) {\n <th>\n <span class=\"is-pr-1\">Units</span>\n <span>(per </span>\n <span>\n @switch (functionalUnit()) {\n @case (CycleFunctionalUnit['1 ha']) {\n hectare\n }\n @default {\n kg product\n }\n }\n </span>\n <span>)</span>\n </th>\n }\n <th>Original</th>\n <th>Recalculated</th>\n @if (isBlankNodes()) {\n <th>Difference</th>\n }\n @for (c of methodModelsCount() | times; track i; let i = $index) {\n <th>({{ i + 1 }})</th>\n }\n </tr>\n </thead>\n <tbody>\n @if (loading()) {\n <tr>\n <td class=\"has-text-centered\" colspan=\"6\">\n <div class=\"has-text-center py-3\">\n <fa-icon [icon]=\"faSpinner\" animation=\"spin\" size=\"lg\" />\n </div>\n </td>\n </tr>\n } @else if (blankNodes().length === 0) {\n <tr>\n <td class=\"has-text-centered\" colspan=\"6\">\n <span>{{ noDataMessage() || 'No original data was provided and no gap filling occurred.' }}</span>\n </td>\n </tr>\n }\n @for (blankNode of blankNodes(); track trackByBlankNode($index, blankNode)) {\n <tr [class.has-sub-rows]=\"blankNode.canOpen\" [class.is-open]=\"blankNode.isOpen\">\n <td\n class=\"width-auto has-border-right is-nowrap\"\n [attr.title]=\"$any(blankNode).term?.name || $any(blankNode).key\">\n @if (blankNode.canOpen) {\n <a class=\"is-inline-block is-align-top pr-2 open-node\" (click)=\"blankNode.isOpen = !blankNode.isOpen\">\n <fa-icon [icon]=\"blankNode.isOpen ? faAngleDown : faAngleRight\" />\n </a>\n }\n @if ($any(blankNode).term) {\n <he-node-link class=\"is-inline-block is-pre-wrap\" [node]=\"$any(blankNode).term\">\n <span [innerHtml]=\"$any(blankNode).term.name | compound: $any(blankNode).term.termType\"></span>\n </he-node-link>\n }\n @if ($any(blankNode).key) {\n @if (nodeKey() === 'completeness') {\n <a [href]=\"schemaBaseUrl + '/Completeness#' + $any(blankNode).key\" target=\"_blank\">\n <span>{{ $any(blankNode).key | keyToLabel }}</span>\n </a>\n }\n } @else {\n <span>{{ $any(blankNode).key }}</span>\n }\n </td>\n @if (isBlankNodes()) {\n <td>\n @if ($any(blankNode).term) {\n <span\n class=\"is-nowrap\"\n [innerHtml]=\"$any(blankNode).term.units | compound: $any(blankNode).term.termType\"></span>\n }\n </td>\n }\n <td>\n <ng-template #originalValueContent>\n <span>{{ $any(blankNode).originalValue | precision: 3 | default: '-' }}</span>\n </ng-template>\n\n @if (blankNode.allParallel) {\n @for (model of $any(blankNode).configModels[0]; track model.methodId) {\n <div>\n {{ $any(blankNode).originalValueByMethodId[model.methodId] | precision: 3 | default: '-' }}\n </div>\n }\n } @else {\n <span\n [class.trigger-popover]=\"!!$any(blankNode).original?.[0]?.methodModel\"\n [ngbPopover]=\"blankNodeOriginalValueDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n placement=\"bottom left right auto\"\n container=\"body\"\n [disablePopover]=\"!$any(blankNode).original?.[0]?.methodModel\"\n [popoverContext]=\"{ blankNode }\">\n <span pointer>\n {{ $any(blankNode).originalValue | precision: 3 | default: '-' }}\n </span>\n </span>\n }\n </td>\n <td>\n @if (!blankNode.isOriginal || blankNode.isRecalculated) {\n @if (blankNode.allParallel) {\n @for (model of $any(blankNode).configModels[0]; track model.methodId) {\n <div>\n {{ $any(blankNode).recalculatedValueByMethodId[model.methodId] | precision: 3 | default: '-' }}\n </div>\n }\n } @else {\n <span>{{ blankNode.recalculatedValue | precision: 3 | default: '-' }}</span>\n }\n } @else {\n not recalculated\n }\n </td>\n @if (isBlankNodes()) {\n <td class=\"is-nowrap\">\n @if (blankNode.allParallel) {\n @for (model of $any(blankNode).configModels[0]; track model.methodId) {\n <div>\n @if (\n $any(blankNode).originalValueByMethodId[model.methodId] !== null &&\n $any(blankNode).recalculatedValueByMethodId[model.methodId] !== null\n ) {\n <he-blank-node-value-delta\n [value]=\"$any(blankNode).recalculatedValueByMethodId[model.methodId]\"\n [originalValue]=\"\n $any(blankNode).originalValueByMethodId[model.methodId]\n \"></he-blank-node-value-delta>\n } @else {\n -\n }\n </div>\n }\n } @else {\n @if ($any(blankNode).original.length && blankNode.isRecalculated) {\n <he-blank-node-value-delta\n [value]=\"blankNode.recalculatedValue\"\n [originalValue]=\"$any(blankNode).originalValue\"></he-blank-node-value-delta>\n } @else {\n -\n }\n }\n </td>\n }\n <ng-container *ngTemplateOutlet=\"blankNodeModels; context: { data: blankNode }\" />\n </tr>\n @for (subValue of $any(blankNode).keys; track trackBySubValue(subValue)) {\n <tr\n [class.is-hidden]=\"!blankNode.isOpen\"\n [class.has-sub-rows]=\"$any(blankNode).subValues?.length\"\n [class.is-sub-row]=\"blankNode.canOpen\">\n <td class=\"width-auto has-border-right is-nowrap\">\n <span class=\"is-inline-block is-align-top pl-3 pr-1 field-node\">Field:</span>\n @if (blankNode.type) {\n <a\n class=\"is-inline-block is-pre-wrap\"\n [href]=\"schemaBaseUrl + '/' + blankNode.type + '#' + subValue.key\"\n target=\"_blank\"\n [title]=\"subValue.key\">\n <span>{{ subValue.key }}</span>\n </a>\n }\n @if (!blankNode.type) {\n <span class=\"is-inline-block is-align-top\">{{ subValue.key }}</span>\n }\n </td>\n @if (isBlankNodes()) {\n <td></td>\n }\n <td>\n @if (subValue.originalValue !== null) {\n <span>\n {{ subValue.originalValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n -\n }\n </td>\n <td>\n @if (subValue.isRecalculated || subValue.key === 'impactAssessment') {\n <span>\n {{ subValue.recalculatedValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n not recalculated\n }\n </td>\n @if (isBlankNodes()) {\n <td>-</td>\n }\n <ng-container *ngTemplateOutlet=\"blankNodeModels; context: { data: subValue }\" />\n </tr>\n }\n @for (subValue of $any(blankNode).subValues; track trackBySubValue(subValue)) {\n @let term = subValue.term || termById(subValue.id);\n <tr [class.is-hidden]=\"!blankNode.isOpen\" [class.is-sub-row]=\"blankNode.canOpen\">\n <td class=\"width-auto has-border-right\">\n <span class=\"is-inline-block is-align-top pl-3\">{{ subValue.key | keyToLabel }}</span>\n @if (subValue.id) {\n <span class=\"is-inline-block\" class=\"is-inline-block is-align-top pr-1\">:</span>\n @switch (subValue.key) {\n @case ('backgroundData') {\n <span class=\"is-inline-block\">{{ term?.name }}</span>\n }\n @default {\n <he-node-link class=\"is-block pl-4\" [node]=\"term\" [attr.title]=\"term?.name\">\n <span [innerHtml]=\"term?.name | compound\"></span>\n </he-node-link>\n }\n }\n }\n </td>\n @if (isBlankNodes()) {\n <td>\n @if (subValue.showUnits && $any(blankNode).term) {\n <span\n class=\"is-nowrap\"\n [innerHtml]=\"$any(blankNode).term.units | compound: $any(blankNode).term.termType\"></span>\n }\n </td>\n }\n <td>\n @if (subValue.originalValue !== null) {\n <span>\n {{ subValue.originalValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n -\n }\n </td>\n <td>\n @if (subValue.isRecalculated) {\n <span>\n {{ subValue.recalculatedValue | precision: 3 | default: '-' }}\n </span>\n } @else {\n not recalculated\n }\n </td>\n @if (isBlankNodes()) {\n <td>-</td>\n }\n <ng-container *ngTemplateOutlet=\"blankNodeModels; context: { data: subValue }\" />\n </tr>\n }\n }\n </tbody>\n </table>\n </he-data-table>\n <div class=\"is-size-7 is-italic\">\n <div class=\"columns is-variable is-1 my-0\">\n <div class=\"column is-narrow\">\n <p>\n <a class=\"is-inline-block pr-2\" (click)=\"showLegend.set(!showLegend())\">\n <fa-icon [icon]=\"showLegend() ? faAngleDown : faAngleRight\" />\n </a>\n <span class=\"is-inline-block\">Legend:</span>\n </p>\n @if (showLegend()) {\n <ul class=\"content pl-2\">\n @for (status of LogStatus | keyvalue; track status.value) {\n @if (logIcon[status.value]) {\n <li class=\"has-text-{{ logColor[status.value] }}\">\n <fa-icon [icon]=\"logIcon[status.value]\" />\n <span class=\"pl-1\">{{ status.value }}</span>\n </li>\n }\n }\n </ul>\n }\n </div>\n @if (filteredType()) {\n <div class=\"column has-text-right\">\n <label class=\"is-inline-block checkbox\">\n <input\n type=\"checkbox\"\n class=\"selector\"\n [ngModel]=\"onlyRequired\"\n (change)=\"onlyRequired.set($event.target.checked)\"\n [disabled]=\"!!term()\" />\n <span class=\"ml-2\">\n Show only {{ filteredType() | pluralize }} included in the default HESTIA system boundary\n </span>\n </label>\n </div>\n }\n </div>\n </div>\n </div>\n} @else {\n <div class=\"is-3 has-text-centered\">\n <p class=\"is-mb-2\">\n <fa-icon class=\"is-pr-2\" [icon]=\"faExclamationTriangle\" />\n <span>These logs might be incorrect as the calculations are outdated.</span>\n </p>\n <p class=\"is-underlined is-size-7\"><a (click)=\"showOutdatedLogs.set(true)\">View logs anyway.</a></p>\n </div>\n}\n\n<ng-template #blankNodeOriginalValueDetails let-blankNode=\"blankNode\">\n <span class=\"is-pr-1\">The original value was reported using:</span>\n <he-node-link\n class=\"is-inline-block\"\n linkClass=\"is-dark\"\n [node]=\"$any(blankNode).original[0].methodModel\"\n [showExternalLink]=\"true\">\n <span>{{ $any(blankNode).original[0].methodModel.name }}</span>\n </he-node-link>\n</ng-template>\n\n<ng-template #blankNodeModels let-data=\"data\">\n <ng-template #notInSystemBoundary>\n <td [attr.colspan]=\"methodModelsCount()\">\n <span>Not in HESTIA system boundary</span>\n </td>\n </ng-template>\n\n @if (isSystemBoundary(data)) {\n @for (configModel of methodModelsCount() | times; track configModelIndex; let configModelIndex = $index) {\n <td class=\"blank-node-index-{{ configModelIndex }}\">\n @if (getModelsAt(data, configModelIndex); as models) {\n @if ($any(models) | isArray) {\n <div>\n @for (model of $any(models); track model.methodId) {\n <p>\n <ng-container *ngTemplateOutlet=\"blankNodeModel; context: { model, data }\" />\n </p>\n }\n </div>\n } @else {\n <ng-container *ngTemplateOutlet=\"blankNodeModel; context: { model: models, data }\" />\n }\n } @else {\n -\n }\n </td>\n }\n } @else {\n -\n }\n</ng-template>\n\n<ng-template #blankNodeModel let-model=\"model\" let-data=\"data\">\n <span\n class=\"is-nowrap\"\n [class.trigger-popover]=\"model.showLogs\"\n [ngbPopover]=\"logDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n triggers=\"manual\"\n #p=\"ngbPopover\"\n placement=\"bottom left right auto\"\n container=\"body\"\n (click)=\"p.isOpen() ? p.close() : model.showLogs ? p.open({ logs: model.logs }) : null\">\n <span class=\"is-capitalized\">{{ methodName(model) }}</span>\n @if (model.logs?.methodTier || model.model?.methodTier) {\n <span class=\"pl-1\">[{{ model.logs?.methodTier || model.model?.methodTier }}]</span>\n }\n\n <span\n class=\"pl-1 has-text-{{ logColor[model.status] }} trigger-popover\"\n [ngbPopover]=\"logStatusDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n triggers=\"manual\"\n #p1=\"ngbPopover\"\n placement=\"bottom left right auto\"\n container=\"body\"\n (click)=\"$event.stopPropagation(); p1.isOpen() ? p1.close() : p1.open({ model, data })\">\n <fa-icon [icon]=\"logIcon[model.status]\" />\n </span>\n\n @if (model.model) {\n <span class=\"pl-1\">\n (\n <ng-container *ngTemplateOutlet=\"docsLink; context: { $implicit: model.model }\" />\n )\n </span>\n }\n </span>\n</ng-template>\n\n<ng-template #logDetails let-logs=\"logs\">\n <he-node-logs-models-logs [logs]=\"logs\" />\n</ng-template>\n\n<ng-template #logStatusDetails let-model=\"model\" let-data=\"data\">\n <he-node-logs-models-logs-status [nodeType]=\"nodeType()\" [model]=\"model\" [data]=\"\" />\n</ng-template>\n\n<ng-template #docsLink let-model>\n <a [href]=\"model.apiDocsPath || model.docPath || model.path\" target=\"_blank\" (click)=\"$event.stopPropagation()\">\n <span>Docs</span>\n <fa-icon class=\"ml-1\" [icon]=\"faExternalLinkAlt\" size=\"sm\" />\n </a>\n</ng-template>\n", styles: [":host{display:block}::ng-deep .table{background-color:transparent}::ng-deep .table td he-node-link{width:190px}@media screen and (max-width: 768px){::ng-deep .table td he-node-link{width:150px}}::ng-deep .table td .open-node+he-node-link{width:170px}@media screen and (max-width: 768px){::ng-deep .table td .open-node+he-node-link{width:130px}}::ng-deep .table td.has-border-right{box-shadow:1px 0 #6c8093}::ng-deep .table .has-sub-rows.is-open>td:first-child:before,::ng-deep .table .is-sub-row>td:first-child:before{display:block;position:absolute;content:\" \";background-color:#6c809333;height:100%;width:1px;top:0;left:12px}::ng-deep .table .has-sub-rows.is-open>td:first-child:before{top:25px}::ng-deep .table .popover-body .table-container{max-height:260px;overflow-y:auto}\n"] }]
|
|
6885
6885
|
}], ctorParameters: () => [] });
|
|
6886
6886
|
|
|
6887
6887
|
var View$3;
|
|
@@ -7472,7 +7472,7 @@ class CyclesNodesComponent {
|
|
|
7472
7472
|
component.headerKeys.set(this.headerKeys());
|
|
7473
7473
|
}
|
|
7474
7474
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.4", ngImport: i0, type: CyclesNodesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
7475
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.4", type: CyclesNodesComponent, isStandalone: true, selector: "he-cycles-nodes", inputs: { dataState: { classPropertyName: "dataState", publicName: "dataState", isSignal: true, isRequired: false, transformFunction: null }, nodeKeys: { classPropertyName: "nodeKeys", publicName: "nodeKeys", isSignal: true, isRequired: true, transformFunction: null }, nodeKeyGroup: { classPropertyName: "nodeKeyGroup", publicName: "nodeKeyGroup", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@if (isGroupNode()) {\n <div class=\"tabs is-mb-1\">\n <ul>\n @for (term of groupNodeTerms(); track term.name) {\n <li [class.is-active]=\"selectedGroupTerm() === term\">\n <a (click)=\"selectedGroupTerm.set(term)\">{{ term.name }}</a>\n </li>\n }\n </ul>\n </div>\n}\n\n<div class=\"columns is-variable is-align-items-center is-2 is-m-0\">\n <div class=\"column\">\n @if (hasData() && selectedView() === View.table) {\n <button class=\"button is-small is-ghost\" (click)=\"showDownload()\">\n <fa-icon [icon]=\"faDownload\" size=\"lg\" />\n </button>\n }\n </div>\n @if (selectedView() === View.table) {\n <div class=\"column is-narrow\">\n <he-search-extend\n class=\"is-secondary is-small\"\n placeholder=\"Filter terms by name\"\n (search)=\"filterTerm.set($event)\" />\n </div>\n }\n @if (views()?.length > 1) {\n <div class=\"column is-narrow\">\n <div class=\"field has-addons\">\n @for (view of views(); track view) {\n <div class=\"control\">\n <button\n class=\"button is-small\"\n [class.is-selected]=\"selectedView() === view\"\n (click)=\"selectedView.set(view)\">\n <span class=\"icon is-small\">\n <fa-icon [icon]=\"viewIcon[view]\" aria-hidden=\"true\" />\n </span>\n <span class=\"is-hidden-mobile\">{{ view }}</span>\n </button>\n </div>\n }\n </div>\n </div>\n }\n</div>\n\n@if (isNodeKeyAllowed()) {\n @switch (selectedView()) {\n @case (View.table) {\n <div class=\"is-px-3 is-pb-3\">\n @if (hasData()) {\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n @if (dataKeys().length > 1) {\n <tr class=\"has-text-weight-bold\">\n <th class=\"width-auto\"></th>\n <th [class.is-hidden]=\"isGroupNode()\"></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @if (data()[dataKey]?.length) {\n <th [attr.colspan]=\"data()[dataKey].length\" [class.has-border-right]=\"!dataKeyLast\">\n <span>{{ dataKey | keyToLabel }}</span>\n </th>\n }\n }\n </tr>\n }\n <tr class=\"has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n <th class=\"has-border-right\" [class.is-hidden]=\"isGroupNode()\"></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.name\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <he-node-link [node]=\"node.value.term\">\n <span\n [innerHtml]=\"\n node.value.term.name | ellipsis: 30 | compound: node.value.term.termType\n \"></span>\n </he-node-link>\n </th>\n }\n }\n </tr>\n <tr class=\"is-italic has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n <th class=\"has-border-right\" [class.is-hidden]=\"isGroupNode()\">\n <a [href]=\"schemaBaseUrl + '/Cycle#functionalUnit'\" target=\"_blank\">Functional unit</a>\n </th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.units\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <span [innerHtml]=\"node.value.term.units | compound: node.value.term.termType\"></span>\n <he-terms-units-description class=\"is-inline-block is-ml-2\" [term]=\"node.value.term\" />\n </th>\n }\n }\n </tr>\n </thead>\n <tbody>\n @for (cycle of cycles(); track trackById(cycleIndex, cycle); let cycleIndex = $index) {\n <tr>\n <td class=\"width-auto has-border-right\" [attr.title]=\"defaultLabel(cycle)\">\n <he-node-link [node]=\"cycleNode(cycle)\">\n <span>{{ cycleIndex + 1 }}. {{ defaultLabel(cycle) }}</span>\n </he-node-link>\n </td>\n <td class=\"has-border-right\" [class.is-hidden]=\"isGroupNode()\">\n <he-cycles-functional-unit-measure [cycle]=\"cycle\" />\n </td>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <td\n class=\"is-nowrap\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n @if (node.value.values[cycle['@id']]) {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"details\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow is-overflow-visible\"\n placement=\"left\"\n container=\"body\"\n [popoverContext]=\"{ data: node.value.values[cycle['@id']], cycle, key: dataKey }\">\n <span pointer>\n {{\n propertyValue(node.value.values[cycle['@id']].value, node.value.term['@id'])\n | precision: 3\n | default: '-'\n }}\n </span>\n <he-blank-node-state\n class=\"ml-1\"\n [dataState]=\"dataState()\"\n [node]=\"node.value.values[cycle['@id']].node\"\n key=\"value\" />\n </span>\n } @else {\n <span>-</span>\n }\n </td>\n }\n }\n </tr>\n }\n </tbody>\n </table>\n </he-data-table>\n <he-blank-node-state-notice\n [dataState]=\"dataState()\"\n [showDeleted]=\"firstNodeKey() === BlankNodesKey.emissions\" />\n } @else {\n <div class=\"is-pt-3 has-text-centered\">\n <span>No data available</span>\n <span class=\"is-pl-1\" [class.is-hidden]=\"!filterTerm()\">matching your search criteria</span>\n <span>.</span>\n @if (showSwitchToRecalculated()) {\n <span>\n Switch to\n <code>recalculated</code>\n version.\n </span>\n }\n </div>\n }\n </div>\n }\n @case (View.chart) {\n @switch (firstNodeKey()) {\n @case (BlankNodesKey.inputs) {\n <he-cycles-result [cycles]=\"cycles()\"></he-cycles-result>\n }\n @case (BlankNodesKey.emissions) {\n <he-cycles-emissions-chart [cycles]=\"cycles()\" />\n }\n }\n }\n @case (View.timeline) {\n <ng-container *ngTemplateOutlet=\"selectCycle\" />\n <div class=\"is-px-3 is-pb-3\">\n <he-cycles-nodes-timeline [recalculatedValues]=\"timelineValues()\" [dataState]=\"dataState()\" />\n <he-blank-node-state-notice [dataState]=\"dataState()\" />\n </div>\n }\n @case (View.logs) {\n <ng-container *ngTemplateOutlet=\"selectCycle\" />\n @if (nodeKeys().length > 1) {\n <div class=\"tabs is-mb-2\">\n <ul>\n @for (nodeKey of nodeKeys(); track nodeKey) {\n <li [class.is-active]=\"selectedNodeKey() === nodeKey\">\n <a (click)=\"selectedNodeKey.set(nodeKey)\">{{ nodeKey | keyToLabel }}</a>\n </li>\n }\n </ul>\n </div>\n }\n @if (selectedNode()) {\n <he-node-logs-models\n [node]=\"selectedNode()\"\n [nodeKey]=\"selectedNodeKey()\"\n [logsKey]=\"selectedLogsKey()\"\n [originalValues]=\"selectedOriginalValues()\"\n [recalculatedValues]=\"selectedRecalculatedValues()\"\n [filterTermTypes]=\"filterTermTypes()\" />\n }\n }\n }\n}\n\n<ng-template #details let-node=\"cycle\" let-data=\"data\" let-key=\"key\">\n <p>\n <b>{{ defaultLabel(node) }}</b>\n </p>\n <he-node-value-details\n class=\"is-overflow-visible\"\n [data]=\"data\"\n [dataState]=\"dataState()\"\n [nodeType]=\"node['@type']\"\n [dataKey]=\"key\" />\n</ng-template>\n\n<ng-template #selectCycle>\n @if (cycles().length > 1) {\n <div class=\"field has-addons is-py-2 is-px-3\">\n <div class=\"control\">\n <span class=\"button is-small is-static is-secondary\">Select a Cycle</span>\n </div>\n <div class=\"control is-expanded\">\n <div class=\"select is-small is-fullwidth is-secondary\">\n <select (change)=\"selectIndex($event)\">\n @for (value of cycles(); track value; let cycleIndex = $index) {\n <option [value]=\"cycleIndex\">{{ cycleIndex + 1 }}. {{ defaultLabel(value) }}</option>\n }\n </select>\n </div>\n </div>\n </div>\n }\n</ng-template>\n", styles: ["fa-icon{display:inline-block;width:10px}he-data-table ::ng-deep .table thead tr th:nth-child(2),he-data-table ::ng-deep .table tbody tr td:nth-child(2){max-width:102px;width:102px}\n"], dependencies: [{ kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "component", type: SearchExtendComponent, selector: "he-search-extend", inputs: ["value", "disabled", "placeholder", "class"], outputs: ["valueChange", "search"] }, { kind: "component", type: DataTableComponent, selector: "he-data-table", inputs: ["minHeight", "maxHeight", "small"] }, { kind: "component", type: NodeLinkComponent, selector: "he-node-link", inputs: ["node", "showExternalLink", "linkClass"] }, { kind: "component", type: TermsUnitsDescriptionComponent, selector: "he-terms-units-description", inputs: ["term", "iconTemplate"] }, { kind: "component", type: CyclesFunctionalUnitMeasureComponent, selector: "he-cycles-functional-unit-measure", inputs: ["cycle"] }, { kind: "directive", type: NgbPopover, selector: "[ngbPopover]", inputs: ["animation", "autoClose", "ngbPopover", "popoverTitle", "placement", "popperOptions", "triggers", "positionTarget", "container", "disablePopover", "popoverClass", "popoverContext", "openDelay", "closeDelay"], outputs: ["shown", "hidden"], exportAs: ["ngbPopover"] }, { kind: "component", type: BlankNodeStateComponent, selector: "he-blank-node-state", inputs: ["dataState", "nodeType", "dataKey", "key", "node", "state", "linkClass"] }, { kind: "component", type: BlankNodeStateNoticeComponent, selector: "he-blank-node-state-notice", inputs: ["dataState", "showDeleted"] }, { kind: "component", type: CyclesResultComponent, selector: "he-cycles-result", inputs: ["cycles"] }, { kind: "component", type: CyclesEmissionsChartComponent, selector: "he-cycles-emissions-chart", inputs: ["cycles"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: CyclesNodesTimelineComponent, selector: "he-cycles-nodes-timeline", inputs: ["recalculatedValues", "dataState"] }, { kind: "component", type: NodeLogsModelsComponent, selector: "he-node-logs-models", inputs: ["node", "nodeKey", "originalValues", "recalculatedValues", "terms", "filterTermTypes", "filterTermTypesLabel", "logsKey", "noDataMessage"] }, { kind: "component", type: NodeValueDetailsComponent, selector: "he-node-value-details", inputs: ["data", "nodeType", "dataState", "dataKey"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "pipe", type: CompoundPipe, name: "compound" }, { kind: "pipe", type: DefaultPipe, name: "default" }, { kind: "pipe", type: EllipsisPipe, name: "ellipsis" }, { kind: "pipe", type: KeyToLabelPipe, name: "keyToLabel" }, { kind: "pipe", type: PrecisionPipe, name: "precision" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
7475
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.4", type: CyclesNodesComponent, isStandalone: true, selector: "he-cycles-nodes", inputs: { dataState: { classPropertyName: "dataState", publicName: "dataState", isSignal: true, isRequired: false, transformFunction: null }, nodeKeys: { classPropertyName: "nodeKeys", publicName: "nodeKeys", isSignal: true, isRequired: true, transformFunction: null }, nodeKeyGroup: { classPropertyName: "nodeKeyGroup", publicName: "nodeKeyGroup", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@if (isGroupNode()) {\n <div class=\"tabs is-mb-1\">\n <ul>\n @for (term of groupNodeTerms(); track term.name) {\n <li [class.is-active]=\"selectedGroupTerm() === term\">\n <a (click)=\"selectedGroupTerm.set(term)\">{{ term.name }}</a>\n </li>\n }\n </ul>\n </div>\n}\n\n<div class=\"columns is-variable is-align-items-center is-2 is-m-0\">\n <div class=\"column\">\n @if (hasData() && selectedView() === View.table) {\n <button class=\"button is-small is-ghost\" (click)=\"showDownload()\">\n <fa-icon [icon]=\"faDownload\" size=\"lg\" />\n </button>\n }\n </div>\n @if (selectedView() === View.table) {\n <div class=\"column is-narrow\">\n <he-search-extend\n class=\"is-secondary is-small\"\n placeholder=\"Filter terms by name\"\n (search)=\"filterTerm.set($event)\" />\n </div>\n }\n @if (views()?.length > 1) {\n <div class=\"column is-narrow\">\n <div class=\"field has-addons\">\n @for (view of views(); track view) {\n <div class=\"control\">\n <button\n class=\"button is-small\"\n [class.is-selected]=\"selectedView() === view\"\n (click)=\"selectedView.set(view)\">\n <span class=\"icon is-small\">\n <fa-icon [icon]=\"viewIcon[view]\" aria-hidden=\"true\" />\n </span>\n <span class=\"is-hidden-mobile\">{{ view }}</span>\n </button>\n </div>\n }\n </div>\n </div>\n }\n</div>\n\n@if (isNodeKeyAllowed()) {\n @switch (selectedView()) {\n @case (View.table) {\n <div class=\"is-px-3 is-pb-3\">\n @if (hasData()) {\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n @if (dataKeys().length > 1) {\n <tr class=\"has-text-weight-bold\">\n <th class=\"width-auto\"></th>\n <th [class.is-hidden]=\"isGroupNode()\"></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @if (data()[dataKey]?.length) {\n <th [attr.colspan]=\"data()[dataKey].length\" [class.has-border-right]=\"!dataKeyLast\">\n <span>{{ dataKey | keyToLabel }}</span>\n </th>\n }\n }\n </tr>\n }\n <tr class=\"has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n <th class=\"has-border-right\" [class.is-hidden]=\"isGroupNode()\"></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.name\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <he-node-link [node]=\"node.value.term\">\n <span\n [innerHtml]=\"\n node.value.term.name | ellipsis: 30 | compound: node.value.term.termType\n \"></span>\n </he-node-link>\n </th>\n }\n }\n </tr>\n <tr class=\"is-italic has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n <th class=\"has-border-right\" [class.is-hidden]=\"isGroupNode()\">\n <a [href]=\"schemaBaseUrl + '/Cycle#functionalUnit'\" target=\"_blank\">Functional unit</a>\n </th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.units\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <span [innerHtml]=\"node.value.term.units | compound: node.value.term.termType\"></span>\n <he-terms-units-description class=\"is-inline-block is-ml-2\" [term]=\"node.value.term\" />\n </th>\n }\n }\n </tr>\n </thead>\n <tbody>\n @for (cycle of cycles(); track trackById(cycleIndex, cycle); let cycleIndex = $index) {\n <tr>\n <td class=\"width-auto has-border-right\" [attr.title]=\"defaultLabel(cycle)\">\n <he-node-link [node]=\"cycleNode(cycle)\">\n <span>{{ cycleIndex + 1 }}. {{ defaultLabel(cycle) }}</span>\n </he-node-link>\n </td>\n <td class=\"has-border-right\" [class.is-hidden]=\"isGroupNode()\">\n <he-cycles-functional-unit-measure [cycle]=\"cycle\" />\n </td>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <td\n class=\"is-nowrap\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n @if (node.value.values[cycle['@id']]) {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"details\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow is-overflow-visible\"\n placement=\"left bottom auto\"\n container=\"body\"\n [popoverContext]=\"{ data: node.value.values[cycle['@id']], cycle, key: dataKey }\">\n <span pointer>\n {{\n propertyValue(node.value.values[cycle['@id']].value, node.value.term['@id'])\n | precision: 3\n | default: '-'\n }}\n </span>\n <he-blank-node-state\n class=\"ml-1\"\n [dataState]=\"dataState()\"\n [node]=\"node.value.values[cycle['@id']].node\"\n key=\"value\" />\n </span>\n } @else {\n <span>-</span>\n }\n </td>\n }\n }\n </tr>\n }\n </tbody>\n </table>\n </he-data-table>\n <he-blank-node-state-notice\n [dataState]=\"dataState()\"\n [showDeleted]=\"firstNodeKey() === BlankNodesKey.emissions\" />\n } @else {\n <div class=\"is-pt-3 has-text-centered\">\n <span>No data available</span>\n <span class=\"is-pl-1\" [class.is-hidden]=\"!filterTerm()\">matching your search criteria</span>\n <span>.</span>\n @if (showSwitchToRecalculated()) {\n <span>\n Switch to\n <code>recalculated</code>\n version.\n </span>\n }\n </div>\n }\n </div>\n }\n @case (View.chart) {\n @switch (firstNodeKey()) {\n @case (BlankNodesKey.inputs) {\n <he-cycles-result [cycles]=\"cycles()\"></he-cycles-result>\n }\n @case (BlankNodesKey.emissions) {\n <he-cycles-emissions-chart [cycles]=\"cycles()\" />\n }\n }\n }\n @case (View.timeline) {\n <ng-container *ngTemplateOutlet=\"selectCycle\" />\n <div class=\"is-px-3 is-pb-3\">\n <he-cycles-nodes-timeline [recalculatedValues]=\"timelineValues()\" [dataState]=\"dataState()\" />\n <he-blank-node-state-notice [dataState]=\"dataState()\" />\n </div>\n }\n @case (View.logs) {\n <ng-container *ngTemplateOutlet=\"selectCycle\" />\n @if (nodeKeys().length > 1) {\n <div class=\"tabs is-mb-2\">\n <ul>\n @for (nodeKey of nodeKeys(); track nodeKey) {\n <li [class.is-active]=\"selectedNodeKey() === nodeKey\">\n <a (click)=\"selectedNodeKey.set(nodeKey)\">{{ nodeKey | keyToLabel }}</a>\n </li>\n }\n </ul>\n </div>\n }\n @if (selectedNode()) {\n <he-node-logs-models\n [node]=\"selectedNode()\"\n [nodeKey]=\"selectedNodeKey()\"\n [logsKey]=\"selectedLogsKey()\"\n [originalValues]=\"selectedOriginalValues()\"\n [recalculatedValues]=\"selectedRecalculatedValues()\"\n [filterTermTypes]=\"filterTermTypes()\" />\n }\n }\n }\n}\n\n<ng-template #details let-node=\"cycle\" let-data=\"data\" let-key=\"key\">\n <p>\n <b>{{ defaultLabel(node) }}</b>\n </p>\n <he-node-value-details\n class=\"is-overflow-visible\"\n [data]=\"data\"\n [dataState]=\"dataState()\"\n [nodeType]=\"node['@type']\"\n [dataKey]=\"key\" />\n</ng-template>\n\n<ng-template #selectCycle>\n @if (cycles().length > 1) {\n <div class=\"field has-addons is-py-2 is-px-3\">\n <div class=\"control\">\n <span class=\"button is-small is-static is-secondary\">Select a Cycle</span>\n </div>\n <div class=\"control is-expanded\">\n <div class=\"select is-small is-fullwidth is-secondary\">\n <select (change)=\"selectIndex($event)\">\n @for (value of cycles(); track value; let cycleIndex = $index) {\n <option [value]=\"cycleIndex\">{{ cycleIndex + 1 }}. {{ defaultLabel(value) }}</option>\n }\n </select>\n </div>\n </div>\n </div>\n }\n</ng-template>\n", styles: ["fa-icon{display:inline-block;width:10px}he-data-table ::ng-deep .table thead tr th:nth-child(2),he-data-table ::ng-deep .table tbody tr td:nth-child(2){max-width:102px;width:102px}\n"], dependencies: [{ kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "component", type: SearchExtendComponent, selector: "he-search-extend", inputs: ["value", "disabled", "placeholder", "class"], outputs: ["valueChange", "search"] }, { kind: "component", type: DataTableComponent, selector: "he-data-table", inputs: ["minHeight", "maxHeight", "small"] }, { kind: "component", type: NodeLinkComponent, selector: "he-node-link", inputs: ["node", "showExternalLink", "linkClass"] }, { kind: "component", type: TermsUnitsDescriptionComponent, selector: "he-terms-units-description", inputs: ["term", "iconTemplate"] }, { kind: "component", type: CyclesFunctionalUnitMeasureComponent, selector: "he-cycles-functional-unit-measure", inputs: ["cycle"] }, { kind: "directive", type: NgbPopover, selector: "[ngbPopover]", inputs: ["animation", "autoClose", "ngbPopover", "popoverTitle", "placement", "popperOptions", "triggers", "positionTarget", "container", "disablePopover", "popoverClass", "popoverContext", "openDelay", "closeDelay"], outputs: ["shown", "hidden"], exportAs: ["ngbPopover"] }, { kind: "component", type: BlankNodeStateComponent, selector: "he-blank-node-state", inputs: ["dataState", "nodeType", "dataKey", "key", "node", "state", "linkClass"] }, { kind: "component", type: BlankNodeStateNoticeComponent, selector: "he-blank-node-state-notice", inputs: ["dataState", "showDeleted"] }, { kind: "component", type: CyclesResultComponent, selector: "he-cycles-result", inputs: ["cycles"] }, { kind: "component", type: CyclesEmissionsChartComponent, selector: "he-cycles-emissions-chart", inputs: ["cycles"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: CyclesNodesTimelineComponent, selector: "he-cycles-nodes-timeline", inputs: ["recalculatedValues", "dataState"] }, { kind: "component", type: NodeLogsModelsComponent, selector: "he-node-logs-models", inputs: ["node", "nodeKey", "originalValues", "recalculatedValues", "terms", "filterTermTypes", "filterTermTypesLabel", "logsKey", "noDataMessage"] }, { kind: "component", type: NodeValueDetailsComponent, selector: "he-node-value-details", inputs: ["data", "nodeType", "dataState", "dataKey"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "pipe", type: CompoundPipe, name: "compound" }, { kind: "pipe", type: DefaultPipe, name: "default" }, { kind: "pipe", type: EllipsisPipe, name: "ellipsis" }, { kind: "pipe", type: KeyToLabelPipe, name: "keyToLabel" }, { kind: "pipe", type: PrecisionPipe, name: "precision" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
7476
7476
|
}
|
|
7477
7477
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.4", ngImport: i0, type: CyclesNodesComponent, decorators: [{
|
|
7478
7478
|
type: Component$1,
|
|
@@ -7498,7 +7498,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.4", ngImpor
|
|
|
7498
7498
|
EllipsisPipe,
|
|
7499
7499
|
KeyToLabelPipe,
|
|
7500
7500
|
PrecisionPipe
|
|
7501
|
-
], template: "@if (isGroupNode()) {\n <div class=\"tabs is-mb-1\">\n <ul>\n @for (term of groupNodeTerms(); track term.name) {\n <li [class.is-active]=\"selectedGroupTerm() === term\">\n <a (click)=\"selectedGroupTerm.set(term)\">{{ term.name }}</a>\n </li>\n }\n </ul>\n </div>\n}\n\n<div class=\"columns is-variable is-align-items-center is-2 is-m-0\">\n <div class=\"column\">\n @if (hasData() && selectedView() === View.table) {\n <button class=\"button is-small is-ghost\" (click)=\"showDownload()\">\n <fa-icon [icon]=\"faDownload\" size=\"lg\" />\n </button>\n }\n </div>\n @if (selectedView() === View.table) {\n <div class=\"column is-narrow\">\n <he-search-extend\n class=\"is-secondary is-small\"\n placeholder=\"Filter terms by name\"\n (search)=\"filterTerm.set($event)\" />\n </div>\n }\n @if (views()?.length > 1) {\n <div class=\"column is-narrow\">\n <div class=\"field has-addons\">\n @for (view of views(); track view) {\n <div class=\"control\">\n <button\n class=\"button is-small\"\n [class.is-selected]=\"selectedView() === view\"\n (click)=\"selectedView.set(view)\">\n <span class=\"icon is-small\">\n <fa-icon [icon]=\"viewIcon[view]\" aria-hidden=\"true\" />\n </span>\n <span class=\"is-hidden-mobile\">{{ view }}</span>\n </button>\n </div>\n }\n </div>\n </div>\n }\n</div>\n\n@if (isNodeKeyAllowed()) {\n @switch (selectedView()) {\n @case (View.table) {\n <div class=\"is-px-3 is-pb-3\">\n @if (hasData()) {\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n @if (dataKeys().length > 1) {\n <tr class=\"has-text-weight-bold\">\n <th class=\"width-auto\"></th>\n <th [class.is-hidden]=\"isGroupNode()\"></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @if (data()[dataKey]?.length) {\n <th [attr.colspan]=\"data()[dataKey].length\" [class.has-border-right]=\"!dataKeyLast\">\n <span>{{ dataKey | keyToLabel }}</span>\n </th>\n }\n }\n </tr>\n }\n <tr class=\"has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n <th class=\"has-border-right\" [class.is-hidden]=\"isGroupNode()\"></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.name\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <he-node-link [node]=\"node.value.term\">\n <span\n [innerHtml]=\"\n node.value.term.name | ellipsis: 30 | compound: node.value.term.termType\n \"></span>\n </he-node-link>\n </th>\n }\n }\n </tr>\n <tr class=\"is-italic has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n <th class=\"has-border-right\" [class.is-hidden]=\"isGroupNode()\">\n <a [href]=\"schemaBaseUrl + '/Cycle#functionalUnit'\" target=\"_blank\">Functional unit</a>\n </th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.units\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <span [innerHtml]=\"node.value.term.units | compound: node.value.term.termType\"></span>\n <he-terms-units-description class=\"is-inline-block is-ml-2\" [term]=\"node.value.term\" />\n </th>\n }\n }\n </tr>\n </thead>\n <tbody>\n @for (cycle of cycles(); track trackById(cycleIndex, cycle); let cycleIndex = $index) {\n <tr>\n <td class=\"width-auto has-border-right\" [attr.title]=\"defaultLabel(cycle)\">\n <he-node-link [node]=\"cycleNode(cycle)\">\n <span>{{ cycleIndex + 1 }}. {{ defaultLabel(cycle) }}</span>\n </he-node-link>\n </td>\n <td class=\"has-border-right\" [class.is-hidden]=\"isGroupNode()\">\n <he-cycles-functional-unit-measure [cycle]=\"cycle\" />\n </td>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <td\n class=\"is-nowrap\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n @if (node.value.values[cycle['@id']]) {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"details\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow is-overflow-visible\"\n placement=\"left\"\n container=\"body\"\n [popoverContext]=\"{ data: node.value.values[cycle['@id']], cycle, key: dataKey }\">\n <span pointer>\n {{\n propertyValue(node.value.values[cycle['@id']].value, node.value.term['@id'])\n | precision: 3\n | default: '-'\n }}\n </span>\n <he-blank-node-state\n class=\"ml-1\"\n [dataState]=\"dataState()\"\n [node]=\"node.value.values[cycle['@id']].node\"\n key=\"value\" />\n </span>\n } @else {\n <span>-</span>\n }\n </td>\n }\n }\n </tr>\n }\n </tbody>\n </table>\n </he-data-table>\n <he-blank-node-state-notice\n [dataState]=\"dataState()\"\n [showDeleted]=\"firstNodeKey() === BlankNodesKey.emissions\" />\n } @else {\n <div class=\"is-pt-3 has-text-centered\">\n <span>No data available</span>\n <span class=\"is-pl-1\" [class.is-hidden]=\"!filterTerm()\">matching your search criteria</span>\n <span>.</span>\n @if (showSwitchToRecalculated()) {\n <span>\n Switch to\n <code>recalculated</code>\n version.\n </span>\n }\n </div>\n }\n </div>\n }\n @case (View.chart) {\n @switch (firstNodeKey()) {\n @case (BlankNodesKey.inputs) {\n <he-cycles-result [cycles]=\"cycles()\"></he-cycles-result>\n }\n @case (BlankNodesKey.emissions) {\n <he-cycles-emissions-chart [cycles]=\"cycles()\" />\n }\n }\n }\n @case (View.timeline) {\n <ng-container *ngTemplateOutlet=\"selectCycle\" />\n <div class=\"is-px-3 is-pb-3\">\n <he-cycles-nodes-timeline [recalculatedValues]=\"timelineValues()\" [dataState]=\"dataState()\" />\n <he-blank-node-state-notice [dataState]=\"dataState()\" />\n </div>\n }\n @case (View.logs) {\n <ng-container *ngTemplateOutlet=\"selectCycle\" />\n @if (nodeKeys().length > 1) {\n <div class=\"tabs is-mb-2\">\n <ul>\n @for (nodeKey of nodeKeys(); track nodeKey) {\n <li [class.is-active]=\"selectedNodeKey() === nodeKey\">\n <a (click)=\"selectedNodeKey.set(nodeKey)\">{{ nodeKey | keyToLabel }}</a>\n </li>\n }\n </ul>\n </div>\n }\n @if (selectedNode()) {\n <he-node-logs-models\n [node]=\"selectedNode()\"\n [nodeKey]=\"selectedNodeKey()\"\n [logsKey]=\"selectedLogsKey()\"\n [originalValues]=\"selectedOriginalValues()\"\n [recalculatedValues]=\"selectedRecalculatedValues()\"\n [filterTermTypes]=\"filterTermTypes()\" />\n }\n }\n }\n}\n\n<ng-template #details let-node=\"cycle\" let-data=\"data\" let-key=\"key\">\n <p>\n <b>{{ defaultLabel(node) }}</b>\n </p>\n <he-node-value-details\n class=\"is-overflow-visible\"\n [data]=\"data\"\n [dataState]=\"dataState()\"\n [nodeType]=\"node['@type']\"\n [dataKey]=\"key\" />\n</ng-template>\n\n<ng-template #selectCycle>\n @if (cycles().length > 1) {\n <div class=\"field has-addons is-py-2 is-px-3\">\n <div class=\"control\">\n <span class=\"button is-small is-static is-secondary\">Select a Cycle</span>\n </div>\n <div class=\"control is-expanded\">\n <div class=\"select is-small is-fullwidth is-secondary\">\n <select (change)=\"selectIndex($event)\">\n @for (value of cycles(); track value; let cycleIndex = $index) {\n <option [value]=\"cycleIndex\">{{ cycleIndex + 1 }}. {{ defaultLabel(value) }}</option>\n }\n </select>\n </div>\n </div>\n </div>\n }\n</ng-template>\n", styles: ["fa-icon{display:inline-block;width:10px}he-data-table ::ng-deep .table thead tr th:nth-child(2),he-data-table ::ng-deep .table tbody tr td:nth-child(2){max-width:102px;width:102px}\n"] }]
|
|
7501
|
+
], template: "@if (isGroupNode()) {\n <div class=\"tabs is-mb-1\">\n <ul>\n @for (term of groupNodeTerms(); track term.name) {\n <li [class.is-active]=\"selectedGroupTerm() === term\">\n <a (click)=\"selectedGroupTerm.set(term)\">{{ term.name }}</a>\n </li>\n }\n </ul>\n </div>\n}\n\n<div class=\"columns is-variable is-align-items-center is-2 is-m-0\">\n <div class=\"column\">\n @if (hasData() && selectedView() === View.table) {\n <button class=\"button is-small is-ghost\" (click)=\"showDownload()\">\n <fa-icon [icon]=\"faDownload\" size=\"lg\" />\n </button>\n }\n </div>\n @if (selectedView() === View.table) {\n <div class=\"column is-narrow\">\n <he-search-extend\n class=\"is-secondary is-small\"\n placeholder=\"Filter terms by name\"\n (search)=\"filterTerm.set($event)\" />\n </div>\n }\n @if (views()?.length > 1) {\n <div class=\"column is-narrow\">\n <div class=\"field has-addons\">\n @for (view of views(); track view) {\n <div class=\"control\">\n <button\n class=\"button is-small\"\n [class.is-selected]=\"selectedView() === view\"\n (click)=\"selectedView.set(view)\">\n <span class=\"icon is-small\">\n <fa-icon [icon]=\"viewIcon[view]\" aria-hidden=\"true\" />\n </span>\n <span class=\"is-hidden-mobile\">{{ view }}</span>\n </button>\n </div>\n }\n </div>\n </div>\n }\n</div>\n\n@if (isNodeKeyAllowed()) {\n @switch (selectedView()) {\n @case (View.table) {\n <div class=\"is-px-3 is-pb-3\">\n @if (hasData()) {\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n @if (dataKeys().length > 1) {\n <tr class=\"has-text-weight-bold\">\n <th class=\"width-auto\"></th>\n <th [class.is-hidden]=\"isGroupNode()\"></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @if (data()[dataKey]?.length) {\n <th [attr.colspan]=\"data()[dataKey].length\" [class.has-border-right]=\"!dataKeyLast\">\n <span>{{ dataKey | keyToLabel }}</span>\n </th>\n }\n }\n </tr>\n }\n <tr class=\"has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n <th class=\"has-border-right\" [class.is-hidden]=\"isGroupNode()\"></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.name\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <he-node-link [node]=\"node.value.term\">\n <span\n [innerHtml]=\"\n node.value.term.name | ellipsis: 30 | compound: node.value.term.termType\n \"></span>\n </he-node-link>\n </th>\n }\n }\n </tr>\n <tr class=\"is-italic has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n <th class=\"has-border-right\" [class.is-hidden]=\"isGroupNode()\">\n <a [href]=\"schemaBaseUrl + '/Cycle#functionalUnit'\" target=\"_blank\">Functional unit</a>\n </th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.units\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <span [innerHtml]=\"node.value.term.units | compound: node.value.term.termType\"></span>\n <he-terms-units-description class=\"is-inline-block is-ml-2\" [term]=\"node.value.term\" />\n </th>\n }\n }\n </tr>\n </thead>\n <tbody>\n @for (cycle of cycles(); track trackById(cycleIndex, cycle); let cycleIndex = $index) {\n <tr>\n <td class=\"width-auto has-border-right\" [attr.title]=\"defaultLabel(cycle)\">\n <he-node-link [node]=\"cycleNode(cycle)\">\n <span>{{ cycleIndex + 1 }}. {{ defaultLabel(cycle) }}</span>\n </he-node-link>\n </td>\n <td class=\"has-border-right\" [class.is-hidden]=\"isGroupNode()\">\n <he-cycles-functional-unit-measure [cycle]=\"cycle\" />\n </td>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <td\n class=\"is-nowrap\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n @if (node.value.values[cycle['@id']]) {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"details\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow is-overflow-visible\"\n placement=\"left bottom auto\"\n container=\"body\"\n [popoverContext]=\"{ data: node.value.values[cycle['@id']], cycle, key: dataKey }\">\n <span pointer>\n {{\n propertyValue(node.value.values[cycle['@id']].value, node.value.term['@id'])\n | precision: 3\n | default: '-'\n }}\n </span>\n <he-blank-node-state\n class=\"ml-1\"\n [dataState]=\"dataState()\"\n [node]=\"node.value.values[cycle['@id']].node\"\n key=\"value\" />\n </span>\n } @else {\n <span>-</span>\n }\n </td>\n }\n }\n </tr>\n }\n </tbody>\n </table>\n </he-data-table>\n <he-blank-node-state-notice\n [dataState]=\"dataState()\"\n [showDeleted]=\"firstNodeKey() === BlankNodesKey.emissions\" />\n } @else {\n <div class=\"is-pt-3 has-text-centered\">\n <span>No data available</span>\n <span class=\"is-pl-1\" [class.is-hidden]=\"!filterTerm()\">matching your search criteria</span>\n <span>.</span>\n @if (showSwitchToRecalculated()) {\n <span>\n Switch to\n <code>recalculated</code>\n version.\n </span>\n }\n </div>\n }\n </div>\n }\n @case (View.chart) {\n @switch (firstNodeKey()) {\n @case (BlankNodesKey.inputs) {\n <he-cycles-result [cycles]=\"cycles()\"></he-cycles-result>\n }\n @case (BlankNodesKey.emissions) {\n <he-cycles-emissions-chart [cycles]=\"cycles()\" />\n }\n }\n }\n @case (View.timeline) {\n <ng-container *ngTemplateOutlet=\"selectCycle\" />\n <div class=\"is-px-3 is-pb-3\">\n <he-cycles-nodes-timeline [recalculatedValues]=\"timelineValues()\" [dataState]=\"dataState()\" />\n <he-blank-node-state-notice [dataState]=\"dataState()\" />\n </div>\n }\n @case (View.logs) {\n <ng-container *ngTemplateOutlet=\"selectCycle\" />\n @if (nodeKeys().length > 1) {\n <div class=\"tabs is-mb-2\">\n <ul>\n @for (nodeKey of nodeKeys(); track nodeKey) {\n <li [class.is-active]=\"selectedNodeKey() === nodeKey\">\n <a (click)=\"selectedNodeKey.set(nodeKey)\">{{ nodeKey | keyToLabel }}</a>\n </li>\n }\n </ul>\n </div>\n }\n @if (selectedNode()) {\n <he-node-logs-models\n [node]=\"selectedNode()\"\n [nodeKey]=\"selectedNodeKey()\"\n [logsKey]=\"selectedLogsKey()\"\n [originalValues]=\"selectedOriginalValues()\"\n [recalculatedValues]=\"selectedRecalculatedValues()\"\n [filterTermTypes]=\"filterTermTypes()\" />\n }\n }\n }\n}\n\n<ng-template #details let-node=\"cycle\" let-data=\"data\" let-key=\"key\">\n <p>\n <b>{{ defaultLabel(node) }}</b>\n </p>\n <he-node-value-details\n class=\"is-overflow-visible\"\n [data]=\"data\"\n [dataState]=\"dataState()\"\n [nodeType]=\"node['@type']\"\n [dataKey]=\"key\" />\n</ng-template>\n\n<ng-template #selectCycle>\n @if (cycles().length > 1) {\n <div class=\"field has-addons is-py-2 is-px-3\">\n <div class=\"control\">\n <span class=\"button is-small is-static is-secondary\">Select a Cycle</span>\n </div>\n <div class=\"control is-expanded\">\n <div class=\"select is-small is-fullwidth is-secondary\">\n <select (change)=\"selectIndex($event)\">\n @for (value of cycles(); track value; let cycleIndex = $index) {\n <option [value]=\"cycleIndex\">{{ cycleIndex + 1 }}. {{ defaultLabel(value) }}</option>\n }\n </select>\n </div>\n </div>\n </div>\n }\n</ng-template>\n", styles: ["fa-icon{display:inline-block;width:10px}he-data-table ::ng-deep .table thead tr th:nth-child(2),he-data-table ::ng-deep .table tbody tr td:nth-child(2){max-width:102px;width:102px}\n"] }]
|
|
7502
7502
|
}], ctorParameters: () => [] });
|
|
7503
7503
|
|
|
7504
7504
|
class HeNodeCsvService {
|
|
@@ -7597,7 +7597,7 @@ class NodeLogsTimeComponent {
|
|
|
7597
7597
|
this.logs = computed(() => this.nodeLogsResource.isLoading()
|
|
7598
7598
|
? []
|
|
7599
7599
|
: parseLines(this.nodeLogsResource.value())
|
|
7600
|
-
.filter(({ data }) => data
|
|
7600
|
+
.filter(({ data }) => data?.message?.includes('memory_used'))
|
|
7601
7601
|
.map(({ data }) => parseMessage$1(data.message))
|
|
7602
7602
|
.map(data => ({
|
|
7603
7603
|
...data,
|
|
@@ -7849,7 +7849,7 @@ class EngineModelsStageDeepComponent {
|
|
|
7849
7849
|
this.service.focusedNode.set(node);
|
|
7850
7850
|
}
|
|
7851
7851
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.4", ngImport: i0, type: EngineModelsStageDeepComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
7852
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.4", type: EngineModelsStageDeepComponent, isStandalone: true, selector: "he-engine-models-stage-deep", inputs: { node: { classPropertyName: "node", publicName: "node", isSignal: true, isRequired: true, transformFunction: null }, expanded: { classPropertyName: "expanded", publicName: "expanded", isSignal: true, isRequired: false, transformFunction: null }, expandedNode: { classPropertyName: "expandedNode", publicName: "expandedNode", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { expanded: "expandedChange" }, ngImport: i0, template: "<div\n class=\"is-flex is-flex-direction-column is-gap-8 is-py-2 is-pl-2 | engine-models-stage--container is-type-{{ type }}\"\n [style.border-color]=\"nodeColour()\">\n <div class=\"is-flex is-flex-direction-row is-justify-content-space-between is-gap-8\">\n @if (canExpand()) {\n <div (click)=\"expanded.set(!expanded())\" pointer>\n <fa-icon [icon]=\"expanded() ? faAngleDown : faAngleRight\" />\n </div>\n }\n\n <div\n class=\"is-flex is-flex-direction-row is-justify-content-space-between is-gap-8 is-flex-wrap-wrap is-flex-grow-1\">\n <he-node-link class=\"is-flex-grow-1\" [node]=\"node()\" [showExternalLink]=\"true\">\n <span>{{ type() }} {{ id() }}</span>\n </he-node-link>\n\n <div class=\"is-flex is-flex-direction-column is-gap-4 | engine-models-stage--calculations\">\n <div class=\"is-flex is-gap-4 is-pr-2\">\n <span class=\"has-text-secondary has-text-weight-bold\">Calculations:</span>\n\n @if (inProgress()) {\n <span [class.has-text-danger]=\"stage() === 0\" [class.has-text-warning]=\"stage() > 0\">\n stage {{ stage() }} / {{ maxStage() }}\n </span>\n } @else {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"popoverDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n placement=\"left\"\n container=\"body\">\n <span class=\"has-text-success\">complete</span>\n </span>\n }\n\n @if (hasError()) {\n <a\n class=\"has-text-danger\"\n ngbTooltip=\"Errors during recalculation. Click to open\"\n (click)=\"openError(node())\">\n <svg-icon name=\"exclamation-triangle\" />\n </a>\n }\n </div>\n </div>\n </div>\n </div>\n\n @if (expanded()) {\n @if (loading() && nodesLength() > 0) {\n @for (node of nodesLength() | times; track $index) {\n <he-skeleton-text [width]=\"60\" />\n }\n }\n\n @for (relatedNode of expandableNodes(); track trackNode(relatedNode)) {\n <div class=\"related-node\">\n <he-engine-models-stage-deep\n [node]=\"relatedNode\"\n [expanded]=\"false\"\n [expandedNode]=\"expandedNode() || node()\" />\n </div>\n }\n }\n</div>\n\n<ng-template #popoverDetails>\n <div class=\"is-flex is-flex-direction-column is-gap-4 has-text-white w-100\">\n <div class=\"is-flex is-align-items-center is-gap-8 w-100\">\n <span class=\"has-text-weight-bold\">Calculated Date:</span>\n <span>{{ recalculatedAt() | date: 'mediumDate' }}</span>\n </div>\n <div class=\"is-flex is-align-items-center is-gap-8 w-100\">\n <span class=\"has-text-weight-bold\">Calculated Version:</span>\n <he-engine-models-version-link [node]=\"node()\" [showDetails]=\"true\" />\n </div>\n </div>\n</ng-template>\n", styles: [".engine-models-stage--container{border:1px solid transparent;border-radius:3px}he-engine-models-stage-deep ::ng-deep .engine-models-stage--container{border-right:0px;border-top-right-radius:0;border-bottom-right-radius:0}\n"], dependencies: [{ kind: "component", type: EngineModelsStageDeepComponent, selector: "he-engine-models-stage-deep", inputs: ["node", "expanded", "expandedNode"], outputs: ["expandedChange"] }, { kind: "pipe", type: DatePipe, name: "date" }, { kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "component", type: SvgIconComponent, selector: "svg-icon", inputs: ["src", "name", "stretch", "applyClass", "svgClass", "class", "viewBox", "svgAriaLabel", "onSVGLoaded", "svgStyle"] }, { kind: "ngmodule", type: NgbPopoverModule }, { kind: "directive", type: i1$2.NgbPopover, selector: "[ngbPopover]", inputs: ["animation", "autoClose", "ngbPopover", "popoverTitle", "placement", "popperOptions", "triggers", "positionTarget", "container", "disablePopover", "popoverClass", "popoverContext", "openDelay", "closeDelay"], outputs: ["shown", "hidden"], exportAs: ["ngbPopover"] }, { kind: "ngmodule", type: NgbTooltipModule }, { kind: "directive", type: i1$2.NgbTooltip, selector: "[ngbTooltip]", inputs: ["animation", "autoClose", "placement", "popperOptions", "triggers", "positionTarget", "container", "disableTooltip", "tooltipClass", "tooltipContext", "openDelay", "closeDelay", "ngbTooltip"], outputs: ["shown", "hidden"], exportAs: ["ngbTooltip"] }, { kind: "component", type: EngineModelsVersionLinkComponent, selector: "he-engine-models-version-link", inputs: ["node", "showDetails"] }, { kind: "component", type: SkeletonTextComponent, selector: "he-skeleton-text", inputs: ["animated", "width", "height"] }, { kind: "pipe", type: TimesPipe, name: "times" }, { kind: "component", type: NodeLinkComponent, selector: "he-node-link", inputs: ["node", "showExternalLink", "linkClass"] }] }); }
|
|
7852
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.4", type: EngineModelsStageDeepComponent, isStandalone: true, selector: "he-engine-models-stage-deep", inputs: { node: { classPropertyName: "node", publicName: "node", isSignal: true, isRequired: true, transformFunction: null }, expanded: { classPropertyName: "expanded", publicName: "expanded", isSignal: true, isRequired: false, transformFunction: null }, expandedNode: { classPropertyName: "expandedNode", publicName: "expandedNode", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { expanded: "expandedChange" }, ngImport: i0, template: "<div\n class=\"is-flex is-flex-direction-column is-gap-8 is-py-2 is-pl-2 | engine-models-stage--container is-type-{{ type }}\"\n [style.border-color]=\"nodeColour()\">\n <div class=\"is-flex is-flex-direction-row is-justify-content-space-between is-gap-8\">\n @if (canExpand()) {\n <div (click)=\"expanded.set(!expanded())\" pointer>\n <fa-icon [icon]=\"expanded() ? faAngleDown : faAngleRight\" />\n </div>\n }\n\n <div\n class=\"is-flex is-flex-direction-row is-justify-content-space-between is-gap-8 is-flex-wrap-wrap is-flex-grow-1\">\n <he-node-link class=\"is-flex-grow-1\" [node]=\"node()\" [showExternalLink]=\"true\">\n <span>{{ type() }} {{ id() }}</span>\n </he-node-link>\n\n <div class=\"is-flex is-flex-direction-column is-gap-4 | engine-models-stage--calculations\">\n <div class=\"is-flex is-gap-4 is-pr-2\">\n <span class=\"has-text-secondary has-text-weight-bold\">Calculations:</span>\n\n @if (inProgress()) {\n <span [class.has-text-danger]=\"stage() === 0\" [class.has-text-warning]=\"stage() > 0\">\n stage {{ stage() }} / {{ maxStage() }}\n </span>\n } @else {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"popoverDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n placement=\"left auto\"\n container=\"body\">\n <span class=\"has-text-success\">complete</span>\n </span>\n }\n\n @if (hasError()) {\n <a\n class=\"has-text-danger\"\n ngbTooltip=\"Errors during recalculation. Click to open\"\n (click)=\"openError(node())\">\n <svg-icon name=\"exclamation-triangle\" />\n </a>\n }\n </div>\n </div>\n </div>\n </div>\n\n @if (expanded()) {\n @if (loading() && nodesLength() > 0) {\n @for (node of nodesLength() | times; track $index) {\n <he-skeleton-text [width]=\"60\" />\n }\n }\n\n @for (relatedNode of expandableNodes(); track trackNode(relatedNode)) {\n <div class=\"related-node\">\n <he-engine-models-stage-deep\n [node]=\"relatedNode\"\n [expanded]=\"false\"\n [expandedNode]=\"expandedNode() || node()\" />\n </div>\n }\n }\n</div>\n\n<ng-template #popoverDetails>\n <div class=\"is-flex is-flex-direction-column is-gap-4 has-text-white w-100\">\n <div class=\"is-flex is-align-items-center is-gap-8 w-100\">\n <span class=\"has-text-weight-bold\">Calculated Date:</span>\n <span>{{ recalculatedAt() | date: 'mediumDate' }}</span>\n </div>\n <div class=\"is-flex is-align-items-center is-gap-8 w-100\">\n <span class=\"has-text-weight-bold\">Calculated Version:</span>\n <he-engine-models-version-link [node]=\"node()\" [showDetails]=\"true\" />\n </div>\n </div>\n</ng-template>\n", styles: [".engine-models-stage--container{border:1px solid transparent;border-radius:3px}he-engine-models-stage-deep ::ng-deep .engine-models-stage--container{border-right:0px;border-top-right-radius:0;border-bottom-right-radius:0}\n"], dependencies: [{ kind: "component", type: EngineModelsStageDeepComponent, selector: "he-engine-models-stage-deep", inputs: ["node", "expanded", "expandedNode"], outputs: ["expandedChange"] }, { kind: "pipe", type: DatePipe, name: "date" }, { kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "component", type: SvgIconComponent, selector: "svg-icon", inputs: ["src", "name", "stretch", "applyClass", "svgClass", "class", "viewBox", "svgAriaLabel", "onSVGLoaded", "svgStyle"] }, { kind: "ngmodule", type: NgbPopoverModule }, { kind: "directive", type: i1$2.NgbPopover, selector: "[ngbPopover]", inputs: ["animation", "autoClose", "ngbPopover", "popoverTitle", "placement", "popperOptions", "triggers", "positionTarget", "container", "disablePopover", "popoverClass", "popoverContext", "openDelay", "closeDelay"], outputs: ["shown", "hidden"], exportAs: ["ngbPopover"] }, { kind: "ngmodule", type: NgbTooltipModule }, { kind: "directive", type: i1$2.NgbTooltip, selector: "[ngbTooltip]", inputs: ["animation", "autoClose", "placement", "popperOptions", "triggers", "positionTarget", "container", "disableTooltip", "tooltipClass", "tooltipContext", "openDelay", "closeDelay", "ngbTooltip"], outputs: ["shown", "hidden"], exportAs: ["ngbTooltip"] }, { kind: "component", type: EngineModelsVersionLinkComponent, selector: "he-engine-models-version-link", inputs: ["node", "showDetails"] }, { kind: "component", type: SkeletonTextComponent, selector: "he-skeleton-text", inputs: ["animated", "width", "height"] }, { kind: "pipe", type: TimesPipe, name: "times" }, { kind: "component", type: NodeLinkComponent, selector: "he-node-link", inputs: ["node", "showExternalLink", "linkClass"] }] }); }
|
|
7853
7853
|
}
|
|
7854
7854
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.4", ngImport: i0, type: EngineModelsStageDeepComponent, decorators: [{
|
|
7855
7855
|
type: Component$1,
|
|
@@ -7863,7 +7863,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.4", ngImpor
|
|
|
7863
7863
|
SkeletonTextComponent,
|
|
7864
7864
|
TimesPipe,
|
|
7865
7865
|
NodeLinkComponent
|
|
7866
|
-
], template: "<div\n class=\"is-flex is-flex-direction-column is-gap-8 is-py-2 is-pl-2 | engine-models-stage--container is-type-{{ type }}\"\n [style.border-color]=\"nodeColour()\">\n <div class=\"is-flex is-flex-direction-row is-justify-content-space-between is-gap-8\">\n @if (canExpand()) {\n <div (click)=\"expanded.set(!expanded())\" pointer>\n <fa-icon [icon]=\"expanded() ? faAngleDown : faAngleRight\" />\n </div>\n }\n\n <div\n class=\"is-flex is-flex-direction-row is-justify-content-space-between is-gap-8 is-flex-wrap-wrap is-flex-grow-1\">\n <he-node-link class=\"is-flex-grow-1\" [node]=\"node()\" [showExternalLink]=\"true\">\n <span>{{ type() }} {{ id() }}</span>\n </he-node-link>\n\n <div class=\"is-flex is-flex-direction-column is-gap-4 | engine-models-stage--calculations\">\n <div class=\"is-flex is-gap-4 is-pr-2\">\n <span class=\"has-text-secondary has-text-weight-bold\">Calculations:</span>\n\n @if (inProgress()) {\n <span [class.has-text-danger]=\"stage() === 0\" [class.has-text-warning]=\"stage() > 0\">\n stage {{ stage() }} / {{ maxStage() }}\n </span>\n } @else {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"popoverDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n placement=\"left\"\n container=\"body\">\n <span class=\"has-text-success\">complete</span>\n </span>\n }\n\n @if (hasError()) {\n <a\n class=\"has-text-danger\"\n ngbTooltip=\"Errors during recalculation. Click to open\"\n (click)=\"openError(node())\">\n <svg-icon name=\"exclamation-triangle\" />\n </a>\n }\n </div>\n </div>\n </div>\n </div>\n\n @if (expanded()) {\n @if (loading() && nodesLength() > 0) {\n @for (node of nodesLength() | times; track $index) {\n <he-skeleton-text [width]=\"60\" />\n }\n }\n\n @for (relatedNode of expandableNodes(); track trackNode(relatedNode)) {\n <div class=\"related-node\">\n <he-engine-models-stage-deep\n [node]=\"relatedNode\"\n [expanded]=\"false\"\n [expandedNode]=\"expandedNode() || node()\" />\n </div>\n }\n }\n</div>\n\n<ng-template #popoverDetails>\n <div class=\"is-flex is-flex-direction-column is-gap-4 has-text-white w-100\">\n <div class=\"is-flex is-align-items-center is-gap-8 w-100\">\n <span class=\"has-text-weight-bold\">Calculated Date:</span>\n <span>{{ recalculatedAt() | date: 'mediumDate' }}</span>\n </div>\n <div class=\"is-flex is-align-items-center is-gap-8 w-100\">\n <span class=\"has-text-weight-bold\">Calculated Version:</span>\n <he-engine-models-version-link [node]=\"node()\" [showDetails]=\"true\" />\n </div>\n </div>\n</ng-template>\n", styles: [".engine-models-stage--container{border:1px solid transparent;border-radius:3px}he-engine-models-stage-deep ::ng-deep .engine-models-stage--container{border-right:0px;border-top-right-radius:0;border-bottom-right-radius:0}\n"] }]
|
|
7866
|
+
], template: "<div\n class=\"is-flex is-flex-direction-column is-gap-8 is-py-2 is-pl-2 | engine-models-stage--container is-type-{{ type }}\"\n [style.border-color]=\"nodeColour()\">\n <div class=\"is-flex is-flex-direction-row is-justify-content-space-between is-gap-8\">\n @if (canExpand()) {\n <div (click)=\"expanded.set(!expanded())\" pointer>\n <fa-icon [icon]=\"expanded() ? faAngleDown : faAngleRight\" />\n </div>\n }\n\n <div\n class=\"is-flex is-flex-direction-row is-justify-content-space-between is-gap-8 is-flex-wrap-wrap is-flex-grow-1\">\n <he-node-link class=\"is-flex-grow-1\" [node]=\"node()\" [showExternalLink]=\"true\">\n <span>{{ type() }} {{ id() }}</span>\n </he-node-link>\n\n <div class=\"is-flex is-flex-direction-column is-gap-4 | engine-models-stage--calculations\">\n <div class=\"is-flex is-gap-4 is-pr-2\">\n <span class=\"has-text-secondary has-text-weight-bold\">Calculations:</span>\n\n @if (inProgress()) {\n <span [class.has-text-danger]=\"stage() === 0\" [class.has-text-warning]=\"stage() > 0\">\n stage {{ stage() }} / {{ maxStage() }}\n </span>\n } @else {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"popoverDetails\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow\"\n placement=\"left auto\"\n container=\"body\">\n <span class=\"has-text-success\">complete</span>\n </span>\n }\n\n @if (hasError()) {\n <a\n class=\"has-text-danger\"\n ngbTooltip=\"Errors during recalculation. Click to open\"\n (click)=\"openError(node())\">\n <svg-icon name=\"exclamation-triangle\" />\n </a>\n }\n </div>\n </div>\n </div>\n </div>\n\n @if (expanded()) {\n @if (loading() && nodesLength() > 0) {\n @for (node of nodesLength() | times; track $index) {\n <he-skeleton-text [width]=\"60\" />\n }\n }\n\n @for (relatedNode of expandableNodes(); track trackNode(relatedNode)) {\n <div class=\"related-node\">\n <he-engine-models-stage-deep\n [node]=\"relatedNode\"\n [expanded]=\"false\"\n [expandedNode]=\"expandedNode() || node()\" />\n </div>\n }\n }\n</div>\n\n<ng-template #popoverDetails>\n <div class=\"is-flex is-flex-direction-column is-gap-4 has-text-white w-100\">\n <div class=\"is-flex is-align-items-center is-gap-8 w-100\">\n <span class=\"has-text-weight-bold\">Calculated Date:</span>\n <span>{{ recalculatedAt() | date: 'mediumDate' }}</span>\n </div>\n <div class=\"is-flex is-align-items-center is-gap-8 w-100\">\n <span class=\"has-text-weight-bold\">Calculated Version:</span>\n <he-engine-models-version-link [node]=\"node()\" [showDetails]=\"true\" />\n </div>\n </div>\n</ng-template>\n", styles: [".engine-models-stage--container{border:1px solid transparent;border-radius:3px}he-engine-models-stage-deep ::ng-deep .engine-models-stage--container{border-right:0px;border-top-right-radius:0;border-bottom-right-radius:0}\n"] }]
|
|
7867
7867
|
}], ctorParameters: () => [] });
|
|
7868
7868
|
|
|
7869
7869
|
const gitUrl = `${gitHome}/${Repository.orchestrator}/-/blob/${gitBranch()}`;
|
|
@@ -8046,10 +8046,11 @@ const parseDataPath = (dataPath = '') => {
|
|
|
8046
8046
|
return paths.map(path => {
|
|
8047
8047
|
const label = path.replace(/[\d\@]+/g, '');
|
|
8048
8048
|
const type = pluralize(keyToLabel(label), 1);
|
|
8049
|
-
const isSchemaType = isTypeValid({ type });
|
|
8050
8049
|
return {
|
|
8050
|
+
nodeType: isTypeNode(type) ? type : null,
|
|
8051
|
+
schemaType: isTypeBlankNode(type) ? type : null,
|
|
8051
8052
|
path: path.replace(/(\d+)/g, '[$1]'),
|
|
8052
|
-
label:
|
|
8053
|
+
label: isTypeValid({ type }) ? type : `<code>${pluralize(label, 1)}</code>`
|
|
8053
8054
|
};
|
|
8054
8055
|
});
|
|
8055
8056
|
};
|
|
@@ -8103,6 +8104,9 @@ const customErrorMessage = {
|
|
|
8103
8104
|
or ${schemaLink('ImpactAssessment#endpoints', 'endpoints')}.`
|
|
8104
8105
|
: ''
|
|
8105
8106
|
].join('\n'),
|
|
8107
|
+
"should have required property '@type'": ({ dataPath }) => parseDataPath(dataPath)?.[0]?.schemaType
|
|
8108
|
+
? `Please add ${code(`"@type" = "${parseDataPath(dataPath)[0].schemaType}"`)} to this blank node.`
|
|
8109
|
+
: '',
|
|
8106
8110
|
"should have required property '@id'": idNotFoundError,
|
|
8107
8111
|
"should have required property 'id'": idNotFoundError,
|
|
8108
8112
|
'should match exactly one schema in oneOf': () => '',
|
|
@@ -8520,7 +8524,8 @@ const customErrorMessage = {
|
|
|
8520
8524
|
This is particularly important for ruminants and will allow for a more accurate estimate of the amount of grass grazed.`,
|
|
8521
8525
|
'should add the fields for a relative cycle': ({ params }) => `We strongly recommend setting ${params?.expected
|
|
8522
8526
|
?.map((param) => code(param))
|
|
8523
|
-
.join('and')} on all other sites for any uploads with a ${code('relative')} functional unit. This will allow calculation of land occupation and land transformation
|
|
8527
|
+
.join('and')} on all other sites for any uploads with a ${code('relative')} functional unit. This will allow calculation of land occupation and land transformation.`,
|
|
8528
|
+
'must not be blank if complete': ({ params }) => `If completeness is set to True for ${schemaLink(`Completeness#${params.expected}`, params.expected)}, none of the data in the completeness area can have missing or blank values.`
|
|
8524
8529
|
};
|
|
8525
8530
|
const requiredPropertyError = (message, error) => {
|
|
8526
8531
|
const field = message.split("'")[1].replace("'", '');
|
|
@@ -11251,7 +11256,7 @@ class ImpactAssessmentsProductsComponent {
|
|
|
11251
11256
|
component.headerKeys.set(this.headerKeys());
|
|
11252
11257
|
}
|
|
11253
11258
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.4", ngImport: i0, type: ImpactAssessmentsProductsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
11254
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.4", type: ImpactAssessmentsProductsComponent, isStandalone: true, selector: "he-impact-assessments-products", inputs: { dataState: { classPropertyName: "dataState", publicName: "dataState", isSignal: true, isRequired: false, transformFunction: null }, nodeKey: { classPropertyName: "nodeKey", publicName: "nodeKey", isSignal: true, isRequired: false, transformFunction: null }, filterTermTypes: { classPropertyName: "filterTermTypes", publicName: "filterTermTypes", isSignal: true, isRequired: false, transformFunction: null }, enableFilterMethodModel: { classPropertyName: "enableFilterMethodModel", publicName: "enableFilterMethodModel", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"columns is-variable is-align-items-center is-2 is-m-0\">\n <div class=\"column\">\n @if (hasData() && selectedView() === View.table) {\n <button class=\"button is-small is-ghost\" (click)=\"showDownload()\">\n <fa-icon [icon]=\"faDownload\" size=\"lg\" />\n </button>\n }\n </div>\n @if (selectedView() === View.table) {\n <div class=\"column is-narrow\">\n <he-search-extend\n class=\"is-secondary is-small\"\n placeholder=\"Filter terms by name\"\n (search)=\"filterTerm.set($event)\" />\n </div>\n }\n @if (views()?.length > 1) {\n <div class=\"column is-narrow\">\n <div class=\"field has-addons\">\n @for (view of views(); track view) {\n <div class=\"control\">\n <button\n class=\"button is-small\"\n [class.is-selected]=\"selectedView() === view\"\n (click)=\"selectedView.set(view)\">\n <span class=\"icon is-small\">\n <fa-icon [icon]=\"viewIcon[view]\" aria-hidden=\"true\" />\n </span>\n <span class=\"is-hidden-mobile\">{{ view }}</span>\n </button>\n </div>\n }\n </div>\n </div>\n }\n</div>\n\n@if (isNodeKeyAllowed()) {\n @switch (selectedView()) {\n @case (View.table) {\n <div class=\"is-px-3 is-pb-3\">\n @if (hasData()) {\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n @if (dataKeys().length > 1) {\n <tr class=\"has-text-weight-bold\">\n <th class=\"width-auto\"></th>\n <th></th>\n <th></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @if (data()[dataKey]?.length) {\n <th [attr.colspan]=\"data()[dataKey].length\" [class.has-border-right]=\"!dataKeyLast\">\n @if (dataKey) {\n <span>{{ dataKey | keyToLabel }}</span>\n }\n </th>\n }\n }\n </tr>\n }\n <tr class=\"has-text-weight-semibold\">\n <th class=\"width-auto has-border-right is-py-0\">\n @if (enableFilterMethodModel()) {\n <div class=\"select is-small\">\n <select (change)=\"updateSelectedMethodModel($event.target.value)\">\n <option [ngValue]=\"undefined\">Filter Model</option>\n @for (term of methodModels(); track term) {\n <option [ngValue]=\"term\">{{ term.name }}</option>\n }\n </select>\n </div>\n }\n </th>\n <th class=\"has-border-right\"></th>\n <th class=\"has-border-right\"></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.name\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <he-node-link [node]=\"node.value.term\">\n <span\n [innerHtml]=\"\n node.value.term.name | ellipsis: 30 | compound: node.value.term.termType\n \"></span>\n </he-node-link>\n </th>\n }\n }\n </tr>\n <tr class=\"is-italic has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n <th class=\"has-border-right\">\n <a [href]=\"schemaBaseUrl + '/ImpactAssessment#functionalUnit'\" target=\"_blank\">Functional unit</a>\n </th>\n <th class=\"has-border-right\">\n <a [href]=\"schemaBaseUrl + '/ImpactAssessment#product'\" target=\"_blank\">Product</a>\n </th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.units\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <span [innerHtml]=\"node.value.term.units | compound: node.value.term.termType\"></span>\n <he-terms-units-description class=\"is-inline-block is-ml-2\" [term]=\"node.value.term\" />\n </th>\n }\n }\n </tr>\n </thead>\n <tbody>\n @for (\n impactAssessment of impactAssessments();\n track trackById(impactIndex, impactAssessment);\n let impactIndex = $index\n ) {\n <tr>\n <td class=\"width-auto has-border-right\" [attr.title]=\"impactName(impactAssessment)\">\n <he-node-link [node]=\"impactAssessment\">\n <span>{{ impactIndex + 1 }}. {{ impactName(impactAssessment) }}</span>\n </he-node-link>\n </td>\n <td class=\"has-border-right\" [attr.title]=\"impactAssessment.product?.term?.units\">\n <span>1 {{ impactAssessment.product?.term?.units }}</span>\n </td>\n <td class=\"has-border-right\" [attr.title]=\"impactAssessment.product?.term?.name\">\n @if (impactAssessment.product?.term) {\n <he-node-link [node]=\"impactAssessment.product.term\">\n <span>{{ impactAssessment.product.term.name | ellipsis: 30 }}</span>\n </he-node-link>\n }\n </td>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <td\n class=\"is-nowrap\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n @if (node.value.values[impactAssessment['@id']]) {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"details\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow is-overflow-visible\"\n placement=\"left\"\n container=\"body\"\n [popoverContext]=\"{\n data: node.value.values[impactAssessment['@id']],\n impactAssessment\n }\">\n <span pointer>\n {{\n propertyValue(\n node.value.values[impactAssessment['@id']].value,\n node.value.term['@id']\n )\n | precision: 3\n | default: '-'\n }}\n </span>\n <he-blank-node-state\n class=\"ml-1\"\n [dataState]=\"dataState()\"\n [node]=\"node.value.values[impactAssessment['@id']].node\"\n key=\"value\"\n [state]=\"impactAssessment.aggregated ? 'aggregated' : undefined\" />\n </span>\n } @else {\n <span>-</span>\n }\n </td>\n }\n }\n </tr>\n }\n </tbody>\n </table>\n </he-data-table>\n <he-blank-node-state-notice [dataState]=\"dataState()\" />\n } @else {\n <div class=\"is-pt-3 has-text-centered\">\n <span>No data available</span>\n <span class=\"is-pl-1\" [class.is-hidden]=\"!filterTerm()\">matching your search criteria</span>\n <span>.</span>\n @if (showSwitchToRecalculated()) {\n <span>\n Switch to\n <code>recalculated</code>\n version.\n </span>\n }\n </div>\n }\n </div>\n }\n @case (View.chart) {\n <he-impact-assessments-indicators-chart [key]=\"nodeKey()\" [filterTermTypes]=\"filterTermTypes()\" />\n }\n @case (View.breakdown) {\n <he-impact-assessments-indicator-breakdown-chart\n [impactAssessment]=\"selectedNode()\"\n [indicators]=\"selectedRecalculatedValues()\" />\n }\n @case (View.logs) {\n @if (impactAssessments().length > 1) {\n <div class=\"field has-addons pt-2 px-3\">\n <div class=\"control\">\n <span class=\"button is-small is-static is-secondary\">Select an Impact Assessment</span>\n </div>\n <div class=\"control is-expanded\">\n <div class=\"select is-small is-fullwidth is-secondary\">\n <select (change)=\"selectIndex($event)\">\n @for (value of impactAssessments(); track value; let i = $index) {\n <option [value]=\"i\">{{ i + 1 }}. {{ impactName(value) }}</option>\n }\n </select>\n </div>\n </div>\n </div>\n }\n @if (selectedNode()) {\n <he-node-logs-models\n [node]=\"selectedNode()\"\n [nodeKey]=\"nodeKey()\"\n [filterTermTypes]=\"filterTermTypes()\"\n [originalValues]=\"selectedOriginalValues()\"\n [recalculatedValues]=\"selectedRecalculatedValues()\"\n [noDataMessage]=\"noDataMessage()\" />\n }\n }\n }\n}\n\n<ng-template #details let-node=\"impactAssessment\" let-data=\"data\">\n <p>\n <b>\n @if (data.cycle) {\n <span>{{ cycleLabel(node.cycle) }}</span>\n }\n @if (!data.cycle) {\n <span>{{ data.name }}</span>\n }\n </b>\n </p>\n <he-node-value-details\n class=\"is-overflow-visible\"\n [data]=\"data\"\n [dataState]=\"dataState()\"\n [nodeType]=\"node['@type']\"\n [dataKey]=\"nodeKey()\" />\n</ng-template>\n", styles: ["fa-icon{display:inline-block;width:10px}he-data-table ::ng-deep .table thead tr th:nth-child(2),he-data-table ::ng-deep .table tbody tr td:nth-child(2){max-width:102px;width:102px}he-data-table ::ng-deep .table thead tr th:nth-child(3),he-data-table ::ng-deep .table tbody tr td:nth-child(3){min-width:110px}\n"], dependencies: [{ kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "component", type: SearchExtendComponent, selector: "he-search-extend", inputs: ["value", "disabled", "placeholder", "class"], outputs: ["valueChange", "search"] }, { kind: "component", type: DataTableComponent, selector: "he-data-table", inputs: ["minHeight", "maxHeight", "small"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "component", type: NodeLinkComponent, selector: "he-node-link", inputs: ["node", "showExternalLink", "linkClass"] }, { kind: "component", type: TermsUnitsDescriptionComponent, selector: "he-terms-units-description", inputs: ["term", "iconTemplate"] }, { kind: "directive", type: NgbPopover, selector: "[ngbPopover]", inputs: ["animation", "autoClose", "ngbPopover", "popoverTitle", "placement", "popperOptions", "triggers", "positionTarget", "container", "disablePopover", "popoverClass", "popoverContext", "openDelay", "closeDelay"], outputs: ["shown", "hidden"], exportAs: ["ngbPopover"] }, { kind: "component", type: BlankNodeStateComponent, selector: "he-blank-node-state", inputs: ["dataState", "nodeType", "dataKey", "key", "node", "state", "linkClass"] }, { kind: "component", type: BlankNodeStateNoticeComponent, selector: "he-blank-node-state-notice", inputs: ["dataState", "showDeleted"] }, { kind: "component", type: ImpactAssessmentsIndicatorsChartComponent, selector: "he-impact-assessments-indicators-chart", inputs: ["key", "filterTermTypes"] }, { kind: "component", type: ImpactAssessmentsIndicatorBreakdownChartComponent, selector: "he-impact-assessments-indicator-breakdown-chart", inputs: ["impactAssessment", "indicators"] }, { kind: "component", type: NodeLogsModelsComponent, selector: "he-node-logs-models", inputs: ["node", "nodeKey", "originalValues", "recalculatedValues", "terms", "filterTermTypes", "filterTermTypesLabel", "logsKey", "noDataMessage"] }, { kind: "component", type: NodeValueDetailsComponent, selector: "he-node-value-details", inputs: ["data", "nodeType", "dataState", "dataKey"] }, { kind: "pipe", type: CompoundPipe, name: "compound" }, { kind: "pipe", type: DefaultPipe, name: "default" }, { kind: "pipe", type: EllipsisPipe, name: "ellipsis" }, { kind: "pipe", type: PrecisionPipe, name: "precision" }, { kind: "pipe", type: KeyToLabelPipe, name: "keyToLabel" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
11259
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.4", type: ImpactAssessmentsProductsComponent, isStandalone: true, selector: "he-impact-assessments-products", inputs: { dataState: { classPropertyName: "dataState", publicName: "dataState", isSignal: true, isRequired: false, transformFunction: null }, nodeKey: { classPropertyName: "nodeKey", publicName: "nodeKey", isSignal: true, isRequired: false, transformFunction: null }, filterTermTypes: { classPropertyName: "filterTermTypes", publicName: "filterTermTypes", isSignal: true, isRequired: false, transformFunction: null }, enableFilterMethodModel: { classPropertyName: "enableFilterMethodModel", publicName: "enableFilterMethodModel", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"columns is-variable is-align-items-center is-2 is-m-0\">\n <div class=\"column\">\n @if (hasData() && selectedView() === View.table) {\n <button class=\"button is-small is-ghost\" (click)=\"showDownload()\">\n <fa-icon [icon]=\"faDownload\" size=\"lg\" />\n </button>\n }\n </div>\n @if (selectedView() === View.table) {\n <div class=\"column is-narrow\">\n <he-search-extend\n class=\"is-secondary is-small\"\n placeholder=\"Filter terms by name\"\n (search)=\"filterTerm.set($event)\" />\n </div>\n }\n @if (views()?.length > 1) {\n <div class=\"column is-narrow\">\n <div class=\"field has-addons\">\n @for (view of views(); track view) {\n <div class=\"control\">\n <button\n class=\"button is-small\"\n [class.is-selected]=\"selectedView() === view\"\n (click)=\"selectedView.set(view)\">\n <span class=\"icon is-small\">\n <fa-icon [icon]=\"viewIcon[view]\" aria-hidden=\"true\" />\n </span>\n <span class=\"is-hidden-mobile\">{{ view }}</span>\n </button>\n </div>\n }\n </div>\n </div>\n }\n</div>\n\n@if (isNodeKeyAllowed()) {\n @switch (selectedView()) {\n @case (View.table) {\n <div class=\"is-px-3 is-pb-3\">\n @if (hasData()) {\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n @if (dataKeys().length > 1) {\n <tr class=\"has-text-weight-bold\">\n <th class=\"width-auto\"></th>\n <th></th>\n <th></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @if (data()[dataKey]?.length) {\n <th [attr.colspan]=\"data()[dataKey].length\" [class.has-border-right]=\"!dataKeyLast\">\n @if (dataKey) {\n <span>{{ dataKey | keyToLabel }}</span>\n }\n </th>\n }\n }\n </tr>\n }\n <tr class=\"has-text-weight-semibold\">\n <th class=\"width-auto has-border-right is-py-0\">\n @if (enableFilterMethodModel()) {\n <div class=\"select is-small\">\n <select (change)=\"updateSelectedMethodModel($event.target.value)\">\n <option [ngValue]=\"undefined\">Filter Model</option>\n @for (term of methodModels(); track term) {\n <option [ngValue]=\"term\">{{ term.name }}</option>\n }\n </select>\n </div>\n }\n </th>\n <th class=\"has-border-right\"></th>\n <th class=\"has-border-right\"></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.name\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <he-node-link [node]=\"node.value.term\">\n <span\n [innerHtml]=\"\n node.value.term.name | ellipsis: 30 | compound: node.value.term.termType\n \"></span>\n </he-node-link>\n </th>\n }\n }\n </tr>\n <tr class=\"is-italic has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n <th class=\"has-border-right\">\n <a [href]=\"schemaBaseUrl + '/ImpactAssessment#functionalUnit'\" target=\"_blank\">Functional unit</a>\n </th>\n <th class=\"has-border-right\">\n <a [href]=\"schemaBaseUrl + '/ImpactAssessment#product'\" target=\"_blank\">Product</a>\n </th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.units\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <span [innerHtml]=\"node.value.term.units | compound: node.value.term.termType\"></span>\n <he-terms-units-description class=\"is-inline-block is-ml-2\" [term]=\"node.value.term\" />\n </th>\n }\n }\n </tr>\n </thead>\n <tbody>\n @for (\n impactAssessment of impactAssessments();\n track trackById(impactIndex, impactAssessment);\n let impactIndex = $index\n ) {\n <tr>\n <td class=\"width-auto has-border-right\" [attr.title]=\"impactName(impactAssessment)\">\n <he-node-link [node]=\"impactAssessment\">\n <span>{{ impactIndex + 1 }}. {{ impactName(impactAssessment) }}</span>\n </he-node-link>\n </td>\n <td class=\"has-border-right\" [attr.title]=\"impactAssessment.product?.term?.units\">\n <span>1 {{ impactAssessment.product?.term?.units }}</span>\n </td>\n <td class=\"has-border-right\" [attr.title]=\"impactAssessment.product?.term?.name\">\n @if (impactAssessment.product?.term) {\n <he-node-link [node]=\"impactAssessment.product.term\">\n <span>{{ impactAssessment.product.term.name | ellipsis: 30 }}</span>\n </he-node-link>\n }\n </td>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <td\n class=\"is-nowrap\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n @if (node.value.values[impactAssessment['@id']]) {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"details\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow is-overflow-visible\"\n placement=\"left bottom auto\"\n container=\"body\"\n [popoverContext]=\"{\n data: node.value.values[impactAssessment['@id']],\n impactAssessment\n }\">\n <span pointer>\n {{\n propertyValue(\n node.value.values[impactAssessment['@id']].value,\n node.value.term['@id']\n )\n | precision: 3\n | default: '-'\n }}\n </span>\n <he-blank-node-state\n class=\"ml-1\"\n [dataState]=\"dataState()\"\n [node]=\"node.value.values[impactAssessment['@id']].node\"\n key=\"value\"\n [state]=\"impactAssessment.aggregated ? 'aggregated' : undefined\" />\n </span>\n } @else {\n <span>-</span>\n }\n </td>\n }\n }\n </tr>\n }\n </tbody>\n </table>\n </he-data-table>\n <he-blank-node-state-notice [dataState]=\"dataState()\" />\n } @else {\n <div class=\"is-pt-3 has-text-centered\">\n <span>No data available</span>\n <span class=\"is-pl-1\" [class.is-hidden]=\"!filterTerm()\">matching your search criteria</span>\n <span>.</span>\n @if (showSwitchToRecalculated()) {\n <span>\n Switch to\n <code>recalculated</code>\n version.\n </span>\n }\n </div>\n }\n </div>\n }\n @case (View.chart) {\n <he-impact-assessments-indicators-chart [key]=\"nodeKey()\" [filterTermTypes]=\"filterTermTypes()\" />\n }\n @case (View.breakdown) {\n <he-impact-assessments-indicator-breakdown-chart\n [impactAssessment]=\"selectedNode()\"\n [indicators]=\"selectedRecalculatedValues()\" />\n }\n @case (View.logs) {\n @if (impactAssessments().length > 1) {\n <div class=\"field has-addons pt-2 px-3\">\n <div class=\"control\">\n <span class=\"button is-small is-static is-secondary\">Select an Impact Assessment</span>\n </div>\n <div class=\"control is-expanded\">\n <div class=\"select is-small is-fullwidth is-secondary\">\n <select (change)=\"selectIndex($event)\">\n @for (value of impactAssessments(); track value; let i = $index) {\n <option [value]=\"i\">{{ i + 1 }}. {{ impactName(value) }}</option>\n }\n </select>\n </div>\n </div>\n </div>\n }\n @if (selectedNode()) {\n <he-node-logs-models\n [node]=\"selectedNode()\"\n [nodeKey]=\"nodeKey()\"\n [filterTermTypes]=\"filterTermTypes()\"\n [originalValues]=\"selectedOriginalValues()\"\n [recalculatedValues]=\"selectedRecalculatedValues()\"\n [noDataMessage]=\"noDataMessage()\" />\n }\n }\n }\n}\n\n<ng-template #details let-node=\"impactAssessment\" let-data=\"data\">\n <p>\n <b>\n @if (data.cycle) {\n <span>{{ cycleLabel(node.cycle) }}</span>\n }\n @if (!data.cycle) {\n <span>{{ data.name }}</span>\n }\n </b>\n </p>\n <he-node-value-details\n class=\"is-overflow-visible\"\n [data]=\"data\"\n [dataState]=\"dataState()\"\n [nodeType]=\"node['@type']\"\n [dataKey]=\"nodeKey()\" />\n</ng-template>\n", styles: ["fa-icon{display:inline-block;width:10px}he-data-table ::ng-deep .table thead tr th:nth-child(2),he-data-table ::ng-deep .table tbody tr td:nth-child(2){max-width:102px;width:102px}he-data-table ::ng-deep .table thead tr th:nth-child(3),he-data-table ::ng-deep .table tbody tr td:nth-child(3){min-width:110px}\n"], dependencies: [{ kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "component", type: SearchExtendComponent, selector: "he-search-extend", inputs: ["value", "disabled", "placeholder", "class"], outputs: ["valueChange", "search"] }, { kind: "component", type: DataTableComponent, selector: "he-data-table", inputs: ["minHeight", "maxHeight", "small"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "component", type: NodeLinkComponent, selector: "he-node-link", inputs: ["node", "showExternalLink", "linkClass"] }, { kind: "component", type: TermsUnitsDescriptionComponent, selector: "he-terms-units-description", inputs: ["term", "iconTemplate"] }, { kind: "directive", type: NgbPopover, selector: "[ngbPopover]", inputs: ["animation", "autoClose", "ngbPopover", "popoverTitle", "placement", "popperOptions", "triggers", "positionTarget", "container", "disablePopover", "popoverClass", "popoverContext", "openDelay", "closeDelay"], outputs: ["shown", "hidden"], exportAs: ["ngbPopover"] }, { kind: "component", type: BlankNodeStateComponent, selector: "he-blank-node-state", inputs: ["dataState", "nodeType", "dataKey", "key", "node", "state", "linkClass"] }, { kind: "component", type: BlankNodeStateNoticeComponent, selector: "he-blank-node-state-notice", inputs: ["dataState", "showDeleted"] }, { kind: "component", type: ImpactAssessmentsIndicatorsChartComponent, selector: "he-impact-assessments-indicators-chart", inputs: ["key", "filterTermTypes"] }, { kind: "component", type: ImpactAssessmentsIndicatorBreakdownChartComponent, selector: "he-impact-assessments-indicator-breakdown-chart", inputs: ["impactAssessment", "indicators"] }, { kind: "component", type: NodeLogsModelsComponent, selector: "he-node-logs-models", inputs: ["node", "nodeKey", "originalValues", "recalculatedValues", "terms", "filterTermTypes", "filterTermTypesLabel", "logsKey", "noDataMessage"] }, { kind: "component", type: NodeValueDetailsComponent, selector: "he-node-value-details", inputs: ["data", "nodeType", "dataState", "dataKey"] }, { kind: "pipe", type: CompoundPipe, name: "compound" }, { kind: "pipe", type: DefaultPipe, name: "default" }, { kind: "pipe", type: EllipsisPipe, name: "ellipsis" }, { kind: "pipe", type: PrecisionPipe, name: "precision" }, { kind: "pipe", type: KeyToLabelPipe, name: "keyToLabel" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
11255
11260
|
}
|
|
11256
11261
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.4", ngImport: i0, type: ImpactAssessmentsProductsComponent, decorators: [{
|
|
11257
11262
|
type: Component$1,
|
|
@@ -11274,7 +11279,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.4", ngImpor
|
|
|
11274
11279
|
EllipsisPipe,
|
|
11275
11280
|
PrecisionPipe,
|
|
11276
11281
|
KeyToLabelPipe
|
|
11277
|
-
], template: "<div class=\"columns is-variable is-align-items-center is-2 is-m-0\">\n <div class=\"column\">\n @if (hasData() && selectedView() === View.table) {\n <button class=\"button is-small is-ghost\" (click)=\"showDownload()\">\n <fa-icon [icon]=\"faDownload\" size=\"lg\" />\n </button>\n }\n </div>\n @if (selectedView() === View.table) {\n <div class=\"column is-narrow\">\n <he-search-extend\n class=\"is-secondary is-small\"\n placeholder=\"Filter terms by name\"\n (search)=\"filterTerm.set($event)\" />\n </div>\n }\n @if (views()?.length > 1) {\n <div class=\"column is-narrow\">\n <div class=\"field has-addons\">\n @for (view of views(); track view) {\n <div class=\"control\">\n <button\n class=\"button is-small\"\n [class.is-selected]=\"selectedView() === view\"\n (click)=\"selectedView.set(view)\">\n <span class=\"icon is-small\">\n <fa-icon [icon]=\"viewIcon[view]\" aria-hidden=\"true\" />\n </span>\n <span class=\"is-hidden-mobile\">{{ view }}</span>\n </button>\n </div>\n }\n </div>\n </div>\n }\n</div>\n\n@if (isNodeKeyAllowed()) {\n @switch (selectedView()) {\n @case (View.table) {\n <div class=\"is-px-3 is-pb-3\">\n @if (hasData()) {\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n @if (dataKeys().length > 1) {\n <tr class=\"has-text-weight-bold\">\n <th class=\"width-auto\"></th>\n <th></th>\n <th></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @if (data()[dataKey]?.length) {\n <th [attr.colspan]=\"data()[dataKey].length\" [class.has-border-right]=\"!dataKeyLast\">\n @if (dataKey) {\n <span>{{ dataKey | keyToLabel }}</span>\n }\n </th>\n }\n }\n </tr>\n }\n <tr class=\"has-text-weight-semibold\">\n <th class=\"width-auto has-border-right is-py-0\">\n @if (enableFilterMethodModel()) {\n <div class=\"select is-small\">\n <select (change)=\"updateSelectedMethodModel($event.target.value)\">\n <option [ngValue]=\"undefined\">Filter Model</option>\n @for (term of methodModels(); track term) {\n <option [ngValue]=\"term\">{{ term.name }}</option>\n }\n </select>\n </div>\n }\n </th>\n <th class=\"has-border-right\"></th>\n <th class=\"has-border-right\"></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.name\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <he-node-link [node]=\"node.value.term\">\n <span\n [innerHtml]=\"\n node.value.term.name | ellipsis: 30 | compound: node.value.term.termType\n \"></span>\n </he-node-link>\n </th>\n }\n }\n </tr>\n <tr class=\"is-italic has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n <th class=\"has-border-right\">\n <a [href]=\"schemaBaseUrl + '/ImpactAssessment#functionalUnit'\" target=\"_blank\">Functional unit</a>\n </th>\n <th class=\"has-border-right\">\n <a [href]=\"schemaBaseUrl + '/ImpactAssessment#product'\" target=\"_blank\">Product</a>\n </th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.units\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <span [innerHtml]=\"node.value.term.units | compound: node.value.term.termType\"></span>\n <he-terms-units-description class=\"is-inline-block is-ml-2\" [term]=\"node.value.term\" />\n </th>\n }\n }\n </tr>\n </thead>\n <tbody>\n @for (\n impactAssessment of impactAssessments();\n track trackById(impactIndex, impactAssessment);\n let impactIndex = $index\n ) {\n <tr>\n <td class=\"width-auto has-border-right\" [attr.title]=\"impactName(impactAssessment)\">\n <he-node-link [node]=\"impactAssessment\">\n <span>{{ impactIndex + 1 }}. {{ impactName(impactAssessment) }}</span>\n </he-node-link>\n </td>\n <td class=\"has-border-right\" [attr.title]=\"impactAssessment.product?.term?.units\">\n <span>1 {{ impactAssessment.product?.term?.units }}</span>\n </td>\n <td class=\"has-border-right\" [attr.title]=\"impactAssessment.product?.term?.name\">\n @if (impactAssessment.product?.term) {\n <he-node-link [node]=\"impactAssessment.product.term\">\n <span>{{ impactAssessment.product.term.name | ellipsis: 30 }}</span>\n </he-node-link>\n }\n </td>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <td\n class=\"is-nowrap\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n @if (node.value.values[impactAssessment['@id']]) {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"details\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow is-overflow-visible\"\n placement=\"left\"\n container=\"body\"\n [popoverContext]=\"{\n data: node.value.values[impactAssessment['@id']],\n impactAssessment\n }\">\n <span pointer>\n {{\n propertyValue(\n node.value.values[impactAssessment['@id']].value,\n node.value.term['@id']\n )\n | precision: 3\n | default: '-'\n }}\n </span>\n <he-blank-node-state\n class=\"ml-1\"\n [dataState]=\"dataState()\"\n [node]=\"node.value.values[impactAssessment['@id']].node\"\n key=\"value\"\n [state]=\"impactAssessment.aggregated ? 'aggregated' : undefined\" />\n </span>\n } @else {\n <span>-</span>\n }\n </td>\n }\n }\n </tr>\n }\n </tbody>\n </table>\n </he-data-table>\n <he-blank-node-state-notice [dataState]=\"dataState()\" />\n } @else {\n <div class=\"is-pt-3 has-text-centered\">\n <span>No data available</span>\n <span class=\"is-pl-1\" [class.is-hidden]=\"!filterTerm()\">matching your search criteria</span>\n <span>.</span>\n @if (showSwitchToRecalculated()) {\n <span>\n Switch to\n <code>recalculated</code>\n version.\n </span>\n }\n </div>\n }\n </div>\n }\n @case (View.chart) {\n <he-impact-assessments-indicators-chart [key]=\"nodeKey()\" [filterTermTypes]=\"filterTermTypes()\" />\n }\n @case (View.breakdown) {\n <he-impact-assessments-indicator-breakdown-chart\n [impactAssessment]=\"selectedNode()\"\n [indicators]=\"selectedRecalculatedValues()\" />\n }\n @case (View.logs) {\n @if (impactAssessments().length > 1) {\n <div class=\"field has-addons pt-2 px-3\">\n <div class=\"control\">\n <span class=\"button is-small is-static is-secondary\">Select an Impact Assessment</span>\n </div>\n <div class=\"control is-expanded\">\n <div class=\"select is-small is-fullwidth is-secondary\">\n <select (change)=\"selectIndex($event)\">\n @for (value of impactAssessments(); track value; let i = $index) {\n <option [value]=\"i\">{{ i + 1 }}. {{ impactName(value) }}</option>\n }\n </select>\n </div>\n </div>\n </div>\n }\n @if (selectedNode()) {\n <he-node-logs-models\n [node]=\"selectedNode()\"\n [nodeKey]=\"nodeKey()\"\n [filterTermTypes]=\"filterTermTypes()\"\n [originalValues]=\"selectedOriginalValues()\"\n [recalculatedValues]=\"selectedRecalculatedValues()\"\n [noDataMessage]=\"noDataMessage()\" />\n }\n }\n }\n}\n\n<ng-template #details let-node=\"impactAssessment\" let-data=\"data\">\n <p>\n <b>\n @if (data.cycle) {\n <span>{{ cycleLabel(node.cycle) }}</span>\n }\n @if (!data.cycle) {\n <span>{{ data.name }}</span>\n }\n </b>\n </p>\n <he-node-value-details\n class=\"is-overflow-visible\"\n [data]=\"data\"\n [dataState]=\"dataState()\"\n [nodeType]=\"node['@type']\"\n [dataKey]=\"nodeKey()\" />\n</ng-template>\n", styles: ["fa-icon{display:inline-block;width:10px}he-data-table ::ng-deep .table thead tr th:nth-child(2),he-data-table ::ng-deep .table tbody tr td:nth-child(2){max-width:102px;width:102px}he-data-table ::ng-deep .table thead tr th:nth-child(3),he-data-table ::ng-deep .table tbody tr td:nth-child(3){min-width:110px}\n"] }]
|
|
11282
|
+
], template: "<div class=\"columns is-variable is-align-items-center is-2 is-m-0\">\n <div class=\"column\">\n @if (hasData() && selectedView() === View.table) {\n <button class=\"button is-small is-ghost\" (click)=\"showDownload()\">\n <fa-icon [icon]=\"faDownload\" size=\"lg\" />\n </button>\n }\n </div>\n @if (selectedView() === View.table) {\n <div class=\"column is-narrow\">\n <he-search-extend\n class=\"is-secondary is-small\"\n placeholder=\"Filter terms by name\"\n (search)=\"filterTerm.set($event)\" />\n </div>\n }\n @if (views()?.length > 1) {\n <div class=\"column is-narrow\">\n <div class=\"field has-addons\">\n @for (view of views(); track view) {\n <div class=\"control\">\n <button\n class=\"button is-small\"\n [class.is-selected]=\"selectedView() === view\"\n (click)=\"selectedView.set(view)\">\n <span class=\"icon is-small\">\n <fa-icon [icon]=\"viewIcon[view]\" aria-hidden=\"true\" />\n </span>\n <span class=\"is-hidden-mobile\">{{ view }}</span>\n </button>\n </div>\n }\n </div>\n </div>\n }\n</div>\n\n@if (isNodeKeyAllowed()) {\n @switch (selectedView()) {\n @case (View.table) {\n <div class=\"is-px-3 is-pb-3\">\n @if (hasData()) {\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n @if (dataKeys().length > 1) {\n <tr class=\"has-text-weight-bold\">\n <th class=\"width-auto\"></th>\n <th></th>\n <th></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @if (data()[dataKey]?.length) {\n <th [attr.colspan]=\"data()[dataKey].length\" [class.has-border-right]=\"!dataKeyLast\">\n @if (dataKey) {\n <span>{{ dataKey | keyToLabel }}</span>\n }\n </th>\n }\n }\n </tr>\n }\n <tr class=\"has-text-weight-semibold\">\n <th class=\"width-auto has-border-right is-py-0\">\n @if (enableFilterMethodModel()) {\n <div class=\"select is-small\">\n <select (change)=\"updateSelectedMethodModel($event.target.value)\">\n <option [ngValue]=\"undefined\">Filter Model</option>\n @for (term of methodModels(); track term) {\n <option [ngValue]=\"term\">{{ term.name }}</option>\n }\n </select>\n </div>\n }\n </th>\n <th class=\"has-border-right\"></th>\n <th class=\"has-border-right\"></th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.name\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <he-node-link [node]=\"node.value.term\">\n <span\n [innerHtml]=\"\n node.value.term.name | ellipsis: 30 | compound: node.value.term.termType\n \"></span>\n </he-node-link>\n </th>\n }\n }\n </tr>\n <tr class=\"is-italic has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n <th class=\"has-border-right\">\n <a [href]=\"schemaBaseUrl + '/ImpactAssessment#functionalUnit'\" target=\"_blank\">Functional unit</a>\n </th>\n <th class=\"has-border-right\">\n <a [href]=\"schemaBaseUrl + '/ImpactAssessment#product'\" target=\"_blank\">Product</a>\n </th>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <th\n [attr.title]=\"node.value.term.units\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n <span [innerHtml]=\"node.value.term.units | compound: node.value.term.termType\"></span>\n <he-terms-units-description class=\"is-inline-block is-ml-2\" [term]=\"node.value.term\" />\n </th>\n }\n }\n </tr>\n </thead>\n <tbody>\n @for (\n impactAssessment of impactAssessments();\n track trackById(impactIndex, impactAssessment);\n let impactIndex = $index\n ) {\n <tr>\n <td class=\"width-auto has-border-right\" [attr.title]=\"impactName(impactAssessment)\">\n <he-node-link [node]=\"impactAssessment\">\n <span>{{ impactIndex + 1 }}. {{ impactName(impactAssessment) }}</span>\n </he-node-link>\n </td>\n <td class=\"has-border-right\" [attr.title]=\"impactAssessment.product?.term?.units\">\n <span>1 {{ impactAssessment.product?.term?.units }}</span>\n </td>\n <td class=\"has-border-right\" [attr.title]=\"impactAssessment.product?.term?.name\">\n @if (impactAssessment.product?.term) {\n <he-node-link [node]=\"impactAssessment.product.term\">\n <span>{{ impactAssessment.product.term.name | ellipsis: 30 }}</span>\n </he-node-link>\n }\n </td>\n @for (dataKey of dataKeys(); track dataKey; let dataKeyLast = $last) {\n @for (node of data()[dataKey]; track node.value.term.name; let nodeLast = $last) {\n <td\n class=\"is-nowrap\"\n [class.has-border-right]=\"dataKeys().length > 1 && !dataKeyLast && nodeLast\">\n @if (node.value.values[impactAssessment['@id']]) {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"details\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow is-overflow-visible\"\n placement=\"left bottom auto\"\n container=\"body\"\n [popoverContext]=\"{\n data: node.value.values[impactAssessment['@id']],\n impactAssessment\n }\">\n <span pointer>\n {{\n propertyValue(\n node.value.values[impactAssessment['@id']].value,\n node.value.term['@id']\n )\n | precision: 3\n | default: '-'\n }}\n </span>\n <he-blank-node-state\n class=\"ml-1\"\n [dataState]=\"dataState()\"\n [node]=\"node.value.values[impactAssessment['@id']].node\"\n key=\"value\"\n [state]=\"impactAssessment.aggregated ? 'aggregated' : undefined\" />\n </span>\n } @else {\n <span>-</span>\n }\n </td>\n }\n }\n </tr>\n }\n </tbody>\n </table>\n </he-data-table>\n <he-blank-node-state-notice [dataState]=\"dataState()\" />\n } @else {\n <div class=\"is-pt-3 has-text-centered\">\n <span>No data available</span>\n <span class=\"is-pl-1\" [class.is-hidden]=\"!filterTerm()\">matching your search criteria</span>\n <span>.</span>\n @if (showSwitchToRecalculated()) {\n <span>\n Switch to\n <code>recalculated</code>\n version.\n </span>\n }\n </div>\n }\n </div>\n }\n @case (View.chart) {\n <he-impact-assessments-indicators-chart [key]=\"nodeKey()\" [filterTermTypes]=\"filterTermTypes()\" />\n }\n @case (View.breakdown) {\n <he-impact-assessments-indicator-breakdown-chart\n [impactAssessment]=\"selectedNode()\"\n [indicators]=\"selectedRecalculatedValues()\" />\n }\n @case (View.logs) {\n @if (impactAssessments().length > 1) {\n <div class=\"field has-addons pt-2 px-3\">\n <div class=\"control\">\n <span class=\"button is-small is-static is-secondary\">Select an Impact Assessment</span>\n </div>\n <div class=\"control is-expanded\">\n <div class=\"select is-small is-fullwidth is-secondary\">\n <select (change)=\"selectIndex($event)\">\n @for (value of impactAssessments(); track value; let i = $index) {\n <option [value]=\"i\">{{ i + 1 }}. {{ impactName(value) }}</option>\n }\n </select>\n </div>\n </div>\n </div>\n }\n @if (selectedNode()) {\n <he-node-logs-models\n [node]=\"selectedNode()\"\n [nodeKey]=\"nodeKey()\"\n [filterTermTypes]=\"filterTermTypes()\"\n [originalValues]=\"selectedOriginalValues()\"\n [recalculatedValues]=\"selectedRecalculatedValues()\"\n [noDataMessage]=\"noDataMessage()\" />\n }\n }\n }\n}\n\n<ng-template #details let-node=\"impactAssessment\" let-data=\"data\">\n <p>\n <b>\n @if (data.cycle) {\n <span>{{ cycleLabel(node.cycle) }}</span>\n }\n @if (!data.cycle) {\n <span>{{ data.name }}</span>\n }\n </b>\n </p>\n <he-node-value-details\n class=\"is-overflow-visible\"\n [data]=\"data\"\n [dataState]=\"dataState()\"\n [nodeType]=\"node['@type']\"\n [dataKey]=\"nodeKey()\" />\n</ng-template>\n", styles: ["fa-icon{display:inline-block;width:10px}he-data-table ::ng-deep .table thead tr th:nth-child(2),he-data-table ::ng-deep .table tbody tr td:nth-child(2){max-width:102px;width:102px}he-data-table ::ng-deep .table thead tr th:nth-child(3),he-data-table ::ng-deep .table tbody tr td:nth-child(3){min-width:110px}\n"] }]
|
|
11278
11283
|
}], ctorParameters: () => [] });
|
|
11279
11284
|
|
|
11280
11285
|
const hasValidationError = (errors = [], level) => {
|
|
@@ -12356,7 +12361,7 @@ class SitesNodesComponent {
|
|
|
12356
12361
|
component.headerKeys.set(this.headerKeys());
|
|
12357
12362
|
}
|
|
12358
12363
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.4", ngImport: i0, type: SitesNodesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
12359
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.4", type: SitesNodesComponent, isStandalone: true, selector: "he-sites-nodes", inputs: { dataState: { classPropertyName: "dataState", publicName: "dataState", isSignal: true, isRequired: false, transformFunction: null }, nodeKey: { classPropertyName: "nodeKey", publicName: "nodeKey", isSignal: true, isRequired: false, transformFunction: null }, enableChart: { classPropertyName: "enableChart", publicName: "enableChart", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"columns is-variable is-align-items-center is-2 is-m-0\">\n <div class=\"column\">\n @if (hasData() && selectedView() === View.table) {\n <button class=\"button is-small is-ghost\" (click)=\"showDownload()\">\n <fa-icon [icon]=\"faDownload\" size=\"lg\" />\n </button>\n }\n </div>\n @if (selectedView() === View.table) {\n <div class=\"column is-narrow\">\n <he-search-extend\n class=\"is-secondary is-small\"\n placeholder=\"Filter terms by name\"\n (search)=\"filterTerm.set($event)\" />\n </div>\n }\n @if (views()?.length > 1) {\n <div class=\"column is-narrow\">\n <div class=\"field has-addons\">\n @for (view of views(); track view) {\n <div class=\"control\">\n <button\n class=\"button is-small\"\n [class.is-selected]=\"selectedView() === view\"\n (click)=\"selectedView.set(view)\">\n <span class=\"icon is-small\">\n <fa-icon [icon]=\"viewIcon[view]\" aria-hidden=\"true\" />\n </span>\n <span class=\"is-hidden-mobile\">{{ view }}</span>\n </button>\n </div>\n }\n </div>\n </div>\n }\n</div>\n\n@if (isNodeKeyAllowed()) {\n @switch (selectedView()) {\n @case (View.table) {\n <div class=\"is-px-3 is-pb-3\">\n @if (hasData()) {\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n <tr class=\"has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n @for (node of data(); track node.value.term.name) {\n <th [attr.title]=\"node.value.term.name\">\n <he-node-link [node]=\"node.value.term\">\n <span\n [innerHtml]=\"node.value.term.name | ellipsis: 30 | compound: node.value.term.termType\"></span>\n </he-node-link>\n </th>\n }\n </tr>\n <tr class=\"is-italic has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n @for (node of data(); track node.value.term.name) {\n <th [attr.title]=\"node.value.term.units\">\n <span [innerHtml]=\"node.value.term.units | compound: node.value.term.termType\"></span>\n <he-terms-units-description class=\"is-inline-block is-ml-2\" [term]=\"node.value.term\" />\n </th>\n }\n </tr>\n </thead>\n <tbody>\n @for (site of sites(); track trackById(siteIndex, site); let siteIndex = $index) {\n <tr>\n <td class=\"width-auto has-border-right\" [attr.title]=\"defaultLabel(site)\">\n <he-node-link [node]=\"site\">\n <span>{{ siteIndex + 1 }}. {{ defaultLabel(site) }}</span>\n </he-node-link>\n </td>\n @for (node of data(); track node.value.term.name) {\n <td class=\"is-nowrap\">\n @if (node.value.values[site['@id']]) {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"details\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow is-overflow-visible\"\n placement=\"left\"\n container=\"body\"\n [popoverContext]=\"{ data: node.value.values[site['@id']], site }\">\n @if (isMeasurement()) {\n <span pointer>\n {{\n measurementValue($any(node).value.values[site['@id']], node.value.term['@id'])\n | precision: 3\n | default: '-'\n }}\n </span>\n } @else {\n <span pointer>\n {{\n propertyValue(node.value.values[site['@id']].value, node.value.term['@id'])\n | precision: 3\n | default: '-'\n }}\n </span>\n }\n <he-blank-node-state\n class=\"ml-1\"\n [dataState]=\"dataState()\"\n [node]=\"node.value.values[site['@id']].node\"\n key=\"value\" />\n </span>\n }\n @if (isMeasurement() && !node.value.values[site['@id']]) {\n <span>\n <span>-</span>\n @if (siteTooBig(site)) {\n <sup class=\"pl-1\">(1)</sup>\n }\n </span>\n }\n </td>\n }\n </tr>\n }\n </tbody>\n </table>\n </he-data-table>\n <he-blank-node-state-notice [dataState]=\"dataState()\" />\n @if (showAreaTooBig()) {\n <p class=\"is-size-7 is-italic\">\n (1) This region is >{{ maxAreaSize }}km2 and is too large to reliably gap fill Measurements.\n </p>\n }\n } @else {\n <div class=\"is-pt-3 has-text-centered\">\n <span>No data available</span>\n <span class=\"is-pl-1\" [class.is-hidden]=\"!filterTerm()\">matching your search criteria</span>\n <span>.</span>\n @if (showSwitchToRecalculated()) {\n <span>\n Switch to\n <code>recalculated</code>\n version.\n </span>\n }\n </div>\n }\n </div>\n }\n @case (View.chart) {\n @if (nodeKey() === BlankNodesKey.management) {\n <ng-container *ngTemplateOutlet=\"selectSite\" />\n @if (selectedNode()) {\n <div class=\"is-px-3 is-pb-3\">\n <he-sites-management-chart [site]=\"selectedNode()\" />\n </div>\n }\n }\n }\n @case (View.logs) {\n <ng-container *ngTemplateOutlet=\"selectSite\" />\n @if (selectedNode()) {\n <he-node-logs-models\n [node]=\"selectedNode()\"\n [nodeKey]=\"nodeKey()\"\n [originalValues]=\"selectedOriginalValues()\"\n [recalculatedValues]=\"selectedRecalculatedValues()\"\n [filterTermTypes]=\"filterTermTypes()\"\n [filterTermTypesLabel]=\"nodeKey() | capitalize\" />\n }\n }\n }\n}\n\n<ng-template #emptyValue>\n <span>-</span>\n</ng-template>\n\n<ng-template #details let-node=\"site\" let-data=\"data\">\n <p>\n <b>{{ node.name }}</b>\n </p>\n <he-node-value-details\n class=\"is-overflow-visible\"\n [data]=\"data\"\n [dataState]=\"dataState()\"\n [nodeType]=\"node['@type']\"\n [dataKey]=\"nodeKey()\" />\n</ng-template>\n\n<ng-template #selectSite>\n @if (sites().length > 1) {\n <div class=\"field has-addons pt-2 px-3\">\n <div class=\"control\">\n <span class=\"button is-small is-static is-secondary\">Select a Site</span>\n </div>\n <div class=\"control is-expanded\">\n <div class=\"select is-small is-fullwidth is-secondary\">\n <select (change)=\"selectIndex($event)\">\n @for (value of sites(); track value; let siteIndex = $index) {\n <option [value]=\"siteIndex\">{{ siteIndex + 1 }}. {{ defaultLabel(value) }}</option>\n }\n </select>\n </div>\n </div>\n </div>\n }\n</ng-template>\n", styles: ["fa-icon{display:inline-block;width:10px}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "component", type: SearchExtendComponent, selector: "he-search-extend", inputs: ["value", "disabled", "placeholder", "class"], outputs: ["valueChange", "search"] }, { kind: "component", type: DataTableComponent, selector: "he-data-table", inputs: ["minHeight", "maxHeight", "small"] }, { kind: "component", type: NodeLinkComponent, selector: "he-node-link", inputs: ["node", "showExternalLink", "linkClass"] }, { kind: "component", type: TermsUnitsDescriptionComponent, selector: "he-terms-units-description", inputs: ["term", "iconTemplate"] }, { kind: "directive", type: NgbPopover, selector: "[ngbPopover]", inputs: ["animation", "autoClose", "ngbPopover", "popoverTitle", "placement", "popperOptions", "triggers", "positionTarget", "container", "disablePopover", "popoverClass", "popoverContext", "openDelay", "closeDelay"], outputs: ["shown", "hidden"], exportAs: ["ngbPopover"] }, { kind: "component", type: BlankNodeStateComponent, selector: "he-blank-node-state", inputs: ["dataState", "nodeType", "dataKey", "key", "node", "state", "linkClass"] }, { kind: "component", type: BlankNodeStateNoticeComponent, selector: "he-blank-node-state-notice", inputs: ["dataState", "showDeleted"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "component", type: NodeLogsModelsComponent, selector: "he-node-logs-models", inputs: ["node", "nodeKey", "originalValues", "recalculatedValues", "terms", "filterTermTypes", "filterTermTypesLabel", "logsKey", "noDataMessage"] }, { kind: "component", type: NodeValueDetailsComponent, selector: "he-node-value-details", inputs: ["data", "nodeType", "dataState", "dataKey"] }, { kind: "pipe", type: CompoundPipe, name: "compound" }, { kind: "pipe", type: DefaultPipe, name: "default" }, { kind: "pipe", type: EllipsisPipe, name: "ellipsis" }, { kind: "pipe", type: PrecisionPipe, name: "precision" }, { kind: "pipe", type: CapitalizePipe, name: "capitalize" }, { kind: "component", type: SitesManagementChartComponent, selector: "he-sites-management-chart", inputs: ["site"] }] }); }
|
|
12364
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.4", type: SitesNodesComponent, isStandalone: true, selector: "he-sites-nodes", inputs: { dataState: { classPropertyName: "dataState", publicName: "dataState", isSignal: true, isRequired: false, transformFunction: null }, nodeKey: { classPropertyName: "nodeKey", publicName: "nodeKey", isSignal: true, isRequired: false, transformFunction: null }, enableChart: { classPropertyName: "enableChart", publicName: "enableChart", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"columns is-variable is-align-items-center is-2 is-m-0\">\n <div class=\"column\">\n @if (hasData() && selectedView() === View.table) {\n <button class=\"button is-small is-ghost\" (click)=\"showDownload()\">\n <fa-icon [icon]=\"faDownload\" size=\"lg\" />\n </button>\n }\n </div>\n @if (selectedView() === View.table) {\n <div class=\"column is-narrow\">\n <he-search-extend\n class=\"is-secondary is-small\"\n placeholder=\"Filter terms by name\"\n (search)=\"filterTerm.set($event)\" />\n </div>\n }\n @if (views()?.length > 1) {\n <div class=\"column is-narrow\">\n <div class=\"field has-addons\">\n @for (view of views(); track view) {\n <div class=\"control\">\n <button\n class=\"button is-small\"\n [class.is-selected]=\"selectedView() === view\"\n (click)=\"selectedView.set(view)\">\n <span class=\"icon is-small\">\n <fa-icon [icon]=\"viewIcon[view]\" aria-hidden=\"true\" />\n </span>\n <span class=\"is-hidden-mobile\">{{ view }}</span>\n </button>\n </div>\n }\n </div>\n </div>\n }\n</div>\n\n@if (isNodeKeyAllowed()) {\n @switch (selectedView()) {\n @case (View.table) {\n <div class=\"is-px-3 is-pb-3\">\n @if (hasData()) {\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n <tr class=\"has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n @for (node of data(); track node.value.term.name) {\n <th [attr.title]=\"node.value.term.name\">\n <he-node-link [node]=\"node.value.term\">\n <span\n [innerHtml]=\"node.value.term.name | ellipsis: 30 | compound: node.value.term.termType\"></span>\n </he-node-link>\n </th>\n }\n </tr>\n <tr class=\"is-italic has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n @for (node of data(); track node.value.term.name) {\n <th [attr.title]=\"node.value.term.units\">\n <span [innerHtml]=\"node.value.term.units | compound: node.value.term.termType\"></span>\n <he-terms-units-description class=\"is-inline-block is-ml-2\" [term]=\"node.value.term\" />\n </th>\n }\n </tr>\n </thead>\n <tbody>\n @for (site of sites(); track trackById(siteIndex, site); let siteIndex = $index) {\n <tr>\n <td class=\"width-auto has-border-right\" [attr.title]=\"defaultLabel(site)\">\n <he-node-link [node]=\"site\">\n <span>{{ siteIndex + 1 }}. {{ defaultLabel(site) }}</span>\n </he-node-link>\n </td>\n @for (node of data(); track node.value.term.name) {\n <td class=\"is-nowrap\">\n @if (node.value.values[site['@id']]) {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"details\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow is-overflow-visible\"\n placement=\"left bottom auto\"\n container=\"body\"\n [popoverContext]=\"{ data: node.value.values[site['@id']], site }\">\n @if (isMeasurement()) {\n <span pointer>\n {{\n measurementValue($any(node).value.values[site['@id']], node.value.term['@id'])\n | precision: 3\n | default: '-'\n }}\n </span>\n } @else {\n <span pointer>\n {{\n propertyValue(node.value.values[site['@id']].value, node.value.term['@id'])\n | precision: 3\n | default: '-'\n }}\n </span>\n }\n <he-blank-node-state\n class=\"ml-1\"\n [dataState]=\"dataState()\"\n [node]=\"node.value.values[site['@id']].node\"\n key=\"value\" />\n </span>\n }\n @if (isMeasurement() && !node.value.values[site['@id']]) {\n <span>\n <span>-</span>\n @if (siteTooBig(site)) {\n <sup class=\"pl-1\">(1)</sup>\n }\n </span>\n }\n </td>\n }\n </tr>\n }\n </tbody>\n </table>\n </he-data-table>\n <he-blank-node-state-notice [dataState]=\"dataState()\" />\n @if (showAreaTooBig()) {\n <p class=\"is-size-7 is-italic\">\n (1) This region is >{{ maxAreaSize }}km2 and is too large to reliably gap fill Measurements.\n </p>\n }\n } @else {\n <div class=\"is-pt-3 has-text-centered\">\n <span>No data available</span>\n <span class=\"is-pl-1\" [class.is-hidden]=\"!filterTerm()\">matching your search criteria</span>\n <span>.</span>\n @if (showSwitchToRecalculated()) {\n <span>\n Switch to\n <code>recalculated</code>\n version.\n </span>\n }\n </div>\n }\n </div>\n }\n @case (View.chart) {\n @if (nodeKey() === BlankNodesKey.management) {\n <ng-container *ngTemplateOutlet=\"selectSite\" />\n @if (selectedNode()) {\n <div class=\"is-px-3 is-pb-3\">\n <he-sites-management-chart [site]=\"selectedNode()\" />\n </div>\n }\n }\n }\n @case (View.logs) {\n <ng-container *ngTemplateOutlet=\"selectSite\" />\n @if (selectedNode()) {\n <he-node-logs-models\n [node]=\"selectedNode()\"\n [nodeKey]=\"nodeKey()\"\n [originalValues]=\"selectedOriginalValues()\"\n [recalculatedValues]=\"selectedRecalculatedValues()\"\n [filterTermTypes]=\"filterTermTypes()\"\n [filterTermTypesLabel]=\"nodeKey() | capitalize\" />\n }\n }\n }\n}\n\n<ng-template #emptyValue>\n <span>-</span>\n</ng-template>\n\n<ng-template #details let-node=\"site\" let-data=\"data\">\n <p>\n <b>{{ node.name }}</b>\n </p>\n <he-node-value-details\n class=\"is-overflow-visible\"\n [data]=\"data\"\n [dataState]=\"dataState()\"\n [nodeType]=\"node['@type']\"\n [dataKey]=\"nodeKey()\" />\n</ng-template>\n\n<ng-template #selectSite>\n @if (sites().length > 1) {\n <div class=\"field has-addons pt-2 px-3\">\n <div class=\"control\">\n <span class=\"button is-small is-static is-secondary\">Select a Site</span>\n </div>\n <div class=\"control is-expanded\">\n <div class=\"select is-small is-fullwidth is-secondary\">\n <select (change)=\"selectIndex($event)\">\n @for (value of sites(); track value; let siteIndex = $index) {\n <option [value]=\"siteIndex\">{{ siteIndex + 1 }}. {{ defaultLabel(value) }}</option>\n }\n </select>\n </div>\n </div>\n </div>\n }\n</ng-template>\n", styles: ["fa-icon{display:inline-block;width:10px}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: FaIconComponent, selector: "fa-icon", inputs: ["icon", "title", "animation", "mask", "flip", "size", "pull", "border", "inverse", "symbol", "rotate", "fixedWidth", "transform", "a11yRole"] }, { kind: "component", type: SearchExtendComponent, selector: "he-search-extend", inputs: ["value", "disabled", "placeholder", "class"], outputs: ["valueChange", "search"] }, { kind: "component", type: DataTableComponent, selector: "he-data-table", inputs: ["minHeight", "maxHeight", "small"] }, { kind: "component", type: NodeLinkComponent, selector: "he-node-link", inputs: ["node", "showExternalLink", "linkClass"] }, { kind: "component", type: TermsUnitsDescriptionComponent, selector: "he-terms-units-description", inputs: ["term", "iconTemplate"] }, { kind: "directive", type: NgbPopover, selector: "[ngbPopover]", inputs: ["animation", "autoClose", "ngbPopover", "popoverTitle", "placement", "popperOptions", "triggers", "positionTarget", "container", "disablePopover", "popoverClass", "popoverContext", "openDelay", "closeDelay"], outputs: ["shown", "hidden"], exportAs: ["ngbPopover"] }, { kind: "component", type: BlankNodeStateComponent, selector: "he-blank-node-state", inputs: ["dataState", "nodeType", "dataKey", "key", "node", "state", "linkClass"] }, { kind: "component", type: BlankNodeStateNoticeComponent, selector: "he-blank-node-state-notice", inputs: ["dataState", "showDeleted"] }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i1.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "component", type: NodeLogsModelsComponent, selector: "he-node-logs-models", inputs: ["node", "nodeKey", "originalValues", "recalculatedValues", "terms", "filterTermTypes", "filterTermTypesLabel", "logsKey", "noDataMessage"] }, { kind: "component", type: NodeValueDetailsComponent, selector: "he-node-value-details", inputs: ["data", "nodeType", "dataState", "dataKey"] }, { kind: "pipe", type: CompoundPipe, name: "compound" }, { kind: "pipe", type: DefaultPipe, name: "default" }, { kind: "pipe", type: EllipsisPipe, name: "ellipsis" }, { kind: "pipe", type: PrecisionPipe, name: "precision" }, { kind: "pipe", type: CapitalizePipe, name: "capitalize" }, { kind: "component", type: SitesManagementChartComponent, selector: "he-sites-management-chart", inputs: ["site"] }] }); }
|
|
12360
12365
|
}
|
|
12361
12366
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.4", ngImport: i0, type: SitesNodesComponent, decorators: [{
|
|
12362
12367
|
type: Component$1,
|
|
@@ -12379,7 +12384,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.4", ngImpor
|
|
|
12379
12384
|
PrecisionPipe,
|
|
12380
12385
|
CapitalizePipe,
|
|
12381
12386
|
SitesManagementChartComponent
|
|
12382
|
-
], template: "<div class=\"columns is-variable is-align-items-center is-2 is-m-0\">\n <div class=\"column\">\n @if (hasData() && selectedView() === View.table) {\n <button class=\"button is-small is-ghost\" (click)=\"showDownload()\">\n <fa-icon [icon]=\"faDownload\" size=\"lg\" />\n </button>\n }\n </div>\n @if (selectedView() === View.table) {\n <div class=\"column is-narrow\">\n <he-search-extend\n class=\"is-secondary is-small\"\n placeholder=\"Filter terms by name\"\n (search)=\"filterTerm.set($event)\" />\n </div>\n }\n @if (views()?.length > 1) {\n <div class=\"column is-narrow\">\n <div class=\"field has-addons\">\n @for (view of views(); track view) {\n <div class=\"control\">\n <button\n class=\"button is-small\"\n [class.is-selected]=\"selectedView() === view\"\n (click)=\"selectedView.set(view)\">\n <span class=\"icon is-small\">\n <fa-icon [icon]=\"viewIcon[view]\" aria-hidden=\"true\" />\n </span>\n <span class=\"is-hidden-mobile\">{{ view }}</span>\n </button>\n </div>\n }\n </div>\n </div>\n }\n</div>\n\n@if (isNodeKeyAllowed()) {\n @switch (selectedView()) {\n @case (View.table) {\n <div class=\"is-px-3 is-pb-3\">\n @if (hasData()) {\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n <tr class=\"has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n @for (node of data(); track node.value.term.name) {\n <th [attr.title]=\"node.value.term.name\">\n <he-node-link [node]=\"node.value.term\">\n <span\n [innerHtml]=\"node.value.term.name | ellipsis: 30 | compound: node.value.term.termType\"></span>\n </he-node-link>\n </th>\n }\n </tr>\n <tr class=\"is-italic has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n @for (node of data(); track node.value.term.name) {\n <th [attr.title]=\"node.value.term.units\">\n <span [innerHtml]=\"node.value.term.units | compound: node.value.term.termType\"></span>\n <he-terms-units-description class=\"is-inline-block is-ml-2\" [term]=\"node.value.term\" />\n </th>\n }\n </tr>\n </thead>\n <tbody>\n @for (site of sites(); track trackById(siteIndex, site); let siteIndex = $index) {\n <tr>\n <td class=\"width-auto has-border-right\" [attr.title]=\"defaultLabel(site)\">\n <he-node-link [node]=\"site\">\n <span>{{ siteIndex + 1 }}. {{ defaultLabel(site) }}</span>\n </he-node-link>\n </td>\n @for (node of data(); track node.value.term.name) {\n <td class=\"is-nowrap\">\n @if (node.value.values[site['@id']]) {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"details\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow is-overflow-visible\"\n placement=\"left\"\n container=\"body\"\n [popoverContext]=\"{ data: node.value.values[site['@id']], site }\">\n @if (isMeasurement()) {\n <span pointer>\n {{\n measurementValue($any(node).value.values[site['@id']], node.value.term['@id'])\n | precision: 3\n | default: '-'\n }}\n </span>\n } @else {\n <span pointer>\n {{\n propertyValue(node.value.values[site['@id']].value, node.value.term['@id'])\n | precision: 3\n | default: '-'\n }}\n </span>\n }\n <he-blank-node-state\n class=\"ml-1\"\n [dataState]=\"dataState()\"\n [node]=\"node.value.values[site['@id']].node\"\n key=\"value\" />\n </span>\n }\n @if (isMeasurement() && !node.value.values[site['@id']]) {\n <span>\n <span>-</span>\n @if (siteTooBig(site)) {\n <sup class=\"pl-1\">(1)</sup>\n }\n </span>\n }\n </td>\n }\n </tr>\n }\n </tbody>\n </table>\n </he-data-table>\n <he-blank-node-state-notice [dataState]=\"dataState()\" />\n @if (showAreaTooBig()) {\n <p class=\"is-size-7 is-italic\">\n (1) This region is >{{ maxAreaSize }}km2 and is too large to reliably gap fill Measurements.\n </p>\n }\n } @else {\n <div class=\"is-pt-3 has-text-centered\">\n <span>No data available</span>\n <span class=\"is-pl-1\" [class.is-hidden]=\"!filterTerm()\">matching your search criteria</span>\n <span>.</span>\n @if (showSwitchToRecalculated()) {\n <span>\n Switch to\n <code>recalculated</code>\n version.\n </span>\n }\n </div>\n }\n </div>\n }\n @case (View.chart) {\n @if (nodeKey() === BlankNodesKey.management) {\n <ng-container *ngTemplateOutlet=\"selectSite\" />\n @if (selectedNode()) {\n <div class=\"is-px-3 is-pb-3\">\n <he-sites-management-chart [site]=\"selectedNode()\" />\n </div>\n }\n }\n }\n @case (View.logs) {\n <ng-container *ngTemplateOutlet=\"selectSite\" />\n @if (selectedNode()) {\n <he-node-logs-models\n [node]=\"selectedNode()\"\n [nodeKey]=\"nodeKey()\"\n [originalValues]=\"selectedOriginalValues()\"\n [recalculatedValues]=\"selectedRecalculatedValues()\"\n [filterTermTypes]=\"filterTermTypes()\"\n [filterTermTypesLabel]=\"nodeKey() | capitalize\" />\n }\n }\n }\n}\n\n<ng-template #emptyValue>\n <span>-</span>\n</ng-template>\n\n<ng-template #details let-node=\"site\" let-data=\"data\">\n <p>\n <b>{{ node.name }}</b>\n </p>\n <he-node-value-details\n class=\"is-overflow-visible\"\n [data]=\"data\"\n [dataState]=\"dataState()\"\n [nodeType]=\"node['@type']\"\n [dataKey]=\"nodeKey()\" />\n</ng-template>\n\n<ng-template #selectSite>\n @if (sites().length > 1) {\n <div class=\"field has-addons pt-2 px-3\">\n <div class=\"control\">\n <span class=\"button is-small is-static is-secondary\">Select a Site</span>\n </div>\n <div class=\"control is-expanded\">\n <div class=\"select is-small is-fullwidth is-secondary\">\n <select (change)=\"selectIndex($event)\">\n @for (value of sites(); track value; let siteIndex = $index) {\n <option [value]=\"siteIndex\">{{ siteIndex + 1 }}. {{ defaultLabel(value) }}</option>\n }\n </select>\n </div>\n </div>\n </div>\n }\n</ng-template>\n", styles: ["fa-icon{display:inline-block;width:10px}\n"] }]
|
|
12387
|
+
], template: "<div class=\"columns is-variable is-align-items-center is-2 is-m-0\">\n <div class=\"column\">\n @if (hasData() && selectedView() === View.table) {\n <button class=\"button is-small is-ghost\" (click)=\"showDownload()\">\n <fa-icon [icon]=\"faDownload\" size=\"lg\" />\n </button>\n }\n </div>\n @if (selectedView() === View.table) {\n <div class=\"column is-narrow\">\n <he-search-extend\n class=\"is-secondary is-small\"\n placeholder=\"Filter terms by name\"\n (search)=\"filterTerm.set($event)\" />\n </div>\n }\n @if (views()?.length > 1) {\n <div class=\"column is-narrow\">\n <div class=\"field has-addons\">\n @for (view of views(); track view) {\n <div class=\"control\">\n <button\n class=\"button is-small\"\n [class.is-selected]=\"selectedView() === view\"\n (click)=\"selectedView.set(view)\">\n <span class=\"icon is-small\">\n <fa-icon [icon]=\"viewIcon[view]\" aria-hidden=\"true\" />\n </span>\n <span class=\"is-hidden-mobile\">{{ view }}</span>\n </button>\n </div>\n }\n </div>\n </div>\n }\n</div>\n\n@if (isNodeKeyAllowed()) {\n @switch (selectedView()) {\n @case (View.table) {\n <div class=\"is-px-3 is-pb-3\">\n @if (hasData()) {\n <he-data-table class=\"mb-1 is-small\" [small]=\"true\" maxHeight=\"320\">\n <table class=\"table is-fullwidth is-narrow is-striped\">\n <thead>\n <tr class=\"has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n @for (node of data(); track node.value.term.name) {\n <th [attr.title]=\"node.value.term.name\">\n <he-node-link [node]=\"node.value.term\">\n <span\n [innerHtml]=\"node.value.term.name | ellipsis: 30 | compound: node.value.term.termType\"></span>\n </he-node-link>\n </th>\n }\n </tr>\n <tr class=\"is-italic has-text-weight-semibold\">\n <th class=\"width-auto has-border-right\"></th>\n @for (node of data(); track node.value.term.name) {\n <th [attr.title]=\"node.value.term.units\">\n <span [innerHtml]=\"node.value.term.units | compound: node.value.term.termType\"></span>\n <he-terms-units-description class=\"is-inline-block is-ml-2\" [term]=\"node.value.term\" />\n </th>\n }\n </tr>\n </thead>\n <tbody>\n @for (site of sites(); track trackById(siteIndex, site); let siteIndex = $index) {\n <tr>\n <td class=\"width-auto has-border-right\" [attr.title]=\"defaultLabel(site)\">\n <he-node-link [node]=\"site\">\n <span>{{ siteIndex + 1 }}. {{ defaultLabel(site) }}</span>\n </he-node-link>\n </td>\n @for (node of data(); track node.value.term.name) {\n <td class=\"is-nowrap\">\n @if (node.value.values[site['@id']]) {\n <span\n class=\"trigger-popover\"\n [ngbPopover]=\"details\"\n autoClose=\"outside\"\n popoverClass=\"is-narrow is-overflow-visible\"\n placement=\"left bottom auto\"\n container=\"body\"\n [popoverContext]=\"{ data: node.value.values[site['@id']], site }\">\n @if (isMeasurement()) {\n <span pointer>\n {{\n measurementValue($any(node).value.values[site['@id']], node.value.term['@id'])\n | precision: 3\n | default: '-'\n }}\n </span>\n } @else {\n <span pointer>\n {{\n propertyValue(node.value.values[site['@id']].value, node.value.term['@id'])\n | precision: 3\n | default: '-'\n }}\n </span>\n }\n <he-blank-node-state\n class=\"ml-1\"\n [dataState]=\"dataState()\"\n [node]=\"node.value.values[site['@id']].node\"\n key=\"value\" />\n </span>\n }\n @if (isMeasurement() && !node.value.values[site['@id']]) {\n <span>\n <span>-</span>\n @if (siteTooBig(site)) {\n <sup class=\"pl-1\">(1)</sup>\n }\n </span>\n }\n </td>\n }\n </tr>\n }\n </tbody>\n </table>\n </he-data-table>\n <he-blank-node-state-notice [dataState]=\"dataState()\" />\n @if (showAreaTooBig()) {\n <p class=\"is-size-7 is-italic\">\n (1) This region is >{{ maxAreaSize }}km2 and is too large to reliably gap fill Measurements.\n </p>\n }\n } @else {\n <div class=\"is-pt-3 has-text-centered\">\n <span>No data available</span>\n <span class=\"is-pl-1\" [class.is-hidden]=\"!filterTerm()\">matching your search criteria</span>\n <span>.</span>\n @if (showSwitchToRecalculated()) {\n <span>\n Switch to\n <code>recalculated</code>\n version.\n </span>\n }\n </div>\n }\n </div>\n }\n @case (View.chart) {\n @if (nodeKey() === BlankNodesKey.management) {\n <ng-container *ngTemplateOutlet=\"selectSite\" />\n @if (selectedNode()) {\n <div class=\"is-px-3 is-pb-3\">\n <he-sites-management-chart [site]=\"selectedNode()\" />\n </div>\n }\n }\n }\n @case (View.logs) {\n <ng-container *ngTemplateOutlet=\"selectSite\" />\n @if (selectedNode()) {\n <he-node-logs-models\n [node]=\"selectedNode()\"\n [nodeKey]=\"nodeKey()\"\n [originalValues]=\"selectedOriginalValues()\"\n [recalculatedValues]=\"selectedRecalculatedValues()\"\n [filterTermTypes]=\"filterTermTypes()\"\n [filterTermTypesLabel]=\"nodeKey() | capitalize\" />\n }\n }\n }\n}\n\n<ng-template #emptyValue>\n <span>-</span>\n</ng-template>\n\n<ng-template #details let-node=\"site\" let-data=\"data\">\n <p>\n <b>{{ node.name }}</b>\n </p>\n <he-node-value-details\n class=\"is-overflow-visible\"\n [data]=\"data\"\n [dataState]=\"dataState()\"\n [nodeType]=\"node['@type']\"\n [dataKey]=\"nodeKey()\" />\n</ng-template>\n\n<ng-template #selectSite>\n @if (sites().length > 1) {\n <div class=\"field has-addons pt-2 px-3\">\n <div class=\"control\">\n <span class=\"button is-small is-static is-secondary\">Select a Site</span>\n </div>\n <div class=\"control is-expanded\">\n <div class=\"select is-small is-fullwidth is-secondary\">\n <select (change)=\"selectIndex($event)\">\n @for (value of sites(); track value; let siteIndex = $index) {\n <option [value]=\"siteIndex\">{{ siteIndex + 1 }}. {{ defaultLabel(value) }}</option>\n }\n </select>\n </div>\n </div>\n </div>\n }\n</ng-template>\n", styles: ["fa-icon{display:inline-block;width:10px}\n"] }]
|
|
12383
12388
|
}], ctorParameters: () => [] });
|
|
12384
12389
|
|
|
12385
12390
|
class TermsPropertyContentComponent {
|