monkey-front-components 0.0.383 → 0.0.384

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/karma.conf.js +44 -0
  2. package/monkey-front-components-0.0.384.tgz +0 -0
  3. package/ng-package.json +10 -0
  4. package/package.json +7 -27
  5. package/src/lib/components/base/base-component.ts +359 -0
  6. package/src/lib/components/base/base-dynamic-array.ts +233 -0
  7. package/src/lib/components/base/base-dynamic.ts +90 -0
  8. package/src/lib/components/base/base-scroll-component.ts +52 -0
  9. package/src/lib/components/base/base-validators.ts +19 -0
  10. package/{lib/components/base/index.d.ts → src/lib/components/base/index.ts} +5 -5
  11. package/src/lib/components/dynamic/button/button.component.html +4 -0
  12. package/src/lib/components/dynamic/button/button.component.scss +7 -0
  13. package/src/lib/components/dynamic/button/button.component.ts +47 -0
  14. package/{lib/components/dynamic/button/index.d.ts → src/lib/components/dynamic/button/index.ts} +1 -1
  15. package/src/lib/components/dynamic/dynamic-directive.ts +102 -0
  16. package/src/lib/components/dynamic/dynamic.module.ts +53 -0
  17. package/src/lib/components/dynamic/file-upload/file-upload.component.html +10 -0
  18. package/src/lib/components/dynamic/file-upload/file-upload.component.ts +46 -0
  19. package/{lib/components/dynamic/file-upload/index.d.ts → src/lib/components/dynamic/file-upload/index.ts} +1 -1
  20. package/src/lib/components/dynamic/form/dynamic-form-array.component.html +19 -0
  21. package/src/lib/components/dynamic/form/dynamic-form-array.component.scss +10 -0
  22. package/src/lib/components/dynamic/form/dynamic-form-array.component.ts +75 -0
  23. package/src/lib/components/dynamic/form/dynamic-form.component.html +7 -0
  24. package/src/lib/components/dynamic/form/dynamic-form.component.ts +49 -0
  25. package/{lib/components/dynamic/form/index.d.ts → src/lib/components/dynamic/form/index.ts} +2 -2
  26. package/{lib/components/dynamic/index.d.ts → src/lib/components/dynamic/index.ts} +8 -8
  27. package/{lib/components/dynamic/input/index.d.ts → src/lib/components/dynamic/input/index.ts} +1 -1
  28. package/src/lib/components/dynamic/input/input.component.html +9 -0
  29. package/src/lib/components/dynamic/input/input.component.ts +58 -0
  30. package/{lib/components/dynamic/input-phone/index.d.ts → src/lib/components/dynamic/input-phone/index.ts} +1 -1
  31. package/src/lib/components/dynamic/input-phone/input-phone.component.html +7 -0
  32. package/src/lib/components/dynamic/input-phone/input-phone.component.ts +58 -0
  33. package/{lib/components/dynamic/radio/index.d.ts → src/lib/components/dynamic/radio/index.ts} +1 -1
  34. package/src/lib/components/dynamic/radio/radio.component.html +8 -0
  35. package/src/lib/components/dynamic/radio/radio.component.ts +22 -0
  36. package/{lib/components/dynamic/select/index.d.ts → src/lib/components/dynamic/select/index.ts} +1 -1
  37. package/src/lib/components/dynamic/select/select.component.html +14 -0
  38. package/src/lib/components/dynamic/select/select.component.ts +75 -0
  39. package/{lib/components/dynamic/select-search/index.d.ts → src/lib/components/dynamic/select-search/index.ts} +1 -1
  40. package/src/lib/components/dynamic/select-search/select-search.component.html +15 -0
  41. package/src/lib/components/dynamic/select-search/select-search.component.ts +76 -0
  42. package/{lib/components/index.d.ts → src/lib/components/index.ts} +3 -3
  43. package/src/lib/components/shared/filter/filter.component.html +51 -0
  44. package/src/lib/components/shared/filter/filter.component.scss +79 -0
  45. package/src/lib/components/shared/filter/filter.component.ts +117 -0
  46. package/src/lib/components/shared/filter/filter.module.ts +36 -0
  47. package/{lib/components/shared/filter/index.d.ts → src/lib/components/shared/filter/index.ts} +2 -2
  48. package/{lib/components/shared/filter/menu/index.d.ts → src/lib/components/shared/filter/menu/index.ts} +1 -1
  49. package/src/lib/components/shared/filter/menu/menu.component.html +28 -0
  50. package/src/lib/components/shared/filter/menu/menu.component.scss +62 -0
  51. package/src/lib/components/shared/filter/menu/menu.component.ts +122 -0
  52. package/src/lib/components/shared/filter/menu/menu.module.ts +41 -0
  53. package/src/lib/components/shared/filter/options/children/children.component.html +6 -0
  54. package/src/lib/components/shared/filter/options/children/children.component.scss +30 -0
  55. package/src/lib/components/shared/filter/options/children/children.component.ts +58 -0
  56. package/{lib/components/shared/filter/options/children/index.d.ts → src/lib/components/shared/filter/options/children/index.ts} +1 -1
  57. package/src/lib/components/shared/filter/options/currency/currency.component.html +3 -0
  58. package/src/lib/components/shared/filter/options/currency/currency.component.scss +19 -0
  59. package/src/lib/components/shared/filter/options/currency/currency.component.ts +52 -0
  60. package/{lib/components/shared/filter/options/currency/index.d.ts → src/lib/components/shared/filter/options/currency/index.ts} +1 -1
  61. package/src/lib/components/shared/filter/options/date-range/date-range.component.html +3 -0
  62. package/src/lib/components/shared/filter/options/date-range/date-range.component.scss +34 -0
  63. package/src/lib/components/shared/filter/options/date-range/date-range.component.ts +72 -0
  64. package/{lib/components/shared/filter/options/date-range/index.d.ts → src/lib/components/shared/filter/options/date-range/index.ts} +1 -1
  65. package/{lib/components/shared/filter/options/index.d.ts → src/lib/components/shared/filter/options/index.ts} +1 -1
  66. package/{lib/components/shared/filter/options/input/index.d.ts → src/lib/components/shared/filter/options/input/index.ts} +1 -1
  67. package/src/lib/components/shared/filter/options/input/input.component.html +3 -0
  68. package/src/lib/components/shared/filter/options/input/input.component.scss +19 -0
  69. package/src/lib/components/shared/filter/options/input/input.component.ts +52 -0
  70. package/src/lib/components/shared/filter/options/options.component.html +43 -0
  71. package/src/lib/components/shared/filter/options/options.component.scss +56 -0
  72. package/src/lib/components/shared/filter/options/options.component.ts +58 -0
  73. package/src/lib/components/shared/filter/options/options.module.ts +58 -0
  74. package/{lib/components/shared/filter/options/status/index.d.ts → src/lib/components/shared/filter/options/status/index.ts} +1 -1
  75. package/src/lib/components/shared/filter/options/status/status.component.html +4 -0
  76. package/src/lib/components/shared/filter/options/status/status.component.scss +29 -0
  77. package/src/lib/components/shared/filter/options/status/status.component.ts +73 -0
  78. package/{lib/components/shared/filter/selected/index.d.ts → src/lib/components/shared/filter/selected/index.ts} +1 -1
  79. package/src/lib/components/shared/filter/selected/item/children/children.component.html +19 -0
  80. package/src/lib/components/shared/filter/selected/item/children/children.component.scss +68 -0
  81. package/src/lib/components/shared/filter/selected/item/children/children.component.ts +49 -0
  82. package/{lib/components/shared/filter/selected/item/children/index.d.ts → src/lib/components/shared/filter/selected/item/children/index.ts} +1 -1
  83. package/src/lib/components/shared/filter/selected/item/currency/currency.component.html +1 -0
  84. package/src/lib/components/shared/filter/selected/item/currency/currency.component.scss +4 -0
  85. package/src/lib/components/shared/filter/selected/item/currency/currency.component.ts +26 -0
  86. package/{lib/components/shared/filter/selected/item/currency/index.d.ts → src/lib/components/shared/filter/selected/item/currency/index.ts} +1 -1
  87. package/src/lib/components/shared/filter/selected/item/date-range/date-range.component.html +2 -0
  88. package/src/lib/components/shared/filter/selected/item/date-range/date-range.component.scss +4 -0
  89. package/src/lib/components/shared/filter/selected/item/date-range/date-range.component.ts +39 -0
  90. package/{lib/components/shared/filter/selected/item/date-range/index.d.ts → src/lib/components/shared/filter/selected/item/date-range/index.ts} +1 -1
  91. package/src/lib/components/shared/filter/selected/item/date-with-action/date-with-action.component.html +1 -0
  92. package/src/lib/components/shared/filter/selected/item/date-with-action/date-with-action.component.scss +4 -0
  93. package/src/lib/components/shared/filter/selected/item/date-with-action/date-with-action.component.ts +29 -0
  94. package/{lib/components/shared/filter/selected/item/date-with-action/index.d.ts → src/lib/components/shared/filter/selected/item/date-with-action/index.ts} +1 -1
  95. package/{lib/components/shared/filter/selected/item/index.d.ts → src/lib/components/shared/filter/selected/item/index.ts} +7 -7
  96. package/{lib/components/shared/filter/selected/item/input/index.d.ts → src/lib/components/shared/filter/selected/item/input/index.ts} +1 -1
  97. package/src/lib/components/shared/filter/selected/item/input/input.component.html +1 -0
  98. package/src/lib/components/shared/filter/selected/item/input/input.component.scss +4 -0
  99. package/src/lib/components/shared/filter/selected/item/input/input.component.ts +26 -0
  100. package/src/lib/components/shared/filter/selected/item/item.component.html +38 -0
  101. package/src/lib/components/shared/filter/selected/item/item.component.scss +72 -0
  102. package/src/lib/components/shared/filter/selected/item/item.component.ts +71 -0
  103. package/{lib/components/shared/filter/selected/item/status/index.d.ts → src/lib/components/shared/filter/selected/item/status/index.ts} +1 -1
  104. package/src/lib/components/shared/filter/selected/item/status/status.component.html +1 -0
  105. package/src/lib/components/shared/filter/selected/item/status/status.component.scss +4 -0
  106. package/src/lib/components/shared/filter/selected/item/status/status.component.ts +36 -0
  107. package/src/lib/components/shared/filter/selected/selected.component.html +3 -0
  108. package/src/lib/components/shared/filter/selected/selected.component.scss +9 -0
  109. package/src/lib/components/shared/filter/selected/selected.component.ts +76 -0
  110. package/src/lib/components/shared/filter/selected/selected.module.ts +60 -0
  111. package/{lib/components/shared/index.d.ts → src/lib/components/shared/index.ts} +4 -4
  112. package/{lib/components/shared/password-strength/index.d.ts → src/lib/components/shared/password-strength/index.ts} +2 -2
  113. package/src/lib/components/shared/password-strength/password-strength.component.html +50 -0
  114. package/src/lib/components/shared/password-strength/password-strength.component.scss +70 -0
  115. package/src/lib/components/shared/password-strength/password-strength.component.ts +89 -0
  116. package/src/lib/components/shared/password-strength/password-strength.module.ts +24 -0
  117. package/src/lib/components/shared/password-strength/password-strength.ts +5 -0
  118. package/src/lib/components/shared/products/filter/filter.component.html +6 -0
  119. package/src/lib/components/shared/products/filter/filter.component.scss +20 -0
  120. package/src/lib/components/shared/products/filter/filter.component.ts +34 -0
  121. package/{lib/components/shared/products/index.d.ts → src/lib/components/shared/products/index.ts} +2 -2
  122. package/src/lib/components/shared/products/products.component.html +15 -0
  123. package/src/lib/components/shared/products/products.component.scss +70 -0
  124. package/src/lib/components/shared/products/products.component.ts +104 -0
  125. package/src/lib/components/shared/products/products.module.ts +13 -0
  126. package/{lib/components/shared/products/providers/index.d.ts → src/lib/components/shared/products/providers/index.ts} +1 -1
  127. package/src/lib/components/shared/products/providers/products.model.ts +60 -0
  128. package/{lib/components/shared/progress-bar/index.d.ts → src/lib/components/shared/progress-bar/index.ts} +3 -3
  129. package/src/lib/components/shared/progress-bar/progress-bar.component.html +3 -0
  130. package/src/lib/components/shared/progress-bar/progress-bar.component.scss +6 -0
  131. package/src/lib/components/shared/progress-bar/progress-bar.component.ts +27 -0
  132. package/src/lib/components/shared/progress-bar/progress-bar.module.ts +10 -0
  133. package/src/lib/components/shared/progress-bar/progress-bar.service.ts +59 -0
  134. package/src/lib/interfaces/field-config.ts +58 -0
  135. package/{lib/interfaces/index.d.ts → src/lib/interfaces/index.ts} +1 -1
  136. package/src/public-api.ts +5 -0
  137. package/src/test.ts +26 -0
  138. package/tsconfig.lib.json +20 -0
  139. package/tsconfig.lib.prod.json +10 -0
  140. package/tsconfig.spec.json +17 -0
  141. package/esm2020/lib/components/base/base-component.mjs +0 -322
  142. package/esm2020/lib/components/base/base-dynamic-array.mjs +0 -221
  143. package/esm2020/lib/components/base/base-dynamic.mjs +0 -99
  144. package/esm2020/lib/components/base/base-scroll-component.mjs +0 -55
  145. package/esm2020/lib/components/base/base-validators.mjs +0 -19
  146. package/esm2020/lib/components/base/index.mjs +0 -6
  147. package/esm2020/lib/components/dynamic/button/button.component.mjs +0 -52
  148. package/esm2020/lib/components/dynamic/button/index.mjs +0 -2
  149. package/esm2020/lib/components/dynamic/dynamic-directive.mjs +0 -95
  150. package/esm2020/lib/components/dynamic/dynamic.module.mjs +0 -84
  151. package/esm2020/lib/components/dynamic/file-upload/file-upload.component.mjs +0 -52
  152. package/esm2020/lib/components/dynamic/file-upload/index.mjs +0 -2
  153. package/esm2020/lib/components/dynamic/form/dynamic-form-array.component.mjs +0 -72
  154. package/esm2020/lib/components/dynamic/form/dynamic-form.component.mjs +0 -46
  155. package/esm2020/lib/components/dynamic/form/index.mjs +0 -3
  156. package/esm2020/lib/components/dynamic/index.mjs +0 -9
  157. package/esm2020/lib/components/dynamic/input/index.mjs +0 -2
  158. package/esm2020/lib/components/dynamic/input/input.component.mjs +0 -65
  159. package/esm2020/lib/components/dynamic/input-phone/index.mjs +0 -2
  160. package/esm2020/lib/components/dynamic/input-phone/input-phone.component.mjs +0 -65
  161. package/esm2020/lib/components/dynamic/radio/index.mjs +0 -2
  162. package/esm2020/lib/components/dynamic/radio/radio.component.mjs +0 -33
  163. package/esm2020/lib/components/dynamic/select/index.mjs +0 -2
  164. package/esm2020/lib/components/dynamic/select/select.component.mjs +0 -80
  165. package/esm2020/lib/components/dynamic/select-search/index.mjs +0 -2
  166. package/esm2020/lib/components/dynamic/select-search/select-search.component.mjs +0 -80
  167. package/esm2020/lib/components/index.mjs +0 -4
  168. package/esm2020/lib/components/shared/filter/filter.component.mjs +0 -119
  169. package/esm2020/lib/components/shared/filter/filter.module.mjs +0 -63
  170. package/esm2020/lib/components/shared/filter/index.mjs +0 -3
  171. package/esm2020/lib/components/shared/filter/menu/index.mjs +0 -2
  172. package/esm2020/lib/components/shared/filter/menu/menu.component.mjs +0 -120
  173. package/esm2020/lib/components/shared/filter/menu/menu.module.mjs +0 -70
  174. package/esm2020/lib/components/shared/filter/options/children/children.component.mjs +0 -50
  175. package/esm2020/lib/components/shared/filter/options/children/index.mjs +0 -2
  176. package/esm2020/lib/components/shared/filter/options/currency/currency.component.mjs +0 -46
  177. package/esm2020/lib/components/shared/filter/options/currency/index.mjs +0 -2
  178. package/esm2020/lib/components/shared/filter/options/date-range/date-range.component.mjs +0 -65
  179. package/esm2020/lib/components/shared/filter/options/date-range/index.mjs +0 -2
  180. package/esm2020/lib/components/shared/filter/options/index.mjs +0 -2
  181. package/esm2020/lib/components/shared/filter/options/input/index.mjs +0 -2
  182. package/esm2020/lib/components/shared/filter/options/input/input.component.mjs +0 -46
  183. package/esm2020/lib/components/shared/filter/options/options.component.mjs +0 -68
  184. package/esm2020/lib/components/shared/filter/options/options.module.mjs +0 -95
  185. package/esm2020/lib/components/shared/filter/options/status/index.mjs +0 -2
  186. package/esm2020/lib/components/shared/filter/options/status/status.component.mjs +0 -66
  187. package/esm2020/lib/components/shared/filter/selected/index.mjs +0 -2
  188. package/esm2020/lib/components/shared/filter/selected/item/children/children.component.mjs +0 -57
  189. package/esm2020/lib/components/shared/filter/selected/item/children/index.mjs +0 -2
  190. package/esm2020/lib/components/shared/filter/selected/item/currency/currency.component.mjs +0 -29
  191. package/esm2020/lib/components/shared/filter/selected/item/currency/index.mjs +0 -2
  192. package/esm2020/lib/components/shared/filter/selected/item/date-range/date-range.component.mjs +0 -42
  193. package/esm2020/lib/components/shared/filter/selected/item/date-range/index.mjs +0 -2
  194. package/esm2020/lib/components/shared/filter/selected/item/date-with-action/date-with-action.component.mjs +0 -33
  195. package/esm2020/lib/components/shared/filter/selected/item/date-with-action/index.mjs +0 -2
  196. package/esm2020/lib/components/shared/filter/selected/item/index.mjs +0 -8
  197. package/esm2020/lib/components/shared/filter/selected/item/input/index.mjs +0 -2
  198. package/esm2020/lib/components/shared/filter/selected/item/input/input.component.mjs +0 -28
  199. package/esm2020/lib/components/shared/filter/selected/item/item.component.mjs +0 -74
  200. package/esm2020/lib/components/shared/filter/selected/item/status/index.mjs +0 -2
  201. package/esm2020/lib/components/shared/filter/selected/item/status/status.component.mjs +0 -39
  202. package/esm2020/lib/components/shared/filter/selected/selected.component.mjs +0 -80
  203. package/esm2020/lib/components/shared/filter/selected/selected.module.mjs +0 -90
  204. package/esm2020/lib/components/shared/index.mjs +0 -5
  205. package/esm2020/lib/components/shared/password-strength/index.mjs +0 -3
  206. package/esm2020/lib/components/shared/password-strength/password-strength.component.mjs +0 -85
  207. package/esm2020/lib/components/shared/password-strength/password-strength.mjs +0 -2
  208. package/esm2020/lib/components/shared/password-strength/password-strength.module.mjs +0 -50
  209. package/esm2020/lib/components/shared/products/filter/filter.component.mjs +0 -36
  210. package/esm2020/lib/components/shared/products/index.mjs +0 -3
  211. package/esm2020/lib/components/shared/products/products.component.mjs +0 -91
  212. package/esm2020/lib/components/shared/products/products.module.mjs +0 -22
  213. package/esm2020/lib/components/shared/products/providers/index.mjs +0 -2
  214. package/esm2020/lib/components/shared/products/providers/products.model.mjs +0 -38
  215. package/esm2020/lib/components/shared/progress-bar/index.mjs +0 -4
  216. package/esm2020/lib/components/shared/progress-bar/progress-bar.component.mjs +0 -28
  217. package/esm2020/lib/components/shared/progress-bar/progress-bar.module.mjs +0 -18
  218. package/esm2020/lib/components/shared/progress-bar/progress-bar.service.mjs +0 -49
  219. package/esm2020/lib/interfaces/field-config.mjs +0 -2
  220. package/esm2020/lib/interfaces/index.mjs +0 -2
  221. package/esm2020/monkey-front-components.mjs +0 -5
  222. package/esm2020/public-api.mjs +0 -5
  223. package/fesm2015/monkey-front-components.mjs +0 -2877
  224. package/fesm2015/monkey-front-components.mjs.map +0 -1
  225. package/fesm2020/monkey-front-components.mjs +0 -2859
  226. package/fesm2020/monkey-front-components.mjs.map +0 -1
  227. package/lib/components/base/base-component.d.ts +0 -50
  228. package/lib/components/base/base-dynamic-array.d.ts +0 -34
  229. package/lib/components/base/base-dynamic.d.ts +0 -24
  230. package/lib/components/base/base-scroll-component.d.ts +0 -16
  231. package/lib/components/base/base-validators.d.ts +0 -1
  232. package/lib/components/dynamic/button/button.component.d.ts +0 -17
  233. package/lib/components/dynamic/dynamic-directive.d.ts +0 -22
  234. package/lib/components/dynamic/dynamic.module.d.ts +0 -20
  235. package/lib/components/dynamic/file-upload/file-upload.component.d.ts +0 -17
  236. package/lib/components/dynamic/form/dynamic-form-array.component.d.ts +0 -16
  237. package/lib/components/dynamic/form/dynamic-form.component.d.ts +0 -14
  238. package/lib/components/dynamic/input/input.component.d.ts +0 -20
  239. package/lib/components/dynamic/input-phone/input-phone.component.d.ts +0 -20
  240. package/lib/components/dynamic/radio/radio.component.d.ts +0 -11
  241. package/lib/components/dynamic/select/select.component.d.ts +0 -16
  242. package/lib/components/dynamic/select-search/select-search.component.d.ts +0 -16
  243. package/lib/components/shared/filter/filter.component.d.ts +0 -32
  244. package/lib/components/shared/filter/filter.module.d.ts +0 -14
  245. package/lib/components/shared/filter/menu/menu.component.d.ts +0 -24
  246. package/lib/components/shared/filter/menu/menu.module.d.ts +0 -14
  247. package/lib/components/shared/filter/options/children/children.component.d.ts +0 -17
  248. package/lib/components/shared/filter/options/currency/currency.component.d.ts +0 -17
  249. package/lib/components/shared/filter/options/date-range/date-range.component.d.ts +0 -24
  250. package/lib/components/shared/filter/options/input/input.component.d.ts +0 -17
  251. package/lib/components/shared/filter/options/options.component.d.ts +0 -20
  252. package/lib/components/shared/filter/options/options.module.d.ts +0 -18
  253. package/lib/components/shared/filter/options/status/status.component.d.ts +0 -19
  254. package/lib/components/shared/filter/selected/item/children/children.component.d.ts +0 -16
  255. package/lib/components/shared/filter/selected/item/currency/currency.component.d.ts +0 -11
  256. package/lib/components/shared/filter/selected/item/date-range/date-range.component.d.ts +0 -12
  257. package/lib/components/shared/filter/selected/item/date-with-action/date-with-action.component.d.ts +0 -11
  258. package/lib/components/shared/filter/selected/item/input/input.component.d.ts +0 -11
  259. package/lib/components/shared/filter/selected/item/item.component.d.ts +0 -20
  260. package/lib/components/shared/filter/selected/item/status/status.component.d.ts +0 -13
  261. package/lib/components/shared/filter/selected/selected.component.d.ts +0 -18
  262. package/lib/components/shared/filter/selected/selected.module.d.ts +0 -21
  263. package/lib/components/shared/password-strength/password-strength.component.d.ts +0 -23
  264. package/lib/components/shared/password-strength/password-strength.d.ts +0 -5
  265. package/lib/components/shared/password-strength/password-strength.module.d.ts +0 -12
  266. package/lib/components/shared/products/filter/filter.component.d.ts +0 -12
  267. package/lib/components/shared/products/products.component.d.ts +0 -20
  268. package/lib/components/shared/products/products.module.d.ts +0 -11
  269. package/lib/components/shared/products/providers/products.model.d.ts +0 -13
  270. package/lib/components/shared/progress-bar/progress-bar.component.d.ts +0 -12
  271. package/lib/components/shared/progress-bar/progress-bar.module.d.ts +0 -8
  272. package/lib/components/shared/progress-bar/progress-bar.service.d.ts +0 -14
  273. package/lib/interfaces/field-config.d.ts +0 -54
  274. package/monkey-front-components-0.0.383.tgz +0 -0
  275. package/monkey-front-components.d.ts +0 -5
  276. package/public-api.d.ts +0 -1
