@bootkit/ng0 0.0.0-alpha.1 → 0.0.0-alpha.10

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.
Files changed (216) hide show
  1. package/common/index.d.ts +82 -3
  2. package/components/accordion/index.d.ts +32 -0
  3. package/components/backdrop/index.d.ts +8 -0
  4. package/components/button/index.d.ts +48 -0
  5. package/components/card/index.d.ts +27 -0
  6. package/components/code/index.d.ts +35 -0
  7. package/components/collapse/index.d.ts +59 -0
  8. package/components/confirmation/index.d.ts +66 -0
  9. package/components/form-field/index.d.ts +72 -0
  10. package/components/modal/index.d.ts +29 -0
  11. package/components/nav/index.d.ts +68 -0
  12. package/{offcanvas/offcanvas.directive.d.ts → components/offcanvas/index.d.ts} +14 -5
  13. package/components/overlay/index.d.ts +40 -0
  14. package/components/pagination/index.d.ts +56 -0
  15. package/components/popover/index.d.ts +36 -0
  16. package/components/sidenav/index.d.ts +46 -0
  17. package/components/stepper/index.d.ts +26 -0
  18. package/components/table/index.d.ts +211 -0
  19. package/components/toast/index.d.ts +101 -0
  20. package/components/tooltip/index.d.ts +30 -0
  21. package/components/vertical-menu/index.d.ts +61 -0
  22. package/data/index.d.ts +203 -0
  23. package/date/index.d.ts +34 -0
  24. package/fesm2022/bootkit-ng0-common.mjs +38 -3
  25. package/fesm2022/bootkit-ng0-common.mjs.map +1 -1
  26. package/fesm2022/{bootkit-ng0-accordion.mjs → bootkit-ng0-components-accordion.mjs} +16 -16
  27. package/fesm2022/bootkit-ng0-components-accordion.mjs.map +1 -0
  28. package/fesm2022/bootkit-ng0-components-backdrop.mjs +41 -0
  29. package/fesm2022/bootkit-ng0-components-backdrop.mjs.map +1 -0
  30. package/fesm2022/bootkit-ng0-components-button.mjs +119 -0
  31. package/fesm2022/bootkit-ng0-components-button.mjs.map +1 -0
  32. package/fesm2022/bootkit-ng0-components-card.mjs +62 -0
  33. package/fesm2022/bootkit-ng0-components-card.mjs.map +1 -0
  34. package/fesm2022/bootkit-ng0-components-code.mjs +70 -0
  35. package/fesm2022/bootkit-ng0-components-code.mjs.map +1 -0
  36. package/fesm2022/{bootkit-ng0-collapse.mjs → bootkit-ng0-components-collapse.mjs} +16 -16
  37. package/fesm2022/bootkit-ng0-components-collapse.mjs.map +1 -0
  38. package/fesm2022/bootkit-ng0-components-confirmation.mjs +167 -0
  39. package/fesm2022/bootkit-ng0-components-confirmation.mjs.map +1 -0
  40. package/fesm2022/bootkit-ng0-components-form-field.mjs +147 -0
  41. package/fesm2022/bootkit-ng0-components-form-field.mjs.map +1 -0
  42. package/fesm2022/bootkit-ng0-components-modal.mjs +68 -0
  43. package/fesm2022/bootkit-ng0-components-modal.mjs.map +1 -0
  44. package/fesm2022/bootkit-ng0-components-nav.mjs +165 -0
  45. package/fesm2022/bootkit-ng0-components-nav.mjs.map +1 -0
  46. package/fesm2022/{bootkit-ng0-offcanvas.mjs → bootkit-ng0-components-offcanvas.mjs} +11 -11
  47. package/fesm2022/bootkit-ng0-components-offcanvas.mjs.map +1 -0
  48. package/fesm2022/bootkit-ng0-components-overlay.mjs +99 -0
  49. package/fesm2022/bootkit-ng0-components-overlay.mjs.map +1 -0
  50. package/fesm2022/bootkit-ng0-components-pagination.mjs +120 -0
  51. package/fesm2022/bootkit-ng0-components-pagination.mjs.map +1 -0
  52. package/fesm2022/{bootkit-ng0-popover.mjs → bootkit-ng0-components-popover.mjs} +12 -12
  53. package/fesm2022/bootkit-ng0-components-popover.mjs.map +1 -0
  54. package/fesm2022/bootkit-ng0-components-sidenav.mjs +132 -0
  55. package/fesm2022/bootkit-ng0-components-sidenav.mjs.map +1 -0
  56. package/fesm2022/bootkit-ng0-components-stepper.mjs +91 -0
  57. package/fesm2022/bootkit-ng0-components-stepper.mjs.map +1 -0
  58. package/fesm2022/bootkit-ng0-components-table.mjs +358 -0
  59. package/fesm2022/bootkit-ng0-components-table.mjs.map +1 -0
  60. package/fesm2022/{bootkit-ng0-toast.mjs → bootkit-ng0-components-toast.mjs} +10 -10
  61. package/fesm2022/bootkit-ng0-components-toast.mjs.map +1 -0
  62. package/fesm2022/{bootkit-ng0-tooltip.mjs → bootkit-ng0-components-tooltip.mjs} +10 -10
  63. package/fesm2022/bootkit-ng0-components-tooltip.mjs.map +1 -0
  64. package/fesm2022/bootkit-ng0-components-vertical-menu.mjs +161 -0
  65. package/fesm2022/bootkit-ng0-components-vertical-menu.mjs.map +1 -0
  66. package/fesm2022/bootkit-ng0-data.mjs +267 -0
  67. package/fesm2022/bootkit-ng0-data.mjs.map +1 -0
  68. package/fesm2022/bootkit-ng0-date.mjs +50 -0
  69. package/fesm2022/bootkit-ng0-date.mjs.map +1 -0
  70. package/fesm2022/bootkit-ng0-file.mjs +50 -0
  71. package/fesm2022/bootkit-ng0-file.mjs.map +1 -0
  72. package/fesm2022/bootkit-ng0-form.mjs +420 -0
  73. package/fesm2022/bootkit-ng0-form.mjs.map +1 -0
  74. package/fesm2022/bootkit-ng0-http.mjs +277 -0
  75. package/fesm2022/bootkit-ng0-http.mjs.map +1 -0
  76. package/fesm2022/bootkit-ng0-localization-locales.mjs +82 -0
  77. package/fesm2022/bootkit-ng0-localization-locales.mjs.map +1 -0
  78. package/fesm2022/bootkit-ng0-localization.mjs +419 -0
  79. package/fesm2022/bootkit-ng0-localization.mjs.map +1 -0
  80. package/fesm2022/bootkit-ng0-platform-browser.mjs +51 -0
  81. package/fesm2022/bootkit-ng0-platform-browser.mjs.map +1 -0
  82. package/fesm2022/bootkit-ng0-script.mjs +59 -0
  83. package/fesm2022/bootkit-ng0-script.mjs.map +1 -0
  84. package/fesm2022/bootkit-ng0-security.mjs +132 -0
  85. package/fesm2022/bootkit-ng0-security.mjs.map +1 -0
  86. package/file/index.d.ts +22 -0
  87. package/form/index.d.ts +91 -0
  88. package/http/index.d.ts +167 -0
  89. package/index.d.ts +3 -5
  90. package/localization/index.d.ts +265 -0
  91. package/localization/locales/index.d.ts +7 -0
  92. package/package.json +123 -61
  93. package/platform/browser/index.d.ts +22 -0
  94. package/script/index.d.ts +27 -0
  95. package/security/index.d.ts +42 -0
  96. package/accordion/accordion-item.component.d.ts +0 -13
  97. package/accordion/accordion.component.d.ts +0 -13
  98. package/accordion/accordion.module.d.ts +0 -8
  99. package/accordion/index.d.ts +0 -5
  100. package/accordion/public-api.d.ts +0 -3
  101. package/collapse/collapse.component.d.ts +0 -18
  102. package/collapse/collapse.directive.d.ts +0 -32
  103. package/collapse/collapse.module.d.ts +0 -8
  104. package/collapse/index.d.ts +0 -5
  105. package/collapse/public-api.d.ts +0 -3
  106. package/common/public-api.d.ts +0 -2
  107. package/common/types.d.ts +0 -4
  108. package/common/utils.d.ts +0 -3
  109. package/esm2022/accordion/accordion-item.component.mjs +0 -34
  110. package/esm2022/accordion/accordion.component.mjs +0 -25
  111. package/esm2022/accordion/accordion.module.mjs +0 -25
  112. package/esm2022/accordion/bootkit-ng0-accordion.mjs +0 -5
  113. package/esm2022/accordion/public-api.mjs +0 -4
  114. package/esm2022/bootkit-ng0.mjs +0 -5
  115. package/esm2022/collapse/bootkit-ng0-collapse.mjs +0 -5
  116. package/esm2022/collapse/collapse.component.mjs +0 -46
  117. package/esm2022/collapse/collapse.directive.mjs +0 -94
  118. package/esm2022/collapse/collapse.module.mjs +0 -23
  119. package/esm2022/collapse/public-api.mjs +0 -4
  120. package/esm2022/common/bootkit-ng0-common.mjs +0 -5
  121. package/esm2022/common/public-api.mjs +0 -3
  122. package/esm2022/common/types.mjs +0 -3
  123. package/esm2022/common/utils.mjs +0 -16
  124. package/esm2022/lib/index.mjs +0 -3
  125. package/esm2022/lib/types.mjs +0 -2
  126. package/esm2022/modal/bootkit-ng0-modal.mjs +0 -5
  127. package/esm2022/modal/modal.component.mjs +0 -44
  128. package/esm2022/modal/modal.module.mjs +0 -20
  129. package/esm2022/modal/public-api.mjs +0 -3
  130. package/esm2022/modal/types.mjs +0 -3
  131. package/esm2022/nav/bootkit-ng0-nav.mjs +0 -5
  132. package/esm2022/nav/nav-item.directive.mjs +0 -26
  133. package/esm2022/nav/nav-link.directive.mjs +0 -45
  134. package/esm2022/nav/nav.directive.mjs +0 -23
  135. package/esm2022/nav/nav.module.mjs +0 -35
  136. package/esm2022/nav/public-api.mjs +0 -7
  137. package/esm2022/nav/tab-content.component.mjs +0 -29
  138. package/esm2022/nav/tab-pane.directive.mjs +0 -20
  139. package/esm2022/offcanvas/bootkit-ng0-offcanvas.mjs +0 -5
  140. package/esm2022/offcanvas/offcanvas.directive.mjs +0 -118
  141. package/esm2022/offcanvas/offcanvas.module.mjs +0 -19
  142. package/esm2022/offcanvas/public-api.mjs +0 -3
  143. package/esm2022/overlay/bootkit-ng0-overlay.mjs +0 -5
  144. package/esm2022/overlay/overlay.directive.mjs +0 -111
  145. package/esm2022/overlay/overlay.module.mjs +0 -22
  146. package/esm2022/overlay/private/utils.mjs +0 -58
  147. package/esm2022/overlay/public-api.mjs +0 -3
  148. package/esm2022/popover/bootkit-ng0-popover.mjs +0 -5
  149. package/esm2022/popover/popover-wrapper/popover-wrapper.component.mjs +0 -29
  150. package/esm2022/popover/popover.directive.mjs +0 -140
  151. package/esm2022/popover/public-api.mjs +0 -2
  152. package/esm2022/popover/types.mjs +0 -2
  153. package/esm2022/public-api.mjs +0 -5
  154. package/esm2022/toast/bootkit-ng0-toast.mjs +0 -5
  155. package/esm2022/toast/public-api.mjs +0 -4
  156. package/esm2022/toast/toast-ref.mjs +0 -27
  157. package/esm2022/toast/toast.component.mjs +0 -68
  158. package/esm2022/toast/toast.service.mjs +0 -93
  159. package/esm2022/toast/types.mjs +0 -2
  160. package/esm2022/tooltip/bootkit-ng0-tooltip.mjs +0 -5
  161. package/esm2022/tooltip/public-api.mjs +0 -3
  162. package/esm2022/tooltip/tooltip-wrapper/tooltip-wrapper.component.mjs +0 -44
  163. package/esm2022/tooltip/tooltip.directive.mjs +0 -93
  164. package/esm2022/tooltip/types.mjs +0 -2
  165. package/fesm2022/bootkit-ng0-accordion.mjs.map +0 -1
  166. package/fesm2022/bootkit-ng0-collapse.mjs.map +0 -1
  167. package/fesm2022/bootkit-ng0-modal.mjs +0 -68
  168. package/fesm2022/bootkit-ng0-modal.mjs.map +0 -1
  169. package/fesm2022/bootkit-ng0-nav.mjs +0 -166
  170. package/fesm2022/bootkit-ng0-nav.mjs.map +0 -1
  171. package/fesm2022/bootkit-ng0-offcanvas.mjs.map +0 -1
  172. package/fesm2022/bootkit-ng0-overlay.mjs +0 -194
  173. package/fesm2022/bootkit-ng0-overlay.mjs.map +0 -1
  174. package/fesm2022/bootkit-ng0-popover.mjs.map +0 -1
  175. package/fesm2022/bootkit-ng0-toast.mjs.map +0 -1
  176. package/fesm2022/bootkit-ng0-tooltip.mjs.map +0 -1
  177. package/lib/index.d.ts +0 -2
  178. package/lib/types.d.ts +0 -1
  179. package/modal/index.d.ts +0 -5
  180. package/modal/modal.component.d.ts +0 -18
  181. package/modal/modal.module.d.ts +0 -7
  182. package/modal/public-api.d.ts +0 -2
  183. package/modal/types.d.ts +0 -2
  184. package/nav/index.d.ts +0 -5
  185. package/nav/nav-item.directive.d.ts +0 -13
  186. package/nav/nav-link.directive.d.ts +0 -16
  187. package/nav/nav.directive.d.ts +0 -11
  188. package/nav/nav.module.d.ts +0 -11
  189. package/nav/public-api.d.ts +0 -6
  190. package/nav/tab-content.component.d.ts +0 -15
  191. package/nav/tab-pane.directive.d.ts +0 -9
  192. package/offcanvas/index.d.ts +0 -5
  193. package/offcanvas/offcanvas.module.d.ts +0 -7
  194. package/offcanvas/public-api.d.ts +0 -2
  195. package/overlay/index.d.ts +0 -5
  196. package/overlay/overlay.directive.d.ts +0 -50
  197. package/overlay/overlay.module.d.ts +0 -10
  198. package/overlay/private/utils.d.ts +0 -10
  199. package/overlay/public-api.d.ts +0 -2
  200. package/popover/index.d.ts +0 -5
  201. package/popover/popover-wrapper/popover-wrapper.component.d.ts +0 -15
  202. package/popover/popover.directive.d.ts +0 -30
  203. package/popover/public-api.d.ts +0 -1
  204. package/popover/types.d.ts +0 -4
  205. package/public-api.d.ts +0 -1
  206. package/toast/index.d.ts +0 -5
  207. package/toast/public-api.d.ts +0 -3
  208. package/toast/toast-ref.d.ts +0 -12
  209. package/toast/toast.component.d.ts +0 -19
  210. package/toast/toast.service.d.ts +0 -43
  211. package/toast/types.d.ts +0 -44
  212. package/tooltip/index.d.ts +0 -5
  213. package/tooltip/public-api.d.ts +0 -2
  214. package/tooltip/tooltip-wrapper/tooltip-wrapper.component.d.ts +0 -19
  215. package/tooltip/tooltip.directive.d.ts +0 -24
  216. package/tooltip/types.d.ts +0 -3
