suis 3.0.0 → 3.0.1
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +1 -1
- package/esm2022/lib/components/suis-input-checkbox/suis-input-checkbox.component.mjs +3 -3
- package/esm2022/lib/components/suis-toggle/suis-toggle.component.mjs +3 -3
- package/esm2022/lib/shared/classes/suis-checkbox.base.mjs +6 -13
- package/fesm2022/suis.mjs +8 -15
- package/fesm2022/suis.mjs.map +1 -1
- package/lib/shared/classes/suis-checkbox.base.d.ts +1 -5
- package/package.json +1 -1
package/README.md
CHANGED
@@ -13,7 +13,7 @@ export class SuisInputCheckboxComponent extends SuisCheckboxBase {
|
|
13
13
|
multi: true,
|
14
14
|
useExisting: forwardRef(() => SuisInputCheckboxComponent),
|
15
15
|
},
|
16
|
-
], usesInheritance: true, ngImport: i0, template: "<input\
|
16
|
+
], usesInheritance: true, ngImport: i0, template: "<input\n type=\"checkbox\"\n class=\"suis-input-checkbox\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [disabled]=\"readonly\"\n/>\n\n<suis-label\n class=\"suis-input-checkbox__label\"\n [class.suis-input-checkbox__label--invalid]=\"invalid\"\n [class.suis-input-checkbox__label--readonly]=\"readonly\"\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\n (click)=\"onChange($event)\"\n>\n <div\n [tabindex]=\"readonly ? -1 : 0\"\n class=\"suis-input-checkbox__check\"\n [class.suis-input-checkbox__check--invalid]=\"invalid\"\n [class.suis-input-checkbox__check--readonly]=\"readonly\"\n >\n <suis-icon\n *ngIf=\"value\"\n type=\"check\"\n size=\"lg\"\n [color]=\"readonly ? 'tertiary' : 'primary'\"\n ></suis-icon>\n </div>\n <ng-content></ng-content>\n</suis-label>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:flex}.suis-input-checkbox{display:none}.suis-input-checkbox__label--invalid{color:#ff4757}.suis-input-checkbox__label--readonly{cursor:not-allowed}.suis-input-checkbox__check{width:1.25rem;height:1.25rem;border:.0625rem solid #dcdde1;display:flex;justify-content:center;align-items:center;margin-right:.5rem;background-color:#fff;border-radius:.25rem}.suis-input-checkbox__check:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-input-checkbox__check--readonly{border:.0625rem solid #dcdde1;cursor:not-allowed}.suis-input-checkbox__check--readonly:focus{box-shadow:none}.suis-input-checkbox__check--invalid{border:.0625rem solid #ff4757;color:#ff4757}.suis-input-checkbox__check--invalid:focus{box-shadow:0 2px 5px #ff4757bf}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: SuisLabelComponent, selector: "suis-label", inputs: ["for", "required", "pointer", "readonly"] }, { kind: "component", type: SuisIconComponent, selector: "suis-icon", inputs: ["size", "color", "type", "outlined", "filled", "pointer", "bold"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
17
17
|
}
|
18
18
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: SuisInputCheckboxComponent, decorators: [{
|
19
19
|
type: Component,
|
@@ -23,6 +23,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
23
23
|
multi: true,
|
24
24
|
useExisting: forwardRef(() => SuisInputCheckboxComponent),
|
25
25
|
},
|
26
|
-
], template: "<input\
|
26
|
+
], template: "<input\n type=\"checkbox\"\n class=\"suis-input-checkbox\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [disabled]=\"readonly\"\n/>\n\n<suis-label\n class=\"suis-input-checkbox__label\"\n [class.suis-input-checkbox__label--invalid]=\"invalid\"\n [class.suis-input-checkbox__label--readonly]=\"readonly\"\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\n (click)=\"onChange($event)\"\n>\n <div\n [tabindex]=\"readonly ? -1 : 0\"\n class=\"suis-input-checkbox__check\"\n [class.suis-input-checkbox__check--invalid]=\"invalid\"\n [class.suis-input-checkbox__check--readonly]=\"readonly\"\n >\n <suis-icon\n *ngIf=\"value\"\n type=\"check\"\n size=\"lg\"\n [color]=\"readonly ? 'tertiary' : 'primary'\"\n ></suis-icon>\n </div>\n <ng-content></ng-content>\n</suis-label>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:flex}.suis-input-checkbox{display:none}.suis-input-checkbox__label--invalid{color:#ff4757}.suis-input-checkbox__label--readonly{cursor:not-allowed}.suis-input-checkbox__check{width:1.25rem;height:1.25rem;border:.0625rem solid #dcdde1;display:flex;justify-content:center;align-items:center;margin-right:.5rem;background-color:#fff;border-radius:.25rem}.suis-input-checkbox__check:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-input-checkbox__check--readonly{border:.0625rem solid #dcdde1;cursor:not-allowed}.suis-input-checkbox__check--readonly:focus{box-shadow:none}.suis-input-checkbox__check--invalid{border:.0625rem solid #ff4757;color:#ff4757}.suis-input-checkbox__check--invalid:focus{box-shadow:0 2px 5px #ff4757bf}\n"] }]
|
27
27
|
}] });
|
28
|
-
//# sourceMappingURL=data:application/json;base64,
|
28
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic3Vpcy1pbnB1dC1jaGVja2JveC5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9saWJzL3N1aXMvc3JjL2xpYi9jb21wb25lbnRzL3N1aXMtaW5wdXQtY2hlY2tib3gvc3Vpcy1pbnB1dC1jaGVja2JveC5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi8uLi8uLi8uLi9saWJzL3N1aXMvc3JjL2xpYi9jb21wb25lbnRzL3N1aXMtaW5wdXQtY2hlY2tib3g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dXQtY2hlY2tib3hfX2NoZWNrLS1yZWFkb25seV09XCJyZWFkb25seVwiXG4gID5cbiAgICA8c3Vpcy1pY29uXG4gICAgICAqbmdJZj1cInZhbHVlXCJcbiAgICAgIHR5cGU9XCJjaGVja1wiXG4gICAgICBzaXplPVwibGdcIlxuICAgICAgW2NvbG9yXT1cInJlYWRvbmx5ID8gJ3RlcnRpYXJ5JyA6ICdwcmltYXJ5J1wiXG4gICAgPjwvc3Vpcy1pY29uPlxuICA8L2Rpdj5cbiAgPG5nLWNvbnRlbnQ+PC9uZy1jb250ZW50PlxuPC9zdWlzLWxhYmVsPlxuIl19
|
@@ -11,7 +11,7 @@ export class SuisToggleComponent extends SuisCheckboxBase {
|
|
11
11
|
multi: true,
|
12
12
|
useExisting: forwardRef(() => SuisToggleComponent),
|
13
13
|
},
|
14
|
-
], usesInheritance: true, ngImport: i0, template: "<input\n
|
14
|
+
], usesInheritance: true, ngImport: i0, template: "<input\n type=\"checkbox\"\n class=\"suis-toggle\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [disabled]=\"readonly\"\n/>\n\n<suis-label\n class=\"suis-toggle__label\"\n [class.suis-toggle__label--invalid]=\"invalid\"\n [class.suis-toggle__label--readonly]=\"readonly\"\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\n (click)=\"onChange($event)\"\n>\n <div\n [tabindex]=\"readonly ? -1 : 0\"\n class=\"suis-toggle__container\"\n [class.suis-toggle__container--invalid]=\"invalid\"\n [class.suis-toggle__container--readonly]=\"readonly\"\n >\n <div\n class=\"suis-toggle__container__thumb\"\n [class.suis-toggle__container__thumb--active]=\"value\"\n [class.suis-toggle__container__thumb--invalid]=\"invalid\"\n [class.suis-toggle__container__thumb--readonly]=\"readonly\"\n ></div>\n </div>\n <ng-content></ng-content>\n</suis-label>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:flex}.suis-toggle{display:none}.suis-toggle:checked~suis-label ::ng-deep .suis-toggle__container{border:.0625rem solid #192a56}.suis-toggle__label--invalid{color:#ff4757}.suis-toggle__label--readonly{cursor:not-allowed}.suis-toggle__container{width:2.25rem;height:1.25rem;border:.0625rem solid #dcdde1;border-radius:1rem;display:flex;align-items:center;margin-right:.5rem;background-color:#fff}.suis-toggle__container:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-toggle__container--readonly{border:.0625rem solid #dcdde1;cursor:not-allowed}.suis-toggle__container--readonly:focus{box-shadow:none}.suis-toggle__container--invalid{border:.0625rem solid #ff4757}.suis-toggle__container--invalid:focus{box-shadow:0 2px 5px #ff4757bf}.suis-toggle__container__thumb{border-radius:100%;height:.75rem;width:.75rem;background-color:#dcdde1;transform:translate(.25rem);transition:.25s ease-in-out}.suis-toggle__container__thumb--invalid{background-color:#ff4757d9}.suis-toggle__container__thumb--active{background-color:#192a56;transform:translate(1.125rem)}.suis-toggle__container__thumb--readonly{background-color:#dcdde1}\n"], dependencies: [{ kind: "component", type: SuisLabelComponent, selector: "suis-label", inputs: ["for", "required", "pointer", "readonly"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
15
15
|
}
|
16
16
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: SuisToggleComponent, decorators: [{
|
17
17
|
type: Component,
|
@@ -21,6 +21,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
21
21
|
multi: true,
|
22
22
|
useExisting: forwardRef(() => SuisToggleComponent),
|
23
23
|
},
|
24
|
-
], template: "<input\n
|
24
|
+
], template: "<input\n type=\"checkbox\"\n class=\"suis-toggle\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [disabled]=\"readonly\"\n/>\n\n<suis-label\n class=\"suis-toggle__label\"\n [class.suis-toggle__label--invalid]=\"invalid\"\n [class.suis-toggle__label--readonly]=\"readonly\"\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\n (click)=\"onChange($event)\"\n>\n <div\n [tabindex]=\"readonly ? -1 : 0\"\n class=\"suis-toggle__container\"\n [class.suis-toggle__container--invalid]=\"invalid\"\n [class.suis-toggle__container--readonly]=\"readonly\"\n >\n <div\n class=\"suis-toggle__container__thumb\"\n [class.suis-toggle__container__thumb--active]=\"value\"\n [class.suis-toggle__container__thumb--invalid]=\"invalid\"\n [class.suis-toggle__container__thumb--readonly]=\"readonly\"\n ></div>\n </div>\n <ng-content></ng-content>\n</suis-label>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:flex}.suis-toggle{display:none}.suis-toggle:checked~suis-label ::ng-deep .suis-toggle__container{border:.0625rem solid #192a56}.suis-toggle__label--invalid{color:#ff4757}.suis-toggle__label--readonly{cursor:not-allowed}.suis-toggle__container{width:2.25rem;height:1.25rem;border:.0625rem solid #dcdde1;border-radius:1rem;display:flex;align-items:center;margin-right:.5rem;background-color:#fff}.suis-toggle__container:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-toggle__container--readonly{border:.0625rem solid #dcdde1;cursor:not-allowed}.suis-toggle__container--readonly:focus{box-shadow:none}.suis-toggle__container--invalid{border:.0625rem solid #ff4757}.suis-toggle__container--invalid:focus{box-shadow:0 2px 5px #ff4757bf}.suis-toggle__container__thumb{border-radius:100%;height:.75rem;width:.75rem;background-color:#dcdde1;transform:translate(.25rem);transition:.25s ease-in-out}.suis-toggle__container__thumb--invalid{background-color:#ff4757d9}.suis-toggle__container__thumb--active{background-color:#192a56;transform:translate(1.125rem)}.suis-toggle__container__thumb--readonly{background-color:#dcdde1}\n"] }]
|
25
25
|
}] });
|
26
|
-
//# sourceMappingURL=data:application/json;base64,
|
26
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaW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CJcbiAgICAgIFtjbGFzcy5zdWlzLXRvZ2dsZV9fY29udGFpbmVyX190aHVtYi0taW52YWxpZF09XCJpbnZhbGlkXCJcbiAgICAgIFtjbGFzcy5zdWlzLXRvZ2dsZV9fY29udGFpbmVyX190aHVtYi0tcmVhZG9ubHldPVwicmVhZG9ubHlcIlxuICAgID48L2Rpdj5cbiAgPC9kaXY+XG4gIDxuZy1jb250ZW50PjwvbmctY29udGVudD5cbjwvc3Vpcy1sYWJlbD5cbiJdfQ==
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { Directive,
|
1
|
+
import { Directive, Input } from '@angular/core';
|
2
2
|
import { SuisInputBase } from './suis-input.base';
|
3
3
|
import * as i0 from "@angular/core";
|
4
4
|
export class SuisCheckboxBase extends SuisInputBase {
|
@@ -11,31 +11,24 @@ export class SuisCheckboxBase extends SuisInputBase {
|
|
11
11
|
*/
|
12
12
|
this.required = false;
|
13
13
|
}
|
14
|
-
ngAfterViewInit() {
|
15
|
-
if (this.value)
|
16
|
-
(this.checkboxInput?.nativeElement).checked = true;
|
17
|
-
}
|
18
14
|
writeValue(obj) {
|
19
15
|
this.value = obj;
|
20
16
|
this._onChange(this.value);
|
21
17
|
this.cdRef.markForCheck();
|
22
18
|
}
|
23
19
|
onChange(event) {
|
24
|
-
|
25
|
-
this.value =
|
20
|
+
event.stopPropagation();
|
21
|
+
this.value = !this.value;
|
26
22
|
this._onChange(this.value);
|
27
23
|
this.changed.emit(this.value);
|
28
24
|
this.cdRef.markForCheck();
|
29
25
|
}
|
30
26
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: SuisCheckboxBase, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
|
31
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.13", type: SuisCheckboxBase, inputs: { required: "required" },
|
27
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.13", type: SuisCheckboxBase, inputs: { required: "required" }, usesInheritance: true, ngImport: i0 }); }
|
32
28
|
}
|
33
29
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: SuisCheckboxBase, decorators: [{
|
34
30
|
type: Directive
|
35
|
-
}], propDecorators: {
|
36
|
-
type: ViewChild,
|
37
|
-
args: ['input']
|
38
|
-
}], required: [{
|
31
|
+
}], propDecorators: { required: [{
|
39
32
|
type: Input
|
40
33
|
}] } });
|
41
|
-
//# sourceMappingURL=data:application/json;base64,
|
34
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoic3Vpcy1jaGVja2JveC5iYXNlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vbGlicy9zdWlzL3NyYy9saWIvc2hhcmVkL2NsYXNzZXMvc3Vpcy1jaGVja2JveC5iYXNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBRSxTQUFTLEVBQUUsS0FBSyxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBQ2pELE9BQU8sRUFBRSxhQUFhLEVBQUUsTUFBTSxtQkFBbUIsQ0FBQzs7QUFHbEQsTUFBTSxPQUFnQixnQkFBaUIsU0FBUSxhQUFhO0lBRDVEOztRQUVFLGdCQUFnQjtRQUNoQixVQUFLLEdBQVksS0FBSyxDQUFDO1FBRXZCOztXQUVHO1FBQ00sYUFBUSxHQUFZLEtBQUssQ0FBQztLQWVwQztJQWJVLFVBQVUsQ0FBQyxHQUFZO1FBQzlCLElBQUksQ0FBQyxLQUFLLEdBQUcsR0FBRyxDQUFDO1FBQ2pCLElBQUksQ0FBQyxTQUFTLENBQUMsSUFBSSxDQUFDLEtBQUssQ0FBQyxDQUFDO1FBQzNCLElBQUksQ0FBQyxLQUFLLENBQUMsWUFBWSxFQUFFLENBQU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zLnZhbHVlID0gb2JqO1xuICAgIHRoaXMuX29uQ2hhbmdlKHRoaXMudmFsdWUpO1xuICAgIHRoaXMuY2RSZWYubWFya0ZvckNoZWNrKCk7XG4gIH1cblxuICBvbkNoYW5nZShldmVudDogRXZlbnQpOiB2b2lkIHtcbiAgICBldmVudC5zdG9wUHJvcGFnYXRpb24oKTtcbiAgICB0aGlzLnZhbHVlID0gIXRoaXMudmFsdWU7XG4gICAgdGhpcy5fb25DaGFuZ2UodGhpcy52YWx1ZSk7XG4gICAgdGhpcy5jaGFuZ2VkLmVtaXQodGhpcy52YWx1ZSk7XG4gICAgdGhpcy5jZFJlZi5tYXJrRm9yQ2hlY2soKTtcbiAgfVxufVxuIl19
|
package/fesm2022/suis.mjs
CHANGED
@@ -860,31 +860,24 @@ class SuisCheckboxBase extends SuisInputBase {
|
|
860
860
|
*/
|
861
861
|
this.required = false;
|
862
862
|
}
|
863
|
-
ngAfterViewInit() {
|
864
|
-
if (this.value)
|
865
|
-
(this.checkboxInput?.nativeElement).checked = true;
|
866
|
-
}
|
867
863
|
writeValue(obj) {
|
868
864
|
this.value = obj;
|
869
865
|
this._onChange(this.value);
|
870
866
|
this.cdRef.markForCheck();
|
871
867
|
}
|
872
868
|
onChange(event) {
|
873
|
-
|
874
|
-
this.value =
|
869
|
+
event.stopPropagation();
|
870
|
+
this.value = !this.value;
|
875
871
|
this._onChange(this.value);
|
876
872
|
this.changed.emit(this.value);
|
877
873
|
this.cdRef.markForCheck();
|
878
874
|
}
|
879
875
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: SuisCheckboxBase, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
|
880
|
-
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.13", type: SuisCheckboxBase, inputs: { required: "required" },
|
876
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "18.2.13", type: SuisCheckboxBase, inputs: { required: "required" }, usesInheritance: true, ngImport: i0 }); }
|
881
877
|
}
|
882
878
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: SuisCheckboxBase, decorators: [{
|
883
879
|
type: Directive
|
884
|
-
}], propDecorators: {
|
885
|
-
type: ViewChild,
|
886
|
-
args: ['input']
|
887
|
-
}], required: [{
|
880
|
+
}], propDecorators: { required: [{
|
888
881
|
type: Input
|
889
882
|
}] } });
|
890
883
|
|
@@ -896,7 +889,7 @@ class SuisInputCheckboxComponent extends SuisCheckboxBase {
|
|
896
889
|
multi: true,
|
897
890
|
useExisting: forwardRef(() => SuisInputCheckboxComponent),
|
898
891
|
},
|
899
|
-
], usesInheritance: true, ngImport: i0, template: "<input\
|
892
|
+
], usesInheritance: true, ngImport: i0, template: "<input\n type=\"checkbox\"\n class=\"suis-input-checkbox\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [disabled]=\"readonly\"\n/>\n\n<suis-label\n class=\"suis-input-checkbox__label\"\n [class.suis-input-checkbox__label--invalid]=\"invalid\"\n [class.suis-input-checkbox__label--readonly]=\"readonly\"\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\n (click)=\"onChange($event)\"\n>\n <div\n [tabindex]=\"readonly ? -1 : 0\"\n class=\"suis-input-checkbox__check\"\n [class.suis-input-checkbox__check--invalid]=\"invalid\"\n [class.suis-input-checkbox__check--readonly]=\"readonly\"\n >\n <suis-icon\n *ngIf=\"value\"\n type=\"check\"\n size=\"lg\"\n [color]=\"readonly ? 'tertiary' : 'primary'\"\n ></suis-icon>\n </div>\n <ng-content></ng-content>\n</suis-label>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:flex}.suis-input-checkbox{display:none}.suis-input-checkbox__label--invalid{color:#ff4757}.suis-input-checkbox__label--readonly{cursor:not-allowed}.suis-input-checkbox__check{width:1.25rem;height:1.25rem;border:.0625rem solid #dcdde1;display:flex;justify-content:center;align-items:center;margin-right:.5rem;background-color:#fff;border-radius:.25rem}.suis-input-checkbox__check:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-input-checkbox__check--readonly{border:.0625rem solid #dcdde1;cursor:not-allowed}.suis-input-checkbox__check--readonly:focus{box-shadow:none}.suis-input-checkbox__check--invalid{border:.0625rem solid #ff4757;color:#ff4757}.suis-input-checkbox__check--invalid:focus{box-shadow:0 2px 5px #ff4757bf}\n"], dependencies: [{ kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: SuisLabelComponent, selector: "suis-label", inputs: ["for", "required", "pointer", "readonly"] }, { kind: "component", type: SuisIconComponent, selector: "suis-icon", inputs: ["size", "color", "type", "outlined", "filled", "pointer", "bold"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
900
893
|
}
|
901
894
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: SuisInputCheckboxComponent, decorators: [{
|
902
895
|
type: Component,
|
@@ -906,7 +899,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
906
899
|
multi: true,
|
907
900
|
useExisting: forwardRef(() => SuisInputCheckboxComponent),
|
908
901
|
},
|
909
|
-
], template: "<input\
|
902
|
+
], template: "<input\n type=\"checkbox\"\n class=\"suis-input-checkbox\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [disabled]=\"readonly\"\n/>\n\n<suis-label\n class=\"suis-input-checkbox__label\"\n [class.suis-input-checkbox__label--invalid]=\"invalid\"\n [class.suis-input-checkbox__label--readonly]=\"readonly\"\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\n (click)=\"onChange($event)\"\n>\n <div\n [tabindex]=\"readonly ? -1 : 0\"\n class=\"suis-input-checkbox__check\"\n [class.suis-input-checkbox__check--invalid]=\"invalid\"\n [class.suis-input-checkbox__check--readonly]=\"readonly\"\n >\n <suis-icon\n *ngIf=\"value\"\n type=\"check\"\n size=\"lg\"\n [color]=\"readonly ? 'tertiary' : 'primary'\"\n ></suis-icon>\n </div>\n <ng-content></ng-content>\n</suis-label>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:flex}.suis-input-checkbox{display:none}.suis-input-checkbox__label--invalid{color:#ff4757}.suis-input-checkbox__label--readonly{cursor:not-allowed}.suis-input-checkbox__check{width:1.25rem;height:1.25rem;border:.0625rem solid #dcdde1;display:flex;justify-content:center;align-items:center;margin-right:.5rem;background-color:#fff;border-radius:.25rem}.suis-input-checkbox__check:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-input-checkbox__check--readonly{border:.0625rem solid #dcdde1;cursor:not-allowed}.suis-input-checkbox__check--readonly:focus{box-shadow:none}.suis-input-checkbox__check--invalid{border:.0625rem solid #ff4757;color:#ff4757}.suis-input-checkbox__check--invalid:focus{box-shadow:0 2px 5px #ff4757bf}\n"] }]
|
910
903
|
}] });
|
911
904
|
|
912
905
|
class SuisInputChipsComponent extends SuisInputBase {
|
@@ -2590,7 +2583,7 @@ class SuisToggleComponent extends SuisCheckboxBase {
|
|
2590
2583
|
multi: true,
|
2591
2584
|
useExisting: forwardRef(() => SuisToggleComponent),
|
2592
2585
|
},
|
2593
|
-
], usesInheritance: true, ngImport: i0, template: "<input\n
|
2586
|
+
], usesInheritance: true, ngImport: i0, template: "<input\n type=\"checkbox\"\n class=\"suis-toggle\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [disabled]=\"readonly\"\n/>\n\n<suis-label\n class=\"suis-toggle__label\"\n [class.suis-toggle__label--invalid]=\"invalid\"\n [class.suis-toggle__label--readonly]=\"readonly\"\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\n (click)=\"onChange($event)\"\n>\n <div\n [tabindex]=\"readonly ? -1 : 0\"\n class=\"suis-toggle__container\"\n [class.suis-toggle__container--invalid]=\"invalid\"\n [class.suis-toggle__container--readonly]=\"readonly\"\n >\n <div\n class=\"suis-toggle__container__thumb\"\n [class.suis-toggle__container__thumb--active]=\"value\"\n [class.suis-toggle__container__thumb--invalid]=\"invalid\"\n [class.suis-toggle__container__thumb--readonly]=\"readonly\"\n ></div>\n </div>\n <ng-content></ng-content>\n</suis-label>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:flex}.suis-toggle{display:none}.suis-toggle:checked~suis-label ::ng-deep .suis-toggle__container{border:.0625rem solid #192a56}.suis-toggle__label--invalid{color:#ff4757}.suis-toggle__label--readonly{cursor:not-allowed}.suis-toggle__container{width:2.25rem;height:1.25rem;border:.0625rem solid #dcdde1;border-radius:1rem;display:flex;align-items:center;margin-right:.5rem;background-color:#fff}.suis-toggle__container:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-toggle__container--readonly{border:.0625rem solid #dcdde1;cursor:not-allowed}.suis-toggle__container--readonly:focus{box-shadow:none}.suis-toggle__container--invalid{border:.0625rem solid #ff4757}.suis-toggle__container--invalid:focus{box-shadow:0 2px 5px #ff4757bf}.suis-toggle__container__thumb{border-radius:100%;height:.75rem;width:.75rem;background-color:#dcdde1;transform:translate(.25rem);transition:.25s ease-in-out}.suis-toggle__container__thumb--invalid{background-color:#ff4757d9}.suis-toggle__container__thumb--active{background-color:#192a56;transform:translate(1.125rem)}.suis-toggle__container__thumb--readonly{background-color:#dcdde1}\n"], dependencies: [{ kind: "component", type: SuisLabelComponent, selector: "suis-label", inputs: ["for", "required", "pointer", "readonly"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
2594
2587
|
}
|
2595
2588
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImport: i0, type: SuisToggleComponent, decorators: [{
|
2596
2589
|
type: Component,
|
@@ -2600,7 +2593,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.13", ngImpo
|
|
2600
2593
|
multi: true,
|
2601
2594
|
useExisting: forwardRef(() => SuisToggleComponent),
|
2602
2595
|
},
|
2603
|
-
], template: "<input\n
|
2596
|
+
], template: "<input\n type=\"checkbox\"\n class=\"suis-toggle\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [disabled]=\"readonly\"\n/>\n\n<suis-label\n class=\"suis-toggle__label\"\n [class.suis-toggle__label--invalid]=\"invalid\"\n [class.suis-toggle__label--readonly]=\"readonly\"\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\n (click)=\"onChange($event)\"\n>\n <div\n [tabindex]=\"readonly ? -1 : 0\"\n class=\"suis-toggle__container\"\n [class.suis-toggle__container--invalid]=\"invalid\"\n [class.suis-toggle__container--readonly]=\"readonly\"\n >\n <div\n class=\"suis-toggle__container__thumb\"\n [class.suis-toggle__container__thumb--active]=\"value\"\n [class.suis-toggle__container__thumb--invalid]=\"invalid\"\n [class.suis-toggle__container__thumb--readonly]=\"readonly\"\n ></div>\n </div>\n <ng-content></ng-content>\n</suis-label>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:flex}.suis-toggle{display:none}.suis-toggle:checked~suis-label ::ng-deep .suis-toggle__container{border:.0625rem solid #192a56}.suis-toggle__label--invalid{color:#ff4757}.suis-toggle__label--readonly{cursor:not-allowed}.suis-toggle__container{width:2.25rem;height:1.25rem;border:.0625rem solid #dcdde1;border-radius:1rem;display:flex;align-items:center;margin-right:.5rem;background-color:#fff}.suis-toggle__container:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-toggle__container--readonly{border:.0625rem solid #dcdde1;cursor:not-allowed}.suis-toggle__container--readonly:focus{box-shadow:none}.suis-toggle__container--invalid{border:.0625rem solid #ff4757}.suis-toggle__container--invalid:focus{box-shadow:0 2px 5px #ff4757bf}.suis-toggle__container__thumb{border-radius:100%;height:.75rem;width:.75rem;background-color:#dcdde1;transform:translate(.25rem);transition:.25s ease-in-out}.suis-toggle__container__thumb--invalid{background-color:#ff4757d9}.suis-toggle__container__thumb--active{background-color:#192a56;transform:translate(1.125rem)}.suis-toggle__container__thumb--readonly{background-color:#dcdde1}\n"] }]
|
2604
2597
|
}] });
|
2605
2598
|
|
2606
2599
|
class SuisToolbarComponent {
|