@@ -0,0 +1,56 @@
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: 8px !important;
11
+ margin: 0px 8px;
12
+
13
+ .header {
14
+ border-bottom: 1px solid #d6d6d6;
15
+ padding: 8px 8px;
16
+
17
+ .title {
18
+ color: #4b4a53;
19
+ font-style: normal;
20
+ font-size: 14px;
21
+ line-height: 16px;
22
+ font-weight: 500;
23
+ text-align: left;
24
+ }
25
+
26
+ .close {
27
+ cursor: pointer;
28
+ border-radius: 120px;
29
+ padding: 4px;
30
+
31
+ &:hover {
32
+ background-color: #6d6d6d0c;
33
+ }
34
+ }
35
+ }
36
+ }
37
+
38
+ .close-menu {
39
+ display: flex;
40
+ flex-direction: column;
41
+ background: #fafafa;
42
+ border: 1px solid #d6d6d6;
43
+ box-sizing: border-box;
44
+ box-shadow: 0px 4px 36px -8px #6d6d6d3a;
45
+ border-radius: 8px !important;
46
+ margin: 0px 8px;
47
+ padding: 8px;
48
+
49
+ ::ng-deep monkey-button {
50
+ width: 100%;
51
+
52
+ button {
53
+ width: 100%;
54
+ }
55
+ }
56
+ }
@@ -0,0 +1,58 @@
1
+ import { Component, EventEmitter, Input, Output } from '@angular/core';
2
+ import { MonkeyEcxFilterMenu, MonkeyEcxFilterMenuChildren } from 'monkey-front-core';
3
+
4
+ @Component({
5
+ selector: 'mecx-filter-options',
6
+ templateUrl: './options.component.html',
7
+ styleUrls: ['./options.component.scss']
8
+ })
9
+ export class MECXFilterOptionsComponent {
10
+ @Input() option: MonkeyEcxFilterMenu = null;
11
+
12
+ @Input() closeDirectly = false;
13
+
14
+ @Output() onClose = new EventEmitter<any>();
15
+
16
+ @Output() onRemove = new EventEmitter<any>();
17
+
18
+ @Output() onSubmit = new EventEmitter<any>();
19
+
20
+ @Output() onShowFromChildren = new EventEmitter<any>();
21
+
22
+ _showMenu = false;
23
+
24
+ closeMenu = () => {
25
+ this._showMenu = false;
26
+ };
27
+
28
+ constructor() {
29
+ // not to do
30
+ }
31
+
32
+ onHandleChildrenAction(child: MonkeyEcxFilterMenuChildren) {
33
+ const { option } = this;
34
+ const { field, action } = child;
35
+ this.onSubmit.next({
36
+ [option.field]: {
37
+ [field]: action()
38
+ }
39
+ });
40
+ }
41
+
42
+ onHandleSubmitChildren(event: any) {
43
+ this.onSubmit.next(event);
44
+ }
45
+
46
+ onHandleSubmit(event: any) {
47
+ this.onSubmit.next(event);
48
+ }
49
+
50
+ onHandleShowMenu() {
51
+ const { closeDirectly } = this;
52
+ if (closeDirectly) {
53
+ this.onClose.next();
54
+ return;
55
+ }
56
+ this._showMenu = true;
57
+ }
58
+ }
@@ -0,0 +1,58 @@
1
+ import { CommonModule } from '@angular/common';
2
+ import { NgModule } from '@angular/core';
3
+ import { FormsModule, ReactiveFormsModule } from '@angular/forms';
4
+ import { RouterModule } from '@angular/router';
5
+ import { TranslateModule } from '@ngx-translate/core';
6
+ import { MonkeyEcxDirectivesModule } from 'monkey-front-core';
7
+ import {
8
+ MonkeyBadgeModule,
9
+ MonkeyButtonModule,
10
+ MonkeyCheckboxModule,
11
+ MonkeyDateRangePickerModule,
12
+ MonkeyIconModule,
13
+ MonkeyInputModule,
14
+ MonkeyOptionModule,
15
+ MonkeySelectModule
16
+ } from 'monkey-style-guide';
17
+ import { MECXFilterOptionsChildrenComponent } from './children';
18
+ import { MECXFilterOptionsCurrencyComponent } from './currency';
19
+ import { MECXFilterOptionsInputComponent } from './input';
20
+ import { MECXFilterOptionsDateRangeComponent } from './date-range';
21
+ import { MECXFilterOptionsComponent } from './options.component';
22
+ import { MECXFilterOptionsStatusComponent } from './status';
23
+
24
+ @NgModule({
25
+ declarations: [
26
+ MECXFilterOptionsChildrenComponent,
27
+ MECXFilterOptionsComponent,
28
+ MECXFilterOptionsCurrencyComponent,
29
+ MECXFilterOptionsDateRangeComponent,
30
+ MECXFilterOptionsInputComponent,
31
+ MECXFilterOptionsStatusComponent
32
+ ],
33
+ imports: [
34
+ CommonModule,
35
+ FormsModule,
36
+ MonkeyBadgeModule,
37
+ MonkeyButtonModule,
38
+ MonkeyCheckboxModule,
39
+ MonkeyDateRangePickerModule,
40
+ MonkeyEcxDirectivesModule,
41
+ MonkeyIconModule,
42
+ MonkeyInputModule,
43
+ MonkeyOptionModule,
44
+ MonkeySelectModule,
45
+ ReactiveFormsModule,
46
+ RouterModule,
47
+ TranslateModule.forChild()
48
+ ],
49
+ exports: [
50
+ MECXFilterOptionsChildrenComponent,
51
+ MECXFilterOptionsComponent,
52
+ MECXFilterOptionsCurrencyComponent,
53
+ MECXFilterOptionsDateRangeComponent,
54
+ MECXFilterOptionsInputComponent,
55
+ MECXFilterOptionsStatusComponent
56
+ ]
57
+ })
58
+ export class MECXFilterOptionsModule {}
@@ -1 +1 @@
1
- export * from './status.component';
1
+ export * from './status.component';
@@ -0,0 +1,4 @@
1
+ <monkey-checkbox type="multiple" *ngFor="let op of option?.values"
2
+ [description]="op?.description | translate" [value]="onHandleChecked(op?.value)"
3
+ (click)="onChangeFilter($event, op?.value)">
4
+ </monkey-checkbox>
@@ -0,0 +1,29 @@
1
+ @import 'node_modules/monkey-style-guide/assets/scss/partials/variables';
2
+
3
+ :host {
4
+ display: flex;
5
+ flex-direction: column;
6
+ max-width: 232px;
7
+ min-width: 180px;
8
+ max-height: 500px;
9
+ padding: 12px 12px 8px 12px;
10
+ color: #72717e;
11
+ overflow: auto;
12
+
13
+ ::ng-deep mecx-form-field mecx-form-field-body.checkbox {
14
+ padding: 0px !important;
15
+
16
+ .mecx-check-container {
17
+ height: unset !important;
18
+
19
+ .mecx-check-mark {
20
+ top: 50%;
21
+ transform: translateY(-50%);
22
+ }
23
+ }
24
+ }
25
+
26
+ ::ng-deep monkey-checkbox {
27
+ margin: 6px 0px !important;
28
+ }
29
+ }
@@ -0,0 +1,73 @@
1
+ import { Component, EventEmitter, Input, OnChanges, OnDestroy, OnInit, Output, SimpleChanges } from '@angular/core';
2
+ import { MonkeyEcxFilterMenu } from 'monkey-front-core';
3
+ import { Subscription } from 'rxjs';
4
+ import { debounceTime } from 'rxjs/operators';
5
+
6
+ @Component({
7
+ selector: 'mecx-filter-options-status',
8
+ templateUrl: './status.component.html',
9
+ styleUrls: ['./status.component.scss']
10
+ })
11
+ export class MECXFilterOptionsStatusComponent implements OnInit, OnChanges, OnDestroy {
12
+ @Input() option: MonkeyEcxFilterMenu = null;
13
+
14
+ @Output() onSubmit = new EventEmitter<any>();
15
+
16
+ _value = '';
17
+
18
+ private eventHandle = new EventEmitter<any>();
19
+
20
+ private eventSubscription: Subscription;
21
+
22
+ constructor() {
23
+ // not to do
24
+ }
25
+
26
+ private verifySelected(value: string): boolean {
27
+ return this._value?.includes(value);
28
+ }
29
+
30
+ ngOnInit() {
31
+ const { eventHandle, onSubmit, option: { field } } = this;
32
+
33
+ this.eventSubscription = eventHandle
34
+ .pipe(debounceTime(800))
35
+ .subscribe((value: string) => {
36
+ onSubmit.next({ [field]: value });
37
+ });
38
+ }
39
+
40
+ ngOnDestroy() {
41
+ this.eventSubscription.unsubscribe();
42
+ }
43
+
44
+ ngOnChanges(changes: SimpleChanges) {
45
+ if (changes.option) {
46
+ const { currentValue } = changes.option;
47
+ if (currentValue && JSON.stringify(currentValue) !== '{}') {
48
+ this._value = currentValue?.value;
49
+ }
50
+ }
51
+ }
52
+
53
+ onHandleChecked(cmp: string) {
54
+ const { _value } = this;
55
+ return `${_value}`.split(',')?.indexOf(cmp) >= 0;
56
+ }
57
+
58
+ onChangeFilter(event: any, value: string): void {
59
+ event.preventDefault();
60
+ event.stopPropagation();
61
+
62
+ const selected = !this.verifySelected(value);
63
+ const filters: string[] = this._value?.split(',') || [];
64
+ if (!selected) {
65
+ filters.splice(filters.indexOf(value), 1);
66
+ } else {
67
+ filters.push(value);
68
+ }
69
+
70
+ this._value = filters?.length ? filters.join(',') : null;
71
+ this.eventHandle.next(this._value);
72
+ }
73
+ }
@@ -1 +1 @@
1
- export * from './selected.module';
1
+ export * from './selected.module';
@@ -0,0 +1,19 @@
1
+ <div class="box">
2
+ <div class="data">
3
+ {{ option.label | translate }}
4
+ </div>
5
+ <div class="value" [id]="'mecx-filter-selected-item-'+option?.field" (click)="onShow.next()">
6
+ <ng-container *ngIf="option?.type as type">
7
+ <ng-container [ngSwitch]="type+'-'+_child?.type">
8
+ <mecx-filter-selected-item-date-with-action *ngSwitchCase="'date-with-action'"
9
+ [option]="_child">
10
+ </mecx-filter-selected-item-date-with-action>
11
+ <mecx-filter-selected-item-date-range *ngSwitchCase="'date-date-range'" [option]="_child">
12
+ </mecx-filter-selected-item-date-range>
13
+ </ng-container>
14
+ </ng-container>
15
+ </div>
16
+ <div class="action" (click)="onShow.next()">
17
+ <monkey-icon icon="arrow-right-14" color="#4B4A53"></monkey-icon>
18
+ </div>
19
+ </div>
@@ -0,0 +1,68 @@
1
+ @import 'node_modules/monkey-style-guide/assets/scss/partials/variables';
2
+
3
+ :host {
4
+ display: flex;
5
+
6
+ .box {
7
+ display: flex;
8
+ justify-content: space-between;
9
+ align-items: center;
10
+ background: #ffffff;
11
+ border: 1px solid #d6d6d6;
12
+ box-sizing: border-box;
13
+ border-radius: 120px;
14
+ height: 40px;
15
+
16
+ .data {
17
+ display: flex;
18
+ align-items: center;
19
+ padding-left: 12px;
20
+ height: 100%;
21
+ font-style: normal;
22
+ font-weight: 400;
23
+ font-size: 14px;
24
+ line-height: 24px;
25
+ text-align: center;
26
+ color: #72717e;
27
+ }
28
+
29
+ .value {
30
+ cursor: pointer;
31
+ display: flex;
32
+ align-items: center;
33
+ padding: 12px;
34
+ height: 100%;
35
+ font-style: normal;
36
+ font-weight: 400;
37
+ font-size: 14px;
38
+ line-height: 24px;
39
+ text-align: center;
40
+ color: #72717e;
41
+ background-color: #6d6d6d0a;
42
+
43
+ &:hover {
44
+ background-color: #6d6d6d0c;
45
+ font-weight: 400;
46
+ text-decoration: underline;
47
+ }
48
+ }
49
+
50
+ .action {
51
+ cursor: pointer;
52
+ border-left: 1px solid #d6d6d6;
53
+ padding: 12px;
54
+ color: #908e9d;
55
+ font-weight: 500;
56
+ font-size: 18px;
57
+ height: 40px;
58
+ align-items: center;
59
+ display: flex;
60
+
61
+ &:hover {
62
+ background-color: #6d6d6d0c;
63
+ border-top-right-radius: 120px;
64
+ border-bottom-right-radius: 120px;
65
+ }
66
+ }
67
+ }
68
+ }
@@ -0,0 +1,49 @@
1
+ import { Component, ElementRef, EventEmitter, Input, OnChanges, Output, SimpleChanges } from '@angular/core';
2
+ import { MonkeyEcxFilterMenu, MonkeyEcxUtils } from 'monkey-front-core';
3
+
4
+ @Component({
5
+ selector: 'mecx-filter-selected-item-children',
6
+ templateUrl: './children.component.html',
7
+ styleUrls: ['./children.component.scss']
8
+ })
9
+ export class MECXFilterSelectedItemChildrenComponent implements OnChanges {
10
+ @Input() option: MonkeyEcxFilterMenu = null;
11
+
12
+ @Output() onShow = new EventEmitter<any>();
13
+
14
+ @Output() onRemove = new EventEmitter<any>();
15
+
16
+ _child: any = null;
17
+
18
+ constructor(private elRef: ElementRef) {
19
+ // not to do
20
+ }
21
+
22
+ private validateValue(value: any) {
23
+ if (!value) return false;
24
+ if (typeof value === 'object') {
25
+ return value && JSON.stringify(value) !== '{}';
26
+ }
27
+ return MonkeyEcxUtils.persistNullEmptyUndefined(value);
28
+ }
29
+
30
+ private onHandleSelectedValue({ children }: any) {
31
+ const found = children.find(({ field, getValue }: any) => {
32
+ return this.validateValue(getValue()?.[field]);
33
+ });
34
+ if (!found) {
35
+ this.elRef.nativeElement.remove();
36
+ return;
37
+ }
38
+ this._child = found;
39
+ }
40
+
41
+ ngOnChanges(changes: SimpleChanges) {
42
+ if (changes.option) {
43
+ const { currentValue } = changes.option;
44
+ if (currentValue && JSON.stringify(currentValue) !== '{}') {
45
+ this.onHandleSelectedValue(currentValue);
46
+ }
47
+ }
48
+ }
49
+ }
@@ -1 +1 @@
1
- export * from './children.component';
1
+ export * from './children.component';
@@ -0,0 +1 @@
1
+ {{ _value | monkeyecxFormatCurrency }}
@@ -0,0 +1,4 @@
1
+ @import 'node_modules/monkey-style-guide/assets/scss/partials/variables';
2
+
3
+ :host {
4
+ }
@@ -0,0 +1,26 @@
1
+ import { Component, Input, OnChanges, SimpleChanges } from '@angular/core';
2
+ import { MonkeyEcxFilterMenu } from 'monkey-front-core';
3
+
4
+ @Component({
5
+ selector: 'mecx-filter-selected-item-currency',
6
+ templateUrl: './currency.component.html',
7
+ styleUrls: ['./currency.component.scss']
8
+ })
9
+ export class MECXFilterSelectedItemCurrencyComponent implements OnChanges {
10
+ @Input() option: MonkeyEcxFilterMenu = null;
11
+
12
+ _value: any = null;
13
+
14
+ private onHandleSelectedValue({ value }: any) {
15
+ this._value = value;
16
+ }
17
+
18
+ ngOnChanges(changes: SimpleChanges) {
19
+ if (changes.option) {
20
+ const { currentValue } = changes.option;
21
+ if (currentValue && JSON.stringify(currentValue) !== '{}') {
22
+ this.onHandleSelectedValue(currentValue);
23
+ }
24
+ }
25
+ }
26
+ }
@@ -1 +1 @@
1
- export * from './currency.component';
1
+ export * from './currency.component';
@@ -0,0 +1,2 @@
1
+ {{ _startDate | monkeyecxFormatDateTimelapse: false }} -
2
+ {{ _endDate | monkeyecxFormatDateTimelapse: false }}
@@ -0,0 +1,4 @@
1
+ @import 'node_modules/monkey-style-guide/assets/scss/partials/variables';
2
+
3
+ :host {
4
+ }
@@ -0,0 +1,39 @@
1
+ import { Component, Input, OnChanges, SimpleChanges } from '@angular/core';
2
+ import { MonkeyEcxFilterMenu, MonkeyEcxFilterMenuChildren } from 'monkey-front-core';
3
+
4
+ @Component({
5
+ selector: 'mecx-filter-selected-item-date-range',
6
+ templateUrl: './date-range.component.html',
7
+ styleUrls: ['./date-range.component.scss']
8
+ })
9
+ export class MECXFilterSelectedItemDateRangeComponent implements OnChanges {
10
+ @Input() option: MonkeyEcxFilterMenu | MonkeyEcxFilterMenuChildren = null;
11
+
12
+ _startDate = '';
13
+
14
+ _endDate = '';
15
+
16
+ private onHandleSelectedValue({ field, value, getValue }: any) {
17
+ try {
18
+ value = value || getValue()?.[field];
19
+ if (value && JSON.stringify(value) !== '{}') {
20
+ const objDates = JSON.parse(value);
21
+ this._startDate = objDates?.startDate;
22
+ this._endDate = objDates?.endDate;
23
+ }
24
+ } catch (e) {
25
+ const objDates = JSON.parse(value?.dates);
26
+ this._startDate = objDates?.startDate;
27
+ this._endDate = objDates?.endDate;
28
+ }
29
+ }
30
+
31
+ ngOnChanges(changes: SimpleChanges) {
32
+ if (changes.option) {
33
+ const { currentValue } = changes.option;
34
+ if (currentValue && JSON.stringify(currentValue) !== '{}') {
35
+ this.onHandleSelectedValue(currentValue);
36
+ }
37
+ }
38
+ }
39
+ }
@@ -1 +1 @@
1
- export * from './date-range.component';
1
+ export * from './date-range.component';
@@ -0,0 +1 @@
1
+ {{ _date | monkeyecxFormatDateTimelapse: false }}
@@ -0,0 +1,4 @@
1
+ @import 'node_modules/monkey-style-guide/assets/scss/partials/variables';
2
+
3
+ :host {
4
+ }
@@ -0,0 +1,29 @@
1
+ import { Component, Input, OnChanges, SimpleChanges } from '@angular/core';
2
+ import { MonkeyEcxFilterMenuChildren, MonkeyEcxUtils } from 'monkey-front-core';
3
+
4
+ @Component({
5
+ selector: 'mecx-filter-selected-item-date-with-action',
6
+ templateUrl: './date-with-action.component.html',
7
+ styleUrls: ['./date-with-action.component.scss']
8
+ })
9
+ export class MECXFilterSelectedItemDateWithActionComponent implements OnChanges {
10
+ @Input() option: MonkeyEcxFilterMenuChildren = null;
11
+
12
+ _date = '';
13
+
14
+ private onHandleSelectedValue({ field, getValue }: any) {
15
+ const value = getValue()?.[field];
16
+ if (MonkeyEcxUtils.persistNullEmptyUndefined(value)) {
17
+ this._date = value;
18
+ }
19
+ }
20
+
21
+ ngOnChanges(changes: SimpleChanges) {
22
+ if (changes.option) {
23
+ const { currentValue } = changes.option;
24
+ if (currentValue && JSON.stringify(currentValue) !== '{}') {
25
+ this.onHandleSelectedValue(currentValue);
26
+ }
27
+ }
28
+ }
29
+ }
@@ -1 +1 @@
1
- export * from './date-with-action.component';
1
+ export * from './date-with-action.component';
@@ -1,7 +1,7 @@
1
- export * from './children';
2
- export * from './currency';
3
- export * from './date-range';
4
- export * from './date-with-action';
5
- export * from './input';
6
- export * from './item.component';
7
- export * from './status';
1
+ export * from './children';
2
+ export * from './currency';
3
+ export * from './date-range';
4
+ export * from './date-with-action';
5
+ export * from './input';
6
+ export * from './item.component';
7
+ export * from './status';
@@ -1 +1 @@
1
- export * from './input.component';
1
+ export * from './input.component';
@@ -0,0 +1,4 @@
1
+ @import 'node_modules/monkey-style-guide/assets/scss/partials/variables';
2
+
3
+ :host {
4
+ }
@@ -0,0 +1,26 @@
1
+ import { Component, Input, OnChanges, SimpleChanges } from '@angular/core';
2
+ import { MonkeyEcxFilterMenu } from 'monkey-front-core';
3
+
4
+ @Component({
5
+ selector: 'mecx-filter-selected-item-input',
6
+ templateUrl: './input.component.html',
7
+ styleUrls: ['./input.component.scss']
8
+ })
9
+ export class MECXFilterSelectedItemInputComponent implements OnChanges {
10
+ @Input() option: MonkeyEcxFilterMenu = null;
11
+
12
+ _value: any = null;
13
+
14
+ private onHandleSelectedValue({ value }: any) {
15
+ this._value = value;
16
+ }
17
+
18
+ ngOnChanges(changes: SimpleChanges) {
19
+ if (changes.option) {
20
+ const { currentValue } = changes.option;
21
+ if (currentValue && JSON.stringify(currentValue) !== '{}') {
22
+ this.onHandleSelectedValue(currentValue);
23
+ }
24
+ }
25
+ }
26
+ }
@@ -0,0 +1,38 @@
1
+ <ng-container *ngIf="_option?.type as type">
2
+ <ng-container *ngIf="_option?.children; else withoutChildren">
3
+ <mecx-filter-selected-item-children [option]="_option" (onShow)="onHandleShowMenu()"
4
+ (onRemove)="onHandleRemove()">
5
+ </mecx-filter-selected-item-children>
6
+ </ng-container>
7
+ <ng-template #withoutChildren>
8
+ <div class="box">
9
+ <div class="data">
10
+ {{ _option.label | translate }}
11
+ </div>
12
+ <div class="value" [id]="'mecx-filter-selected-item-'+_option?.field"
13
+ (click)="onHandleShowMenu()">
14
+ <ng-container [ngSwitch]="type">
15
+ <mecx-filter-selected-item-currency *ngSwitchCase="'currency'" [option]="_option">
16
+ </mecx-filter-selected-item-currency>
17
+ <mecx-filter-selected-item-input *ngSwitchCase="'input'" [option]="_option">
18
+ </mecx-filter-selected-item-input>
19
+ <mecx-filter-selected-item-date-range *ngSwitchCase="'date-range'" [option]="_option">
20
+ </mecx-filter-selected-item-date-range>
21
+ <mecx-filter-selected-item-status *ngSwitchCase="'status'" [option]="_option"
22
+ [labelMoreValues]="'FIELD.AND-MORE' | translate">
23
+ </mecx-filter-selected-item-status>
24
+ </ng-container>
25
+ </div>
26
+ <div class="action" (click)="onHandleShowMenu()">
27
+ <monkey-icon icon="arrow-right-14" color="#4B4A53"></monkey-icon>
28
+ </div>
29
+ </div>
30
+ </ng-template>
31
+ </ng-container>
32
+ <ng-container
33
+ *monkeyecxPopover="_showMenu; target: $any(_actionElement); closed: closeMenu; dir: 'ltr'">
34
+ <mecx-filter-options [option]="_option" (onClose)="onHandleClose()"
35
+ (onRemove)="onHandleRemove()" (onSubmit)="onHandleSubmit($event)"
36
+ (onShowFromChildren)="onHandleShowFromChildren($event)">
37
+ </mecx-filter-options>
38
+ </ng-container>