bpm-core 0.0.52 → 0.0.54
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/esm2022/lib/app/app.component.mjs +20 -9
- package/esm2022/lib/components/app-component-sections/activities/activities.component.mjs +6 -3
- package/esm2022/lib/components/app-component-sections/approvals/approvals.component.mjs +3 -6
- package/esm2022/lib/components/app-component-sections/approvals-workflow/approvals-workflow.component.mjs +69 -56
- package/esm2022/lib/components/app-component-sections/faqs/faqs.component.mjs +1 -1
- package/esm2022/lib/components/app-component-sections/feedback-section/feedback-section.component.mjs +5 -6
- package/esm2022/lib/components/app-component-sections/previous-requests/previous-requests.component.mjs +3 -5
- package/esm2022/lib/components/app-component-sections/service-header/service-header.component.mjs +7 -5
- package/esm2022/lib/components/shared-components/action-buttons/action-buttons.component.mjs +4 -6
- package/esm2022/lib/components/shared-components/dialogs/delete-dialog/delete-dialog.component.mjs +5 -4
- package/esm2022/lib/components/shared-components/form-field/add-attachment-section/add-attachment-section.component.mjs +76 -51
- package/esm2022/lib/components/shared-components/form-field/attachment-section/attachment-section.component.mjs +153 -110
- package/esm2022/lib/components/shared-components/form-field/checkbox/checkbox.component.mjs +9 -9
- package/esm2022/lib/components/shared-components/form-field/control-value-accessor.directive.mjs +31 -8
- package/esm2022/lib/components/shared-components/form-field/custom-searchable-autocomplete/custom-searchable.component.mjs +15 -18
- package/esm2022/lib/components/shared-components/form-field/date-picker/date-picker.component.mjs +15 -18
- package/esm2022/lib/components/shared-components/form-field/date-range-picker/date-range-picker.component.mjs +12 -14
- package/esm2022/lib/components/shared-components/form-field/doc-uploader/docs-uploader.component.mjs +141 -212
- package/esm2022/lib/components/shared-components/form-field/form-label/form-label.component.mjs +9 -9
- package/esm2022/lib/components/shared-components/form-field/index.mjs +2 -1
- package/esm2022/lib/components/shared-components/form-field/info-item/info-item.component.mjs +3 -3
- package/esm2022/lib/components/shared-components/form-field/input/input.component.mjs +19 -33
- package/esm2022/lib/components/shared-components/form-field/input-currency/input-currency.component.mjs +16 -26
- package/esm2022/lib/components/shared-components/form-field/input-email/input-email.component.mjs +16 -27
- package/esm2022/lib/components/shared-components/form-field/input-mask/input-mask.component.mjs +16 -12
- package/esm2022/lib/components/shared-components/form-field/input-number/input-number.component.mjs +16 -24
- package/esm2022/lib/components/shared-components/form-field/input-telephone/input-telephone.component.mjs +11 -12
- package/esm2022/lib/components/shared-components/form-field/radio/radio.component.mjs +10 -10
- package/esm2022/lib/components/shared-components/form-field/search-employee/search-employee.component.mjs +43 -108
- package/esm2022/lib/components/shared-components/form-field/select/select.component.mjs +2 -2
- package/esm2022/lib/components/shared-components/form-field/shared-imports.mjs +19 -1
- package/esm2022/lib/components/shared-components/form-field/textarea/textarea.component.mjs +17 -29
- package/esm2022/lib/components/shared-components/form-field/toggle-button/toggle-button.component.mjs +11 -20
- package/esm2022/lib/components/shared-components/index.mjs +1 -3
- package/esm2022/lib/i18n/ar.mjs +5 -3
- package/esm2022/lib/i18n/en.mjs +5 -3
- package/esm2022/lib/services/core.service.ts.mjs +11 -1
- package/esm2022/lib/services/i18n.service.mjs +4 -4
- package/esm2022/lib/testComponent/general-approver-section/general-approver-section.component.mjs +2 -2
- package/esm2022/lib/testComponent/request-details-section/request-details-section.component.mjs +303 -35
- package/esm2022/lib/testComponent/services/i18n.service.mjs +3 -3
- package/fesm2022/bpm-core.mjs +1230 -1103
- package/fesm2022/bpm-core.mjs.map +1 -1
- package/lib/app/app.component.d.ts +5 -2
- package/lib/components/app-component-sections/activities/activities.component.d.ts +2 -0
- package/lib/components/app-component-sections/approvals/approvals.component.d.ts +1 -1
- package/lib/components/app-component-sections/approvals-workflow/approvals-workflow.component.d.ts +19 -5
- package/lib/components/app-component-sections/feedback-section/feedback-section.component.d.ts +1 -1
- package/lib/components/app-component-sections/service-header/service-header.component.d.ts +2 -2
- package/lib/components/shared-components/action-buttons/action-buttons.component.d.ts +2 -3
- package/lib/components/shared-components/form-field/add-attachment-section/add-attachment-section.component.d.ts +12 -3
- package/lib/components/shared-components/form-field/attachment-section/attachment-section.component.d.ts +23 -12
- package/lib/components/shared-components/form-field/control-value-accessor.directive.d.ts +7 -3
- package/lib/components/shared-components/form-field/date-picker/date-picker.component.d.ts +1 -2
- package/lib/components/shared-components/form-field/doc-uploader/docs-uploader.component.d.ts +14 -14
- package/lib/components/shared-components/form-field/form-label/form-label.component.d.ts +2 -3
- package/lib/components/shared-components/form-field/index.d.ts +1 -0
- package/lib/components/shared-components/form-field/info-item/info-item.component.d.ts +1 -1
- package/lib/components/shared-components/form-field/input/input.component.d.ts +1 -2
- package/lib/components/shared-components/form-field/input-currency/input-currency.component.d.ts +1 -2
- package/lib/components/shared-components/form-field/input-email/input-email.component.d.ts +1 -2
- package/lib/components/shared-components/form-field/input-mask/input-mask.component.d.ts +1 -2
- package/lib/components/shared-components/form-field/input-number/input-number.component.d.ts +1 -2
- package/lib/components/shared-components/form-field/search-employee/search-employee.component.d.ts +2 -10
- package/lib/components/shared-components/form-field/shared-imports.d.ts +11 -2
- package/lib/components/shared-components/form-field/textarea/textarea.component.d.ts +0 -3
- package/lib/components/shared-components/form-field/toggle-button/toggle-button.component.d.ts +1 -3
- package/lib/components/shared-components/index.d.ts +0 -2
- package/lib/i18n/ar.d.ts +3 -1
- package/lib/i18n/en.d.ts +3 -1
- package/lib/services/core.service.ts.d.ts +1 -0
- package/lib/testComponent/request-details-section/request-details-section.component.d.ts +40 -2
- package/package.json +1 -1
- package/src/lib/assets/images/user.svg +6 -0
- package/src/lib/assets/scss/_general.scss +4 -1
- package/src/lib/assets/scss/_upgrade.scss +4 -2
- package/esm2022/lib/components/shared-components/confirmation-popup/confirmation-popup.component.mjs +0 -39
- package/esm2022/lib/components/shared-components/delete-popup/delete-popup.component.mjs +0 -19
- package/esm2022/lib/components/shared-components/doc-uploader/docs-uploader.component.mjs +0 -686
- package/esm2022/lib/environments/environment.local.mjs +0 -27
- package/lib/components/shared-components/confirmation-popup/confirmation-popup.component.d.ts +0 -25
- package/lib/components/shared-components/delete-popup/delete-popup.component.d.ts +0 -6
- package/lib/components/shared-components/doc-uploader/docs-uploader.component.d.ts +0 -144
- package/lib/environments/environment.local.d.ts +0 -26
package/esm2022/lib/components/shared-components/form-field/input-email/input-email.component.mjs
CHANGED
|
@@ -1,20 +1,16 @@
|
|
|
1
|
-
|
|
2
|
-
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
3
|
-
/* eslint-disable @angular-eslint/component-selector */
|
|
4
|
-
import { NG_VALUE_ACCESSOR, ReactiveFormsModule } from '@angular/forms';
|
|
1
|
+
import { NG_VALUE_ACCESSOR } from '@angular/forms';
|
|
5
2
|
import { Component, CUSTOM_ELEMENTS_SCHEMA, forwardRef, Input } from '@angular/core';
|
|
6
|
-
import { MatFormField } from '@angular/material/form-field';
|
|
7
|
-
import { NgClass } from "@angular/common";
|
|
8
|
-
import { InfoItemComponent } from "../info-item/info-item.component";
|
|
9
|
-
import { SatPopoverModule } from "@ncstate/sat-popover";
|
|
10
3
|
import { ControlValueAccessorDirective } from '../control-value-accessor.directive';
|
|
11
|
-
import {
|
|
12
|
-
import { MatInput } from '@angular/material/input';
|
|
4
|
+
import { MatFormImports, Shareds } from '../shared-imports';
|
|
13
5
|
import * as i0 from "@angular/core";
|
|
14
|
-
import * as i1 from "
|
|
15
|
-
import * as i2 from "
|
|
6
|
+
import * as i1 from "../form-label/form-label.component";
|
|
7
|
+
import * as i2 from "../validation-errors/validation-errors.component";
|
|
8
|
+
import * as i3 from "../info-item/info-item.component";
|
|
9
|
+
import * as i4 from "@angular/forms";
|
|
10
|
+
import * as i5 from "@angular/common";
|
|
11
|
+
import * as i6 from "@angular/material/form-field";
|
|
12
|
+
import * as i7 from "@angular/material/input";
|
|
16
13
|
export class InputEmailComponent extends ControlValueAccessorDirective {
|
|
17
|
-
tooltip;
|
|
18
14
|
floatLabel = 'auto';
|
|
19
15
|
className = 'bordered-input';
|
|
20
16
|
matPrefix;
|
|
@@ -25,34 +21,27 @@ export class InputEmailComponent extends ControlValueAccessorDirective {
|
|
|
25
21
|
console.log(this.control.errors);
|
|
26
22
|
}
|
|
27
23
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputEmailComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
28
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: InputEmailComponent, isStandalone: true, selector: "app-input-email", inputs: {
|
|
24
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: InputEmailComponent, isStandalone: true, selector: "app-input-email", inputs: { floatLabel: "floatLabel", className: "className", matPrefix: "matPrefix", iconPrefixName: "iconPrefixName", iconSuffixName: "iconSuffixName", numberSuffixName: "numberSuffixName" }, providers: [
|
|
29
25
|
{
|
|
30
26
|
provide: NG_VALUE_ACCESSOR,
|
|
31
27
|
useExisting: forwardRef(() => InputEmailComponent),
|
|
32
28
|
multi: true,
|
|
33
29
|
},
|
|
34
|
-
], usesInheritance: true, ngImport: i0, template: "@if(!isReadOnly){\r\n @if(label){\r\n
|
|
30
|
+
], usesInheritance: true, ngImport: i0, template: "@if(!isReadOnly){\r\n @if(label){\r\n <app-form-label [label]=\"label\" [optional]=\"!required\" [tooltip]=\"tooltip\"></app-form-label>\r\n }\r\n <mat-form-field\r\n class=\"primary-form {{ className }}\"\r\n [ngClass]=\"{ 'input-disabled': control.disabled }\"\r\n [floatLabel]=\"floatLabel\"\r\n >\r\n @if(iconPrefixName){<span class=\"sfi {{ iconPrefixName }}\"></span>}\r\n @if(loading){<span\r\n class=\"sfi sfi-spinner d-inline-block spin fc-coral\"\r\n matSuffix\r\n ></span\r\n >}\r\n <label class=\"mat-form-content\">\r\n <!-- add input for ar && en custom directive with add type = arOnly || type = enOnly-->\r\n <input\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [type]=\"type\"\r\n [placeholder]=\"placeholder\"\r\n (change)=\"displayErrors($event)\"\r\n />\r\n </label>\r\n @if(iconSuffixName){<span matSuffix class=\"sfi {{ iconSuffixName }}\"></span>}\r\n @if(hint){\r\n <mat-hint class=\"d-flex align-items-center gap-1 mt-1\">\r\n <span\r\n class=\"sfi sfi-info fs-17 fc-dark-gray\"\r\n [ngClass]=\"{ 'fc-oasis-light-imp': value }\"\r\n ></span>\r\n <span class=\"fs-12 fc-black line-height-1\">{{ hint }}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n } @if(isReadOnly && (showIfEmpty || control)){\r\n <ng-container class=\"info-section\">\r\n <app-info-item\r\n class=\"info-item w-100\"\r\n [label]=\"label\"\r\n [insideTable]=\"insideTable\"\r\n [hasLabel]=\"!!label\"\r\n [type]=\"type\"\r\n [value]=\"control.value\"\r\n ></app-info-item>\r\n </ng-container>\r\n }", styles: [":host{flex-grow:1}.input-disabled{pointer-events:none;opacity:1.5}\n"], dependencies: [{ kind: "component", type: i1.FormLabelComponent, selector: "app-form-label", inputs: ["tooltip", "label", "optional"] }, { kind: "component", type: i2.ValidationErrorsComponent, selector: "app-validation-errors", inputs: ["errors", "customErrorMessages"] }, { kind: "component", type: i3.InfoItemComponent, selector: "app-info-item", inputs: ["label", "value", "name", "type", "dateType", "multiple", "insideTable", "hasLabel", "arrayList", "actionType", "download"] }, { kind: "ngmodule", type: i4.ReactiveFormsModule }, { kind: "directive", type: i4.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: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i4.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i5.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: i6.MatFormFieldModule }, { kind: "component", type: i6.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i6.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: i6.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "directive", type: i7.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"] }] });
|
|
35
31
|
}
|
|
36
32
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputEmailComponent, decorators: [{
|
|
37
33
|
type: Component,
|
|
38
34
|
args: [{ selector: 'app-input-email', schemas: [CUSTOM_ELEMENTS_SCHEMA], standalone: true, imports: [
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
SatPopoverModule,
|
|
42
|
-
NgClass,
|
|
43
|
-
MatInput,
|
|
44
|
-
ReactiveFormsModule,
|
|
45
|
-
ValidationErrorsComponent
|
|
35
|
+
...Shareds,
|
|
36
|
+
...MatFormImports
|
|
46
37
|
], providers: [
|
|
47
38
|
{
|
|
48
39
|
provide: NG_VALUE_ACCESSOR,
|
|
49
40
|
useExisting: forwardRef(() => InputEmailComponent),
|
|
50
41
|
multi: true,
|
|
51
42
|
},
|
|
52
|
-
], template: "@if(!isReadOnly){\r\n @if(label){\r\n
|
|
53
|
-
}], propDecorators: {
|
|
54
|
-
type: Input
|
|
55
|
-
}], floatLabel: [{
|
|
43
|
+
], template: "@if(!isReadOnly){\r\n @if(label){\r\n <app-form-label [label]=\"label\" [optional]=\"!required\" [tooltip]=\"tooltip\"></app-form-label>\r\n }\r\n <mat-form-field\r\n class=\"primary-form {{ className }}\"\r\n [ngClass]=\"{ 'input-disabled': control.disabled }\"\r\n [floatLabel]=\"floatLabel\"\r\n >\r\n @if(iconPrefixName){<span class=\"sfi {{ iconPrefixName }}\"></span>}\r\n @if(loading){<span\r\n class=\"sfi sfi-spinner d-inline-block spin fc-coral\"\r\n matSuffix\r\n ></span\r\n >}\r\n <label class=\"mat-form-content\">\r\n <!-- add input for ar && en custom directive with add type = arOnly || type = enOnly-->\r\n <input\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [type]=\"type\"\r\n [placeholder]=\"placeholder\"\r\n (change)=\"displayErrors($event)\"\r\n />\r\n </label>\r\n @if(iconSuffixName){<span matSuffix class=\"sfi {{ iconSuffixName }}\"></span>}\r\n @if(hint){\r\n <mat-hint class=\"d-flex align-items-center gap-1 mt-1\">\r\n <span\r\n class=\"sfi sfi-info fs-17 fc-dark-gray\"\r\n [ngClass]=\"{ 'fc-oasis-light-imp': value }\"\r\n ></span>\r\n <span class=\"fs-12 fc-black line-height-1\">{{ hint }}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n } @if(isReadOnly && (showIfEmpty || control)){\r\n <ng-container class=\"info-section\">\r\n <app-info-item\r\n class=\"info-item w-100\"\r\n [label]=\"label\"\r\n [insideTable]=\"insideTable\"\r\n [hasLabel]=\"!!label\"\r\n [type]=\"type\"\r\n [value]=\"control.value\"\r\n ></app-info-item>\r\n </ng-container>\r\n }", styles: [":host{flex-grow:1}.input-disabled{pointer-events:none;opacity:1.5}\n"] }]
|
|
44
|
+
}], propDecorators: { floatLabel: [{
|
|
56
45
|
type: Input
|
|
57
46
|
}], className: [{
|
|
58
47
|
type: Input
|
|
@@ -65,4 +54,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
65
54
|
}], numberSuffixName: [{
|
|
66
55
|
type: Input
|
|
67
56
|
}] } });
|
|
68
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
57
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5wdXQtZW1haWwuY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvYnBtLWNvcmUvc3JjL2xpYi9jb21wb25lbnRzL3NoYXJlZC1jb21wb25lbnRzL2Zvcm0tZmllbGQvaW5wdXQtZW1haWwvaW5wdXQtZW1haWwuY29tcG9uZW50LnRzIiwiLi4vLi4vLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvYnBtLWNvcmUvc3JjL2xpYi9jb21wb25lbnRzL3NoYXJlZC1jb21wb25lbnRzL2Zvcm0tZmllbGQvaW5wdXQtZW1haWwvaW5wdXQtZW1haWwuY29tcG9uZW50Lmh0bWwiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFDLGlCQUFpQixFQUFDLE1BQU0sZ0JBQWdCLENBQUM7QUFDakQsT0FBTyxFQUFFLFNBQVMsRUFBRSxzQkFBc0IsRUFBRSxVQUFVLEVBQUUsS0FBSyxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBRXJGLE9BQU8sRUFBRSw2QkFBNkIsRUFBRSxNQUFNLHFDQUFxQyxDQUFDO0FBQ3BGLE9BQU8sRUFBRSxjQUFjLEVBQUUsT0FBTyxFQUFFLE1BQU0sbUJBQW1CLENBQUM7Ozs7Ozs7OztBQW9CNUQsTUFBTSxPQUFPLG1CQUEwQixTQUFRLDZCQUFtQztJQUN2RSxVQUFVLEdBQVEsTUFBTSxDQUFDO0lBQ3pCLFNBQVMsR0FBRyxnQkFBZ0IsQ0FBQztJQUM3QixTQUFTLENBQVc7SUFDcEIsY0FBYyxDQUFVO0lBQ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tYXQtaGludD5cclxuICAgIH1cclxuICA8L21hdC1mb3JtLWZpZWxkPlxyXG4gIDxhcHAtdmFsaWRhdGlvbi1lcnJvcnMgW2Vycm9yc109XCJjb250cm9sLmVycm9yc1wiPjwvYXBwLXZhbGlkYXRpb24tZXJyb3JzPlxyXG4gIH0gQGlmKGlzUmVhZE9ubHkgJiYgKHNob3dJZkVtcHR5IHx8IGNvbnRyb2wpKXtcclxuICA8bmctY29udGFpbmVyIGNsYXNzPVwiaW5mby1zZWN0aW9uXCI+XHJcbiAgICA8YXBwLWluZm8taXRlbVxyXG4gICAgICBjbGFzcz1cImluZm8taXRlbSB3LTEwMFwiXHJcbiAgICAgIFtsYWJlbF09XCJsYWJlbFwiXHJcbiAgICAgIFtpbnNpZGVUYWJsZV09XCJpbnNpZGVUYWJsZVwiXHJcbiAgICAgIFtoYXNMYWJlbF09XCIhIWxhYmVsXCJcclxuICAgICAgW3R5cGVdPVwidHlwZVwiXHJcbiAgICAgIFt2YWx1ZV09XCJjb250cm9sLnZhbHVlXCJcclxuICAgID48L2FwcC1pbmZvLWl0ZW0+XHJcbiAgPC9uZy1jb250YWluZXI+XHJcbiAgfSJdfQ==
|
package/esm2022/lib/components/shared-components/form-field/input-mask/input-mask.component.mjs
CHANGED
|
@@ -2,19 +2,18 @@
|
|
|
2
2
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
3
3
|
/* eslint-disable @angular-eslint/component-selector */
|
|
4
4
|
// import { Validators } from '@angular/forms';
|
|
5
|
-
import { Component, CUSTOM_ELEMENTS_SCHEMA, forwardRef, Input } from '@angular/core';
|
|
5
|
+
import { Component, CUSTOM_ELEMENTS_SCHEMA, forwardRef, Input, } from '@angular/core';
|
|
6
6
|
import { MatFormField } from '@angular/material/form-field';
|
|
7
7
|
import { SatPopoverModule } from '@ncstate/sat-popover';
|
|
8
|
-
import { NgxMaskDirective } from
|
|
9
|
-
import { NgClass
|
|
10
|
-
import { InfoItemComponent } from
|
|
11
|
-
import { NG_VALUE_ACCESSOR, ReactiveFormsModule } from
|
|
8
|
+
import { NgxMaskDirective } from 'ngx-mask';
|
|
9
|
+
import { NgClass } from '@angular/common';
|
|
10
|
+
import { InfoItemComponent } from '../info-item/info-item.component';
|
|
11
|
+
import { NG_VALUE_ACCESSOR, ReactiveFormsModule } from '@angular/forms';
|
|
12
12
|
import { ControlValueAccessorDirective } from '../control-value-accessor.directive';
|
|
13
13
|
import * as i0 from "@angular/core";
|
|
14
14
|
import * as i1 from "@ncstate/sat-popover";
|
|
15
15
|
import * as i2 from "@angular/forms";
|
|
16
16
|
export class InputMaskComponent extends ControlValueAccessorDirective {
|
|
17
|
-
tooltip;
|
|
18
17
|
floatLabel = 'auto';
|
|
19
18
|
className = 'bordered-input';
|
|
20
19
|
matPrefix;
|
|
@@ -22,7 +21,7 @@ export class InputMaskComponent extends ControlValueAccessorDirective {
|
|
|
22
21
|
iconSuffixName;
|
|
23
22
|
numberSuffixName;
|
|
24
23
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputMaskComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
25
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: InputMaskComponent, isStandalone: true, selector: "app-input-mask", inputs: {
|
|
24
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: InputMaskComponent, isStandalone: true, selector: "app-input-mask", inputs: { floatLabel: "floatLabel", className: "className", matPrefix: "matPrefix", iconPrefixName: "iconPrefixName", iconSuffixName: "iconSuffixName", numberSuffixName: "numberSuffixName" }, providers: [
|
|
26
25
|
{
|
|
27
26
|
provide: NG_VALUE_ACCESSOR,
|
|
28
27
|
useExisting: forwardRef(() => InputMaskComponent),
|
|
@@ -38,10 +37,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
38
37
|
useExisting: forwardRef(() => InputMaskComponent),
|
|
39
38
|
multi: true,
|
|
40
39
|
},
|
|
41
|
-
], imports: [
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
40
|
+
], imports: [
|
|
41
|
+
SatPopoverModule,
|
|
42
|
+
MatFormField,
|
|
43
|
+
NgxMaskDirective,
|
|
44
|
+
InfoItemComponent,
|
|
45
|
+
ReactiveFormsModule,
|
|
46
|
+
NgClass,
|
|
47
|
+
], template: "\r\n@if(!isReadOnly){\r\n <ng-container>\r\n <!-- <app-form-label [label]=\"label\" [optional]=\"!required\" [hideOption]=\"hideOption\" [showLabel]=\"showLabel\"></app-form-label> -->\r\n @if(label){\r\n <div class=\"d-flex justify-content-between mb-1\">\r\n <span class=\"form-label mb-0\">{{label}}</span>\r\n @if(!required){\r\n <span class=\"fs-11 fc-dark-gray\">{{i18n.translate('Optional')}}\r\n </span>\r\n }\r\n </div>\r\n }\r\n \r\n <mat-form-field class=\"primary-form {{className}}\" [ngClass]=\"{'input-disabled' : isDisabled }\"\r\n [floatLabel]=\"floatLabel\">\r\n \r\n @if(iconPrefixName){\r\n <span matPrefix class=\"sfi {{iconPrefixName}}\"></span>\r\n }\r\n <label class=\"mat-form-content\">\r\n <input matInput [placeholder]=\"placeholder\" [value]=\"value\" [attr.disabled]=\"isDisabled\" [mask]=\"mask\"\r\n [showMaskTyped]=\"false\" oninput=\"validity.valid || (value='');\" [formControl]=\"control\"\r\n [required]=\"required\" [placeholder]=\"placeholder\">\r\n </label>\r\n \r\n @if(matSuffix){\r\n <span matSuffix class=\"sfi {{iconSuffixName}}\"></span>\r\n }\r\n @if(type === 'number'){\r\n <div matSuffix class=\"d-flex align-items-center gap-2\">\r\n @if(numberSuffixName){\r\n <span class=\"fs-14 fw-medium\">{{numberSuffixName}}</span>\r\n }\r\n <!-- <span class=\"sfi sfi-minus p-2 bc-light-gray fc-black\"></span>\r\n <span class=\"sfi sfi-plus p-2 bc-light-gray fc-black\"></span> -->\r\n </div>\r\n }\r\n <!-- @if((!control?.valid)){\r\n <mat-error class=\"mb-2\">\r\n {{i18n.translate('validFieldError')}}{{label}}\r\n </mat-error>\r\n } -->\r\n \r\n \r\n <!-- <mat-error *ngIf=\"(type ==='email' && !control?.valid)\">\r\n {{i18n.translate('validEmailError')}}\r\n </mat-error> -->\r\n @if(showHint){\r\n <mat-hint>\r\n <span class=\"sfi sfi-check-circle font-10 fc-dark-gray\" [ngClass]=\"{'fc-oasis-light-imp':value}\"></span>\r\n <span class=\"mx-1\"></span>\r\n <span class=\"fs-12 fc-onyx\">{{hint}}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <!-- <span class=\"fc-coral\" style=\"color:#f44336\" *ngIf=\"( showErrorMessage && control.value)\">\r\n {{errorMessage}}\r\n </span> -->\r\n \r\n </ng-container>\r\n}\r\n\r\n@if(isReadOnly && control){\r\n <ng-container class=\"info-section\">\r\n <app-info-item class=\"info-item w-100\" [label]=\"label\" [insideTable]=\"insideTable\" [hasLabel]=\"label ? true: false\"\r\n [value]=\"control\"></app-info-item>\r\n </ng-container>\r\n \r\n}\r\n\r\n\r\n<!-- section tooltip -->\r\n<sat-popover #popover [hasBackdrop]=\"true\" verticalAlign=\"below\">\r\n <div class=\"deafult-tooltip\">\r\n {{tooltip}}\r\n </div>\r\n</sat-popover>\r\n", styles: [":host{flex-grow:1}\n"] }]
|
|
48
|
+
}], propDecorators: { floatLabel: [{
|
|
45
49
|
type: Input
|
|
46
50
|
}], className: [{
|
|
47
51
|
type: Input
|
|
@@ -54,4 +58,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
54
58
|
}], numberSuffixName: [{
|
|
55
59
|
type: Input
|
|
56
60
|
}] } });
|
|
57
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
61
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5wdXQtbWFzay5jb21wb25lbnQuanMiLCJzb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XHJcbiAgXHJcbn1cclxuXHJcblxyXG48IS0tIHNlY3Rpb24gdG9vbHRpcCAtLT5cclxuPHNhdC1wb3BvdmVyICNwb3BvdmVyIFtoYXNCYWNrZHJvcF09XCJ0cnVlXCIgdmVydGljYWxBbGlnbj1cImJlbG93XCI+XHJcbiAgPGRpdiBjbGFzcz1cImRlYWZ1bHQtdG9vbHRpcFwiPlxyXG4gICAge3t0b29sdGlwfX1cclxuICA8L2Rpdj5cclxuPC9zYXQtcG9wb3Zlcj5cclxuIl19
|
package/esm2022/lib/components/shared-components/form-field/input-number/input-number.component.mjs
CHANGED
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
/* eslint-disable @angular-eslint/use-lifecycle-interface */
|
|
2
2
|
/* eslint-disable @typescript-eslint/no-explicit-any */
|
|
3
3
|
/* eslint-disable @angular-eslint/component-selector */
|
|
4
|
-
import { NG_VALUE_ACCESSOR
|
|
4
|
+
import { NG_VALUE_ACCESSOR } from '@angular/forms';
|
|
5
5
|
import { Component, CUSTOM_ELEMENTS_SCHEMA, EventEmitter, forwardRef, Input, Output } from '@angular/core';
|
|
6
|
-
import { MatFormField } from '@angular/material/form-field';
|
|
7
|
-
import { NgClass } from "@angular/common";
|
|
8
|
-
import { InfoItemComponent } from "../info-item/info-item.component";
|
|
9
|
-
import { SatPopoverModule } from "@ncstate/sat-popover";
|
|
10
|
-
import { MatInput } from "@angular/material/input";
|
|
11
6
|
import { ControlValueAccessorDirective } from '../control-value-accessor.directive';
|
|
12
|
-
import { ValidationErrorsComponent } from '../validation-errors/validation-errors.component';
|
|
13
7
|
import { NumberDirective } from "../../../../directives/number.directive";
|
|
8
|
+
import { MatFormImports, Shareds } from '../shared-imports';
|
|
14
9
|
import * as i0 from "@angular/core";
|
|
15
|
-
import * as i1 from "
|
|
16
|
-
import * as i2 from "
|
|
10
|
+
import * as i1 from "../form-label/form-label.component";
|
|
11
|
+
import * as i2 from "../validation-errors/validation-errors.component";
|
|
12
|
+
import * as i3 from "../info-item/info-item.component";
|
|
13
|
+
import * as i4 from "@angular/forms";
|
|
14
|
+
import * as i5 from "@angular/common";
|
|
15
|
+
import * as i6 from "@angular/material/form-field";
|
|
16
|
+
import * as i7 from "@angular/material/input";
|
|
17
17
|
export class InputNumberComponent extends ControlValueAccessorDirective {
|
|
18
|
-
tooltip;
|
|
19
18
|
floatLabel = 'auto';
|
|
20
19
|
className = 'bordered-input';
|
|
21
20
|
iconPrefixName;
|
|
@@ -24,35 +23,28 @@ export class InputNumberComponent extends ControlValueAccessorDirective {
|
|
|
24
23
|
allowedPattern = '';
|
|
25
24
|
emitedChangedValue = new EventEmitter();
|
|
26
25
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputNumberComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
27
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: InputNumberComponent, isStandalone: true, selector: "app-input-number", inputs: {
|
|
26
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.8", type: InputNumberComponent, isStandalone: true, selector: "app-input-number", inputs: { floatLabel: "floatLabel", className: "className", iconPrefixName: "iconPrefixName", iconSuffixName: "iconSuffixName", numberSuffixName: "numberSuffixName", allowedPattern: "allowedPattern" }, outputs: { emitedChangedValue: "emitedChangedValue" }, providers: [
|
|
28
27
|
{
|
|
29
28
|
provide: NG_VALUE_ACCESSOR,
|
|
30
29
|
useExisting: forwardRef(() => InputNumberComponent),
|
|
31
30
|
multi: true,
|
|
32
31
|
},
|
|
33
|
-
], usesInheritance: true, ngImport: i0, template: "@if(!isReadOnly){\r\n @if(label){\r\n
|
|
32
|
+
], usesInheritance: true, ngImport: i0, template: "@if(!isReadOnly){\r\n @if(label){\r\n <app-form-label [label]=\"label\" [optional]=\"!required\" [tooltip]=\"tooltip\"></app-form-label>\r\n }\r\n <mat-form-field\r\n class=\"primary-form {{ className }}\"\r\n [ngClass]=\"{ 'input-disabled': control.disabled }\"\r\n [floatLabel]=\"floatLabel\"\r\n >\r\n @if(iconPrefixName){<span class=\"sfi {{ iconPrefixName }}\"></span>}\r\n @if(loading){<span\r\n class=\"sfi sfi-spinner d-inline-block spin fc-coral\"\r\n matSuffix\r\n ></span\r\n >}\r\n <label class=\"mat-form-content\">\r\n <!-- add input for ar && en custom directive with add type = arOnly || type = enOnly-->\r\n <input\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [type]=\"type\"\r\n [placeholder]=\"placeholder\"\r\n numberOnly\r\n />\r\n </label>\r\n @if(iconSuffixName){<span matSuffix class=\"sfi {{ iconSuffixName }}\"></span>}\r\n @if(hint){\r\n <mat-hint class=\"d-flex align-items-center gap-1 mt-1\">\r\n <span\r\n class=\"sfi sfi-info fs-17 fc-dark-gray\"\r\n [ngClass]=\"{ 'fc-oasis-light-imp': value }\"\r\n ></span>\r\n <span class=\"fs-12 fc-black line-height-1\">{{ hint }}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n } @if(isReadOnly && (showIfEmpty || control)){\r\n <ng-container class=\"info-section\">\r\n <app-info-item\r\n class=\"info-item w-100\"\r\n [label]=\"label\"\r\n [insideTable]=\"insideTable\"\r\n [hasLabel]=\"!!label\"\r\n [type]=\"type\"\r\n [value]=\"control.value\"\r\n ></app-info-item>\r\n </ng-container>\r\n }", styles: [":host{flex-grow:1}.input-disabled{pointer-events:none;opacity:1.5}\n"], dependencies: [{ kind: "directive", type: NumberDirective, selector: "[numberOnly]", inputs: ["decimals"] }, { kind: "component", type: i1.FormLabelComponent, selector: "app-form-label", inputs: ["tooltip", "label", "optional"] }, { kind: "component", type: i2.ValidationErrorsComponent, selector: "app-validation-errors", inputs: ["errors", "customErrorMessages"] }, { kind: "component", type: i3.InfoItemComponent, selector: "app-info-item", inputs: ["label", "value", "name", "type", "dateType", "multiple", "insideTable", "hasLabel", "arrayList", "actionType", "download"] }, { kind: "ngmodule", type: i4.ReactiveFormsModule }, { kind: "directive", type: i4.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: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i4.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i5.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: i6.MatFormFieldModule }, { kind: "component", type: i6.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i6.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: i6.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "directive", type: i7.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"] }] });
|
|
34
33
|
}
|
|
35
34
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputNumberComponent, decorators: [{
|
|
36
35
|
type: Component,
|
|
37
36
|
args: [{ selector: 'app-input-number', schemas: [CUSTOM_ELEMENTS_SCHEMA], standalone: true, imports: [
|
|
38
|
-
MatFormField,
|
|
39
|
-
NgClass,
|
|
40
|
-
ReactiveFormsModule,
|
|
41
|
-
InfoItemComponent,
|
|
42
|
-
SatPopoverModule,
|
|
43
|
-
MatInput,
|
|
44
37
|
NumberDirective,
|
|
45
|
-
|
|
38
|
+
...Shareds,
|
|
39
|
+
...MatFormImports
|
|
46
40
|
], providers: [
|
|
47
41
|
{
|
|
48
42
|
provide: NG_VALUE_ACCESSOR,
|
|
49
43
|
useExisting: forwardRef(() => InputNumberComponent),
|
|
50
44
|
multi: true,
|
|
51
45
|
},
|
|
52
|
-
], template: "@if(!isReadOnly){\r\n @if(label){\r\n
|
|
53
|
-
}], propDecorators: {
|
|
54
|
-
type: Input
|
|
55
|
-
}], floatLabel: [{
|
|
46
|
+
], template: "@if(!isReadOnly){\r\n @if(label){\r\n <app-form-label [label]=\"label\" [optional]=\"!required\" [tooltip]=\"tooltip\"></app-form-label>\r\n }\r\n <mat-form-field\r\n class=\"primary-form {{ className }}\"\r\n [ngClass]=\"{ 'input-disabled': control.disabled }\"\r\n [floatLabel]=\"floatLabel\"\r\n >\r\n @if(iconPrefixName){<span class=\"sfi {{ iconPrefixName }}\"></span>}\r\n @if(loading){<span\r\n class=\"sfi sfi-spinner d-inline-block spin fc-coral\"\r\n matSuffix\r\n ></span\r\n >}\r\n <label class=\"mat-form-content\">\r\n <!-- add input for ar && en custom directive with add type = arOnly || type = enOnly-->\r\n <input\r\n matInput\r\n [value]=\"value\"\r\n oninput=\"validity.valid || (value='');\"\r\n [formControl]=\"control\"\r\n [type]=\"type\"\r\n [placeholder]=\"placeholder\"\r\n numberOnly\r\n />\r\n </label>\r\n @if(iconSuffixName){<span matSuffix class=\"sfi {{ iconSuffixName }}\"></span>}\r\n @if(hint){\r\n <mat-hint class=\"d-flex align-items-center gap-1 mt-1\">\r\n <span\r\n class=\"sfi sfi-info fs-17 fc-dark-gray\"\r\n [ngClass]=\"{ 'fc-oasis-light-imp': value }\"\r\n ></span>\r\n <span class=\"fs-12 fc-black line-height-1\">{{ hint }}</span>\r\n </mat-hint>\r\n }\r\n </mat-form-field>\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n } @if(isReadOnly && (showIfEmpty || control)){\r\n <ng-container class=\"info-section\">\r\n <app-info-item\r\n class=\"info-item w-100\"\r\n [label]=\"label\"\r\n [insideTable]=\"insideTable\"\r\n [hasLabel]=\"!!label\"\r\n [type]=\"type\"\r\n [value]=\"control.value\"\r\n ></app-info-item>\r\n </ng-container>\r\n }", styles: [":host{flex-grow:1}.input-disabled{pointer-events:none;opacity:1.5}\n"] }]
|
|
47
|
+
}], propDecorators: { floatLabel: [{
|
|
56
48
|
type: Input
|
|
57
49
|
}], className: [{
|
|
58
50
|
type: Input
|
|
@@ -67,4 +59,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImpor
|
|
|
67
59
|
}], emitedChangedValue: [{
|
|
68
60
|
type: Output
|
|
69
61
|
}] } });
|
|
70
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
62
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5wdXQtbnVtYmVyLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL2JwbS1jb3JlL3NyYy9saWIvY29tcG9uZW50cy9zaGFyZWQtY29tcG9uZW50cy9mb3JtLWZpZWxkL2lucHV0LW51bWJlci9pbnB1dC1udW1iZXIuY29tcG9uZW50LnRzIiwiLi4vLi4vLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvYnBtLWNvcmUvc3JjL2xpYi9jb21wb25lbnRzL3NoYXJlZC1jb21wb25lbnRzL2Zvcm0tZmllbGQvaW5wdXQtbnVtYmVyL2lucHV0LW51bWJlci5jb21wb25lbnQuaHRtbCJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSw0REFBNEQ7QUFDNUQsdURBQXVEO0FBQ3ZELHVEQUF1RDtBQUN2RCxPQUFPLEVBQUMsaUJBQWlCLEVBQUMsTUFBTSxnQkFBZ0IsQ0FBQztBQUN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AaWYoaXNSZWFkT25seSAmJiAoc2hvd0lmRW1wdHkgfHwgY29udHJvbCkpe1xyXG4gIDxuZy1jb250YWluZXIgY2xhc3M9XCJpbmZvLXNlY3Rpb25cIj5cclxuICAgIDxhcHAtaW5mby1pdGVtXHJcbiAgICAgIGNsYXNzPVwiaW5mby1pdGVtIHctMTAwXCJcclxuICAgICAgW2xhYmVsXT1cImxhYmVsXCJcclxuICAgICAgW2luc2lkZVRhYmxlXT1cImluc2lkZVRhYmxlXCJcclxuICAgICAgW2hhc0xhYmVsXT1cIiEhbGFiZWxcIlxyXG4gICAgICBbdHlwZV09XCJ0eXBlXCJcclxuICAgICAgW3ZhbHVlXT1cImNvbnRyb2wudmFsdWVcIlxyXG4gICAgPjwvYXBwLWluZm8taXRlbT5cclxuICA8L25nLWNvbnRhaW5lcj5cclxuICB9Il19
|
|
@@ -1,15 +1,16 @@
|
|
|
1
1
|
import { NgxIntlTelInputModule } from 'ngx-intl-tel-input-gg';
|
|
2
2
|
import { CountryISO, SearchCountryField } from 'ngx-intl-tel-input-gg';
|
|
3
|
-
import { FormsModule, NG_VALUE_ACCESSOR
|
|
3
|
+
import { FormsModule, NG_VALUE_ACCESSOR } from '@angular/forms';
|
|
4
4
|
import { Component, Input, CUSTOM_ELEMENTS_SCHEMA, forwardRef } from '@angular/core';
|
|
5
|
-
import { InfoItemComponent } from "../info-item/info-item.component";
|
|
6
5
|
import { CommonModule } from "@angular/common";
|
|
7
6
|
import { ControlValueAccessorDirective } from '../control-value-accessor.directive';
|
|
8
|
-
import {
|
|
7
|
+
import { Shareds } from '../shared-imports';
|
|
9
8
|
import * as i0 from "@angular/core";
|
|
10
|
-
import * as i1 from "@angular/
|
|
11
|
-
import * as i2 from "
|
|
12
|
-
import * as i3 from "
|
|
9
|
+
import * as i1 from "@angular/forms";
|
|
10
|
+
import * as i2 from "ngx-intl-tel-input-gg";
|
|
11
|
+
import * as i3 from "../form-label/form-label.component";
|
|
12
|
+
import * as i4 from "../validation-errors/validation-errors.component";
|
|
13
|
+
import * as i5 from "../info-item/info-item.component";
|
|
13
14
|
export class InputTelephoneComponent extends ControlValueAccessorDirective {
|
|
14
15
|
floatLabel = 'auto';
|
|
15
16
|
className = 'bordered-input';
|
|
@@ -23,27 +24,25 @@ export class InputTelephoneComponent extends ControlValueAccessorDirective {
|
|
|
23
24
|
useExisting: forwardRef(() => InputTelephoneComponent),
|
|
24
25
|
multi: true,
|
|
25
26
|
},
|
|
26
|
-
], usesInheritance: true, ngImport: i0, template: "@if(!isReadOnly){\r\n <ng-container>\r\n @if(label){\r\n <
|
|
27
|
+
], usesInheritance: true, ngImport: i0, template: "@if(!isReadOnly){\r\n <ng-container>\r\n @if(label){\r\n <app-form-label [label]=\"label\" [optional]=\"!required\" [tooltip]=\"tooltip\"></app-form-label>\r\n }\r\n <!-- <mat-form-field style=\"height: 50px;\" class=\"primary-form input-telephone {{className}}\" floatLabel=\"always\"> -->\r\n <div class=\"primary-form input-telephone {{className}}\" floatLabel=\"always\">\r\n <label class=\"mat-form-content\">\r\n <!-- [placeholder]=\"label\" -->\r\n <!-- <input matInput [disabled]=\"disabled\" ng2TelInput numberOnly #phone\r\n [ng2TelInputOptions]=\"{initialCountry: 'sa', utilsScript: 'assets/js/utils.js'}\" (hasError)=\"hasError($event)\"\r\n (ng2TelOutput)=\"getNumber($event)\" (intlTelInputObject)=\"telInputObject($event)\"\r\n (countryChange)=\"onCountryChange($event)\" [(ngModel)]=\"field\" [name]=\"name\"\r\n oninput=\"this.value.replace(/[^0-9.]/g, ''); this.value = this.value.replace(/(\\..*)\\./g, '$1');\"\r\n [maxlength]=\"maxLength\" [minLength]=\"minLength\" />-->\r\n <!-- <input matInput [hidden]=\"true\"/> -->\r\n <ngx-intl-tel-input\r\n [formControl]=\"control\"\r\n [cssClass]=\"'custom'\"\r\n [preferredCountries]=\"[CountryISO.UnitedStates, CountryISO.UnitedKingdom]\"\r\n [enableAutoCountrySelect]=\"false\"\r\n [enablePlaceholder]=\"true\"\r\n [searchCountryFlag]=\"true\"\r\n [searchCountryField]=\"[SearchCountryField.Iso2, SearchCountryField.Name]\"\r\n [selectFirstCountry]=\"false\"\r\n [selectedCountryISO]=\"CountryISO.SaudiArabia\"\r\n [maxLength]=\"15\"\r\n [phoneValidation]=\"true\"\r\n [inputId]=\"\"\r\n name=\"phone\"\r\n ></ngx-intl-tel-input>\r\n </label>\r\n </div>\r\n <!-- </mat-form-field> -->\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n </ng-container>\r\n}\r\n@if(isReadOnly){\r\n <ng-container>\r\n <app-info-item class=\"info-item w-100\" [type]=\"'telephone'\" [label]=\"label\"\r\n [value]=\"control.value\"></app-info-item>\r\n </ng-container>\r\n}\r\n\r\n", styles: ["[dir=rtl] :host .mat-input-element{direction:ltr;text-align:right}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: FormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "ngmodule", type: NgxIntlTelInputModule }, { kind: "component", type: i2.NgxIntlTelInputComponent, selector: "ngx-intl-tel-input", inputs: ["value", "preferredCountries", "enablePlaceholder", "customPlaceholder", "numberFormat", "cssClass", "onlyCountries", "enableAutoCountrySelect", "searchCountryFlag", "searchCountryField", "searchCountryPlaceholder", "maxLength", "selectFirstCountry", "selectedCountryISO", "phoneValidation", "inputId", "separateDialCode"], outputs: ["countryChange"] }, { kind: "directive", type: i2.NativeElementInjectorDirective, selector: "[ngModel], [formControl], [formControlName]" }, { kind: "component", type: i3.FormLabelComponent, selector: "app-form-label", inputs: ["tooltip", "label", "optional"] }, { kind: "component", type: i4.ValidationErrorsComponent, selector: "app-validation-errors", inputs: ["errors", "customErrorMessages"] }, { kind: "component", type: i5.InfoItemComponent, selector: "app-info-item", inputs: ["label", "value", "name", "type", "dateType", "multiple", "insideTable", "hasLabel", "arrayList", "actionType", "download"] }, { kind: "ngmodule", type: i1.ReactiveFormsModule }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }] });
|
|
27
28
|
}
|
|
28
29
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.8", ngImport: i0, type: InputTelephoneComponent, decorators: [{
|
|
29
30
|
type: Component,
|
|
30
31
|
args: [{ selector: 'app-input-telephone', schemas: [CUSTOM_ELEMENTS_SCHEMA], standalone: true, imports: [
|
|
31
32
|
CommonModule,
|
|
32
|
-
InfoItemComponent,
|
|
33
33
|
FormsModule,
|
|
34
34
|
NgxIntlTelInputModule,
|
|
35
|
-
|
|
36
|
-
ValidationErrorsComponent
|
|
35
|
+
...Shareds
|
|
37
36
|
], providers: [
|
|
38
37
|
{
|
|
39
38
|
provide: NG_VALUE_ACCESSOR,
|
|
40
39
|
useExisting: forwardRef(() => InputTelephoneComponent),
|
|
41
40
|
multi: true,
|
|
42
41
|
},
|
|
43
|
-
], template: "@if(!isReadOnly){\r\n <ng-container>\r\n @if(label){\r\n <
|
|
42
|
+
], template: "@if(!isReadOnly){\r\n <ng-container>\r\n @if(label){\r\n <app-form-label [label]=\"label\" [optional]=\"!required\" [tooltip]=\"tooltip\"></app-form-label>\r\n }\r\n <!-- <mat-form-field style=\"height: 50px;\" class=\"primary-form input-telephone {{className}}\" floatLabel=\"always\"> -->\r\n <div class=\"primary-form input-telephone {{className}}\" floatLabel=\"always\">\r\n <label class=\"mat-form-content\">\r\n <!-- [placeholder]=\"label\" -->\r\n <!-- <input matInput [disabled]=\"disabled\" ng2TelInput numberOnly #phone\r\n [ng2TelInputOptions]=\"{initialCountry: 'sa', utilsScript: 'assets/js/utils.js'}\" (hasError)=\"hasError($event)\"\r\n (ng2TelOutput)=\"getNumber($event)\" (intlTelInputObject)=\"telInputObject($event)\"\r\n (countryChange)=\"onCountryChange($event)\" [(ngModel)]=\"field\" [name]=\"name\"\r\n oninput=\"this.value.replace(/[^0-9.]/g, ''); this.value = this.value.replace(/(\\..*)\\./g, '$1');\"\r\n [maxlength]=\"maxLength\" [minLength]=\"minLength\" />-->\r\n <!-- <input matInput [hidden]=\"true\"/> -->\r\n <ngx-intl-tel-input\r\n [formControl]=\"control\"\r\n [cssClass]=\"'custom'\"\r\n [preferredCountries]=\"[CountryISO.UnitedStates, CountryISO.UnitedKingdom]\"\r\n [enableAutoCountrySelect]=\"false\"\r\n [enablePlaceholder]=\"true\"\r\n [searchCountryFlag]=\"true\"\r\n [searchCountryField]=\"[SearchCountryField.Iso2, SearchCountryField.Name]\"\r\n [selectFirstCountry]=\"false\"\r\n [selectedCountryISO]=\"CountryISO.SaudiArabia\"\r\n [maxLength]=\"15\"\r\n [phoneValidation]=\"true\"\r\n [inputId]=\"\"\r\n name=\"phone\"\r\n ></ngx-intl-tel-input>\r\n </label>\r\n </div>\r\n <!-- </mat-form-field> -->\r\n <app-validation-errors [errors]=\"control.errors\"></app-validation-errors>\r\n </ng-container>\r\n}\r\n@if(isReadOnly){\r\n <ng-container>\r\n <app-info-item class=\"info-item w-100\" [type]=\"'telephone'\" [label]=\"label\"\r\n [value]=\"control.value\"></app-info-item>\r\n </ng-container>\r\n}\r\n\r\n", styles: ["[dir=rtl] :host .mat-input-element{direction:ltr;text-align:right}\n"] }]
|
|
44
43
|
}], propDecorators: { floatLabel: [{
|
|
45
44
|
type: Input
|
|
46
45
|
}], className: [{
|
|
47
46
|
type: Input
|
|
48
47
|
}] } });
|
|
49
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
48
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5wdXQtdGVsZXBob25lLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL2JwbS1jb3JlL3NyYy9saWIvY29tcG9uZW50cy9zaGFyZWQtY29tcG9uZW50cy9mb3J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