@akcelik/strct 4.13.0 → 4.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/akcelik-strct.mjs +224 -41
- package/fesm2022/akcelik-strct.mjs.map +1 -1
- package/package.json +1 -1
- package/types/akcelik-strct.d.ts +81 -6
|
@@ -18021,6 +18021,22 @@ class StrctMetricTile {
|
|
|
18021
18021
|
/** Tints the value (defaults to neutral primary text). */
|
|
18022
18022
|
status = input('neutral', /* @ts-ignore */
|
|
18023
18023
|
...(ngDevMode ? [{ debugName: "status" }] : /* istanbul ignore next */ []));
|
|
18024
|
+
/**
|
|
18025
|
+
* Tints the caption instead of the value — "2 down" is the warning, and the
|
|
18026
|
+
* 14 nodes above it are not. `null` keeps the caption muted.
|
|
18027
|
+
*/
|
|
18028
|
+
captionStatus = input(null, /* @ts-ignore */
|
|
18029
|
+
...(ngDevMode ? [{ debugName: "captionStatus" }] : /* istanbul ignore next */ []));
|
|
18030
|
+
/** Renders the tile as a link: the whole tile is the target. */
|
|
18031
|
+
href = input(null, /* @ts-ignore */
|
|
18032
|
+
...(ngDevMode ? [{ debugName: "href" }] : /* istanbul ignore next */ []));
|
|
18033
|
+
/** Makes the whole tile a control that emits `activated`. */
|
|
18034
|
+
interactive = input(false, { ...(ngDevMode ? { debugName: "interactive" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
18035
|
+
/** Emitted when an `interactive` tile is activated. */
|
|
18036
|
+
activated = output();
|
|
18037
|
+
/** The link / button's name: the KPI and its value, since the tile is the target. */
|
|
18038
|
+
hitLabel = computed(() => [this.label(), `${this.value()}${this.unit()}`].filter(Boolean).join(': '), /* @ts-ignore */
|
|
18039
|
+
...(ngDevMode ? [{ debugName: "hitLabel" }] : /* istanbul ignore next */ []));
|
|
18024
18040
|
/** Change indicator; sign drives the arrow + colour. Null hides it. */
|
|
18025
18041
|
delta = input(null, /* @ts-ignore */
|
|
18026
18042
|
...(ngDevMode ? [{ debugName: "delta" }] : /* istanbul ignore next */ []));
|
|
@@ -18072,7 +18088,7 @@ class StrctMetricTile {
|
|
|
18072
18088
|
}, /* @ts-ignore */
|
|
18073
18089
|
...(ngDevMode ? [{ debugName: "sparkStatus" }] : /* istanbul ignore next */ []));
|
|
18074
18090
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: StrctMetricTile, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
18075
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: StrctMetricTile, isStandalone: true, selector: "strct-metric-tile", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: true, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: true, transformFunction: null }, unit: { classPropertyName: "unit", publicName: "unit", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: false, transformFunction: null }, delta: { classPropertyName: "delta", publicName: "delta", isSignal: true, isRequired: false, transformFunction: null }, deltaSuffix: { classPropertyName: "deltaSuffix", publicName: "deltaSuffix", isSignal: true, isRequired: false, transformFunction: null }, deltaAriaLabel: { classPropertyName: "deltaAriaLabel", publicName: "deltaAriaLabel", isSignal: true, isRequired: false, transformFunction: null }, invertDelta: { classPropertyName: "invertDelta", publicName: "invertDelta", isSignal: true, isRequired: false, transformFunction: null }, loading: { classPropertyName: "loading", publicName: "loading", isSignal: true, isRequired: false, transformFunction: null }, caption: { classPropertyName: "caption", publicName: "caption", isSignal: true, isRequired: false, transformFunction: null }, data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class.strct-mt--loading": "loading()", "attr.aria-busy": "loading() ? \"true\" : null" }, classAttribute: "strct-mt" }, ngImport: i0, template: `
|
|
18091
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: StrctMetricTile, isStandalone: true, selector: "strct-metric-tile", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: true, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: true, transformFunction: null }, unit: { classPropertyName: "unit", publicName: "unit", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: false, transformFunction: null }, captionStatus: { classPropertyName: "captionStatus", publicName: "captionStatus", isSignal: true, isRequired: false, transformFunction: null }, href: { classPropertyName: "href", publicName: "href", isSignal: true, isRequired: false, transformFunction: null }, interactive: { classPropertyName: "interactive", publicName: "interactive", isSignal: true, isRequired: false, transformFunction: null }, delta: { classPropertyName: "delta", publicName: "delta", isSignal: true, isRequired: false, transformFunction: null }, deltaSuffix: { classPropertyName: "deltaSuffix", publicName: "deltaSuffix", isSignal: true, isRequired: false, transformFunction: null }, deltaAriaLabel: { classPropertyName: "deltaAriaLabel", publicName: "deltaAriaLabel", isSignal: true, isRequired: false, transformFunction: null }, invertDelta: { classPropertyName: "invertDelta", publicName: "invertDelta", isSignal: true, isRequired: false, transformFunction: null }, loading: { classPropertyName: "loading", publicName: "loading", isSignal: true, isRequired: false, transformFunction: null }, caption: { classPropertyName: "caption", publicName: "caption", isSignal: true, isRequired: false, transformFunction: null }, data: { classPropertyName: "data", publicName: "data", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { activated: "activated" }, host: { properties: { "class.strct-mt--actionable": "href() || interactive()", "class.strct-mt--loading": "loading()", "attr.aria-busy": "loading() ? \"true\" : null" }, classAttribute: "strct-mt" }, ngImport: i0, template: `
|
|
18076
18092
|
@if (loading()) {
|
|
18077
18093
|
<strct-skeleton width="45%" height="12px" />
|
|
18078
18094
|
<strct-skeleton width="65%" height="28px" />
|
|
@@ -18098,8 +18114,14 @@ class StrctMetricTile {
|
|
|
18098
18114
|
}
|
|
18099
18115
|
</div>
|
|
18100
18116
|
|
|
18117
|
+
<!-- A number over its bar: the meter sits under the value and above the
|
|
18118
|
+
caption, so "62 %" and "of 80 GB" read as one thing. -->
|
|
18119
|
+
<div class="strct-mt__meter"><ng-content select="[strctMetricMeter]" /></div>
|
|
18120
|
+
|
|
18101
18121
|
@if (caption()) {
|
|
18102
|
-
<div class="strct-mt__caption
|
|
18122
|
+
<div class="strct-mt__caption strct-mt__caption--{{ captionStatus() ?? 'none' }}">
|
|
18123
|
+
{{ caption() }}
|
|
18124
|
+
</div>
|
|
18103
18125
|
}
|
|
18104
18126
|
|
|
18105
18127
|
@if (data().length) {
|
|
@@ -18108,7 +18130,19 @@ class StrctMetricTile {
|
|
|
18108
18130
|
</div>
|
|
18109
18131
|
}
|
|
18110
18132
|
}
|
|
18111
|
-
|
|
18133
|
+
<!-- A KPI you can drill into is a link. The hit area covers the tile, so
|
|
18134
|
+
the whole tile is the target and the focus ring is the tile's own. -->
|
|
18135
|
+
@if (href()) {
|
|
18136
|
+
<a class="strct-mt__hit" [href]="href()" [attr.aria-label]="hitLabel()"></a>
|
|
18137
|
+
} @else if (interactive()) {
|
|
18138
|
+
<button
|
|
18139
|
+
type="button"
|
|
18140
|
+
class="strct-mt__hit"
|
|
18141
|
+
[attr.aria-label]="hitLabel()"
|
|
18142
|
+
(click)="activated.emit()"
|
|
18143
|
+
></button>
|
|
18144
|
+
}
|
|
18145
|
+
`, isInline: true, styles: [".strct-mt{position:relative;display:flex;flex-direction:column;gap:6px;padding:var(--space-3) var(--space-4);border:1px solid var(--b2);border-radius:var(--radius-lg);background:var(--bg-1);min-width:0}.strct-mt__top{display:flex;align-items:center;gap:7px}.strct-mt__icon{display:inline-flex;color:var(--t3);flex-shrink:0}.strct-mt__label{font-size:12px;font-weight:500;color:var(--t3);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.strct-mt__delta{display:inline-flex;align-items:center;gap:2px;margin-inline-start:auto;font-size:12px;font-weight:600;font-variant-numeric:tabular-nums;flex-shrink:0}.strct-mt__delta--up{color:var(--success)}.strct-mt__delta--down{color:var(--critical)}.strct-mt__delta--flat{color:var(--t3)}.strct-mt__meter:empty{display:none}.strct-mt__hit{position:absolute;inset:-1px;padding:0;border:0;background:none;border-radius:inherit;cursor:pointer}.strct-mt__hit:focus-visible{outline:2px solid var(--acc50);outline-offset:2px}.strct-mt--actionable:hover{border-color:var(--b3);background:var(--bg-2)}.strct-mt__sr{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}.strct-mt__value{display:flex;align-items:baseline;gap:4px;font-size:var(--text-3xl);font-weight:650;letter-spacing:-.01em;color:var(--t1);line-height:1.1}.strct-mt__value--accent{color:var(--acc)}.strct-mt__value--success{color:var(--success)}.strct-mt__value--warning{color:var(--warning)}.strct-mt__value--critical{color:var(--critical)}.strct-mt__unit{font-size:14px;font-weight:500;color:var(--t3);letter-spacing:0}.strct-mt__caption{font-size:12px;color:var(--t3)}.strct-mt__caption--accent{color:var(--acc)}.strct-mt__caption--success{color:var(--success)}.strct-mt__caption--warning{color:var(--warning)}.strct-mt__caption--critical{color:var(--critical)}.strct-mt__spark{margin-top:2px;line-height:0}.strct-mt__spark strct-sparkline,.strct-mt__spark .strct-spark__svg{width:100%}\n"], dependencies: [{ kind: "component", type: StrctIcon, selector: "strct-icon", inputs: ["name", "strictName", "size", "strokeWidth", "badge", "ariaLabel", "count", "countMax", "countStatus", "countLabel"] }, { kind: "component", type: StrctSkeleton, selector: "strct-skeleton", inputs: ["width", "height", "circle"] }, { kind: "component", type: StrctSparkline, selector: "strct-sparkline", inputs: ["data", "status", "area", "width", "height", "ariaLabel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
18112
18146
|
}
|
|
18113
18147
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: StrctMetricTile, decorators: [{
|
|
18114
18148
|
type: Component,
|
|
@@ -18138,8 +18172,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImpor
|
|
|
18138
18172
|
}
|
|
18139
18173
|
</div>
|
|
18140
18174
|
|
|
18175
|
+
<!-- A number over its bar: the meter sits under the value and above the
|
|
18176
|
+
caption, so "62 %" and "of 80 GB" read as one thing. -->
|
|
18177
|
+
<div class="strct-mt__meter"><ng-content select="[strctMetricMeter]" /></div>
|
|
18178
|
+
|
|
18141
18179
|
@if (caption()) {
|
|
18142
|
-
<div class="strct-mt__caption
|
|
18180
|
+
<div class="strct-mt__caption strct-mt__caption--{{ captionStatus() ?? 'none' }}">
|
|
18181
|
+
{{ caption() }}
|
|
18182
|
+
</div>
|
|
18143
18183
|
}
|
|
18144
18184
|
|
|
18145
18185
|
@if (data().length) {
|
|
@@ -18148,12 +18188,25 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImpor
|
|
|
18148
18188
|
</div>
|
|
18149
18189
|
}
|
|
18150
18190
|
}
|
|
18191
|
+
<!-- A KPI you can drill into is a link. The hit area covers the tile, so
|
|
18192
|
+
the whole tile is the target and the focus ring is the tile's own. -->
|
|
18193
|
+
@if (href()) {
|
|
18194
|
+
<a class="strct-mt__hit" [href]="href()" [attr.aria-label]="hitLabel()"></a>
|
|
18195
|
+
} @else if (interactive()) {
|
|
18196
|
+
<button
|
|
18197
|
+
type="button"
|
|
18198
|
+
class="strct-mt__hit"
|
|
18199
|
+
[attr.aria-label]="hitLabel()"
|
|
18200
|
+
(click)="activated.emit()"
|
|
18201
|
+
></button>
|
|
18202
|
+
}
|
|
18151
18203
|
`, host: {
|
|
18152
18204
|
class: 'strct-mt',
|
|
18205
|
+
'[class.strct-mt--actionable]': 'href() || interactive()',
|
|
18153
18206
|
'[class.strct-mt--loading]': 'loading()',
|
|
18154
18207
|
'[attr.aria-busy]': 'loading() ? "true" : null',
|
|
18155
|
-
}, styles: [".strct-mt{display:flex;flex-direction:column;gap:6px;padding:var(--space-3) var(--space-4);border:1px solid var(--b2);border-radius:var(--radius-lg);background:var(--bg-1);min-width:0}.strct-mt__top{display:flex;align-items:center;gap:7px}.strct-mt__icon{display:inline-flex;color:var(--t3);flex-shrink:0}.strct-mt__label{font-size:12px;font-weight:500;color:var(--t3);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.strct-mt__delta{display:inline-flex;align-items:center;gap:2px;margin-inline-start:auto;font-size:12px;font-weight:600;font-variant-numeric:tabular-nums;flex-shrink:0}.strct-mt__delta--up{color:var(--success)}.strct-mt__delta--down{color:var(--critical)}.strct-mt__delta--flat{color:var(--t3)}.strct-mt__sr{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}.strct-mt__value{display:flex;align-items:baseline;gap:4px;font-size:var(--text-3xl);font-weight:650;letter-spacing:-.01em;color:var(--t1);line-height:1.1}.strct-mt__value--accent{color:var(--acc)}.strct-mt__value--success{color:var(--success)}.strct-mt__value--warning{color:var(--warning)}.strct-mt__value--critical{color:var(--critical)}.strct-mt__unit{font-size:14px;font-weight:500;color:var(--t3);letter-spacing:0}.strct-mt__caption{font-size:12px;color:var(--t3)}.strct-mt__spark{margin-top:2px;line-height:0}.strct-mt__spark strct-sparkline,.strct-mt__spark .strct-spark__svg{width:100%}\n"] }]
|
|
18156
|
-
}], propDecorators: { label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: true }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: true }] }], unit: [{ type: i0.Input, args: [{ isSignal: true, alias: "unit", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], status: [{ type: i0.Input, args: [{ isSignal: true, alias: "status", required: false }] }], delta: [{ type: i0.Input, args: [{ isSignal: true, alias: "delta", required: false }] }], deltaSuffix: [{ type: i0.Input, args: [{ isSignal: true, alias: "deltaSuffix", required: false }] }], deltaAriaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "deltaAriaLabel", required: false }] }], invertDelta: [{ type: i0.Input, args: [{ isSignal: true, alias: "invertDelta", required: false }] }], loading: [{ type: i0.Input, args: [{ isSignal: true, alias: "loading", required: false }] }], caption: [{ type: i0.Input, args: [{ isSignal: true, alias: "caption", required: false }] }], data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: false }] }] } });
|
|
18208
|
+
}, styles: [".strct-mt{position:relative;display:flex;flex-direction:column;gap:6px;padding:var(--space-3) var(--space-4);border:1px solid var(--b2);border-radius:var(--radius-lg);background:var(--bg-1);min-width:0}.strct-mt__top{display:flex;align-items:center;gap:7px}.strct-mt__icon{display:inline-flex;color:var(--t3);flex-shrink:0}.strct-mt__label{font-size:12px;font-weight:500;color:var(--t3);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.strct-mt__delta{display:inline-flex;align-items:center;gap:2px;margin-inline-start:auto;font-size:12px;font-weight:600;font-variant-numeric:tabular-nums;flex-shrink:0}.strct-mt__delta--up{color:var(--success)}.strct-mt__delta--down{color:var(--critical)}.strct-mt__delta--flat{color:var(--t3)}.strct-mt__meter:empty{display:none}.strct-mt__hit{position:absolute;inset:-1px;padding:0;border:0;background:none;border-radius:inherit;cursor:pointer}.strct-mt__hit:focus-visible{outline:2px solid var(--acc50);outline-offset:2px}.strct-mt--actionable:hover{border-color:var(--b3);background:var(--bg-2)}.strct-mt__sr{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}.strct-mt__value{display:flex;align-items:baseline;gap:4px;font-size:var(--text-3xl);font-weight:650;letter-spacing:-.01em;color:var(--t1);line-height:1.1}.strct-mt__value--accent{color:var(--acc)}.strct-mt__value--success{color:var(--success)}.strct-mt__value--warning{color:var(--warning)}.strct-mt__value--critical{color:var(--critical)}.strct-mt__unit{font-size:14px;font-weight:500;color:var(--t3);letter-spacing:0}.strct-mt__caption{font-size:12px;color:var(--t3)}.strct-mt__caption--accent{color:var(--acc)}.strct-mt__caption--success{color:var(--success)}.strct-mt__caption--warning{color:var(--warning)}.strct-mt__caption--critical{color:var(--critical)}.strct-mt__spark{margin-top:2px;line-height:0}.strct-mt__spark strct-sparkline,.strct-mt__spark .strct-spark__svg{width:100%}\n"] }]
|
|
18209
|
+
}], propDecorators: { label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: true }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: true }] }], unit: [{ type: i0.Input, args: [{ isSignal: true, alias: "unit", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], status: [{ type: i0.Input, args: [{ isSignal: true, alias: "status", required: false }] }], captionStatus: [{ type: i0.Input, args: [{ isSignal: true, alias: "captionStatus", required: false }] }], href: [{ type: i0.Input, args: [{ isSignal: true, alias: "href", required: false }] }], interactive: [{ type: i0.Input, args: [{ isSignal: true, alias: "interactive", required: false }] }], activated: [{ type: i0.Output, args: ["activated"] }], delta: [{ type: i0.Input, args: [{ isSignal: true, alias: "delta", required: false }] }], deltaSuffix: [{ type: i0.Input, args: [{ isSignal: true, alias: "deltaSuffix", required: false }] }], deltaAriaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "deltaAriaLabel", required: false }] }], invertDelta: [{ type: i0.Input, args: [{ isSignal: true, alias: "invertDelta", required: false }] }], loading: [{ type: i0.Input, args: [{ isSignal: true, alias: "loading", required: false }] }], caption: [{ type: i0.Input, args: [{ isSignal: true, alias: "caption", required: false }] }], data: [{ type: i0.Input, args: [{ isSignal: true, alias: "data", required: false }] }] } });
|
|
18157
18210
|
|
|
18158
18211
|
let heroCounter = 0;
|
|
18159
18212
|
/** Default leading icon per status, when `icon` is not supplied. */
|
|
@@ -18256,9 +18309,18 @@ class StrctAlert {
|
|
|
18256
18309
|
/** Accessible label of the dismiss button (localizable). */
|
|
18257
18310
|
dismissLabel = input('Dismiss', /* @ts-ignore */
|
|
18258
18311
|
...(ngDevMode ? [{ debugName: "dismissLabel" }] : /* istanbul ignore next */ []));
|
|
18312
|
+
/**
|
|
18313
|
+
* Overrides the icon derived from `type` — a lock for a locked setting, a
|
|
18314
|
+
* shield for a security note, when the tone alone does not say what kind of
|
|
18315
|
+
* note this is. `null` keeps the derived one.
|
|
18316
|
+
*/
|
|
18317
|
+
icon = input(null, /* @ts-ignore */
|
|
18318
|
+
...(ngDevMode ? [{ debugName: "icon" }] : /* istanbul ignore next */ []));
|
|
18259
18319
|
/** Emitted when the alert is dismissed. */
|
|
18260
18320
|
closed = output();
|
|
18261
|
-
|
|
18321
|
+
iconName = computed(() => this.icon() ?? this.derivedIcon(), /* @ts-ignore */
|
|
18322
|
+
...(ngDevMode ? [{ debugName: "iconName" }] : /* istanbul ignore next */ []));
|
|
18323
|
+
derivedIcon = computed(() => {
|
|
18262
18324
|
switch (this.type()) {
|
|
18263
18325
|
case 'success':
|
|
18264
18326
|
return 'success';
|
|
@@ -18270,38 +18332,46 @@ class StrctAlert {
|
|
|
18270
18332
|
return 'info';
|
|
18271
18333
|
}
|
|
18272
18334
|
}, /* @ts-ignore */
|
|
18273
|
-
...(ngDevMode ? [{ debugName: "
|
|
18335
|
+
...(ngDevMode ? [{ debugName: "derivedIcon" }] : /* istanbul ignore next */ []));
|
|
18274
18336
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: StrctAlert, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
18275
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: StrctAlert, isStandalone: true, selector: "strct-alert", inputs: { type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: false, transformFunction: null }, closable: { classPropertyName: "closable", publicName: "closable", isSignal: true, isRequired: false, transformFunction: null }, dismissLabel: { classPropertyName: "dismissLabel", publicName: "dismissLabel", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { closed: "closed" }, host: { properties: { "attr.role": "type() === 'critical' ? 'alert' : 'status'", "class.strct-alert--success": "type() === 'success'", "class.strct-alert--warning": "type() === 'warning'", "class.strct-alert--critical": "type() === 'critical'" }, classAttribute: "strct-alert" }, ngImport: i0, template: `
|
|
18276
|
-
|
|
18277
|
-
|
|
18278
|
-
|
|
18279
|
-
<
|
|
18280
|
-
|
|
18281
|
-
|
|
18282
|
-
|
|
18283
|
-
|
|
18284
|
-
|
|
18285
|
-
|
|
18286
|
-
|
|
18287
|
-
|
|
18288
|
-
|
|
18337
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.1.4", type: StrctAlert, isStandalone: true, selector: "strct-alert", inputs: { type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: false, transformFunction: null }, closable: { classPropertyName: "closable", publicName: "closable", isSignal: true, isRequired: false, transformFunction: null }, dismissLabel: { classPropertyName: "dismissLabel", publicName: "dismissLabel", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { closed: "closed" }, host: { properties: { "attr.role": "type() === 'critical' ? 'alert' : 'status'", "class.strct-alert--success": "type() === 'success'", "class.strct-alert--warning": "type() === 'warning'", "class.strct-alert--critical": "type() === 'critical'" }, classAttribute: "strct-alert" }, ngImport: i0, template: `
|
|
18338
|
+
<!-- The row carries the layout, not the host: a consumer setting
|
|
18339
|
+
display:block for spacing must not put the icon on its own line. -->
|
|
18340
|
+
<div class="strct-alert__row">
|
|
18341
|
+
<strct-icon class="strct-alert__icon" [name]="iconName()" [size]="16" />
|
|
18342
|
+
<div class="strct-alert__body"><ng-content /></div>
|
|
18343
|
+
@if (closable()) {
|
|
18344
|
+
<button
|
|
18345
|
+
type="button"
|
|
18346
|
+
class="strct-alert__close"
|
|
18347
|
+
[attr.aria-label]="dismissLabel()"
|
|
18348
|
+
(click)="closed.emit()"
|
|
18349
|
+
>
|
|
18350
|
+
<strct-icon name="close" [size]="13" />
|
|
18351
|
+
</button>
|
|
18352
|
+
}
|
|
18353
|
+
</div>
|
|
18354
|
+
`, isInline: true, styles: [".strct-alert{display:block;padding:var(--space-2) var(--space-3);border-radius:var(--radius-lg);font-size:13px;color:var(--t1);background:var(--bg-1);border:1px solid var(--b2);border-inline-start:3px solid var(--acc)}.strct-alert__row{display:flex;align-items:flex-start;gap:var(--space-2)}.strct-alert strct-icon{color:var(--acc);margin-top:1px;flex-shrink:0}.strct-alert__body{flex:1;color:var(--t1)}.strct-alert__close{flex-shrink:0;display:inline-flex;padding:2px;margin-block-start:-2px;margin-inline-end:-2px;border:0;background:transparent;color:var(--t3);cursor:pointer;border-radius:var(--radius-sm)}.strct-alert__close:hover{color:var(--t1);background:var(--bg-3)}.strct-alert--success{border-inline-start-color:var(--success)}.strct-alert--success strct-icon{color:var(--success)}.strct-alert--warning{border-inline-start-color:var(--warning)}.strct-alert--warning strct-icon{color:var(--warning)}.strct-alert--critical{border-inline-start-color:var(--critical)}.strct-alert--critical strct-icon{color:var(--critical)}\n"], dependencies: [{ kind: "component", type: StrctIcon, selector: "strct-icon", inputs: ["name", "strictName", "size", "strokeWidth", "badge", "ariaLabel", "count", "countMax", "countStatus", "countLabel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
18289
18355
|
}
|
|
18290
18356
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: StrctAlert, decorators: [{
|
|
18291
18357
|
type: Component,
|
|
18292
18358
|
args: [{ selector: 'strct-alert', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [StrctIcon], template: `
|
|
18293
|
-
|
|
18294
|
-
|
|
18295
|
-
|
|
18296
|
-
<
|
|
18297
|
-
|
|
18298
|
-
|
|
18299
|
-
|
|
18300
|
-
|
|
18301
|
-
|
|
18302
|
-
|
|
18303
|
-
|
|
18304
|
-
|
|
18359
|
+
<!-- The row carries the layout, not the host: a consumer setting
|
|
18360
|
+
display:block for spacing must not put the icon on its own line. -->
|
|
18361
|
+
<div class="strct-alert__row">
|
|
18362
|
+
<strct-icon class="strct-alert__icon" [name]="iconName()" [size]="16" />
|
|
18363
|
+
<div class="strct-alert__body"><ng-content /></div>
|
|
18364
|
+
@if (closable()) {
|
|
18365
|
+
<button
|
|
18366
|
+
type="button"
|
|
18367
|
+
class="strct-alert__close"
|
|
18368
|
+
[attr.aria-label]="dismissLabel()"
|
|
18369
|
+
(click)="closed.emit()"
|
|
18370
|
+
>
|
|
18371
|
+
<strct-icon name="close" [size]="13" />
|
|
18372
|
+
</button>
|
|
18373
|
+
}
|
|
18374
|
+
</div>
|
|
18305
18375
|
`, host: {
|
|
18306
18376
|
class: 'strct-alert',
|
|
18307
18377
|
// role="alert" implies aria-live="assertive" for critical alerts.
|
|
@@ -18309,8 +18379,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImpor
|
|
|
18309
18379
|
'[class.strct-alert--success]': "type() === 'success'",
|
|
18310
18380
|
'[class.strct-alert--warning]': "type() === 'warning'",
|
|
18311
18381
|
'[class.strct-alert--critical]': "type() === 'critical'",
|
|
18312
|
-
}, styles: [".strct-alert{display:
|
|
18313
|
-
}], propDecorators: { type: [{ type: i0.Input, args: [{ isSignal: true, alias: "type", required: false }] }], closable: [{ type: i0.Input, args: [{ isSignal: true, alias: "closable", required: false }] }], dismissLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "dismissLabel", required: false }] }], closed: [{ type: i0.Output, args: ["closed"] }] } });
|
|
18382
|
+
}, styles: [".strct-alert{display:block;padding:var(--space-2) var(--space-3);border-radius:var(--radius-lg);font-size:13px;color:var(--t1);background:var(--bg-1);border:1px solid var(--b2);border-inline-start:3px solid var(--acc)}.strct-alert__row{display:flex;align-items:flex-start;gap:var(--space-2)}.strct-alert strct-icon{color:var(--acc);margin-top:1px;flex-shrink:0}.strct-alert__body{flex:1;color:var(--t1)}.strct-alert__close{flex-shrink:0;display:inline-flex;padding:2px;margin-block-start:-2px;margin-inline-end:-2px;border:0;background:transparent;color:var(--t3);cursor:pointer;border-radius:var(--radius-sm)}.strct-alert__close:hover{color:var(--t1);background:var(--bg-3)}.strct-alert--success{border-inline-start-color:var(--success)}.strct-alert--success strct-icon{color:var(--success)}.strct-alert--warning{border-inline-start-color:var(--warning)}.strct-alert--warning strct-icon{color:var(--warning)}.strct-alert--critical{border-inline-start-color:var(--critical)}.strct-alert--critical strct-icon{color:var(--critical)}\n"] }]
|
|
18383
|
+
}], propDecorators: { type: [{ type: i0.Input, args: [{ isSignal: true, alias: "type", required: false }] }], closable: [{ type: i0.Input, args: [{ isSignal: true, alias: "closable", required: false }] }], dismissLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "dismissLabel", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], closed: [{ type: i0.Output, args: ["closed"] }] } });
|
|
18314
18384
|
|
|
18315
18385
|
let tooltipCounter = 0;
|
|
18316
18386
|
/**
|
|
@@ -21858,13 +21928,19 @@ class StrctStatusDot {
|
|
|
21858
21928
|
/** Dot size: `sm` for dense rows, `md` standalone. */
|
|
21859
21929
|
size = input('md', /* @ts-ignore */
|
|
21860
21930
|
...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
21931
|
+
/**
|
|
21932
|
+
* Something happening *now* — a task running, a live chart. The halo pulses
|
|
21933
|
+
* once a second; the dot itself never changes size, so a column of dots does
|
|
21934
|
+
* not jitter. Under `prefers-reduced-motion` the halo is a static ring.
|
|
21935
|
+
*/
|
|
21936
|
+
pulse = input(false, { ...(ngDevMode ? { debugName: "pulse" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
21861
21937
|
text = computed(() => this.label() || DEFAULT_LABEL[this.status()], /* @ts-ignore */
|
|
21862
21938
|
...(ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []));
|
|
21863
21939
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: StrctStatusDot, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
21864
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.4", type: StrctStatusDot, isStandalone: true, selector: "strct-status-dot", inputs: { status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class.strct-dot--accent": "status() === 'accent'", "class.strct-dot--success": "status() === 'success'", "class.strct-dot--warning": "status() === 'warning'", "class.strct-dot--critical": "status() === 'critical'", "class.strct-dot--sm": "size() === 'sm'" }, classAttribute: "strct-dot" }, ngImport: i0, template: `
|
|
21940
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.4", type: StrctStatusDot, isStandalone: true, selector: "strct-status-dot", inputs: { status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, pulse: { classPropertyName: "pulse", publicName: "pulse", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class.strct-dot--accent": "status() === 'accent'", "class.strct-dot--success": "status() === 'success'", "class.strct-dot--warning": "status() === 'warning'", "class.strct-dot--critical": "status() === 'critical'", "class.strct-dot--sm": "size() === 'sm'", "class.strct-dot--pulse": "pulse()" }, classAttribute: "strct-dot" }, ngImport: i0, template: `
|
|
21865
21941
|
<span class="strct-dot__dot" aria-hidden="true"></span>
|
|
21866
21942
|
<span class="strct-dot__sr">{{ text() }}</span>
|
|
21867
|
-
`, isInline: true, styles: [".strct-dot{display:inline-flex;align-items:center;flex:none;line-height:0}.strct-dot__dot{width:10px;height:10px;border-radius:50%;background:var(--t3)}.strct-dot--sm .strct-dot__dot{width:8px;height:8px}.strct-dot--accent .strct-dot__dot{background:var(--acc)}.strct-dot--success .strct-dot__dot{background:var(--success)}.strct-dot--warning .strct-dot__dot{background:var(--warning)}.strct-dot--critical .strct-dot__dot{background:var(--critical)}.strct-dot__sr{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
21943
|
+
`, isInline: true, styles: [".strct-dot{display:inline-flex;align-items:center;flex:none;line-height:0}.strct-dot__dot{width:10px;height:10px;border-radius:50%;background:var(--t3)}.strct-dot--sm .strct-dot__dot{width:8px;height:8px}.strct-dot--accent .strct-dot__dot{background:var(--acc)}.strct-dot--success .strct-dot__dot{background:var(--success)}.strct-dot--warning .strct-dot__dot{background:var(--warning)}.strct-dot--critical .strct-dot__dot{background:var(--critical)}.strct-dot--pulse .strct-dot__dot{position:relative}.strct-dot--pulse .strct-dot__dot:after{content:\"\";position:absolute;inset:0;border-radius:50%;background:inherit;animation:strct-dot-pulse 1s ease-out infinite}@keyframes strct-dot-pulse{0%{box-shadow:0 0 0 0 currentColor;opacity:.55}to{box-shadow:0 0 0 5px transparent;opacity:0}}.strct-dot--pulse .strct-dot__dot{color:var(--t3)}.strct-dot--pulse.strct-dot--accent .strct-dot__dot{color:var(--acc)}.strct-dot--pulse.strct-dot--success .strct-dot__dot{color:var(--success)}.strct-dot--pulse.strct-dot--warning .strct-dot__dot{color:var(--warning)}.strct-dot--pulse.strct-dot--critical .strct-dot__dot{color:var(--critical)}@media(prefers-reduced-motion:reduce){.strct-dot--pulse .strct-dot__dot:after{animation:none;box-shadow:0 0 0 3px currentColor;opacity:.25}}.strct-dot__sr{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
21868
21944
|
}
|
|
21869
21945
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: StrctStatusDot, decorators: [{
|
|
21870
21946
|
type: Component,
|
|
@@ -21878,8 +21954,115 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImpor
|
|
|
21878
21954
|
'[class.strct-dot--warning]': "status() === 'warning'",
|
|
21879
21955
|
'[class.strct-dot--critical]': "status() === 'critical'",
|
|
21880
21956
|
'[class.strct-dot--sm]': "size() === 'sm'",
|
|
21881
|
-
|
|
21882
|
-
|
|
21957
|
+
'[class.strct-dot--pulse]': 'pulse()',
|
|
21958
|
+
}, styles: [".strct-dot{display:inline-flex;align-items:center;flex:none;line-height:0}.strct-dot__dot{width:10px;height:10px;border-radius:50%;background:var(--t3)}.strct-dot--sm .strct-dot__dot{width:8px;height:8px}.strct-dot--accent .strct-dot__dot{background:var(--acc)}.strct-dot--success .strct-dot__dot{background:var(--success)}.strct-dot--warning .strct-dot__dot{background:var(--warning)}.strct-dot--critical .strct-dot__dot{background:var(--critical)}.strct-dot--pulse .strct-dot__dot{position:relative}.strct-dot--pulse .strct-dot__dot:after{content:\"\";position:absolute;inset:0;border-radius:50%;background:inherit;animation:strct-dot-pulse 1s ease-out infinite}@keyframes strct-dot-pulse{0%{box-shadow:0 0 0 0 currentColor;opacity:.55}to{box-shadow:0 0 0 5px transparent;opacity:0}}.strct-dot--pulse .strct-dot__dot{color:var(--t3)}.strct-dot--pulse.strct-dot--accent .strct-dot__dot{color:var(--acc)}.strct-dot--pulse.strct-dot--success .strct-dot__dot{color:var(--success)}.strct-dot--pulse.strct-dot--warning .strct-dot__dot{color:var(--warning)}.strct-dot--pulse.strct-dot--critical .strct-dot__dot{color:var(--critical)}@media(prefers-reduced-motion:reduce){.strct-dot--pulse .strct-dot__dot:after{animation:none;box-shadow:0 0 0 3px currentColor;opacity:.25}}.strct-dot__sr{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}\n"] }]
|
|
21959
|
+
}], propDecorators: { status: [{ type: i0.Input, args: [{ isSignal: true, alias: "status", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], pulse: [{ type: i0.Input, args: [{ isSignal: true, alias: "pulse", required: false }] }] } });
|
|
21960
|
+
|
|
21961
|
+
const DEFAULT_LABELS = {
|
|
21962
|
+
live: 'Live',
|
|
21963
|
+
liveEvery: (s) => `Live · updates every ${s} s`,
|
|
21964
|
+
connecting: 'Connecting…',
|
|
21965
|
+
reconnecting: 'Reconnecting…',
|
|
21966
|
+
paused: 'Paused',
|
|
21967
|
+
stale: (relative) => `Last updated ${relative}`,
|
|
21968
|
+
justNow: 'just now',
|
|
21969
|
+
minutesAgo: (n) => `${n} min ago`,
|
|
21970
|
+
hoursAgo: (n) => `${n} h ago`,
|
|
21971
|
+
};
|
|
21972
|
+
const TONE = {
|
|
21973
|
+
live: 'success',
|
|
21974
|
+
connecting: 'accent',
|
|
21975
|
+
reconnecting: 'warning',
|
|
21976
|
+
paused: 'neutral',
|
|
21977
|
+
stale: 'warning',
|
|
21978
|
+
};
|
|
21979
|
+
/**
|
|
21980
|
+
* "Live · updates every 5 s" and "Reconnecting…" are states of one indicator,
|
|
21981
|
+
* not three captions written by hand next to three hand-rolled dots. A dot that
|
|
21982
|
+
* is live and a dot that is merely green are different facts.
|
|
21983
|
+
*
|
|
21984
|
+
* <strct-live-indicator state="live" [interval]="5000" />
|
|
21985
|
+
* <strct-live-indicator state="stale" [updatedAt]="lastRead" />
|
|
21986
|
+
*
|
|
21987
|
+
* It is a `role="status"`, so a change of state is announced politely — and the
|
|
21988
|
+
* relative time re-renders on its own every 30 s without announcing each tick.
|
|
21989
|
+
*/
|
|
21990
|
+
class StrctLiveIndicator {
|
|
21991
|
+
/** What the view is doing. */
|
|
21992
|
+
state = input('live', /* @ts-ignore */
|
|
21993
|
+
...(ngDevMode ? [{ debugName: "state" }] : /* istanbul ignore next */ []));
|
|
21994
|
+
/** Refresh period in ms — turns "Live" into "Live · updates every 5 s". */
|
|
21995
|
+
interval = input(null, /* @ts-ignore */
|
|
21996
|
+
...(ngDevMode ? [{ debugName: "interval" }] : /* istanbul ignore next */ []));
|
|
21997
|
+
/** When the data last arrived; drives the relative time of `stale`. */
|
|
21998
|
+
updatedAt = input(null, /* @ts-ignore */
|
|
21999
|
+
...(ngDevMode ? [{ debugName: "updatedAt" }] : /* istanbul ignore next */ []));
|
|
22000
|
+
/** Every string, for localisation. */
|
|
22001
|
+
labels = input({}, /* @ts-ignore */
|
|
22002
|
+
...(ngDevMode ? [{ debugName: "labels" }] : /* istanbul ignore next */ []));
|
|
22003
|
+
tone = computed(() => TONE[this.state()], /* @ts-ignore */
|
|
22004
|
+
...(ngDevMode ? [{ debugName: "tone" }] : /* istanbul ignore next */ []));
|
|
22005
|
+
/** Only a view that is actually receiving data pulses. */
|
|
22006
|
+
pulsing = computed(() => this.state() === 'live', /* @ts-ignore */
|
|
22007
|
+
...(ngDevMode ? [{ debugName: "pulsing" }] : /* istanbul ignore next */ []));
|
|
22008
|
+
L = computed(() => ({ ...DEFAULT_LABELS, ...this.labels() }), /* @ts-ignore */
|
|
22009
|
+
...(ngDevMode ? [{ debugName: "L" }] : /* istanbul ignore next */ []));
|
|
22010
|
+
/** Re-read every 30 s, so "3 min ago" does not go stale on screen. */
|
|
22011
|
+
now = signal(Date.now(), /* @ts-ignore */
|
|
22012
|
+
...(ngDevMode ? [{ debugName: "now" }] : /* istanbul ignore next */ []));
|
|
22013
|
+
constructor() {
|
|
22014
|
+
const timer = setInterval(() => this.now.set(Date.now()), 30_000);
|
|
22015
|
+
inject(DestroyRef).onDestroy(() => clearInterval(timer));
|
|
22016
|
+
}
|
|
22017
|
+
relative = computed(() => {
|
|
22018
|
+
const at = this.updatedAt();
|
|
22019
|
+
if (at == null)
|
|
22020
|
+
return '';
|
|
22021
|
+
const ms = this.now() - (at instanceof Date ? at.getTime() : at);
|
|
22022
|
+
const mins = Math.floor(ms / 60_000);
|
|
22023
|
+
if (mins < 1)
|
|
22024
|
+
return this.L().justNow;
|
|
22025
|
+
if (mins < 60)
|
|
22026
|
+
return this.L().minutesAgo(mins);
|
|
22027
|
+
return this.L().hoursAgo(Math.floor(mins / 60));
|
|
22028
|
+
}, /* @ts-ignore */
|
|
22029
|
+
...(ngDevMode ? [{ debugName: "relative" }] : /* istanbul ignore next */ []));
|
|
22030
|
+
text = computed(() => {
|
|
22031
|
+
const l = this.L();
|
|
22032
|
+
switch (this.state()) {
|
|
22033
|
+
case 'live': {
|
|
22034
|
+
const ms = this.interval();
|
|
22035
|
+
return ms ? l.liveEvery(Math.round(ms / 1000)) : l.live;
|
|
22036
|
+
}
|
|
22037
|
+
case 'connecting':
|
|
22038
|
+
return l.connecting;
|
|
22039
|
+
case 'reconnecting':
|
|
22040
|
+
return l.reconnecting;
|
|
22041
|
+
case 'paused':
|
|
22042
|
+
return l.paused;
|
|
22043
|
+
case 'stale':
|
|
22044
|
+
return this.relative() ? l.stale(this.relative()) : l.stale('');
|
|
22045
|
+
}
|
|
22046
|
+
}, /* @ts-ignore */
|
|
22047
|
+
...(ngDevMode ? [{ debugName: "text" }] : /* istanbul ignore next */ []));
|
|
22048
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: StrctLiveIndicator, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
22049
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "22.1.4", type: StrctLiveIndicator, isStandalone: true, selector: "strct-live-indicator", inputs: { state: { classPropertyName: "state", publicName: "state", isSignal: true, isRequired: false, transformFunction: null }, interval: { classPropertyName: "interval", publicName: "interval", isSignal: true, isRequired: false, transformFunction: null }, updatedAt: { classPropertyName: "updatedAt", publicName: "updatedAt", isSignal: true, isRequired: false, transformFunction: null }, labels: { classPropertyName: "labels", publicName: "labels", isSignal: true, isRequired: false, transformFunction: null } }, host: { attributes: { "role": "status", "aria-live": "polite" }, properties: { "attr.data-state": "state()" }, classAttribute: "strct-live" }, ngImport: i0, template: `
|
|
22050
|
+
<strct-status-dot size="sm" [status]="tone()" [pulse]="pulsing()" [label]="text()" />
|
|
22051
|
+
<span class="strct-live__text">{{ text() }}</span>
|
|
22052
|
+
`, isInline: true, styles: [".strct-live{display:inline-flex;align-items:center;gap:6px;font-size:var(--text-sm);color:var(--t3)}.strct-live[data-state=reconnecting] .strct-live__text,.strct-live[data-state=stale] .strct-live__text{color:var(--warning)}.strct-live .strct-dot__sr{display:none}\n"], dependencies: [{ kind: "component", type: StrctStatusDot, selector: "strct-status-dot", inputs: ["status", "label", "size", "pulse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
22053
|
+
}
|
|
22054
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImport: i0, type: StrctLiveIndicator, decorators: [{
|
|
22055
|
+
type: Component,
|
|
22056
|
+
args: [{ selector: 'strct-live-indicator', changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, imports: [StrctStatusDot], template: `
|
|
22057
|
+
<strct-status-dot size="sm" [status]="tone()" [pulse]="pulsing()" [label]="text()" />
|
|
22058
|
+
<span class="strct-live__text">{{ text() }}</span>
|
|
22059
|
+
`, host: {
|
|
22060
|
+
class: 'strct-live',
|
|
22061
|
+
role: 'status',
|
|
22062
|
+
'aria-live': 'polite',
|
|
22063
|
+
'[attr.data-state]': 'state()',
|
|
22064
|
+
}, styles: [".strct-live{display:inline-flex;align-items:center;gap:6px;font-size:var(--text-sm);color:var(--t3)}.strct-live[data-state=reconnecting] .strct-live__text,.strct-live[data-state=stale] .strct-live__text{color:var(--warning)}.strct-live .strct-dot__sr{display:none}\n"] }]
|
|
22065
|
+
}], ctorParameters: () => [], propDecorators: { state: [{ type: i0.Input, args: [{ isSignal: true, alias: "state", required: false }] }], interval: [{ type: i0.Input, args: [{ isSignal: true, alias: "interval", required: false }] }], updatedAt: [{ type: i0.Input, args: [{ isSignal: true, alias: "updatedAt", required: false }] }], labels: [{ type: i0.Input, args: [{ isSignal: true, alias: "labels", required: false }] }] } });
|
|
21883
22066
|
|
|
21884
22067
|
/**
|
|
21885
22068
|
* A generic anchored overlay panel for arbitrary projected content — the
|
|
@@ -23747,5 +23930,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.1.4", ngImpor
|
|
|
23747
23930
|
* Generated bundle index. Do not edit.
|
|
23748
23931
|
*/
|
|
23749
23932
|
|
|
23750
|
-
export { FOCUSABLE_SELECTOR, STRCT_DP_DOW, STRCT_DP_DOW_FULL, STRCT_DP_MONTHS, STRCT_ICONS, STRCT_ICON_GROUPS, STRCT_ICON_NAMES, STRCT_MASKS, STRCT_NOTIFICATION_HISTORY_LIMIT, STRCT_PALETTES, STRCT_RAW_ICONS, STRCT_TIME_RANGE_PRESETS, STRCT_WIZARD_DEFAULTS, StrctAccordion, StrctAccordionPanel, StrctAlert, StrctAnnouncer, StrctAvatar, StrctBadge, StrctBreadcrumb, StrctBreadcrumbItem, StrctButton, StrctButtonGroup, StrctBytesPipe, StrctCard, StrctCardBlock, StrctCardFooter, StrctCardHeader, StrctCardHeaderActions, StrctCardHeaderMeta, StrctCardHeaderNote, StrctCascadeColumn, StrctCascadeHost, StrctCascadeSelect, StrctCellDef, StrctCellStatus, StrctChart, StrctCheckbox, StrctChips, StrctCode, StrctCodeInline, StrctColorPicker, StrctCombobox, StrctCommandPalette, StrctConfirmOutlet, StrctConfirmService, StrctContextMenu, StrctContextMenuTrigger, StrctControlDescription, StrctCopy, StrctDatagrid, StrctDatagridActionBar, StrctDatagridActionBarCaption, StrctDatepicker, StrctDatetimePicker, StrctDesc, StrctDescriptionList, StrctDiff, StrctDivider, StrctDonut, StrctDrawer, StrctDrawerFooter, StrctDropdown, StrctDropdownDivider, StrctDropdownItem, StrctDropdownItemAction, StrctDropdownTrigger, StrctDurationPipe, StrctEmptyState, StrctField, StrctFieldGroup, StrctFieldHint, StrctFieldPrefix, StrctFieldSuffix, StrctFile, StrctFilterBar, StrctFlow, StrctFooter, StrctGauge, StrctHeader, StrctHeatmap, StrctHero, StrctHotkeysHelp, StrctHotkeysService, StrctIcon, StrctInlineEdit, StrctInput, StrctInputMask, StrctInputOtp, StrctKbd, StrctKnob, StrctList, StrctListItem, StrctListItemDescription, StrctListItemLeading, StrctListItemMeta, StrctListItemTrailing, StrctLogViewer, StrctLogin, StrctMenuPanel, StrctMenuService, StrctMenubar, StrctMetricTile, StrctModal, StrctModalContent, StrctNav, StrctNavItem, StrctNotificationCenter, StrctNumber, StrctOverlay, StrctPageHeader, StrctPageHeaderActions, StrctPageHeaderCrumbs, StrctPageHeaderTitleMeta, StrctPagination, StrctPassword, StrctPopover, StrctPopoverTrigger, StrctProgress, StrctRadio, StrctRadioGroup, StrctRail, StrctRange, StrctRatePipe, StrctRating, StrctReorder, StrctReorderItem, StrctRowDetailDef, StrctSearchbox, StrctSectionHeader, StrctSectionHeaderActions, StrctSectionHeaderMeta, StrctSectionMenu, StrctSegmented, StrctSelect, StrctShell, StrctShellService, StrctSiPipe, StrctSignpost, StrctSignpostTrigger, StrctSkeleton, StrctSparkline, StrctSpeedDial, StrctSpinner, StrctSplitButton, StrctSplitter, StrctStack, StrctStackItem, StrctStatusDot, StrctStep, StrctSubmenu, StrctTab, StrctTable, StrctTabs, StrctTag, StrctTagLeading, StrctThemeService, StrctThemeSwitcher, StrctTimeRangePicker, StrctTimeline, StrctTimelineItem, StrctToastOutlet, StrctToastService, StrctToggle, StrctToolbar, StrctToolbarCaption, StrctToolbarSpacer, StrctTooltip, StrctTour, StrctTransfer, StrctTree, StrctTreeNode, StrctTreeSelect, StrctVerticalNav, StrctWatermark, StrctWizard, StrctWizardAside, focusFirstIn, keepTabInside, lockBodyScroll, parseAnsi, provideStrctWizardDefaults, registerStrctIcon, restoreFocus, saveFocusedElement, strctComputeDiff, strctDpPad, strctFormatBytes, strctFormatDuration, strctFormatRate, strctFormatSi, strctValidationIcon, strctValidationTone, unlockBodyScroll };
|
|
23933
|
+
export { FOCUSABLE_SELECTOR, STRCT_DP_DOW, STRCT_DP_DOW_FULL, STRCT_DP_MONTHS, STRCT_ICONS, STRCT_ICON_GROUPS, STRCT_ICON_NAMES, STRCT_MASKS, STRCT_NOTIFICATION_HISTORY_LIMIT, STRCT_PALETTES, STRCT_RAW_ICONS, STRCT_TIME_RANGE_PRESETS, STRCT_WIZARD_DEFAULTS, StrctAccordion, StrctAccordionPanel, StrctAlert, StrctAnnouncer, StrctAvatar, StrctBadge, StrctBreadcrumb, StrctBreadcrumbItem, StrctButton, StrctButtonGroup, StrctBytesPipe, StrctCard, StrctCardBlock, StrctCardFooter, StrctCardHeader, StrctCardHeaderActions, StrctCardHeaderMeta, StrctCardHeaderNote, StrctCascadeColumn, StrctCascadeHost, StrctCascadeSelect, StrctCellDef, StrctCellStatus, StrctChart, StrctCheckbox, StrctChips, StrctCode, StrctCodeInline, StrctColorPicker, StrctCombobox, StrctCommandPalette, StrctConfirmOutlet, StrctConfirmService, StrctContextMenu, StrctContextMenuTrigger, StrctControlDescription, StrctCopy, StrctDatagrid, StrctDatagridActionBar, StrctDatagridActionBarCaption, StrctDatepicker, StrctDatetimePicker, StrctDesc, StrctDescriptionList, StrctDiff, StrctDivider, StrctDonut, StrctDrawer, StrctDrawerFooter, StrctDropdown, StrctDropdownDivider, StrctDropdownItem, StrctDropdownItemAction, StrctDropdownTrigger, StrctDurationPipe, StrctEmptyState, StrctField, StrctFieldGroup, StrctFieldHint, StrctFieldPrefix, StrctFieldSuffix, StrctFile, StrctFilterBar, StrctFlow, StrctFooter, StrctGauge, StrctHeader, StrctHeatmap, StrctHero, StrctHotkeysHelp, StrctHotkeysService, StrctIcon, StrctInlineEdit, StrctInput, StrctInputMask, StrctInputOtp, StrctKbd, StrctKnob, StrctList, StrctListItem, StrctListItemDescription, StrctListItemLeading, StrctListItemMeta, StrctListItemTrailing, StrctLiveIndicator, StrctLogViewer, StrctLogin, StrctMenuPanel, StrctMenuService, StrctMenubar, StrctMetricTile, StrctModal, StrctModalContent, StrctNav, StrctNavItem, StrctNotificationCenter, StrctNumber, StrctOverlay, StrctPageHeader, StrctPageHeaderActions, StrctPageHeaderCrumbs, StrctPageHeaderTitleMeta, StrctPagination, StrctPassword, StrctPopover, StrctPopoverTrigger, StrctProgress, StrctRadio, StrctRadioGroup, StrctRail, StrctRange, StrctRatePipe, StrctRating, StrctReorder, StrctReorderItem, StrctRowDetailDef, StrctSearchbox, StrctSectionHeader, StrctSectionHeaderActions, StrctSectionHeaderMeta, StrctSectionMenu, StrctSegmented, StrctSelect, StrctShell, StrctShellService, StrctSiPipe, StrctSignpost, StrctSignpostTrigger, StrctSkeleton, StrctSparkline, StrctSpeedDial, StrctSpinner, StrctSplitButton, StrctSplitter, StrctStack, StrctStackItem, StrctStatusDot, StrctStep, StrctSubmenu, StrctTab, StrctTable, StrctTabs, StrctTag, StrctTagLeading, StrctThemeService, StrctThemeSwitcher, StrctTimeRangePicker, StrctTimeline, StrctTimelineItem, StrctToastOutlet, StrctToastService, StrctToggle, StrctToolbar, StrctToolbarCaption, StrctToolbarSpacer, StrctTooltip, StrctTour, StrctTransfer, StrctTree, StrctTreeNode, StrctTreeSelect, StrctVerticalNav, StrctWatermark, StrctWizard, StrctWizardAside, focusFirstIn, keepTabInside, lockBodyScroll, parseAnsi, provideStrctWizardDefaults, registerStrctIcon, restoreFocus, saveFocusedElement, strctComputeDiff, strctDpPad, strctFormatBytes, strctFormatDuration, strctFormatRate, strctFormatSi, strctValidationIcon, strctValidationTone, unlockBodyScroll };
|
|
23751
23934
|
//# sourceMappingURL=akcelik-strct.mjs.map
|