ecabs-components 1.0.19 → 1.0.21

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 (365) hide show
  1. package/esm2022/ecabs-components.mjs +5 -0
  2. package/esm2022/lib/base/consts/date-mask.consts.mjs +57 -0
  3. package/esm2022/lib/base/directives/date-mask.directive.mjs +67 -0
  4. package/esm2022/lib/base/directives/date-mask.directive.module.mjs +22 -0
  5. package/esm2022/lib/base/directives/digits-only.directive.mjs +133 -0
  6. package/esm2022/lib/base/directives/digits-only.directive.module.mjs +22 -0
  7. package/esm2022/lib/base/directives/number-border.directive.mjs +58 -0
  8. package/esm2022/lib/base/directives/number-border.directive.module.mjs +22 -0
  9. package/esm2022/lib/base/element-base.mjs +105 -0
  10. package/esm2022/lib/base/element-wrapper/element-wrapper.component.mjs +56 -0
  11. package/esm2022/lib/base/element-wrapper/element-wrapper.module.mjs +52 -0
  12. package/esm2022/lib/base/hint/hint.component.mjs +21 -0
  13. package/esm2022/lib/base/hint/hint.module.mjs +20 -0
  14. package/esm2022/lib/base/validation/validation.component.mjs +75 -0
  15. package/esm2022/lib/base/validation/validation.module.mjs +20 -0
  16. package/esm2022/lib/ecabs-breadcrumb/ecabs-breadcrumb.component.mjs +17 -0
  17. package/esm2022/lib/ecabs-breadcrumb/ecabs-breadcrumb.module.mjs +20 -0
  18. package/esm2022/lib/ecabs-buttons/ecabs-buttons.component.mjs +64 -0
  19. package/esm2022/lib/ecabs-buttons/ecabs-buttons.module.mjs +21 -0
  20. package/esm2022/lib/ecabs-checkbox-toggle/ecabs-checkbox-toggle.component.mjs +94 -0
  21. package/esm2022/lib/ecabs-checkbox-toggle/ecabs-checkbox-toggle.module.mjs +36 -0
  22. package/esm2022/lib/ecabs-date-picker/components/ecabs-date-picker-header/ecabs-date-picker-header.component.mjs +15 -0
  23. package/esm2022/lib/ecabs-date-picker/ecabs-date-picker.component.mjs +89 -0
  24. package/esm2022/lib/ecabs-date-picker/ecabs-date-picker.module.mjs +48 -0
  25. package/esm2022/lib/ecabs-date-time-picker/components/ecabs-date-time-picker-header/ecabs-date-time-picker-header.component.mjs +15 -0
  26. package/esm2022/lib/ecabs-date-time-picker/ecabs-date-time-picker.component.mjs +186 -0
  27. package/esm2022/lib/ecabs-date-time-picker/ecabs-date-time-picker.module.mjs +64 -0
  28. package/esm2022/lib/ecabs-date-time-range-picker/components/ecabs-date-time-range-picker-header/ecabs-date-time-range-picker-header.component.mjs +15 -0
  29. package/esm2022/lib/ecabs-date-time-range-picker/ecabs-date-time-range-picker.component.mjs +199 -0
  30. package/esm2022/lib/ecabs-date-time-range-picker/ecabs-date-time-range-picker.module.mjs +65 -0
  31. package/esm2022/lib/ecabs-date-time-range-picker/time-range.directive.mjs +48 -0
  32. package/esm2022/lib/ecabs-dialog-confirm/ecabs-dialog-confirm.component.mjs +50 -0
  33. package/esm2022/lib/ecabs-dialog-confirm/ecabs-dialog-confirm.module.mjs +20 -0
  34. package/esm2022/lib/ecabs-dialog-message/ecabs-dialog-message.component.mjs +47 -0
  35. package/esm2022/lib/ecabs-dialog-message/ecabs-dialog-message.module.mjs +20 -0
  36. package/esm2022/lib/ecabs-empty-placeholder/ecabs-empty-placeholder.component.mjs +22 -0
  37. package/esm2022/lib/ecabs-empty-placeholder/ecabs-empty-placeholder.module.mjs +19 -0
  38. package/esm2022/lib/ecabs-expansion-panel/ecabs-expansion-panel.component.mjs +85 -0
  39. package/esm2022/lib/ecabs-expansion-panel/ecabs-expansion-panel.module.mjs +24 -0
  40. package/esm2022/lib/ecabs-increment/ecabs-increment.component.mjs +83 -0
  41. package/esm2022/lib/ecabs-increment/ecabs-increment.module.mjs +23 -0
  42. package/esm2022/lib/ecabs-input/ecabs-input.component.mjs +90 -0
  43. package/esm2022/lib/ecabs-input/ecabs-input.module.mjs +22 -0
  44. package/esm2022/lib/ecabs-language-selector/ecabs-language-selector.component.mjs +64 -0
  45. package/esm2022/lib/ecabs-language-selector/ecabs-language-selector.module.mjs +39 -0
  46. package/esm2022/lib/ecabs-loading/ecabs-loading.component.mjs +22 -0
  47. package/esm2022/lib/ecabs-loading/ecabs-loading.module.mjs +19 -0
  48. package/esm2022/lib/ecabs-loading/spinner/spinner.component.mjs +14 -0
  49. package/esm2022/lib/ecabs-note/ecabs-note.component.mjs +28 -0
  50. package/esm2022/lib/ecabs-note/ecabs-note.module.mjs +19 -0
  51. package/esm2022/lib/ecabs-phone/ecabs-phone.component.mjs +111 -0
  52. package/esm2022/lib/ecabs-phone/ecabs-phone.module.mjs +22 -0
  53. package/esm2022/lib/ecabs-picker-header/ecabs-picker-header.component.mjs +53 -0
  54. package/esm2022/lib/ecabs-picker-header/ecabs-picker-header.module.mjs +22 -0
  55. package/esm2022/lib/ecabs-radio-button-list/ecabs-radio-button-list.component.mjs +68 -0
  56. package/esm2022/lib/ecabs-radio-button-list/ecabs-radio-button-list.module.mjs +32 -0
  57. package/esm2022/lib/ecabs-select/ecabs-select.component.mjs +316 -0
  58. package/esm2022/lib/ecabs-select/ecabs-select.module.mjs +60 -0
  59. package/esm2022/lib/ecabs-table/ecabs-table-filter-wrapper/ecabs-table-filter-wrapper.component.mjs +19 -0
  60. package/esm2022/lib/ecabs-table/ecabs-table-filter-wrapper/ecabs-table-filter-wrapper.module.mjs +24 -0
  61. package/esm2022/lib/ecabs-table/ecabs-table.component.mjs +48 -0
  62. package/esm2022/lib/ecabs-table/ecabs-table.module.mjs +33 -0
  63. package/esm2022/lib/ecabs-textarea/ecabs-textarea.component.mjs +65 -0
  64. package/esm2022/lib/ecabs-textarea/ecabs-textarea.module.mjs +20 -0
  65. package/esm2022/lib/ecabs-timepicker/componets/ecabs-time-list-panel/ecabs-time-list-panel.component.mjs +144 -0
  66. package/esm2022/lib/ecabs-timepicker/config.model.mjs +2 -0
  67. package/esm2022/lib/ecabs-timepicker/ecabs-timepicker.component.mjs +322 -0
  68. package/esm2022/lib/ecabs-timepicker/ecabs-timepicker.module.mjs +20 -0
  69. package/esm2022/lib/ecabs-timepicker/ecabs-timepicker.service.mjs +29 -0
  70. package/esm2022/lib/models/bread-crumb.mjs +2 -0
  71. package/esm2022/lib/models/timepicker.models.mjs +2 -0
  72. package/esm2022/lib/services/ecabs-components.service.mjs +31 -0
  73. package/esm2022/public-api.mjs +55 -0
  74. package/fesm2022/ecabs-components.mjs +3478 -0
  75. package/fesm2022/ecabs-components.mjs.map +1 -0
  76. package/index.d.ts +5 -0
  77. package/lib/base/consts/date-mask.consts.d.ts +7 -0
  78. package/lib/base/directives/date-mask.directive.d.ts +16 -0
  79. package/lib/base/directives/date-mask.directive.module.d.ts +8 -0
  80. package/lib/base/directives/digits-only.directive.d.ts +26 -0
  81. package/lib/base/directives/digits-only.directive.module.d.ts +8 -0
  82. package/lib/base/directives/number-border.directive.d.ts +13 -0
  83. package/lib/base/directives/number-border.directive.module.d.ts +8 -0
  84. package/lib/base/element-base.d.ts +28 -0
  85. package/lib/base/element-wrapper/element-wrapper.component.d.ts +19 -0
  86. package/lib/base/element-wrapper/element-wrapper.module.d.ts +16 -0
  87. package/lib/base/hint/hint.component.d.ts +8 -0
  88. package/lib/base/hint/hint.module.d.ts +10 -0
  89. package/lib/base/validation/validation.component.d.ts +24 -0
  90. package/lib/base/validation/validation.module.d.ts +10 -0
  91. package/lib/ecabs-breadcrumb/ecabs-breadcrumb.component.d.ts +7 -0
  92. package/lib/ecabs-breadcrumb/ecabs-breadcrumb.module.d.ts +10 -0
  93. package/lib/ecabs-buttons/ecabs-buttons.component.d.ts +20 -0
  94. package/lib/ecabs-buttons/ecabs-buttons.module.d.ts +11 -0
  95. package/lib/ecabs-checkbox-toggle/ecabs-checkbox-toggle.component.d.ts +29 -0
  96. package/lib/ecabs-checkbox-toggle/ecabs-checkbox-toggle.module.d.ts +12 -0
  97. package/lib/ecabs-date-picker/components/ecabs-date-picker-header/ecabs-date-picker-header.component.d.ts +6 -0
  98. package/lib/ecabs-date-picker/ecabs-date-picker.component.d.ts +29 -0
  99. package/lib/ecabs-date-picker/ecabs-date-picker.module.d.ts +15 -0
  100. package/lib/ecabs-date-time-picker/components/ecabs-date-time-picker-header/ecabs-date-time-picker-header.component.d.ts +6 -0
  101. package/lib/ecabs-date-time-picker/ecabs-date-time-picker.component.d.ts +51 -0
  102. package/lib/ecabs-date-time-picker/ecabs-date-time-picker.module.d.ts +19 -0
  103. package/lib/ecabs-date-time-range-picker/components/ecabs-date-time-range-picker-header/ecabs-date-time-range-picker-header.component.d.ts +6 -0
  104. package/lib/ecabs-date-time-range-picker/ecabs-date-time-range-picker.component.d.ts +58 -0
  105. package/lib/ecabs-date-time-range-picker/ecabs-date-time-range-picker.module.d.ts +20 -0
  106. package/lib/ecabs-date-time-range-picker/time-range.directive.d.ts +15 -0
  107. package/lib/ecabs-dialog-confirm/ecabs-dialog-confirm.component.d.ts +31 -0
  108. package/lib/ecabs-dialog-confirm/ecabs-dialog-confirm.module.d.ts +11 -0
  109. package/lib/ecabs-dialog-message/ecabs-dialog-message.component.d.ts +28 -0
  110. package/lib/ecabs-dialog-message/ecabs-dialog-message.module.d.ts +11 -0
  111. package/lib/ecabs-empty-placeholder/ecabs-empty-placeholder.component.d.ts +12 -0
  112. package/lib/ecabs-empty-placeholder/ecabs-empty-placeholder.module.d.ts +9 -0
  113. package/lib/ecabs-expansion-panel/ecabs-expansion-panel.component.d.ts +28 -0
  114. package/lib/ecabs-expansion-panel/ecabs-expansion-panel.module.d.ts +14 -0
  115. package/lib/ecabs-increment/ecabs-increment.component.d.ts +26 -0
  116. package/lib/ecabs-increment/ecabs-increment.module.d.ts +13 -0
  117. package/lib/ecabs-input/ecabs-input.component.d.ts +27 -0
  118. package/lib/ecabs-input/ecabs-input.module.d.ts +12 -0
  119. package/lib/ecabs-language-selector/ecabs-language-selector.component.d.ts +20 -0
  120. package/lib/ecabs-language-selector/ecabs-language-selector.module.d.ts +12 -0
  121. package/lib/ecabs-loading/ecabs-loading.component.d.ts +8 -0
  122. package/lib/ecabs-loading/ecabs-loading.module.d.ts +9 -0
  123. package/lib/ecabs-loading/spinner/spinner.component.d.ts +6 -0
  124. package/lib/ecabs-note/ecabs-note.component.d.ts +7 -0
  125. package/lib/ecabs-note/ecabs-note.module.d.ts +9 -0
  126. package/lib/ecabs-phone/ecabs-phone.component.d.ts +33 -0
  127. package/lib/ecabs-phone/ecabs-phone.module.d.ts +12 -0
  128. package/lib/ecabs-picker-header/ecabs-picker-header.component.d.ts +19 -0
  129. package/lib/ecabs-picker-header/ecabs-picker-header.module.d.ts +12 -0
  130. package/lib/ecabs-radio-button-list/ecabs-radio-button-list.component.d.ts +24 -0
  131. package/lib/ecabs-radio-button-list/ecabs-radio-button-list.module.d.ts +11 -0
  132. package/lib/ecabs-select/ecabs-select.component.d.ts +71 -0
  133. package/lib/ecabs-select/ecabs-select.module.d.ts +15 -0
  134. package/lib/ecabs-table/ecabs-table-filter-wrapper/ecabs-table-filter-wrapper.component.d.ts +8 -0
  135. package/lib/ecabs-table/ecabs-table-filter-wrapper/ecabs-table-filter-wrapper.module.d.ts +9 -0
  136. package/lib/ecabs-table/ecabs-table.component.d.ts +18 -0
  137. package/lib/ecabs-table/ecabs-table.module.d.ts +12 -0
  138. package/lib/ecabs-textarea/ecabs-textarea.component.d.ts +20 -0
  139. package/lib/ecabs-textarea/ecabs-textarea.module.d.ts +10 -0
  140. package/lib/ecabs-timepicker/componets/ecabs-time-list-panel/ecabs-time-list-panel.component.d.ts +40 -0
  141. package/lib/ecabs-timepicker/config.model.d.ts +5 -0
  142. package/lib/ecabs-timepicker/ecabs-timepicker.component.d.ts +53 -0
  143. package/lib/ecabs-timepicker/ecabs-timepicker.module.d.ts +10 -0
  144. package/lib/ecabs-timepicker/ecabs-timepicker.service.d.ts +12 -0
  145. package/lib/models/bread-crumb.d.ts +5 -0
  146. package/{src/lib/models/timepicker.models.ts → lib/models/timepicker.models.d.ts} +3 -4
  147. package/lib/services/ecabs-components.service.d.ts +16 -0
  148. package/package.json +33 -25
  149. package/{src/styles → styles}/material/overrides/_button.scss +1 -0
  150. package/styles/material/overrides/_icon.scss +3 -0
  151. package/{src/styles → styles}/material/overrides/_phone.scss +24 -2
  152. package/karma.conf.js +0 -44
  153. package/ng-package.json +0 -7
  154. package/src/assets/images/nothing-here.svg +0 -22
  155. package/src/lib/base/consts/date-mask.consts.ts +0 -70
  156. package/src/lib/base/directives/date-mask.directive.module.ts +0 -14
  157. package/src/lib/base/directives/date-mask.directive.ts +0 -58
  158. package/src/lib/base/directives/digits-only.directive.module.ts +0 -15
  159. package/src/lib/base/directives/digits-only.directive.ts +0 -129
  160. package/src/lib/base/directives/number-border.directive.module.ts +0 -14
  161. package/src/lib/base/directives/number-border.directive.ts +0 -57
  162. package/src/lib/base/element-base.ts +0 -72
  163. package/src/lib/base/element-wrapper/element-wrapper.component.html +0 -30
  164. package/src/lib/base/element-wrapper/element-wrapper.component.ts +0 -33
  165. package/src/lib/base/element-wrapper/element-wrapper.module.ts +0 -30
  166. package/src/lib/base/hint/hint.component.html +0 -1
  167. package/src/lib/base/hint/hint.component.scss +0 -0
  168. package/src/lib/base/hint/hint.component.ts +0 -12
  169. package/src/lib/base/hint/hint.module.ts +0 -13
  170. package/src/lib/base/validation/validation.component.html +0 -8
  171. package/src/lib/base/validation/validation.component.scss +0 -0
  172. package/src/lib/base/validation/validation.component.ts +0 -84
  173. package/src/lib/base/validation/validation.module.ts +0 -13
  174. package/src/lib/consts/tenant.consts.ts +0 -8
  175. package/src/lib/ecabs-breadcrumb/ecabs-breadcrumb.component.html +0 -11
  176. package/src/lib/ecabs-breadcrumb/ecabs-breadcrumb.component.scss +0 -0
  177. package/src/lib/ecabs-breadcrumb/ecabs-breadcrumb.component.spec.ts +0 -24
  178. package/src/lib/ecabs-breadcrumb/ecabs-breadcrumb.component.ts +0 -12
  179. package/src/lib/ecabs-breadcrumb/ecabs-breadcrumb.module.ts +0 -12
  180. package/src/lib/ecabs-buttons/ecabs-buttons.component.html +0 -18
  181. package/src/lib/ecabs-buttons/ecabs-buttons.component.scss +0 -3
  182. package/src/lib/ecabs-buttons/ecabs-buttons.component.ts +0 -55
  183. package/src/lib/ecabs-buttons/ecabs-buttons.module.ts +0 -14
  184. package/src/lib/ecabs-checkbox-toggle/ecabs-checkbox-toggle.component.html +0 -27
  185. package/src/lib/ecabs-checkbox-toggle/ecabs-checkbox-toggle.component.scss +0 -15
  186. package/src/lib/ecabs-checkbox-toggle/ecabs-checkbox-toggle.component.ts +0 -81
  187. package/src/lib/ecabs-checkbox-toggle/ecabs-checkbox-toggle.module.ts +0 -21
  188. package/src/lib/ecabs-date-picker/components/ecabs-date-picker-header/ecabs-date-picker-header.component.html +0 -4
  189. package/src/lib/ecabs-date-picker/components/ecabs-date-picker-header/ecabs-date-picker-header.component.scss +0 -0
  190. package/src/lib/ecabs-date-picker/components/ecabs-date-picker-header/ecabs-date-picker-header.component.spec.ts +0 -23
  191. package/src/lib/ecabs-date-picker/components/ecabs-date-picker-header/ecabs-date-picker-header.component.ts +0 -11
  192. package/src/lib/ecabs-date-picker/ecabs-date-picker.component.html +0 -31
  193. package/src/lib/ecabs-date-picker/ecabs-date-picker.component.scss +0 -23
  194. package/src/lib/ecabs-date-picker/ecabs-date-picker.component.spec.ts +0 -24
  195. package/src/lib/ecabs-date-picker/ecabs-date-picker.component.ts +0 -72
  196. package/src/lib/ecabs-date-picker/ecabs-date-picker.module.ts +0 -29
  197. package/src/lib/ecabs-date-range-picker/components/ecabs-date-range-picker-header/ecabs-date-range-picker-header.component.html +0 -4
  198. package/src/lib/ecabs-date-range-picker/components/ecabs-date-range-picker-header/ecabs-date-range-picker-header.component.scss +0 -0
  199. package/src/lib/ecabs-date-range-picker/components/ecabs-date-range-picker-header/ecabs-date-range-picker-header.component.spec.ts +0 -23
  200. package/src/lib/ecabs-date-range-picker/components/ecabs-date-range-picker-header/ecabs-date-range-picker-header.component.ts +0 -11
  201. package/src/lib/ecabs-date-range-picker/ecabs-date-range-picker.component.html +0 -31
  202. package/src/lib/ecabs-date-range-picker/ecabs-date-range-picker.component.scss +0 -36
  203. package/src/lib/ecabs-date-range-picker/ecabs-date-range-picker.component.spec.ts +0 -23
  204. package/src/lib/ecabs-date-range-picker/ecabs-date-range-picker.component.ts +0 -113
  205. package/src/lib/ecabs-date-range-picker/ecabs-date-range-picker.module.ts +0 -50
  206. package/src/lib/ecabs-date-time-picker/components/ecabs-date-time-picker-header/ecabs-date-time-picker-header.component.html +0 -4
  207. package/src/lib/ecabs-date-time-picker/components/ecabs-date-time-picker-header/ecabs-date-time-picker-header.component.scss +0 -14
  208. package/src/lib/ecabs-date-time-picker/components/ecabs-date-time-picker-header/ecabs-date-time-picker-header.component.ts +0 -11
  209. package/src/lib/ecabs-date-time-picker/ecabs-date-time-picker.component.html +0 -87
  210. package/src/lib/ecabs-date-time-picker/ecabs-date-time-picker.component.scss +0 -82
  211. package/src/lib/ecabs-date-time-picker/ecabs-date-time-picker.component.spec.ts +0 -23
  212. package/src/lib/ecabs-date-time-picker/ecabs-date-time-picker.component.ts +0 -185
  213. package/src/lib/ecabs-date-time-picker/ecabs-date-time-picker.module.ts +0 -38
  214. package/src/lib/ecabs-date-time-range-picker/components/ecabs-date-time-range-picker-header/ecabs-date-time-range-picker-header.component.html +0 -4
  215. package/src/lib/ecabs-date-time-range-picker/components/ecabs-date-time-range-picker-header/ecabs-date-time-range-picker-header.component.scss +0 -5
  216. package/src/lib/ecabs-date-time-range-picker/components/ecabs-date-time-range-picker-header/ecabs-date-time-range-picker-header.component.spec.ts +0 -23
  217. package/src/lib/ecabs-date-time-range-picker/components/ecabs-date-time-range-picker-header/ecabs-date-time-range-picker-header.component.ts +0 -10
  218. package/src/lib/ecabs-date-time-range-picker/ecabs-date-time-range-picker.component.html +0 -116
  219. package/src/lib/ecabs-date-time-range-picker/ecabs-date-time-range-picker.component.scss +0 -43
  220. package/src/lib/ecabs-date-time-range-picker/ecabs-date-time-range-picker.component.spec.ts +0 -24
  221. package/src/lib/ecabs-date-time-range-picker/ecabs-date-time-range-picker.component.ts +0 -206
  222. package/src/lib/ecabs-date-time-range-picker/ecabs-date-time-range-picker.module.ts +0 -39
  223. package/src/lib/ecabs-date-time-range-picker/time-range.directive.ts +0 -38
  224. package/src/lib/ecabs-dialog-confirm/ecabs-dialog-confirm.component.html +0 -32
  225. package/src/lib/ecabs-dialog-confirm/ecabs-dialog-confirm.component.scss +0 -24
  226. package/src/lib/ecabs-dialog-confirm/ecabs-dialog-confirm.component.ts +0 -57
  227. package/src/lib/ecabs-dialog-confirm/ecabs-dialog-confirm.module.ts +0 -13
  228. package/src/lib/ecabs-dialog-message/ecabs-dialog-message.component.html +0 -27
  229. package/src/lib/ecabs-dialog-message/ecabs-dialog-message.component.scss +0 -25
  230. package/src/lib/ecabs-dialog-message/ecabs-dialog-message.component.spec.ts +0 -38
  231. package/src/lib/ecabs-dialog-message/ecabs-dialog-message.component.ts +0 -49
  232. package/src/lib/ecabs-dialog-message/ecabs-dialog-message.module.ts +0 -13
  233. package/src/lib/ecabs-empty-placeholder/ecabs-empty-placeholder.component.html +0 -9
  234. package/src/lib/ecabs-empty-placeholder/ecabs-empty-placeholder.component.scss +0 -0
  235. package/src/lib/ecabs-empty-placeholder/ecabs-empty-placeholder.component.spec.ts +0 -34
  236. package/src/lib/ecabs-empty-placeholder/ecabs-empty-placeholder.component.ts +0 -22
  237. package/src/lib/ecabs-empty-placeholder/ecabs-empty-placeholder.module.ts +0 -11
  238. package/src/lib/ecabs-expansion-panel/ecabs-expansion-panel.component.html +0 -33
  239. package/src/lib/ecabs-expansion-panel/ecabs-expansion-panel.component.scss +0 -79
  240. package/src/lib/ecabs-expansion-panel/ecabs-expansion-panel.component.spec.ts +0 -26
  241. package/src/lib/ecabs-expansion-panel/ecabs-expansion-panel.component.ts +0 -77
  242. package/src/lib/ecabs-expansion-panel/ecabs-expansion-panel.module.ts +0 -17
  243. package/src/lib/ecabs-increment/ecabs-increment.component.html +0 -18
  244. package/src/lib/ecabs-increment/ecabs-increment.component.scss +0 -33
  245. package/src/lib/ecabs-increment/ecabs-increment.component.ts +0 -74
  246. package/src/lib/ecabs-increment/ecabs-increment.module.ts +0 -15
  247. package/src/lib/ecabs-input/ecabs-input.component.html +0 -26
  248. package/src/lib/ecabs-input/ecabs-input.component.ts +0 -85
  249. package/src/lib/ecabs-input/ecabs-input.module.ts +0 -14
  250. package/src/lib/ecabs-language-selector/ecabs-language-selector.component.html +0 -17
  251. package/src/lib/ecabs-language-selector/ecabs-language-selector.component.scss +0 -26
  252. package/src/lib/ecabs-language-selector/ecabs-language-selector.component.ts +0 -63
  253. package/src/lib/ecabs-language-selector/ecabs-language-selector.module.ts +0 -22
  254. package/src/lib/ecabs-loading/ecabs-loading.component.html +0 -7
  255. package/src/lib/ecabs-loading/ecabs-loading.component.spec.ts +0 -24
  256. package/src/lib/ecabs-loading/ecabs-loading.component.ts +0 -11
  257. package/src/lib/ecabs-loading/ecabs-loading.module.ts +0 -11
  258. package/src/lib/ecabs-loading/spinner/spinner.component.html +0 -5
  259. package/src/lib/ecabs-loading/spinner/spinner.component.scss +0 -61
  260. package/src/lib/ecabs-loading/spinner/spinner.component.spec.ts +0 -24
  261. package/src/lib/ecabs-loading/spinner/spinner.component.ts +0 -11
  262. package/src/lib/ecabs-note/ecabs-note.component.html +0 -10
  263. package/src/lib/ecabs-note/ecabs-note.component.scss +0 -29
  264. package/src/lib/ecabs-note/ecabs-note.component.ts +0 -27
  265. package/src/lib/ecabs-note/ecabs-note.module.ts +0 -11
  266. package/src/lib/ecabs-phone/ecabs-phone.component.html +0 -17
  267. package/src/lib/ecabs-phone/ecabs-phone.component.ts +0 -108
  268. package/src/lib/ecabs-phone/ecabs-phone.module.ts +0 -15
  269. package/src/lib/ecabs-picker-header/ecabs-picker-header.component.html +0 -12
  270. package/src/lib/ecabs-picker-header/ecabs-picker-header.component.scss +0 -16
  271. package/src/lib/ecabs-picker-header/ecabs-picker-header.component.ts +0 -61
  272. package/src/lib/ecabs-picker-header/ecabs-picker-header.module.ts +0 -15
  273. package/src/lib/ecabs-radio-button-list/ecabs-radio-button-list.component.html +0 -13
  274. package/src/lib/ecabs-radio-button-list/ecabs-radio-button-list.component.scss +0 -16
  275. package/src/lib/ecabs-radio-button-list/ecabs-radio-button-list.component.ts +0 -60
  276. package/src/lib/ecabs-radio-button-list/ecabs-radio-button-list.module.ts +0 -18
  277. package/src/lib/ecabs-select/ecabs-select.component.html +0 -45
  278. package/src/lib/ecabs-select/ecabs-select.component.ts +0 -346
  279. package/src/lib/ecabs-select/ecabs-select.module.ts +0 -37
  280. package/src/lib/ecabs-table/ecabs-table-filter-wrapper/ecabs-table-filter-wrapper.component.html +0 -7
  281. package/src/lib/ecabs-table/ecabs-table-filter-wrapper/ecabs-table-filter-wrapper.component.scss +0 -11
  282. package/src/lib/ecabs-table/ecabs-table-filter-wrapper/ecabs-table-filter-wrapper.component.spec.ts +0 -34
  283. package/src/lib/ecabs-table/ecabs-table-filter-wrapper/ecabs-table-filter-wrapper.component.ts +0 -14
  284. package/src/lib/ecabs-table/ecabs-table-filter-wrapper/ecabs-table-filter-wrapper.module.ts +0 -14
  285. package/src/lib/ecabs-table/ecabs-table.component.html +0 -26
  286. package/src/lib/ecabs-table/ecabs-table.component.scss +0 -6
  287. package/src/lib/ecabs-table/ecabs-table.component.spec.ts +0 -24
  288. package/src/lib/ecabs-table/ecabs-table.component.ts +0 -42
  289. package/src/lib/ecabs-table/ecabs-table.module.ts +0 -19
  290. package/src/lib/ecabs-textarea/ecabs-textarea.component.html +0 -13
  291. package/src/lib/ecabs-textarea/ecabs-textarea.component.ts +0 -61
  292. package/src/lib/ecabs-textarea/ecabs-textarea.module.ts +0 -12
  293. package/src/lib/ecabs-timepicker/componets/ecabs-time-list-panel/ecabs-time-list-panel.component.html +0 -16
  294. package/src/lib/ecabs-timepicker/componets/ecabs-time-list-panel/ecabs-time-list-panel.component.ts +0 -126
  295. package/src/lib/ecabs-timepicker/config.model.ts +0 -5
  296. package/src/lib/ecabs-timepicker/ecabs-timepicker.component.html +0 -36
  297. package/src/lib/ecabs-timepicker/ecabs-timepicker.component.scss +0 -5
  298. package/src/lib/ecabs-timepicker/ecabs-timepicker.component.ts +0 -330
  299. package/src/lib/ecabs-timepicker/ecabs-timepicker.module.ts +0 -12
  300. package/src/lib/ecabs-timepicker/ecabs-timepicker.service.ts +0 -28
  301. package/src/lib/models/bread-crumb.ts +0 -5
  302. package/src/lib/services/ecabs-components.service.ts +0 -33
  303. package/src/styles/material/overrides/_icon.scss +0 -3
  304. package/src/test.ts +0 -27
  305. package/tailwind.config.js +0 -31
  306. package/tsconfig.lib.json +0 -15
  307. package/tsconfig.lib.prod.json +0 -10
  308. package/tsconfig.spec.json +0 -17
  309. /package/{src/public-api.ts → public-api.d.ts} +0 -0
  310. /package/{src/styles → styles}/material/_theme.scss +0 -0
  311. /package/{src/styles → styles}/material/overrides/_autocomplete.scss +0 -0
  312. /package/{src/styles → styles}/material/overrides/_card.scss +0 -0
  313. /package/{src/styles → styles}/material/overrides/_chip.scss +0 -0
  314. /package/{src/styles → styles}/material/overrides/_datepicker.scss +0 -0
  315. /package/{src/styles → styles}/material/overrides/_dialog.scss +0 -0
  316. /package/{src/styles → styles}/material/overrides/_divider.scss +0 -0
  317. /package/{src/styles → styles}/material/overrides/_expansion.scss +0 -0
  318. /package/{src/styles → styles}/material/overrides/_form.scss +0 -0
  319. /package/{src/styles → styles}/material/overrides/_menu.scss +0 -0
  320. /package/{src/styles → styles}/material/overrides/_paginator.scss +0 -0
  321. /package/{src/styles → styles}/material/overrides/_select.scss +0 -0
  322. /package/{src/styles → styles}/material/overrides/_tab.scss +0 -0
  323. /package/{src/styles → styles}/material/overrides/_table.scss +0 -0
  324. /package/{src/styles → styles}/material/overrides/_toaster.scss +0 -0
  325. /package/{src/styles → styles}/material/overrides/_toggle.scss +0 -0
  326. /package/{src/styles → styles}/material/overrides/_toolbar.scss +0 -0
  327. /package/{src/styles → styles}/material/overrides/_tooltip.scss +0 -0
  328. /package/{src/styles → styles}/material/overrides/index.scss +0 -0
  329. /package/{src/styles → styles}/scss/base/_heading.scss +0 -0
  330. /package/{src/styles → styles}/scss/base/_normalize.scss +0 -0
  331. /package/{src/styles → styles}/scss/base/index.scss +0 -0
  332. /package/{src/styles → styles}/scss/modules/_autocomplete.scss +0 -0
  333. /package/{src/styles → styles}/scss/modules/_button.scss +0 -0
  334. /package/{src/styles → styles}/scss/modules/_card.scss +0 -0
  335. /package/{src/styles → styles}/scss/modules/_chip.scss +0 -0
  336. /package/{src/styles → styles}/scss/modules/_datepicker.scss +0 -0
  337. /package/{src/styles → styles}/scss/modules/_dialog.scss +0 -0
  338. /package/{src/styles → styles}/scss/modules/_divider.scss +0 -0
  339. /package/{src/styles → styles}/scss/modules/_form.scss +0 -0
  340. /package/{src/styles → styles}/scss/modules/_icon.scss +0 -0
  341. /package/{src/styles → styles}/scss/modules/_img.scss +0 -0
  342. /package/{src/styles → styles}/scss/modules/_legend.scss +0 -0
  343. /package/{src/styles → styles}/scss/modules/_list.scss +0 -0
  344. /package/{src/styles → styles}/scss/modules/_map.scss +0 -0
  345. /package/{src/styles → styles}/scss/modules/_percentage.scss +0 -0
  346. /package/{src/styles → styles}/scss/modules/_phone.scss +0 -0
  347. /package/{src/styles → styles}/scss/modules/_select.scss +0 -0
  348. /package/{src/styles → styles}/scss/modules/_statuses.scss +0 -0
  349. /package/{src/styles → styles}/scss/modules/_tab.scss +0 -0
  350. /package/{src/styles → styles}/scss/modules/_table.scss +0 -0
  351. /package/{src/styles → styles}/scss/modules/_timepicker.scss +0 -0
  352. /package/{src/styles → styles}/scss/modules/_toaster.scss +0 -0
  353. /package/{src/styles → styles}/scss/modules/_tooltip.scss +0 -0
  354. /package/{src/styles → styles}/scss/modules/drag-drop.scss +0 -0
  355. /package/{src/styles → styles}/scss/modules/index.scss +0 -0
  356. /package/{src/styles → styles}/scss/utilities/_colors.scss +0 -0
  357. /package/{src/styles → styles}/scss/utilities/_fonts.scss +0 -0
  358. /package/{src/styles → styles}/scss/utilities/_functions.scss +0 -0
  359. /package/{src/styles → styles}/scss/utilities/_helpers.scss +0 -0
  360. /package/{src/styles → styles}/scss/utilities/_mixins.scss +0 -0
  361. /package/{src/styles → styles}/scss/utilities/_palettes.scss +0 -0
  362. /package/{src/styles → styles}/scss/utilities/_variables.scss +0 -0
  363. /package/{src/styles → styles}/scss/utilities/index.scss +0 -0
  364. /package/{src/styles → styles}/styles.scss +0 -0
  365. /package/{src/styles → styles}/tailwind/index.scss +0 -0
