@rivet-health/design-system 11.2.1 → 11.2.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.
- package/esm2020/lib/content-toggle/text-toggle/text-toggle.component.mjs +17 -4
- package/fesm2015/rivet-health-design-system.mjs +16 -3
- package/fesm2015/rivet-health-design-system.mjs.map +1 -1
- package/fesm2020/rivet-health-design-system.mjs +16 -3
- package/fesm2020/rivet-health-design-system.mjs.map +1 -1
- package/lib/content-toggle/text-toggle/text-toggle.component.d.ts +6 -1
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ChangeDetectionStrategy, Component, Input } from '@angular/core';
|
|
1
|
+
import { ChangeDetectionStrategy, Component, EventEmitter, Input, Output, } from '@angular/core';
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
import * as i1 from "@angular/common";
|
|
4
4
|
import * as i2 from "../../icon/icon.component";
|
|
@@ -6,19 +6,32 @@ export class TextToggleComponent {
|
|
|
6
6
|
constructor() {
|
|
7
7
|
this.showLabel = '';
|
|
8
8
|
this.hideLabel = '';
|
|
9
|
+
this.colorToken = '';
|
|
9
10
|
this.open = false;
|
|
11
|
+
this.openChange = new EventEmitter();
|
|
12
|
+
}
|
|
13
|
+
get color() {
|
|
14
|
+
return `var(${this.colorToken})`;
|
|
15
|
+
}
|
|
16
|
+
toggleOpen() {
|
|
17
|
+
this.open = !this.open;
|
|
18
|
+
this.openChange.emit(this.open);
|
|
10
19
|
}
|
|
11
20
|
}
|
|
12
21
|
TextToggleComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TextToggleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
13
|
-
TextToggleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: TextToggleComponent, selector: "riv-text-toggle", inputs: { showLabel: "showLabel", hideLabel: "hideLabel", open: "open" }, ngImport: i0, template: "<button
|
|
22
|
+
TextToggleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: TextToggleComponent, selector: "riv-text-toggle", inputs: { showLabel: "showLabel", hideLabel: "hideLabel", colorToken: "colorToken", open: "open" }, outputs: { openChange: "openChange" }, ngImport: i0, template: "<button\n class=\"toggle\"\n type=\"button\"\n (click)=\"toggleOpen()\"\n type=\"button\"\n [style.color]=\"color\"\n>\n <riv-icon [class.open]=\"open\" [name]=\"'ChevronDown'\" [size]=\"24\"></riv-icon>\n <div>{{ open ? hideLabel : showLabel }}</div>\n</button>\n<div *ngIf=\"open\">\n <ng-content></ng-content>\n</div>\n", styles: [".toggle{padding:var(--size-xxsmall);display:flex;align-items:center}.toggle:hover{cursor:pointer}button{color:inherit}riv-icon{transition:transform var(--medium-transition)}riv-icon.open{transform:rotate(-180deg)}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i2.IconComponent, selector: "riv-icon", inputs: ["name", "size", "customSize", "strokeWidth"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
14
23
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TextToggleComponent, decorators: [{
|
|
15
24
|
type: Component,
|
|
16
|
-
args: [{ selector: 'riv-text-toggle', changeDetection: ChangeDetectionStrategy.OnPush, template: "<button
|
|
25
|
+
args: [{ selector: 'riv-text-toggle', changeDetection: ChangeDetectionStrategy.OnPush, template: "<button\n class=\"toggle\"\n type=\"button\"\n (click)=\"toggleOpen()\"\n type=\"button\"\n [style.color]=\"color\"\n>\n <riv-icon [class.open]=\"open\" [name]=\"'ChevronDown'\" [size]=\"24\"></riv-icon>\n <div>{{ open ? hideLabel : showLabel }}</div>\n</button>\n<div *ngIf=\"open\">\n <ng-content></ng-content>\n</div>\n", styles: [".toggle{padding:var(--size-xxsmall);display:flex;align-items:center}.toggle:hover{cursor:pointer}button{color:inherit}riv-icon{transition:transform var(--medium-transition)}riv-icon.open{transform:rotate(-180deg)}\n"] }]
|
|
17
26
|
}], propDecorators: { showLabel: [{
|
|
18
27
|
type: Input
|
|
19
28
|
}], hideLabel: [{
|
|
20
29
|
type: Input
|
|
30
|
+
}], colorToken: [{
|
|
31
|
+
type: Input
|
|
21
32
|
}], open: [{
|
|
22
33
|
type: Input
|
|
34
|
+
}], openChange: [{
|
|
35
|
+
type: Output
|
|
23
36
|
}] } });
|
|
24
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
37
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoidGV4dC10b2dnbGUuY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvcml2L3NyYy9saWIvY29udGVudC10b2dnbGUvdGV4dC10b2dnbGUvdGV4dC10b2dnbGUuY29tcG9uZW50LnRzIiwiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvcml2L3NyYy9saWIvY29udGVudC10b2dnbGUvdGV4dC10b2dnbGUvdGV4dC10b2dnbGUuY29tcG9uZW50Lmh0bWwiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUNMLHVCQUF1QixFQUN2QixTQUFTLEVBQ1QsWUFBWSxFQUNaLEtBQUssRUFDTCxNQUFNLEdBQ1AsTUFBTSxlQUFlLENBQUM7Ozs7QUFRdkIsTUFBTSxPQUFPLG1CQUFtQjtJQU5oQztRQVFFLGNBQVMsR0FBVyxFQUFFLENBQUM7UUFHdkIsY0FBUyxHQUFXLEVBQUUsQ0FBQztRQUd2QixlQUFVLEdBQVcsRUFBRSxDQUFDO1FBT3hCLFNBQUksR0FBWSxLQUFLLENBQUM7UUFHdEIsZUFBVSxHQUEwQixJQUFJLFlBQVksRUFBVyxDQU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KVxuICBzaG93TGFiZWw6IHN0cmluZyA9ICcnO1xuXG4gIEBJbnB1dCgpXG4gIGhpZGVMYWJlbDogc3RyaW5nID0gJyc7XG5cbiAgQElucHV0KClcbiAgY29sb3JUb2tlbjogc3RyaW5nID0gJyc7XG5cbiAgZ2V0IGNvbG9yKCk6IHN0cmluZyB7XG4gICAgcmV0dXJuIGB2YXIoJHt0aGlzLmNvbG9yVG9rZW59KWA7XG4gIH1cblxuICBASW5wdXQoKVxuICBvcGVuOiBib29sZWFuID0gZmFsc2U7XG5cbiAgQE91dHB1dCgpXG4gIG9wZW5DaGFuZ2U6IEV2ZW50RW1pdHRlcjxib29sZWFuPiA9IG5ldyBFdmVudEVtaXR0ZXI8Ym9vbGVhbj4oKTtcblxuICB0b2dnbGVPcGVuKCkge1xuICAgIHRoaXMub3BlbiA9ICF0aGlzLm9wZW47XG4gICAgdGhpcy5vcGVuQ2hhbmdlLmVtaXQodGhpcy5vcGVuKTtcbiAgfVxufVxuIiwiPGJ1dHRvblxuICBjbGFzcz1cInRvZ2dsZVwiXG4gIHR5cGU9XCJidXR0b25cIlxuICAoY2xpY2spPVwidG9nZ2xlT3BlbigpXCJcbiAgdHlwZT1cImJ1dHRvblwiXG4gIFtzdHlsZS5jb2xvcl09XCJjb2xvclwiXG4+XG4gIDxyaXYtaWNvbiBbY2xhc3Mub3Blbl09XCJvcGVuXCIgW25hbWVdPVwiJ0NoZXZyb25Eb3duJ1wiIFtzaXplXT1cIjI0XCI+PC9yaXYtaWNvbj5cbiAgPGRpdj57eyBvcGVuID8gaGlkZUxhYmVsIDogc2hvd0xhYmVsIH19PC9kaXY+XG48L2J1dHRvbj5cbjxkaXYgKm5nSWY9XCJvcGVuXCI+XG4gIDxuZy1jb250ZW50PjwvbmctY29udGVudD5cbjwvZGl2PlxuIl19
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Component, ChangeDetectionStrategy, Input, HostBinding, Injectable, Inject, Pipe, Directive,
|
|
2
|
+
import { Component, ChangeDetectionStrategy, Input, HostBinding, EventEmitter, Output, Injectable, Inject, Pipe, Directive, ViewChild, HostListener, ViewContainerRef, Self, ElementRef, ContentChild, TemplateRef, NgModule } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/common';
|
|
4
4
|
import { DOCUMENT, DatePipe as DatePipe$1, DecimalPipe, CurrencyPipe, PercentPipe, CommonModule } from '@angular/common';
|
|
5
5
|
import { __awaiter, __asyncValues, __asyncGenerator, __await, __asyncDelegator } from 'tslib';
|
|
@@ -368,20 +368,33 @@ class TextToggleComponent {
|
|
|
368
368
|
constructor() {
|
|
369
369
|
this.showLabel = '';
|
|
370
370
|
this.hideLabel = '';
|
|
371
|
+
this.colorToken = '';
|
|
371
372
|
this.open = false;
|
|
373
|
+
this.openChange = new EventEmitter();
|
|
374
|
+
}
|
|
375
|
+
get color() {
|
|
376
|
+
return `var(${this.colorToken})`;
|
|
377
|
+
}
|
|
378
|
+
toggleOpen() {
|
|
379
|
+
this.open = !this.open;
|
|
380
|
+
this.openChange.emit(this.open);
|
|
372
381
|
}
|
|
373
382
|
}
|
|
374
383
|
TextToggleComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TextToggleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
375
|
-
TextToggleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: TextToggleComponent, selector: "riv-text-toggle", inputs: { showLabel: "showLabel", hideLabel: "hideLabel", open: "open" }, ngImport: i0, template: "<button
|
|
384
|
+
TextToggleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: TextToggleComponent, selector: "riv-text-toggle", inputs: { showLabel: "showLabel", hideLabel: "hideLabel", colorToken: "colorToken", open: "open" }, outputs: { openChange: "openChange" }, ngImport: i0, template: "<button\n class=\"toggle\"\n type=\"button\"\n (click)=\"toggleOpen()\"\n type=\"button\"\n [style.color]=\"color\"\n>\n <riv-icon [class.open]=\"open\" [name]=\"'ChevronDown'\" [size]=\"24\"></riv-icon>\n <div>{{ open ? hideLabel : showLabel }}</div>\n</button>\n<div *ngIf=\"open\">\n <ng-content></ng-content>\n</div>\n", styles: [".toggle{padding:var(--size-xxsmall);display:flex;align-items:center}.toggle:hover{cursor:pointer}button{color:inherit}riv-icon{transition:transform var(--medium-transition)}riv-icon.open{transform:rotate(-180deg)}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: IconComponent, selector: "riv-icon", inputs: ["name", "size", "customSize", "strokeWidth"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
376
385
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: TextToggleComponent, decorators: [{
|
|
377
386
|
type: Component,
|
|
378
|
-
args: [{ selector: 'riv-text-toggle', changeDetection: ChangeDetectionStrategy.OnPush, template: "<button
|
|
387
|
+
args: [{ selector: 'riv-text-toggle', changeDetection: ChangeDetectionStrategy.OnPush, template: "<button\n class=\"toggle\"\n type=\"button\"\n (click)=\"toggleOpen()\"\n type=\"button\"\n [style.color]=\"color\"\n>\n <riv-icon [class.open]=\"open\" [name]=\"'ChevronDown'\" [size]=\"24\"></riv-icon>\n <div>{{ open ? hideLabel : showLabel }}</div>\n</button>\n<div *ngIf=\"open\">\n <ng-content></ng-content>\n</div>\n", styles: [".toggle{padding:var(--size-xxsmall);display:flex;align-items:center}.toggle:hover{cursor:pointer}button{color:inherit}riv-icon{transition:transform var(--medium-transition)}riv-icon.open{transform:rotate(-180deg)}\n"] }]
|
|
379
388
|
}], propDecorators: { showLabel: [{
|
|
380
389
|
type: Input
|
|
381
390
|
}], hideLabel: [{
|
|
382
391
|
type: Input
|
|
392
|
+
}], colorToken: [{
|
|
393
|
+
type: Input
|
|
383
394
|
}], open: [{
|
|
384
395
|
type: Input
|
|
396
|
+
}], openChange: [{
|
|
397
|
+
type: Output
|
|
385
398
|
}] } });
|
|
386
399
|
|
|
387
400
|
class DownloadService {
|