@@ -0,0 +1,420 @@
1
+ import * as i0 from '@angular/core';
2
+ import { Input, Directive, input, NgModule, forwardRef, HostListener } from '@angular/core';
3
+ import { NG_VALIDATORS, NG_VALUE_ACCESSOR } from '@angular/forms';
4
+ import { formatNumber } from '@angular/common';
5
+
6
+ function equalWithValidator(targetValue, inequalityMessage) {
7
+ return (control) => {
8
+ const isValid = control.value === targetValue;
9
+ return isValid ? null :
10
+ {
11
+ equalWith: {
12
+ value: control.value,
13
+ message: inequalityMessage
14
+ }
15
+ };
16
+ };
17
+ }
18
+
19
+ class EqualWithValidatorDirective {
20
+ targetValue;
21
+ inequalityMessage;
22
+ constructor() {
23
+ }
24
+ validate(control) {
25
+ return equalWithValidator(this.targetValue, this.inequalityMessage)(control);
26
+ }
27
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: EqualWithValidatorDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
28
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.1.6", type: EqualWithValidatorDirective, isStandalone: true, selector: "[ng0EqualWith]", inputs: { targetValue: ["ng0EqualWith", "targetValue"], inequalityMessage: "inequalityMessage" }, providers: [
29
+ { provide: NG_VALIDATORS, useExisting: EqualWithValidatorDirective, multi: true }
30
+ ], exportAs: ["ng0EqualWith"], ngImport: i0 });
31
+ }
32
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: EqualWithValidatorDirective, decorators: [{
33
+ type: Directive,
34
+ args: [{
35
+ selector: '[ng0EqualWith]',
36
+ exportAs: 'ng0EqualWith',
37
+ standalone: true,
38
+ providers: [
39
+ { provide: NG_VALIDATORS, useExisting: EqualWithValidatorDirective, multi: true }
40
+ ]
41
+ }]
42
+ }], ctorParameters: () => [], propDecorators: { targetValue: [{
43
+ type: Input,
44
+ args: ['ng0EqualWith']
45
+ }], inequalityMessage: [{
46
+ type: Input
47
+ }] } });
48
+
49
+ const urlRegEx = new RegExp('(https?://)?([\\da-z.-]+)\\.([a-z.]{2,6})[/\\w .-]*/?');
50
+ function urlValidator() {
51
+ return (control) => {
52
+ const value = control.value;
53
+ if (!value || urlRegEx.test(value)) {
54
+ return null;
55
+ }
56
+ else {
57
+ return {
58
+ 'url': {
59
+ value
60
+ }
61
+ };
62
+ }
63
+ };
64
+ }
65
+
66
+ class UrlValidatorDirective {
67
+ /** Directive is enabled or disabled */
68
+ iscUrl = true;
69
+ validate(control) {
70
+ return urlValidator()(control);
71
+ }
72
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: UrlValidatorDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
73
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.1.6", type: UrlValidatorDirective, isStandalone: true, selector: "input[ng0Url]", inputs: { iscUrl: "iscUrl" }, providers: [{ provide: NG_VALIDATORS, useExisting: UrlValidatorDirective, multi: true }], exportAs: ["ng0Url"], ngImport: i0 });
74
+ }
75
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: UrlValidatorDirective, decorators: [{
76
+ type: Directive,
77
+ args: [{
78
+ selector: 'input[ng0Url]',
79
+ exportAs: 'ng0Url',
80
+ standalone: true,
81
+ providers: [{ provide: NG_VALIDATORS, useExisting: UrlValidatorDirective, multi: true }]
82
+ }]
83
+ }], propDecorators: { iscUrl: [{
84
+ type: Input
85
+ }] } });
86
+
87
+ class CustomValidatorDirective {
88
+ validator = input.required(...(ngDevMode ? [{ debugName: "validator", alias: 'ng0CustomValidator' }] : [{ alias: 'ng0CustomValidator' }]));
89
+ constructor() { }
90
+ validate(control) {
91
+ return this.validator()(control);
92
+ }
93
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: CustomValidatorDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
94
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.1.6", type: CustomValidatorDirective, isStandalone: true, selector: "[ng0CustomValidator]", inputs: { validator: { classPropertyName: "validator", publicName: "ng0CustomValidator", isSignal: true, isRequired: true, transformFunction: null } }, providers: [
95
+ { provide: NG_VALIDATORS, useExisting: CustomValidatorDirective, multi: true }
96
+ ], exportAs: ["ng0CustomValidator"], ngImport: i0 });
97
+ }
98
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: CustomValidatorDirective, decorators: [{
99
+ type: Directive,
100
+ args: [{
101
+ selector: '[ng0CustomValidator]',
102
+ exportAs: 'ng0CustomValidator',
103
+ standalone: true,
104
+ providers: [
105
+ { provide: NG_VALIDATORS, useExisting: CustomValidatorDirective, multi: true }
106
+ ]
107
+ }]
108
+ }], ctorParameters: () => [] });
109
+
110
+ const items = [
111
+ // ErrorDirective,
112
+ // FirstErrorDirective,
113
+ // Validators
114
+ EqualWithValidatorDirective,
115
+ UrlValidatorDirective,
116
+ CustomValidatorDirective,
117
+ ];
118
+ class ValidationModule {
119
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: ValidationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
120
+ static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.1.6", ngImport: i0, type: ValidationModule, imports: [
121
+ // ErrorDirective,
122
+ // FirstErrorDirective,
123
+ // Validators
124
+ EqualWithValidatorDirective,
125
+ UrlValidatorDirective,
126
+ CustomValidatorDirective], exports: [
127
+ // ErrorDirective,
128
+ // FirstErrorDirective,
129
+ // Validators
130
+ EqualWithValidatorDirective,
131
+ UrlValidatorDirective,
132
+ CustomValidatorDirective] });
133
+ static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: ValidationModule });
134
+ }
135
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: ValidationModule, decorators: [{
136
+ type: NgModule,
137
+ args: [{
138
+ imports: items,
139
+ exports: items,
140
+ }]
141
+ }] });
142
+
143
+ class FocusDirective {
144
+ elementRef;
145
+ /**
146
+ *
147
+ */
148
+ focusOnLoad = true;
149
+ focusWhen;
150
+ focused = false;
151
+ constructor(elementRef) {
152
+ this.elementRef = elementRef;
153
+ }
154
+ ngOnInit() {
155
+ if (this.focusOnLoad) {
156
+ setTimeout(() => {
157
+ this.elementRef.nativeElement.focus();
158
+ });
159
+ }
160
+ }
161
+ ngOnChanges(changes) {
162
+ if (changes['focusWhen']) {
163
+ if (this.focusWhen) {
164
+ setTimeout(() => {
165
+ this.elementRef.nativeElement.focus();
166
+ });
167
+ }
168
+ }
169
+ }
170
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: FocusDirective, deps: [{ token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Directive });
171
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.1.6", type: FocusDirective, isStandalone: true, selector: "[ng0Focus]", inputs: { focusOnLoad: "focusOnLoad", focusWhen: "focusWhen" }, exportAs: ["ng0Focus"], usesOnChanges: true, ngImport: i0 });
172
+ }
173
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: FocusDirective, decorators: [{
174
+ type: Directive,
175
+ args: [{
176
+ selector: '[ng0Focus]',
177
+ exportAs: 'ng0Focus',
178
+ standalone: true
179
+ }]
180
+ }], ctorParameters: () => [{ type: i0.ElementRef }], propDecorators: { focusOnLoad: [{
181
+ type: Input
182
+ }], focusWhen: [{
183
+ type: Input
184
+ }] } });
185
+
186
+ const addThousandsSeparator = (str) => str.replace(/\B(?=(\d{3})+(?!\d))/g, ",");
187
+ const isValidNumber = (str) => str.trim() !== '' && !isNaN(Number(str));
188
+ const removeChar = (str, charToRemove) => str.split(charToRemove).join('');
189
+ const Keys = {
190
+ backspace: 'Backspace',
191
+ tab: 'Tab',
192
+ arrowLeft: 'ArrowLeft',
193
+ arrowRight: 'ArrowRight',
194
+ delete: 'Delete',
195
+ home: 'Home',
196
+ end: 'End'
197
+ };
198
+ class NumberDirective {
199
+ el;
200
+ renderer;
201
+ /** */
202
+ minFractionDigits = input(3, ...(ngDevMode ? [{ debugName: "minFractionDigits" }] : []));
203
+ maxFractionDigits = input(10, ...(ngDevMode ? [{ debugName: "maxFractionDigits" }] : []));
204
+ useGrouping = input(false, ...(ngDevMode ? [{ debugName: "useGrouping" }] : []));
205
+ numberType = input('integer', ...(ngDevMode ? [{ debugName: "numberType" }] : []));
206
+ onChange = (_) => { };
207
+ onTouched = () => { };
208
+ decimalSeparator;
209
+ thousandsSeparator = ',';
210
+ selectionStart = 0;
211
+ selectionEnd = 0;
212
+ isCursorInsideIntegerPart = false;
213
+ decimalSeparatorPosition = -1;
214
+ value;
215
+ setProperty = (prop, value) => this.renderer.setProperty(this.el.nativeElement, prop, value);
216
+ constructor(el, renderer) {
217
+ this.el = el;
218
+ this.renderer = renderer;
219
+ }
220
+ ngOnInit() {
221
+ // Use Intl.NumberFormat to find decimal separator for locale
222
+ const formatted = formatNumber(1.1, 'en', '1.1-1');
223
+ this.decimalSeparator = formatted.replace(/\d/g, '') || '.';
224
+ }
225
+ registerOnChange(fn) {
226
+ this.onChange = fn;
227
+ }
228
+ registerOnTouched(fn) {
229
+ this.onTouched = fn;
230
+ }
231
+ setDisabledState(isDisabled) {
232
+ this.setProperty('disabled', isDisabled);
233
+ }
234
+ writeValue(value) {
235
+ var inputValue;
236
+ if (value === undefined || value === null) {
237
+ inputValue = '';
238
+ this.value = undefined;
239
+ }
240
+ else if (typeof value === 'number') {
241
+ inputValue = this.formatNumber(value);
242
+ this.value = value;
243
+ }
244
+ else if (typeof value === 'string') {
245
+ const parsedValue = this.value = Number.parseFloat(value);
246
+ inputValue = this.formatNumber(parsedValue);
247
+ }
248
+ else {
249
+ console.error('NumberDirective: Unsupported value type', value);
250
+ inputValue = 'Invalid';
251
+ }
252
+ this.setProperty('value', inputValue);
253
+ }
254
+ onKeyDown(event) {
255
+ this.updateCursorInfo();
256
+ if (!this.isKeyAllowed(event.key)) {
257
+ event.preventDefault();
258
+ return;
259
+ }
260
+ const key = event.key;
261
+ if (key == Keys.backspace) {
262
+ if (this.selectionStart > 1 && (this.selectionStart === this.selectionEnd)) {
263
+ let value = this.el.nativeElement.value;
264
+ let beforeSelection = value.charAt(this.selectionStart - 1);
265
+ if (beforeSelection === ',') {
266
+ // If the character before the cursor is a comma, we need to skip it
267
+ this.setProperty('selectionStart', this.selectionStart - 2);
268
+ }
269
+ }
270
+ }
271
+ }
272
+ onInput(s) {
273
+ if (s === '') {
274
+ this.value = undefined;
275
+ this.onChange(undefined);
276
+ return;
277
+ }
278
+ this.updateCursorInfo();
279
+ if (this.isCursorInsideIntegerPart) {
280
+ this.formatIntegerPart(s);
281
+ }
282
+ var number = Number(removeChar(this.el.nativeElement.value, this.thousandsSeparator));
283
+ this.value = isNaN(number) ? undefined : number;
284
+ this.onChange(this.value);
285
+ }
286
+ formatIntegerPart(value) {
287
+ // Format the input value
288
+ const integerPart = value.split(this.decimalSeparator)[0];
289
+ const decimalPart = value.split(this.decimalSeparator)[1];
290
+ if (integerPart.length <= 3) {
291
+ return;
292
+ }
293
+ let normalizedIntegerPart = removeChar(integerPart, this.thousandsSeparator); // Remove commas
294
+ let formattedValue = addThousandsSeparator(normalizedIntegerPart);
295
+ if (decimalPart !== undefined) {
296
+ formattedValue += this.decimalSeparator + decimalPart;
297
+ }
298
+ this.setProperty('value', formattedValue);
299
+ let newSelectionStart;
300
+ // fix the cursor position after formatting
301
+ if (value.length == 1) {
302
+ newSelectionStart = 1;
303
+ }
304
+ else {
305
+ const newValueLength = formattedValue.length;
306
+ const cursorJump = newValueLength - value.length;
307
+ newSelectionStart = Math.max(0, this.selectionStart + cursorJump);
308
+ }
309
+ this.setProperty('selectionStart', newSelectionStart);
310
+ this.setProperty('selectionEnd', newSelectionStart);
311
+ // return formattedValue;
312
+ }
313
+ onBlur() {
314
+ if (this.value !== undefined) {
315
+ let formattedValue = this.formatNumber(this.value);
316
+ this.setProperty('value', formattedValue);
317
+ }
318
+ this.onTouched();
319
+ }
320
+ onPaste(event) {
321
+ // event.
322
+ // value = value.trim();
323
+ }
324
+ updateCursorInfo() {
325
+ let value = this.el.nativeElement.value;
326
+ this.selectionStart = this.el.nativeElement.selectionStart || 0;
327
+ this.selectionEnd = this.el.nativeElement.selectionEnd || 0;
328
+ this.decimalSeparatorPosition = value.indexOf(this.decimalSeparator);
329
+ if (this.decimalSeparatorPosition > -1) {
330
+ this.isCursorInsideIntegerPart = (this.selectionStart <= this.decimalSeparatorPosition);
331
+ }
332
+ else {
333
+ this.isCursorInsideIntegerPart = true;
334
+ }
335
+ }
336
+ formatNumber(n) {
337
+ var isInteger = this.numberType() == 'integer';
338
+ return new Intl.NumberFormat('en-US', {
339
+ useGrouping: this.useGrouping(),
340
+ minimumFractionDigits: isInteger ? 0 : this.minFractionDigits(),
341
+ maximumFractionDigits: isInteger ? 0 : this.maxFractionDigits(),
342
+ style: 'decimal',
343
+ }).format(n);
344
+ }
345
+ isKeyAllowed(key) {
346
+ const allowedKeys = [Keys.backspace, Keys.tab, Keys.arrowLeft, Keys.arrowRight, Keys.delete, Keys.home, Keys.end];
347
+ const input = this.el.nativeElement;
348
+ const value = input.value;
349
+ if (allowedKeys.includes(key)) {
350
+ return true; // allow control/navigation keys
351
+ }
352
+ // Allow one leading minus
353
+ if (key === '-') {
354
+ return (input.selectionStart === 0 || input.selectionEnd === 0) && value.charAt(0) !== '-';
355
+ }
356
+ // Allow one dot for decimal
357
+ if (key === this.decimalSeparator) {
358
+ return (this.numberType() == 'decimal') &&
359
+ (!value.includes(this.decimalSeparator)) &&
360
+ (this.selectionStart == input.value.length);
361
+ }
362
+ // Allow numbers only
363
+ if (/^\d$/.test(key)) {
364
+ if (this.isCursorInsideIntegerPart) {
365
+ return true;
366
+ }
367
+ else {
368
+ var decimalPart = value.split(this.decimalSeparator)[1];
369
+ var maxFractionDigits = this.maxFractionDigits();
370
+ if (maxFractionDigits != undefined && decimalPart.length < maxFractionDigits) {
371
+ return true;
372
+ }
373
+ else {
374
+ return this.selectionStart !== this.selectionEnd; // allow a new digit if a substring is selected
375
+ }
376
+ }
377
+ }
378
+ return false;
379
+ }
380
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: NumberDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive });
381
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.1.6", type: NumberDirective, isStandalone: true, selector: "[ng0Number]", inputs: { minFractionDigits: { classPropertyName: "minFractionDigits", publicName: "minFractionDigits", isSignal: true, isRequired: false, transformFunction: null }, maxFractionDigits: { classPropertyName: "maxFractionDigits", publicName: "maxFractionDigits", isSignal: true, isRequired: false, transformFunction: null }, useGrouping: { classPropertyName: "useGrouping", publicName: "useGrouping", isSignal: true, isRequired: false, transformFunction: null }, numberType: { classPropertyName: "numberType", publicName: "numberType", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "keydown": "onKeyDown($event)", "input": "onInput($event.target.value)", "blur": "onBlur()", "paste": "onPaste($event)" } }, providers: [
382
+ {
383
+ provide: NG_VALUE_ACCESSOR,
384
+ useExisting: forwardRef(() => NumberDirective),
385
+ multi: true
386
+ }
387
+ ], ngImport: i0 });
388
+ }
389
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.1.6", ngImport: i0, type: NumberDirective, decorators: [{
390
+ type: Directive,
391
+ args: [{
392
+ selector: '[ng0Number]',
393
+ providers: [
394
+ {
395
+ provide: NG_VALUE_ACCESSOR,
396
+ useExisting: forwardRef(() => NumberDirective),
397
+ multi: true
398
+ }
399
+ ]
400
+ }]
401
+ }], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.Renderer2 }], propDecorators: { onKeyDown: [{
402
+ type: HostListener,
403
+ args: ['keydown', ['$event']]
404
+ }], onInput: [{
405
+ type: HostListener,
406
+ args: ['input', ['$event.target.value']]
407
+ }], onBlur: [{
408
+ type: HostListener,
409
+ args: ['blur']
410
+ }], onPaste: [{
411
+ type: HostListener,
412
+ args: ['paste', ['$event']]
413
+ }] } });
414
+
415
+ /**
416
+ * Generated bundle index. Do not edit.
417
+ */
418
+
419
+ export { CustomValidatorDirective, EqualWithValidatorDirective, FocusDirective, NumberDirective, UrlValidatorDirective, ValidationModule, equalWithValidator };
420
+ //# sourceMappingURL=bootkit-ng0-form.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"bootkit-ng0-form.mjs","sources":["../../../projects/ng0/form/validation/validators/equal-with/equal-with-validator.ts","../../../projects/ng0/form/validation/validators/equal-with/equal-with.directive.ts","../../../projects/ng0/form/validation/validators/url/url-validator.ts","../../../projects/ng0/form/validation/validators/url/url-validator.directive.ts","../../../projects/ng0/form/validation/validators/custom/custom-validator.directive.ts","../../../projects/ng0/form/validation/validation.module.ts","../../../projects/ng0/form/focus.directive.ts","../../../projects/ng0/form/number.directive.ts","../../../projects/ng0/form/bootkit-ng0-form.ts"],"sourcesContent":["import { AbstractControl, ValidatorFn } from '@angular/forms';\r\n\r\nexport function equalWithValidator(targetValue?: string, inequalityMessage?: string): ValidatorFn {\r\n return (control: AbstractControl): { [key: string]: any } | null => {\r\n const isValid = control.value === targetValue;\r\n\r\n return isValid ? null :\r\n {\r\n equalWith: {\r\n value: control.value,\r\n message: inequalityMessage\r\n }\r\n };\r\n };\r\n}\r\n","import { Directive, Input } from '@angular/core';\r\nimport { AbstractControl, NG_VALIDATORS, Validator } from '@angular/forms';\r\nimport { equalWithValidator } from './equal-with-validator';\r\n\r\n@Directive({\r\n selector: '[ng0EqualWith]',\r\n exportAs: 'ng0EqualWith',\r\n standalone: true,\r\n providers: [\r\n { provide: NG_VALIDATORS, useExisting: EqualWithValidatorDirective, multi: true }\r\n ]\r\n})\r\nexport class EqualWithValidatorDirective implements Validator {\r\n @Input('ng0EqualWith') targetValue?: string;\r\n @Input() inequalityMessage?: string;\r\n\r\n constructor() {\r\n }\r\n\r\n validate(control: AbstractControl): { [key: string]: any } | null {\r\n return equalWithValidator(this.targetValue, this.inequalityMessage)(control);\r\n }\r\n}\r\n","import { AbstractControl, ValidatorFn } from '@angular/forms';\r\nconst urlRegEx = new RegExp('(https?://)?([\\\\da-z.-]+)\\\\.([a-z.]{2,6})[/\\\\w .-]*/?');\r\n\r\nexport function urlValidator(): ValidatorFn {\r\n return (control: AbstractControl): { [key: string]: any } | null => {\r\n const value = (control.value as string);\r\n if (!value || urlRegEx.test(value)) {\r\n return null;\r\n } else {\r\n return {\r\n 'url': {\r\n value\r\n }\r\n };\r\n }\r\n };\r\n}","import { Directive, Input } from '@angular/core';\r\nimport { FormControl, NG_VALIDATORS, ValidationErrors, Validator } from '@angular/forms';\r\nimport { urlValidator } from './url-validator';\r\n\r\n@Directive({\r\n selector: 'input[ng0Url]',\r\n exportAs: 'ng0Url',\r\n standalone: true,\r\n providers: [{ provide: NG_VALIDATORS, useExisting: UrlValidatorDirective, multi: true }]\r\n})\r\nexport class UrlValidatorDirective implements Validator {\r\n /** Directive is enabled or disabled */\r\n @Input() iscUrl?: boolean | string = true;\r\n\r\n validate(control: FormControl): ValidationErrors | null {\r\n return urlValidator()(control);\r\n }\r\n}\r\n","import { Directive, input, Input } from '@angular/core';\r\nimport { AbstractControl, NG_VALIDATORS, ValidationErrors, Validator } from '@angular/forms';\r\n\r\n@Directive({\r\n selector: '[ng0CustomValidator]',\r\n exportAs: 'ng0CustomValidator',\r\n standalone: true,\r\n providers: [\r\n { provide: NG_VALIDATORS, useExisting: CustomValidatorDirective, multi: true }\r\n ]\r\n})\r\nexport class CustomValidatorDirective implements Validator {\r\n validator = input.required<(value: any) => ValidationErrors | null>({alias: 'ng0CustomValidator'});\r\n\r\n constructor() { }\r\n\r\n validate(control: AbstractControl): ValidationErrors | null {\r\n return this.validator()(control);\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { EqualWithValidatorDirective } from './validators/equal-with/equal-with.directive';\r\nimport { UrlValidatorDirective } from './validators/url/url-validator.directive';\r\nimport { CustomValidatorDirective } from './validators/custom/custom-validator.directive';\r\n\r\nconst items = [\r\n // ErrorDirective,\r\n // FirstErrorDirective,\r\n\r\n // Validators\r\n EqualWithValidatorDirective,\r\n UrlValidatorDirective,\r\n CustomValidatorDirective,\r\n];\r\n\r\n@NgModule({\r\n imports: items,\r\n exports: items,\r\n})\r\nexport class ValidationModule { }\r\n","import { Directive, ElementRef, Input, OnChanges, SimpleChanges, OnInit } from '@angular/core';\r\n\r\n@Directive({\r\n selector: '[ng0Focus]',\r\n exportAs: 'ng0Focus',\r\n standalone: true\r\n})\r\nexport class FocusDirective implements OnInit, OnChanges {\r\n /** \r\n * \r\n */\r\n @Input() focusOnLoad = true;\r\n @Input() focusWhen?: boolean;\r\n private focused = false;\r\n\r\n constructor(private elementRef: ElementRef) {\r\n }\r\n\r\n ngOnInit(): void {\r\n if (this.focusOnLoad) {\r\n setTimeout(() => {\r\n this.elementRef.nativeElement.focus();\r\n });\r\n }\r\n }\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes['focusWhen']) {\r\n if (this.focusWhen) {\r\n setTimeout(() => {\r\n this.elementRef.nativeElement.focus();\r\n });\r\n }\r\n }\r\n }\r\n}\r\n","import { Directive, HostListener, forwardRef, ElementRef, Renderer2, input } from '@angular/core';\r\nimport { ControlValueAccessor, NG_VALUE_ACCESSOR } from '@angular/forms';\r\nimport { formatNumber } from '@angular/common';\r\n\r\nconst addThousandsSeparator = (str: string) => str.replace(/\\B(?=(\\d{3})+(?!\\d))/g, \",\");\r\nconst isValidNumber = (str: string) => str.trim() !== '' && !isNaN(Number(str));\r\nconst removeChar = (str: string, charToRemove: string) => str.split(charToRemove).join('');\r\n\r\nconst Keys = {\r\n backspace: 'Backspace',\r\n tab: 'Tab',\r\n arrowLeft: 'ArrowLeft',\r\n arrowRight: 'ArrowRight',\r\n delete: 'Delete',\r\n home: 'Home',\r\n end: 'End'\r\n}\r\n\r\n@Directive({\r\n selector: '[ng0Number]',\r\n providers: [\r\n {\r\n provide: NG_VALUE_ACCESSOR,\r\n useExisting: forwardRef(() => NumberDirective),\r\n multi: true\r\n }\r\n ]\r\n})\r\nexport class NumberDirective implements ControlValueAccessor {\r\n /** */\r\n minFractionDigits = input<number | undefined>(3);\r\n maxFractionDigits = input<number| undefined>(10);\r\n useGrouping = input<boolean>(false);\r\n numberType = input<'decimal' | 'integer'>('integer');\r\n private onChange = (_: any) => { };\r\n private onTouched = () => { };\r\n private decimalSeparator!: string;\r\n private thousandsSeparator: string = ',';\r\n private selectionStart: number = 0;\r\n private selectionEnd: number = 0;\r\n private isCursorInsideIntegerPart: boolean = false;\r\n private decimalSeparatorPosition = -1;\r\n private value?: number;\r\n private setProperty = (prop: string, value: any) => this.renderer.setProperty(this.el.nativeElement, prop, value);\r\n\r\n constructor(\r\n private el: ElementRef<HTMLInputElement>,\r\n private renderer: Renderer2,\r\n // private locale: Locale,\r\n ) { }\r\n\r\n ngOnInit() {\r\n // Use Intl.NumberFormat to find decimal separator for locale\r\n const formatted = formatNumber(1.1, 'en', '1.1-1');\r\n this.decimalSeparator = formatted.replace(/\\d/g, '') || '.';\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouched = fn;\r\n }\r\n\r\n setDisabledState?(isDisabled: boolean): void {\r\n this.setProperty('disabled', isDisabled);\r\n }\r\n\r\n writeValue(value: any): void {\r\n var inputValue: string;\r\n\r\n if (value === undefined || value === null) {\r\n inputValue = '';\r\n this.value = undefined;\r\n } else if (typeof value === 'number') {\r\n inputValue = this.formatNumber(value);\r\n this.value = value;\r\n }\r\n else if (typeof value === 'string') {\r\n const parsedValue = this.value = Number.parseFloat(value);\r\n inputValue = this.formatNumber(parsedValue);\r\n } else {\r\n console.error('NumberDirective: Unsupported value type', value);\r\n inputValue = 'Invalid';\r\n }\r\n\r\n this.setProperty('value', inputValue);\r\n }\r\n\r\n @HostListener('keydown', ['$event'])\r\n private onKeyDown(event: KeyboardEvent) {\r\n this.updateCursorInfo();\r\n\r\n if (!this.isKeyAllowed(event.key)) {\r\n event.preventDefault();\r\n return;\r\n }\r\n\r\n const key = event.key;\r\n\r\n if (key == Keys.backspace) {\r\n if (this.selectionStart > 1 && (this.selectionStart === this.selectionEnd)) {\r\n let value = this.el.nativeElement.value;\r\n let beforeSelection = value.charAt(this.selectionStart - 1);\r\n if (beforeSelection === ',') {\r\n // If the character before the cursor is a comma, we need to skip it\r\n this.setProperty('selectionStart', this.selectionStart - 2);\r\n }\r\n }\r\n }\r\n }\r\n\r\n @HostListener('input', ['$event.target.value'])\r\n private onInput(s: string) {\r\n if (s === '') {\r\n this.value = undefined;\r\n this.onChange(undefined);\r\n return;\r\n }\r\n\r\n this.updateCursorInfo();\r\n\r\n if (this.isCursorInsideIntegerPart) {\r\n this.formatIntegerPart(s);\r\n }\r\n\r\n var number = Number(removeChar(this.el.nativeElement.value, this.thousandsSeparator));\r\n this.value = isNaN(number) ? undefined : number;\r\n this.onChange(this.value);\r\n }\r\n\r\n private formatIntegerPart(value: string) {\r\n // Format the input value\r\n const integerPart = value.split(this.decimalSeparator)[0];\r\n const decimalPart = value.split(this.decimalSeparator)[1];\r\n\r\n if (integerPart.length <= 3) {\r\n return;\r\n }\r\n\r\n let normalizedIntegerPart = removeChar(integerPart, this.thousandsSeparator); // Remove commas\r\n\r\n let formattedValue = addThousandsSeparator(normalizedIntegerPart);\r\n if (decimalPart !== undefined) {\r\n formattedValue += this.decimalSeparator + decimalPart;\r\n }\r\n\r\n this.setProperty('value', formattedValue);\r\n let newSelectionStart: number;\r\n\r\n // fix the cursor position after formatting\r\n if (value.length == 1) {\r\n newSelectionStart = 1;\r\n } else {\r\n const newValueLength = formattedValue.length;\r\n const cursorJump = newValueLength - value.length;\r\n newSelectionStart = Math.max(0, this.selectionStart + cursorJump);\r\n }\r\n\r\n this.setProperty('selectionStart', newSelectionStart);\r\n this.setProperty('selectionEnd', newSelectionStart);\r\n\r\n // return formattedValue;\r\n }\r\n\r\n @HostListener('blur')\r\n private onBlur() {\r\n if (this.value !== undefined) {\r\n let formattedValue = this.formatNumber(this.value);\r\n this.setProperty('value', formattedValue);\r\n }\r\n\r\n this.onTouched();\r\n }\r\n\r\n @HostListener('paste', ['$event'])\r\n private onPaste(event: ClipboardEvent) {\r\n // event.\r\n // value = value.trim();\r\n }\r\n\r\n private updateCursorInfo() {\r\n let value = this.el.nativeElement.value;\r\n this.selectionStart = this.el.nativeElement.selectionStart || 0;\r\n this.selectionEnd = this.el.nativeElement.selectionEnd || 0;\r\n\r\n this.decimalSeparatorPosition = value.indexOf(this.decimalSeparator);\r\n if (this.decimalSeparatorPosition > -1) {\r\n this.isCursorInsideIntegerPart = (this.selectionStart <= this.decimalSeparatorPosition);\r\n } else {\r\n this.isCursorInsideIntegerPart = true;\r\n }\r\n }\r\n\r\n private formatNumber(n: number): string {\r\n var isInteger = this.numberType() == 'integer';\r\n return new Intl.NumberFormat('en-US', {\r\n useGrouping: this.useGrouping(),\r\n minimumFractionDigits: isInteger ? 0 : this.minFractionDigits(),\r\n maximumFractionDigits: isInteger ? 0 : this.maxFractionDigits(),\r\n style: 'decimal',\r\n }).format(n);\r\n }\r\n\r\n private isKeyAllowed(key: string) {\r\n const allowedKeys = [Keys.backspace, Keys.tab, Keys.arrowLeft, Keys.arrowRight, Keys.delete, Keys.home, Keys.end];\r\n const input = this.el.nativeElement;\r\n const value = input.value;\r\n\r\n if (allowedKeys.includes(key)) {\r\n return true; // allow control/navigation keys\r\n }\r\n\r\n // Allow one leading minus\r\n if (key === '-') {\r\n return (input.selectionStart === 0 || input.selectionEnd === 0) && value.charAt(0) !== '-';\r\n }\r\n\r\n // Allow one dot for decimal\r\n if (key === this.decimalSeparator) {\r\n return (this.numberType() == 'decimal') &&\r\n (!value.includes(this.decimalSeparator)) &&\r\n (this.selectionStart == input.value.length);\r\n }\r\n\r\n // Allow numbers only\r\n if (/^\\d$/.test(key)) {\r\n if (this.isCursorInsideIntegerPart) {\r\n return true;\r\n } else {\r\n var decimalPart = value.split(this.decimalSeparator)[1];\r\n var maxFractionDigits = this.maxFractionDigits();\r\n if (maxFractionDigits != undefined && decimalPart.length < maxFractionDigits) {\r\n return true;\r\n } else {\r\n return this.selectionStart !== this.selectionEnd; // allow a new digit if a substring is selected\r\n }\r\n }\r\n }\r\n\r\n return false;\r\n }\r\n}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAEM,SAAU,kBAAkB,CAAC,WAAoB,EAAE,iBAA0B,EAAA;IAC7E,OAAO,CAAC,OAAwB,KAAmC;AAC7D,QAAA,MAAM,OAAO,GAAG,OAAO,CAAC,KAAK,KAAK,WAAW;AAE7C,QAAA,OAAO,OAAO,GAAG,IAAI;AACf,YAAA;AACM,gBAAA,SAAS,EAAE;oBACL,KAAK,EAAE,OAAO,CAAC,KAAK;AACpB,oBAAA,OAAO,EAAE;AACd;aACN;AACb,KAAC;AACP;;MCFa,2BAA2B,CAAA;AACX,IAAA,WAAW;AACzB,I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