@@ -1,16 +0,0 @@
1
- <div class="list">
2
- <div class="inner-scroll">
3
- <div class="inner">
4
- <ul>
5
- <li
6
- *ngFor="let i of timeList; let counter = index"
7
- (click)="setTime(i.value)"
8
- (mouseenter)="hoveredItemIndex = counter"
9
- [ngClass]="{ active: typedValue === i.value, hovered: counter === hoveredItemIndex }"
10
- >
11
- {{ i.title }}
12
- </li>
13
- </ul>
14
- </div>
15
- </div>
16
- </div>
@@ -1,126 +0,0 @@
1
- import { Component, OnInit, Input, Output, EventEmitter, HostListener, ElementRef, OnChanges } from '@angular/core';
2
- import { ListPlacement, ListPosition } from '../../../models/timepicker.models';
3
- import { FormTimePickerService } from '../../ecabs-timepicker.service';
4
- @Component( {
5
- selector: 'ecabs-time-list-panel',
6
- templateUrl: './ecabs-time-list-panel.component.html',
7
- } )
8
- export class EcabsTimeListPanelComponent implements OnInit, OnChanges {
9
- @Input() typedValue: any;
10
- @Input() listPlacement: ListPlacement = 'auto';
11
- @Input() listPosition: ListPosition = {};
12
-
13
- @Input() appendTo!: string;
14
- @Input() min!: string;
15
- @Input() max!: string;
16
- @Input() showDayStart = true;
17
- @Input() showDayEnd = false;
18
- @Input() position: ListPosition = {};
19
-
20
- @Output() onscroll = new EventEmitter<{ start: number; end: number }>();
21
- @Output() closeMe = new EventEmitter<any>();
22
-
23
- hoveredItemIndex = 0;
24
- timeList: { value: any; title: string }[] = [];
25
-
26
- private listItemHeight!: any;
27
-
28
- constructor( private elementRef: ElementRef, private timepickerService: FormTimePickerService ) { }
29
-
30
- @HostListener( 'document:keydown', [ '$event' ] )
31
- handleKeydown( $event: KeyboardEvent ): void {
32
- if ( $event.key === 'ArrowUp' ) {
33
- // eslint-disable-next-line @typescript-eslint/no-unused-expressions
34
- this.hoveredItemIndex ? this.hoveredItemIndex-- : null;
35
- this.scrollTo( this.hoveredItemIndex );
36
- }
37
- if ( $event.key === 'ArrowDown' ) {
38
- // eslint-disable-next-line @typescript-eslint/no-unused-expressions
39
- this.hoveredItemIndex + 1 < this.timeList.length ? this.hoveredItemIndex++ : null;
40
- this.scrollTo( this.hoveredItemIndex );
41
- }
42
- if ( $event.key === 'Enter' ) {
43
- this.setTime( this.timeList[ this.hoveredItemIndex ].value );
44
- }
45
- }
46
-
47
- ngOnInit(): void {
48
- this.calcListItems();
49
- if ( this.appendTo ) {
50
- this.appendListTo();
51
- }
52
-
53
- setTimeout( () => {
54
- this.listItemHeight = this.elementRef.nativeElement.querySelector( 'li' ).getBoundingClientRect().height;
55
- this.selectTypedValue( this.typedValue );
56
- } );
57
- }
58
-
59
- appendListTo(): void {
60
- const parent = document.querySelector( this.appendTo );
61
- if ( !parent ) {
62
- throw new Error( `appendTo selector ${ this.appendTo } did not found any parent element` );
63
- }
64
- parent.appendChild( this.elementRef.nativeElement );
65
- }
66
-
67
- calcListItems(): void {
68
- if ( this.showDayStart ) {
69
- this.timeList.push( {
70
- value: '00:00',
71
- title: this.timepickerService.getConfig().dayStart,
72
- } );
73
- }
74
- for ( let index = 0; index < 24; index++ ) {
75
- for ( const minute of [ '00', '30' ] ) {
76
- if ( index === 0 && minute === '00' ) {
77
- continue;
78
- }
79
- this.timeList.push( {
80
- value: ( index > 9 ? index + '' : '0' + index ) + ':' + minute,
81
- title: ( index > 9 ? index + '' : '0' + index ) + ':' + minute,
82
- } );
83
- }
84
- }
85
- if ( this.showDayEnd ) {
86
- this.timeList.push( {
87
- value: '23:59',
88
- title: this.timepickerService.getConfig().dayEnd,
89
- } );
90
- }
91
- }
92
-
93
- ngOnChanges(): void {
94
- this.selectTypedValue( this.typedValue );
95
- if ( this.elementRef.nativeElement ) {
96
- this.elementRef.nativeElement.style.top = this.listPosition.top + 'px';
97
- this.elementRef.nativeElement.style.left = this.listPosition.left + 'px';
98
- this.elementRef.nativeElement.style.width = this.listPosition.width + 'px';
99
- if ( this.appendTo ) {
100
- this.elementRef.nativeElement.style.position = 'fixed';
101
- }
102
- }
103
- }
104
-
105
- selectTypedValue( value: any ): void {
106
- if ( value ) {
107
- const hour = parseInt( value.split( ':' )[ 0 ], 10 );
108
- if ( hour || hour === 0 ) {
109
- this.hoveredItemIndex = hour * 2;
110
- this.scrollTo( this.hoveredItemIndex );
111
- }
112
- }
113
- }
114
-
115
- scrollTo( index: number ): void {
116
- this.elementRef.nativeElement.querySelector( '.inner-scroll' ).scrollTop = index * this.listItemHeight;
117
- }
118
-
119
- close(): void {
120
- this.closeMe.emit( null );
121
- }
122
-
123
- setTime( value: any ): void {
124
- this.closeMe.emit( value );
125
- }
126
- }
@@ -1,5 +0,0 @@
1
- export interface FormTimePickerConfig {
2
- dayStart: string;
3
- dayEnd: string;
4
- iconClass: string;
5
- }
@@ -1,36 +0,0 @@
1
- <div class="timeInputWrapper" [ngClass]="{ disabled: disabled }">
2
- <app-element-wrapper
3
- [data]="getData()"
4
- [showCloseIcon]="showCloseIcon"
5
- [focusedFlag]="focusedFlag"
6
- (clear)="clearInput()"
7
- >
8
- <div class="timeInputFieldWrapper">
9
- <input
10
- type="text"
11
- class="form-field__input"
12
- [value]="data"
13
- [disabled]="disabled"
14
- (focus)="show()"
15
- (click)="show()"
16
- (keydown)="inputKeyDown($event)"
17
- [placeholder]="placeholder"
18
- />
19
- <div class="form-field__input--suffix" *ngIf="type !== 'number'">
20
- <ng-content select="mat-icon"></ng-content>
21
- </div>
22
- <ecabs-time-list-panel
23
- [typedValue]="data"
24
- *ngIf="focusedFlag"
25
- [showDayStart]="showDayStart"
26
- [showDayEnd]="showDayEnd"
27
- [min]="min"
28
- [max]="max"
29
- class="form-time-list"
30
- [appendTo]="appendTo"
31
- [listPosition]="listPosition"
32
- (closeMe)="close($event)"
33
- ></ecabs-time-list-panel>
34
- </div>
35
- </app-element-wrapper>
36
- </div>
@@ -1,5 +0,0 @@
1
- :host::ng-deep {
2
- .timeInputWrapper app-element-wrapper .form-field {
3
- margin-bottom: 0;
4
- }
5
- }
@@ -1,330 +0,0 @@
1
- import { Component, Input, HostBinding, HostListener, ElementRef, Injector, AfterViewInit } from '@angular/core';
2
- import { ControlValueAccessor, NG_VALUE_ACCESSOR, NgControl, UntypedFormControl } from '@angular/forms';
3
- import { FormTimePickerService } from './ecabs-timepicker.service';
4
- import ElementBaseComponent from '../base/element-base';
5
- import { ListPlacement, ListPosition } from '../models/timepicker.models';
6
-
7
- @Component( {
8
- selector: 'ecabs-timepicker',
9
- templateUrl: './ecabs-timepicker.component.html',
10
- styleUrls: [ 'ecabs-timepicker.component.scss' ],
11
- providers: [
12
- {
13
- provide: NG_VALUE_ACCESSOR,
14
- useExisting: EcabsTimepickerComponent,
15
- multi: true,
16
- },
17
- ],
18
- } )
19
- export class EcabsTimepickerComponent extends ElementBaseComponent implements ControlValueAccessor, AfterViewInit {
20
- @Input() showCloseIcon = true;
21
- @Input() @HostBinding( 'class.form-timepicker-focused' ) focusedFlag = false;
22
- @Input() listPlacement: ListPlacement = 'auto';
23
- @Input() appendTo!: string;
24
- @Input() min!: string;
25
- @Input() max!: string;
26
- @Input() showDayStart = true;
27
- @Input() showDayEnd = false;
28
- @Input() addSecond = true;
29
-
30
- position: ListPosition = {};
31
- _data = '';
32
- _timePicker;
33
- _input!: any;
34
- listPosition: ListPosition = {};
35
- caretPositionStart!: any;
36
- caretPositionEnd!: any;
37
-
38
- get data(): any {
39
- return this._data;
40
- }
41
-
42
- set data( value: any ) {
43
- this._data = value;
44
- if ( this._data.length === 5 ) {
45
- if ( this._data === '23:59' ) {
46
- this.onChangeFn( this._data + ( this.addSecond ? ':59' : '' ) );
47
- } else {
48
- this.onChangeFn( this._data + ( this.addSecond ? ':00' : '' ) );
49
- }
50
- } else if ( this._data === '' ) {
51
- this.onChangeFn( this._data );
52
- }
53
- }
54
-
55
- constructor(
56
- private elementRef: ElementRef,
57
- private timepickerService: FormTimePickerService,
58
- private injector: Injector
59
- ) {
60
- super();
61
- this.placeholder = '00:00';
62
- this._timePicker = this.elementRef.nativeElement;
63
- setTimeout( () => {
64
- this._input = this._timePicker.querySelector( 'input' );
65
- } );
66
- if ( !this.iconClass ) {
67
- this.iconClass = this.timepickerService.getConfig().iconClass;
68
- }
69
- }
70
-
71
- @HostListener( 'document:mousedown', [ '$event' ] )
72
- handleMousedown( $event: MouseEvent ): void {
73
- const target = $event.target as HTMLElement;
74
- if (
75
- target.closest( '.form-time-list' ) ||
76
- target.closest( '.timeInputWrapper' ) === this._timePicker.querySelector( '.timeInputWrapper' )
77
- ) {
78
- this._timePicker.querySelector( '.timeInputWrapper' ).focus();
79
-
80
- return;
81
- }
82
- if ( this.focusedFlag ) {
83
- this.close();
84
- }
85
- }
86
-
87
- ngAfterViewInit(): void {
88
- const ngControl: NgControl = this.injector.get( NgControl, null ) as NgControl;
89
- if ( ngControl ) {
90
- this.control = ngControl.control as UntypedFormControl;
91
- }
92
- }
93
-
94
- clearInput(): void {
95
- this.data = '';
96
- }
97
-
98
- calcListPosition(): void {
99
- const position = this._timePicker.querySelector( '.timeInputFieldWrapper' ).getBoundingClientRect();
100
- if ( this.appendTo ) {
101
- this.listPosition = {
102
- left: position.x,
103
- top: position.top + position.height,
104
- width: position.width,
105
- };
106
- } else {
107
- this.listPosition = {
108
- left: 0,
109
- top: position.height,
110
- width: position.width,
111
- };
112
- }
113
- }
114
-
115
- inputKeyDown( event: any ): boolean {
116
- this.caretPositionStart = event.target.selectionStart;
117
- this.caretPositionEnd = event.target.selectionEnd;
118
- const key = event.key;
119
- this.setCaretPosition( this._input );
120
- switch ( this.checkSpecialKeys( key, this.caretPositionStart, this.caretPositionEnd ) ) {
121
- case 'stop':
122
- return false;
123
-
124
- case 'tab':
125
- this.close();
126
-
127
- return false;
128
-
129
- case 'arrow':
130
- return false;
131
- }
132
-
133
- if ( this.checkUnUsedKeys( key ) ) {
134
- return false;
135
- }
136
-
137
- const newData =
138
- this.data.slice( 0, this.caretPositionStart ) + key + this.data.slice( this.caretPositionStart, this.data.length );
139
-
140
- if ( this.checkOutOfRangeNumber( newData ) ) {
141
- this.data = newData;
142
- this.caretPositionStart++;
143
- }
144
-
145
- if (
146
- this.caretPositionStart === this.data.length &&
147
- ( this.data.length === 2 || ( this.data.length === 1 && parseInt( this.data ) > 2 ) )
148
- ) {
149
- this.makeHourFull();
150
- this.data += ':';
151
- this.caretPositionStart++;
152
- }
153
-
154
- return false;
155
- }
156
-
157
- checkSpecialKeys( key: any, selectionStart: any, selectionEnd: any ): 'stop' | 'continue' | 'tab' | 'arrow' {
158
- if ( selectionStart !== selectionEnd && key !== 'ArrowLeft' && key !== 'ArrowRight' ) {
159
- if ( !( this.data.slice( selectionStart, selectionEnd ).includes( ':' ) && selectionEnd !== this.data.length ) ) {
160
- this.data = this.data.slice( 0, selectionStart ) + this.data.slice( selectionEnd, this.data.length );
161
- }
162
- }
163
- if ( selectionStart === selectionEnd && key === 'Backspace' ) {
164
- if ( this.data.length > 0 ) {
165
- if (
166
- this.data[ selectionStart - 1 ] !== ':' ||
167
- ( this.data[ selectionStart - 1 ] === ':' && selectionStart === this.data.length )
168
- ) {
169
- this.data = this.data.slice( 0, selectionStart - 1 ) + this.data.slice( selectionEnd, this.data.length );
170
- this.caretPositionStart--;
171
- }
172
- }
173
-
174
- return 'stop';
175
- }
176
- if ( key === 'Tab' || key === ' ' || key === ':' ) {
177
- if ( !this.data.includes( ':' ) && this.data.length > 0 ) {
178
- this.makeHourFull();
179
- this.data += ':';
180
- this.caretPositionStart++;
181
-
182
- return 'stop';
183
- }
184
- if ( key === 'Tab' ) {
185
- return 'tab';
186
- }
187
-
188
- return 'stop';
189
- }
190
- if ( key === 'ArrowRight' ) {
191
- if ( this.caretPositionStart < this.data.length ) {
192
- this.caretPositionStart++;
193
- }
194
-
195
- return 'arrow';
196
- }
197
- if ( key === 'ArrowLeft' ) {
198
- if ( this.caretPositionStart > 0 ) {
199
- this.caretPositionStart--;
200
- }
201
-
202
- return 'arrow';
203
- }
204
- if ( key === 'ArrowDown' && !this.focusedFlag ) {
205
- this.show();
206
- }
207
-
208
- return 'continue';
209
- }
210
-
211
- checkUnUsedKeys( key: string ): boolean {
212
- const r = new RegExp( '[0-9]' );
213
-
214
- return !r.test( key );
215
- }
216
-
217
- setCaretPosition( elem: any ): void {
218
- setTimeout( () => {
219
- if ( elem !== null ) {
220
- if ( elem.createTextRange ) {
221
- const range = elem.createTextRange();
222
- range.move( 'character', this.caretPositionStart );
223
- range.select();
224
- } else {
225
- if ( elem.selectionStart ) {
226
- elem.focus();
227
- elem.setSelectionRange( this.caretPositionStart, this.caretPositionStart );
228
- } else {
229
- elem.focus();
230
- }
231
- }
232
- }
233
- } );
234
- }
235
-
236
- checkOutOfRangeNumber( time: any ): boolean {
237
- const hour = parseInt( time.split( ':' )[ 0 ], 10 );
238
- let minute = -1;
239
- if ( time.split( ':' ).length > 1 ) {
240
- minute = parseInt( time.split( ':' )[ 1 ], 10 );
241
- }
242
- if ( hour < 24 && time.split( ':' )[ 0 ].length < 3 && minute < 60 ) {
243
- if ( time.split( ':' ).length > 1 && time.split( ':' )[ 1 ].length > 2 ) {
244
- return false;
245
- }
246
-
247
- return true;
248
- }
249
-
250
- return false;
251
- }
252
-
253
- makeHourFull(): void {
254
- const hourPart = this.data.split( ':' )[ 0 ];
255
- const minutePart = this.data.split( ':' ).length > 1 ? this.data.split( ':' )[ 1 ] : '';
256
- if ( hourPart.length === 1 ) {
257
- this.data = '0' + hourPart + ( minutePart ? ':' + minutePart : minutePart );
258
- this.caretPositionStart++;
259
- }
260
- }
261
-
262
- makeMinuteFull(): void {
263
- const hourPart = this.data.split( ':' )[ 0 ];
264
- const minutePart = this.data.split( ':' ).length > 1 ? this.data.split( ':' )[ 1 ] : '';
265
- if ( minutePart.length === 0 ) {
266
- this.data = hourPart + ':00';
267
- this.caretPositionStart += 2;
268
- }
269
- if ( minutePart.length === 1 ) {
270
- this.data = hourPart + ':' + minutePart + '0';
271
- this.caretPositionStart++;
272
- }
273
- }
274
-
275
- fixTimeToNearest(): void {
276
- if ( this.data.length > 0 ) {
277
- this.makeHourFull();
278
- this.makeMinuteFull();
279
- }
280
- }
281
-
282
- //eslint-disable-next-line @typescript-eslint/no-unused-vars, no-unused-vars, @typescript-eslint/no-empty-function
283
- public onChangeFn = ( _: any ): void => { };
284
- // eslint-disable-next-line @typescript-eslint/no-empty-function
285
- public onTouchedFn = (): void => { };
286
-
287
- public registerOnChange( fn: any ): void {
288
- this.onChangeFn = fn;
289
- }
290
-
291
- public registerOnTouched( fn: any ): void {
292
- this.onTouchedFn = fn;
293
- }
294
-
295
- public setDisabledState( isDisabled: boolean ): void {
296
- this.disabled = isDisabled;
297
- }
298
-
299
- public writeValue( obj: any ): void {
300
- if ( obj ) {
301
- obj = obj.toString();
302
- let temp = '';
303
- if ( obj.split( ':' ).length >= 2 ) {
304
- temp = obj.split( ':' )[ 0 ] + ':' + obj.split( ':' )[ 1 ];
305
- }
306
- this._data = temp;
307
- } else {
308
- this._data = '';
309
- }
310
- }
311
-
312
- public onChange(): void {
313
- this.onChangeFn( this.data );
314
- }
315
-
316
- show(): void {
317
- this.calcListPosition();
318
- this.focusedFlag = true;
319
- }
320
-
321
- close( val = null ): void {
322
- if ( val ) {
323
- this.data = val;
324
- } else {
325
- this.fixTimeToNearest();
326
- }
327
- this.focusedFlag = false;
328
- this.control?.markAsTouched();
329
- }
330
- }
@@ -1,12 +0,0 @@
1
- import { NgModule } from '@angular/core';
2
- import { CommonModule } from '@angular/common';
3
- import { EcabsTimepickerComponent } from './ecabs-timepicker.component';
4
- import { EcabsTimeListPanelComponent } from './componets/ecabs-time-list-panel/ecabs-time-list-panel.component';
5
- import { ElementWrapperModule } from '../base/element-wrapper/element-wrapper.module';
6
-
7
- @NgModule( {
8
- declarations: [ EcabsTimepickerComponent, EcabsTimeListPanelComponent ],
9
- imports: [ CommonModule, ElementWrapperModule ],
10
- exports: [ EcabsTimeListPanelComponent, EcabsTimepickerComponent ],
11
- } )
12
- export class EcabsTimepickerModule { }
@@ -1,28 +0,0 @@
1
- import { Injectable } from '@angular/core';
2
- import { Subject } from 'rxjs';
3
- import { FormTimePickerConfig } from './config.model';
4
-
5
- @Injectable({
6
- providedIn: 'root',
7
- })
8
- export class FormTimePickerService {
9
- config: FormTimePickerConfig = {
10
- dayEnd: 'Day End',
11
- dayStart: 'Day Start',
12
- iconClass: '',
13
- };
14
-
15
- public closeSub = new Subject<boolean>();
16
-
17
- setConfig(c: FormTimePickerConfig): void {
18
- this.config = Object.assign(this.config, c);
19
- }
20
-
21
- getConfig(): FormTimePickerConfig {
22
- return this.config;
23
- }
24
-
25
- close(): void {
26
- this.closeSub.next(true);
27
- }
28
- }
@@ -1,5 +0,0 @@
1
- export interface BreadCrumb {
2
- title: string;
3
- url?: string;
4
- icon?: string;
5
- }
@@ -1,33 +0,0 @@
1
- import { Injectable } from '@angular/core';
2
-
3
- @Injectable({
4
- providedIn: 'root',
5
- })
6
- export class EcabsComponentsService {
7
- config: EcabsComponentsConfig = {
8
- errorMessages: [
9
- { type: 'required', message: '[label] is required' },
10
- { type: 'minlength', message: '[label] should be atleast [requiredLength] character' },
11
- { type: 'maxLength', message: '[label] should be maximum [requiredLength] character' },
12
- { type: 'min', message: '[label] should be minmum [min]' },
13
- { type: 'max', message: '[label] should be maximum [max]' },
14
- { type: 'minValue', message: '[label] should be minmum [requiredMin]' },
15
- { type: 'maxValue', message: '[label] should be maximum [requiredMax]' },
16
- ],
17
- };
18
- constructor() {}
19
- setConfig(c: EcabsComponentsConfig) {
20
- this.config.errorMessages = c.errorMessages;
21
- }
22
- getConfig(): EcabsComponentsConfig {
23
- return this.config;
24
- }
25
- }
26
-
27
- export interface EcabsComponentsConfig {
28
- errorMessages: ErrorMessage[];
29
- }
30
- export interface ErrorMessage {
31
- type: string;
32
- message: string;
33
- }
@@ -1,3 +0,0 @@
1
- mat-icon {
2
- @extend .icon;
3
- }
package/src/test.ts DELETED
@@ -1,27 +0,0 @@
1
- // This file is required by karma.conf.js and loads recursively all the .spec and framework files
2
-
3
- import 'zone.js';
4
- import 'zone.js/testing';
5
- import { getTestBed } from '@angular/core/testing';
6
- import {
7
- BrowserDynamicTestingModule,
8
- platformBrowserDynamicTesting
9
- } from '@angular/platform-browser-dynamic/testing';
10
-
11
- declare const require: {
12
- context(path: string, deep?: boolean, filter?: RegExp): {
13
- <T>(id: string): T;
14
- keys(): string[];
15
- };
16
- };
17
-
18
- // First, initialize the Angular testing environment.
19
- getTestBed().initTestEnvironment(
20
- BrowserDynamicTestingModule,
21
- platformBrowserDynamicTesting(),
22
- );
23
-
24
- // Then we find all the tests.
25
- const context = require.context('./', true, /\.spec\.ts$/);
26
- // And load the modules.
27
- context.keys().forEach(context);
@@ -1,31 +0,0 @@
1
- module.exports = {
2
- content: ['./src/**/*.{html,ts}'],
3
- theme: {
4
- extend: {
5
- colors: {
6
- black: 'var(--color-black)',
7
- gray: {
8
- 100: 'var(--color-gray-100)',
9
- 200: 'var(--color-gray-200)',
10
- 300: 'var(--color-gray-300)',
11
- 400: 'var(--color-gray-400)',
12
- 500: 'var(--color-gray-500)',
13
- },
14
- brand: {
15
- dark: 'var(--color-brand-dark)',
16
- light: 'var(--color-brand-light)',
17
- 300: 'var(--color-brand-300)',
18
- },
19
- accent: {
20
- error: 'var(--color-error)',
21
- notification: 'var(--color-notification)',
22
- success: 'var(--color-success)',
23
- },
24
- },
25
- lineHeight: {
26
- 0: '0',
27
- },
28
- },
29
- },
30
- plugins: [],
31
- };
package/tsconfig.lib.json DELETED
@@ -1,15 +0,0 @@
1
- /* To learn more about this file see: https://angular.io/config/tsconfig. */
2
- {
3
- "extends": "../../tsconfig.json",
4
- "compilerOptions": {
5
- "outDir": "../../out-tsc/lib",
6
- "declaration": true,
7
- "declarationMap": true,
8
- "inlineSources": true,
9
- "types": []
10
- },
11
- "exclude": [
12
- "src/test.ts",
13
- "**/*.spec.ts"
14
- ]
15
- }