monkey-front-components 0.0.384 → 0.0.387

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 (276) hide show
  1. package/esm2020/lib/components/base/base-component.mjs +322 -0
  2. package/esm2020/lib/components/base/base-dynamic-array.mjs +221 -0
  3. package/esm2020/lib/components/base/base-dynamic.mjs +99 -0
  4. package/esm2020/lib/components/base/base-scroll-component.mjs +55 -0
  5. package/esm2020/lib/components/base/base-validators.mjs +19 -0
  6. package/esm2020/lib/components/base/index.mjs +6 -0
  7. package/esm2020/lib/components/dynamic/button/button.component.mjs +52 -0
  8. package/esm2020/lib/components/dynamic/button/index.mjs +2 -0
  9. package/esm2020/lib/components/dynamic/dynamic-directive.mjs +95 -0
  10. package/esm2020/lib/components/dynamic/dynamic.module.mjs +84 -0
  11. package/esm2020/lib/components/dynamic/file-upload/file-upload.component.mjs +52 -0
  12. package/esm2020/lib/components/dynamic/file-upload/index.mjs +2 -0
  13. package/esm2020/lib/components/dynamic/form/dynamic-form-array.component.mjs +72 -0
  14. package/esm2020/lib/components/dynamic/form/dynamic-form.component.mjs +46 -0
  15. package/esm2020/lib/components/dynamic/form/index.mjs +3 -0
  16. package/esm2020/lib/components/dynamic/index.mjs +9 -0
  17. package/esm2020/lib/components/dynamic/input/index.mjs +2 -0
  18. package/esm2020/lib/components/dynamic/input/input.component.mjs +65 -0
  19. package/esm2020/lib/components/dynamic/input-phone/index.mjs +2 -0
  20. package/esm2020/lib/components/dynamic/input-phone/input-phone.component.mjs +65 -0
  21. package/esm2020/lib/components/dynamic/radio/index.mjs +2 -0
  22. package/esm2020/lib/components/dynamic/radio/radio.component.mjs +33 -0
  23. package/esm2020/lib/components/dynamic/select/index.mjs +2 -0
  24. package/esm2020/lib/components/dynamic/select/select.component.mjs +80 -0
  25. package/esm2020/lib/components/dynamic/select-search/index.mjs +2 -0
  26. package/esm2020/lib/components/dynamic/select-search/select-search.component.mjs +80 -0
  27. package/esm2020/lib/components/index.mjs +4 -0
  28. package/esm2020/lib/components/shared/filter/filter.component.mjs +119 -0
  29. package/esm2020/lib/components/shared/filter/filter.module.mjs +63 -0
  30. package/esm2020/lib/components/shared/filter/index.mjs +3 -0
  31. package/esm2020/lib/components/shared/filter/menu/index.mjs +2 -0
  32. package/esm2020/lib/components/shared/filter/menu/menu.component.mjs +120 -0
  33. package/esm2020/lib/components/shared/filter/menu/menu.module.mjs +70 -0
  34. package/esm2020/lib/components/shared/filter/options/children/children.component.mjs +50 -0
  35. package/esm2020/lib/components/shared/filter/options/children/index.mjs +2 -0
  36. package/esm2020/lib/components/shared/filter/options/currency/currency.component.mjs +46 -0
  37. package/esm2020/lib/components/shared/filter/options/currency/index.mjs +2 -0
  38. package/esm2020/lib/components/shared/filter/options/date-range/date-range.component.mjs +65 -0
  39. package/esm2020/lib/components/shared/filter/options/date-range/index.mjs +2 -0
  40. package/esm2020/lib/components/shared/filter/options/index.mjs +2 -0
  41. package/esm2020/lib/components/shared/filter/options/input/index.mjs +2 -0
  42. package/esm2020/lib/components/shared/filter/options/input/input.component.mjs +46 -0
  43. package/esm2020/lib/components/shared/filter/options/options.component.mjs +68 -0
  44. package/esm2020/lib/components/shared/filter/options/options.module.mjs +95 -0
  45. package/esm2020/lib/components/shared/filter/options/status/index.mjs +2 -0
  46. package/esm2020/lib/components/shared/filter/options/status/status.component.mjs +66 -0
  47. package/esm2020/lib/components/shared/filter/selected/index.mjs +2 -0
  48. package/esm2020/lib/components/shared/filter/selected/item/children/children.component.mjs +57 -0
  49. package/esm2020/lib/components/shared/filter/selected/item/children/index.mjs +2 -0
  50. package/esm2020/lib/components/shared/filter/selected/item/currency/currency.component.mjs +29 -0
  51. package/esm2020/lib/components/shared/filter/selected/item/currency/index.mjs +2 -0
  52. package/esm2020/lib/components/shared/filter/selected/item/date-range/date-range.component.mjs +42 -0
  53. package/esm2020/lib/components/shared/filter/selected/item/date-range/index.mjs +2 -0
  54. package/esm2020/lib/components/shared/filter/selected/item/date-with-action/date-with-action.component.mjs +33 -0
  55. package/esm2020/lib/components/shared/filter/selected/item/date-with-action/index.mjs +2 -0
  56. package/esm2020/lib/components/shared/filter/selected/item/index.mjs +8 -0
  57. package/esm2020/lib/components/shared/filter/selected/item/input/index.mjs +2 -0
  58. package/esm2020/lib/components/shared/filter/selected/item/input/input.component.mjs +28 -0
  59. package/esm2020/lib/components/shared/filter/selected/item/item.component.mjs +74 -0
  60. package/esm2020/lib/components/shared/filter/selected/item/status/index.mjs +2 -0
  61. package/esm2020/lib/components/shared/filter/selected/item/status/status.component.mjs +39 -0
  62. package/esm2020/lib/components/shared/filter/selected/selected.component.mjs +80 -0
  63. package/esm2020/lib/components/shared/filter/selected/selected.module.mjs +90 -0
  64. package/esm2020/lib/components/shared/index.mjs +5 -0
  65. package/esm2020/lib/components/shared/password-strength/index.mjs +3 -0
  66. package/esm2020/lib/components/shared/password-strength/password-strength.component.mjs +85 -0
  67. package/esm2020/lib/components/shared/password-strength/password-strength.mjs +2 -0
  68. package/esm2020/lib/components/shared/password-strength/password-strength.module.mjs +50 -0
  69. package/esm2020/lib/components/shared/products/filter/filter.component.mjs +36 -0
  70. package/esm2020/lib/components/shared/products/index.mjs +3 -0
  71. package/esm2020/lib/components/shared/products/products.component.mjs +91 -0
  72. package/esm2020/lib/components/shared/products/products.module.mjs +22 -0
  73. package/esm2020/lib/components/shared/products/providers/index.mjs +2 -0
  74. package/esm2020/lib/components/shared/products/providers/products.model.mjs +38 -0
  75. package/esm2020/lib/components/shared/progress-bar/index.mjs +4 -0
  76. package/esm2020/lib/components/shared/progress-bar/progress-bar.component.mjs +28 -0
  77. package/esm2020/lib/components/shared/progress-bar/progress-bar.module.mjs +18 -0
  78. package/esm2020/lib/components/shared/progress-bar/progress-bar.service.mjs +49 -0
  79. package/esm2020/lib/interfaces/field-config.mjs +2 -0
  80. package/esm2020/lib/interfaces/index.mjs +2 -0
  81. package/esm2020/monkey-front-components.mjs +5 -0
  82. package/esm2020/public-api.mjs +5 -0
  83. package/fesm2015/monkey-front-components.mjs +2877 -0
  84. package/fesm2015/monkey-front-components.mjs.map +1 -0
  85. package/fesm2020/monkey-front-components.mjs +2859 -0
  86. package/fesm2020/monkey-front-components.mjs.map +1 -0
  87. package/lib/components/base/base-component.d.ts +50 -0
  88. package/lib/components/base/base-dynamic-array.d.ts +34 -0
  89. package/lib/components/base/base-dynamic.d.ts +24 -0
  90. package/lib/components/base/base-scroll-component.d.ts +16 -0
  91. package/lib/components/base/base-validators.d.ts +1 -0
  92. package/{src/lib/components/base/index.ts → lib/components/base/index.d.ts} +5 -5
  93. package/lib/components/dynamic/button/button.component.d.ts +17 -0
  94. package/{src/lib/components/dynamic/button/index.ts → lib/components/dynamic/button/index.d.ts} +1 -1
  95. package/lib/components/dynamic/dynamic-directive.d.ts +22 -0
  96. package/lib/components/dynamic/dynamic.module.d.ts +20 -0
  97. package/lib/components/dynamic/file-upload/file-upload.component.d.ts +17 -0
  98. package/{src/lib/components/dynamic/file-upload/index.ts → lib/components/dynamic/file-upload/index.d.ts} +1 -1
  99. package/lib/components/dynamic/form/dynamic-form-array.component.d.ts +16 -0
  100. package/lib/components/dynamic/form/dynamic-form.component.d.ts +14 -0
  101. package/{src/lib/components/dynamic/form/index.ts → lib/components/dynamic/form/index.d.ts} +2 -2
  102. package/{src/lib/components/dynamic/index.ts → lib/components/dynamic/index.d.ts} +8 -8
  103. package/{src/lib/components/dynamic/input/index.ts → lib/components/dynamic/input/index.d.ts} +1 -1
  104. package/lib/components/dynamic/input/input.component.d.ts +20 -0
  105. package/{src/lib/components/dynamic/input-phone/index.ts → lib/components/dynamic/input-phone/index.d.ts} +1 -1
  106. package/lib/components/dynamic/input-phone/input-phone.component.d.ts +20 -0
  107. package/{src/lib/components/dynamic/radio/index.ts → lib/components/dynamic/radio/index.d.ts} +1 -1
  108. package/lib/components/dynamic/radio/radio.component.d.ts +11 -0
  109. package/{src/lib/components/dynamic/select/index.ts → lib/components/dynamic/select/index.d.ts} +1 -1
  110. package/lib/components/dynamic/select/select.component.d.ts +16 -0
  111. package/{src/lib/components/dynamic/select-search/index.ts → lib/components/dynamic/select-search/index.d.ts} +1 -1
  112. package/lib/components/dynamic/select-search/select-search.component.d.ts +16 -0
  113. package/{src/lib/components/index.ts → lib/components/index.d.ts} +3 -3
  114. package/lib/components/shared/filter/filter.component.d.ts +32 -0
  115. package/lib/components/shared/filter/filter.module.d.ts +14 -0
  116. package/{src/lib/components/shared/filter/index.ts → lib/components/shared/filter/index.d.ts} +2 -2
  117. package/{src/lib/components/shared/filter/menu/index.ts → lib/components/shared/filter/menu/index.d.ts} +1 -1
  118. package/lib/components/shared/filter/menu/menu.component.d.ts +24 -0
  119. package/lib/components/shared/filter/menu/menu.module.d.ts +14 -0
  120. package/lib/components/shared/filter/options/children/children.component.d.ts +17 -0
  121. package/{src/lib/components/shared/filter/options/children/index.ts → lib/components/shared/filter/options/children/index.d.ts} +1 -1
  122. package/lib/components/shared/filter/options/currency/currency.component.d.ts +17 -0
  123. package/{src/lib/components/shared/filter/options/currency/index.ts → lib/components/shared/filter/options/currency/index.d.ts} +1 -1
  124. package/lib/components/shared/filter/options/date-range/date-range.component.d.ts +24 -0
  125. package/{src/lib/components/shared/filter/options/date-range/index.ts → lib/components/shared/filter/options/date-range/index.d.ts} +1 -1
  126. package/{src/lib/components/shared/filter/options/index.ts → lib/components/shared/filter/options/index.d.ts} +1 -1
  127. package/{src/lib/components/shared/filter/options/input/index.ts → lib/components/shared/filter/options/input/index.d.ts} +1 -1
  128. package/lib/components/shared/filter/options/input/input.component.d.ts +17 -0
  129. package/lib/components/shared/filter/options/options.component.d.ts +20 -0
  130. package/lib/components/shared/filter/options/options.module.d.ts +18 -0
  131. package/{src/lib/components/shared/filter/options/status/index.ts → lib/components/shared/filter/options/status/index.d.ts} +1 -1
  132. package/lib/components/shared/filter/options/status/status.component.d.ts +19 -0
  133. package/{src/lib/components/shared/filter/selected/index.ts → lib/components/shared/filter/selected/index.d.ts} +1 -1
  134. package/lib/components/shared/filter/selected/item/children/children.component.d.ts +16 -0
  135. package/{src/lib/components/shared/filter/selected/item/children/index.ts → lib/components/shared/filter/selected/item/children/index.d.ts} +1 -1
  136. package/lib/components/shared/filter/selected/item/currency/currency.component.d.ts +11 -0
  137. package/{src/lib/components/shared/filter/selected/item/currency/index.ts → lib/components/shared/filter/selected/item/currency/index.d.ts} +1 -1
  138. package/lib/components/shared/filter/selected/item/date-range/date-range.component.d.ts +12 -0
  139. package/{src/lib/components/shared/filter/selected/item/date-range/index.ts → lib/components/shared/filter/selected/item/date-range/index.d.ts} +1 -1
  140. package/lib/components/shared/filter/selected/item/date-with-action/date-with-action.component.d.ts +11 -0
  141. package/{src/lib/components/shared/filter/selected/item/date-with-action/index.ts → lib/components/shared/filter/selected/item/date-with-action/index.d.ts} +1 -1
  142. package/{src/lib/components/shared/filter/selected/item/index.ts → lib/components/shared/filter/selected/item/index.d.ts} +7 -7
  143. package/{src/lib/components/shared/filter/selected/item/input/index.ts → lib/components/shared/filter/selected/item/input/index.d.ts} +1 -1
  144. package/lib/components/shared/filter/selected/item/input/input.component.d.ts +11 -0
  145. package/lib/components/shared/filter/selected/item/item.component.d.ts +20 -0
  146. package/{src/lib/components/shared/filter/selected/item/status/index.ts → lib/components/shared/filter/selected/item/status/index.d.ts} +1 -1
  147. package/lib/components/shared/filter/selected/item/status/status.component.d.ts +13 -0
  148. package/lib/components/shared/filter/selected/selected.component.d.ts +18 -0
  149. package/lib/components/shared/filter/selected/selected.module.d.ts +21 -0
  150. package/{src/lib/components/shared/index.ts → lib/components/shared/index.d.ts} +4 -4
  151. package/{src/lib/components/shared/password-strength/index.ts → lib/components/shared/password-strength/index.d.ts} +2 -2
  152. package/lib/components/shared/password-strength/password-strength.component.d.ts +23 -0
  153. package/lib/components/shared/password-strength/password-strength.d.ts +5 -0
  154. package/lib/components/shared/password-strength/password-strength.module.d.ts +12 -0
  155. package/lib/components/shared/products/filter/filter.component.d.ts +12 -0
  156. package/{src/lib/components/shared/products/index.ts → lib/components/shared/products/index.d.ts} +2 -2
  157. package/lib/components/shared/products/products.component.d.ts +20 -0
  158. package/lib/components/shared/products/products.module.d.ts +11 -0
  159. package/{src/lib/components/shared/products/providers/index.ts → lib/components/shared/products/providers/index.d.ts} +1 -1
  160. package/lib/components/shared/products/providers/products.model.d.ts +13 -0
  161. package/{src/lib/components/shared/progress-bar/index.ts → lib/components/shared/progress-bar/index.d.ts} +3 -3
  162. package/lib/components/shared/progress-bar/progress-bar.component.d.ts +12 -0
  163. package/lib/components/shared/progress-bar/progress-bar.module.d.ts +8 -0
  164. package/lib/components/shared/progress-bar/progress-bar.service.d.ts +14 -0
  165. package/lib/interfaces/field-config.d.ts +54 -0
  166. package/{src/lib/interfaces/index.ts → lib/interfaces/index.d.ts} +1 -1
  167. package/monkey-front-components-0.0.387.tgz +0 -0
  168. package/monkey-front-components.d.ts +5 -0
  169. package/package.json +25 -5
  170. package/public-api.d.ts +1 -0
  171. package/karma.conf.js +0 -44
  172. package/monkey-front-components-0.0.384.tgz +0 -0
  173. package/ng-package.json +0 -10
  174. package/src/lib/components/base/base-component.ts +0 -359
  175. package/src/lib/components/base/base-dynamic-array.ts +0 -233
  176. package/src/lib/components/base/base-dynamic.ts +0 -90
  177. package/src/lib/components/base/base-scroll-component.ts +0 -52
  178. package/src/lib/components/base/base-validators.ts +0 -19
  179. package/src/lib/components/dynamic/button/button.component.html +0 -4
  180. package/src/lib/components/dynamic/button/button.component.scss +0 -7
  181. package/src/lib/components/dynamic/button/button.component.ts +0 -47
  182. package/src/lib/components/dynamic/dynamic-directive.ts +0 -102
  183. package/src/lib/components/dynamic/dynamic.module.ts +0 -53
  184. package/src/lib/components/dynamic/file-upload/file-upload.component.html +0 -10
  185. package/src/lib/components/dynamic/file-upload/file-upload.component.ts +0 -46
  186. package/src/lib/components/dynamic/form/dynamic-form-array.component.html +0 -19
  187. package/src/lib/components/dynamic/form/dynamic-form-array.component.scss +0 -10
  188. package/src/lib/components/dynamic/form/dynamic-form-array.component.ts +0 -75
  189. package/src/lib/components/dynamic/form/dynamic-form.component.html +0 -7
  190. package/src/lib/components/dynamic/form/dynamic-form.component.ts +0 -49
  191. package/src/lib/components/dynamic/input/input.component.html +0 -9
  192. package/src/lib/components/dynamic/input/input.component.ts +0 -58
  193. package/src/lib/components/dynamic/input-phone/input-phone.component.html +0 -7
  194. package/src/lib/components/dynamic/input-phone/input-phone.component.ts +0 -58
  195. package/src/lib/components/dynamic/radio/radio.component.html +0 -8
  196. package/src/lib/components/dynamic/radio/radio.component.ts +0 -22
  197. package/src/lib/components/dynamic/select/select.component.html +0 -14
  198. package/src/lib/components/dynamic/select/select.component.ts +0 -75
  199. package/src/lib/components/dynamic/select-search/select-search.component.html +0 -15
  200. package/src/lib/components/dynamic/select-search/select-search.component.ts +0 -76
  201. package/src/lib/components/shared/filter/filter.component.html +0 -51
  202. package/src/lib/components/shared/filter/filter.component.scss +0 -79
  203. package/src/lib/components/shared/filter/filter.component.ts +0 -117
  204. package/src/lib/components/shared/filter/filter.module.ts +0 -36
  205. package/src/lib/components/shared/filter/menu/menu.component.html +0 -28
  206. package/src/lib/components/shared/filter/menu/menu.component.scss +0 -62
  207. package/src/lib/components/shared/filter/menu/menu.component.ts +0 -122
  208. package/src/lib/components/shared/filter/menu/menu.module.ts +0 -41
  209. package/src/lib/components/shared/filter/options/children/children.component.html +0 -6
  210. package/src/lib/components/shared/filter/options/children/children.component.scss +0 -30
  211. package/src/lib/components/shared/filter/options/children/children.component.ts +0 -58
  212. package/src/lib/components/shared/filter/options/currency/currency.component.html +0 -3
  213. package/src/lib/components/shared/filter/options/currency/currency.component.scss +0 -19
  214. package/src/lib/components/shared/filter/options/currency/currency.component.ts +0 -52
  215. package/src/lib/components/shared/filter/options/date-range/date-range.component.html +0 -3
  216. package/src/lib/components/shared/filter/options/date-range/date-range.component.scss +0 -34
  217. package/src/lib/components/shared/filter/options/date-range/date-range.component.ts +0 -72
  218. package/src/lib/components/shared/filter/options/input/input.component.html +0 -3
  219. package/src/lib/components/shared/filter/options/input/input.component.scss +0 -19
  220. package/src/lib/components/shared/filter/options/input/input.component.ts +0 -52
  221. package/src/lib/components/shared/filter/options/options.component.html +0 -43
  222. package/src/lib/components/shared/filter/options/options.component.scss +0 -56
  223. package/src/lib/components/shared/filter/options/options.component.ts +0 -58
  224. package/src/lib/components/shared/filter/options/options.module.ts +0 -58
  225. package/src/lib/components/shared/filter/options/status/status.component.html +0 -4
  226. package/src/lib/components/shared/filter/options/status/status.component.scss +0 -29
  227. package/src/lib/components/shared/filter/options/status/status.component.ts +0 -73
  228. package/src/lib/components/shared/filter/selected/item/children/children.component.html +0 -19
  229. package/src/lib/components/shared/filter/selected/item/children/children.component.scss +0 -68
  230. package/src/lib/components/shared/filter/selected/item/children/children.component.ts +0 -49
  231. package/src/lib/components/shared/filter/selected/item/currency/currency.component.html +0 -1
  232. package/src/lib/components/shared/filter/selected/item/currency/currency.component.scss +0 -4
  233. package/src/lib/components/shared/filter/selected/item/currency/currency.component.ts +0 -26
  234. package/src/lib/components/shared/filter/selected/item/date-range/date-range.component.html +0 -2
  235. package/src/lib/components/shared/filter/selected/item/date-range/date-range.component.scss +0 -4
  236. package/src/lib/components/shared/filter/selected/item/date-range/date-range.component.ts +0 -39
  237. package/src/lib/components/shared/filter/selected/item/date-with-action/date-with-action.component.html +0 -1
  238. package/src/lib/components/shared/filter/selected/item/date-with-action/date-with-action.component.scss +0 -4
  239. package/src/lib/components/shared/filter/selected/item/date-with-action/date-with-action.component.ts +0 -29
  240. package/src/lib/components/shared/filter/selected/item/input/input.component.html +0 -1
  241. package/src/lib/components/shared/filter/selected/item/input/input.component.scss +0 -4
  242. package/src/lib/components/shared/filter/selected/item/input/input.component.ts +0 -26
  243. package/src/lib/components/shared/filter/selected/item/item.component.html +0 -38
  244. package/src/lib/components/shared/filter/selected/item/item.component.scss +0 -72
  245. package/src/lib/components/shared/filter/selected/item/item.component.ts +0 -71
  246. package/src/lib/components/shared/filter/selected/item/status/status.component.html +0 -1
  247. package/src/lib/components/shared/filter/selected/item/status/status.component.scss +0 -4
  248. package/src/lib/components/shared/filter/selected/item/status/status.component.ts +0 -36
  249. package/src/lib/components/shared/filter/selected/selected.component.html +0 -3
  250. package/src/lib/components/shared/filter/selected/selected.component.scss +0 -9
  251. package/src/lib/components/shared/filter/selected/selected.component.ts +0 -76
  252. package/src/lib/components/shared/filter/selected/selected.module.ts +0 -60
  253. package/src/lib/components/shared/password-strength/password-strength.component.html +0 -50
  254. package/src/lib/components/shared/password-strength/password-strength.component.scss +0 -70
  255. package/src/lib/components/shared/password-strength/password-strength.component.ts +0 -89
  256. package/src/lib/components/shared/password-strength/password-strength.module.ts +0 -24
  257. package/src/lib/components/shared/password-strength/password-strength.ts +0 -5
  258. package/src/lib/components/shared/products/filter/filter.component.html +0 -6
  259. package/src/lib/components/shared/products/filter/filter.component.scss +0 -20
  260. package/src/lib/components/shared/products/filter/filter.component.ts +0 -34
  261. package/src/lib/components/shared/products/products.component.html +0 -15
  262. package/src/lib/components/shared/products/products.component.scss +0 -70
  263. package/src/lib/components/shared/products/products.component.ts +0 -104
  264. package/src/lib/components/shared/products/products.module.ts +0 -13
  265. package/src/lib/components/shared/products/providers/products.model.ts +0 -60
  266. package/src/lib/components/shared/progress-bar/progress-bar.component.html +0 -3
  267. package/src/lib/components/shared/progress-bar/progress-bar.component.scss +0 -6
  268. package/src/lib/components/shared/progress-bar/progress-bar.component.ts +0 -27
  269. package/src/lib/components/shared/progress-bar/progress-bar.module.ts +0 -10
  270. package/src/lib/components/shared/progress-bar/progress-bar.service.ts +0 -59
  271. package/src/lib/interfaces/field-config.ts +0 -58
  272. package/src/public-api.ts +0 -5
  273. package/src/test.ts +0 -26
  274. package/tsconfig.lib.json +0 -20
  275. package/tsconfig.lib.prod.json +0 -10
  276. package/tsconfig.spec.json +0 -17
