@falcon-ng/tailwind 0.0.2 → 0.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2020/falcon-ng-tailwind.mjs +5 -0
- package/esm2020/lib/base-control.mjs +50 -0
- package/esm2020/lib/base-form-component.mjs +234 -0
- package/esm2020/lib/component/auto-complete/auto-complete.component.mjs +33 -0
- package/esm2020/lib/component/bottom-sheet/bottom-sheet.component.mjs +29 -0
- package/esm2020/lib/component/button/button.component.mjs +27 -0
- package/esm2020/lib/component/button-toggle/button-toggle.component.mjs +32 -0
- package/esm2020/lib/component/checkbox/checkbox.component.mjs +18 -0
- package/esm2020/lib/component/chips/chip.component.mjs +109 -0
- package/esm2020/lib/component/date-picker/date-picker.component.mjs +17 -0
- package/esm2020/lib/component/dialog/dialog.component.mjs +21 -0
- package/esm2020/lib/component/pagination/pagination.component.mjs +95 -0
- package/esm2020/lib/component/progress-bar/progress-bar.component.mjs +20 -0
- package/esm2020/lib/component/progress-spinner/progress-spinner.component.mjs +26 -0
- package/esm2020/lib/component/radio/radio.component.mjs +31 -0
- package/esm2020/lib/component/rich-text-editor/rich-text-editor.component.mjs +15 -0
- package/esm2020/lib/component/select/select.component.mjs +35 -0
- package/esm2020/lib/component/slide-toggle/slide-toggle.component.mjs +14 -0
- package/esm2020/lib/component/slider/slider.component.mjs +15 -0
- package/esm2020/lib/component/snack-bar/snack-bar.component.mjs +11 -0
- package/esm2020/lib/component/table/table.component.mjs +74 -0
- package/esm2020/lib/component/textarea/textarea.component.mjs +16 -0
- package/esm2020/lib/component/textbox/textbox.component.mjs +17 -0
- package/esm2020/lib/control-builder/control-builder.component.mjs +18 -0
- package/esm2020/lib/control-type/AutoComplete.mjs +8 -0
- package/esm2020/lib/control-type/Button.mjs +8 -0
- package/esm2020/lib/control-type/ButtonToggle.mjs +8 -0
- package/esm2020/lib/control-type/CheckBox.mjs +8 -0
- package/esm2020/lib/control-type/Chip.mjs +8 -0
- package/esm2020/lib/control-type/DatePicker.mjs +8 -0
- package/esm2020/lib/control-type/Divider.mjs +8 -0
- package/esm2020/lib/control-type/Editor.mjs +8 -0
- package/esm2020/lib/control-type/Radio.mjs +8 -0
- package/esm2020/lib/control-type/RichTextEditor.mjs +8 -0
- package/esm2020/lib/control-type/SlideToggle.mjs +8 -0
- package/esm2020/lib/control-type/Slider.mjs +8 -0
- package/esm2020/lib/control-type/Textarea.mjs +8 -0
- package/esm2020/lib/control-type/Textbox.mjs +8 -0
- package/esm2020/lib/control-type/select.mjs +8 -0
- package/esm2020/lib/falcon-core.module.mjs +230 -0
- package/esm2020/lib/model/constant.mjs +32 -0
- package/esm2020/lib/model/enum.mjs +2 -0
- package/esm2020/lib/model/environments.mjs +3 -0
- package/esm2020/lib/model/interface.mjs +2 -0
- package/esm2020/lib/model/ivalidator.mjs +2 -0
- package/esm2020/lib/module/angularmaterial.module.mjs +189 -0
- package/esm2020/lib/reactive-field.directive.mjs +28 -0
- package/esm2020/lib/service/appsetting.service.mjs +55 -0
- package/esm2020/lib/service/http/generic-http-client.mjs +197 -0
- package/esm2020/lib/service/http/igeneric-http-client.mjs +10 -0
- package/esm2020/lib/service/logger.service.mjs +78 -0
- package/esm2020/lib/service/open-id/TokenHelperService.mjs +71 -0
- package/esm2020/lib/service/open-id/auth-guard.service.mjs +30 -0
- package/esm2020/lib/service/open-id/auth.service.mjs +154 -0
- package/esm2020/public-api.mjs +47 -0
- package/fesm2015/falcon-ng-tailwind.mjs +1988 -0
- package/fesm2015/falcon-ng-tailwind.mjs.map +1 -0
- package/fesm2020/falcon-ng-tailwind.mjs +1962 -0
- package/fesm2020/falcon-ng-tailwind.mjs.map +1 -0
- package/index.d.ts +5 -0
- package/lib/base-control.d.ts +104 -0
- package/lib/base-form-component.d.ts +169 -0
- package/lib/component/auto-complete/auto-complete.component.d.ts +17 -0
- package/lib/component/bottom-sheet/bottom-sheet.component.d.ts +11 -0
- package/lib/component/button/button.component.d.ts +12 -0
- package/lib/component/button-toggle/button-toggle.component.d.ts +14 -0
- package/lib/component/checkbox/checkbox.component.d.ts +10 -0
- package/lib/component/chips/chip.component.d.ts +35 -0
- package/lib/component/date-picker/date-picker.component.d.ts +9 -0
- package/lib/component/dialog/dialog.component.d.ts +8 -0
- package/lib/component/pagination/pagination.component.d.ts +20 -0
- package/lib/component/progress-bar/progress-bar.component.d.ts +11 -0
- package/lib/component/progress-spinner/progress-spinner.component.d.ts +12 -0
- package/lib/component/radio/radio.component.d.ts +14 -0
- package/lib/component/rich-text-editor/rich-text-editor.component.d.ts +9 -0
- package/lib/component/select/select.component.d.ts +15 -0
- package/lib/component/slide-toggle/slide-toggle.component.d.ts +9 -0
- package/lib/component/slider/slider.component.d.ts +9 -0
- package/lib/component/snack-bar/snack-bar.component.d.ts +5 -0
- package/lib/component/table/table.component.d.ts +21 -0
- package/lib/component/textarea/textarea.component.d.ts +9 -0
- package/lib/component/textbox/textbox.component.d.ts +9 -0
- package/lib/control-builder/control-builder.component.d.ts +9 -0
- package/lib/control-type/AutoComplete.d.ts +5 -0
- package/lib/control-type/Button.d.ts +5 -0
- package/lib/control-type/ButtonToggle.d.ts +5 -0
- package/{src/lib/control-type/Chip.ts → lib/control-type/CheckBox.d.ts} +2 -3
- package/lib/control-type/Chip.d.ts +5 -0
- package/lib/control-type/DatePicker.d.ts +5 -0
- package/lib/control-type/Divider.d.ts +5 -0
- package/lib/control-type/Editor.d.ts +5 -0
- package/lib/control-type/Radio.d.ts +5 -0
- package/lib/control-type/RichTextEditor.d.ts +5 -0
- package/{src/lib/control-type/Radio.ts → lib/control-type/SlideToggle.d.ts} +2 -3
- package/lib/control-type/Slider.d.ts +5 -0
- package/lib/control-type/Textarea.d.ts +5 -0
- package/lib/control-type/Textbox.d.ts +5 -0
- package/lib/control-type/select.d.ts +5 -0
- package/lib/falcon-core.module.d.ts +35 -0
- package/lib/model/constant.d.ts +5 -0
- package/lib/model/enum.d.ts +144 -0
- package/{src/lib/model/environments.ts → lib/model/environments.d.ts} +5 -7
- package/{src/lib/model/interface.ts → lib/model/interface.d.ts} +80 -91
- package/{src/lib/model/ivalidator.ts → lib/model/ivalidator.d.ts} +3 -3
- package/lib/module/angularmaterial.module.d.ts +49 -0
- package/lib/reactive-field.directive.d.ts +14 -0
- package/lib/service/appsetting.service.d.ts +22 -0
- package/lib/service/http/generic-http-client.d.ts +121 -0
- package/lib/service/http/igeneric-http-client.d.ts +92 -0
- package/lib/service/logger.service.d.ts +18 -0
- package/lib/service/open-id/TokenHelperService.d.ts +11 -0
- package/lib/service/open-id/auth-guard.service.d.ts +11 -0
- package/lib/service/open-id/auth.service.d.ts +36 -0
- package/package.json +22 -2
- package/public-api.d.ts +34 -0
- package/ng-package.json +0 -7
- package/src/lib/base-control.ts +0 -142
- package/src/lib/base-form-component.ts +0 -363
- package/src/lib/component/auto-complete/auto-complete.component.html +0 -39
- package/src/lib/component/auto-complete/auto-complete.component.scss +0 -0
- package/src/lib/component/auto-complete/auto-complete.component.spec.ts +0 -23
- package/src/lib/component/auto-complete/auto-complete.component.ts +0 -31
- package/src/lib/component/bottom-sheet/bottom-sheet.component.html +0 -9
- package/src/lib/component/bottom-sheet/bottom-sheet.component.scss +0 -0
- package/src/lib/component/bottom-sheet/bottom-sheet.component.spec.ts +0 -23
- package/src/lib/component/bottom-sheet/bottom-sheet.component.ts +0 -19
- package/src/lib/component/button/button.component.css +0 -0
- package/src/lib/component/button/button.component.html +0 -54
- package/src/lib/component/button/button.component.spec.ts +0 -23
- package/src/lib/component/button/button.component.ts +0 -17
- package/src/lib/component/button-toggle/button-toggle.component.html +0 -21
- package/src/lib/component/button-toggle/button-toggle.component.scss +0 -0
- package/src/lib/component/button-toggle/button-toggle.component.spec.ts +0 -23
- package/src/lib/component/button-toggle/button-toggle.component.ts +0 -26
- package/src/lib/component/checkbox/checkbox.component.html +0 -6
- package/src/lib/component/checkbox/checkbox.component.scss +0 -0
- package/src/lib/component/checkbox/checkbox.component.spec.ts +0 -23
- package/src/lib/component/checkbox/checkbox.component.ts +0 -17
- package/src/lib/component/chips/chip.component.html +0 -75
- package/src/lib/component/chips/chip.component.scss +0 -3
- package/src/lib/component/chips/chip.component.spec.ts +0 -23
- package/src/lib/component/chips/chip.component.ts +0 -125
- package/src/lib/component/date-picker/date-picker.component.html +0 -18
- package/src/lib/component/date-picker/date-picker.component.scss +0 -0
- package/src/lib/component/date-picker/date-picker.component.spec.ts +0 -23
- package/src/lib/component/date-picker/date-picker.component.ts +0 -13
- package/src/lib/component/dialog/dialog.component.html +0 -12
- package/src/lib/component/dialog/dialog.component.scss +0 -3
- package/src/lib/component/dialog/dialog.component.spec.ts +0 -23
- package/src/lib/component/dialog/dialog.component.ts +0 -12
- package/src/lib/component/pagination/pagination.component.html +0 -10
- package/src/lib/component/pagination/pagination.component.scss +0 -0
- package/src/lib/component/pagination/pagination.component.spec.ts +0 -23
- package/src/lib/component/pagination/pagination.component.ts +0 -86
- package/src/lib/component/progress-bar/progress-bar.component.html +0 -1
- package/src/lib/component/progress-bar/progress-bar.component.scss +0 -0
- package/src/lib/component/progress-bar/progress-bar.component.spec.ts +0 -23
- package/src/lib/component/progress-bar/progress-bar.component.ts +0 -15
- package/src/lib/component/progress-spinner/progress-spinner.component.html +0 -7
- package/src/lib/component/progress-spinner/progress-spinner.component.scss +0 -0
- package/src/lib/component/progress-spinner/progress-spinner.component.spec.ts +0 -23
- package/src/lib/component/progress-spinner/progress-spinner.component.ts +0 -16
- package/src/lib/component/radio/radio.component.html +0 -13
- package/src/lib/component/radio/radio.component.scss +0 -14
- package/src/lib/component/radio/radio.component.spec.ts +0 -23
- package/src/lib/component/radio/radio.component.ts +0 -29
- package/src/lib/component/rich-text-editor/rich-text-editor.component.html +0 -10
- package/src/lib/component/rich-text-editor/rich-text-editor.component.scss +0 -0
- package/src/lib/component/rich-text-editor/rich-text-editor.component.spec.ts +0 -23
- package/src/lib/component/rich-text-editor/rich-text-editor.component.ts +0 -13
- package/src/lib/component/select/select.component.html +0 -25
- package/src/lib/component/select/select.component.scss +0 -0
- package/src/lib/component/select/select.component.spec.ts +0 -23
- package/src/lib/component/select/select.component.ts +0 -32
- package/src/lib/component/slide-toggle/slide-toggle.component.html +0 -7
- package/src/lib/component/slide-toggle/slide-toggle.component.scss +0 -0
- package/src/lib/component/slide-toggle/slide-toggle.component.spec.ts +0 -23
- package/src/lib/component/slide-toggle/slide-toggle.component.ts +0 -13
- package/src/lib/component/slider/slider.component.html +0 -11
- package/src/lib/component/slider/slider.component.scss +0 -0
- package/src/lib/component/slider/slider.component.spec.ts +0 -23
- package/src/lib/component/slider/slider.component.ts +0 -13
- package/src/lib/component/snack-bar/snack-bar.component.html +0 -1
- package/src/lib/component/snack-bar/snack-bar.component.scss +0 -0
- package/src/lib/component/snack-bar/snack-bar.component.spec.ts +0 -23
- package/src/lib/component/snack-bar/snack-bar.component.ts +0 -10
- package/src/lib/component/table/table.component.html +0 -82
- package/src/lib/component/table/table.component.scss +0 -17
- package/src/lib/component/table/table.component.spec.ts +0 -23
- package/src/lib/component/table/table.component.ts +0 -54
- package/src/lib/component/textarea/textarea.component.html +0 -22
- package/src/lib/component/textarea/textarea.component.scss +0 -3
- package/src/lib/component/textarea/textarea.component.spec.ts +0 -23
- package/src/lib/component/textarea/textarea.component.ts +0 -13
- package/src/lib/component/textbox/textbox.component.html +0 -27
- package/src/lib/component/textbox/textbox.component.scss +0 -3
- package/src/lib/component/textbox/textbox.component.spec.ts +0 -23
- package/src/lib/component/textbox/textbox.component.ts +0 -13
- package/src/lib/control-builder/control-builder.component.html +0 -5
- package/src/lib/control-builder/control-builder.component.scss +0 -0
- package/src/lib/control-builder/control-builder.component.ts +0 -14
- package/src/lib/control-type/AutoComplete.ts +0 -6
- package/src/lib/control-type/Button.ts +0 -6
- package/src/lib/control-type/ButtonToggle.ts +0 -6
- package/src/lib/control-type/CheckBox.ts +0 -6
- package/src/lib/control-type/DatePicker.ts +0 -6
- package/src/lib/control-type/Divider.ts +0 -6
- package/src/lib/control-type/Editor.ts +0 -6
- package/src/lib/control-type/RichTextEditor.ts +0 -6
- package/src/lib/control-type/SlideToggle.ts +0 -6
- package/src/lib/control-type/Slider.ts +0 -6
- package/src/lib/control-type/select.ts +0 -6
- package/src/lib/control-type/textarea.ts +0 -6
- package/src/lib/control-type/textbox.ts +0 -6
- package/src/lib/falcon-core.module.ts +0 -141
- package/src/lib/model/constant.ts +0 -32
- package/src/lib/model/enum.ts +0 -151
- package/src/lib/module/angularmaterial.module.ts +0 -98
- package/src/lib/reactive-field.directive.ts +0 -24
- package/src/lib/service/appsetting.service.ts +0 -57
- package/src/lib/service/http/generic-http-client.ts +0 -205
- package/src/lib/service/http/httpInterceptor.ts +0 -36
- package/src/lib/service/http/igeneric-http-client.ts +0 -110
- package/src/lib/service/logger.service.ts +0 -75
- package/src/lib/service/open-id/TokenHelperService.ts +0 -76
- package/src/lib/service/open-id/auth-guard.service.ts +0 -25
- package/src/lib/service/open-id/auth.service.ts +0 -179
- package/src/public-api.ts +0 -35
- package/tsconfig.lib.json +0 -15
- package/tsconfig.lib.prod.json +0 -10
- package/tsconfig.spec.json +0 -14
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { ComponentFixture, TestBed } from '@angular/core/testing';
|
|
2
|
-
|
|
3
|
-
import { TextboxComponent } from './textbox.component';
|
|
4
|
-
|
|
5
|
-
describe('TextboxComponent', () => {
|
|
6
|
-
let component: TextboxComponent;
|
|
7
|
-
let fixture: ComponentFixture<TextboxComponent>;
|
|
8
|
-
|
|
9
|
-
beforeEach(async () => {
|
|
10
|
-
await TestBed.configureTestingModule({
|
|
11
|
-
declarations: [ TextboxComponent ]
|
|
12
|
-
})
|
|
13
|
-
.compileComponents();
|
|
14
|
-
|
|
15
|
-
fixture = TestBed.createComponent(TextboxComponent);
|
|
16
|
-
component = fixture.componentInstance;
|
|
17
|
-
fixture.detectChanges();
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
it('should create', () => {
|
|
21
|
-
expect(component).toBeTruthy();
|
|
22
|
-
});
|
|
23
|
-
});
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { Component, OnInit } from '@angular/core';
|
|
2
|
-
import { FormGroup } from '@angular/forms';
|
|
3
|
-
import { BaseControl } from '../../base-control';
|
|
4
|
-
|
|
5
|
-
@Component({
|
|
6
|
-
selector: 'falcon-textbox',
|
|
7
|
-
templateUrl: './textbox.component.html',
|
|
8
|
-
styleUrls: ['./textbox.component.scss'],
|
|
9
|
-
})
|
|
10
|
-
export class TextboxComponent {
|
|
11
|
-
control!: BaseControl<string>;
|
|
12
|
-
formGroup!: FormGroup;
|
|
13
|
-
}
|
|
File without changes
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import {Component, Input} from '@angular/core';
|
|
2
|
-
import {FormGroup, ReactiveFormsModule} from "@angular/forms";
|
|
3
|
-
import {BaseControl, Layout} from "../base-control";
|
|
4
|
-
import {CommonModule} from "@angular/common";
|
|
5
|
-
|
|
6
|
-
@Component({
|
|
7
|
-
selector: 'control-builder',
|
|
8
|
-
templateUrl: './control-builder.component.html',
|
|
9
|
-
styleUrls: ['./control-builder.component.scss']
|
|
10
|
-
})
|
|
11
|
-
export class ControlBuilderComponent {
|
|
12
|
-
@Input() layout!: Layout<string>;
|
|
13
|
-
@Input() formGroup!: FormGroup;
|
|
14
|
-
}
|
|
@@ -1,141 +0,0 @@
|
|
|
1
|
-
import {ModuleWithProviders, NgModule, APP_INITIALIZER, inject} from '@angular/core';
|
|
2
|
-
import {TextboxComponent} from './component/textbox/textbox.component';
|
|
3
|
-
import {TextareaComponent} from './component/textarea/textarea.component';
|
|
4
|
-
import {SelectComponent} from './component/select/select.component';
|
|
5
|
-
import {ReactiveFieldDirective} from './reactive-field.directive';
|
|
6
|
-
import {AngularmaterialModule} from "./module/angularmaterial.module";
|
|
7
|
-
import {CommonModule} from "@angular/common";
|
|
8
|
-
import {FormsModule, ReactiveFormsModule} from "@angular/forms";
|
|
9
|
-
import {ControlBuilderComponent} from "./control-builder/control-builder.component";
|
|
10
|
-
import {EnvironmentViewModel} from "./model/environments";
|
|
11
|
-
import {RouterModule} from "@angular/router";
|
|
12
|
-
import {IGenericHttpClient} from "./service/http/igeneric-http-client";
|
|
13
|
-
import {GenericHttpClient} from "./service/http/generic-http-client";
|
|
14
|
-
import {AppSettingService, appSettingsFactory} from "./service/appsetting.service";
|
|
15
|
-
import {AuthService, authServiceFactory} from "./service/open-id/auth.service";
|
|
16
|
-
import {LoggerService, loggerServiceFactory} from "./service/logger.service";
|
|
17
|
-
import {MAT_SNACK_BAR_DEFAULT_OPTIONS} from "@angular/material/snack-bar";
|
|
18
|
-
import {provideHttpClient, withInterceptors} from "@angular/common/http";
|
|
19
|
-
import { DatePickerComponent } from './component/date-picker/date-picker.component';
|
|
20
|
-
import { CheckboxComponent } from './component/checkbox/checkbox.component';
|
|
21
|
-
import { RadioComponent } from './component/radio/radio.component';
|
|
22
|
-
import { AutoCompleteComponent } from './component/auto-complete/auto-complete.component';
|
|
23
|
-
import { ButtonToggleComponent } from './component/button-toggle/button-toggle.component';
|
|
24
|
-
import { ChipComponent } from './component/chips/chip.component';
|
|
25
|
-
import { SliderComponent } from './component/slider/slider.component';
|
|
26
|
-
import { SlideToggleComponent } from './component/slide-toggle/slide-toggle.component';
|
|
27
|
-
import { ButtonComponent } from './component/button/button.component';
|
|
28
|
-
import { DialogComponent } from './component/dialog/dialog.component';
|
|
29
|
-
import { SnackBarComponent } from './component/snack-bar/snack-bar.component';
|
|
30
|
-
import { BottomSheetComponent } from './component/bottom-sheet/bottom-sheet.component';
|
|
31
|
-
import { ProgressBarComponent } from './component/progress-bar/progress-bar.component';
|
|
32
|
-
import { ProgressSpinnerComponent } from './component/progress-spinner/progress-spinner.component';
|
|
33
|
-
import { TableComponent } from './component/table/table.component';
|
|
34
|
-
import { PaginationComponent } from './component/pagination/pagination.component';
|
|
35
|
-
import { RichTextEditorComponent } from './component/rich-text-editor/rich-text-editor.component';
|
|
36
|
-
import {AngularEditorModule} from "@kolkov/angular-editor";
|
|
37
|
-
|
|
38
|
-
@NgModule({
|
|
39
|
-
declarations: [
|
|
40
|
-
TextboxComponent,
|
|
41
|
-
TextareaComponent,
|
|
42
|
-
SelectComponent,
|
|
43
|
-
ReactiveFieldDirective,
|
|
44
|
-
ControlBuilderComponent,
|
|
45
|
-
DatePickerComponent,
|
|
46
|
-
CheckboxComponent,
|
|
47
|
-
RadioComponent,
|
|
48
|
-
AutoCompleteComponent,
|
|
49
|
-
ButtonToggleComponent,
|
|
50
|
-
ChipComponent,
|
|
51
|
-
SliderComponent,
|
|
52
|
-
SlideToggleComponent,
|
|
53
|
-
ButtonComponent,
|
|
54
|
-
DialogComponent,
|
|
55
|
-
SnackBarComponent,
|
|
56
|
-
BottomSheetComponent,
|
|
57
|
-
ProgressBarComponent,
|
|
58
|
-
ProgressSpinnerComponent,
|
|
59
|
-
TableComponent,
|
|
60
|
-
PaginationComponent,
|
|
61
|
-
RichTextEditorComponent
|
|
62
|
-
],
|
|
63
|
-
imports: [
|
|
64
|
-
AngularmaterialModule,
|
|
65
|
-
CommonModule,
|
|
66
|
-
FormsModule,
|
|
67
|
-
ReactiveFormsModule,
|
|
68
|
-
RouterModule,
|
|
69
|
-
AngularEditorModule,
|
|
70
|
-
],
|
|
71
|
-
exports: [
|
|
72
|
-
AngularmaterialModule,
|
|
73
|
-
CommonModule,
|
|
74
|
-
FormsModule,
|
|
75
|
-
ReactiveFormsModule,
|
|
76
|
-
ControlBuilderComponent,
|
|
77
|
-
RouterModule,
|
|
78
|
-
ProgressBarComponent,
|
|
79
|
-
ProgressSpinnerComponent,
|
|
80
|
-
ChipComponent,
|
|
81
|
-
PaginationComponent,
|
|
82
|
-
TableComponent,
|
|
83
|
-
AngularEditorModule,
|
|
84
|
-
ButtonComponent,
|
|
85
|
-
],
|
|
86
|
-
providers: [
|
|
87
|
-
provideHttpClient(
|
|
88
|
-
withInterceptors([
|
|
89
|
-
(req, next) => {
|
|
90
|
-
// Get the auth token from the service.
|
|
91
|
-
const authToken = inject(AuthService).getAuthorizationHeaderValue();
|
|
92
|
-
inject(LoggerService).info("Auth bearer token ", authToken);
|
|
93
|
-
if (authToken) {
|
|
94
|
-
req = req.clone({
|
|
95
|
-
setHeaders: {
|
|
96
|
-
'Content-Type': 'application/json',
|
|
97
|
-
Authorization: authToken
|
|
98
|
-
}
|
|
99
|
-
});
|
|
100
|
-
}
|
|
101
|
-
return next(req);
|
|
102
|
-
},
|
|
103
|
-
])
|
|
104
|
-
),
|
|
105
|
-
{provide: IGenericHttpClient, useClass: GenericHttpClient},
|
|
106
|
-
{
|
|
107
|
-
provide: APP_INITIALIZER,
|
|
108
|
-
useFactory: appSettingsFactory,
|
|
109
|
-
deps: [AppSettingService],
|
|
110
|
-
multi: true,
|
|
111
|
-
},
|
|
112
|
-
{
|
|
113
|
-
provide: APP_INITIALIZER,
|
|
114
|
-
useFactory: authServiceFactory,
|
|
115
|
-
deps: [AuthService, AppSettingService, EnvironmentViewModel],
|
|
116
|
-
multi: true,
|
|
117
|
-
},
|
|
118
|
-
{
|
|
119
|
-
provide: APP_INITIALIZER,
|
|
120
|
-
useFactory: loggerServiceFactory,
|
|
121
|
-
deps: [LoggerService, AppSettingService],
|
|
122
|
-
multi: true,
|
|
123
|
-
},
|
|
124
|
-
{
|
|
125
|
-
provide: MAT_SNACK_BAR_DEFAULT_OPTIONS,
|
|
126
|
-
useValue: {duration: 5000},
|
|
127
|
-
},
|
|
128
|
-
],
|
|
129
|
-
})
|
|
130
|
-
export class FalconCoreModule {
|
|
131
|
-
public static forRoot(
|
|
132
|
-
environment: any,
|
|
133
|
-
): ModuleWithProviders<FalconCoreModule> {
|
|
134
|
-
return {
|
|
135
|
-
ngModule: FalconCoreModule,
|
|
136
|
-
providers: [
|
|
137
|
-
{provide: EnvironmentViewModel, useValue: environment},
|
|
138
|
-
],
|
|
139
|
-
};
|
|
140
|
-
}
|
|
141
|
-
}
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import { TextboxComponent } from '../component/textbox/textbox.component';
|
|
2
|
-
import { TextareaComponent } from '../component/textarea/textarea.component';
|
|
3
|
-
import { SelectComponent } from '../component/select/select.component';
|
|
4
|
-
import { DatePickerComponent } from '../component/date-picker/date-picker.component';
|
|
5
|
-
import { RadioComponent } from '../component/radio/radio.component';
|
|
6
|
-
import { CheckboxComponent } from '../component/checkbox/checkbox.component';
|
|
7
|
-
import { SlideToggleComponent } from '../component/slide-toggle/slide-toggle.component';
|
|
8
|
-
import { SliderComponent } from '../component/slider/slider.component';
|
|
9
|
-
import { ButtonToggleComponent } from '../component/button-toggle/button-toggle.component';
|
|
10
|
-
import { AutoCompleteComponent } from '../component/auto-complete/auto-complete.component';
|
|
11
|
-
import { ChipComponent } from '../component/chips/chip.component';
|
|
12
|
-
import {ButtonComponent} from "../component/button/button.component";
|
|
13
|
-
import {RichTextEditorComponent} from "../component/rich-text-editor/rich-text-editor.component";
|
|
14
|
-
|
|
15
|
-
export class Constant {
|
|
16
|
-
public static ComponentMapper = [
|
|
17
|
-
TextboxComponent,
|
|
18
|
-
TextareaComponent,
|
|
19
|
-
SelectComponent,
|
|
20
|
-
DatePickerComponent,
|
|
21
|
-
RadioComponent,
|
|
22
|
-
CheckboxComponent,
|
|
23
|
-
ButtonComponent,
|
|
24
|
-
SlideToggleComponent,
|
|
25
|
-
SliderComponent,
|
|
26
|
-
ButtonToggleComponent,
|
|
27
|
-
AutoCompleteComponent,
|
|
28
|
-
ChipComponent,
|
|
29
|
-
RichTextEditorComponent,
|
|
30
|
-
//DividerComponent,
|
|
31
|
-
];
|
|
32
|
-
}
|
package/src/lib/model/enum.ts
DELETED
|
@@ -1,151 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @description
|
|
3
|
-
* Enum use for setting the form control Types.
|
|
4
|
-
* @usageNotes
|
|
5
|
-
* ```ts
|
|
6
|
-
* export class Textbox extends BaseControl<string>{
|
|
7
|
-
* override controlType = ControlType.Select;
|
|
8
|
-
* }
|
|
9
|
-
* ```
|
|
10
|
-
*/
|
|
11
|
-
export const enum ControlType {
|
|
12
|
-
TextBox = 0,
|
|
13
|
-
TextArea = 1,
|
|
14
|
-
Select = 2,
|
|
15
|
-
DatePicker = 3,
|
|
16
|
-
Radio = 4,
|
|
17
|
-
Checkbox = 5,
|
|
18
|
-
Button = 6,
|
|
19
|
-
SlideToggle = 7,
|
|
20
|
-
Slider = 8,
|
|
21
|
-
ButtonToggle = 9,
|
|
22
|
-
AutoComplete = 10,
|
|
23
|
-
Chip = 11,
|
|
24
|
-
Editor = 12,
|
|
25
|
-
Divider = 13,
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
/**
|
|
29
|
-
* @description
|
|
30
|
-
* Enum use for Appearance of the control.
|
|
31
|
-
* @usageNotes
|
|
32
|
-
* Before and After property should be only use for Checkbox and Radio button
|
|
33
|
-
* ```ts
|
|
34
|
-
* if (componentType == ComponentType.Radio && componentType == ComponentType.Checkbox) THEN
|
|
35
|
-
* only use Appearance Before and After
|
|
36
|
-
* ```
|
|
37
|
-
*/
|
|
38
|
-
export const enum Appearance {
|
|
39
|
-
/**
|
|
40
|
-
* @usageNotes Should be only use for input, textbox, and select
|
|
41
|
-
*/
|
|
42
|
-
Plain = 'plain',
|
|
43
|
-
Legacy = 'legacy',
|
|
44
|
-
Standard = 'standard',
|
|
45
|
-
Fill = 'fill',
|
|
46
|
-
Outline = 'outline',
|
|
47
|
-
/**
|
|
48
|
-
* @usageNotes Should be only use for label position
|
|
49
|
-
*/
|
|
50
|
-
Before = 'before',
|
|
51
|
-
After = 'after',
|
|
52
|
-
/**
|
|
53
|
-
* @usageNotes Should be only use for select
|
|
54
|
-
*/
|
|
55
|
-
Multiple = 'true',
|
|
56
|
-
|
|
57
|
-
/**
|
|
58
|
-
* @usageNotes Should be only use for Buttom
|
|
59
|
-
*/
|
|
60
|
-
Basic = 0,
|
|
61
|
-
Raised = 1,
|
|
62
|
-
Stroked = 2,
|
|
63
|
-
Flat = 3,
|
|
64
|
-
Icon = 4,
|
|
65
|
-
FAB = 5,
|
|
66
|
-
MiniFAB = 6,
|
|
67
|
-
routeLink = 7,
|
|
68
|
-
routeHref = 8,
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
/**
|
|
72
|
-
* @description
|
|
73
|
-
* Enum use for setting the attribute Types.
|
|
74
|
-
* @usageNotes
|
|
75
|
-
* ```ts
|
|
76
|
-
* componentProperty: {
|
|
77
|
-
* attrType: InputTypes.Text
|
|
78
|
-
* }
|
|
79
|
-
* ```
|
|
80
|
-
*/
|
|
81
|
-
export const enum InputTypes {
|
|
82
|
-
Color = 'color',
|
|
83
|
-
Date = 'date',
|
|
84
|
-
DatetimeLocal = 'datetime-local',
|
|
85
|
-
Email = 'email',
|
|
86
|
-
Month = 'month',
|
|
87
|
-
Number = 'number',
|
|
88
|
-
Password = 'password',
|
|
89
|
-
Search = 'search',
|
|
90
|
-
Tel = 'tel',
|
|
91
|
-
Text = 'text',
|
|
92
|
-
Time = 'time',
|
|
93
|
-
Url = 'url',
|
|
94
|
-
Week = 'week',
|
|
95
|
-
/**
|
|
96
|
-
* @usageNotes Should be only use for Buttom
|
|
97
|
-
*/
|
|
98
|
-
Button = 'button',
|
|
99
|
-
Submit = 'submit',
|
|
100
|
-
DragDrop = 'dragDrop',
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
/**
|
|
104
|
-
* @description
|
|
105
|
-
* Enum use for setting HTTP method.
|
|
106
|
-
* @usageNotes
|
|
107
|
-
* ```ts
|
|
108
|
-
* this.genericHttpClientService.Delete(this.deleteUserUrl).subscribe(item => {}, error => {});
|
|
109
|
-
* ```
|
|
110
|
-
*/
|
|
111
|
-
export const enum HttpMethod {
|
|
112
|
-
Get = 'GET',
|
|
113
|
-
Post = 'POST',
|
|
114
|
-
Put = 'PUT',
|
|
115
|
-
Patch = 'PATCH',
|
|
116
|
-
Delete = 'DELETE',
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
/**
|
|
120
|
-
* @description
|
|
121
|
-
* Enum use for Table actions
|
|
122
|
-
*/
|
|
123
|
-
export const enum TableAction {
|
|
124
|
-
View,
|
|
125
|
-
Edit,
|
|
126
|
-
Delete,
|
|
127
|
-
RightArrow,
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
/**
|
|
131
|
-
* @description
|
|
132
|
-
* Enum use for setting the Floating label.
|
|
133
|
-
* @usageNotes
|
|
134
|
-
* ```ts
|
|
135
|
-
* componentProperty: {
|
|
136
|
-
* floatLabel: Floatinglabel.Always
|
|
137
|
-
* }
|
|
138
|
-
* ```
|
|
139
|
-
*/
|
|
140
|
-
export const enum Floatinglabel {
|
|
141
|
-
Auto = 'auto',
|
|
142
|
-
Always = 'always',
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
export const enum LoggingLevel {
|
|
146
|
-
None = 'None',
|
|
147
|
-
Verbose = 'Verbose',
|
|
148
|
-
Info = 'Info',
|
|
149
|
-
Warnings = 'Warnings',
|
|
150
|
-
Errors = 'Errors'
|
|
151
|
-
}
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
import { NgModule } from '@angular/core';
|
|
2
|
-
import { CommonModule } from '@angular/common';
|
|
3
|
-
import {ScrollingModule} from "@angular/cdk/scrolling";
|
|
4
|
-
import {PortalModule} from "@angular/cdk/portal";
|
|
5
|
-
import {OverlayModule} from "@angular/cdk/overlay";
|
|
6
|
-
import {MatTreeModule} from "@angular/material/tree";
|
|
7
|
-
import {MatTooltipModule} from "@angular/material/tooltip";
|
|
8
|
-
import {MatToolbarModule} from "@angular/material/toolbar";
|
|
9
|
-
import {MatTabsModule} from "@angular/material/tabs";
|
|
10
|
-
import {MatTableModule} from "@angular/material/table";
|
|
11
|
-
import {MatSortModule} from "@angular/material/sort";
|
|
12
|
-
import {MatSnackBarModule} from "@angular/material/snack-bar";
|
|
13
|
-
import {MatSlideToggleModule} from "@angular/material/slide-toggle";
|
|
14
|
-
import {MatSliderModule} from "@angular/material/slider";
|
|
15
|
-
import {MatSidenavModule} from "@angular/material/sidenav";
|
|
16
|
-
import {MatSelectModule} from "@angular/material/select";
|
|
17
|
-
import {MatNativeDateModule, MatRippleModule} from "@angular/material/core";
|
|
18
|
-
import {MatRadioModule} from "@angular/material/radio";
|
|
19
|
-
import {MatProgressSpinnerModule} from "@angular/material/progress-spinner";
|
|
20
|
-
import {MatProgressBarModule} from "@angular/material/progress-bar";
|
|
21
|
-
import {MatPaginatorModule} from "@angular/material/paginator";
|
|
22
|
-
import {MatMenuModule} from "@angular/material/menu";
|
|
23
|
-
import {MatListModule} from "@angular/material/list";
|
|
24
|
-
import {MatInputModule} from "@angular/material/input";
|
|
25
|
-
import {MatIconModule} from "@angular/material/icon";
|
|
26
|
-
import {MatGridListModule} from "@angular/material/grid-list";
|
|
27
|
-
import {MatExpansionModule} from "@angular/material/expansion";
|
|
28
|
-
import {MatDividerModule} from "@angular/material/divider";
|
|
29
|
-
import {MatDialogModule} from "@angular/material/dialog";
|
|
30
|
-
import {MatDatepickerModule} from "@angular/material/datepicker";
|
|
31
|
-
import {MatStepperModule} from "@angular/material/stepper";
|
|
32
|
-
import {MatChipsModule} from "@angular/material/chips";
|
|
33
|
-
import {MatCheckboxModule} from "@angular/material/checkbox";
|
|
34
|
-
import {MatCardModule} from "@angular/material/card";
|
|
35
|
-
import {MatButtonToggleModule} from "@angular/material/button-toggle";
|
|
36
|
-
import {MatButtonModule} from "@angular/material/button";
|
|
37
|
-
import {MatBottomSheetModule} from "@angular/material/bottom-sheet";
|
|
38
|
-
import {MatBadgeModule} from "@angular/material/badge";
|
|
39
|
-
import {MatAutocompleteModule} from "@angular/material/autocomplete";
|
|
40
|
-
import {DragDropModule} from "@angular/cdk/drag-drop";
|
|
41
|
-
import {CdkTreeModule} from "@angular/cdk/tree";
|
|
42
|
-
import {CdkTableModule} from "@angular/cdk/table";
|
|
43
|
-
import {CdkStepperModule} from "@angular/cdk/stepper";
|
|
44
|
-
import {ClipboardModule} from "@angular/cdk/clipboard";
|
|
45
|
-
import {A11yModule} from "@angular/cdk/a11y";
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
@NgModule({
|
|
50
|
-
declarations: [],
|
|
51
|
-
exports: [
|
|
52
|
-
A11yModule,
|
|
53
|
-
ClipboardModule,
|
|
54
|
-
CdkStepperModule,
|
|
55
|
-
CdkTableModule,
|
|
56
|
-
CdkTreeModule,
|
|
57
|
-
DragDropModule,
|
|
58
|
-
MatAutocompleteModule,
|
|
59
|
-
MatBadgeModule,
|
|
60
|
-
MatBottomSheetModule,
|
|
61
|
-
MatButtonModule,
|
|
62
|
-
MatButtonToggleModule,
|
|
63
|
-
MatCardModule,
|
|
64
|
-
MatCheckboxModule,
|
|
65
|
-
MatChipsModule,
|
|
66
|
-
MatStepperModule,
|
|
67
|
-
MatDatepickerModule,
|
|
68
|
-
MatDialogModule,
|
|
69
|
-
MatDividerModule,
|
|
70
|
-
MatExpansionModule,
|
|
71
|
-
MatGridListModule,
|
|
72
|
-
MatIconModule,
|
|
73
|
-
MatInputModule,
|
|
74
|
-
MatListModule,
|
|
75
|
-
MatMenuModule,
|
|
76
|
-
MatNativeDateModule,
|
|
77
|
-
MatPaginatorModule,
|
|
78
|
-
MatProgressBarModule,
|
|
79
|
-
MatProgressSpinnerModule,
|
|
80
|
-
MatRadioModule,
|
|
81
|
-
MatRippleModule,
|
|
82
|
-
MatSelectModule,
|
|
83
|
-
MatSidenavModule,
|
|
84
|
-
MatSliderModule,
|
|
85
|
-
MatSlideToggleModule,
|
|
86
|
-
MatSnackBarModule,
|
|
87
|
-
MatSortModule,
|
|
88
|
-
MatTableModule,
|
|
89
|
-
MatTabsModule,
|
|
90
|
-
MatToolbarModule,
|
|
91
|
-
MatTooltipModule,
|
|
92
|
-
MatTreeModule,
|
|
93
|
-
OverlayModule,
|
|
94
|
-
PortalModule,
|
|
95
|
-
ScrollingModule
|
|
96
|
-
]
|
|
97
|
-
})
|
|
98
|
-
export class AngularmaterialModule { }
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import {ComponentRef, Directive, Input, OnInit, ViewContainerRef} from '@angular/core';
|
|
2
|
-
import {BaseControl} from "./base-control";
|
|
3
|
-
import {FormGroup} from "@angular/forms";
|
|
4
|
-
import {Constant} from "./model/constant";
|
|
5
|
-
|
|
6
|
-
@Directive({
|
|
7
|
-
selector: '[reactiveField]'
|
|
8
|
-
})
|
|
9
|
-
export class ReactiveFieldDirective implements OnInit {
|
|
10
|
-
@Input() control!: BaseControl<string>;
|
|
11
|
-
@Input() formGroup!: FormGroup;
|
|
12
|
-
private componentRef!: ComponentRef<any>;
|
|
13
|
-
constructor(private viewContainerRef: ViewContainerRef) {
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
ngOnInit(): void {
|
|
17
|
-
if (this.control !== undefined) {
|
|
18
|
-
this.componentRef = this.viewContainerRef.createComponent(Constant.ComponentMapper[this.control.controlType]);
|
|
19
|
-
this.componentRef.instance.control = this.control;
|
|
20
|
-
this.componentRef.instance.formGroup = this.formGroup;
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
}
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
import {Injectable} from '@angular/core';
|
|
2
|
-
import {HttpClient} from '@angular/common/http';
|
|
3
|
-
import {Subject, Observable, from} from 'rxjs';
|
|
4
|
-
import {LoggerService} from './logger.service';
|
|
5
|
-
|
|
6
|
-
@Injectable({
|
|
7
|
-
providedIn: 'root'
|
|
8
|
-
})
|
|
9
|
-
export class AppSettingService {
|
|
10
|
-
static APP_SETTINGS_LOADED = "APP_SETTINGS_LOADED";
|
|
11
|
-
private listeners: any;
|
|
12
|
-
initialized: boolean = false;
|
|
13
|
-
private eventsSubject: Subject<any>;
|
|
14
|
-
public isServiceReady: Subject<boolean> = new Subject<boolean>();
|
|
15
|
-
private events: Observable<any>;
|
|
16
|
-
private appSettings: any;
|
|
17
|
-
|
|
18
|
-
constructor(private http: HttpClient, private logger: LoggerService) {
|
|
19
|
-
this.listeners = {};
|
|
20
|
-
this.eventsSubject = new Subject<any>();
|
|
21
|
-
|
|
22
|
-
this.events = from(this.eventsSubject);
|
|
23
|
-
this.events.subscribe(
|
|
24
|
-
({name, args}) => {
|
|
25
|
-
if (this.listeners[name]) {
|
|
26
|
-
for (let listener of this.listeners[name]) {
|
|
27
|
-
listener(...args);
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
});
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
async load() {
|
|
34
|
-
if (this.initialized) return;
|
|
35
|
-
let data = await this.http.get('assets/appsetting.json').toPromise();
|
|
36
|
-
this.appSettings = data;
|
|
37
|
-
this.initialized = true;
|
|
38
|
-
this.isServiceReady.next(this.initialized);
|
|
39
|
-
this.logger.info("[AppSettingService] load --> isServiceReady", this.initialized);
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
on(name: any, listener: any) {
|
|
43
|
-
if (!this.listeners[name]) {
|
|
44
|
-
this.listeners[name] = [];
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
this.listeners[name].push(listener);
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
public getAppsettingValue<T>(): T | null {
|
|
51
|
-
return this.appSettings ? <T>this.appSettings : null;
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
export function appSettingsFactory(appSettings: AppSettingService) {
|
|
56
|
-
return async () => await appSettings.load();
|
|
57
|
-
};
|