@flywheel-io/vision 0.9.2 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/text-input/text-input.component.d.ts +27 -0
- package/components/text-input/text-input.module.d.ts +10 -0
- package/esm2020/components/text-input/text-input.component.mjs +72 -0
- package/esm2020/components/text-input/text-input.module.mjs +35 -0
- package/esm2020/public-api.mjs +3 -5
- package/fesm2015/flywheel-io-vision.mjs +140 -261
- package/fesm2015/flywheel-io-vision.mjs.map +1 -1
- package/fesm2020/flywheel-io-vision.mjs +140 -261
- package/fesm2020/flywheel-io-vision.mjs.map +1 -1
- package/package.json +1 -1
- package/public-api.d.ts +2 -4
- package/components/table/table.component.d.ts +0 -52
- package/components/table/table.module.d.ts +0 -14
- package/esm2020/components/table/table.component.mjs +0 -179
- package/esm2020/components/table/table.module.mjs +0 -51
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Component, ChangeDetectionStrategy, Input, NgModule,
|
|
2
|
+
import { Component, ChangeDetectionStrategy, Input, NgModule, Inject, Injectable, Pipe, SimpleChange, EventEmitter, ViewEncapsulation, Output, HostBinding, Directive, TemplateRef, ViewChild } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/common';
|
|
4
4
|
import { CommonModule } from '@angular/common';
|
|
5
5
|
import * as i2 from '@angular/material/button';
|
|
@@ -12,23 +12,10 @@ import { of, Subject, BehaviorSubject, Subscription } from 'rxjs';
|
|
|
12
12
|
import * as i1$1 from '@angular/platform-browser';
|
|
13
13
|
import * as i5 from '@angular/cdk/portal';
|
|
14
14
|
import { ComponentPortal, TemplatePortal, PortalModule } from '@angular/cdk/portal';
|
|
15
|
-
import { takeUntil
|
|
15
|
+
import { takeUntil } from 'rxjs/operators';
|
|
16
16
|
import * as i1$2 from '@angular/cdk/overlay';
|
|
17
17
|
import { Overlay } from '@angular/cdk/overlay';
|
|
18
|
-
import
|
|
19
|
-
import { UntypedFormGroup, UntypedFormControl, FormsModule, ReactiveFormsModule } from '@angular/forms';
|
|
20
|
-
import * as i5$1 from '@angular/material/paginator';
|
|
21
|
-
import { MatPaginator, MatPaginatorModule } from '@angular/material/paginator';
|
|
22
|
-
import * as i8 from '@angular/material/sort';
|
|
23
|
-
import { MatSort, MatSortModule } from '@angular/material/sort';
|
|
24
|
-
import * as i9 from '@angular/material/table';
|
|
25
|
-
import { MatTableDataSource, MatTableModule } from '@angular/material/table';
|
|
26
|
-
import * as i3$1 from '@angular/material/form-field';
|
|
27
|
-
import * as i4$1 from '@angular/material/input';
|
|
28
|
-
import { MatInputModule } from '@angular/material/input';
|
|
29
|
-
import * as i6 from '@angular/material/select';
|
|
30
|
-
import { MatSelectModule } from '@angular/material/select';
|
|
31
|
-
import * as i7 from '@angular/material/core';
|
|
18
|
+
import { NG_VALUE_ACCESSOR, ReactiveFormsModule } from '@angular/forms';
|
|
32
19
|
|
|
33
20
|
class FwIconComponent {
|
|
34
21
|
}
|
|
@@ -139,46 +126,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImpor
|
|
|
139
126
|
}]
|
|
140
127
|
}] });
|
|
141
128
|
|
|
142
|
-
class FwButtonGroupComponent {
|
|
143
|
-
constructor() {
|
|
144
|
-
this.layout = 'basic';
|
|
145
|
-
this.size = 'medium';
|
|
146
|
-
}
|
|
147
|
-
}
|
|
148
|
-
FwButtonGroupComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwButtonGroupComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
149
|
-
FwButtonGroupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: FwButtonGroupComponent, selector: "fw-button-group", inputs: { layout: "layout", size: "size" }, host: { properties: { "class.small": "size === \"small\"", "class.medium": "size === \"medium\"", "class.large": "size === \"large\"", "class.compact": "layout === \"compact\"" }, classAttribute: "fw-button-group" }, ngImport: i0, template: `<ng-content></ng-content>`, isInline: true, styles: ["fw-button-group.fw-button-group{border-radius:4px;display:inline-flex;align-items:stretch}fw-button-group.fw-button-group.compact button{line-height:24px;height:24px}fw-button-group.fw-button-group.small button{font-size:12px}fw-button-group.fw-button-group.medium button{font-size:14px}fw-button-group.fw-button-group.large button{font-size:18px}fw-button-group.fw-button-group button{min-width:0;margin:0!important;border-radius:0}fw-button-group.fw-button-group>fw-button:first-of-type>button,fw-button-group.fw-button-group>button:first-of-type{border-top-left-radius:4px;border-bottom-left-radius:4px}fw-button-group.fw-button-group>fw-button:last-of-type>button,fw-button-group.fw-button-group>button:last-of-type{border-top-right-radius:4px;border-bottom-right-radius:4px}fw-button-group.fw-button-group>fw-button[ng-reflect-type=stroked]>button,fw-button-group.fw-button-group>fw-button[ng-reflect-type=stroked]+fw-button[ng-reflect-type=stroked]>button,fw-button-group.fw-button-group>fw-button[type=stroked]>button,fw-button-group.fw-button-group>fw-button[type=stroked]+fw-button[type=stroked]>button,fw-button-group.fw-button-group>button.mat-stroked-button,fw-button-group.fw-button-group>button.mat-stroked-button+button.mat-stroke-button{border-right-width:0}fw-button-group.fw-button-group>fw-button[ng-reflect-type=stroked]:last-of-type>button,fw-button-group.fw-button-group>fw-button[type=stroked]:last-of-type>button,fw-button-group.fw-button-group>button.mat-stroked-button:last-of-type{border-right-width:1px!important}fw-button-group.fw-button-group>fw-button:not([ng-reflect-type=stroked])+fw-button[ng-reflect-type=stroked]>button,fw-button-group.fw-button-group>fw-button:not([type=stroked])+fw-button[type=stroked]>button,fw-button-group.fw-button-group>button:not(.mat-stroked-button)+button.mat-stroked-button{border-left-width:0}\n"], encapsulation: i0.ViewEncapsulation.None });
|
|
150
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwButtonGroupComponent, decorators: [{
|
|
151
|
-
type: Component,
|
|
152
|
-
args: [{ host: {
|
|
153
|
-
'class': 'fw-button-group',
|
|
154
|
-
'[class.small]': 'size === "small"',
|
|
155
|
-
'[class.medium]': 'size === "medium"',
|
|
156
|
-
'[class.large]': 'size === "large"',
|
|
157
|
-
'[class.compact]': 'layout === "compact"',
|
|
158
|
-
}, selector: 'fw-button-group', template: `<ng-content></ng-content>`, encapsulation: ViewEncapsulation.None, styles: ["fw-button-group.fw-button-group{border-radius:4px;display:inline-flex;align-items:stretch}fw-button-group.fw-button-group.compact button{line-height:24px;height:24px}fw-button-group.fw-button-group.small button{font-size:12px}fw-button-group.fw-button-group.medium button{font-size:14px}fw-button-group.fw-button-group.large button{font-size:18px}fw-button-group.fw-button-group button{min-width:0;margin:0!important;border-radius:0}fw-button-group.fw-button-group>fw-button:first-of-type>button,fw-button-group.fw-button-group>button:first-of-type{border-top-left-radius:4px;border-bottom-left-radius:4px}fw-button-group.fw-button-group>fw-button:last-of-type>button,fw-button-group.fw-button-group>button:last-of-type{border-top-right-radius:4px;border-bottom-right-radius:4px}fw-button-group.fw-button-group>fw-button[ng-reflect-type=stroked]>button,fw-button-group.fw-button-group>fw-button[ng-reflect-type=stroked]+fw-button[ng-reflect-type=stroked]>button,fw-button-group.fw-button-group>fw-button[type=stroked]>button,fw-button-group.fw-button-group>fw-button[type=stroked]+fw-button[type=stroked]>button,fw-button-group.fw-button-group>button.mat-stroked-button,fw-button-group.fw-button-group>button.mat-stroked-button+button.mat-stroke-button{border-right-width:0}fw-button-group.fw-button-group>fw-button[ng-reflect-type=stroked]:last-of-type>button,fw-button-group.fw-button-group>fw-button[type=stroked]:last-of-type>button,fw-button-group.fw-button-group>button.mat-stroked-button:last-of-type{border-right-width:1px!important}fw-button-group.fw-button-group>fw-button:not([ng-reflect-type=stroked])+fw-button[ng-reflect-type=stroked]>button,fw-button-group.fw-button-group>fw-button:not([type=stroked])+fw-button[type=stroked]>button,fw-button-group.fw-button-group>button:not(.mat-stroked-button)+button.mat-stroked-button{border-left-width:0}\n"] }]
|
|
159
|
-
}], propDecorators: { layout: [{
|
|
160
|
-
type: Input
|
|
161
|
-
}], size: [{
|
|
162
|
-
type: Input
|
|
163
|
-
}] } });
|
|
164
|
-
|
|
165
|
-
class FwButtonGroupModule {
|
|
166
|
-
}
|
|
167
|
-
FwButtonGroupModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwButtonGroupModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
168
|
-
FwButtonGroupModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: FwButtonGroupModule, declarations: [FwButtonGroupComponent], exports: [FwButtonGroupComponent] });
|
|
169
|
-
FwButtonGroupModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwButtonGroupModule });
|
|
170
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwButtonGroupModule, decorators: [{
|
|
171
|
-
type: NgModule,
|
|
172
|
-
args: [{
|
|
173
|
-
exports: [
|
|
174
|
-
FwButtonGroupComponent,
|
|
175
|
-
],
|
|
176
|
-
declarations: [
|
|
177
|
-
FwButtonGroupComponent,
|
|
178
|
-
]
|
|
179
|
-
}]
|
|
180
|
-
}] });
|
|
181
|
-
|
|
182
129
|
class FwButtonComponent {
|
|
183
130
|
constructor() {
|
|
184
131
|
this.color = 'primary';
|
|
@@ -940,6 +887,46 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImpor
|
|
|
940
887
|
}, selector: 'fw-notification-container', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<div role=\"list\">\n <fw-notification *ngFor=\"let notification of notifications; index as $index\"\n (ready)=\"onReady($event)\"\n (dismiss)=\"onDismiss($event)\"\n [class]=\"notificationClass($index)\"\n [notification]=\"expanded || $index === notifications.length - 1 ? notification : getEmptyNotification(notification)\"\n [attr.aria-label]=\"notification.type + ' : ' + notification.message\"\n role=\"listitem\"\n ></fw-notification>\n <div class=\"buttons\">\n <fw-button *ngIf=\"expanded\" (click)=\"onShowLess()\" mat-button aria-label=\"show less\" layout=\"compact\" size=\"small\">\n <mat-icon>expand_less</mat-icon>\n </fw-button>\n <fw-button *ngIf=\"!expanded && notifications.length > 1\" (click)=\"onShowMore()\" mat-button aria-label=\"show more\" layout=\"compact\" size=\"small\">\n <mat-icon>expand_more</mat-icon>\n </fw-button>\n <fw-button (click)=\"clearAll()\" mat-button class=\"clear-all\" aria-label=\"clear all\" layout=\"compact\" size=\"small\">\n Clear All\n </fw-button>\n </div>\n</div>\n", styles: ["fw-notification-container{position:absolute;right:0;top:0;margin-top:20px;z-index:999999}fw-notification-container>div{display:flex;flex-direction:column-reverse}fw-notification-container .buttons{display:none;position:absolute;top:-5px;right:25px}fw-notification-container .buttons button{color:#fff;background-color:#919292;margin-left:2px}fw-notification-container .buttons button.mat-button{line-height:24px!important;margin:0 0 0 2px!important}fw-notification-container:hover .buttons{display:flex}fw-notification-container .hidden{display:none}fw-notification-container fw-notification:last-of-type{margin-top:24px}fw-notification-container.duo fw-notification.level-0{transform:scale(.95) translateY(-51px)}fw-notification-container.triple fw-notification.level-1{transform:scale(.95) translateY(-51px)}fw-notification-container.triple fw-notification.level-0{transform:scale(.9) translateY(-108px)}\n"] }]
|
|
941
888
|
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: FwNotificationService }]; } });
|
|
942
889
|
|
|
890
|
+
class FwButtonGroupComponent {
|
|
891
|
+
constructor() {
|
|
892
|
+
this.layout = 'basic';
|
|
893
|
+
this.size = 'medium';
|
|
894
|
+
}
|
|
895
|
+
}
|
|
896
|
+
FwButtonGroupComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwButtonGroupComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
897
|
+
FwButtonGroupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: FwButtonGroupComponent, selector: "fw-button-group", inputs: { layout: "layout", size: "size" }, host: { properties: { "class.small": "size === \"small\"", "class.medium": "size === \"medium\"", "class.large": "size === \"large\"", "class.compact": "layout === \"compact\"" }, classAttribute: "fw-button-group" }, ngImport: i0, template: `<ng-content></ng-content>`, isInline: true, styles: ["fw-button-group.fw-button-group{border-radius:4px;display:inline-flex;align-items:stretch}fw-button-group.fw-button-group.compact button{line-height:24px;height:24px}fw-button-group.fw-button-group.small button{font-size:12px}fw-button-group.fw-button-group.medium button{font-size:14px}fw-button-group.fw-button-group.large button{font-size:18px}fw-button-group.fw-button-group button{min-width:0;margin:0!important;border-radius:0}fw-button-group.fw-button-group>fw-button:first-of-type>button,fw-button-group.fw-button-group>button:first-of-type{border-top-left-radius:4px;border-bottom-left-radius:4px}fw-button-group.fw-button-group>fw-button:last-of-type>button,fw-button-group.fw-button-group>button:last-of-type{border-top-right-radius:4px;border-bottom-right-radius:4px}fw-button-group.fw-button-group>fw-button[ng-reflect-type=stroked]>button,fw-button-group.fw-button-group>fw-button[ng-reflect-type=stroked]+fw-button[ng-reflect-type=stroked]>button,fw-button-group.fw-button-group>fw-button[type=stroked]>button,fw-button-group.fw-button-group>fw-button[type=stroked]+fw-button[type=stroked]>button,fw-button-group.fw-button-group>button.mat-stroked-button,fw-button-group.fw-button-group>button.mat-stroked-button+button.mat-stroke-button{border-right-width:0}fw-button-group.fw-button-group>fw-button[ng-reflect-type=stroked]:last-of-type>button,fw-button-group.fw-button-group>fw-button[type=stroked]:last-of-type>button,fw-button-group.fw-button-group>button.mat-stroked-button:last-of-type{border-right-width:1px!important}fw-button-group.fw-button-group>fw-button:not([ng-reflect-type=stroked])+fw-button[ng-reflect-type=stroked]>button,fw-button-group.fw-button-group>fw-button:not([type=stroked])+fw-button[type=stroked]>button,fw-button-group.fw-button-group>button:not(.mat-stroked-button)+button.mat-stroked-button{border-left-width:0}\n"], encapsulation: i0.ViewEncapsulation.None });
|
|
898
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwButtonGroupComponent, decorators: [{
|
|
899
|
+
type: Component,
|
|
900
|
+
args: [{ host: {
|
|
901
|
+
'class': 'fw-button-group',
|
|
902
|
+
'[class.small]': 'size === "small"',
|
|
903
|
+
'[class.medium]': 'size === "medium"',
|
|
904
|
+
'[class.large]': 'size === "large"',
|
|
905
|
+
'[class.compact]': 'layout === "compact"',
|
|
906
|
+
}, selector: 'fw-button-group', template: `<ng-content></ng-content>`, encapsulation: ViewEncapsulation.None, styles: ["fw-button-group.fw-button-group{border-radius:4px;display:inline-flex;align-items:stretch}fw-button-group.fw-button-group.compact button{line-height:24px;height:24px}fw-button-group.fw-button-group.small button{font-size:12px}fw-button-group.fw-button-group.medium button{font-size:14px}fw-button-group.fw-button-group.large button{font-size:18px}fw-button-group.fw-button-group button{min-width:0;margin:0!important;border-radius:0}fw-button-group.fw-button-group>fw-button:first-of-type>button,fw-button-group.fw-button-group>button:first-of-type{border-top-left-radius:4px;border-bottom-left-radius:4px}fw-button-group.fw-button-group>fw-button:last-of-type>button,fw-button-group.fw-button-group>button:last-of-type{border-top-right-radius:4px;border-bottom-right-radius:4px}fw-button-group.fw-button-group>fw-button[ng-reflect-type=stroked]>button,fw-button-group.fw-button-group>fw-button[ng-reflect-type=stroked]+fw-button[ng-reflect-type=stroked]>button,fw-button-group.fw-button-group>fw-button[type=stroked]>button,fw-button-group.fw-button-group>fw-button[type=stroked]+fw-button[type=stroked]>button,fw-button-group.fw-button-group>button.mat-stroked-button,fw-button-group.fw-button-group>button.mat-stroked-button+button.mat-stroke-button{border-right-width:0}fw-button-group.fw-button-group>fw-button[ng-reflect-type=stroked]:last-of-type>button,fw-button-group.fw-button-group>fw-button[type=stroked]:last-of-type>button,fw-button-group.fw-button-group>button.mat-stroked-button:last-of-type{border-right-width:1px!important}fw-button-group.fw-button-group>fw-button:not([ng-reflect-type=stroked])+fw-button[ng-reflect-type=stroked]>button,fw-button-group.fw-button-group>fw-button:not([type=stroked])+fw-button[type=stroked]>button,fw-button-group.fw-button-group>button:not(.mat-stroked-button)+button.mat-stroked-button{border-left-width:0}\n"] }]
|
|
907
|
+
}], propDecorators: { layout: [{
|
|
908
|
+
type: Input
|
|
909
|
+
}], size: [{
|
|
910
|
+
type: Input
|
|
911
|
+
}] } });
|
|
912
|
+
|
|
913
|
+
class FwButtonGroupModule {
|
|
914
|
+
}
|
|
915
|
+
FwButtonGroupModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwButtonGroupModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
916
|
+
FwButtonGroupModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: FwButtonGroupModule, declarations: [FwButtonGroupComponent], exports: [FwButtonGroupComponent] });
|
|
917
|
+
FwButtonGroupModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwButtonGroupModule });
|
|
918
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwButtonGroupModule, decorators: [{
|
|
919
|
+
type: NgModule,
|
|
920
|
+
args: [{
|
|
921
|
+
exports: [
|
|
922
|
+
FwButtonGroupComponent,
|
|
923
|
+
],
|
|
924
|
+
declarations: [
|
|
925
|
+
FwButtonGroupComponent,
|
|
926
|
+
]
|
|
927
|
+
}]
|
|
928
|
+
}] });
|
|
929
|
+
|
|
943
930
|
class FwNotificationModule {
|
|
944
931
|
}
|
|
945
932
|
FwNotificationModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwNotificationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
@@ -1220,210 +1207,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImpor
|
|
|
1220
1207
|
}]
|
|
1221
1208
|
}] });
|
|
1222
1209
|
|
|
1223
|
-
class FwTableComponent {
|
|
1224
|
-
constructor(changeDetectorRef) {
|
|
1225
|
-
this.changeDetectorRef = changeDetectorRef;
|
|
1226
|
-
this.columns = [];
|
|
1227
|
-
this.dataSource = [];
|
|
1228
|
-
this.layout = 'basic';
|
|
1229
|
-
this.pageSize = null;
|
|
1230
|
-
this.webCompPageSize = null;
|
|
1231
|
-
this.sort = null;
|
|
1232
|
-
this.sortColumn = '';
|
|
1233
|
-
this.sortOrder = 'asc';
|
|
1234
|
-
this.displayedColumns = [];
|
|
1235
|
-
this.filters = new UntypedFormGroup({});
|
|
1236
|
-
// to support updating column header labels
|
|
1237
|
-
this.trackByIndex = i => i;
|
|
1238
|
-
}
|
|
1239
|
-
ngOnInit() {
|
|
1240
|
-
this.setDataSource();
|
|
1241
|
-
this.setColumns();
|
|
1242
|
-
this.addFilterControls();
|
|
1243
|
-
this.setFilter();
|
|
1244
|
-
this.matDataSource.filterPredicate = (row, filter) => {
|
|
1245
|
-
const filters = JSON.parse(filter);
|
|
1246
|
-
for (const filter in filters) {
|
|
1247
|
-
const filterValue = filters[filter];
|
|
1248
|
-
const rowValue = row[filter];
|
|
1249
|
-
// multi-select
|
|
1250
|
-
if (Array.isArray(filterValue) && filterValue.length > 0 && !filterValue.includes(rowValue)) {
|
|
1251
|
-
return false;
|
|
1252
|
-
}
|
|
1253
|
-
// input or select
|
|
1254
|
-
if (!Array.isArray(filterValue) && !String(rowValue).toLowerCase().includes(String(filterValue !== null && filterValue !== void 0 ? filterValue : '').toLowerCase())) {
|
|
1255
|
-
return false;
|
|
1256
|
-
}
|
|
1257
|
-
}
|
|
1258
|
-
return true;
|
|
1259
|
-
};
|
|
1260
|
-
this.filters.valueChanges.pipe(debounceTime(200)).subscribe(() => this.setFilter());
|
|
1261
|
-
}
|
|
1262
|
-
ngAfterViewInit() {
|
|
1263
|
-
this.setSort();
|
|
1264
|
-
this.setPaginator();
|
|
1265
|
-
}
|
|
1266
|
-
ngOnChanges(changes) {
|
|
1267
|
-
if (changes.columns) {
|
|
1268
|
-
this.setColumns();
|
|
1269
|
-
}
|
|
1270
|
-
if (changes.dataSource) {
|
|
1271
|
-
this.setDataSource();
|
|
1272
|
-
}
|
|
1273
|
-
if (changes.sort || changes.dataSource) {
|
|
1274
|
-
this.setSort();
|
|
1275
|
-
}
|
|
1276
|
-
if (changes.pageSize || changes['page-size']) {
|
|
1277
|
-
this.setPaginator();
|
|
1278
|
-
}
|
|
1279
|
-
}
|
|
1280
|
-
get isCompact() {
|
|
1281
|
-
return this.layout === 'compact';
|
|
1282
|
-
}
|
|
1283
|
-
get paginationSize() {
|
|
1284
|
-
return this.pageSize || this.webCompPageSize || 0;
|
|
1285
|
-
}
|
|
1286
|
-
get isSortEnabled() {
|
|
1287
|
-
return this.sort !== null;
|
|
1288
|
-
}
|
|
1289
|
-
addFilterControls() {
|
|
1290
|
-
for (const column of this.columns) {
|
|
1291
|
-
this.filters.addControl(column.key, new UntypedFormControl());
|
|
1292
|
-
}
|
|
1293
|
-
}
|
|
1294
|
-
setDataSource() {
|
|
1295
|
-
this.matDataSource = new MatTableDataSource(this.dataSource);
|
|
1296
|
-
}
|
|
1297
|
-
setColumns() {
|
|
1298
|
-
this.displayedColumns = this.columns.map(column => column.key);
|
|
1299
|
-
}
|
|
1300
|
-
setFilter() {
|
|
1301
|
-
this.matDataSource.filter = JSON.stringify(this.filters.value);
|
|
1302
|
-
}
|
|
1303
|
-
setSort() {
|
|
1304
|
-
if (!this.matSort || this.sort === null) {
|
|
1305
|
-
return;
|
|
1306
|
-
}
|
|
1307
|
-
const sortSplit = this.sort.split(' ');
|
|
1308
|
-
this.sortColumn = sortSplit[0];
|
|
1309
|
-
if (['asc', 'desc'].includes(sortSplit[1])) {
|
|
1310
|
-
this.sortOrder = sortSplit[1];
|
|
1311
|
-
}
|
|
1312
|
-
else {
|
|
1313
|
-
console.warn(`Sort order '${sortSplit[1]}' is not 'asc' or 'desc', defaulting to 'asc'`);
|
|
1314
|
-
}
|
|
1315
|
-
if (this.sortColumn) {
|
|
1316
|
-
this.matSort.sort({ id: this.sortColumn, start: this.sortOrder, disableClear: false });
|
|
1317
|
-
const sortHeader = this.matSort.sortables.get(this.sortColumn);
|
|
1318
|
-
if (sortHeader) {
|
|
1319
|
-
sortHeader._setAnimationTransitionState({ toState: 'active' });
|
|
1320
|
-
}
|
|
1321
|
-
else {
|
|
1322
|
-
console.warn(`Unable to find sort column '${this.sortColumn}'. Initial sort failed.`);
|
|
1323
|
-
}
|
|
1324
|
-
}
|
|
1325
|
-
this.matDataSource.sort = this.matSort;
|
|
1326
|
-
}
|
|
1327
|
-
setPaginator() {
|
|
1328
|
-
// ensures ui updates correctly when paginator options change
|
|
1329
|
-
this.changeDetectorRef.detectChanges();
|
|
1330
|
-
this.matDataSource.paginator = this.matPaginator;
|
|
1331
|
-
}
|
|
1332
|
-
// necessary for web component to trigger this.filter.valueChanges
|
|
1333
|
-
onInputFilter(event, column) {
|
|
1334
|
-
// defer setting filter control as event.target.value is not set yet
|
|
1335
|
-
setTimeout(() => this.filters.get(column.key).setValue(event.target.value));
|
|
1336
|
-
}
|
|
1337
|
-
// necessary for web component to trigger this.filter.valueChanges
|
|
1338
|
-
onSelectFilter(event, column) {
|
|
1339
|
-
const innerText = event.target.innerText;
|
|
1340
|
-
this.filters.get(column.key).setValue(innerText === '- none -' ? null : innerText);
|
|
1341
|
-
}
|
|
1342
|
-
// necessary for web component to trigger this.filter.valueChanges
|
|
1343
|
-
onMultiSelectFilter(event, column) {
|
|
1344
|
-
let value = this.filters.controls[column.key].value || [];
|
|
1345
|
-
const innerText = event.target.parentElement.innerText;
|
|
1346
|
-
if (value.includes(innerText)) {
|
|
1347
|
-
value = value.filter(v => v !== innerText);
|
|
1348
|
-
}
|
|
1349
|
-
else {
|
|
1350
|
-
value.push(innerText);
|
|
1351
|
-
}
|
|
1352
|
-
this.filters.get(column.key).setValue(value.length === 1 && innerText === ''
|
|
1353
|
-
? null // when all checboxes have been deselected
|
|
1354
|
-
: value);
|
|
1355
|
-
}
|
|
1356
|
-
}
|
|
1357
|
-
FwTableComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwTableComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
1358
|
-
FwTableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: FwTableComponent, selector: "fw-table", inputs: { columns: "columns", dataSource: "dataSource", layout: "layout", pageSize: "pageSize", webCompPageSize: ["page-size", "webCompPageSize"], sort: "sort" }, host: { properties: { "class.compact": "isCompact" }, classAttribute: "fw-table" }, viewQueries: [{ propertyName: "matPaginator", first: true, predicate: MatPaginator, descendants: true }, { propertyName: "matSort", first: true, predicate: MatSort, descendants: true }], usesOnChanges: true, ngImport: i0, template: "<table mat-table [dataSource]=\"matDataSource\" matSort>\n <ng-container *ngFor=\"let column of columns; trackBy: trackByIndex\">\n <ng-container [matColumnDef]=\"column.key\">\n\n <ng-template #tableHeaders>\n <ng-container [ngSwitch]=\"column.filter?.control\">\n <ng-container *ngSwitchCase=\"'input'\">\n <mat-form-field *ngIf=\"filters.get(column.key) as control\" appearance=\"outline\" (click)=\"$event.stopPropagation()\">\n <mat-label *ngIf=\"!isCompact\">{{ column.label }}</mat-label>\n <input matInput [formControl]=\"control\" [placeholder]=\"column.filter.placeholder\" (keydown)=\"$event.stopPropagation(); onInputFilter($event, column);\">\n </mat-form-field>\n </ng-container>\n <ng-container *ngSwitchCase=\"'select'\">\n <mat-form-field *ngIf=\"filters.get(column.key) as control\" appearance=\"outline\" (click)=\"$event.stopPropagation()\">\n <mat-label *ngIf=\"!isCompact\">{{ column.label }}</mat-label>\n <mat-select [formControl]=\"control\" [placeholder]=\"column.filter.placeholder\">\n <mat-option (click)=\"onSelectFilter($event, column);\">- none -</mat-option>\n <mat-option *ngFor=\"let option of column.filter.options\" [value]=\"option\" (click)=\"onSelectFilter($event, column);\">{{ option }}</mat-option>\n </mat-select>\n </mat-form-field>\n </ng-container>\n <ng-container *ngSwitchCase=\"'multi-select'\">\n <mat-form-field *ngIf=\"filters.get(column.key) as control\" appearance=\"outline\" (click)=\"$event.stopPropagation()\">\n <mat-label *ngIf=\"!isCompact\">{{ column.label }}</mat-label>\n <mat-select [formControl]=\"control\" [placeholder]=\"column.filter.placeholder\" multiple=\"true\">\n <mat-option *ngFor=\"let option of column.filter.options\" [value]=\"option\" (click)=\"onMultiSelectFilter($event, column);\">{{ option }}</mat-option>\n </mat-select>\n </mat-form-field>\n </ng-container>\n <ng-container *ngSwitchDefault>{{ column.label }}</ng-container>\n </ng-container>\n </ng-template>\n\n <ng-container *ngIf=\"isSortEnabled\">\n <th mat-header-cell *matHeaderCellDef mat-sort-header>\n <ng-container [ngTemplateOutlet]=\"tableHeaders\"></ng-container>\n </th>\n </ng-container>\n\n <ng-container *ngIf=\"!isSortEnabled\">\n <th mat-header-cell *matHeaderCellDef>\n <ng-container [ngTemplateOutlet]=\"tableHeaders\"></ng-container>\n </th>\n </ng-container>\n\n <td mat-cell *matCellDef=\"let element\"> {{ element[column.key] }} </td>\n </ng-container>\n </ng-container>\n <tr mat-header-row *matHeaderRowDef=\"displayedColumns\"></tr>\n <tr mat-row *matRowDef=\"let row; columns: displayedColumns;\"></tr>\n</table>\n<mat-paginator *ngIf=\"paginationSize > 0\" [pageSize]=\"paginationSize\"></mat-paginator>\n\n\n\n", styles: [":host{display:block;width:100%}:host:not(.compact) table.mat-table tr.mat-header-row,:host:not(.compact) table.mat-table tr.mat-row{height:56px}:host.compact table.mat-table tr.mat-header-row,:host.compact table.mat-table tr.mat-row{height:32px}:host.compact mat-paginator.mat-paginator{align-items:center;display:flex;height:32px;justify-content:flex-end}table.mat-table{width:100%}table.mat-table th,table.mat-table td{vertical-align:middle}table.mat-table th.mat-header-cell,table.mat-table th.mat-cell,table.mat-table td.mat-header-cell,table.mat-table td.mat-cell{border-bottom-color:var(--color-gray)}\n"], dependencies: [{ kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i1.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "directive", type: i2$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i3$1.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i3$1.MatLabel, selector: "mat-label" }, { kind: "directive", type: i4$1.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "component", type: i5$1.MatPaginator, selector: "mat-paginator", inputs: ["disabled"], exportAs: ["matPaginator"] }, { kind: "component", type: i6.MatSelect, selector: "mat-select", inputs: ["disabled", "disableRipple", "tabIndex"], exportAs: ["matSelect"] }, { kind: "component", type: i7.MatOption, selector: "mat-option", exportAs: ["matOption"] }, { kind: "directive", type: i8.MatSort, selector: "[matSort]", inputs: ["matSortDisabled", "matSortActive", "matSortStart", "matSortDirection", "matSortDisableClear"], outputs: ["matSortChange"], exportAs: ["matSort"] }, { kind: "component", type: i8.MatSortHeader, selector: "[mat-sort-header]", inputs: ["disabled", "mat-sort-header", "arrowPosition", "start", "sortActionDescription", "disableClear"], exportAs: ["matSortHeader"] }, { kind: "component", type: i9.MatTable, selector: "mat-table, table[mat-table]", exportAs: ["matTable"] }, { kind: "directive", type: i9.MatHeaderCellDef, selector: "[matHeaderCellDef]" }, { kind: "directive", type: i9.MatHeaderRowDef, selector: "[matHeaderRowDef]", inputs: ["matHeaderRowDef", "matHeaderRowDefSticky"] }, { kind: "directive", type: i9.MatColumnDef, selector: "[matColumnDef]", inputs: ["sticky", "matColumnDef"] }, { kind: "directive", type: i9.MatCellDef, selector: "[matCellDef]" }, { kind: "directive", type: i9.MatRowDef, selector: "[matRowDef]", inputs: ["matRowDefColumns", "matRowDefWhen"] }, { kind: "directive", type: i9.MatHeaderCell, selector: "mat-header-cell, th[mat-header-cell]" }, { kind: "directive", type: i9.MatCell, selector: "mat-cell, td[mat-cell]" }, { kind: "component", type: i9.MatHeaderRow, selector: "mat-header-row, tr[mat-header-row]", exportAs: ["matHeaderRow"] }, { kind: "component", type: i9.MatRow, selector: "mat-row, tr[mat-row]", exportAs: ["matRow"] }] });
|
|
1359
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwTableComponent, decorators: [{
|
|
1360
|
-
type: Component,
|
|
1361
|
-
args: [{ host: {
|
|
1362
|
-
'class': 'fw-table',
|
|
1363
|
-
'[class.compact]': 'isCompact',
|
|
1364
|
-
}, selector: 'fw-table', template: "<table mat-table [dataSource]=\"matDataSource\" matSort>\n <ng-container *ngFor=\"let column of columns; trackBy: trackByIndex\">\n <ng-container [matColumnDef]=\"column.key\">\n\n <ng-template #tableHeaders>\n <ng-container [ngSwitch]=\"column.filter?.control\">\n <ng-container *ngSwitchCase=\"'input'\">\n <mat-form-field *ngIf=\"filters.get(column.key) as control\" appearance=\"outline\" (click)=\"$event.stopPropagation()\">\n <mat-label *ngIf=\"!isCompact\">{{ column.label }}</mat-label>\n <input matInput [formControl]=\"control\" [placeholder]=\"column.filter.placeholder\" (keydown)=\"$event.stopPropagation(); onInputFilter($event, column);\">\n </mat-form-field>\n </ng-container>\n <ng-container *ngSwitchCase=\"'select'\">\n <mat-form-field *ngIf=\"filters.get(column.key) as control\" appearance=\"outline\" (click)=\"$event.stopPropagation()\">\n <mat-label *ngIf=\"!isCompact\">{{ column.label }}</mat-label>\n <mat-select [formControl]=\"control\" [placeholder]=\"column.filter.placeholder\">\n <mat-option (click)=\"onSelectFilter($event, column);\">- none -</mat-option>\n <mat-option *ngFor=\"let option of column.filter.options\" [value]=\"option\" (click)=\"onSelectFilter($event, column);\">{{ option }}</mat-option>\n </mat-select>\n </mat-form-field>\n </ng-container>\n <ng-container *ngSwitchCase=\"'multi-select'\">\n <mat-form-field *ngIf=\"filters.get(column.key) as control\" appearance=\"outline\" (click)=\"$event.stopPropagation()\">\n <mat-label *ngIf=\"!isCompact\">{{ column.label }}</mat-label>\n <mat-select [formControl]=\"control\" [placeholder]=\"column.filter.placeholder\" multiple=\"true\">\n <mat-option *ngFor=\"let option of column.filter.options\" [value]=\"option\" (click)=\"onMultiSelectFilter($event, column);\">{{ option }}</mat-option>\n </mat-select>\n </mat-form-field>\n </ng-container>\n <ng-container *ngSwitchDefault>{{ column.label }}</ng-container>\n </ng-container>\n </ng-template>\n\n <ng-container *ngIf=\"isSortEnabled\">\n <th mat-header-cell *matHeaderCellDef mat-sort-header>\n <ng-container [ngTemplateOutlet]=\"tableHeaders\"></ng-container>\n </th>\n </ng-container>\n\n <ng-container *ngIf=\"!isSortEnabled\">\n <th mat-header-cell *matHeaderCellDef>\n <ng-container [ngTemplateOutlet]=\"tableHeaders\"></ng-container>\n </th>\n </ng-container>\n\n <td mat-cell *matCellDef=\"let element\"> {{ element[column.key] }} </td>\n </ng-container>\n </ng-container>\n <tr mat-header-row *matHeaderRowDef=\"displayedColumns\"></tr>\n <tr mat-row *matRowDef=\"let row; columns: displayedColumns;\"></tr>\n</table>\n<mat-paginator *ngIf=\"paginationSize > 0\" [pageSize]=\"paginationSize\"></mat-paginator>\n\n\n\n", styles: [":host{display:block;width:100%}:host:not(.compact) table.mat-table tr.mat-header-row,:host:not(.compact) table.mat-table tr.mat-row{height:56px}:host.compact table.mat-table tr.mat-header-row,:host.compact table.mat-table tr.mat-row{height:32px}:host.compact mat-paginator.mat-paginator{align-items:center;display:flex;height:32px;justify-content:flex-end}table.mat-table{width:100%}table.mat-table th,table.mat-table td{vertical-align:middle}table.mat-table th.mat-header-cell,table.mat-table th.mat-cell,table.mat-table td.mat-header-cell,table.mat-table td.mat-cell{border-bottom-color:var(--color-gray)}\n"] }]
|
|
1365
|
-
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { columns: [{
|
|
1366
|
-
type: Input
|
|
1367
|
-
}], dataSource: [{
|
|
1368
|
-
type: Input
|
|
1369
|
-
}], layout: [{
|
|
1370
|
-
type: Input
|
|
1371
|
-
}], pageSize: [{
|
|
1372
|
-
type: Input
|
|
1373
|
-
}], webCompPageSize: [{
|
|
1374
|
-
type: Input,
|
|
1375
|
-
args: ['page-size']
|
|
1376
|
-
}], sort: [{
|
|
1377
|
-
type: Input
|
|
1378
|
-
}], matPaginator: [{
|
|
1379
|
-
type: ViewChild,
|
|
1380
|
-
args: [MatPaginator]
|
|
1381
|
-
}], matSort: [{
|
|
1382
|
-
type: ViewChild,
|
|
1383
|
-
args: [MatSort]
|
|
1384
|
-
}] } });
|
|
1385
|
-
|
|
1386
|
-
class FwTableModule {
|
|
1387
|
-
}
|
|
1388
|
-
FwTableModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwTableModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1389
|
-
FwTableModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: FwTableModule, declarations: [FwTableComponent], imports: [CommonModule,
|
|
1390
|
-
FormsModule,
|
|
1391
|
-
ReactiveFormsModule,
|
|
1392
|
-
MatInputModule,
|
|
1393
|
-
MatPaginatorModule,
|
|
1394
|
-
MatSelectModule,
|
|
1395
|
-
MatSortModule,
|
|
1396
|
-
MatTableModule], exports: [FwTableComponent] });
|
|
1397
|
-
FwTableModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwTableModule, imports: [CommonModule,
|
|
1398
|
-
FormsModule,
|
|
1399
|
-
ReactiveFormsModule,
|
|
1400
|
-
MatInputModule,
|
|
1401
|
-
MatPaginatorModule,
|
|
1402
|
-
MatSelectModule,
|
|
1403
|
-
MatSortModule,
|
|
1404
|
-
MatTableModule] });
|
|
1405
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwTableModule, decorators: [{
|
|
1406
|
-
type: NgModule,
|
|
1407
|
-
args: [{
|
|
1408
|
-
imports: [
|
|
1409
|
-
CommonModule,
|
|
1410
|
-
FormsModule,
|
|
1411
|
-
ReactiveFormsModule,
|
|
1412
|
-
MatInputModule,
|
|
1413
|
-
MatPaginatorModule,
|
|
1414
|
-
MatSelectModule,
|
|
1415
|
-
MatSortModule,
|
|
1416
|
-
MatTableModule,
|
|
1417
|
-
],
|
|
1418
|
-
exports: [
|
|
1419
|
-
FwTableComponent,
|
|
1420
|
-
],
|
|
1421
|
-
declarations: [
|
|
1422
|
-
FwTableComponent,
|
|
1423
|
-
]
|
|
1424
|
-
}]
|
|
1425
|
-
}] });
|
|
1426
|
-
|
|
1427
1210
|
class BackButtonComponent {
|
|
1428
1211
|
constructor(location) {
|
|
1429
1212
|
this.location = location;
|
|
@@ -1486,9 +1269,105 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImpor
|
|
|
1486
1269
|
}]
|
|
1487
1270
|
}] });
|
|
1488
1271
|
|
|
1272
|
+
class FwTextInputComponent {
|
|
1273
|
+
constructor() {
|
|
1274
|
+
this.size = 'medium';
|
|
1275
|
+
// we bind this to host because that's where angular form apis put the error classes
|
|
1276
|
+
this.error = false;
|
|
1277
|
+
this.value = '';
|
|
1278
|
+
this.externalControl = null;
|
|
1279
|
+
this.disabled = false;
|
|
1280
|
+
this.onTouch = () => { };
|
|
1281
|
+
this.onChange = (value) => { };
|
|
1282
|
+
}
|
|
1283
|
+
ngOnInit() {
|
|
1284
|
+
console.log(this.leftIcon, this.rightIcon, this.context, this.helperText, this.placeholder);
|
|
1285
|
+
}
|
|
1286
|
+
writeValue(obj) {
|
|
1287
|
+
this.value = obj;
|
|
1288
|
+
}
|
|
1289
|
+
registerOnChange(fn) {
|
|
1290
|
+
this.onChange = fn;
|
|
1291
|
+
}
|
|
1292
|
+
registerOnTouched(fn) {
|
|
1293
|
+
this.onTouch = fn;
|
|
1294
|
+
}
|
|
1295
|
+
setDisabledState(isDisabled) {
|
|
1296
|
+
this.disabled = isDisabled;
|
|
1297
|
+
}
|
|
1298
|
+
changeHandler(event) {
|
|
1299
|
+
this.value = event.target.value;
|
|
1300
|
+
this.onChange(this.value);
|
|
1301
|
+
this.onTouch();
|
|
1302
|
+
}
|
|
1303
|
+
blurHandler() {
|
|
1304
|
+
this.onTouch();
|
|
1305
|
+
}
|
|
1306
|
+
}
|
|
1307
|
+
FwTextInputComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwTextInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1308
|
+
FwTextInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: FwTextInputComponent, selector: "fw-text-input", inputs: { leftIcon: "leftIcon", rightIcon: "rightIcon", context: "context", helperText: "helperText", placeholder: "placeholder", size: "size", error: "error" }, host: { properties: { "class.errored": "this.error" } }, providers: [{
|
|
1309
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1310
|
+
useExisting: FwTextInputComponent,
|
|
1311
|
+
multi: true
|
|
1312
|
+
}], ngImport: i0, template: "<div class=\"full-container\">\n <div class=\"input-container\" [class]=\"size\">\n <fw-icon *ngIf=\"!!leftIcon\">{{leftIcon}}</fw-icon>\n\n <input \n type=\"text\"\n (keyup)=\"changeHandler($event)\"\n (blur)=\"blurHandler()\"\n [value]=\"value\"\n [placeholder]=\"placeholder || ''\"\n [disabled]=\"disabled\">\n\n <p class=\"context\" *ngIf=\"!!context\">{{context}}</p>\n\n <fw-icon class=\"error-icon\">warning-circle</fw-icon>\n <fw-icon *ngIf=\"!!rightIcon\">{{rightIcon}}</fw-icon>\n </div>\n <p class=\"helperText\" *ngIf=\"!!helperText\">{{helperText}}</p>\n</div>", styles: [".full-container{display:flex;flex-direction:column;line-height:21px}.full-container .input-container{color:var(--typography-light);background:var(--page-light);display:flex;padding:8px;align-items:center;gap:5px;border-radius:6px;border:1px solid var(--separations-input);font-family:Inter}.full-container .input-container:focus-within{border:1px solid var(--primary-base)}.full-container .input-container input{min-width:0;flex-grow:1;color:var(--typography-base);background:var(--page-light);border:none}.full-container .input-container input:focus{outline:none;border:none}.full-container .input-container .context{color:var(--typography-light)}.full-container .error-icon{display:none}.full-container .helperText{margin-top:4px;color:var(--typography-light);font-family:Inter;font-size:10px;font-style:normal;font-weight:400;line-height:130%;margin-left:6px}.small{height:30px}.small>fw-icon{font-size:18px}.medium{height:36px}.medium>fw-icon{font-size:20px}.large{height:40px}.large>fw-icon{font-size:24px}:host.ng-touched.ng-invalid .input-container,:host.errored .input-container{border:1px solid var(--red-base)}:host.ng-touched.ng-invalid .error-icon,:host.errored .error-icon{color:var(--red-base);display:inline!important}:host.ng-touched.ng-invalid .helperText,:host.errored .helperText{color:var(--red-base)}:disabled{opacity:.4;cursor:not-allowed}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: FwIconComponent, selector: "fw-icon" }] });
|
|
1313
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwTextInputComponent, decorators: [{
|
|
1314
|
+
type: Component,
|
|
1315
|
+
args: [{ selector: 'fw-text-input', providers: [{
|
|
1316
|
+
provide: NG_VALUE_ACCESSOR,
|
|
1317
|
+
useExisting: FwTextInputComponent,
|
|
1318
|
+
multi: true
|
|
1319
|
+
}], template: "<div class=\"full-container\">\n <div class=\"input-container\" [class]=\"size\">\n <fw-icon *ngIf=\"!!leftIcon\">{{leftIcon}}</fw-icon>\n\n <input \n type=\"text\"\n (keyup)=\"changeHandler($event)\"\n (blur)=\"blurHandler()\"\n [value]=\"value\"\n [placeholder]=\"placeholder || ''\"\n [disabled]=\"disabled\">\n\n <p class=\"context\" *ngIf=\"!!context\">{{context}}</p>\n\n <fw-icon class=\"error-icon\">warning-circle</fw-icon>\n <fw-icon *ngIf=\"!!rightIcon\">{{rightIcon}}</fw-icon>\n </div>\n <p class=\"helperText\" *ngIf=\"!!helperText\">{{helperText}}</p>\n</div>", styles: [".full-container{display:flex;flex-direction:column;line-height:21px}.full-container .input-container{color:var(--typography-light);background:var(--page-light);display:flex;padding:8px;align-items:center;gap:5px;border-radius:6px;border:1px solid var(--separations-input);font-family:Inter}.full-container .input-container:focus-within{border:1px solid var(--primary-base)}.full-container .input-container input{min-width:0;flex-grow:1;color:var(--typography-base);background:var(--page-light);border:none}.full-container .input-container input:focus{outline:none;border:none}.full-container .input-container .context{color:var(--typography-light)}.full-container .error-icon{display:none}.full-container .helperText{margin-top:4px;color:var(--typography-light);font-family:Inter;font-size:10px;font-style:normal;font-weight:400;line-height:130%;margin-left:6px}.small{height:30px}.small>fw-icon{font-size:18px}.medium{height:36px}.medium>fw-icon{font-size:20px}.large{height:40px}.large>fw-icon{font-size:24px}:host.ng-touched.ng-invalid .input-container,:host.errored .input-container{border:1px solid var(--red-base)}:host.ng-touched.ng-invalid .error-icon,:host.errored .error-icon{color:var(--red-base);display:inline!important}:host.ng-touched.ng-invalid .helperText,:host.errored .helperText{color:var(--red-base)}:disabled{opacity:.4;cursor:not-allowed}\n"] }]
|
|
1320
|
+
}], ctorParameters: function () { return []; }, propDecorators: { leftIcon: [{
|
|
1321
|
+
type: Input
|
|
1322
|
+
}], rightIcon: [{
|
|
1323
|
+
type: Input
|
|
1324
|
+
}], context: [{
|
|
1325
|
+
type: Input
|
|
1326
|
+
}], helperText: [{
|
|
1327
|
+
type: Input
|
|
1328
|
+
}], placeholder: [{
|
|
1329
|
+
type: Input
|
|
1330
|
+
}], size: [{
|
|
1331
|
+
type: Input
|
|
1332
|
+
}], error: [{
|
|
1333
|
+
type: HostBinding,
|
|
1334
|
+
args: ['class.errored']
|
|
1335
|
+
}, {
|
|
1336
|
+
type: Input
|
|
1337
|
+
}] } });
|
|
1338
|
+
|
|
1339
|
+
class FwTextInputModule {
|
|
1340
|
+
}
|
|
1341
|
+
FwTextInputModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwTextInputModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1342
|
+
FwTextInputModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.3.0", ngImport: i0, type: FwTextInputModule, declarations: [FwTextInputComponent], imports: [CommonModule,
|
|
1343
|
+
FwIconModule,
|
|
1344
|
+
ReactiveFormsModule], exports: [FwTextInputComponent] });
|
|
1345
|
+
FwTextInputModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwTextInputModule, imports: [CommonModule,
|
|
1346
|
+
FwIconModule,
|
|
1347
|
+
ReactiveFormsModule] });
|
|
1348
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: FwTextInputModule, decorators: [{
|
|
1349
|
+
type: NgModule,
|
|
1350
|
+
args: [{
|
|
1351
|
+
imports: [
|
|
1352
|
+
CommonModule,
|
|
1353
|
+
FwIconModule,
|
|
1354
|
+
ReactiveFormsModule
|
|
1355
|
+
],
|
|
1356
|
+
exports: [
|
|
1357
|
+
FwTextInputComponent,
|
|
1358
|
+
],
|
|
1359
|
+
declarations: [
|
|
1360
|
+
FwTextInputComponent,
|
|
1361
|
+
],
|
|
1362
|
+
entryComponents: [
|
|
1363
|
+
FwTextInputComponent,
|
|
1364
|
+
]
|
|
1365
|
+
}]
|
|
1366
|
+
}] });
|
|
1367
|
+
|
|
1489
1368
|
/**
|
|
1490
1369
|
* Generated bundle index. Do not edit.
|
|
1491
1370
|
*/
|
|
1492
1371
|
|
|
1493
|
-
export { FwAvatarComponent, FwAvatarModule, FwButtonComponent,
|
|
1372
|
+
export { FwAvatarComponent, FwAvatarModule, FwButtonComponent, FwButtonModule, FwChoiceDialog, FwConfirmDialog, FwDialogModule, FwDialogService, FwErrorDialog, FwIconComponent, FwIconModule, FwNotificationComponent, FwNotificationContainerComponent, FwNotificationModule, FwNotificationService, FwNotificationType, FwPopoverComponent, FwPopoverModule, FwPopoverTriggerComponent, FwPopoverTriggerDirective, FwPortalDialog, FwSectionHeadingComponent, FwSectionHeadingModule, FwTextInputComponent, FwTextInputModule, MinimalTranslationService, TranslationService, genId };
|
|
1494
1373
|
//# sourceMappingURL=flywheel-io-vision.mjs.map
|