@@ -1,22 +0,0 @@
1
- import { Component, HostBinding, Input, ViewEncapsulation } from '@angular/core';
2
- import { FormGroup } from '@angular/forms';
3
- import { MECXFieldConfig } from '../../../interfaces';
4
-
5
- @Component({
6
- selector: 'mecx-dynamic-radio',
7
- templateUrl: './radio.component.html',
8
- encapsulation: ViewEncapsulation.None
9
- })
10
- export class MECXDynamicRadioComponent {
11
- @Input() _field: MECXFieldConfig | null = null;
12
-
13
- @Input() _form: FormGroup | null = null;
14
-
15
- // eslint-disable-next-line object-curly-newline
16
- @Input() _formErrors: any | any[] = {};
17
-
18
- @HostBinding('class')
19
- get className() {
20
- return this._field?.style?.class;
21
- }
22
- }
@@ -1,14 +0,0 @@
1
- <monkey-select
2
- errorMessage="{{ _formErrors[_field?.name]?.firstMessage | translate }} {{ _formErrors[_field?.name]?.lastMessage }}"
3
- [formControl]="_form.controls[_field?.name]" [helperMessage]="_field?.helperMessage | translate"
4
- [label]="_field?.label | translate" (click)="onHandleGenericLoad()"
5
- [onHandleOptions]="_onHandleOptions" (onChange)="onChange($event)"
6
- [labelSelect]="_form.get(_field?.name).value || ('FIELD.SELECT' | translate)"
7
- [placeholder]="_field?.placeholder | translate">
8
- <monkey-option [label]="'FIELD.LOADING' | translate" *ngIf="!_field?.value?.length"
9
- enableClick="false">
10
- </monkey-option>
11
- <monkey-option *ngFor="let value of _field?.value" [label]="value.description | translate"
12
- [value]="value.value">
13
- </monkey-option>
14
- </monkey-select>
@@ -1,75 +0,0 @@
1
- import {
2
- Component,
3
- HostBinding,
4
- Input,
5
- EventEmitter,
6
- ViewEncapsulation
7
- } from '@angular/core';
8
- import { FormGroup } from '@angular/forms';
9
- import { MECXFieldConfig, MECXFieldConfigValue } from '../../../interfaces';
10
-
11
- @Component({
12
- selector: 'mecx-dynamic-select',
13
- templateUrl: './select.component.html',
14
- encapsulation: ViewEncapsulation.None
15
- })
16
- export class MECXDynamicSelectComponent {
17
- @Input() _field: MECXFieldConfig | null = null;
18
-
19
- @Input() _form: FormGroup | null = null;
20
-
21
- // eslint-disable-next-line object-curly-newline
22
- @Input() _formErrors: any | any[] = {};
23
-
24
- @Input() self: any;
25
-
26
- @HostBinding('class')
27
- get className() {
28
- return this._field?.style?.class;
29
- }
30
-
31
- _onHandleOptions = new EventEmitter<any>();
32
-
33
- onHandleGenericLoad() {
34
- const { _form, _field, self } = this;
35
- if (_form?.disabled || !_field || !_field?.functions?.onHandleGenericLoad) return;
36
- const { name } = _field;
37
- if ((_field?.value as MECXFieldConfigValue[])?.length) return;
38
- const { func, url } = _field?.functions?.onHandleGenericLoad;
39
- if (!func || !self[func]) {
40
- console.error('onHandleGenericLoad not declared');
41
- return;
42
- }
43
- _form?.disable();
44
- self[func]({
45
- name,
46
- url,
47
- form: _form,
48
- callback: (data: any[]) => {
49
- if (this._field) {
50
- this._field.value = data;
51
- }
52
- this._form?.enable();
53
- this._onHandleOptions.next(null);
54
- }
55
- });
56
- }
57
-
58
- onChange(event: string) {
59
- const { _form, _field, self } = this;
60
- if (!_field || !_form) return;
61
- const { name } = _field;
62
- const func = _field?.functions?.onChange;
63
- const isValid = _form?.get(_field.name as string)?.valid;
64
- if (func) {
65
- self[func]({
66
- name,
67
- isValid,
68
- event,
69
- ctrl: _form?.get(this._field?.name as string),
70
- form: _form,
71
- value: _field.value
72
- });
73
- }
74
- }
75
- }
@@ -1,15 +0,0 @@
1
- <monkey-select-search
2
- errorMessage="{{ _formErrors[_field?.name]?.firstMessage | translate }} {{ _formErrors[_field?.name]?.lastMessage }}"
3
- [formControl]="_form.controls[_field?.name]" [helperMessage]="_field?.helperMessage | translate"
4
- [label]="_field?.label | translate" (click)="onHandleGenericLoad()"
5
- [onHandleOptions]="_onHandleOptions" (onChange)="onChange($event)"
6
- [fieldToCompare]="_field?.fieldToCompare"
7
- [labelSelect]="_form.get(_field?.name).value || ('FIELD.SELECT' | translate)"
8
- [placeholder]="_field?.placeholder | translate">
9
- <monkey-option [label]="'FIELD.LOADING' | translate" *ngIf="!_field?.value?.length"
10
- enableClick="false">
11
- </monkey-option>
12
- <monkey-option *ngFor="let value of _field?.value" [label]="value.description | translate"
13
- [value]="value.value">
14
- </monkey-option>
15
- </monkey-select-search>
@@ -1,76 +0,0 @@
1
- import {
2
- Component,
3
- HostBinding,
4
- Input,
5
- EventEmitter,
6
- ViewEncapsulation
7
- } from '@angular/core';
8
- import { FormGroup } from '@angular/forms';
9
- import { MECXFieldConfig } from '../../../interfaces';
10
-
11
- @Component({
12
- selector: 'mecx-dynamic-select-search',
13
- templateUrl: './select-search.component.html',
14
- encapsulation: ViewEncapsulation.None
15
- })
16
- export class MECXDynamicSelectSearchComponent {
17
- @Input() _field: MECXFieldConfig | null = null;
18
-
19
- @Input() _form: FormGroup | null = null;
20
-
21
- // eslint-disable-next-line object-curly-newline
22
- @Input() _formErrors: any | any[] = {};
23
-
24
- @Input() self: any;
25
-
26
- @HostBinding('class')
27
- get className() {
28
- return this._field?.style?.class;
29
- }
30
-
31
- _onHandleOptions = new EventEmitter<any>();
32
-
33
- onHandleGenericLoad() {
34
- const { _form, _field, self } = this;
35
- if (_form?.disabled || !_field || !_field?.functions?.onHandleGenericLoad) return;
36
- const { name } = _field;
37
- const { func, url } = _field?.functions?.onHandleGenericLoad || {
38
- func: null, url: ''
39
- };
40
- if (!func || !self[func]) {
41
- console.error('onHandleGenericLoad not declared');
42
- return;
43
- }
44
- _form?.disable();
45
- self[func]({
46
- name,
47
- url,
48
- form: _form,
49
- callback: (data: any[]) => {
50
- if (this._field) {
51
- this._field.value = data;
52
- }
53
- this._form?.enable();
54
- this._onHandleOptions.next(null);
55
- }
56
- });
57
- }
58
-
59
- onChange(event: string) {
60
- const { _form, _field, self } = this;
61
- if (!_field || !_form) return;
62
- const { name } = _field;
63
- const func = _field?.functions?.onChange;
64
- const isValid = _form?.get(_field?.name as string)?.valid;
65
- if (func) {
66
- self[func]({
67
- name,
68
- isValid,
69
- event,
70
- ctrl: _form.get(this._field?.name as string),
71
- form: _form,
72
- value: _field.value
73
- });
74
- }
75
- }
76
- }
@@ -1,51 +0,0 @@
1
- <div class="d-flex flex-column full-width">
2
- <div class="d-flex flex-column flex-md-row justify-content-between">
3
- <div class="d-flex full-width">
4
- <ng-container *ngIf="enableSearch">
5
- <monkey-input-filter [placeholder]="searchPlaceholder | translate"
6
- (onChange)="onSearchFilter($event)" icon="search-16" iconPosition="left"
7
- [(value)]="_search">
8
- </monkey-input-filter>
9
- </ng-container>
10
- <ng-container *ngIf="!_hasFilterByMenu">
11
- <div class="d-flex actions" id="mecx-filters-add-filter">
12
- <monkey-button type="filter" color="border" (click)="onHandleShowMenu()" icon="more-16"
13
- iconPosition="right">
14
- {{ 'BUTTONS.ADD-FILTER' | translate }}
15
- </monkey-button>
16
- </div>
17
- </ng-container>
18
- </div>
19
- <div class="order hidden-sm hidden-xs">
20
- <ng-container *ngTemplateOutlet="orderBy"></ng-container>
21
- </div>
22
- </div>
23
- <ng-container *ngIf="_hasFilterByMenu">
24
- <div class="separator"></div>
25
- <div class="d-flex full-width">
26
- <mecx-filter-selected (onSubmit)="onHandleSubmit($event)" (onClose)="onHandleClose()"
27
- [model]="menus"></mecx-filter-selected>
28
- <div class="more-filters">
29
- <monkey-button type="filter" color="border" icon="more-16" id="mecx-filters-add-filter"
30
- (click)="onHandleShowMenu()">
31
- </monkey-button>
32
- </div>
33
- </div>
34
- </ng-container>
35
- <div class="order hidden-md hidden-lg">
36
- <ng-container *ngTemplateOutlet="orderBy"></ng-container>
37
- </div>
38
- </div>
39
-
40
- <mecx-filter-menu
41
- *monkeyecxPopover="_showMenu; target: $any(_actionElement); closed: closeMenu; dir: 'ltr'"
42
- (onSubmit)="onHandleSubmit($event)" (onClose)="onHandleClose()" [model]="menus">
43
- </mecx-filter-menu>
44
-
45
- <ng-template #orderBy>
46
- <monkey-select-filter (onChange)="onHandleOrder($event)" [placeholder]="orderPlaceholder | translate" type="none"
47
- [(value)]="_order">
48
- <monkey-option *ngFor="let ordBy of orders" [label]="ordBy?.label | translate" [value]="ordBy?.value">
49
- </monkey-option>
50
- </monkey-select-filter>
51
- </ng-template>
@@ -1,79 +0,0 @@
1
- @import 'node_modules/monkey-style-guide/assets/scss/partials/breakpoints';
2
-
3
- :host {
4
- display: flex;
5
- width: 100%;
6
- align-items: center;
7
-
8
- @include media-breakpoint('lt-md') {
9
- flex-direction: column;
10
- max-width: 100%;
11
-
12
- ::ng-deep monkey-input-filter {
13
- width: 100%;
14
- }
15
-
16
- ::ng-deep monkey-select-filter {
17
- width: 100%;
18
- }
19
-
20
- ::ng-deep monkey-button {
21
- width: 100%;
22
-
23
- button {
24
- width: 100%;
25
- }
26
- }
27
- }
28
-
29
- .actions {
30
- ::ng-deep monkey-button {
31
- @include media-breakpoint('gt-sm') {
32
- margin-left: 8px;
33
-
34
- button {
35
- width: 170px;
36
- }
37
- }
38
- }
39
- }
40
-
41
- .more-filters {
42
- ::ng-deep monkey-button {
43
- monkey-icon {
44
- margin-right: unset !important;
45
- }
46
- }
47
- }
48
-
49
- .order {
50
- @include media-breakpoint('gt-sm') {
51
- width: 230px;
52
- }
53
-
54
- @include media-breakpoint('lt-md') {
55
- margin-top: 8px;
56
- }
57
- }
58
-
59
- ::ng-deep monkey-button {
60
- margin-bottom: 0px;
61
- }
62
-
63
- ::ng-deep mecx-form-field-filter mecx-form-field-body {
64
- height: 40px;
65
- margin: 0px;
66
- }
67
-
68
- ::ng-deep monkey-input-filter {
69
- @include media-breakpoint('gt-sm') {
70
- width: 464px;
71
- }
72
- }
73
-
74
- .separator {
75
- border-bottom: 1px solid #ebebeb;
76
- margin-top: 16px;
77
- margin-bottom: 16px;
78
- }
79
- }
@@ -1,117 +0,0 @@
1
- import { Component, EventEmitter, Input, OnChanges, Output, SimpleChanges } from '@angular/core';
2
- import { MonkeyEcxFilterMenu, MonkeyEcxFilterOrder, MonkeyEcxUtils } from 'monkey-front-core';
3
-
4
- @Component({
5
- selector: 'mecx-filter',
6
- templateUrl: './filter.component.html',
7
- styleUrls: ['./filter.component.scss']
8
- })
9
- export class MECXFilterComponent implements OnChanges {
10
- @Input() searchPlaceholder = '';
11
-
12
- @Input() orderPlaceholder = '';
13
-
14
- @Input() menus: MonkeyEcxFilterMenu[] = [];
15
-
16
- @Input() orders: MonkeyEcxFilterOrder[] = [];
17
-
18
- @Input() enableSearch = true;
19
-
20
- @Input()
21
- set search(value: string) {
22
- this._search = value;
23
- }
24
-
25
- @Input()
26
- set order(value: any) {
27
- this._order = value;
28
- }
29
-
30
- @Input() isLoading = false;
31
-
32
- @Output() onFilter = new EventEmitter<any>();
33
-
34
- _order: MonkeyEcxFilterOrder = null;
35
-
36
- _search = '';
37
-
38
- _showMenu = false;
39
-
40
- _hasFilterByMenu = false;
41
-
42
- _actionElement: HTMLElement = null;
43
-
44
- closeMenu = () => {
45
- this._showMenu = false;
46
- };
47
-
48
- constructor() {
49
- // not to do
50
- }
51
-
52
- private validateValue({ field, value, getValue }: any) {
53
- try {
54
- value = value || getValue()?.[field];
55
- if (!value) return false;
56
- if (typeof value === 'object') {
57
- return value && JSON.stringify(value) !== '{}';
58
- }
59
- return MonkeyEcxUtils.persistNullEmptyUndefined(value);
60
- } catch (e) {
61
- // not to do
62
- }
63
- return false;
64
- }
65
-
66
- private handleFilters() {
67
- const { menus } = this;
68
- let found = menus.find((_: any) => {
69
- return this.validateValue(_);
70
- });
71
- if (!found) {
72
- found = menus.find(({ children }) => {
73
- return (children || [])?.find((_: any) => {
74
- return this.validateValue(_);
75
- });
76
- });
77
- }
78
- this._hasFilterByMenu = !!found;
79
- }
80
-
81
- ngOnChanges(changes: SimpleChanges) {
82
- if (changes.menus) {
83
- const { currentValue } = changes.menus;
84
- if (currentValue && JSON.stringify(currentValue) !== '{}') {
85
- this.handleFilters();
86
- }
87
- }
88
- }
89
-
90
- onSearchFilter(event: string) {
91
- this.onFilter.next({ search: event });
92
- }
93
-
94
- onClearFilter() {
95
- this._search = '';
96
- this.onFilter.next({ search: null });
97
- }
98
-
99
- onHandleSubmit(event: any) {
100
- this.onFilter.next(event);
101
- }
102
-
103
- onHandleShowMenu() {
104
- this._actionElement = document.getElementById('mecx-filters-add-filter');
105
- setTimeout(() => {
106
- this._showMenu = true;
107
- }, 0);
108
- }
109
-
110
- onHandleClose() {
111
- this._showMenu = false;
112
- }
113
-
114
- onHandleOrder(event: any) {
115
- this.onFilter.next({ sort: event });
116
- }
117
- }
@@ -1,36 +0,0 @@
1
- import { CommonModule } from '@angular/common';
2
- import { NgModule } from '@angular/core';
3
- import { FormsModule, ReactiveFormsModule } from '@angular/forms';
4
- import { TranslateModule } from '@ngx-translate/core';
5
- import { MonkeyEcxDirectivesModule, MonkeyEcxPipesModule } from 'monkey-front-core';
6
- import {
7
- MonkeyButtonModule,
8
- MonkeyIconModule,
9
- MonkeyInputModule,
10
- MonkeyOptionModule,
11
- MonkeySelectModule
12
- } from 'monkey-style-guide';
13
- import { MECXFilterComponent } from './filter.component';
14
- import { MECXFilterMenuModule } from './menu';
15
- import { MECXFilterSelectedModule } from './selected';
16
-
17
- @NgModule({
18
- declarations: [MECXFilterComponent],
19
- imports: [
20
- MonkeyEcxDirectivesModule,
21
- MonkeyEcxPipesModule,
22
- MonkeyButtonModule,
23
- MonkeyInputModule,
24
- MonkeyIconModule,
25
- MonkeySelectModule,
26
- MonkeyOptionModule,
27
- TranslateModule.forChild(),
28
- MECXFilterMenuModule,
29
- MECXFilterSelectedModule,
30
- CommonModule,
31
- FormsModule,
32
- ReactiveFormsModule
33
- ],
34
- exports: [MECXFilterComponent]
35
- })
36
- export class MECXFilterModule {}
@@ -1,28 +0,0 @@
1
- <div class="d-flex flex-column" #actionElement>
2
- <ng-container *ngFor="let menu of _model; let index = index">
3
- <ng-container *ngIf="menu?.children; else withoutChildren">
4
- <div class="item no-action">
5
- {{ menu.label | translate }}
6
- </div>
7
- <div class="separator"></div>
8
- <ng-container *ngFor="let child of menu?.children">
9
- <div class="item children" (click)="onHandleChildrenAction(menu, child)">
10
- {{ child.label | translate }}
11
- </div>
12
- </ng-container>
13
- </ng-container>
14
- <ng-template #withoutChildren>
15
- <div class="item" (click)="onHandleShowMenu(menu)">
16
- {{ menu.label | translate }}
17
- </div>
18
- </ng-template>
19
- <ng-container *ngIf="_model[index+1]?.group as next; _model[index]?.group as current">
20
- <div class="separator" *ngIf="next !== current"></div>
21
- </ng-container>
22
- </ng-container>
23
- </div>
24
- <ng-container
25
- *monkeyecxPopover="_showMenu; target: $any(actionElement); closed: closeMenu; dir: 'rt'">
26
- <mecx-filter-options [option]="_menuOption" (onClose)="onHandleClose()"
27
- (onSubmit)="onHandleSubmit($event)" [closeDirectly]="true"></mecx-filter-options>
28
- </ng-container>
@@ -1,62 +0,0 @@
1
- @import 'node_modules/monkey-style-guide/assets/scss/partials/variables';
2
-
3
- :host {
4
- display: flex;
5
- flex-direction: column;
6
- background: #fafafa;
7
- border: 1px solid #d6d6d6;
8
- box-sizing: border-box;
9
- box-shadow: 0px 4px 36px -8px #6d6d6d3a;
10
- border-radius: 16px !important;
11
- min-width: 192px;
12
- margin: 4px 8px;
13
- overflow: auto;
14
- max-height: 500px;
15
-
16
- ::ng-deep monkey-button {
17
- width: 100%;
18
-
19
- button {
20
- justify-content: flex-start !important;
21
- width: 100%;
22
- }
23
- }
24
-
25
- .item {
26
- font-style: normal;
27
- font-weight: 400;
28
- font-size: 16px;
29
- line-height: 24px;
30
- color: #72717e;
31
- padding: 8px 24px 8px 24px;
32
-
33
- &.no-action {
34
- cursor: not-allowed;
35
- padding: 8px;
36
- margin: 0px !important;
37
- font-weight: 500;
38
- }
39
-
40
- &:first-child {
41
- margin: 12px 0px 0px 0px;
42
- }
43
-
44
- &:last-child {
45
- margin: 0px 0px 12px 0px;
46
- }
47
-
48
- &:not(.no-action) {
49
- cursor: pointer;
50
-
51
- &:hover {
52
- background-color: map-get($mecx-theme, 200) !important;
53
- color: map-get($mecx-theme, main) !important;
54
- font-weight: 400;
55
- }
56
- }
57
- }
58
-
59
- .separator {
60
- border-bottom: 1px solid #ebebeb;
61
- }
62
- }