@rivet-health/design-system 42.0.1 → 42.0.2
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.
|
@@ -1334,13 +1334,19 @@ var SVGTextTruncateDirective = class SVGTextTruncateDirective extends TooltipDir
|
|
|
1334
1334
|
this.applicationRef = applicationRef;
|
|
1335
1335
|
this.text = "";
|
|
1336
1336
|
this.width = 50;
|
|
1337
|
+
this.truncated = false;
|
|
1337
1338
|
}
|
|
1338
|
-
|
|
1339
|
-
this.
|
|
1339
|
+
ngOnChanges() {
|
|
1340
|
+
this.truncated = false;
|
|
1341
|
+
}
|
|
1342
|
+
ngAfterViewChecked() {
|
|
1343
|
+
if (!this.truncated) this.svgTruncate(this.el.nativeElement);
|
|
1340
1344
|
}
|
|
1341
1345
|
svgTruncate(element) {
|
|
1346
|
+
if (element.getClientRects().length === 0) return;
|
|
1342
1347
|
element.textContent = this.text;
|
|
1343
1348
|
let currentLength = element.textContent.length;
|
|
1349
|
+
this.truncated = true;
|
|
1344
1350
|
if (currentLength > 0 && element.getComputedTextLength() <= this.width) {
|
|
1345
1351
|
element.textContent = this.text;
|
|
1346
1352
|
this.rivTooltip = "";
|
|
@@ -1379,6 +1385,7 @@ var SVGTextTruncateDirective = class SVGTextTruncateDirective extends TooltipDir
|
|
|
1379
1385
|
width: "width"
|
|
1380
1386
|
},
|
|
1381
1387
|
usesInheritance: true,
|
|
1388
|
+
usesOnChanges: true,
|
|
1382
1389
|
ngImport: i0
|
|
1383
1390
|
});
|
|
1384
1391
|
}
|
|
@@ -4028,7 +4035,7 @@ var HighlightComponent = class HighlightComponent {
|
|
|
4028
4035
|
}
|
|
4029
4036
|
static {
|
|
4030
4037
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
4031
|
-
minVersion: "
|
|
4038
|
+
minVersion: "17.0.0",
|
|
4032
4039
|
version: "22.2.4",
|
|
4033
4040
|
type: HighlightComponent,
|
|
4034
4041
|
isStandalone: false,
|
|
@@ -4038,18 +4045,8 @@ var HighlightComponent = class HighlightComponent {
|
|
|
4038
4045
|
indices: "indices"
|
|
4039
4046
|
},
|
|
4040
4047
|
ngImport: i0,
|
|
4041
|
-
template: "
|
|
4048
|
+
template: "@for (chunk of getChunks(); track $index) {\n <span [class.highlight]=\"chunk.highlight\">{{ chunk.text }}</span>\n}\n",
|
|
4042
4049
|
styles: [".highlight{background-color:var(--baloo-10);border-radius:var(--border-radius-medium)}\n"],
|
|
4043
|
-
dependencies: [{
|
|
4044
|
-
kind: "directive",
|
|
4045
|
-
type: i1.NgForOf,
|
|
4046
|
-
selector: "[ngFor][ngForOf]",
|
|
4047
|
-
inputs: [
|
|
4048
|
-
"ngForOf",
|
|
4049
|
-
"ngForTrackBy",
|
|
4050
|
-
"ngForTemplate"
|
|
4051
|
-
]
|
|
4052
|
-
}],
|
|
4053
4050
|
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
4054
4051
|
});
|
|
4055
4052
|
}
|
|
@@ -4065,7 +4062,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
4065
4062
|
selector: "riv-highlight",
|
|
4066
4063
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
4067
4064
|
standalone: false,
|
|
4068
|
-
template: "
|
|
4065
|
+
template: "@for (chunk of getChunks(); track $index) {\n <span [class.highlight]=\"chunk.highlight\">{{ chunk.text }}</span>\n}\n",
|
|
4069
4066
|
styles: [".highlight{background-color:var(--baloo-10);border-radius:var(--border-radius-medium)}\n"]
|
|
4070
4067
|
}]
|
|
4071
4068
|
}],
|
|
@@ -4268,7 +4265,7 @@ var ZeroStateComponent = class ZeroStateComponent {
|
|
|
4268
4265
|
}
|
|
4269
4266
|
static {
|
|
4270
4267
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
4271
|
-
minVersion: "
|
|
4268
|
+
minVersion: "17.0.0",
|
|
4272
4269
|
version: "22.2.4",
|
|
4273
4270
|
type: ZeroStateComponent,
|
|
4274
4271
|
isStandalone: false,
|
|
@@ -4279,18 +4276,9 @@ var ZeroStateComponent = class ZeroStateComponent {
|
|
|
4279
4276
|
icon: "icon"
|
|
4280
4277
|
},
|
|
4281
4278
|
ngImport: i0,
|
|
4282
|
-
template: "
|
|
4279
|
+
template: "@if (icon; as i) {\n <riv-icon [name]=\"i\" [customSize]=\"40\"></riv-icon>\n}\n@if (title; as t) {\n <span class=\"title\">{{ t }}</span>\n}\n<span class=\"message\">{{ message }}</span>\n",
|
|
4283
4280
|
styles: [":host{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:var(--size-medium);font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0);color:var(--type-light-high-contrast);padding:var(--size-large);min-height:100%}.title{font:var(--title-02)}.message{color:var(--type-light-low-contrast)}\n"],
|
|
4284
4281
|
dependencies: [{
|
|
4285
|
-
kind: "directive",
|
|
4286
|
-
type: i1.NgIf,
|
|
4287
|
-
selector: "[ngIf]",
|
|
4288
|
-
inputs: [
|
|
4289
|
-
"ngIf",
|
|
4290
|
-
"ngIfThen",
|
|
4291
|
-
"ngIfElse"
|
|
4292
|
-
]
|
|
4293
|
-
}, {
|
|
4294
4282
|
kind: "component",
|
|
4295
4283
|
type: IconComponent,
|
|
4296
4284
|
selector: "riv-icon",
|
|
@@ -4317,7 +4305,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
4317
4305
|
selector: "riv-zero-state",
|
|
4318
4306
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
4319
4307
|
standalone: false,
|
|
4320
|
-
template: "
|
|
4308
|
+
template: "@if (icon; as i) {\n <riv-icon [name]=\"i\" [customSize]=\"40\"></riv-icon>\n}\n@if (title; as t) {\n <span class=\"title\">{{ t }}</span>\n}\n<span class=\"message\">{{ message }}</span>\n",
|
|
4321
4309
|
styles: [":host{display:flex;flex-direction:column;justify-content:center;align-items:center;gap:var(--size-medium);font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0);color:var(--type-light-high-contrast);padding:var(--size-large);min-height:100%}.title{font:var(--title-02)}.message{color:var(--type-light-low-contrast)}\n"]
|
|
4322
4310
|
}]
|
|
4323
4311
|
}],
|
|
@@ -19355,7 +19343,7 @@ var IssueComponent = class IssueComponent {
|
|
|
19355
19343
|
}
|
|
19356
19344
|
static {
|
|
19357
19345
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
19358
|
-
minVersion: "
|
|
19346
|
+
minVersion: "17.0.0",
|
|
19359
19347
|
version: "22.2.4",
|
|
19360
19348
|
type: IssueComponent,
|
|
19361
19349
|
isStandalone: false,
|
|
@@ -19366,18 +19354,9 @@ var IssueComponent = class IssueComponent {
|
|
|
19366
19354
|
textColorOverride: "textColorOverride"
|
|
19367
19355
|
},
|
|
19368
19356
|
ngImport: i0,
|
|
19369
|
-
template: "<i [style.background-color]=\"backgroundColor\"></i>\n
|
|
19357
|
+
template: "<i [style.background-color]=\"backgroundColor\"></i>\n@if (label) {\n <span [style.color]=\"textColor\" rivTruncate>{{ label }}</span>\n}\n",
|
|
19370
19358
|
styles: [":host{display:flex;align-items:center;gap:var(--size-xsmall)}i{width:var(--size-small);min-width:var(--size-small);height:var(--size-small);min-height:var(--size-small);border-radius:var(--border-radius-small)}span{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0)}\n"],
|
|
19371
19359
|
dependencies: [{
|
|
19372
|
-
kind: "directive",
|
|
19373
|
-
type: i1.NgIf,
|
|
19374
|
-
selector: "[ngIf]",
|
|
19375
|
-
inputs: [
|
|
19376
|
-
"ngIf",
|
|
19377
|
-
"ngIfThen",
|
|
19378
|
-
"ngIfElse"
|
|
19379
|
-
]
|
|
19380
|
-
}, {
|
|
19381
19360
|
kind: "component",
|
|
19382
19361
|
type: TruncateComponent,
|
|
19383
19362
|
selector: "[rivTruncate]",
|
|
@@ -19398,7 +19377,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
19398
19377
|
selector: "riv-issue",
|
|
19399
19378
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
19400
19379
|
standalone: false,
|
|
19401
|
-
template: "<i [style.background-color]=\"backgroundColor\"></i>\n
|
|
19380
|
+
template: "<i [style.background-color]=\"backgroundColor\"></i>\n@if (label) {\n <span [style.color]=\"textColor\" rivTruncate>{{ label }}</span>\n}\n",
|
|
19402
19381
|
styles: [":host{display:flex;align-items:center;gap:var(--size-xsmall)}i{width:var(--size-small);min-width:var(--size-small);height:var(--size-small);min-height:var(--size-small);border-radius:var(--border-radius-small)}span{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0)}\n"]
|
|
19403
19382
|
}]
|
|
19404
19383
|
}],
|
|
@@ -19436,7 +19415,7 @@ var LegendItemComponent = class LegendItemComponent {
|
|
|
19436
19415
|
}
|
|
19437
19416
|
static {
|
|
19438
19417
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
19439
|
-
minVersion: "
|
|
19418
|
+
minVersion: "17.0.0",
|
|
19440
19419
|
version: "22.2.4",
|
|
19441
19420
|
type: LegendItemComponent,
|
|
19442
19421
|
isStandalone: false,
|
|
@@ -19452,47 +19431,34 @@ var LegendItemComponent = class LegendItemComponent {
|
|
|
19452
19431
|
},
|
|
19453
19432
|
outputs: { itemClick: "itemClick" },
|
|
19454
19433
|
ngImport: i0,
|
|
19455
|
-
template: "<button\n (click)=\"isLegendItemClickable() ? itemClick.emit($event) : null\"\n [rivTooltip]=\"iconTooltip\"\n type=\"button\"\n [disabled]=\"visibility === 'locked'\"\n [attr.aria-disabled]=\"visibility === 'locked' ? 'true' : null\"\n [class.clickable]=\"clickable\"\n>\n
|
|
19434
|
+
template: "<button\n (click)=\"isLegendItemClickable() ? itemClick.emit($event) : null\"\n [rivTooltip]=\"iconTooltip\"\n type=\"button\"\n [disabled]=\"visibility === 'locked'\"\n [attr.aria-disabled]=\"visibility === 'locked' ? 'true' : null\"\n [class.clickable]=\"clickable\"\n>\n @if (visibility === 'visible') {\n <i\n [class.striped]=\"style === 'striped'\"\n [class.dots]=\"style === 'dots'\"\n [style.background-color]=\"style === 'dots' ? null : backgroundColor\"\n [style.--dot-color]=\"backgroundColor\"\n class=\"opacity-hover\"\n >\n @if (clickable && showCheckWhenClickable) {\n <riv-icon\n name=\"Check\"\n [size]=\"16\"\n [strokeWidth]=\"3\"\n style=\"color: var(--white-100)\"\n ></riv-icon>\n }\n </i>\n }\n @if (visibility === 'hidden') {\n <i\n class=\"hidden-legend-item opacity-hover\"\n [class.striped]=\"style === 'striped'\"\n [class.dots]=\"style === 'dots'\"\n [style.border-color]=\"backgroundColor\"\n [style.--background-color-hover]=\"backgroundColor\"\n [style.--dot-color]=\"backgroundColor\"\n ></i>\n }\n @if (visibility === 'locked') {\n <riv-icon name=\"Lock\" [size]=\"16\"></riv-icon>\n }\n\n @if (label) {\n <span\n [class.low-contrast]=\"visibility === 'hidden' || visibility === 'locked'\"\n >\n {{ label }}\n </span>\n }\n</button>\n",
|
|
19456
19435
|
styles: [":host{display:inline-flex;align-items:center;gap:var(--size-small)}i{width:var(--size-large);height:var(--size-large)}i.striped{background-image:repeating-linear-gradient(315deg,transparent 0px,transparent 2.5px,var(--white-100) 2.5px,var(--white-100) 3.5px,transparent 3.5px,transparent 6px)}i.dots{background-color:var(--white-100);background-image:radial-gradient(circle,var(--dot-color) 1.5px,transparent 1.5px);background-size:4px 4px}span{color:var(--type-light-low-contrast);font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0)}button{display:inline-flex;gap:var(--size-small);align-items:center;cursor:default}.hidden-legend-item{border-width:var(--border-width);border-style:solid;background-color:transparent}.hidden-legend-item.dots{background-image:none}button:hover.clickable .hidden-legend-item{background-color:var(--background-color-hover)}button:hover.clickable .hidden-legend-item.dots{border:none;background-color:var(--white-100);background-image:radial-gradient(circle,var(--dot-color) 1.5px,transparent 1.5px);background-size:4px 4px}button:not([disabled]).clickable:hover{cursor:pointer}button:not([disabled]).clickable:hover .opacity-hover{opacity:.6}button[disabled]{cursor:not-allowed}button[disabled] .low-contrast{color:var(--type-light-disabled)}button:not(:hover) .low-contrast{color:var(--type-light-disabled)}button:not(.clickable):hover .low-contrast{color:var(--type-light-disabled)}\n"],
|
|
19457
|
-
dependencies: [
|
|
19458
|
-
|
|
19459
|
-
|
|
19460
|
-
|
|
19461
|
-
|
|
19462
|
-
|
|
19463
|
-
|
|
19464
|
-
|
|
19465
|
-
|
|
19466
|
-
|
|
19467
|
-
|
|
19468
|
-
|
|
19469
|
-
|
|
19470
|
-
|
|
19471
|
-
|
|
19472
|
-
|
|
19473
|
-
|
|
19474
|
-
|
|
19475
|
-
|
|
19476
|
-
|
|
19477
|
-
|
|
19478
|
-
|
|
19479
|
-
|
|
19480
|
-
|
|
19481
|
-
|
|
19482
|
-
|
|
19483
|
-
selector: "[rivTooltip]",
|
|
19484
|
-
inputs: [
|
|
19485
|
-
"rivTooltip",
|
|
19486
|
-
"rivTooltipTheme",
|
|
19487
|
-
"rivTooltipMaxWidth",
|
|
19488
|
-
"rivTooltipPreferredPosition",
|
|
19489
|
-
"rivTooltipAnchor",
|
|
19490
|
-
"rivTooltipCloseDelay",
|
|
19491
|
-
"rivTooltipOpenDelay",
|
|
19492
|
-
"rivTooltipGracePeriod"
|
|
19493
|
-
]
|
|
19494
|
-
}
|
|
19495
|
-
],
|
|
19436
|
+
dependencies: [{
|
|
19437
|
+
kind: "component",
|
|
19438
|
+
type: IconComponent,
|
|
19439
|
+
selector: "riv-icon",
|
|
19440
|
+
inputs: [
|
|
19441
|
+
"name",
|
|
19442
|
+
"fillColor",
|
|
19443
|
+
"size",
|
|
19444
|
+
"customSize",
|
|
19445
|
+
"strokeWidth"
|
|
19446
|
+
]
|
|
19447
|
+
}, {
|
|
19448
|
+
kind: "directive",
|
|
19449
|
+
type: TooltipDirective,
|
|
19450
|
+
selector: "[rivTooltip]",
|
|
19451
|
+
inputs: [
|
|
19452
|
+
"rivTooltip",
|
|
19453
|
+
"rivTooltipTheme",
|
|
19454
|
+
"rivTooltipMaxWidth",
|
|
19455
|
+
"rivTooltipPreferredPosition",
|
|
19456
|
+
"rivTooltipAnchor",
|
|
19457
|
+
"rivTooltipCloseDelay",
|
|
19458
|
+
"rivTooltipOpenDelay",
|
|
19459
|
+
"rivTooltipGracePeriod"
|
|
19460
|
+
]
|
|
19461
|
+
}],
|
|
19496
19462
|
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
19497
19463
|
});
|
|
19498
19464
|
}
|
|
@@ -19508,7 +19474,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
19508
19474
|
selector: "riv-legend-item",
|
|
19509
19475
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
19510
19476
|
standalone: false,
|
|
19511
|
-
template: "<button\n (click)=\"isLegendItemClickable() ? itemClick.emit($event) : null\"\n [rivTooltip]=\"iconTooltip\"\n type=\"button\"\n [disabled]=\"visibility === 'locked'\"\n [attr.aria-disabled]=\"visibility === 'locked' ? 'true' : null\"\n [class.clickable]=\"clickable\"\n>\n
|
|
19477
|
+
template: "<button\n (click)=\"isLegendItemClickable() ? itemClick.emit($event) : null\"\n [rivTooltip]=\"iconTooltip\"\n type=\"button\"\n [disabled]=\"visibility === 'locked'\"\n [attr.aria-disabled]=\"visibility === 'locked' ? 'true' : null\"\n [class.clickable]=\"clickable\"\n>\n @if (visibility === 'visible') {\n <i\n [class.striped]=\"style === 'striped'\"\n [class.dots]=\"style === 'dots'\"\n [style.background-color]=\"style === 'dots' ? null : backgroundColor\"\n [style.--dot-color]=\"backgroundColor\"\n class=\"opacity-hover\"\n >\n @if (clickable && showCheckWhenClickable) {\n <riv-icon\n name=\"Check\"\n [size]=\"16\"\n [strokeWidth]=\"3\"\n style=\"color: var(--white-100)\"\n ></riv-icon>\n }\n </i>\n }\n @if (visibility === 'hidden') {\n <i\n class=\"hidden-legend-item opacity-hover\"\n [class.striped]=\"style === 'striped'\"\n [class.dots]=\"style === 'dots'\"\n [style.border-color]=\"backgroundColor\"\n [style.--background-color-hover]=\"backgroundColor\"\n [style.--dot-color]=\"backgroundColor\"\n ></i>\n }\n @if (visibility === 'locked') {\n <riv-icon name=\"Lock\" [size]=\"16\"></riv-icon>\n }\n\n @if (label) {\n <span\n [class.low-contrast]=\"visibility === 'hidden' || visibility === 'locked'\"\n >\n {{ label }}\n </span>\n }\n</button>\n",
|
|
19512
19478
|
styles: [":host{display:inline-flex;align-items:center;gap:var(--size-small)}i{width:var(--size-large);height:var(--size-large)}i.striped{background-image:repeating-linear-gradient(315deg,transparent 0px,transparent 2.5px,var(--white-100) 2.5px,var(--white-100) 3.5px,transparent 3.5px,transparent 6px)}i.dots{background-color:var(--white-100);background-image:radial-gradient(circle,var(--dot-color) 1.5px,transparent 1.5px);background-size:4px 4px}span{color:var(--type-light-low-contrast);font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0)}button{display:inline-flex;gap:var(--size-small);align-items:center;cursor:default}.hidden-legend-item{border-width:var(--border-width);border-style:solid;background-color:transparent}.hidden-legend-item.dots{background-image:none}button:hover.clickable .hidden-legend-item{background-color:var(--background-color-hover)}button:hover.clickable .hidden-legend-item.dots{border:none;background-color:var(--white-100);background-image:radial-gradient(circle,var(--dot-color) 1.5px,transparent 1.5px);background-size:4px 4px}button:not([disabled]).clickable:hover{cursor:pointer}button:not([disabled]).clickable:hover .opacity-hover{opacity:.6}button[disabled]{cursor:not-allowed}button[disabled] .low-contrast{color:var(--type-light-disabled)}button:not(:hover) .low-contrast{color:var(--type-light-disabled)}button:not(.clickable):hover .low-contrast{color:var(--type-light-disabled)}\n"]
|
|
19513
19479
|
}]
|
|
19514
19480
|
}],
|
|
@@ -19942,7 +19908,7 @@ var ChartComponent = class ChartComponent {
|
|
|
19942
19908
|
}
|
|
19943
19909
|
static {
|
|
19944
19910
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
19945
|
-
minVersion: "
|
|
19911
|
+
minVersion: "17.0.0",
|
|
19946
19912
|
version: "22.2.4",
|
|
19947
19913
|
type: ChartComponent,
|
|
19948
19914
|
isStandalone: false,
|
|
@@ -19977,7 +19943,7 @@ var ChartComponent = class ChartComponent {
|
|
|
19977
19943
|
descendants: true
|
|
19978
19944
|
}],
|
|
19979
19945
|
ngImport: i0,
|
|
19980
|
-
template: "<div\n class=\"container\"\n (rivClientSize)=\"width = $event.width\"\n *ngIf=\"{ d: drawData$ | async } as vm\"\n [style.--override-font-size]=\"getFontSize(vm.d)\"\n>\n <ng-container\n *ngIf=\"\n !checkForNonDisplayState(vm.d) && (drawData$ | async);\n let d;\n else nonDisplayState\n \"\n >\n <div\n (mousemove)=\"mousemove($event, d.hover)\"\n (mouseleave)=\"mouseleave($event)\"\n (click)=\"click()\"\n #container\n class=\"sub-container\"\n [class.clickable]=\"isHoverClickable\"\n tabIndex=\"0\"\n [ngClass]=\"{ 'donut-container': config.type === 'donut' }\"\n [ngStyle]=\"{\n height: getSubcontainerHeight(d),\n width: getSubcontainerWidth(d),\n }\"\n >\n <svg:svg\n xmlns=\"http://www.w3.org/2000/svg\"\n [attr.viewBox]=\"d.viewBox\"\n [attr.height]=\"d.chartHeight\"\n [attr.width]=\"d.chartWidth\"\n >\n <defs>\n <!-- Stripe pattern -->\n <pattern\n id=\"stripes\"\n x=\"0\"\n y=\"0\"\n [attr.width]=\"10\"\n [attr.height]=\"10\"\n patternUnits=\"userSpaceOnUse\"\n >\n <line\n [attr.x1]=\"0\"\n [attr.y1]=\"10\"\n [attr.x2]=\"10\"\n [attr.y2]=\"0\"\n stroke=\"var(--white-100)\"\n stroke-width=\"1\"\n ></line>\n </pattern>\n </defs>\n <ng-container *ngIf=\"!(config.type === 'horizontal-bar')\">\n <g *ngFor=\"let tick of d.xTicks\" text-anchor=\"middle\">\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"getBottomLabelY(d)\"\n >\n {{ tick.label }}\n </text>\n </g>\n </ng-container>\n <ng-container *ngIf=\"config.type === 'horizontal-bar'\">\n <g *ngFor=\"let tick of d.xTicks\" text-anchor=\"left\">\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"d.chartSizingValues.fontSize\"\n >\n {{ tick.label }}\n </text>\n <line\n class=\"tick-line\"\n [attr.x1]=\"tick.x\"\n [attr.x2]=\"tick.x\"\n y1=\"0\"\n [attr.y2]=\"d.chartHeight\"\n ></line>\n <text\n *ngIf=\"tick.secondaryLabel\"\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"getBottomLabelY(d)\"\n >\n {{ tick.secondaryLabel }}\n </text>\n </g>\n </ng-container>\n <g *ngFor=\"let tick of d.yTicks\">\n <line\n *ngIf=\"!(config.type === 'horizontal-bar')\"\n class=\"tick-line\"\n [attr.y1]=\"tick.y\"\n [attr.y2]=\"tick.y\"\n x1=\"0\"\n [attr.x2]=\"d.chartWidth\"\n ></line>\n <text\n rivSVGTextTruncate\n [text]=\"tick.label\"\n [width]=\"\n config.type === 'horizontal-bar'\n ? d.chartSizingValues.leftBucketLabel\n : d.chartSizingValues.leftPadding\n \"\n class=\"tick-label\"\n [attr.y]=\"tick.y\"\n [attr.x]=\"0\"\n >\n {{ tick.label }}\n </text>\n <text\n *ngIf=\"tick.secondaryLabel\"\n rivSVGTextTruncate\n [text]=\"tick.secondaryLabel\"\n [width]=\"d.chartSizingValues.rightPadding\"\n class=\"tick-label\"\n [attr.y]=\"tick.y\"\n [attr.x]=\"d.chartWidth\"\n text-anchor=\"end\"\n >\n {{ tick.secondaryLabel }}\n </text>\n </g>\n <ng-container *ngIf=\"standardHoverDataGuard(hover) as hoverData\">\n <g\n *ngIf=\"config.type !== 'horizontal-bar' && config.type !== 'donut'\"\n >\n <line\n class=\"tick-line\"\n [attr.x1]=\"hoverData?.x\"\n [attr.x2]=\"hoverData?.x\"\n y1=\"0\"\n [attr.y2]=\"d.chartHeight\"\n stroke-width=\"2\"\n stroke-dasharray=\"4\"\n />\n </g>\n </ng-container>\n <g *ngFor=\"let bar of d.bars; let i = index\">\n <ng-container *ngFor=\"let rect of bar; let j = index\">\n <defs *ngIf=\"rect.pattern === 'dots'\">\n <pattern\n [attr.id]=\"'dots-' + i + '-' + j\"\n patternUnits=\"userSpaceOnUse\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n width=\"4\"\n height=\"4\"\n >\n <circle\n cx=\"2\"\n cy=\"2\"\n r=\"1.5\"\n [attr.fill]=\"varColor(d.colors, i)\"\n ></circle>\n </pattern>\n </defs>\n\n <rect\n *ngIf=\"rect.nonDisplay !== true\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"\n rect.pattern === 'dots'\n ? 'url(#dots-' + i + '-' + j + ')'\n : getBarColor(rect, d.colors, i, hover)\n \"\n [attr.stroke]=\"\n showBarBorders(rect, hover) ? varWrap('--black-100') : undefined\n \"\n [attr.stroke-width]=\"showBarBorders(rect, hover) ? 1 : undefined\"\n ></rect>\n <rect\n *ngIf=\"showNonDisplayRect(rect, hover)\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"transparent\"\n [attr.stroke]=\"varWrap('--black-100')\"\n [attr.stroke-width]=\"1\"\n ></rect>\n <rect\n *ngIf=\"rect.pattern === 'striped'\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"url(#stripes)\"\n ></rect>\n </ng-container>\n </g>\n <g *ngFor=\"let bar of d.horizontalBars; let i = index\">\n <ng-container *ngFor=\"let indBar of bar; let j = index\">\n <defs *ngIf=\"indBar.pattern === 'dots'\">\n <pattern\n [attr.id]=\"'dots-' + i + '-' + j\"\n patternUnits=\"userSpaceOnUse\"\n [attr.x]=\"indBar.x\"\n [attr.y]=\"indBar.y\"\n width=\"4\"\n height=\"4\"\n >\n <circle\n cx=\"2\"\n cy=\"2\"\n r=\"1.5\"\n [attr.fill]=\"varColor(d.colors, i)\"\n ></circle>\n </pattern>\n </defs>\n <path\n [attr.d]=\"indBar.horizontalBar\"\n [attr.fill]=\"\n indBar.pattern === 'dots'\n ? 'url(#dots-' + i + '-' + j + ')'\n : varColor(d.colors, i)\n \"\n [attr.stroke]=\"\n indBar.pattern === 'dots' ? 'none' : varColor(d.colors, i)\n \"\n [attr.stroke-width]=\"indBar.pattern === 'dots' ? 0 : 2\"\n />\n <path\n *ngIf=\"indBar.pattern === 'striped'\"\n [attr.d]=\"indBar.horizontalBar\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n fill=\"url(#stripes)\"\n stroke-width=\"0\"\n />\n </ng-container>\n </g>\n <g *ngFor=\"let gradient of d.gradients; let i = index\">\n <ng-container *ngFor=\"let rect of gradient; let j = index\">\n <defs>\n <linearGradient\n [attr.id]=\"'grad-' + i + '-' + j\"\n x1=\"0\"\n y1=\"0\"\n x2=\"0\"\n y2=\"1\"\n >\n <stop offset=\"0%\" [attr.stop-color]=\"varColor(d.colors, i)\" />\n <stop offset=\"100%\" stop-color=\"white\" />\n </linearGradient>\n </defs>\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"'url(#grad-' + i + '-' + j + ')'\"\n opacity=\"0.4\"\n ></rect>\n </ng-container>\n </g>\n <g *ngFor=\"let line of d.lines; let i = index\">\n <path\n [attr.d]=\"line.line\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n fill=\"none\"\n stroke-width=\"2\"\n [attr.stroke-linecap]=\"\n line.pattern === 'dots' ? 'round' : undefined\n \"\n [attr.stroke-linejoin]=\"\n line.pattern === 'dots' ? 'round' : undefined\n \"\n [attr.stroke-dasharray]=\"\n line.pattern === 'striped'\n ? '10 10'\n : line.pattern === 'dots'\n ? '0.25 7'\n : undefined\n \"\n ></path>\n </g>\n <g *ngFor=\"let lineSinglePointFallback of d.circles; let i = index\">\n <circle\n class=\"marker\"\n [attr.cx]=\"lineSinglePointFallback.cx\"\n [attr.cy]=\"lineSinglePointFallback.cy\"\n r=\"3.5\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></circle>\n </g>\n <g *ngFor=\"let line of d.lines; let i = index\">\n <ng-container *ngIf=\"standardHoverDataGuard(hover) as hoverData\">\n <circle\n class=\"marker\"\n *ngIf=\"config.groupedTooltip || i === hoverData?.visibleYIndex\"\n [attr.cx]=\"hoverData?.x\"\n [attr.cy]=\"hoverData?.ys?.[i]\"\n r=\"3.5\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></circle>\n </ng-container>\n </g>\n <g *ngFor=\"let area of d.areas; let i = index\">\n <path [attr.d]=\"area.area\" [attr.fill]=\"varColor(d.colors, i)\"></path>\n <path\n *ngIf=\"area.pattern === 'striped'\"\n [attr.d]=\"area.area\"\n fill=\"url(#stripes)\"\n ></path>\n </g>\n <g *ngFor=\"let area of d.areas; let i = index\">\n <ng-container *ngIf=\"standardHoverDataGuard(hover) as hoverData\">\n <circle\n class=\"marker\"\n *ngIf=\"config.groupedTooltip || i === hoverData?.visibleYIndex\"\n [attr.cx]=\"hoverData?.x\"\n [attr.cy]=\"hoverData?.ys?.[i]\"\n r=\"3.5\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></circle>\n </ng-container>\n </g>\n <g *ngFor=\"let wLine of d.waterfallLines\">\n <line\n class=\"waterfall-line\"\n [attr.x1]=\"wLine.x1\"\n [attr.x2]=\"wLine.x2\"\n [attr.y1]=\"wLine.y1\"\n [attr.y2]=\"wLine.y2\"\n stroke-width=\"1\"\n stroke-dasharray=\"6\"\n />\n </g>\n <path\n *ngFor=\"let path of d.arcs; let i = index\"\n [attr.d]=\"path\"\n [attr.fill]=\"varColor(d.colors, i)\"\n ></path>\n <g *ngFor=\"let dataLabel of d.dataLabels; let i = index\">\n <text\n *ngIf=\"config.showDataLabels && dataLabel.label\"\n [ngClass]=\"getDataLabelClass(dataLabel, config, hover)\"\n [attr.y]=\"dataLabel.yPos\"\n [attr.x]=\"dataLabel.xPos\"\n [attr.text-anchor]=\"dataLabel.anchor\"\n [attr.font-weight]=\"\n dataLabel.bold\n ? 'var(--font-weight-heavy)'\n : 'var(--font-weight-normal)'\n \"\n [attr.opacity]=\"getDataLabelOpacity(dataLabel, config, hover)\"\n >\n {{ dataLabel.label }}\n </text>\n <line\n *ngIf=\"dataLabel.line && config.showDataLabels\"\n [attr.y1]=\"dataLabel.line.y1\"\n [attr.y2]=\"dataLabel.line.y2\"\n [attr.x1]=\"dataLabel.line.x1\"\n [attr.x2]=\"dataLabel.line.x2\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></line>\n </g>\n <g *ngFor=\"let connection of d.flowConnections\">\n <path\n [attr.d]=\"connection.path\"\n [attr.fill]=\"getConnectionColor()\"\n [attr.opacity]=\"getConnectionOpacity(connection, hover)\"\n />\n </g>\n </svg:svg>\n <div *ngIf=\"config.type === 'donut'\" class=\"donut-display\">\n <div class=\"donut-value\" [ngClass]=\"config.donutDisplayInfo.size\">\n {{ config.donutDisplayInfo.displayValue }}\n </div>\n <div class=\"donut-label\">\n {{ config.donutDisplayInfo.displayLabel }}\n </div>\n </div>\n <ng-container *ngIf=\"standardHoverDataGuard(hover) as hoverData\">\n <riv-callout\n *riv-overlay\n class=\"hover-tooltip\"\n [anchor]=\"\n hoverData?.tooltip?.anchor ? hoverData.tooltip.anchor : null\n \"\n [isModal]=\"false\"\n [preferredPosition]=\"\n hoverData?.tooltip?.preferredPosition ?? 'center-right'\n \"\n [theme]=\"'light'\"\n >\n <ng-container *ngIf=\"tooltipTemplate; else defaultTooltip\">\n <ng-container\n *ngIf=\"hoverData\"\n [ngTemplateOutlet]=\"tooltipTemplate\"\n [ngTemplateOutletContext]=\"{\n xIndex: hoverData.xIndex,\n yIndex: hoverData.yIndex,\n isSuppValue: hoverData.isSuppValue,\n suppYIndex: hoverData.suppYIndex,\n isDropOff: hoverData.isDropOff,\n }\"\n ></ng-container>\n </ng-container>\n <ng-template #defaultTooltip>\n <div class=\"callout-content\">\n <div *ngIf=\"hoverData?.tooltip?.date\" class=\"callout-row\">\n {{ hoverData?.tooltip?.date }}\n </div>\n <div\n class=\"callout-row\"\n *ngFor=\"let metric of hoverData?.tooltip?.metrics\"\n >\n <span class=\"series-label\">\n <riv-legend-item\n [colorToken]=\"metric.color\"\n [style]=\"metric.pattern || 'solid'\"\n ></riv-legend-item>\n <span>{{ metric.label }}</span>\n </span>\n <span>{{ metric.value }}</span>\n </div>\n </div>\n </ng-template>\n </riv-callout>\n </ng-container>\n <ng-container *ngIf=\"flowHoverDataGuard(hover) as hoverData\">\n <riv-callout\n *riv-overlay\n class=\"hover-tooltip\"\n [anchor]=\"\n hoverData?.tooltip?.anchor ? hoverData.tooltip.anchor : null\n \"\n [isModal]=\"false\"\n [preferredPosition]=\"'top-center'\"\n [theme]=\"'light'\"\n >\n <div class=\"callout-content\">\n <div class=\"callout-row\">\n <ng-container *ngIf=\"hoverData?.hoverTarget === 'connection'\">\n <ng-container\n *ngIf=\"\n getBucketConfigInfo(hoverData, 'startId') as startConfig\n \"\n >\n <riv-issue\n [label]=\"startConfig.title\"\n [colorToken]=\"startConfig.color\"\n ></riv-issue>\n </ng-container>\n ->\n <ng-container\n *ngIf=\"getBucketConfigInfo(hoverData, 'endId') as endConfig\"\n >\n <riv-issue\n [label]=\"endConfig.title\"\n [colorToken]=\"endConfig.color\"\n ></riv-issue>\n </ng-container>\n </ng-container>\n <ng-container *ngIf=\"hoverData?.hoverTarget !== 'connection'\">\n <ng-container\n *ngIf=\"getBucketConfigInfo(hoverData, 'barId') as barConfig\"\n >\n <riv-issue\n [label]=\"barConfig.title\"\n [colorToken]=\"barConfig.color\"\n ></riv-issue>\n </ng-container>\n </ng-container>\n </div>\n <div\n *ngIf=\"hoverData?.tooltip?.subtitle\"\n class=\"callout-row flow-subtitle\"\n >\n {{ hoverData?.tooltip?.subtitle }}\n </div>\n </div>\n </riv-callout>\n </ng-container>\n </div>\n <legend *ngIf=\"d.data.type !== 'flow'\">\n <ng-container *ngIf=\"firstHiddenLegendItemIndex$ | async; let fi\">\n <ng-container *ngFor=\"let item of d.data.ys; let i = index\">\n <riv-legend-item\n *ngIf=\"i < fi.dataIndex && item.showLegendItem !== false\"\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n [colorToken]=\"getItemColor(item, i)\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n </ng-container>\n <ng-container\n *ngFor=\"let item of d.data.supplementaryYs; let i = index\"\n >\n <riv-legend-item\n *ngIf=\"i < fi.suppIndex && item.showLegendItem !== false\"\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n [colorToken]=\"getItemColor(item, i)\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n </ng-container>\n <div\n #moreTextContainer\n class=\"more-text-container\"\n (mouseover)=\"mouseoverLegend()\"\n (mouseleave)=\"mouseleaveLegend()\"\n (click)=\"moreClick()\"\n *ngIf=\"fi.hiddenCount\"\n >\n <span rivLink class=\"more-text\">\n +\n {{ fi.hiddenCount }} more\n </span>\n </div>\n <ng-container *ngIf=\"showMoreTooltip || lockShowMoreTooltip\">\n <riv-callout\n *riv-overlay\n [anchor]=\"\n $safeNavigationMigration(moreTextContainer?.nativeElement)\n \"\n [isModal]=\"lockShowMoreTooltip\"\n (close)=\"closeHandler()\"\n [preferredPosition]=\"'bottom-right'\"\n [theme]=\"'light'\"\n [showCaret]=\"false\"\n >\n <div class=\"legend-tooltip\">\n <ng-container *ngFor=\"let item of d.data.ys; let i = index\">\n <riv-legend-item\n *ngIf=\"i >= fi.dataIndex && item.showLegendItem !== false\"\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n [colorToken]=\"getItemColor(item, i)\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n </ng-container>\n <ng-container\n *ngFor=\"let item of d.data.supplementaryYs; let i = index\"\n >\n <riv-legend-item\n *ngIf=\"i >= fi.suppIndex && item.showLegendItem !== false\"\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [colorToken]=\"getItemColor(item, i)\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n </ng-container>\n </div>\n </riv-callout>\n </ng-container>\n </ng-container>\n </legend>\n </ng-container>\n</div>\n\n<ng-template #nonDisplayState>\n <ng-container *ngIf=\"checkForNonDisplayState(drawData$ | async); let type\">\n <riv-zero-state\n *ngIf=\"type === 'zeroState'\"\n [message]=\"config.zeroStateMessage\"\n ></riv-zero-state>\n <riv-zero-state\n *ngIf=\"type === 'sizingErrorState'\"\n [message]=\"config.sizingErrorStateMessage\"\n ></riv-zero-state>\n </ng-container>\n</ng-template>\n",
|
|
19946
|
+
template: "@if ({ d: drawData$ | async }; as vm) {\n <div\n class=\"container\"\n (rivClientSize)=\"width = $event.width\"\n [style.--override-font-size]=\"getFontSize(vm.d)\"\n >\n @if (!checkForNonDisplayState(vm.d) && (drawData$ | async); as d) {\n <div\n (mousemove)=\"mousemove($event, d.hover)\"\n (mouseleave)=\"mouseleave($event)\"\n (click)=\"click()\"\n #container\n class=\"sub-container\"\n [class.clickable]=\"isHoverClickable\"\n tabIndex=\"0\"\n [ngClass]=\"{ 'donut-container': config.type === 'donut' }\"\n [ngStyle]=\"{\n height: getSubcontainerHeight(d),\n width: getSubcontainerWidth(d),\n }\"\n >\n <svg:svg\n xmlns=\"http://www.w3.org/2000/svg\"\n [attr.viewBox]=\"d.viewBox\"\n [attr.height]=\"d.chartHeight\"\n [attr.width]=\"d.chartWidth\"\n >\n <defs>\n <!-- Stripe pattern -->\n <pattern\n id=\"stripes\"\n x=\"0\"\n y=\"0\"\n [attr.width]=\"10\"\n [attr.height]=\"10\"\n patternUnits=\"userSpaceOnUse\"\n >\n <line\n [attr.x1]=\"0\"\n [attr.y1]=\"10\"\n [attr.x2]=\"10\"\n [attr.y2]=\"0\"\n stroke=\"var(--white-100)\"\n stroke-width=\"1\"\n ></line>\n </pattern>\n </defs>\n @if (!(config.type === 'horizontal-bar')) {\n @for (tick of d.xTicks; track $index) {\n <g text-anchor=\"middle\">\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"getBottomLabelY(d)\"\n >\n {{ tick.label }}\n </text>\n </g>\n }\n }\n @if (config.type === 'horizontal-bar') {\n @for (tick of d.xTicks; track $index) {\n <g text-anchor=\"left\">\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"d.chartSizingValues.fontSize\"\n >\n {{ tick.label }}\n </text>\n <line\n class=\"tick-line\"\n [attr.x1]=\"tick.x\"\n [attr.x2]=\"tick.x\"\n y1=\"0\"\n [attr.y2]=\"d.chartHeight\"\n ></line>\n @if (tick.secondaryLabel) {\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"getBottomLabelY(d)\"\n >\n {{ tick.secondaryLabel }}\n </text>\n }\n </g>\n }\n }\n @for (tick of d.yTicks; track $index) {\n <g>\n @if (!(config.type === 'horizontal-bar')) {\n <line\n class=\"tick-line\"\n [attr.y1]=\"tick.y\"\n [attr.y2]=\"tick.y\"\n x1=\"0\"\n [attr.x2]=\"d.chartWidth\"\n ></line>\n }\n <text\n rivSVGTextTruncate\n [text]=\"tick.label\"\n [width]=\"\n config.type === 'horizontal-bar'\n ? d.chartSizingValues.leftBucketLabel\n : d.chartSizingValues.leftPadding\n \"\n class=\"tick-label\"\n [attr.y]=\"tick.y\"\n [attr.x]=\"0\"\n >\n {{ tick.label }}\n </text>\n @if (tick.secondaryLabel) {\n <text\n rivSVGTextTruncate\n [text]=\"tick.secondaryLabel\"\n [width]=\"d.chartSizingValues.rightPadding\"\n class=\"tick-label\"\n [attr.y]=\"tick.y\"\n [attr.x]=\"d.chartWidth\"\n text-anchor=\"end\"\n >\n {{ tick.secondaryLabel }}\n </text>\n }\n </g>\n }\n @if (standardHoverDataGuard(hover); as hoverData) {\n @if (config.type !== 'horizontal-bar' && config.type !== 'donut') {\n <g>\n <line\n class=\"tick-line\"\n [attr.x1]=\"hoverData?.x\"\n [attr.x2]=\"hoverData?.x\"\n y1=\"0\"\n [attr.y2]=\"d.chartHeight\"\n stroke-width=\"2\"\n stroke-dasharray=\"4\"\n />\n </g>\n }\n }\n @for (bar of d.bars; track $index; let i = $index) {\n <g>\n @for (rect of bar; track $index; let j = $index) {\n @if (rect.pattern === 'dots') {\n <defs>\n <pattern\n [attr.id]=\"'dots-' + i + '-' + j\"\n patternUnits=\"userSpaceOnUse\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n width=\"4\"\n height=\"4\"\n >\n <circle\n cx=\"2\"\n cy=\"2\"\n r=\"1.5\"\n [attr.fill]=\"varColor(d.colors, i)\"\n ></circle>\n </pattern>\n </defs>\n }\n @if (rect.nonDisplay !== true) {\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"\n rect.pattern === 'dots'\n ? 'url(#dots-' + i + '-' + j + ')'\n : getBarColor(rect, d.colors, i, hover)\n \"\n [attr.stroke]=\"\n showBarBorders(rect, hover)\n ? varWrap('--black-100')\n : undefined\n \"\n [attr.stroke-width]=\"\n showBarBorders(rect, hover) ? 1 : undefined\n \"\n ></rect>\n }\n @if (showNonDisplayRect(rect, hover)) {\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"transparent\"\n [attr.stroke]=\"varWrap('--black-100')\"\n [attr.stroke-width]=\"1\"\n ></rect>\n }\n @if (rect.pattern === 'striped') {\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"url(#stripes)\"\n ></rect>\n }\n }\n </g>\n }\n @for (bar of d.horizontalBars; track $index; let i = $index) {\n <g>\n @for (indBar of bar; track $index; let j = $index) {\n @if (indBar.pattern === 'dots') {\n <defs>\n <pattern\n [attr.id]=\"'dots-' + i + '-' + j\"\n patternUnits=\"userSpaceOnUse\"\n [attr.x]=\"indBar.x\"\n [attr.y]=\"indBar.y\"\n width=\"4\"\n height=\"4\"\n >\n <circle\n cx=\"2\"\n cy=\"2\"\n r=\"1.5\"\n [attr.fill]=\"varColor(d.colors, i)\"\n ></circle>\n </pattern>\n </defs>\n }\n <path\n [attr.d]=\"indBar.horizontalBar\"\n [attr.fill]=\"\n indBar.pattern === 'dots'\n ? 'url(#dots-' + i + '-' + j + ')'\n : varColor(d.colors, i)\n \"\n [attr.stroke]=\"\n indBar.pattern === 'dots' ? 'none' : varColor(d.colors, i)\n \"\n [attr.stroke-width]=\"indBar.pattern === 'dots' ? 0 : 2\"\n />\n @if (indBar.pattern === 'striped') {\n <path\n [attr.d]=\"indBar.horizontalBar\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n fill=\"url(#stripes)\"\n stroke-width=\"0\"\n />\n }\n }\n </g>\n }\n @for (gradient of d.gradients; track $index; let i = $index) {\n <g>\n @for (rect of gradient; track $index; let j = $index) {\n <defs>\n <linearGradient\n [attr.id]=\"'grad-' + i + '-' + j\"\n x1=\"0\"\n y1=\"0\"\n x2=\"0\"\n y2=\"1\"\n >\n <stop\n offset=\"0%\"\n [attr.stop-color]=\"varColor(d.colors, i)\"\n />\n <stop offset=\"100%\" stop-color=\"white\" />\n </linearGradient>\n </defs>\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"'url(#grad-' + i + '-' + j + ')'\"\n opacity=\"0.4\"\n ></rect>\n }\n </g>\n }\n @for (line of d.lines; track $index; let i = $index) {\n <g>\n <path\n [attr.d]=\"line.line\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n fill=\"none\"\n stroke-width=\"2\"\n [attr.stroke-linecap]=\"\n line.pattern === 'dots' ? 'round' : undefined\n \"\n [attr.stroke-linejoin]=\"\n line.pattern === 'dots' ? 'round' : undefined\n \"\n [attr.stroke-dasharray]=\"\n line.pattern === 'striped'\n ? '10 10'\n : line.pattern === 'dots'\n ? '0.25 7'\n : undefined\n \"\n ></path>\n </g>\n }\n @for (\n lineSinglePointFallback of d.circles;\n track $index;\n let i = $index\n ) {\n <g>\n <circle\n class=\"marker\"\n [attr.cx]=\"lineSinglePointFallback.cx\"\n [attr.cy]=\"lineSinglePointFallback.cy\"\n r=\"3.5\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></circle>\n </g>\n }\n @for (line of d.lines; track $index; let i = $index) {\n <g>\n @if (standardHoverDataGuard(hover); as hoverData) {\n @if (config.groupedTooltip || i === hoverData?.visibleYIndex) {\n <circle\n class=\"marker\"\n [attr.cx]=\"hoverData?.x\"\n [attr.cy]=\"hoverData?.ys?.[i]\"\n r=\"3.5\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></circle>\n }\n }\n </g>\n }\n @for (area of d.areas; track $index; let i = $index) {\n <g>\n <path\n [attr.d]=\"area.area\"\n [attr.fill]=\"varColor(d.colors, i)\"\n ></path>\n @if (area.pattern === 'striped') {\n <path [attr.d]=\"area.area\" fill=\"url(#stripes)\"></path>\n }\n </g>\n }\n @for (area of d.areas; track $index; let i = $index) {\n <g>\n @if (standardHoverDataGuard(hover); as hoverData) {\n @if (config.groupedTooltip || i === hoverData?.visibleYIndex) {\n <circle\n class=\"marker\"\n [attr.cx]=\"hoverData?.x\"\n [attr.cy]=\"hoverData?.ys?.[i]\"\n r=\"3.5\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></circle>\n }\n }\n </g>\n }\n @for (wLine of d.waterfallLines; track $index) {\n <g>\n <line\n class=\"waterfall-line\"\n [attr.x1]=\"wLine.x1\"\n [attr.x2]=\"wLine.x2\"\n [attr.y1]=\"wLine.y1\"\n [attr.y2]=\"wLine.y2\"\n stroke-width=\"1\"\n stroke-dasharray=\"6\"\n />\n </g>\n }\n @for (path of d.arcs; track $index; let i = $index) {\n <path [attr.d]=\"path\" [attr.fill]=\"varColor(d.colors, i)\"></path>\n }\n @for (dataLabel of d.dataLabels; track $index; let i = $index) {\n <g>\n @if (config.showDataLabels && dataLabel.label) {\n <text\n [ngClass]=\"getDataLabelClass(dataLabel, config, hover)\"\n [attr.y]=\"dataLabel.yPos\"\n [attr.x]=\"dataLabel.xPos\"\n [attr.text-anchor]=\"dataLabel.anchor\"\n [attr.font-weight]=\"\n dataLabel.bold\n ? 'var(--font-weight-heavy)'\n : 'var(--font-weight-normal)'\n \"\n [attr.opacity]=\"getDataLabelOpacity(dataLabel, config, hover)\"\n >\n {{ dataLabel.label }}\n </text>\n }\n @if (dataLabel.line && config.showDataLabels) {\n <line\n [attr.y1]=\"dataLabel.line.y1\"\n [attr.y2]=\"dataLabel.line.y2\"\n [attr.x1]=\"dataLabel.line.x1\"\n [attr.x2]=\"dataLabel.line.x2\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></line>\n }\n </g>\n }\n @for (connection of d.flowConnections; track $index) {\n <g>\n <path\n [attr.d]=\"connection.path\"\n [attr.fill]=\"getConnectionColor()\"\n [attr.opacity]=\"getConnectionOpacity(connection, hover)\"\n />\n </g>\n }\n </svg:svg>\n @if (config.type === 'donut') {\n <div class=\"donut-display\">\n <div class=\"donut-value\" [ngClass]=\"config.donutDisplayInfo.size\">\n {{ config.donutDisplayInfo.displayValue }}\n </div>\n <div class=\"donut-label\">\n {{ config.donutDisplayInfo.displayLabel }}\n </div>\n </div>\n }\n @if (standardHoverDataGuard(hover); as hoverData) {\n <riv-callout\n *riv-overlay\n class=\"hover-tooltip\"\n [anchor]=\"\n hoverData?.tooltip?.anchor ? hoverData.tooltip.anchor : null\n \"\n [isModal]=\"false\"\n [preferredPosition]=\"\n hoverData?.tooltip?.preferredPosition ?? 'center-right'\n \"\n [theme]=\"'light'\"\n >\n @if (tooltipTemplate) {\n @if (hoverData) {\n <ng-container\n [ngTemplateOutlet]=\"tooltipTemplate\"\n [ngTemplateOutletContext]=\"{\n xIndex: hoverData.xIndex,\n yIndex: hoverData.yIndex,\n isSuppValue: hoverData.isSuppValue,\n suppYIndex: hoverData.suppYIndex,\n isDropOff: hoverData.isDropOff,\n }\"\n ></ng-container>\n }\n } @else {\n <div class=\"callout-content\">\n @if (hoverData?.tooltip?.date) {\n <div class=\"callout-row\">\n {{ hoverData?.tooltip?.date }}\n </div>\n }\n @for (metric of hoverData?.tooltip?.metrics; track $index) {\n <div class=\"callout-row\">\n <span class=\"series-label\">\n <riv-legend-item\n [colorToken]=\"metric.color\"\n [style]=\"metric.pattern || 'solid'\"\n ></riv-legend-item>\n <span>{{ metric.label }}</span>\n </span>\n <span>{{ metric.value }}</span>\n </div>\n }\n </div>\n }\n </riv-callout>\n }\n @if (flowHoverDataGuard(hover); as hoverData) {\n <riv-callout\n *riv-overlay\n class=\"hover-tooltip\"\n [anchor]=\"\n hoverData?.tooltip?.anchor ? hoverData.tooltip.anchor : null\n \"\n [isModal]=\"false\"\n [preferredPosition]=\"'top-center'\"\n [theme]=\"'light'\"\n >\n <div class=\"callout-content\">\n <div class=\"callout-row\">\n @if (hoverData?.hoverTarget === 'connection') {\n @if (\n getBucketConfigInfo(hoverData, 'startId');\n as startConfig\n ) {\n <riv-issue\n [label]=\"startConfig.title\"\n [colorToken]=\"startConfig.color\"\n ></riv-issue>\n }\n ->\n @if (getBucketConfigInfo(hoverData, 'endId'); as endConfig) {\n <riv-issue\n [label]=\"endConfig.title\"\n [colorToken]=\"endConfig.color\"\n ></riv-issue>\n }\n } @else {\n @if (getBucketConfigInfo(hoverData, 'barId'); as barConfig) {\n <riv-issue\n [label]=\"barConfig.title\"\n [colorToken]=\"barConfig.color\"\n ></riv-issue>\n }\n }\n </div>\n @if (hoverData?.tooltip?.subtitle) {\n <div class=\"callout-row flow-subtitle\">\n {{ hoverData?.tooltip?.subtitle }}\n </div>\n }\n </div>\n </riv-callout>\n }\n </div>\n @if (d.data.type !== 'flow') {\n <legend>\n @if (firstHiddenLegendItemIndex$ | async; as fi) {\n @for (item of d.data.ys; track $index; let i = $index) {\n @if (i < fi.dataIndex && item.showLegendItem !== false) {\n <riv-legend-item\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n [colorToken]=\"getItemColor(item, i)\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n }\n }\n @for (\n item of d.data.supplementaryYs;\n track $index;\n let i = $index\n ) {\n @if (i < fi.suppIndex && item.showLegendItem !== false) {\n <riv-legend-item\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n [colorToken]=\"getItemColor(item, i)\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n }\n }\n @if (fi.hiddenCount) {\n <div\n #moreTextContainer\n class=\"more-text-container\"\n (mouseover)=\"mouseoverLegend()\"\n (mouseleave)=\"mouseleaveLegend()\"\n (click)=\"moreClick()\"\n >\n <span rivLink class=\"more-text\">\n +\n {{ fi.hiddenCount }} more\n </span>\n </div>\n }\n @if (showMoreTooltip || lockShowMoreTooltip) {\n <riv-callout\n *riv-overlay\n [anchor]=\"\n $safeNavigationMigration(moreTextContainer?.nativeElement)\n \"\n [isModal]=\"lockShowMoreTooltip\"\n (close)=\"closeHandler()\"\n [preferredPosition]=\"'bottom-right'\"\n [theme]=\"'light'\"\n [showCaret]=\"false\"\n >\n <div class=\"legend-tooltip\">\n @for (item of d.data.ys; track $index; let i = $index) {\n @if (i >= fi.dataIndex && item.showLegendItem !== false) {\n <riv-legend-item\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n [colorToken]=\"getItemColor(item, i)\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n }\n }\n @for (\n item of d.data.supplementaryYs;\n track $index;\n let i = $index\n ) {\n @if (i >= fi.suppIndex && item.showLegendItem !== false) {\n <riv-legend-item\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [colorToken]=\"getItemColor(item, i)\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n }\n }\n </div>\n </riv-callout>\n }\n }\n </legend>\n }\n } @else {\n @if (checkForNonDisplayState(drawData$ | async); as type) {\n @if (type === 'zeroState') {\n <riv-zero-state [message]=\"config.zeroStateMessage\"></riv-zero-state>\n }\n @if (type === 'sizingErrorState') {\n <riv-zero-state\n [message]=\"config.sizingErrorStateMessage\"\n ></riv-zero-state>\n }\n }\n }\n </div>\n}\n",
|
|
19981
19947
|
styles: [".container{-webkit-user-select:none;user-select:none;position:relative;display:flex;flex-direction:column;gap:var(--size-xlarge)}.tick-line{stroke:var(--gray-20)}.tick-label{font-size:var(--override-font-size);line-height:var(--type-1-line-height-0);fill:var(--type-light-low-contrast)}.marker{fill:var(--surface-light-0)}.hover-tooltip{pointer-events:none}.callout-content{padding:var(--size-medium) var(--size-xlarge);display:flex;flex-direction:column}.callout-row{white-space:nowrap;display:flex;padding:var(--size-medium) 0;gap:var(--size-medium);align-items:center;font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0)}.callout-row:not(:last-child){border-bottom:var(--border-width) solid var(--border-light)}.series-label{flex-grow:1;font-weight:var(--font-weight-heavy);display:flex;align-items:center;gap:var(--size-small)}legend{display:flex;flex-wrap:wrap;gap:var(--size-large);justify-content:flex-start;align-items:baseline;width:100%}.more-text-container{width:calc(var(--base-grid-size) * 15);height:var(--size-large)}.more-text{font-size:var(--type-1-font-size);top:calc(var(--base-grid-size) * -1);position:relative}.legend-tooltip{padding:var(--size-medium) var(--size-xlarge);display:flex;flex-direction:column;overflow-y:scroll;max-height:clamp(0px,60vh,600px)}.legend-tooltip>riv-legend-item{white-space:nowrap;display:flex;padding:var(--size-medium) 0;gap:var(--size-medium);align-items:center;line-height:var(--type-1-line-height-0)}.sub-container.clickable{cursor:pointer}.sub-container{display:grid;grid-template-rows:1fr;grid-template-columns:1fr;overflow:auto}.sub-container:not(.donut-container){justify-items:start;align-items:start}.sub-container.donut-container{justify-items:center;align-items:center}svg{grid-row:1 / 1;grid-column:1 / 1}.donut-display{grid-row:1 / 1;grid-column:1 / 1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--size-small)}.donut-label{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0);color:var(--type-light-low-contrast)}.donut-value,.donut-label{text-shadow:0 0 var(--size-small) var(--surface-light-0),0 0 var(--size-xsmall) var(--surface-light-0)}.donut-value.xsmall{font:var(--stat-xsmall)}.donut-value.small{font:var(--stat-small)}.donut-value.medium{font:var(--stat-medium)}.donut-value.large{font:var(--stat-large)}.data-label{fill:var(--type-light-high-contrast);font-size:var(--override-font-size)}.flow-data-label{text-decoration:underline;font-size:var(--override-font-size);cursor:pointer;fill:var(--type-light-link-hover)}.waterfall-line{stroke:var(--gray-60)}.flow-subtitle{font-weight:var(--font-weight-heavy)}\n"],
|
|
19982
19948
|
dependencies: [
|
|
19983
19949
|
{
|
|
@@ -19986,26 +19952,6 @@ var ChartComponent = class ChartComponent {
|
|
|
19986
19952
|
selector: "[ngClass]",
|
|
19987
19953
|
inputs: ["class", "ngClass"]
|
|
19988
19954
|
},
|
|
19989
|
-
{
|
|
19990
|
-
kind: "directive",
|
|
19991
|
-
type: i1.NgForOf,
|
|
19992
|
-
selector: "[ngFor][ngForOf]",
|
|
19993
|
-
inputs: [
|
|
19994
|
-
"ngForOf",
|
|
19995
|
-
"ngForTrackBy",
|
|
19996
|
-
"ngForTemplate"
|
|
19997
|
-
]
|
|
19998
|
-
},
|
|
19999
|
-
{
|
|
20000
|
-
kind: "directive",
|
|
20001
|
-
type: i1.NgIf,
|
|
20002
|
-
selector: "[ngIf]",
|
|
20003
|
-
inputs: [
|
|
20004
|
-
"ngIf",
|
|
20005
|
-
"ngIfThen",
|
|
20006
|
-
"ngIfElse"
|
|
20007
|
-
]
|
|
20008
|
-
},
|
|
20009
19955
|
{
|
|
20010
19956
|
kind: "directive",
|
|
20011
19957
|
type: i1.NgTemplateOutlet,
|
|
@@ -20121,7 +20067,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
20121
20067
|
selector: "riv-chart",
|
|
20122
20068
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
20123
20069
|
standalone: false,
|
|
20124
|
-
template: "<div\n class=\"container\"\n (rivClientSize)=\"width = $event.width\"\n *ngIf=\"{ d: drawData$ | async } as vm\"\n [style.--override-font-size]=\"getFontSize(vm.d)\"\n>\n <ng-container\n *ngIf=\"\n !checkForNonDisplayState(vm.d) && (drawData$ | async);\n let d;\n else nonDisplayState\n \"\n >\n <div\n (mousemove)=\"mousemove($event, d.hover)\"\n (mouseleave)=\"mouseleave($event)\"\n (click)=\"click()\"\n #container\n class=\"sub-container\"\n [class.clickable]=\"isHoverClickable\"\n tabIndex=\"0\"\n [ngClass]=\"{ 'donut-container': config.type === 'donut' }\"\n [ngStyle]=\"{\n height: getSubcontainerHeight(d),\n width: getSubcontainerWidth(d),\n }\"\n >\n <svg:svg\n xmlns=\"http://www.w3.org/2000/svg\"\n [attr.viewBox]=\"d.viewBox\"\n [attr.height]=\"d.chartHeight\"\n [attr.width]=\"d.chartWidth\"\n >\n <defs>\n <!-- Stripe pattern -->\n <pattern\n id=\"stripes\"\n x=\"0\"\n y=\"0\"\n [attr.width]=\"10\"\n [attr.height]=\"10\"\n patternUnits=\"userSpaceOnUse\"\n >\n <line\n [attr.x1]=\"0\"\n [attr.y1]=\"10\"\n [attr.x2]=\"10\"\n [attr.y2]=\"0\"\n stroke=\"var(--white-100)\"\n stroke-width=\"1\"\n ></line>\n </pattern>\n </defs>\n <ng-container *ngIf=\"!(config.type === 'horizontal-bar')\">\n <g *ngFor=\"let tick of d.xTicks\" text-anchor=\"middle\">\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"getBottomLabelY(d)\"\n >\n {{ tick.label }}\n </text>\n </g>\n </ng-container>\n <ng-container *ngIf=\"config.type === 'horizontal-bar'\">\n <g *ngFor=\"let tick of d.xTicks\" text-anchor=\"left\">\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"d.chartSizingValues.fontSize\"\n >\n {{ tick.label }}\n </text>\n <line\n class=\"tick-line\"\n [attr.x1]=\"tick.x\"\n [attr.x2]=\"tick.x\"\n y1=\"0\"\n [attr.y2]=\"d.chartHeight\"\n ></line>\n <text\n *ngIf=\"tick.secondaryLabel\"\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"getBottomLabelY(d)\"\n >\n {{ tick.secondaryLabel }}\n </text>\n </g>\n </ng-container>\n <g *ngFor=\"let tick of d.yTicks\">\n <line\n *ngIf=\"!(config.type === 'horizontal-bar')\"\n class=\"tick-line\"\n [attr.y1]=\"tick.y\"\n [attr.y2]=\"tick.y\"\n x1=\"0\"\n [attr.x2]=\"d.chartWidth\"\n ></line>\n <text\n rivSVGTextTruncate\n [text]=\"tick.label\"\n [width]=\"\n config.type === 'horizontal-bar'\n ? d.chartSizingValues.leftBucketLabel\n : d.chartSizingValues.leftPadding\n \"\n class=\"tick-label\"\n [attr.y]=\"tick.y\"\n [attr.x]=\"0\"\n >\n {{ tick.label }}\n </text>\n <text\n *ngIf=\"tick.secondaryLabel\"\n rivSVGTextTruncate\n [text]=\"tick.secondaryLabel\"\n [width]=\"d.chartSizingValues.rightPadding\"\n class=\"tick-label\"\n [attr.y]=\"tick.y\"\n [attr.x]=\"d.chartWidth\"\n text-anchor=\"end\"\n >\n {{ tick.secondaryLabel }}\n </text>\n </g>\n <ng-container *ngIf=\"standardHoverDataGuard(hover) as hoverData\">\n <g\n *ngIf=\"config.type !== 'horizontal-bar' && config.type !== 'donut'\"\n >\n <line\n class=\"tick-line\"\n [attr.x1]=\"hoverData?.x\"\n [attr.x2]=\"hoverData?.x\"\n y1=\"0\"\n [attr.y2]=\"d.chartHeight\"\n stroke-width=\"2\"\n stroke-dasharray=\"4\"\n />\n </g>\n </ng-container>\n <g *ngFor=\"let bar of d.bars; let i = index\">\n <ng-container *ngFor=\"let rect of bar; let j = index\">\n <defs *ngIf=\"rect.pattern === 'dots'\">\n <pattern\n [attr.id]=\"'dots-' + i + '-' + j\"\n patternUnits=\"userSpaceOnUse\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n width=\"4\"\n height=\"4\"\n >\n <circle\n cx=\"2\"\n cy=\"2\"\n r=\"1.5\"\n [attr.fill]=\"varColor(d.colors, i)\"\n ></circle>\n </pattern>\n </defs>\n\n <rect\n *ngIf=\"rect.nonDisplay !== true\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"\n rect.pattern === 'dots'\n ? 'url(#dots-' + i + '-' + j + ')'\n : getBarColor(rect, d.colors, i, hover)\n \"\n [attr.stroke]=\"\n showBarBorders(rect, hover) ? varWrap('--black-100') : undefined\n \"\n [attr.stroke-width]=\"showBarBorders(rect, hover) ? 1 : undefined\"\n ></rect>\n <rect\n *ngIf=\"showNonDisplayRect(rect, hover)\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"transparent\"\n [attr.stroke]=\"varWrap('--black-100')\"\n [attr.stroke-width]=\"1\"\n ></rect>\n <rect\n *ngIf=\"rect.pattern === 'striped'\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"url(#stripes)\"\n ></rect>\n </ng-container>\n </g>\n <g *ngFor=\"let bar of d.horizontalBars; let i = index\">\n <ng-container *ngFor=\"let indBar of bar; let j = index\">\n <defs *ngIf=\"indBar.pattern === 'dots'\">\n <pattern\n [attr.id]=\"'dots-' + i + '-' + j\"\n patternUnits=\"userSpaceOnUse\"\n [attr.x]=\"indBar.x\"\n [attr.y]=\"indBar.y\"\n width=\"4\"\n height=\"4\"\n >\n <circle\n cx=\"2\"\n cy=\"2\"\n r=\"1.5\"\n [attr.fill]=\"varColor(d.colors, i)\"\n ></circle>\n </pattern>\n </defs>\n <path\n [attr.d]=\"indBar.horizontalBar\"\n [attr.fill]=\"\n indBar.pattern === 'dots'\n ? 'url(#dots-' + i + '-' + j + ')'\n : varColor(d.colors, i)\n \"\n [attr.stroke]=\"\n indBar.pattern === 'dots' ? 'none' : varColor(d.colors, i)\n \"\n [attr.stroke-width]=\"indBar.pattern === 'dots' ? 0 : 2\"\n />\n <path\n *ngIf=\"indBar.pattern === 'striped'\"\n [attr.d]=\"indBar.horizontalBar\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n fill=\"url(#stripes)\"\n stroke-width=\"0\"\n />\n </ng-container>\n </g>\n <g *ngFor=\"let gradient of d.gradients; let i = index\">\n <ng-container *ngFor=\"let rect of gradient; let j = index\">\n <defs>\n <linearGradient\n [attr.id]=\"'grad-' + i + '-' + j\"\n x1=\"0\"\n y1=\"0\"\n x2=\"0\"\n y2=\"1\"\n >\n <stop offset=\"0%\" [attr.stop-color]=\"varColor(d.colors, i)\" />\n <stop offset=\"100%\" stop-color=\"white\" />\n </linearGradient>\n </defs>\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"'url(#grad-' + i + '-' + j + ')'\"\n opacity=\"0.4\"\n ></rect>\n </ng-container>\n </g>\n <g *ngFor=\"let line of d.lines; let i = index\">\n <path\n [attr.d]=\"line.line\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n fill=\"none\"\n stroke-width=\"2\"\n [attr.stroke-linecap]=\"\n line.pattern === 'dots' ? 'round' : undefined\n \"\n [attr.stroke-linejoin]=\"\n line.pattern === 'dots' ? 'round' : undefined\n \"\n [attr.stroke-dasharray]=\"\n line.pattern === 'striped'\n ? '10 10'\n : line.pattern === 'dots'\n ? '0.25 7'\n : undefined\n \"\n ></path>\n </g>\n <g *ngFor=\"let lineSinglePointFallback of d.circles; let i = index\">\n <circle\n class=\"marker\"\n [attr.cx]=\"lineSinglePointFallback.cx\"\n [attr.cy]=\"lineSinglePointFallback.cy\"\n r=\"3.5\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></circle>\n </g>\n <g *ngFor=\"let line of d.lines; let i = index\">\n <ng-container *ngIf=\"standardHoverDataGuard(hover) as hoverData\">\n <circle\n class=\"marker\"\n *ngIf=\"config.groupedTooltip || i === hoverData?.visibleYIndex\"\n [attr.cx]=\"hoverData?.x\"\n [attr.cy]=\"hoverData?.ys?.[i]\"\n r=\"3.5\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></circle>\n </ng-container>\n </g>\n <g *ngFor=\"let area of d.areas; let i = index\">\n <path [attr.d]=\"area.area\" [attr.fill]=\"varColor(d.colors, i)\"></path>\n <path\n *ngIf=\"area.pattern === 'striped'\"\n [attr.d]=\"area.area\"\n fill=\"url(#stripes)\"\n ></path>\n </g>\n <g *ngFor=\"let area of d.areas; let i = index\">\n <ng-container *ngIf=\"standardHoverDataGuard(hover) as hoverData\">\n <circle\n class=\"marker\"\n *ngIf=\"config.groupedTooltip || i === hoverData?.visibleYIndex\"\n [attr.cx]=\"hoverData?.x\"\n [attr.cy]=\"hoverData?.ys?.[i]\"\n r=\"3.5\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></circle>\n </ng-container>\n </g>\n <g *ngFor=\"let wLine of d.waterfallLines\">\n <line\n class=\"waterfall-line\"\n [attr.x1]=\"wLine.x1\"\n [attr.x2]=\"wLine.x2\"\n [attr.y1]=\"wLine.y1\"\n [attr.y2]=\"wLine.y2\"\n stroke-width=\"1\"\n stroke-dasharray=\"6\"\n />\n </g>\n <path\n *ngFor=\"let path of d.arcs; let i = index\"\n [attr.d]=\"path\"\n [attr.fill]=\"varColor(d.colors, i)\"\n ></path>\n <g *ngFor=\"let dataLabel of d.dataLabels; let i = index\">\n <text\n *ngIf=\"config.showDataLabels && dataLabel.label\"\n [ngClass]=\"getDataLabelClass(dataLabel, config, hover)\"\n [attr.y]=\"dataLabel.yPos\"\n [attr.x]=\"dataLabel.xPos\"\n [attr.text-anchor]=\"dataLabel.anchor\"\n [attr.font-weight]=\"\n dataLabel.bold\n ? 'var(--font-weight-heavy)'\n : 'var(--font-weight-normal)'\n \"\n [attr.opacity]=\"getDataLabelOpacity(dataLabel, config, hover)\"\n >\n {{ dataLabel.label }}\n </text>\n <line\n *ngIf=\"dataLabel.line && config.showDataLabels\"\n [attr.y1]=\"dataLabel.line.y1\"\n [attr.y2]=\"dataLabel.line.y2\"\n [attr.x1]=\"dataLabel.line.x1\"\n [attr.x2]=\"dataLabel.line.x2\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></line>\n </g>\n <g *ngFor=\"let connection of d.flowConnections\">\n <path\n [attr.d]=\"connection.path\"\n [attr.fill]=\"getConnectionColor()\"\n [attr.opacity]=\"getConnectionOpacity(connection, hover)\"\n />\n </g>\n </svg:svg>\n <div *ngIf=\"config.type === 'donut'\" class=\"donut-display\">\n <div class=\"donut-value\" [ngClass]=\"config.donutDisplayInfo.size\">\n {{ config.donutDisplayInfo.displayValue }}\n </div>\n <div class=\"donut-label\">\n {{ config.donutDisplayInfo.displayLabel }}\n </div>\n </div>\n <ng-container *ngIf=\"standardHoverDataGuard(hover) as hoverData\">\n <riv-callout\n *riv-overlay\n class=\"hover-tooltip\"\n [anchor]=\"\n hoverData?.tooltip?.anchor ? hoverData.tooltip.anchor : null\n \"\n [isModal]=\"false\"\n [preferredPosition]=\"\n hoverData?.tooltip?.preferredPosition ?? 'center-right'\n \"\n [theme]=\"'light'\"\n >\n <ng-container *ngIf=\"tooltipTemplate; else defaultTooltip\">\n <ng-container\n *ngIf=\"hoverData\"\n [ngTemplateOutlet]=\"tooltipTemplate\"\n [ngTemplateOutletContext]=\"{\n xIndex: hoverData.xIndex,\n yIndex: hoverData.yIndex,\n isSuppValue: hoverData.isSuppValue,\n suppYIndex: hoverData.suppYIndex,\n isDropOff: hoverData.isDropOff,\n }\"\n ></ng-container>\n </ng-container>\n <ng-template #defaultTooltip>\n <div class=\"callout-content\">\n <div *ngIf=\"hoverData?.tooltip?.date\" class=\"callout-row\">\n {{ hoverData?.tooltip?.date }}\n </div>\n <div\n class=\"callout-row\"\n *ngFor=\"let metric of hoverData?.tooltip?.metrics\"\n >\n <span class=\"series-label\">\n <riv-legend-item\n [colorToken]=\"metric.color\"\n [style]=\"metric.pattern || 'solid'\"\n ></riv-legend-item>\n <span>{{ metric.label }}</span>\n </span>\n <span>{{ metric.value }}</span>\n </div>\n </div>\n </ng-template>\n </riv-callout>\n </ng-container>\n <ng-container *ngIf=\"flowHoverDataGuard(hover) as hoverData\">\n <riv-callout\n *riv-overlay\n class=\"hover-tooltip\"\n [anchor]=\"\n hoverData?.tooltip?.anchor ? hoverData.tooltip.anchor : null\n \"\n [isModal]=\"false\"\n [preferredPosition]=\"'top-center'\"\n [theme]=\"'light'\"\n >\n <div class=\"callout-content\">\n <div class=\"callout-row\">\n <ng-container *ngIf=\"hoverData?.hoverTarget === 'connection'\">\n <ng-container\n *ngIf=\"\n getBucketConfigInfo(hoverData, 'startId') as startConfig\n \"\n >\n <riv-issue\n [label]=\"startConfig.title\"\n [colorToken]=\"startConfig.color\"\n ></riv-issue>\n </ng-container>\n ->\n <ng-container\n *ngIf=\"getBucketConfigInfo(hoverData, 'endId') as endConfig\"\n >\n <riv-issue\n [label]=\"endConfig.title\"\n [colorToken]=\"endConfig.color\"\n ></riv-issue>\n </ng-container>\n </ng-container>\n <ng-container *ngIf=\"hoverData?.hoverTarget !== 'connection'\">\n <ng-container\n *ngIf=\"getBucketConfigInfo(hoverData, 'barId') as barConfig\"\n >\n <riv-issue\n [label]=\"barConfig.title\"\n [colorToken]=\"barConfig.color\"\n ></riv-issue>\n </ng-container>\n </ng-container>\n </div>\n <div\n *ngIf=\"hoverData?.tooltip?.subtitle\"\n class=\"callout-row flow-subtitle\"\n >\n {{ hoverData?.tooltip?.subtitle }}\n </div>\n </div>\n </riv-callout>\n </ng-container>\n </div>\n <legend *ngIf=\"d.data.type !== 'flow'\">\n <ng-container *ngIf=\"firstHiddenLegendItemIndex$ | async; let fi\">\n <ng-container *ngFor=\"let item of d.data.ys; let i = index\">\n <riv-legend-item\n *ngIf=\"i < fi.dataIndex && item.showLegendItem !== false\"\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n [colorToken]=\"getItemColor(item, i)\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n </ng-container>\n <ng-container\n *ngFor=\"let item of d.data.supplementaryYs; let i = index\"\n >\n <riv-legend-item\n *ngIf=\"i < fi.suppIndex && item.showLegendItem !== false\"\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n [colorToken]=\"getItemColor(item, i)\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n </ng-container>\n <div\n #moreTextContainer\n class=\"more-text-container\"\n (mouseover)=\"mouseoverLegend()\"\n (mouseleave)=\"mouseleaveLegend()\"\n (click)=\"moreClick()\"\n *ngIf=\"fi.hiddenCount\"\n >\n <span rivLink class=\"more-text\">\n +\n {{ fi.hiddenCount }} more\n </span>\n </div>\n <ng-container *ngIf=\"showMoreTooltip || lockShowMoreTooltip\">\n <riv-callout\n *riv-overlay\n [anchor]=\"\n $safeNavigationMigration(moreTextContainer?.nativeElement)\n \"\n [isModal]=\"lockShowMoreTooltip\"\n (close)=\"closeHandler()\"\n [preferredPosition]=\"'bottom-right'\"\n [theme]=\"'light'\"\n [showCaret]=\"false\"\n >\n <div class=\"legend-tooltip\">\n <ng-container *ngFor=\"let item of d.data.ys; let i = index\">\n <riv-legend-item\n *ngIf=\"i >= fi.dataIndex && item.showLegendItem !== false\"\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n [colorToken]=\"getItemColor(item, i)\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n </ng-container>\n <ng-container\n *ngFor=\"let item of d.data.supplementaryYs; let i = index\"\n >\n <riv-legend-item\n *ngIf=\"i >= fi.suppIndex && item.showLegendItem !== false\"\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [colorToken]=\"getItemColor(item, i)\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n </ng-container>\n </div>\n </riv-callout>\n </ng-container>\n </ng-container>\n </legend>\n </ng-container>\n</div>\n\n<ng-template #nonDisplayState>\n <ng-container *ngIf=\"checkForNonDisplayState(drawData$ | async); let type\">\n <riv-zero-state\n *ngIf=\"type === 'zeroState'\"\n [message]=\"config.zeroStateMessage\"\n ></riv-zero-state>\n <riv-zero-state\n *ngIf=\"type === 'sizingErrorState'\"\n [message]=\"config.sizingErrorStateMessage\"\n ></riv-zero-state>\n </ng-container>\n</ng-template>\n",
|
|
20070
|
+
template: "@if ({ d: drawData$ | async }; as vm) {\n <div\n class=\"container\"\n (rivClientSize)=\"width = $event.width\"\n [style.--override-font-size]=\"getFontSize(vm.d)\"\n >\n @if (!checkForNonDisplayState(vm.d) && (drawData$ | async); as d) {\n <div\n (mousemove)=\"mousemove($event, d.hover)\"\n (mouseleave)=\"mouseleave($event)\"\n (click)=\"click()\"\n #container\n class=\"sub-container\"\n [class.clickable]=\"isHoverClickable\"\n tabIndex=\"0\"\n [ngClass]=\"{ 'donut-container': config.type === 'donut' }\"\n [ngStyle]=\"{\n height: getSubcontainerHeight(d),\n width: getSubcontainerWidth(d),\n }\"\n >\n <svg:svg\n xmlns=\"http://www.w3.org/2000/svg\"\n [attr.viewBox]=\"d.viewBox\"\n [attr.height]=\"d.chartHeight\"\n [attr.width]=\"d.chartWidth\"\n >\n <defs>\n <!-- Stripe pattern -->\n <pattern\n id=\"stripes\"\n x=\"0\"\n y=\"0\"\n [attr.width]=\"10\"\n [attr.height]=\"10\"\n patternUnits=\"userSpaceOnUse\"\n >\n <line\n [attr.x1]=\"0\"\n [attr.y1]=\"10\"\n [attr.x2]=\"10\"\n [attr.y2]=\"0\"\n stroke=\"var(--white-100)\"\n stroke-width=\"1\"\n ></line>\n </pattern>\n </defs>\n @if (!(config.type === 'horizontal-bar')) {\n @for (tick of d.xTicks; track $index) {\n <g text-anchor=\"middle\">\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"getBottomLabelY(d)\"\n >\n {{ tick.label }}\n </text>\n </g>\n }\n }\n @if (config.type === 'horizontal-bar') {\n @for (tick of d.xTicks; track $index) {\n <g text-anchor=\"left\">\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"d.chartSizingValues.fontSize\"\n >\n {{ tick.label }}\n </text>\n <line\n class=\"tick-line\"\n [attr.x1]=\"tick.x\"\n [attr.x2]=\"tick.x\"\n y1=\"0\"\n [attr.y2]=\"d.chartHeight\"\n ></line>\n @if (tick.secondaryLabel) {\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"getBottomLabelY(d)\"\n >\n {{ tick.secondaryLabel }}\n </text>\n }\n </g>\n }\n }\n @for (tick of d.yTicks; track $index) {\n <g>\n @if (!(config.type === 'horizontal-bar')) {\n <line\n class=\"tick-line\"\n [attr.y1]=\"tick.y\"\n [attr.y2]=\"tick.y\"\n x1=\"0\"\n [attr.x2]=\"d.chartWidth\"\n ></line>\n }\n <text\n rivSVGTextTruncate\n [text]=\"tick.label\"\n [width]=\"\n config.type === 'horizontal-bar'\n ? d.chartSizingValues.leftBucketLabel\n : d.chartSizingValues.leftPadding\n \"\n class=\"tick-label\"\n [attr.y]=\"tick.y\"\n [attr.x]=\"0\"\n >\n {{ tick.label }}\n </text>\n @if (tick.secondaryLabel) {\n <text\n rivSVGTextTruncate\n [text]=\"tick.secondaryLabel\"\n [width]=\"d.chartSizingValues.rightPadding\"\n class=\"tick-label\"\n [attr.y]=\"tick.y\"\n [attr.x]=\"d.chartWidth\"\n text-anchor=\"end\"\n >\n {{ tick.secondaryLabel }}\n </text>\n }\n </g>\n }\n @if (standardHoverDataGuard(hover); as hoverData) {\n @if (config.type !== 'horizontal-bar' && config.type !== 'donut') {\n <g>\n <line\n class=\"tick-line\"\n [attr.x1]=\"hoverData?.x\"\n [attr.x2]=\"hoverData?.x\"\n y1=\"0\"\n [attr.y2]=\"d.chartHeight\"\n stroke-width=\"2\"\n stroke-dasharray=\"4\"\n />\n </g>\n }\n }\n @for (bar of d.bars; track $index; let i = $index) {\n <g>\n @for (rect of bar; track $index; let j = $index) {\n @if (rect.pattern === 'dots') {\n <defs>\n <pattern\n [attr.id]=\"'dots-' + i + '-' + j\"\n patternUnits=\"userSpaceOnUse\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n width=\"4\"\n height=\"4\"\n >\n <circle\n cx=\"2\"\n cy=\"2\"\n r=\"1.5\"\n [attr.fill]=\"varColor(d.colors, i)\"\n ></circle>\n </pattern>\n </defs>\n }\n @if (rect.nonDisplay !== true) {\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"\n rect.pattern === 'dots'\n ? 'url(#dots-' + i + '-' + j + ')'\n : getBarColor(rect, d.colors, i, hover)\n \"\n [attr.stroke]=\"\n showBarBorders(rect, hover)\n ? varWrap('--black-100')\n : undefined\n \"\n [attr.stroke-width]=\"\n showBarBorders(rect, hover) ? 1 : undefined\n \"\n ></rect>\n }\n @if (showNonDisplayRect(rect, hover)) {\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"transparent\"\n [attr.stroke]=\"varWrap('--black-100')\"\n [attr.stroke-width]=\"1\"\n ></rect>\n }\n @if (rect.pattern === 'striped') {\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"url(#stripes)\"\n ></rect>\n }\n }\n </g>\n }\n @for (bar of d.horizontalBars; track $index; let i = $index) {\n <g>\n @for (indBar of bar; track $index; let j = $index) {\n @if (indBar.pattern === 'dots') {\n <defs>\n <pattern\n [attr.id]=\"'dots-' + i + '-' + j\"\n patternUnits=\"userSpaceOnUse\"\n [attr.x]=\"indBar.x\"\n [attr.y]=\"indBar.y\"\n width=\"4\"\n height=\"4\"\n >\n <circle\n cx=\"2\"\n cy=\"2\"\n r=\"1.5\"\n [attr.fill]=\"varColor(d.colors, i)\"\n ></circle>\n </pattern>\n </defs>\n }\n <path\n [attr.d]=\"indBar.horizontalBar\"\n [attr.fill]=\"\n indBar.pattern === 'dots'\n ? 'url(#dots-' + i + '-' + j + ')'\n : varColor(d.colors, i)\n \"\n [attr.stroke]=\"\n indBar.pattern === 'dots' ? 'none' : varColor(d.colors, i)\n \"\n [attr.stroke-width]=\"indBar.pattern === 'dots' ? 0 : 2\"\n />\n @if (indBar.pattern === 'striped') {\n <path\n [attr.d]=\"indBar.horizontalBar\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n fill=\"url(#stripes)\"\n stroke-width=\"0\"\n />\n }\n }\n </g>\n }\n @for (gradient of d.gradients; track $index; let i = $index) {\n <g>\n @for (rect of gradient; track $index; let j = $index) {\n <defs>\n <linearGradient\n [attr.id]=\"'grad-' + i + '-' + j\"\n x1=\"0\"\n y1=\"0\"\n x2=\"0\"\n y2=\"1\"\n >\n <stop\n offset=\"0%\"\n [attr.stop-color]=\"varColor(d.colors, i)\"\n />\n <stop offset=\"100%\" stop-color=\"white\" />\n </linearGradient>\n </defs>\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"'url(#grad-' + i + '-' + j + ')'\"\n opacity=\"0.4\"\n ></rect>\n }\n </g>\n }\n @for (line of d.lines; track $index; let i = $index) {\n <g>\n <path\n [attr.d]=\"line.line\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n fill=\"none\"\n stroke-width=\"2\"\n [attr.stroke-linecap]=\"\n line.pattern === 'dots' ? 'round' : undefined\n \"\n [attr.stroke-linejoin]=\"\n line.pattern === 'dots' ? 'round' : undefined\n \"\n [attr.stroke-dasharray]=\"\n line.pattern === 'striped'\n ? '10 10'\n : line.pattern === 'dots'\n ? '0.25 7'\n : undefined\n \"\n ></path>\n </g>\n }\n @for (\n lineSinglePointFallback of d.circles;\n track $index;\n let i = $index\n ) {\n <g>\n <circle\n class=\"marker\"\n [attr.cx]=\"lineSinglePointFallback.cx\"\n [attr.cy]=\"lineSinglePointFallback.cy\"\n r=\"3.5\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></circle>\n </g>\n }\n @for (line of d.lines; track $index; let i = $index) {\n <g>\n @if (standardHoverDataGuard(hover); as hoverData) {\n @if (config.groupedTooltip || i === hoverData?.visibleYIndex) {\n <circle\n class=\"marker\"\n [attr.cx]=\"hoverData?.x\"\n [attr.cy]=\"hoverData?.ys?.[i]\"\n r=\"3.5\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></circle>\n }\n }\n </g>\n }\n @for (area of d.areas; track $index; let i = $index) {\n <g>\n <path\n [attr.d]=\"area.area\"\n [attr.fill]=\"varColor(d.colors, i)\"\n ></path>\n @if (area.pattern === 'striped') {\n <path [attr.d]=\"area.area\" fill=\"url(#stripes)\"></path>\n }\n </g>\n }\n @for (area of d.areas; track $index; let i = $index) {\n <g>\n @if (standardHoverDataGuard(hover); as hoverData) {\n @if (config.groupedTooltip || i === hoverData?.visibleYIndex) {\n <circle\n class=\"marker\"\n [attr.cx]=\"hoverData?.x\"\n [attr.cy]=\"hoverData?.ys?.[i]\"\n r=\"3.5\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></circle>\n }\n }\n </g>\n }\n @for (wLine of d.waterfallLines; track $index) {\n <g>\n <line\n class=\"waterfall-line\"\n [attr.x1]=\"wLine.x1\"\n [attr.x2]=\"wLine.x2\"\n [attr.y1]=\"wLine.y1\"\n [attr.y2]=\"wLine.y2\"\n stroke-width=\"1\"\n stroke-dasharray=\"6\"\n />\n </g>\n }\n @for (path of d.arcs; track $index; let i = $index) {\n <path [attr.d]=\"path\" [attr.fill]=\"varColor(d.colors, i)\"></path>\n }\n @for (dataLabel of d.dataLabels; track $index; let i = $index) {\n <g>\n @if (config.showDataLabels && dataLabel.label) {\n <text\n [ngClass]=\"getDataLabelClass(dataLabel, config, hover)\"\n [attr.y]=\"dataLabel.yPos\"\n [attr.x]=\"dataLabel.xPos\"\n [attr.text-anchor]=\"dataLabel.anchor\"\n [attr.font-weight]=\"\n dataLabel.bold\n ? 'var(--font-weight-heavy)'\n : 'var(--font-weight-normal)'\n \"\n [attr.opacity]=\"getDataLabelOpacity(dataLabel, config, hover)\"\n >\n {{ dataLabel.label }}\n </text>\n }\n @if (dataLabel.line && config.showDataLabels) {\n <line\n [attr.y1]=\"dataLabel.line.y1\"\n [attr.y2]=\"dataLabel.line.y2\"\n [attr.x1]=\"dataLabel.line.x1\"\n [attr.x2]=\"dataLabel.line.x2\"\n stroke-width=\"2\"\n [attr.stroke]=\"varColor(d.colors, i)\"\n ></line>\n }\n </g>\n }\n @for (connection of d.flowConnections; track $index) {\n <g>\n <path\n [attr.d]=\"connection.path\"\n [attr.fill]=\"getConnectionColor()\"\n [attr.opacity]=\"getConnectionOpacity(connection, hover)\"\n />\n </g>\n }\n </svg:svg>\n @if (config.type === 'donut') {\n <div class=\"donut-display\">\n <div class=\"donut-value\" [ngClass]=\"config.donutDisplayInfo.size\">\n {{ config.donutDisplayInfo.displayValue }}\n </div>\n <div class=\"donut-label\">\n {{ config.donutDisplayInfo.displayLabel }}\n </div>\n </div>\n }\n @if (standardHoverDataGuard(hover); as hoverData) {\n <riv-callout\n *riv-overlay\n class=\"hover-tooltip\"\n [anchor]=\"\n hoverData?.tooltip?.anchor ? hoverData.tooltip.anchor : null\n \"\n [isModal]=\"false\"\n [preferredPosition]=\"\n hoverData?.tooltip?.preferredPosition ?? 'center-right'\n \"\n [theme]=\"'light'\"\n >\n @if (tooltipTemplate) {\n @if (hoverData) {\n <ng-container\n [ngTemplateOutlet]=\"tooltipTemplate\"\n [ngTemplateOutletContext]=\"{\n xIndex: hoverData.xIndex,\n yIndex: hoverData.yIndex,\n isSuppValue: hoverData.isSuppValue,\n suppYIndex: hoverData.suppYIndex,\n isDropOff: hoverData.isDropOff,\n }\"\n ></ng-container>\n }\n } @else {\n <div class=\"callout-content\">\n @if (hoverData?.tooltip?.date) {\n <div class=\"callout-row\">\n {{ hoverData?.tooltip?.date }}\n </div>\n }\n @for (metric of hoverData?.tooltip?.metrics; track $index) {\n <div class=\"callout-row\">\n <span class=\"series-label\">\n <riv-legend-item\n [colorToken]=\"metric.color\"\n [style]=\"metric.pattern || 'solid'\"\n ></riv-legend-item>\n <span>{{ metric.label }}</span>\n </span>\n <span>{{ metric.value }}</span>\n </div>\n }\n </div>\n }\n </riv-callout>\n }\n @if (flowHoverDataGuard(hover); as hoverData) {\n <riv-callout\n *riv-overlay\n class=\"hover-tooltip\"\n [anchor]=\"\n hoverData?.tooltip?.anchor ? hoverData.tooltip.anchor : null\n \"\n [isModal]=\"false\"\n [preferredPosition]=\"'top-center'\"\n [theme]=\"'light'\"\n >\n <div class=\"callout-content\">\n <div class=\"callout-row\">\n @if (hoverData?.hoverTarget === 'connection') {\n @if (\n getBucketConfigInfo(hoverData, 'startId');\n as startConfig\n ) {\n <riv-issue\n [label]=\"startConfig.title\"\n [colorToken]=\"startConfig.color\"\n ></riv-issue>\n }\n ->\n @if (getBucketConfigInfo(hoverData, 'endId'); as endConfig) {\n <riv-issue\n [label]=\"endConfig.title\"\n [colorToken]=\"endConfig.color\"\n ></riv-issue>\n }\n } @else {\n @if (getBucketConfigInfo(hoverData, 'barId'); as barConfig) {\n <riv-issue\n [label]=\"barConfig.title\"\n [colorToken]=\"barConfig.color\"\n ></riv-issue>\n }\n }\n </div>\n @if (hoverData?.tooltip?.subtitle) {\n <div class=\"callout-row flow-subtitle\">\n {{ hoverData?.tooltip?.subtitle }}\n </div>\n }\n </div>\n </riv-callout>\n }\n </div>\n @if (d.data.type !== 'flow') {\n <legend>\n @if (firstHiddenLegendItemIndex$ | async; as fi) {\n @for (item of d.data.ys; track $index; let i = $index) {\n @if (i < fi.dataIndex && item.showLegendItem !== false) {\n <riv-legend-item\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n [colorToken]=\"getItemColor(item, i)\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n }\n }\n @for (\n item of d.data.supplementaryYs;\n track $index;\n let i = $index\n ) {\n @if (i < fi.suppIndex && item.showLegendItem !== false) {\n <riv-legend-item\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n [colorToken]=\"getItemColor(item, i)\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n }\n }\n @if (fi.hiddenCount) {\n <div\n #moreTextContainer\n class=\"more-text-container\"\n (mouseover)=\"mouseoverLegend()\"\n (mouseleave)=\"mouseleaveLegend()\"\n (click)=\"moreClick()\"\n >\n <span rivLink class=\"more-text\">\n +\n {{ fi.hiddenCount }} more\n </span>\n </div>\n }\n @if (showMoreTooltip || lockShowMoreTooltip) {\n <riv-callout\n *riv-overlay\n [anchor]=\"\n $safeNavigationMigration(moreTextContainer?.nativeElement)\n \"\n [isModal]=\"lockShowMoreTooltip\"\n (close)=\"closeHandler()\"\n [preferredPosition]=\"'bottom-right'\"\n [theme]=\"'light'\"\n [showCaret]=\"false\"\n >\n <div class=\"legend-tooltip\">\n @for (item of d.data.ys; track $index; let i = $index) {\n @if (i >= fi.dataIndex && item.showLegendItem !== false) {\n <riv-legend-item\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n [colorToken]=\"getItemColor(item, i)\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n }\n }\n @for (\n item of d.data.supplementaryYs;\n track $index;\n let i = $index\n ) {\n @if (i >= fi.suppIndex && item.showLegendItem !== false) {\n <riv-legend-item\n [label]=\"item.label\"\n [style]=\"item.pattern || 'solid'\"\n [visibility]=\"item.hidden ? 'hidden' : 'visible'\"\n [colorToken]=\"getItemColor(item, i)\"\n [clickable]=\"config.allowLegendToggle\"\n [showCheckWhenClickable]=\"item.pattern !== 'dots'\"\n (itemClick)=\"toggleLegend(item, i)\"\n ></riv-legend-item>\n }\n }\n </div>\n </riv-callout>\n }\n }\n </legend>\n }\n } @else {\n @if (checkForNonDisplayState(drawData$ | async); as type) {\n @if (type === 'zeroState') {\n <riv-zero-state [message]=\"config.zeroStateMessage\"></riv-zero-state>\n }\n @if (type === 'sizingErrorState') {\n <riv-zero-state\n [message]=\"config.sizingErrorStateMessage\"\n ></riv-zero-state>\n }\n }\n }\n </div>\n}\n",
|
|
20125
20071
|
styles: [".container{-webkit-user-select:none;user-select:none;position:relative;display:flex;flex-direction:column;gap:var(--size-xlarge)}.tick-line{stroke:var(--gray-20)}.tick-label{font-size:var(--override-font-size);line-height:var(--type-1-line-height-0);fill:var(--type-light-low-contrast)}.marker{fill:var(--surface-light-0)}.hover-tooltip{pointer-events:none}.callout-content{padding:var(--size-medium) var(--size-xlarge);display:flex;flex-direction:column}.callout-row{white-space:nowrap;display:flex;padding:var(--size-medium) 0;gap:var(--size-medium);align-items:center;font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0)}.callout-row:not(:last-child){border-bottom:var(--border-width) solid var(--border-light)}.series-label{flex-grow:1;font-weight:var(--font-weight-heavy);display:flex;align-items:center;gap:var(--size-small)}legend{display:flex;flex-wrap:wrap;gap:var(--size-large);justify-content:flex-start;align-items:baseline;width:100%}.more-text-container{width:calc(var(--base-grid-size) * 15);height:var(--size-large)}.more-text{font-size:var(--type-1-font-size);top:calc(var(--base-grid-size) * -1);position:relative}.legend-tooltip{padding:var(--size-medium) var(--size-xlarge);display:flex;flex-direction:column;overflow-y:scroll;max-height:clamp(0px,60vh,600px)}.legend-tooltip>riv-legend-item{white-space:nowrap;display:flex;padding:var(--size-medium) 0;gap:var(--size-medium);align-items:center;line-height:var(--type-1-line-height-0)}.sub-container.clickable{cursor:pointer}.sub-container{display:grid;grid-template-rows:1fr;grid-template-columns:1fr;overflow:auto}.sub-container:not(.donut-container){justify-items:start;align-items:start}.sub-container.donut-container{justify-items:center;align-items:center}svg{grid-row:1 / 1;grid-column:1 / 1}.donut-display{grid-row:1 / 1;grid-column:1 / 1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--size-small)}.donut-label{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0);color:var(--type-light-low-contrast)}.donut-value,.donut-label{text-shadow:0 0 var(--size-small) var(--surface-light-0),0 0 var(--size-xsmall) var(--surface-light-0)}.donut-value.xsmall{font:var(--stat-xsmall)}.donut-value.small{font:var(--stat-small)}.donut-value.medium{font:var(--stat-medium)}.donut-value.large{font:var(--stat-large)}.data-label{fill:var(--type-light-high-contrast);font-size:var(--override-font-size)}.flow-data-label{text-decoration:underline;font-size:var(--override-font-size);cursor:pointer;fill:var(--type-light-link-hover)}.waterfall-line{stroke:var(--gray-60)}.flow-subtitle{font-weight:var(--font-weight-heavy)}\n"]
|
|
20126
20072
|
}]
|
|
20127
20073
|
}],
|
|
@@ -20378,7 +20324,7 @@ var DonutComponent = class DonutComponent {
|
|
|
20378
20324
|
}
|
|
20379
20325
|
static {
|
|
20380
20326
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
20381
|
-
minVersion: "
|
|
20327
|
+
minVersion: "17.0.0",
|
|
20382
20328
|
version: "22.2.4",
|
|
20383
20329
|
type: DonutComponent,
|
|
20384
20330
|
isStandalone: false,
|
|
@@ -20391,7 +20337,7 @@ var DonutComponent = class DonutComponent {
|
|
|
20391
20337
|
size: "size"
|
|
20392
20338
|
},
|
|
20393
20339
|
ngImport: i0,
|
|
20394
|
-
template: "
|
|
20340
|
+
template: "@if (!empty) {\n <div class=\"container\">\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"100%\"\n [attr.height]=\"HEIGHT\"\n viewBox=\"-128 -128 256 256\"\n >\n @for (path of arcPaths; track $index; let i = $index) {\n <path [attr.d]=\"path\" [attr.fill]=\"getFillStyle(i)\"></path>\n }\n </svg>\n <div class=\"display\">\n <div class=\"value\" [ngClass]=\"size\" [rivTooltip]=\"displayTooltip\">\n {{ displayValue }}\n </div>\n <div class=\"label\">{{ displayLabel }}</div>\n </div>\n </div>\n} @else {\n <riv-zero-state></riv-zero-state>\n}\n",
|
|
20395
20341
|
styles: [".container{display:grid;grid-template-rows:1fr;grid-template-columns:1fr;justify-items:center;align-items:center}svg{grid-row:1 / 1;grid-column:1 / 1}.display{grid-row:1 / 1;grid-column:1 / 1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--size-small)}.label{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0);color:var(--type-light-low-contrast)}.value,.label{text-shadow:0 0 var(--size-small) var(--surface-light-0),0 0 var(--size-xsmall) var(--surface-light-0)}.value.xsmall{font:var(--stat-xsmall)}.value.small{font:var(--stat-small)}.value.medium{font:var(--stat-medium)}.value.large{font:var(--stat-large)}\n"],
|
|
20396
20342
|
dependencies: [
|
|
20397
20343
|
{
|
|
@@ -20400,26 +20346,6 @@ var DonutComponent = class DonutComponent {
|
|
|
20400
20346
|
selector: "[ngClass]",
|
|
20401
20347
|
inputs: ["class", "ngClass"]
|
|
20402
20348
|
},
|
|
20403
|
-
{
|
|
20404
|
-
kind: "directive",
|
|
20405
|
-
type: i1.NgForOf,
|
|
20406
|
-
selector: "[ngFor][ngForOf]",
|
|
20407
|
-
inputs: [
|
|
20408
|
-
"ngForOf",
|
|
20409
|
-
"ngForTrackBy",
|
|
20410
|
-
"ngForTemplate"
|
|
20411
|
-
]
|
|
20412
|
-
},
|
|
20413
|
-
{
|
|
20414
|
-
kind: "directive",
|
|
20415
|
-
type: i1.NgIf,
|
|
20416
|
-
selector: "[ngIf]",
|
|
20417
|
-
inputs: [
|
|
20418
|
-
"ngIf",
|
|
20419
|
-
"ngIfThen",
|
|
20420
|
-
"ngIfElse"
|
|
20421
|
-
]
|
|
20422
|
-
},
|
|
20423
20349
|
{
|
|
20424
20350
|
kind: "directive",
|
|
20425
20351
|
type: TooltipDirective,
|
|
@@ -20461,7 +20387,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
20461
20387
|
selector: "riv-donut",
|
|
20462
20388
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
20463
20389
|
standalone: false,
|
|
20464
|
-
template: "
|
|
20390
|
+
template: "@if (!empty) {\n <div class=\"container\">\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n width=\"100%\"\n [attr.height]=\"HEIGHT\"\n viewBox=\"-128 -128 256 256\"\n >\n @for (path of arcPaths; track $index; let i = $index) {\n <path [attr.d]=\"path\" [attr.fill]=\"getFillStyle(i)\"></path>\n }\n </svg>\n <div class=\"display\">\n <div class=\"value\" [ngClass]=\"size\" [rivTooltip]=\"displayTooltip\">\n {{ displayValue }}\n </div>\n <div class=\"label\">{{ displayLabel }}</div>\n </div>\n </div>\n} @else {\n <riv-zero-state></riv-zero-state>\n}\n",
|
|
20465
20391
|
styles: [".container{display:grid;grid-template-rows:1fr;grid-template-columns:1fr;justify-items:center;align-items:center}svg{grid-row:1 / 1;grid-column:1 / 1}.display{grid-row:1 / 1;grid-column:1 / 1;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--size-small)}.label{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0);color:var(--type-light-low-contrast)}.value,.label{text-shadow:0 0 var(--size-small) var(--surface-light-0),0 0 var(--size-xsmall) var(--surface-light-0)}.value.xsmall{font:var(--stat-xsmall)}.value.small{font:var(--stat-small)}.value.medium{font:var(--stat-medium)}.value.large{font:var(--stat-large)}\n"]
|
|
20466
20392
|
}]
|
|
20467
20393
|
}],
|
|
@@ -20528,7 +20454,7 @@ var MetricComponent = class MetricComponent {
|
|
|
20528
20454
|
}
|
|
20529
20455
|
static {
|
|
20530
20456
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
20531
|
-
minVersion: "
|
|
20457
|
+
minVersion: "17.0.0",
|
|
20532
20458
|
version: "22.2.4",
|
|
20533
20459
|
type: MetricComponent,
|
|
20534
20460
|
isStandalone: false,
|
|
@@ -20548,7 +20474,7 @@ var MetricComponent = class MetricComponent {
|
|
|
20548
20474
|
"class.card": "this.card"
|
|
20549
20475
|
} },
|
|
20550
20476
|
ngImport: i0,
|
|
20551
|
-
template: "<div class=\"label\" [ngClass]=\"align\">\n {{ label }}\n
|
|
20477
|
+
template: "<div class=\"label\" [ngClass]=\"align\">\n {{ label }}\n @if (help) {\n <span\n ><riv-icon [rivTooltip]=\"help\" [name]=\"'Info'\" [size]=\"12\"></riv-icon>\n </span>\n }\n</div>\n<div class=\"content\" [ngClass]=\"align\">\n <div class=\"value\" [ngClass]=\"size\" [style.color]=\"valueColor\">\n {{ value }}\n </div>\n <ng-content></ng-content>\n</div>\n",
|
|
20552
20478
|
styles: [":host.card{border-radius:var(--size-xsmall);border:var(--border-width) solid var(--border-light);background-color:var(--surface-light-0);padding:var(--size-xlarge);display:block}:host.compact{padding:var(--size-large)}.label{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0);color:var(--type-light-low-contrast);margin-bottom:var(--size-xsmall)}.label.left{text-align:left}.label.center{text-align:center}.label.right{text-align:right}.value.xsmall{font:var(--stat-xsmall)}.value.small{font:var(--stat-small)}.value.medium{font:var(--stat-medium)}.value.large{font:var(--stat-large)}.content{display:flex;align-items:flex-end;gap:var(--size-small)}.content.left{justify-content:flex-start}.content.center{justify-content:center}.content.right{justify-content:flex-end}\n"],
|
|
20553
20479
|
dependencies: [
|
|
20554
20480
|
{
|
|
@@ -20557,16 +20483,6 @@ var MetricComponent = class MetricComponent {
|
|
|
20557
20483
|
selector: "[ngClass]",
|
|
20558
20484
|
inputs: ["class", "ngClass"]
|
|
20559
20485
|
},
|
|
20560
|
-
{
|
|
20561
|
-
kind: "directive",
|
|
20562
|
-
type: i1.NgIf,
|
|
20563
|
-
selector: "[ngIf]",
|
|
20564
|
-
inputs: [
|
|
20565
|
-
"ngIf",
|
|
20566
|
-
"ngIfThen",
|
|
20567
|
-
"ngIfElse"
|
|
20568
|
-
]
|
|
20569
|
-
},
|
|
20570
20486
|
{
|
|
20571
20487
|
kind: "component",
|
|
20572
20488
|
type: IconComponent,
|
|
@@ -20610,7 +20526,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
20610
20526
|
selector: "riv-metric",
|
|
20611
20527
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
20612
20528
|
standalone: false,
|
|
20613
|
-
template: "<div class=\"label\" [ngClass]=\"align\">\n {{ label }}\n
|
|
20529
|
+
template: "<div class=\"label\" [ngClass]=\"align\">\n {{ label }}\n @if (help) {\n <span\n ><riv-icon [rivTooltip]=\"help\" [name]=\"'Info'\" [size]=\"12\"></riv-icon>\n </span>\n }\n</div>\n<div class=\"content\" [ngClass]=\"align\">\n <div class=\"value\" [ngClass]=\"size\" [style.color]=\"valueColor\">\n {{ value }}\n </div>\n <ng-content></ng-content>\n</div>\n",
|
|
20614
20530
|
styles: [":host.card{border-radius:var(--size-xsmall);border:var(--border-width) solid var(--border-light);background-color:var(--surface-light-0);padding:var(--size-xlarge);display:block}:host.compact{padding:var(--size-large)}.label{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0);color:var(--type-light-low-contrast);margin-bottom:var(--size-xsmall)}.label.left{text-align:left}.label.center{text-align:center}.label.right{text-align:right}.value.xsmall{font:var(--stat-xsmall)}.value.small{font:var(--stat-small)}.value.medium{font:var(--stat-medium)}.value.large{font:var(--stat-large)}.content{display:flex;align-items:flex-end;gap:var(--size-small)}.content.left{justify-content:flex-start}.content.center{justify-content:center}.content.right{justify-content:flex-end}\n"]
|
|
20615
20531
|
}]
|
|
20616
20532
|
}],
|
|
@@ -20779,7 +20695,7 @@ var FunnelChartComponent = class FunnelChartComponent {
|
|
|
20779
20695
|
}
|
|
20780
20696
|
static {
|
|
20781
20697
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
20782
|
-
minVersion: "
|
|
20698
|
+
minVersion: "17.0.0",
|
|
20783
20699
|
version: "22.2.4",
|
|
20784
20700
|
type: FunnelChartComponent,
|
|
20785
20701
|
isStandalone: false,
|
|
@@ -20793,55 +20709,32 @@ var FunnelChartComponent = class FunnelChartComponent {
|
|
|
20793
20709
|
},
|
|
20794
20710
|
usesOnChanges: true,
|
|
20795
20711
|
ngImport: i0,
|
|
20796
|
-
template: "<div class=\"funnel-chart\">\n <div class=\"header\">\n <!-- allocate space for the header -->\n <riv-metric\n class=\"metric-placeholder\"\n label=\"placeholder\"\n value=\"0\"\n ></riv-metric>\n <!-- center each metric over vertical lines -->\n
|
|
20712
|
+
template: "<div class=\"funnel-chart\">\n <div class=\"header\">\n <!-- allocate space for the header -->\n <riv-metric\n class=\"metric-placeholder\"\n label=\"placeholder\"\n value=\"0\"\n ></riv-metric>\n <!-- center each metric over vertical lines -->\n @for (value of aggregatedValues; track $index; let ix = $index) {\n <riv-metric\n class=\"metric\"\n [label]=\"data[ix]?.label ?? ''\"\n [value]=\"value.toString()\"\n [style.left.px]=\"ix * sectionWidth + ix * gapWidth\"\n ></riv-metric>\n }\n </div>\n\n <div class=\"chart\">\n @for (step of percentageSteps; track $index; let ix = $index) {\n <div class=\"vertical-line\"></div>\n <div>\n @if (showConverted && !allZeroes) {\n <div class=\"step-info\">\n {{ step }}% converted\n @if (trends[ix] !== null) {\n <riv-trend\n [label]=\"trends[ix]! + '%'\"\n [value]=\"trends[ix]!\"\n ></riv-trend>\n }\n </div>\n }\n <!-- allocate space for the graph -->\n <div\n class=\"graph-placeholder\"\n [style.width.px]=\"sectionWidth\"\n [style.height.px]=\"graphHeight\"\n ></div>\n </div>\n }\n\n <div class=\"vertical-line\"></div>\n\n @if (path) {\n <svg\n class=\"graph\"\n xmlns=\"http://www.w3.org/2000/svg\"\n [attr.width]=\"graphWidth\"\n [attr.height]=\"graphHeight\"\n >\n <linearGradient id=\"gradient\">\n <stop stop-color=\"var(--purp-30)\" offset=\"0%\" />\n <stop stop-color=\"var(--brand)\" offset=\"100%\" />\n </linearGradient>\n <path [attr.d]=\"path\" fill=\"url(#gradient)\"></path>\n </svg>\n }\n </div>\n</div>\n",
|
|
20797
20713
|
styles: [".funnel-chart{width:fit-content}.header{position:relative;margin-left:var(--size-xlarge);margin-right:var(--size-xlarge)}.metric-placeholder{visibility:hidden}.metric{position:absolute;transform:translate(-50%);top:0;display:flex;flex-direction:column;align-items:center;gap:var(--size-xsmall);white-space:nowrap}.chart{position:relative;display:flex;justify-content:space-between;margin-top:var(--size-medium);margin-left:var(--size-xlarge);margin-right:var(--size-xlarge)}.step-info{display:flex;gap:var(--size-large);border:var(--border-width) solid var(--border-light);border-radius:var(--size-xsmall);padding:var(--size-medium);width:fit-content;align-items:center;color:var(--type-light-low-contrast);margin:var(--size-xsmall)}.vertical-line{width:var(--size-xxsmall);background:var(--surface-light-4);z-index:1}.graph-placeholder{margin-bottom:var(--size-xlarge)}.graph{position:absolute;bottom:var(--size-xlarge)}\n"],
|
|
20798
|
-
dependencies: [
|
|
20799
|
-
|
|
20800
|
-
|
|
20801
|
-
|
|
20802
|
-
|
|
20803
|
-
|
|
20804
|
-
|
|
20805
|
-
|
|
20806
|
-
|
|
20807
|
-
|
|
20808
|
-
|
|
20809
|
-
|
|
20810
|
-
|
|
20811
|
-
|
|
20812
|
-
|
|
20813
|
-
|
|
20814
|
-
|
|
20815
|
-
|
|
20816
|
-
|
|
20817
|
-
|
|
20818
|
-
|
|
20819
|
-
|
|
20820
|
-
|
|
20821
|
-
|
|
20822
|
-
selector: "riv-metric",
|
|
20823
|
-
inputs: [
|
|
20824
|
-
"label",
|
|
20825
|
-
"value",
|
|
20826
|
-
"size",
|
|
20827
|
-
"compact",
|
|
20828
|
-
"card",
|
|
20829
|
-
"help",
|
|
20830
|
-
"align",
|
|
20831
|
-
"valueColorToken"
|
|
20832
|
-
]
|
|
20833
|
-
},
|
|
20834
|
-
{
|
|
20835
|
-
kind: "component",
|
|
20836
|
-
type: TrendComponent,
|
|
20837
|
-
selector: "riv-trend",
|
|
20838
|
-
inputs: [
|
|
20839
|
-
"label",
|
|
20840
|
-
"value",
|
|
20841
|
-
"successCondition"
|
|
20842
|
-
]
|
|
20843
|
-
}
|
|
20844
|
-
],
|
|
20714
|
+
dependencies: [{
|
|
20715
|
+
kind: "component",
|
|
20716
|
+
type: MetricComponent,
|
|
20717
|
+
selector: "riv-metric",
|
|
20718
|
+
inputs: [
|
|
20719
|
+
"label",
|
|
20720
|
+
"value",
|
|
20721
|
+
"size",
|
|
20722
|
+
"compact",
|
|
20723
|
+
"card",
|
|
20724
|
+
"help",
|
|
20725
|
+
"align",
|
|
20726
|
+
"valueColorToken"
|
|
20727
|
+
]
|
|
20728
|
+
}, {
|
|
20729
|
+
kind: "component",
|
|
20730
|
+
type: TrendComponent,
|
|
20731
|
+
selector: "riv-trend",
|
|
20732
|
+
inputs: [
|
|
20733
|
+
"label",
|
|
20734
|
+
"value",
|
|
20735
|
+
"successCondition"
|
|
20736
|
+
]
|
|
20737
|
+
}],
|
|
20845
20738
|
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
20846
20739
|
});
|
|
20847
20740
|
}
|
|
@@ -20857,7 +20750,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
20857
20750
|
selector: "riv-funnel",
|
|
20858
20751
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
20859
20752
|
standalone: false,
|
|
20860
|
-
template: "<div class=\"funnel-chart\">\n <div class=\"header\">\n <!-- allocate space for the header -->\n <riv-metric\n class=\"metric-placeholder\"\n label=\"placeholder\"\n value=\"0\"\n ></riv-metric>\n <!-- center each metric over vertical lines -->\n
|
|
20753
|
+
template: "<div class=\"funnel-chart\">\n <div class=\"header\">\n <!-- allocate space for the header -->\n <riv-metric\n class=\"metric-placeholder\"\n label=\"placeholder\"\n value=\"0\"\n ></riv-metric>\n <!-- center each metric over vertical lines -->\n @for (value of aggregatedValues; track $index; let ix = $index) {\n <riv-metric\n class=\"metric\"\n [label]=\"data[ix]?.label ?? ''\"\n [value]=\"value.toString()\"\n [style.left.px]=\"ix * sectionWidth + ix * gapWidth\"\n ></riv-metric>\n }\n </div>\n\n <div class=\"chart\">\n @for (step of percentageSteps; track $index; let ix = $index) {\n <div class=\"vertical-line\"></div>\n <div>\n @if (showConverted && !allZeroes) {\n <div class=\"step-info\">\n {{ step }}% converted\n @if (trends[ix] !== null) {\n <riv-trend\n [label]=\"trends[ix]! + '%'\"\n [value]=\"trends[ix]!\"\n ></riv-trend>\n }\n </div>\n }\n <!-- allocate space for the graph -->\n <div\n class=\"graph-placeholder\"\n [style.width.px]=\"sectionWidth\"\n [style.height.px]=\"graphHeight\"\n ></div>\n </div>\n }\n\n <div class=\"vertical-line\"></div>\n\n @if (path) {\n <svg\n class=\"graph\"\n xmlns=\"http://www.w3.org/2000/svg\"\n [attr.width]=\"graphWidth\"\n [attr.height]=\"graphHeight\"\n >\n <linearGradient id=\"gradient\">\n <stop stop-color=\"var(--purp-30)\" offset=\"0%\" />\n <stop stop-color=\"var(--brand)\" offset=\"100%\" />\n </linearGradient>\n <path [attr.d]=\"path\" fill=\"url(#gradient)\"></path>\n </svg>\n }\n </div>\n</div>\n",
|
|
20861
20754
|
styles: [".funnel-chart{width:fit-content}.header{position:relative;margin-left:var(--size-xlarge);margin-right:var(--size-xlarge)}.metric-placeholder{visibility:hidden}.metric{position:absolute;transform:translate(-50%);top:0;display:flex;flex-direction:column;align-items:center;gap:var(--size-xsmall);white-space:nowrap}.chart{position:relative;display:flex;justify-content:space-between;margin-top:var(--size-medium);margin-left:var(--size-xlarge);margin-right:var(--size-xlarge)}.step-info{display:flex;gap:var(--size-large);border:var(--border-width) solid var(--border-light);border-radius:var(--size-xsmall);padding:var(--size-medium);width:fit-content;align-items:center;color:var(--type-light-low-contrast);margin:var(--size-xsmall)}.vertical-line{width:var(--size-xxsmall);background:var(--surface-light-4);z-index:1}.graph-placeholder{margin-bottom:var(--size-xlarge)}.graph{position:absolute;bottom:var(--size-xlarge)}\n"]
|
|
20862
20755
|
}]
|
|
20863
20756
|
}],
|
|
@@ -20907,7 +20800,7 @@ var MiniPieComponent = class MiniPieComponent {
|
|
|
20907
20800
|
}
|
|
20908
20801
|
static {
|
|
20909
20802
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
20910
|
-
minVersion: "
|
|
20803
|
+
minVersion: "17.0.0",
|
|
20911
20804
|
version: "22.2.4",
|
|
20912
20805
|
type: MiniPieComponent,
|
|
20913
20806
|
isStandalone: false,
|
|
@@ -20919,18 +20812,8 @@ var MiniPieComponent = class MiniPieComponent {
|
|
|
20919
20812
|
},
|
|
20920
20813
|
host: { properties: { "class": "this.classes" } },
|
|
20921
20814
|
ngImport: i0,
|
|
20922
|
-
template: "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"-10 -10 20 20\">\n <circle cx=\"0\" cy=\"0\" r=\"8\" class=\"track\" />\n
|
|
20815
|
+
template: "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"-10 -10 20 20\">\n <circle cx=\"0\" cy=\"0\" r=\"8\" class=\"track\" />\n @if (isFull) {\n <circle cx=\"0\" cy=\"0\" r=\"8\" [attr.fill]=\"fillColor\" />\n }\n @if (clampedValue > 0 && !isFull) {\n <path [attr.d]=\"wedgePath\" [attr.fill]=\"fillColor\" />\n }\n</svg>\n",
|
|
20923
20816
|
styles: [":host{display:inline-flex;align-items:center;justify-content:center;vertical-align:middle}:host.small{width:20px;height:20px}:host.medium{width:24px;height:24px}:host.large{width:32px;height:32px}svg{width:100%;height:100%}.track{fill:var(--border-light)}\n"],
|
|
20924
|
-
dependencies: [{
|
|
20925
|
-
kind: "directive",
|
|
20926
|
-
type: i1.NgIf,
|
|
20927
|
-
selector: "[ngIf]",
|
|
20928
|
-
inputs: [
|
|
20929
|
-
"ngIf",
|
|
20930
|
-
"ngIfThen",
|
|
20931
|
-
"ngIfElse"
|
|
20932
|
-
]
|
|
20933
|
-
}],
|
|
20934
20817
|
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
20935
20818
|
});
|
|
20936
20819
|
}
|
|
@@ -20946,7 +20829,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
20946
20829
|
selector: "riv-mini-pie",
|
|
20947
20830
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
20948
20831
|
standalone: false,
|
|
20949
|
-
template: "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"-10 -10 20 20\">\n <circle cx=\"0\" cy=\"0\" r=\"8\" class=\"track\" />\n
|
|
20832
|
+
template: "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"-10 -10 20 20\">\n <circle cx=\"0\" cy=\"0\" r=\"8\" class=\"track\" />\n @if (isFull) {\n <circle cx=\"0\" cy=\"0\" r=\"8\" [attr.fill]=\"fillColor\" />\n }\n @if (clampedValue > 0 && !isFull) {\n <path [attr.d]=\"wedgePath\" [attr.fill]=\"fillColor\" />\n }\n</svg>\n",
|
|
20950
20833
|
styles: [":host{display:inline-flex;align-items:center;justify-content:center;vertical-align:middle}:host.small{width:20px;height:20px}:host.medium{width:24px;height:24px}:host.large{width:32px;height:32px}svg{width:100%;height:100%}.track{fill:var(--border-light)}\n"]
|
|
20951
20834
|
}]
|
|
20952
20835
|
}],
|
|
@@ -21370,7 +21253,7 @@ var StackedColumnComponent = class StackedColumnComponent {
|
|
|
21370
21253
|
}
|
|
21371
21254
|
static {
|
|
21372
21255
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
21373
|
-
minVersion: "
|
|
21256
|
+
minVersion: "17.0.0",
|
|
21374
21257
|
version: "22.2.4",
|
|
21375
21258
|
type: StackedColumnComponent,
|
|
21376
21259
|
isStandalone: false,
|
|
@@ -21397,29 +21280,9 @@ var StackedColumnComponent = class StackedColumnComponent {
|
|
|
21397
21280
|
descendants: true
|
|
21398
21281
|
}],
|
|
21399
21282
|
ngImport: i0,
|
|
21400
|
-
template: "
|
|
21283
|
+
template: "@if ((empty$ | async) === false) {\n <div class=\"container\" (rivClientSize)=\"width = $event.width\">\n @if (drawData$ | async; as d) {\n <svg xmlns=\"http://www.w3.org/2000/svg\" [attr.viewBox]=\"d.viewBox\">\n <defs>\n <pattern\n id=\"stripes\"\n x=\"0\"\n y=\"0\"\n [attr.width]=\"d.columnWidth\"\n [attr.height]=\"d.columnWidth\"\n patternUnits=\"userSpaceOnUse\"\n >\n <line\n x1=\"0\"\n [attr.y1]=\"d.columnWidth\"\n [attr.x2]=\"d.columnWidth\"\n y2=\"0\"\n stroke=\"var(--white-100)\"\n stroke-width=\"1\"\n ></line>\n </pattern>\n </defs>\n @for (tick of d.xMinorTicks; track tick.dateValue) {\n <g>\n <rect\n class=\"tick-background\"\n [class.focused]=\"\n (hoveredBand$ | async)?.dateValue === tick.dateValue\n \"\n [attr.x]=\"tick.x - 20\"\n [attr.y]=\"d.yScale(0) + 3\"\n width=\"40\"\n height=\"12\"\n rx=\"2\"\n ></rect>\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"d.yScale(0) + 12\"\n text-anchor=\"middle\"\n >\n {{ tick.label }}\n </text>\n </g>\n }\n @for (tick of d.xMajorTicks; track tick.dateValue) {\n <g>\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"d.yScale(0) + 24\"\n text-anchor=\"middle\"\n >\n {{ tick.label }}\n </text>\n </g>\n }\n @for (tick of d.yTicks; track $index) {\n <g>\n <rect\n class=\"tick\"\n x=\"0\"\n [attr.y]=\"d.yScale(tick)\"\n width=\"100%\"\n height=\"1\"\n ></rect>\n <text class=\"tick-label\" x=\"0\" [attr.y]=\"d.yScale(tick)\" dy=\"-4\">\n {{ valueFormatter(tick) }}\n </text>\n </g>\n }\n @for (rect of d.rects; track $index) {\n <g>\n <rect\n class=\"column\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"rect.fill\"\n [class.blurred]=\"\n (hoveredBand$ | async) !== null &&\n (hoveredBand$ | async)?.dateValue !== rect.dateValue\n \"\n ></rect>\n @if (rect.striped) {\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"url(#stripes)\"\n ></rect>\n }\n </g>\n }\n @if (getRange$ | async; as getRange) {\n @for (rect of d.hoverBands; track rect.dateValue) {\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"transparent\"\n (mouseenter)=\"\n hoveredBand$.next({\n dateValue: rect.dateValue,\n event: $event,\n })\n \"\n (mouseleave)=\"hoveredBand$.next(null)\"\n (click)=\"\n stackClicked.emit(getRange(rect.dateValue));\n hoveredBand$.next(null)\n \"\n ></rect>\n }\n }\n </svg>\n }\n </div>\n} @else {\n <riv-zero-state></riv-zero-state>\n}\n\n@if (callout$ | async; as callout) {\n <riv-callout\n *riv-overlay\n [anchor]=\"callout?.anchor ?? null\"\n [theme]=\"'light'\"\n [isModal]=\"false\"\n [preferredPosition]=\"'center-right'\"\n [allowedPositions]=\"[\n 'center-right',\n 'center-left',\n 'top-center',\n 'bottom-center',\n ]\"\n >\n <div class=\"callout-content\">\n <ng-container\n [ngTemplateOutlet]=\"calloutHeaderTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: callout }\"\n ></ng-container>\n @for (stack of callout?.content; track $index) {\n <div class=\"callout-stack\">\n @if (stack.title; as title) {\n <div class=\"callout-row\">\n <span class=\"series-label\">{{ title }}</span>\n <span>{{ stack.total }}</span>\n </div>\n }\n @for (series of stack.series; track $index) {\n <div class=\"callout-row\">\n <span class=\"series-label\">\n <riv-legend-item\n [colorToken]=\"series.colorToken\"\n [style]=\"series.style\"\n ></riv-legend-item>\n <span>{{ series.label }}</span>\n </span>\n <span>{{ series.formattedValue }}</span>\n </div>\n }\n </div>\n }\n </div>\n </riv-callout>\n}\n\n<ng-template #controls>\n <riv-simple-select\n [optionGroups]=\"intervalOptions$ | async | rivOptionGroup\"\n [orderBy]=\"'source'\"\n [selectedOption]=\"selectedIntervalOption$ | async\"\n (selectedOptionChange)=\"setIntervalOption($event)\"\n ></riv-simple-select>\n</ng-template>\n",
|
|
21401
21284
|
styles: [".tick{fill:var(--gray-20)}.tick-label{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0);fill:var(--type-light-low-contrast)}.tick-background{transition:fill var(--short-transition);fill:transparent}.tick-background.focused{fill:var(--baloo-10)}.column{transition:opacity var(--short-transition)}.column.blurred{opacity:.4}.callout-content{padding:var(--size-medium) var(--size-xlarge);display:flex;flex-direction:column}.callout-stack{display:flex;flex-direction:column;padding:var(--size-medium) 0;gap:var(--size-medium)}.callout-stack:not(:last-child){border-bottom:var(--border-width) solid var(--border-light)}.callout-row{display:flex;gap:var(--size-large);align-items:center;font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0)}.series-label{flex-grow:1;font-weight:var(--font-weight-heavy);display:flex;align-items:center;gap:var(--size-small)}\n"],
|
|
21402
21285
|
dependencies: [
|
|
21403
|
-
{
|
|
21404
|
-
kind: "directive",
|
|
21405
|
-
type: i1.NgForOf,
|
|
21406
|
-
selector: "[ngFor][ngForOf]",
|
|
21407
|
-
inputs: [
|
|
21408
|
-
"ngForOf",
|
|
21409
|
-
"ngForTrackBy",
|
|
21410
|
-
"ngForTemplate"
|
|
21411
|
-
]
|
|
21412
|
-
},
|
|
21413
|
-
{
|
|
21414
|
-
kind: "directive",
|
|
21415
|
-
type: i1.NgIf,
|
|
21416
|
-
selector: "[ngIf]",
|
|
21417
|
-
inputs: [
|
|
21418
|
-
"ngIf",
|
|
21419
|
-
"ngIfThen",
|
|
21420
|
-
"ngIfElse"
|
|
21421
|
-
]
|
|
21422
|
-
},
|
|
21423
21286
|
{
|
|
21424
21287
|
kind: "directive",
|
|
21425
21288
|
type: i1.NgTemplateOutlet,
|
|
@@ -21532,7 +21395,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
21532
21395
|
selector: "riv-stacked-column",
|
|
21533
21396
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
21534
21397
|
standalone: false,
|
|
21535
|
-
template: "
|
|
21398
|
+
template: "@if ((empty$ | async) === false) {\n <div class=\"container\" (rivClientSize)=\"width = $event.width\">\n @if (drawData$ | async; as d) {\n <svg xmlns=\"http://www.w3.org/2000/svg\" [attr.viewBox]=\"d.viewBox\">\n <defs>\n <pattern\n id=\"stripes\"\n x=\"0\"\n y=\"0\"\n [attr.width]=\"d.columnWidth\"\n [attr.height]=\"d.columnWidth\"\n patternUnits=\"userSpaceOnUse\"\n >\n <line\n x1=\"0\"\n [attr.y1]=\"d.columnWidth\"\n [attr.x2]=\"d.columnWidth\"\n y2=\"0\"\n stroke=\"var(--white-100)\"\n stroke-width=\"1\"\n ></line>\n </pattern>\n </defs>\n @for (tick of d.xMinorTicks; track tick.dateValue) {\n <g>\n <rect\n class=\"tick-background\"\n [class.focused]=\"\n (hoveredBand$ | async)?.dateValue === tick.dateValue\n \"\n [attr.x]=\"tick.x - 20\"\n [attr.y]=\"d.yScale(0) + 3\"\n width=\"40\"\n height=\"12\"\n rx=\"2\"\n ></rect>\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"d.yScale(0) + 12\"\n text-anchor=\"middle\"\n >\n {{ tick.label }}\n </text>\n </g>\n }\n @for (tick of d.xMajorTicks; track tick.dateValue) {\n <g>\n <text\n class=\"tick-label\"\n [attr.x]=\"tick.x\"\n [attr.y]=\"d.yScale(0) + 24\"\n text-anchor=\"middle\"\n >\n {{ tick.label }}\n </text>\n </g>\n }\n @for (tick of d.yTicks; track $index) {\n <g>\n <rect\n class=\"tick\"\n x=\"0\"\n [attr.y]=\"d.yScale(tick)\"\n width=\"100%\"\n height=\"1\"\n ></rect>\n <text class=\"tick-label\" x=\"0\" [attr.y]=\"d.yScale(tick)\" dy=\"-4\">\n {{ valueFormatter(tick) }}\n </text>\n </g>\n }\n @for (rect of d.rects; track $index) {\n <g>\n <rect\n class=\"column\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"rect.fill\"\n [class.blurred]=\"\n (hoveredBand$ | async) !== null &&\n (hoveredBand$ | async)?.dateValue !== rect.dateValue\n \"\n ></rect>\n @if (rect.striped) {\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"url(#stripes)\"\n ></rect>\n }\n </g>\n }\n @if (getRange$ | async; as getRange) {\n @for (rect of d.hoverBands; track rect.dateValue) {\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"transparent\"\n (mouseenter)=\"\n hoveredBand$.next({\n dateValue: rect.dateValue,\n event: $event,\n })\n \"\n (mouseleave)=\"hoveredBand$.next(null)\"\n (click)=\"\n stackClicked.emit(getRange(rect.dateValue));\n hoveredBand$.next(null)\n \"\n ></rect>\n }\n }\n </svg>\n }\n </div>\n} @else {\n <riv-zero-state></riv-zero-state>\n}\n\n@if (callout$ | async; as callout) {\n <riv-callout\n *riv-overlay\n [anchor]=\"callout?.anchor ?? null\"\n [theme]=\"'light'\"\n [isModal]=\"false\"\n [preferredPosition]=\"'center-right'\"\n [allowedPositions]=\"[\n 'center-right',\n 'center-left',\n 'top-center',\n 'bottom-center',\n ]\"\n >\n <div class=\"callout-content\">\n <ng-container\n [ngTemplateOutlet]=\"calloutHeaderTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: callout }\"\n ></ng-container>\n @for (stack of callout?.content; track $index) {\n <div class=\"callout-stack\">\n @if (stack.title; as title) {\n <div class=\"callout-row\">\n <span class=\"series-label\">{{ title }}</span>\n <span>{{ stack.total }}</span>\n </div>\n }\n @for (series of stack.series; track $index) {\n <div class=\"callout-row\">\n <span class=\"series-label\">\n <riv-legend-item\n [colorToken]=\"series.colorToken\"\n [style]=\"series.style\"\n ></riv-legend-item>\n <span>{{ series.label }}</span>\n </span>\n <span>{{ series.formattedValue }}</span>\n </div>\n }\n </div>\n }\n </div>\n </riv-callout>\n}\n\n<ng-template #controls>\n <riv-simple-select\n [optionGroups]=\"intervalOptions$ | async | rivOptionGroup\"\n [orderBy]=\"'source'\"\n [selectedOption]=\"selectedIntervalOption$ | async\"\n (selectedOptionChange)=\"setIntervalOption($event)\"\n ></riv-simple-select>\n</ng-template>\n",
|
|
21536
21399
|
styles: [".tick{fill:var(--gray-20)}.tick-label{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0);fill:var(--type-light-low-contrast)}.tick-background{transition:fill var(--short-transition);fill:transparent}.tick-background.focused{fill:var(--baloo-10)}.column{transition:opacity var(--short-transition)}.column.blurred{opacity:.4}.callout-content{padding:var(--size-medium) var(--size-xlarge);display:flex;flex-direction:column}.callout-stack{display:flex;flex-direction:column;padding:var(--size-medium) 0;gap:var(--size-medium)}.callout-stack:not(:last-child){border-bottom:var(--border-width) solid var(--border-light)}.callout-row{display:flex;gap:var(--size-large);align-items:center;font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0)}.series-label{flex-grow:1;font-weight:var(--font-weight-heavy);display:flex;align-items:center;gap:var(--size-small)}\n"]
|
|
21537
21400
|
}]
|
|
21538
21401
|
}],
|
|
@@ -21798,7 +21661,7 @@ var StackedRowComponent = class StackedRowComponent {
|
|
|
21798
21661
|
}
|
|
21799
21662
|
static {
|
|
21800
21663
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
21801
|
-
minVersion: "
|
|
21664
|
+
minVersion: "17.0.0",
|
|
21802
21665
|
version: "22.2.4",
|
|
21803
21666
|
type: StackedRowComponent,
|
|
21804
21667
|
isStandalone: false,
|
|
@@ -21816,29 +21679,9 @@ var StackedRowComponent = class StackedRowComponent {
|
|
|
21816
21679
|
descendants: true
|
|
21817
21680
|
}],
|
|
21818
21681
|
ngImport: i0,
|
|
21819
|
-
template: "
|
|
21682
|
+
template: "@if ((empty$ | async) === false) {\n <div class=\"container\" (rivClientSize)=\"width = $event.width\">\n @if (drawData$ | async; as draw) {\n <svg xmlns=\"http://www.w3.org/2000/svg\" [attr.viewBox]=\"draw.viewBox\">\n <defs>\n <pattern\n id=\"stripes\"\n x=\"0\"\n y=\"0\"\n [attr.width]=\"draw.rowHeight\"\n [attr.height]=\"draw.rowHeight\"\n patternUnits=\"userSpaceOnUse\"\n >\n <line\n [attr.x1]=\"0\"\n [attr.y1]=\"0\"\n [attr.x2]=\"draw.rowHeight\"\n [attr.y2]=\"draw.rowHeight\"\n stroke=\"var(--white-100)\"\n stroke-width=\"1\"\n ></line>\n </pattern>\n </defs>\n @for (rowNameToDraw of draw.rowNames; track $index) {\n <g>\n <text\n rivSVGTextTruncate\n [text]=\"rowNameToDraw.label\"\n [width]=\"SECTION_WIDTHS.ROW_NAME\"\n class=\"row-title\"\n [attr.x]=\"rowNameToDraw.x\"\n [attr.y]=\"rowNameToDraw.y\"\n ></text>\n </g>\n }\n @for (tick of draw.xTicks; track $index) {\n <g>\n <rect\n class=\"tick\"\n [attr.x]=\"draw.xScale(tick)\"\n y=\"0\"\n width=\"1\"\n height=\"100%\"\n ></rect>\n <text\n class=\"tick-label\"\n [attr.x]=\"draw.xScale(tick)\"\n [attr.y]=\"locationOfXAxisTick()\"\n dx=\"4\"\n dy=\"-4\"\n >\n {{ valueFormatter(tick) }}\n </text>\n </g>\n }\n @for (rect of draw.rects; track $index) {\n <g\n (mouseenter)=\"\n hoveredBand$.next({ rowName: rect.rowName, event: $event })\n \"\n (mouseleave)=\"hoveredBand$.next(null)\"\n (click)=\"\n stackClicked.emit({ stackIndex: rect.stackIndex });\n hoveredBand$.next(null)\n \"\n >\n <rect\n class=\"row\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"rect.fill\"\n [class.blurred]=\"\n (hoveredBand$ | async) !== null &&\n (hoveredBand$ | async)?.rowName !== rect.rowName\n \"\n ></rect>\n @if (rect.striped) {\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"url(#stripes)\"\n ></rect>\n }\n </g>\n }\n @for (rowTotalToDraw of draw.rowTotals; track $index) {\n <g>\n <text\n class=\"row-total\"\n [attr.x]=\"rowTotalToDraw.x\"\n [attr.y]=\"rowTotalToDraw.y\"\n text-anchor=\"end\"\n >\n {{ rowTotalToDraw.label }}\n </text>\n </g>\n }\n </svg>\n }\n @if (drawData$ | async; as draw) {\n <legend>\n @for (item of draw.legendItems; track item.label) {\n <riv-legend-item\n [label]=\"item.label\"\n [colorToken]=\"item.colorToken\"\n [style]=\"item.style ? item.style : 'solid'\"\n ></riv-legend-item>\n }\n </legend>\n }\n </div>\n} @else {\n <riv-zero-state [message]=\"zeroStateMessage\"></riv-zero-state>\n}\n\n@if (callout$ | async; as callout) {\n <riv-callout\n *riv-overlay\n [anchor]=\"callout?.anchor ?? null\"\n [isModal]=\"false\"\n [preferredPosition]=\"'bottom-center'\"\n [allowedPositions]=\"[\n 'center-right',\n 'center-left',\n 'top-center',\n 'bottom-center',\n ]\"\n [theme]=\"'light'\"\n >\n <div class=\"callout-content\">\n <ng-container\n [ngTemplateOutlet]=\"calloutHeaderTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: callout }\"\n ></ng-container>\n @for (metric of callout?.metrics; track $index) {\n <div class=\"callout-row\">\n <span class=\"series-label\">\n <riv-legend-item [colorToken]=\"metric.colorToken\"></riv-legend-item>\n <span>{{ metric.label }}</span>\n </span>\n <span>{{ metric.value }}</span>\n </div>\n }\n </div>\n </riv-callout>\n}\n",
|
|
21820
21683
|
styles: [".tick{fill:var(--gray-20)}.tick-label{font-size:var(--type-0-font-size);line-height:var(--type-0-line-height-0);fill:var(--type-light-low-contrast)}.row-title{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-2)}.row-total{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-2);fill:var(--type-light-low-contrast)}.row{transition:opacity var(--short-transition)}.row.blurred{opacity:.4}legend{display:flex;flex-wrap:wrap;gap:var(--size-large);justify-content:flex-start;align-items:baseline}.callout-content{padding:var(--size-medium) var(--size-xlarge);display:flex;flex-direction:column}.callout-row{padding:var(--size-medium) 0;display:flex;gap:var(--size-large);align-items:center;font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0)}.series-label{flex-grow:1;font-weight:var(--font-weight-heavy);display:flex;align-items:center;gap:var(--size-small)}\n"],
|
|
21821
21684
|
dependencies: [
|
|
21822
|
-
{
|
|
21823
|
-
kind: "directive",
|
|
21824
|
-
type: i1.NgForOf,
|
|
21825
|
-
selector: "[ngFor][ngForOf]",
|
|
21826
|
-
inputs: [
|
|
21827
|
-
"ngForOf",
|
|
21828
|
-
"ngForTrackBy",
|
|
21829
|
-
"ngForTemplate"
|
|
21830
|
-
]
|
|
21831
|
-
},
|
|
21832
|
-
{
|
|
21833
|
-
kind: "directive",
|
|
21834
|
-
type: i1.NgIf,
|
|
21835
|
-
selector: "[ngIf]",
|
|
21836
|
-
inputs: [
|
|
21837
|
-
"ngIf",
|
|
21838
|
-
"ngIfThen",
|
|
21839
|
-
"ngIfElse"
|
|
21840
|
-
]
|
|
21841
|
-
},
|
|
21842
21685
|
{
|
|
21843
21686
|
kind: "directive",
|
|
21844
21687
|
type: i1.NgTemplateOutlet,
|
|
@@ -21927,7 +21770,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
21927
21770
|
selector: "riv-stacked-row",
|
|
21928
21771
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
21929
21772
|
standalone: false,
|
|
21930
|
-
template: "
|
|
21773
|
+
template: "@if ((empty$ | async) === false) {\n <div class=\"container\" (rivClientSize)=\"width = $event.width\">\n @if (drawData$ | async; as draw) {\n <svg xmlns=\"http://www.w3.org/2000/svg\" [attr.viewBox]=\"draw.viewBox\">\n <defs>\n <pattern\n id=\"stripes\"\n x=\"0\"\n y=\"0\"\n [attr.width]=\"draw.rowHeight\"\n [attr.height]=\"draw.rowHeight\"\n patternUnits=\"userSpaceOnUse\"\n >\n <line\n [attr.x1]=\"0\"\n [attr.y1]=\"0\"\n [attr.x2]=\"draw.rowHeight\"\n [attr.y2]=\"draw.rowHeight\"\n stroke=\"var(--white-100)\"\n stroke-width=\"1\"\n ></line>\n </pattern>\n </defs>\n @for (rowNameToDraw of draw.rowNames; track $index) {\n <g>\n <text\n rivSVGTextTruncate\n [text]=\"rowNameToDraw.label\"\n [width]=\"SECTION_WIDTHS.ROW_NAME\"\n class=\"row-title\"\n [attr.x]=\"rowNameToDraw.x\"\n [attr.y]=\"rowNameToDraw.y\"\n ></text>\n </g>\n }\n @for (tick of draw.xTicks; track $index) {\n <g>\n <rect\n class=\"tick\"\n [attr.x]=\"draw.xScale(tick)\"\n y=\"0\"\n width=\"1\"\n height=\"100%\"\n ></rect>\n <text\n class=\"tick-label\"\n [attr.x]=\"draw.xScale(tick)\"\n [attr.y]=\"locationOfXAxisTick()\"\n dx=\"4\"\n dy=\"-4\"\n >\n {{ valueFormatter(tick) }}\n </text>\n </g>\n }\n @for (rect of draw.rects; track $index) {\n <g\n (mouseenter)=\"\n hoveredBand$.next({ rowName: rect.rowName, event: $event })\n \"\n (mouseleave)=\"hoveredBand$.next(null)\"\n (click)=\"\n stackClicked.emit({ stackIndex: rect.stackIndex });\n hoveredBand$.next(null)\n \"\n >\n <rect\n class=\"row\"\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n [attr.fill]=\"rect.fill\"\n [class.blurred]=\"\n (hoveredBand$ | async) !== null &&\n (hoveredBand$ | async)?.rowName !== rect.rowName\n \"\n ></rect>\n @if (rect.striped) {\n <rect\n [attr.x]=\"rect.x\"\n [attr.y]=\"rect.y\"\n [attr.width]=\"rect.width\"\n [attr.height]=\"rect.height\"\n fill=\"url(#stripes)\"\n ></rect>\n }\n </g>\n }\n @for (rowTotalToDraw of draw.rowTotals; track $index) {\n <g>\n <text\n class=\"row-total\"\n [attr.x]=\"rowTotalToDraw.x\"\n [attr.y]=\"rowTotalToDraw.y\"\n text-anchor=\"end\"\n >\n {{ rowTotalToDraw.label }}\n </text>\n </g>\n }\n </svg>\n }\n @if (drawData$ | async; as draw) {\n <legend>\n @for (item of draw.legendItems; track item.label) {\n <riv-legend-item\n [label]=\"item.label\"\n [colorToken]=\"item.colorToken\"\n [style]=\"item.style ? item.style : 'solid'\"\n ></riv-legend-item>\n }\n </legend>\n }\n </div>\n} @else {\n <riv-zero-state [message]=\"zeroStateMessage\"></riv-zero-state>\n}\n\n@if (callout$ | async; as callout) {\n <riv-callout\n *riv-overlay\n [anchor]=\"callout?.anchor ?? null\"\n [isModal]=\"false\"\n [preferredPosition]=\"'bottom-center'\"\n [allowedPositions]=\"[\n 'center-right',\n 'center-left',\n 'top-center',\n 'bottom-center',\n ]\"\n [theme]=\"'light'\"\n >\n <div class=\"callout-content\">\n <ng-container\n [ngTemplateOutlet]=\"calloutHeaderTemplate\"\n [ngTemplateOutletContext]=\"{ $implicit: callout }\"\n ></ng-container>\n @for (metric of callout?.metrics; track $index) {\n <div class=\"callout-row\">\n <span class=\"series-label\">\n <riv-legend-item [colorToken]=\"metric.colorToken\"></riv-legend-item>\n <span>{{ metric.label }}</span>\n </span>\n <span>{{ metric.value }}</span>\n </div>\n }\n </div>\n </riv-callout>\n}\n",
|
|
21931
21774
|
styles: [".tick{fill:var(--gray-20)}.tick-label{font-size:var(--type-0-font-size);line-height:var(--type-0-line-height-0);fill:var(--type-light-low-contrast)}.row-title{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-2)}.row-total{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-2);fill:var(--type-light-low-contrast)}.row{transition:opacity var(--short-transition)}.row.blurred{opacity:.4}legend{display:flex;flex-wrap:wrap;gap:var(--size-large);justify-content:flex-start;align-items:baseline}.callout-content{padding:var(--size-medium) var(--size-xlarge);display:flex;flex-direction:column}.callout-row{padding:var(--size-medium) 0;display:flex;gap:var(--size-large);align-items:center;font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0)}.series-label{flex-grow:1;font-weight:var(--font-weight-heavy);display:flex;align-items:center;gap:var(--size-small)}\n"]
|
|
21932
21775
|
}]
|
|
21933
21776
|
}],
|
|
@@ -22256,7 +22099,7 @@ var TimeSeriesComponent = class TimeSeriesComponent {
|
|
|
22256
22099
|
}
|
|
22257
22100
|
static {
|
|
22258
22101
|
this.ɵcmp = i0.ɵɵngDeclareComponent({
|
|
22259
|
-
minVersion: "
|
|
22102
|
+
minVersion: "17.0.0",
|
|
22260
22103
|
version: "22.2.4",
|
|
22261
22104
|
type: TimeSeriesComponent,
|
|
22262
22105
|
isStandalone: false,
|
|
@@ -22279,29 +22122,9 @@ var TimeSeriesComponent = class TimeSeriesComponent {
|
|
|
22279
22122
|
descendants: true
|
|
22280
22123
|
}],
|
|
22281
22124
|
ngImport: i0,
|
|
22282
|
-
template: "
|
|
22125
|
+
template: "@if ((empty$ | async) === false) {\n <div class=\"container\" (rivClientSize)=\"width = $event.width\">\n @if (drawData$ | async; as d) {\n <svg xmlns=\"http://www.w3.org/2000/svg\" [attr.viewBox]=\"d.viewBox\">\n @for (tick of d.x.xMajorTicks; track tick.value) {\n <g>\n @if (d.x.xScale(tick.value) >= 0) {\n <text\n class=\"x-major-tick-label\"\n [attr.x]=\"d.x.xScale(tick.value)\"\n [attr.y]=\"HEIGHT - BOTTOM_OFFSET\"\n dx=\"4\"\n dy=\"-4\"\n >\n {{ tick.label }}\n </text>\n }\n </g>\n }\n @for (tick of d.x.xMinorTicks; track tick.value) {\n <g>\n <text\n class=\"x-minor-tick-label\"\n [attr.x]=\"d.x.xScale(tick.value)\"\n [attr.y]=\"HEIGHT - BOTTOM_OFFSET\"\n text-anchor=\"middle\"\n dominant-baseline=\"hanging\"\n dy=\"8\"\n >\n {{ tick.label }}\n <title>{{ tick.value | date }}</title>\n </text>\n </g>\n }\n @for (tick of d.y1.yTicks; track $index) {\n <g>\n <rect\n class=\"tick\"\n x=\"0\"\n [attr.y]=\"d.y1.yScale(tick)\"\n width=\"100%\"\n height=\"1\"\n ></rect>\n <text\n class=\"y-tick-label\"\n x=\"0\"\n [attr.y]=\"d.y1.yScale(tick)\"\n dy=\"-4\"\n >\n {{ d.y1.valueFormatter(tick) }}\n </text>\n </g>\n }\n @for (tick of d.y2?.yTicks; track $index) {\n <g>\n <text\n class=\"y-tick-label\"\n [attr.x]=\"width\"\n [attr.y]=\"d.y2?.yScale(tick)\"\n text-anchor=\"end\"\n dy=\"-4\"\n >\n {{ d.y2?.valueFormatter(tick) }}\n </text>\n </g>\n }\n @if (hoveredMarker$ | async; as hoveredMarker) {\n <g>\n <line\n class=\"hover-rule\"\n [attr.x1]=\"hoveredMarker.marker.x\"\n [attr.y1]=\"d.y1.yScale(d.y1.yMin)\"\n [attr.x2]=\"hoveredMarker.marker.x\"\n [attr.y2]=\"d.y1.yScale(d.y1.yMax)\"\n stroke-width=\"2\"\n stroke-dasharray=\"4\"\n />\n </g>\n }\n <ng-template #seriesTpl let-series=\"series\" let-index=\"index\" let-y=\"y\">\n @if (series.visibility !== 'hidden') {\n <path\n class=\"data path\"\n [class.marker-hovered]=\"!!(hoveredMarker$ | async)\"\n [attr.d]=\"series.path\"\n fill=\"none\"\n stroke-width=\"2\"\n [attr.stroke]=\"series.stroke\"\n [attr.stroke-dasharray]=\"series.style === 'dashed' ? '4' : null\"\n ></path>\n }\n @if (getRange$ | async; as getRange) {\n @for (marker of series.markers; track $index) {\n @if (series.visibility !== 'hidden') {\n <circle\n class=\"data marker\"\n [class.focused]=\"\n (hoveredMarker$ | async)?.marker?.x === marker.x &&\n (groupedTooltips ||\n ((hoveredMarker$ | async)?.seriesIndex === index &&\n (hoveredMarker$ | async)?.y === y))\n \"\n [class.blurred]=\"\n (hoveredMarker$ | async) !== null &&\n ((hoveredMarker$ | async)?.marker?.x !== marker.x ||\n ((hoveredMarker$ | async)?.marker?.x === marker.x &&\n !groupedTooltips &&\n ((hoveredMarker$ | async)?.seriesIndex !== index ||\n (hoveredMarker$ | async)?.y !== y)))\n \"\n [attr.cx]=\"marker.x\"\n [attr.cy]=\"marker.y\"\n [attr.r]=\"POINT_RADIUS\"\n stroke-width=\"2\"\n [attr.stroke]=\"series.stroke\"\n (mouseover)=\"\n hoveredMarker$.next({\n event: $event,\n marker: marker,\n seriesIndex: index,\n y: y,\n })\n \"\n (mouseleave)=\"hoveredMarker$.next(null)\"\n (click)=\"\n markerClicked.emit(\n getMarkerClicked(getRange(marker.date), index, y)\n );\n hoveredMarker$.next(null)\n \"\n ></circle>\n }\n }\n }\n </ng-template>\n @for (series of d.y1.series; track $index; let i = $index) {\n <g>\n <ng-container\n *ngTemplateOutlet=\"\n seriesTpl;\n context: { series: series, index: i, y: 'y1' }\n \"\n ></ng-container>\n </g>\n }\n @for (series of d.y2?.series; track $index; let i = $index) {\n <g>\n <ng-container\n *ngTemplateOutlet=\"\n seriesTpl;\n context: { series: series, index: i, y: 'y2' }\n \"\n ></ng-container>\n </g>\n }\n </svg>\n }\n <legend>\n @for (item of legend$ | async; track $index) {\n <riv-legend-item\n [label]=\"item.label\"\n [colorToken]=\"item.colorToken\"\n [visibility]=\"item.visibility\"\n [clickable]=\"allowLegendToggle\"\n (itemClick)=\"\n allowLegendToggle\n ? toggleVisibility$.next({\n label: item.label,\n visibility:\n item.visibility === 'hidden' ? 'visible' : 'hidden',\n })\n : null\n \"\n ></riv-legend-item>\n }\n </legend>\n </div>\n} @else {\n <riv-zero-state [message]=\"zeroStateMessage\"></riv-zero-state>\n}\n\n@if (callout$ | async; as callout) {\n <riv-callout\n *riv-overlay\n [anchor]=\"callout?.anchor ?? null\"\n [isModal]=\"false\"\n [preferredPosition]=\"'center-right'\"\n [theme]=\"'light'\"\n >\n <div class=\"callout-content\">\n @for (metric of callout?.metrics; track $index) {\n <div class=\"callout-row\">\n <span class=\"series-label\">\n <riv-legend-item [colorToken]=\"metric.colorToken\"></riv-legend-item>\n <span>{{ metric.label }}</span>\n </span>\n <span>{{ metric.value }}</span>\n </div>\n }\n </div>\n </riv-callout>\n}\n\n<ng-template #controls>\n <riv-simple-select\n [optionGroups]=\"intervalOptions$ | async | rivOptionGroup\"\n [orderBy]=\"'source'\"\n [selectedOption]=\"selectedIntervalOption$ | async\"\n (selectedOptionChange)=\"setIntervalOption($event)\"\n ></riv-simple-select>\n</ng-template>\n",
|
|
22283
22126
|
styles: [".container{display:flex;flex-direction:column;gap:var(--size-xlarge)}.y-tick-label,.x-major-tick-label{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0);fill:var(--type-light-low-contrast)}.x-minor-tick-label{font-size:var(--type-2-font-size);line-height:var(--type-2-line-height-0);fill:var(--type-light-low-contrast);text-anchor:middle}.tick{fill:var(--gray-20)}.data.path{transition:stroke-opacity var(--short-transition)}.data.path.marker-hovered{stroke-opacity:.4}.data.marker{fill:var(--surface-light-0);transition:stroke-opacity var(--short-transition)}.data.marker.focused{stroke-opacity:1;filter:drop-shadow(0 1px 1px rgba(10,2,22,.15))}.data.marker.blurred{stroke-opacity:.4}.hover-rule{stroke:var(--gray-20)}legend{display:flex;flex-wrap:wrap;gap:var(--size-large);justify-content:flex-start;align-items:baseline}.callout-content{padding:var(--size-medium) var(--size-xlarge);display:flex;flex-direction:column}.callout-row{display:flex;padding:var(--size-medium) 0;gap:var(--size-medium);align-items:center;font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0)}.callout-row:not(:last-child){border-bottom:var(--border-width) solid var(--border-light)}.series-label{flex-grow:1;font-weight:var(--font-weight-heavy);display:flex;align-items:center;gap:var(--size-small)}\n"],
|
|
22284
22127
|
dependencies: [
|
|
22285
|
-
{
|
|
22286
|
-
kind: "directive",
|
|
22287
|
-
type: i1.NgForOf,
|
|
22288
|
-
selector: "[ngFor][ngForOf]",
|
|
22289
|
-
inputs: [
|
|
22290
|
-
"ngForOf",
|
|
22291
|
-
"ngForTrackBy",
|
|
22292
|
-
"ngForTemplate"
|
|
22293
|
-
]
|
|
22294
|
-
},
|
|
22295
|
-
{
|
|
22296
|
-
kind: "directive",
|
|
22297
|
-
type: i1.NgIf,
|
|
22298
|
-
selector: "[ngIf]",
|
|
22299
|
-
inputs: [
|
|
22300
|
-
"ngIf",
|
|
22301
|
-
"ngIfThen",
|
|
22302
|
-
"ngIfElse"
|
|
22303
|
-
]
|
|
22304
|
-
},
|
|
22305
22128
|
{
|
|
22306
22129
|
kind: "directive",
|
|
22307
22130
|
type: i1.NgTemplateOutlet,
|
|
@@ -22419,7 +22242,7 @@ i0.ɵɵngDeclareClassMetadata({
|
|
|
22419
22242
|
selector: "riv-time-series",
|
|
22420
22243
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
22421
22244
|
standalone: false,
|
|
22422
|
-
template: "
|
|
22245
|
+
template: "@if ((empty$ | async) === false) {\n <div class=\"container\" (rivClientSize)=\"width = $event.width\">\n @if (drawData$ | async; as d) {\n <svg xmlns=\"http://www.w3.org/2000/svg\" [attr.viewBox]=\"d.viewBox\">\n @for (tick of d.x.xMajorTicks; track tick.value) {\n <g>\n @if (d.x.xScale(tick.value) >= 0) {\n <text\n class=\"x-major-tick-label\"\n [attr.x]=\"d.x.xScale(tick.value)\"\n [attr.y]=\"HEIGHT - BOTTOM_OFFSET\"\n dx=\"4\"\n dy=\"-4\"\n >\n {{ tick.label }}\n </text>\n }\n </g>\n }\n @for (tick of d.x.xMinorTicks; track tick.value) {\n <g>\n <text\n class=\"x-minor-tick-label\"\n [attr.x]=\"d.x.xScale(tick.value)\"\n [attr.y]=\"HEIGHT - BOTTOM_OFFSET\"\n text-anchor=\"middle\"\n dominant-baseline=\"hanging\"\n dy=\"8\"\n >\n {{ tick.label }}\n <title>{{ tick.value | date }}</title>\n </text>\n </g>\n }\n @for (tick of d.y1.yTicks; track $index) {\n <g>\n <rect\n class=\"tick\"\n x=\"0\"\n [attr.y]=\"d.y1.yScale(tick)\"\n width=\"100%\"\n height=\"1\"\n ></rect>\n <text\n class=\"y-tick-label\"\n x=\"0\"\n [attr.y]=\"d.y1.yScale(tick)\"\n dy=\"-4\"\n >\n {{ d.y1.valueFormatter(tick) }}\n </text>\n </g>\n }\n @for (tick of d.y2?.yTicks; track $index) {\n <g>\n <text\n class=\"y-tick-label\"\n [attr.x]=\"width\"\n [attr.y]=\"d.y2?.yScale(tick)\"\n text-anchor=\"end\"\n dy=\"-4\"\n >\n {{ d.y2?.valueFormatter(tick) }}\n </text>\n </g>\n }\n @if (hoveredMarker$ | async; as hoveredMarker) {\n <g>\n <line\n class=\"hover-rule\"\n [attr.x1]=\"hoveredMarker.marker.x\"\n [attr.y1]=\"d.y1.yScale(d.y1.yMin)\"\n [attr.x2]=\"hoveredMarker.marker.x\"\n [attr.y2]=\"d.y1.yScale(d.y1.yMax)\"\n stroke-width=\"2\"\n stroke-dasharray=\"4\"\n />\n </g>\n }\n <ng-template #seriesTpl let-series=\"series\" let-index=\"index\" let-y=\"y\">\n @if (series.visibility !== 'hidden') {\n <path\n class=\"data path\"\n [class.marker-hovered]=\"!!(hoveredMarker$ | async)\"\n [attr.d]=\"series.path\"\n fill=\"none\"\n stroke-width=\"2\"\n [attr.stroke]=\"series.stroke\"\n [attr.stroke-dasharray]=\"series.style === 'dashed' ? '4' : null\"\n ></path>\n }\n @if (getRange$ | async; as getRange) {\n @for (marker of series.markers; track $index) {\n @if (series.visibility !== 'hidden') {\n <circle\n class=\"data marker\"\n [class.focused]=\"\n (hoveredMarker$ | async)?.marker?.x === marker.x &&\n (groupedTooltips ||\n ((hoveredMarker$ | async)?.seriesIndex === index &&\n (hoveredMarker$ | async)?.y === y))\n \"\n [class.blurred]=\"\n (hoveredMarker$ | async) !== null &&\n ((hoveredMarker$ | async)?.marker?.x !== marker.x ||\n ((hoveredMarker$ | async)?.marker?.x === marker.x &&\n !groupedTooltips &&\n ((hoveredMarker$ | async)?.seriesIndex !== index ||\n (hoveredMarker$ | async)?.y !== y)))\n \"\n [attr.cx]=\"marker.x\"\n [attr.cy]=\"marker.y\"\n [attr.r]=\"POINT_RADIUS\"\n stroke-width=\"2\"\n [attr.stroke]=\"series.stroke\"\n (mouseover)=\"\n hoveredMarker$.next({\n event: $event,\n marker: marker,\n seriesIndex: index,\n y: y,\n })\n \"\n (mouseleave)=\"hoveredMarker$.next(null)\"\n (click)=\"\n markerClicked.emit(\n getMarkerClicked(getRange(marker.date), index, y)\n );\n hoveredMarker$.next(null)\n \"\n ></circle>\n }\n }\n }\n </ng-template>\n @for (series of d.y1.series; track $index; let i = $index) {\n <g>\n <ng-container\n *ngTemplateOutlet=\"\n seriesTpl;\n context: { series: series, index: i, y: 'y1' }\n \"\n ></ng-container>\n </g>\n }\n @for (series of d.y2?.series; track $index; let i = $index) {\n <g>\n <ng-container\n *ngTemplateOutlet=\"\n seriesTpl;\n context: { series: series, index: i, y: 'y2' }\n \"\n ></ng-container>\n </g>\n }\n </svg>\n }\n <legend>\n @for (item of legend$ | async; track $index) {\n <riv-legend-item\n [label]=\"item.label\"\n [colorToken]=\"item.colorToken\"\n [visibility]=\"item.visibility\"\n [clickable]=\"allowLegendToggle\"\n (itemClick)=\"\n allowLegendToggle\n ? toggleVisibility$.next({\n label: item.label,\n visibility:\n item.visibility === 'hidden' ? 'visible' : 'hidden',\n })\n : null\n \"\n ></riv-legend-item>\n }\n </legend>\n </div>\n} @else {\n <riv-zero-state [message]=\"zeroStateMessage\"></riv-zero-state>\n}\n\n@if (callout$ | async; as callout) {\n <riv-callout\n *riv-overlay\n [anchor]=\"callout?.anchor ?? null\"\n [isModal]=\"false\"\n [preferredPosition]=\"'center-right'\"\n [theme]=\"'light'\"\n >\n <div class=\"callout-content\">\n @for (metric of callout?.metrics; track $index) {\n <div class=\"callout-row\">\n <span class=\"series-label\">\n <riv-legend-item [colorToken]=\"metric.colorToken\"></riv-legend-item>\n <span>{{ metric.label }}</span>\n </span>\n <span>{{ metric.value }}</span>\n </div>\n }\n </div>\n </riv-callout>\n}\n\n<ng-template #controls>\n <riv-simple-select\n [optionGroups]=\"intervalOptions$ | async | rivOptionGroup\"\n [orderBy]=\"'source'\"\n [selectedOption]=\"selectedIntervalOption$ | async\"\n (selectedOptionChange)=\"setIntervalOption($event)\"\n ></riv-simple-select>\n</ng-template>\n",
|
|
22423
22246
|
styles: [".container{display:flex;flex-direction:column;gap:var(--size-xlarge)}.y-tick-label,.x-major-tick-label{font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0);fill:var(--type-light-low-contrast)}.x-minor-tick-label{font-size:var(--type-2-font-size);line-height:var(--type-2-line-height-0);fill:var(--type-light-low-contrast);text-anchor:middle}.tick{fill:var(--gray-20)}.data.path{transition:stroke-opacity var(--short-transition)}.data.path.marker-hovered{stroke-opacity:.4}.data.marker{fill:var(--surface-light-0);transition:stroke-opacity var(--short-transition)}.data.marker.focused{stroke-opacity:1;filter:drop-shadow(0 1px 1px rgba(10,2,22,.15))}.data.marker.blurred{stroke-opacity:.4}.hover-rule{stroke:var(--gray-20)}legend{display:flex;flex-wrap:wrap;gap:var(--size-large);justify-content:flex-start;align-items:baseline}.callout-content{padding:var(--size-medium) var(--size-xlarge);display:flex;flex-direction:column}.callout-row{display:flex;padding:var(--size-medium) 0;gap:var(--size-medium);align-items:center;font-size:var(--type-1-font-size);line-height:var(--type-1-line-height-0)}.callout-row:not(:last-child){border-bottom:var(--border-width) solid var(--border-light)}.series-label{flex-grow:1;font-weight:var(--font-weight-heavy);display:flex;align-items:center;gap:var(--size-small)}\n"]
|
|
22424
22247
|
}]
|
|
22425
22248
|
}],
|