suis 0.27.0 → 0.29.0
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +3 -0
- package/esm2022/lib/components/index.mjs +4 -1
- package/esm2022/lib/components/suis-input-checkbox/suis-input-checkbox.component.mjs +8 -28
- package/esm2022/lib/components/suis-input-image/index.mjs +2 -0
- package/esm2022/lib/components/suis-input-image/suis-input-image.component.mjs +61 -0
- package/esm2022/lib/components/suis-navigation/suis-navigation.component.mjs +3 -3
- package/esm2022/lib/components/suis-text-area/index.mjs +2 -0
- package/esm2022/lib/components/suis-text-area/suis-text-area.component.mjs +51 -0
- package/esm2022/lib/components/suis-toggle/index.mjs +2 -0
- package/esm2022/lib/components/suis-toggle/suis-toggle.component.mjs +28 -0
- package/esm2022/lib/shared/classes/index.mjs +2 -1
- package/esm2022/lib/shared/classes/suis-checkbox.base.mjs +42 -0
- package/fesm2022/suis.mjs +148 -12
- package/fesm2022/suis.mjs.map +1 -1
- package/lib/components/index.d.ts +3 -0
- package/lib/components/suis-input-checkbox/suis-input-checkbox.component.d.ts +3 -11
- package/lib/components/suis-input-image/index.d.ts +1 -0
- package/lib/components/suis-input-image/suis-input-image.component.d.ts +19 -0
- package/lib/components/suis-text-area/index.d.ts +1 -0
- package/lib/components/suis-text-area/suis-text-area.component.d.ts +14 -0
- package/lib/components/suis-toggle/index.d.ts +1 -0
- package/lib/components/suis-toggle/suis-toggle.component.d.ts +6 -0
- package/lib/shared/classes/index.d.ts +1 -0
- package/lib/shared/classes/suis-checkbox.base.d.ts +18 -0
- package/package.json +1 -1
package/fesm2022/suis.mjs
CHANGED
@@ -554,18 +554,20 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImpor
|
|
554
554
|
type: Input
|
555
555
|
}] } });
|
556
556
|
|
557
|
-
class
|
557
|
+
class SuisCheckboxBase extends SuisInputBase {
|
558
558
|
constructor() {
|
559
559
|
super(...arguments);
|
560
560
|
/** @internal */
|
561
|
-
this.SuisIconType = SuisIconType;
|
562
|
-
/** @internal */
|
563
561
|
this.value = false;
|
564
562
|
/**
|
565
563
|
* Adds a red colored asterisk after the label. By default set to false.
|
566
564
|
*/
|
567
565
|
this.required = false;
|
568
566
|
}
|
567
|
+
ngAfterViewInit() {
|
568
|
+
if (this.value)
|
569
|
+
(this.checkboxInput?.nativeElement).checked = true;
|
570
|
+
}
|
569
571
|
writeValue(obj) {
|
570
572
|
this.value = obj;
|
571
573
|
this._onChange(this.value);
|
@@ -578,14 +580,32 @@ class SuisInputCheckboxComponent extends SuisInputBase {
|
|
578
580
|
this.changed.emit(this.value);
|
579
581
|
this.cdRef.markForCheck();
|
580
582
|
}
|
583
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisCheckboxBase, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
|
584
|
+
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "16.0.0", type: SuisCheckboxBase, inputs: { required: "required" }, viewQueries: [{ propertyName: "checkboxInput", first: true, predicate: ["input"], descendants: true }], usesInheritance: true, ngImport: i0 }); }
|
585
|
+
}
|
586
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisCheckboxBase, decorators: [{
|
587
|
+
type: Directive
|
588
|
+
}], propDecorators: { checkboxInput: [{
|
589
|
+
type: ViewChild,
|
590
|
+
args: ['input']
|
591
|
+
}], required: [{
|
592
|
+
type: Input
|
593
|
+
}] } });
|
594
|
+
|
595
|
+
class SuisInputCheckboxComponent extends SuisCheckboxBase {
|
596
|
+
constructor() {
|
597
|
+
super(...arguments);
|
598
|
+
/** @internal */
|
599
|
+
this.SuisIconType = SuisIconType;
|
600
|
+
}
|
581
601
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisInputCheckboxComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
582
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: SuisInputCheckboxComponent, isStandalone: true, selector: "suis-input-checkbox",
|
602
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: SuisInputCheckboxComponent, isStandalone: true, selector: "suis-input-checkbox", providers: [
|
583
603
|
{
|
584
604
|
provide: NG_VALUE_ACCESSOR,
|
585
605
|
multi: true,
|
586
606
|
useExisting: forwardRef(() => SuisInputCheckboxComponent),
|
587
607
|
},
|
588
|
-
], 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 (input)=\"onChange($event)\"\n (focus)=\"onTouch()\"\n/>\n\n<suis-label\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\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]=\"SuisIconType.CHECK\"\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__check{width:1.25rem;height:1.25rem;border:.0625rem solid #192a56;display:flex;justify-content:center;align-items:center;margin-right:.5rem;background-color:#fff}.suis-input-checkbox__check:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-input-checkbox__check--readonly{border:.0625rem solid #dcdde1}.suis-input-checkbox__check--readonly:focus{box-shadow:none}.suis-input-checkbox__check--invalid{border:.0625rem solid #ff4757;box-shadow:0 2px 5px #ff4757bf}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.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 }); }
|
608
|
+
], usesInheritance: true, ngImport: i0, template: "<input\n #input\n type=\"checkbox\"\n class=\"suis-input-checkbox\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [disabled]=\"readonly\"\n (input)=\"onChange($event)\"\n (focus)=\"onTouch()\"\n/>\n\n<suis-label\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\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]=\"SuisIconType.CHECK\"\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__check{width:1.25rem;height:1.25rem;border:.0625rem solid #192a56;display:flex;justify-content:center;align-items:center;margin-right:.5rem;background-color:#fff}.suis-input-checkbox__check:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-input-checkbox__check--readonly{border:.0625rem solid #dcdde1}.suis-input-checkbox__check--readonly:focus{box-shadow:none}.suis-input-checkbox__check--invalid{border:.0625rem solid #ff4757;box-shadow:0 2px 5px #ff4757bf}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.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 }); }
|
589
609
|
}
|
590
610
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisInputCheckboxComponent, decorators: [{
|
591
611
|
type: Component,
|
@@ -595,10 +615,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImpor
|
|
595
615
|
multi: true,
|
596
616
|
useExisting: forwardRef(() => SuisInputCheckboxComponent),
|
597
617
|
},
|
598
|
-
], 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 (input)=\"onChange($event)\"\n (focus)=\"onTouch()\"\n/>\n\n<suis-label\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\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]=\"SuisIconType.CHECK\"\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__check{width:1.25rem;height:1.25rem;border:.0625rem solid #192a56;display:flex;justify-content:center;align-items:center;margin-right:.5rem;background-color:#fff}.suis-input-checkbox__check:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-input-checkbox__check--readonly{border:.0625rem solid #dcdde1}.suis-input-checkbox__check--readonly:focus{box-shadow:none}.suis-input-checkbox__check--invalid{border:.0625rem solid #ff4757;box-shadow:0 2px 5px #ff4757bf}\n"] }]
|
599
|
-
}]
|
600
|
-
type: Input
|
601
|
-
}] } });
|
618
|
+
], template: "<input\n #input\n type=\"checkbox\"\n class=\"suis-input-checkbox\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [disabled]=\"readonly\"\n (input)=\"onChange($event)\"\n (focus)=\"onTouch()\"\n/>\n\n<suis-label\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\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]=\"SuisIconType.CHECK\"\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__check{width:1.25rem;height:1.25rem;border:.0625rem solid #192a56;display:flex;justify-content:center;align-items:center;margin-right:.5rem;background-color:#fff}.suis-input-checkbox__check:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-input-checkbox__check--readonly{border:.0625rem solid #dcdde1}.suis-input-checkbox__check--readonly:focus{box-shadow:none}.suis-input-checkbox__check--invalid{border:.0625rem solid #ff4757;box-shadow:0 2px 5px #ff4757bf}\n"] }]
|
619
|
+
}] });
|
602
620
|
|
603
621
|
class SuisInputChipsComponent extends SuisInputBase {
|
604
622
|
constructor() {
|
@@ -682,6 +700,58 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImpor
|
|
682
700
|
args: ['document:click', ['$event']]
|
683
701
|
}] } });
|
684
702
|
|
703
|
+
class SuisInputImageComponent extends SuisInputBase {
|
704
|
+
constructor() {
|
705
|
+
super(...arguments);
|
706
|
+
/** @internal */
|
707
|
+
this.SuisIconType = SuisIconType;
|
708
|
+
/** @internal */
|
709
|
+
this.value = null;
|
710
|
+
/** @internal */
|
711
|
+
this.imageUrl = null;
|
712
|
+
}
|
713
|
+
writeValue(obj) {
|
714
|
+
if (typeof obj === 'string')
|
715
|
+
this.imageUrl = obj;
|
716
|
+
}
|
717
|
+
onChange(event) {
|
718
|
+
const target = event.target;
|
719
|
+
this.value = target.files;
|
720
|
+
this._onChange(this.value);
|
721
|
+
this.changed.emit(this.value);
|
722
|
+
this.cdRef.markForCheck();
|
723
|
+
}
|
724
|
+
onRemove() {
|
725
|
+
this.imageUrl = null;
|
726
|
+
this.value = null;
|
727
|
+
(this.fileInput?.nativeElement).value = '';
|
728
|
+
this._onChange(this.value);
|
729
|
+
this.changed.emit(this.value);
|
730
|
+
this.cdRef.markForCheck();
|
731
|
+
}
|
732
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisInputImageComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
733
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: SuisInputImageComponent, isStandalone: true, selector: "suis-input-image", providers: [
|
734
|
+
{
|
735
|
+
provide: NG_VALUE_ACCESSOR,
|
736
|
+
multi: true,
|
737
|
+
useExisting: forwardRef(() => SuisInputImageComponent),
|
738
|
+
},
|
739
|
+
], viewQueries: [{ propertyName: "fileInput", first: true, predicate: ["input"], descendants: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"suis-input-image\">\n <figure *ngIf=\"imageUrl\" class=\"suis-input-image__preview\">\n <img [src]=\"imageUrl\" alt=\"Uploaded image\" />\n <button type=\"button\" (click)=\"onRemove()\">\n <suis-icon\n [type]=\"SuisIconType.CROSS\"\n color=\"danger\"\n size=\"md\"\n [filled]=\"true\"\n ></suis-icon>\n </button>\n </figure>\n <input\n #input\n type=\"file\"\n class=\"suis-input-image__input\"\n [class.suis-input-image--invalid]=\"invalid\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [disabled]=\"readonly\"\n (input)=\"onChange($event)\"\n (focus)=\"onTouch()\"\n />\n</div>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:block}.suis-input-image{width:100%;background-color:#fff;box-shadow:0 2px 5px #00000040;border-radius:.25rem;padding:.5rem 1rem;border:0;min-height:2rem;display:flex;align-items:center}.suis-input-image:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-input-image--invalid{box-shadow:0 2px 5px #ff4757bf}.suis-input-image__preview{position:relative;margin-right:1rem}.suis-input-image__preview img{display:block;min-width:6.25rem;min-height:6.25rem;max-width:6.25rem;max-height:6.25rem;border-radius:.25rem;object-fit:contain;background-color:#dcdde1d9}.suis-input-image__preview button{position:absolute;top:.1875rem;right:.1875rem;border:0;background-color:transparent;cursor:pointer}.suis-input-image__input::file-selector-button{color:#fff;background-color:#273c75;border-radius:.25rem;transition:background-color .25s ease-in-out;padding:.25rem .75rem;border:0;font-size:.75rem}.suis-input-image__input::file-selector-button:hover{background-color:#273c75d9;cursor:pointer}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: SuisIconComponent, selector: "suis-icon", inputs: ["size", "color", "type", "outlined", "filled", "pointer", "bold"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
740
|
+
}
|
741
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisInputImageComponent, decorators: [{
|
742
|
+
type: Component,
|
743
|
+
args: [{ selector: 'suis-input-image', standalone: true, imports: [CommonModule, SuisIconComponent], changeDetection: ChangeDetectionStrategy.OnPush, providers: [
|
744
|
+
{
|
745
|
+
provide: NG_VALUE_ACCESSOR,
|
746
|
+
multi: true,
|
747
|
+
useExisting: forwardRef(() => SuisInputImageComponent),
|
748
|
+
},
|
749
|
+
], template: "<div class=\"suis-input-image\">\n <figure *ngIf=\"imageUrl\" class=\"suis-input-image__preview\">\n <img [src]=\"imageUrl\" alt=\"Uploaded image\" />\n <button type=\"button\" (click)=\"onRemove()\">\n <suis-icon\n [type]=\"SuisIconType.CROSS\"\n color=\"danger\"\n size=\"md\"\n [filled]=\"true\"\n ></suis-icon>\n </button>\n </figure>\n <input\n #input\n type=\"file\"\n class=\"suis-input-image__input\"\n [class.suis-input-image--invalid]=\"invalid\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [disabled]=\"readonly\"\n (input)=\"onChange($event)\"\n (focus)=\"onTouch()\"\n />\n</div>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:block}.suis-input-image{width:100%;background-color:#fff;box-shadow:0 2px 5px #00000040;border-radius:.25rem;padding:.5rem 1rem;border:0;min-height:2rem;display:flex;align-items:center}.suis-input-image:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-input-image--invalid{box-shadow:0 2px 5px #ff4757bf}.suis-input-image__preview{position:relative;margin-right:1rem}.suis-input-image__preview img{display:block;min-width:6.25rem;min-height:6.25rem;max-width:6.25rem;max-height:6.25rem;border-radius:.25rem;object-fit:contain;background-color:#dcdde1d9}.suis-input-image__preview button{position:absolute;top:.1875rem;right:.1875rem;border:0;background-color:transparent;cursor:pointer}.suis-input-image__input::file-selector-button{color:#fff;background-color:#273c75;border-radius:.25rem;transition:background-color .25s ease-in-out;padding:.25rem .75rem;border:0;font-size:.75rem}.suis-input-image__input::file-selector-button:hover{background-color:#273c75d9;cursor:pointer}\n"] }]
|
750
|
+
}], propDecorators: { fileInput: [{
|
751
|
+
type: ViewChild,
|
752
|
+
args: ['input']
|
753
|
+
}] } });
|
754
|
+
|
685
755
|
class SuisSelectOptionDirective {
|
686
756
|
constructor() {
|
687
757
|
/**
|
@@ -1004,11 +1074,11 @@ class SuisNavigationComponent {
|
|
1004
1074
|
return `${groupItem.label}-${index}`;
|
1005
1075
|
}
|
1006
1076
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisNavigationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
1007
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: SuisNavigationComponent, isStandalone: true, selector: "suis-navigation", inputs: { items: "items", expandedGroups: "expandedGroups", expandable: "expandable" }, queries: [{ propertyName: "suisNavigationItem", first: true, predicate: SuisNavigationItemDirective, descendants: true }], ngImport: i0, template: "<div class=\"suis-navigation\">\n <suis-navigation-group\n *ngFor=\"let groupItem of items; trackBy: groupItemTrackBy\"\n [item]=\"groupItem\"\n [templateRef]=\"suisNavigationItem?.templateRef\"\n [expanded]=\"expandedGroups\"\n [expandable]=\"expandable\"\n ></suis-navigation-group>\n</div>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:block}.suis-navigation{width:100%;min-width:15rem;max-width:15rem;background-color:#192a56;color:#fff;height:100%;min-height:100vh;max-height:100vh;overflow-y:auto}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: SuisNavigationGroupComponent, selector: "suis-navigation-group", inputs: ["item", "templateRef", "expanded", "expandable"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
1077
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: SuisNavigationComponent, isStandalone: true, selector: "suis-navigation", inputs: { items: "items", expandedGroups: "expandedGroups", expandable: "expandable" }, queries: [{ propertyName: "suisNavigationItem", first: true, predicate: SuisNavigationItemDirective, descendants: true }], ngImport: i0, template: "<div class=\"suis-navigation\">\r\n <suis-navigation-group\r\n *ngFor=\"let groupItem of items; trackBy: groupItemTrackBy\"\r\n [item]=\"groupItem\"\r\n [templateRef]=\"suisNavigationItem?.templateRef\"\r\n [expanded]=\"expandedGroups\"\r\n [expandable]=\"expandable\"\r\n ></suis-navigation-group>\r\n</div>\r\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:block}.suis-navigation{width:100%;min-width:15rem;max-width:15rem;background-color:#192a56;color:#fff;height:100%;min-height:100vh;max-height:100vh;overflow-y:auto}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: SuisNavigationGroupComponent, selector: "suis-navigation-group", inputs: ["item", "templateRef", "expanded", "expandable"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
1008
1078
|
}
|
1009
1079
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisNavigationComponent, decorators: [{
|
1010
1080
|
type: Component,
|
1011
|
-
args: [{ selector: 'suis-navigation', standalone: true, imports: [CommonModule, SuisNavigationGroupComponent], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"suis-navigation\">\n <suis-navigation-group\n *ngFor=\"let groupItem of items; trackBy: groupItemTrackBy\"\n [item]=\"groupItem\"\n [templateRef]=\"suisNavigationItem?.templateRef\"\n [expanded]=\"expandedGroups\"\n [expandable]=\"expandable\"\n ></suis-navigation-group>\n</div>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:block}.suis-navigation{width:100%;min-width:15rem;max-width:15rem;background-color:#192a56;color:#fff;height:100%;min-height:100vh;max-height:100vh;overflow-y:auto}\n"] }]
|
1081
|
+
args: [{ selector: 'suis-navigation', standalone: true, imports: [CommonModule, SuisNavigationGroupComponent], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"suis-navigation\">\r\n <suis-navigation-group\r\n *ngFor=\"let groupItem of items; trackBy: groupItemTrackBy\"\r\n [item]=\"groupItem\"\r\n [templateRef]=\"suisNavigationItem?.templateRef\"\r\n [expanded]=\"expandedGroups\"\r\n [expandable]=\"expandable\"\r\n ></suis-navigation-group>\r\n</div>\r\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:block}.suis-navigation{width:100%;min-width:15rem;max-width:15rem;background-color:#192a56;color:#fff;height:100%;min-height:100vh;max-height:100vh;overflow-y:auto}\n"] }]
|
1012
1082
|
}], propDecorators: { suisNavigationItem: [{
|
1013
1083
|
type: ContentChild,
|
1014
1084
|
args: [SuisNavigationItemDirective]
|
@@ -1981,6 +2051,51 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImpor
|
|
1981
2051
|
}]
|
1982
2052
|
}] });
|
1983
2053
|
|
2054
|
+
class SuisTextAreaComponent extends SuisInputBase {
|
2055
|
+
constructor() {
|
2056
|
+
super(...arguments);
|
2057
|
+
/**
|
2058
|
+
* Placeholder text displayed in input. By default set to empty string.
|
2059
|
+
*/
|
2060
|
+
this.placeholder = '';
|
2061
|
+
/** @internal */
|
2062
|
+
this.value = '';
|
2063
|
+
}
|
2064
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
2065
|
+
writeValue(obj) {
|
2066
|
+
this.value = obj;
|
2067
|
+
this._onChange(this.value);
|
2068
|
+
this.cdRef.markForCheck();
|
2069
|
+
}
|
2070
|
+
onChange(event) {
|
2071
|
+
const target = event.target;
|
2072
|
+
this.value = target.value;
|
2073
|
+
this._onChange(this.value);
|
2074
|
+
this.changed.emit(this.value);
|
2075
|
+
this.cdRef.markForCheck();
|
2076
|
+
}
|
2077
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisTextAreaComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
2078
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: SuisTextAreaComponent, isStandalone: true, selector: "suis-text-area", inputs: { placeholder: "placeholder" }, providers: [
|
2079
|
+
{
|
2080
|
+
provide: NG_VALUE_ACCESSOR,
|
2081
|
+
multi: true,
|
2082
|
+
useExisting: forwardRef(() => SuisTextAreaComponent),
|
2083
|
+
},
|
2084
|
+
], usesInheritance: true, ngImport: i0, template: "<textarea\n class=\"suis-text-area\"\n [class.suis-text-area--invalid]=\"invalid\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [placeholder]=\"placeholder\"\n [disabled]=\"readonly\"\n (input)=\"onChange($event)\"\n (focus)=\"onTouch()\"\n></textarea>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:block}.suis-text-area{width:100%;background-color:#fff;box-shadow:0 2px 5px #00000040;border-radius:.25rem;padding:.5rem 1rem;border:0;min-height:2rem;min-height:6.25rem}.suis-text-area:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-text-area--invalid{box-shadow:0 2px 5px #ff4757bf}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
2085
|
+
}
|
2086
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisTextAreaComponent, decorators: [{
|
2087
|
+
type: Component,
|
2088
|
+
args: [{ selector: 'suis-text-area', standalone: true, imports: [CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, providers: [
|
2089
|
+
{
|
2090
|
+
provide: NG_VALUE_ACCESSOR,
|
2091
|
+
multi: true,
|
2092
|
+
useExisting: forwardRef(() => SuisTextAreaComponent),
|
2093
|
+
},
|
2094
|
+
], template: "<textarea\n class=\"suis-text-area\"\n [class.suis-text-area--invalid]=\"invalid\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [placeholder]=\"placeholder\"\n [disabled]=\"readonly\"\n (input)=\"onChange($event)\"\n (focus)=\"onTouch()\"\n></textarea>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:block}.suis-text-area{width:100%;background-color:#fff;box-shadow:0 2px 5px #00000040;border-radius:.25rem;padding:.5rem 1rem;border:0;min-height:2rem;min-height:6.25rem}.suis-text-area:focus{box-shadow:0 2px 5px #192a56bf;outline:none}.suis-text-area--invalid{box-shadow:0 2px 5px #ff4757bf}\n"] }]
|
2095
|
+
}], propDecorators: { placeholder: [{
|
2096
|
+
type: Input
|
2097
|
+
}] } });
|
2098
|
+
|
1984
2099
|
class SuisTitleComponent {
|
1985
2100
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisTitleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
1986
2101
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: SuisTitleComponent, isStandalone: true, selector: "suis-title", ngImport: i0, template: "<h1 class=\"suis-title\">\n <ng-content></ng-content>\n</h1>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:block}.suis-title{color:#192a56;font-weight:600;font-size:1.5rem}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
@@ -1990,6 +2105,27 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImpor
|
|
1990
2105
|
args: [{ selector: 'suis-title', standalone: true, imports: [CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "<h1 class=\"suis-title\">\n <ng-content></ng-content>\n</h1>\n", styles: ["*{margin:0;padding:0;box-sizing:border-box}@keyframes spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}:host{display:block}.suis-title{color:#192a56;font-weight:600;font-size:1.5rem}\n"] }]
|
1991
2106
|
}] });
|
1992
2107
|
|
2108
|
+
class SuisToggleComponent extends SuisCheckboxBase {
|
2109
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisToggleComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
2110
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "16.0.0", type: SuisToggleComponent, isStandalone: true, selector: "suis-toggle", providers: [
|
2111
|
+
{
|
2112
|
+
provide: NG_VALUE_ACCESSOR,
|
2113
|
+
multi: true,
|
2114
|
+
useExisting: forwardRef(() => SuisToggleComponent),
|
2115
|
+
},
|
2116
|
+
], usesInheritance: true, ngImport: i0, template: "<input\n #input\n type=\"checkbox\"\n class=\"suis-toggle\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [disabled]=\"readonly\"\n (input)=\"onChange($event)\"\n (focus)=\"onTouch()\"\n/>\n\n<suis-label\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\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 ></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__container{width:2.25rem;height:1.25rem;border:.0625rem solid #192a56;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}.suis-toggle__container--readonly:focus{box-shadow:none}.suis-toggle__container--invalid{border:.0625rem solid #ff4757;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--active{background-color:#192a56;transform:translate(1.125rem)}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "component", type: SuisLabelComponent, selector: "suis-label", inputs: ["for", "required", "pointer", "readonly"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
2117
|
+
}
|
2118
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImport: i0, type: SuisToggleComponent, decorators: [{
|
2119
|
+
type: Component,
|
2120
|
+
args: [{ selector: 'suis-toggle', standalone: true, imports: [CommonModule, SuisLabelComponent], changeDetection: ChangeDetectionStrategy.OnPush, providers: [
|
2121
|
+
{
|
2122
|
+
provide: NG_VALUE_ACCESSOR,
|
2123
|
+
multi: true,
|
2124
|
+
useExisting: forwardRef(() => SuisToggleComponent),
|
2125
|
+
},
|
2126
|
+
], template: "<input\n #input\n type=\"checkbox\"\n class=\"suis-toggle\"\n [attr.id]=\"id\"\n [attr.name]=\"name\"\n [value]=\"value\"\n [disabled]=\"readonly\"\n (input)=\"onChange($event)\"\n (focus)=\"onTouch()\"\n/>\n\n<suis-label\n [for]=\"id\"\n [required]=\"required\"\n [pointer]=\"true\"\n [readonly]=\"readonly\"\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 ></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__container{width:2.25rem;height:1.25rem;border:.0625rem solid #192a56;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}.suis-toggle__container--readonly:focus{box-shadow:none}.suis-toggle__container--invalid{border:.0625rem solid #ff4757;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--active{background-color:#192a56;transform:translate(1.125rem)}\n"] }]
|
2127
|
+
}] });
|
2128
|
+
|
1993
2129
|
class SuisToolbarComponent {
|
1994
2130
|
constructor() {
|
1995
2131
|
/**
|
@@ -2011,5 +2147,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.0.0", ngImpor
|
|
2011
2147
|
* Generated bundle index. Do not edit.
|
2012
2148
|
*/
|
2013
2149
|
|
2014
|
-
export { SuisAlertComponent, SuisBoxComponent, SuisBreadcrumbsComponent, SuisButtonComponent, SuisButtonLinkComponent, SuisButtonOutlinedComponent, SuisChipComponent, SuisContainerComponent, SuisFormFieldComponent, SuisIconComponent, SuisIconType, SuisInputCheckboxComponent, SuisInputChipsComponent, SuisInputComponent, SuisInputNumberComponent, SuisInputRadioComponent, SuisLabelComponent, SuisNavigationComponent, SuisNavigationGroupComponent, SuisNavigationGroupItemComponent, SuisNavigationItemComponent, SuisNavigationItemDirective, SuisNavigationModule, SuisNgClassPipe, SuisNotificationComponent, SuisNotificationService, SuisNotificationsComponent, SuisPaginationComponent, SuisProgressBarComponent, SuisSelectComponent, SuisSelectModule, SuisSelectMultiComponent, SuisSelectMultiModule, SuisSelectOptionComponent, SuisSelectOptionDirective, SuisSpinnerComponent, SuisSpinnerContainerComponent, SuisTabDirective, SuisTableCellDirective, SuisTableColumnDirective, SuisTableComponent, SuisTableModule, SuisTabsComponent, SuisTabsModule, SuisTitleComponent, SuisToolbarComponent };
|
2150
|
+
export { SuisAlertComponent, SuisBoxComponent, SuisBreadcrumbsComponent, SuisButtonComponent, SuisButtonLinkComponent, SuisButtonOutlinedComponent, SuisChipComponent, SuisContainerComponent, SuisFormFieldComponent, SuisIconComponent, SuisIconType, SuisInputCheckboxComponent, SuisInputChipsComponent, SuisInputComponent, SuisInputImageComponent, SuisInputNumberComponent, SuisInputRadioComponent, SuisLabelComponent, SuisNavigationComponent, SuisNavigationGroupComponent, SuisNavigationGroupItemComponent, SuisNavigationItemComponent, SuisNavigationItemDirective, SuisNavigationModule, SuisNgClassPipe, SuisNotificationComponent, SuisNotificationService, SuisNotificationsComponent, SuisPaginationComponent, SuisProgressBarComponent, SuisSelectComponent, SuisSelectModule, SuisSelectMultiComponent, SuisSelectMultiModule, SuisSelectOptionComponent, SuisSelectOptionDirective, SuisSpinnerComponent, SuisSpinnerContainerComponent, SuisTabDirective, SuisTableCellDirective, SuisTableColumnDirective, SuisTableComponent, SuisTableModule, SuisTabsComponent, SuisTabsModule, SuisTextAreaComponent, SuisTitleComponent, SuisToggleComponent, SuisToolbarComponent };
|
2015
2151
|
//# sourceMappingURL=suis.mjs.map
|