@zohodesk/library-platform 1.1.12 → 1.2.0

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 (475) hide show
  1. package/es/.DS_Store +0 -0
  2. package/es/bc/action-band/Constants.js +4 -0
  3. package/es/bc/action-band/Properties.js +10 -0
  4. package/es/bc/action-band/index.js +1 -0
  5. package/es/bc/app-context/Properties.js +19 -0
  6. package/es/bc/column-chooser/EventHandlers.js +1 -2
  7. package/es/bc/float-pagination/ActionHandlers.js +1 -0
  8. package/es/bc/float-pagination/Constants.js +4 -0
  9. package/es/bc/float-pagination/Properties.js +18 -0
  10. package/es/bc/float-pagination/index.js +2 -0
  11. package/es/bc/index.js +0 -1
  12. package/es/bc/sdk/ResourceNamesEnum.js +1 -0
  13. package/es/bc/search/Constants.js +3 -0
  14. package/es/bc/search/EventHandlers.js +1 -0
  15. package/es/bc/search/Properties.js +11 -0
  16. package/es/bc/search/index.js +2 -0
  17. package/es/bc/search-box/ActionHandlers.js +1 -0
  18. package/es/bc/search-box/Constants.js +4 -0
  19. package/es/bc/search-box/Properties.js +18 -0
  20. package/es/bc/search-box/index.js +2 -0
  21. package/es/bc/sort-by/ActionHandlers.js +1 -1
  22. package/es/bc/sort-by/Constants.js +2 -2
  23. package/es/bc/sort-by/Properties.js +13 -11
  24. package/es/bc/sort-by/Types.js +10 -0
  25. package/es/bc/sort-by/types/SortByBehaviourState.js +1 -0
  26. package/es/bc/zfield/Constants.js +5 -1
  27. package/es/bc/zform/Properties.js +20 -0
  28. package/es/bc/zform/Symbol.js +3 -0
  29. package/es/bc/zlist/Constants.js +0 -1
  30. package/es/bc/zlist/Types.js +27 -0
  31. package/es/bc/zrecord/Constants.js +4 -0
  32. package/es/bc/zrecord/Schemas.js +29 -0
  33. package/es/bc/zrecord/Types.js +45 -0
  34. package/es/cc/action-band/Properties.js +120 -0
  35. package/es/cc/action-band/SdkContract.js +13 -0
  36. package/es/cc/action-band/constants/Events.js +1 -0
  37. package/es/cc/action-band/constants/ExternalConstants.js +9 -0
  38. package/es/cc/action-band/constants/index.js +2 -0
  39. package/es/cc/action-band/index.js +3 -0
  40. package/es/cc/action-icon/Properties.js +20 -1
  41. package/es/cc/checkbox/Properties.js +2 -1
  42. package/es/cc/component/LifeCycleEventsEnum.js +1 -0
  43. package/es/cc/email/Properties.js +8 -0
  44. package/es/cc/fields/currency/Properties.js +9 -0
  45. package/es/cc/fields/decimal/Properties.js +9 -0
  46. package/es/cc/fields/email/Properties.js +9 -0
  47. package/es/cc/fields/field/Types.js +31 -23
  48. package/es/cc/fields/lookup/Properties.js +10 -26
  49. package/es/cc/fields/multi-line/Properties.js +1 -0
  50. package/es/cc/fields/number/Properties.js +10 -1
  51. package/es/cc/fields/phone/Properties.js +9 -0
  52. package/es/cc/fields/text/Properties.js +2 -2
  53. package/es/cc/fields/url/Properties.js +9 -0
  54. package/es/cc/floating-pagination/Constants.js +6 -0
  55. package/es/cc/floating-pagination/Events.js +8 -0
  56. package/es/cc/floating-pagination/Properties.js +56 -0
  57. package/es/cc/floating-pagination/index.js +3 -0
  58. package/es/cc/highlighted-value/Properties.js +18 -0
  59. package/es/cc/link/Properties.js +13 -3
  60. package/es/cc/list-item/Properties.js +10 -0
  61. package/es/cc/more-dropdown/Properties.js +4 -0
  62. package/es/cc/radio-dropdown/Constants.js +6 -0
  63. package/es/cc/radio-dropdown/Data.js +1 -0
  64. package/es/cc/radio-dropdown/Events.js +42 -0
  65. package/es/cc/radio-dropdown/Properties.js +142 -0
  66. package/es/cc/radio-dropdown/index.js +4 -0
  67. package/es/cc/ribbon/Properties.js +59 -0
  68. package/es/cc/ribbon/index.js +1 -0
  69. package/es/cc/search/Constants.js +6 -0
  70. package/es/cc/search/Events.js +17 -0
  71. package/es/cc/search/Properties.js +11 -0
  72. package/es/cc/search/index.js +3 -0
  73. package/es/cc/sort-dropdown/Constants.js +7 -0
  74. package/es/cc/sort-dropdown/Events.js +46 -0
  75. package/es/cc/sort-dropdown/Properties.js +135 -0
  76. package/es/cc/sort-dropdown/index.js +3 -0
  77. package/es/cc/switch/Properties.js +2 -2
  78. package/es/cc/table-column-chooser/Constants.js +2 -1
  79. package/es/cc/table-connected/Properties.js +16 -0
  80. package/es/cc/table-connected/SdkContract.js +46 -0
  81. package/es/cc/table-connected/constants/Events.js +2 -0
  82. package/es/cc/table-list/Actions.js +0 -2
  83. package/es/cc/table-list/Constants.js +1 -1
  84. package/es/cc/table-list/Events.js +0 -2
  85. package/es/cc/table-list/Properties.js +35 -38
  86. package/es/cc/table-list/data-types/FloatPaginationConfig.js +1 -0
  87. package/es/cc/tag/Constants.js +6 -0
  88. package/es/cc/tag/Data.js +14 -0
  89. package/es/cc/tag/EventHandlers.js +1 -0
  90. package/es/cc/tag/Events.js +26 -0
  91. package/es/cc/{tags/model/TagModel.js → tag/Model.js} +6 -2
  92. package/es/cc/tag/Properties.js +104 -0
  93. package/es/cc/tag/index.js +6 -0
  94. package/es/cc/tags/Data.js +0 -6
  95. package/es/cc/tags/model/index.js +1 -1
  96. package/es/cc/tags-list-dropdown/Constants.js +5 -0
  97. package/es/cc/tags-list-dropdown/Data.js +1 -0
  98. package/es/cc/tags-list-dropdown/Events.js +14 -0
  99. package/es/cc/tags-list-dropdown/Properties.js +96 -0
  100. package/es/cc/tags-list-dropdown/index.js +4 -0
  101. package/es/cc/text/Properties.js +100 -0
  102. package/es/cc/textbox/Properties.js +1 -1
  103. package/es/index.js +2 -1
  104. package/es/library/behaviours/action-band/adapters/controllers/AbstractController.js +10 -0
  105. package/es/library/behaviours/action-band/adapters/controllers/MountController.js +21 -0
  106. package/es/library/behaviours/action-band/adapters/gateways/Repository.js +24 -0
  107. package/es/library/behaviours/action-band/adapters/gateways/Service.js +11 -0
  108. package/es/library/behaviours/action-band/applications/interfaces/State.js +1 -0
  109. package/es/library/behaviours/action-band/applications/interfaces/UseCaseDependencies.js +1 -0
  110. package/es/library/behaviours/action-band/applications/interfaces/gateways/IRepository.js +1 -0
  111. package/es/library/behaviours/action-band/applications/interfaces/gateways/IService.js +1 -0
  112. package/es/library/behaviours/action-band/applications/interfaces/input/InitializeInput.js +1 -0
  113. package/es/library/behaviours/action-band/applications/usecases/AbstractUseCase.js +17 -0
  114. package/es/library/behaviours/action-band/applications/usecases/InitializeUseCase.js +20 -0
  115. package/es/library/behaviours/action-band/domain/entities/ActionBand.js +95 -0
  116. package/es/library/behaviours/action-band/domain/entities/interfaces/IActionBand.js +1 -0
  117. package/es/library/behaviours/action-band/domain/entities/interfaces/IActionModel.js +1 -0
  118. package/es/library/behaviours/action-band/domain/entities/interfaces/IApiPropsModel.js +1 -0
  119. package/es/library/behaviours/action-band/domain/entities/interfaces/Properties.js +1 -0
  120. package/es/library/behaviours/action-band/frameworks/ActionBandBehaviourFactory.js +21 -0
  121. package/es/library/behaviours/action-band/frameworks/ActionHandlersFactory.js +17 -0
  122. package/es/library/behaviours/clip-wrap/adapters/controllers/DestructController.js +3 -3
  123. package/es/library/behaviours/clip-wrap/adapters/controllers/InitializeController.js +3 -3
  124. package/es/library/behaviours/clip-wrap/adapters/gateway/Service.js +4 -0
  125. package/es/library/behaviours/clip-wrap/applications/usecases/ClipWrapUpdateUseCase.js +19 -0
  126. package/es/library/behaviours/float-pagination/adapters/controllers/AbstractController.js +9 -0
  127. package/es/library/behaviours/float-pagination/adapters/controllers/DestructController.js +18 -0
  128. package/es/library/behaviours/float-pagination/adapters/controllers/FloatPaginationController.js +25 -0
  129. package/es/library/behaviours/float-pagination/adapters/controllers/InitializeController.js +18 -0
  130. package/es/library/behaviours/float-pagination/adapters/controllers/ScrollBottomController.js +23 -0
  131. package/es/library/behaviours/float-pagination/adapters/controllers/ScrollTopController.js +23 -0
  132. package/es/library/behaviours/float-pagination/adapters/controllers/UpdateIndexController.js +30 -0
  133. package/es/library/behaviours/float-pagination/adapters/gateway/Repository.js +27 -0
  134. package/es/library/behaviours/float-pagination/adapters/gateway/Service.js +20 -0
  135. package/es/library/behaviours/float-pagination/adapters/presenter/Presenter.js +16 -0
  136. package/es/library/behaviours/float-pagination/applications/interfaces/UseCaseDependencies.js +1 -0
  137. package/es/library/behaviours/float-pagination/applications/interfaces/gateways/IRepository.js +1 -0
  138. package/es/library/behaviours/float-pagination/applications/interfaces/gateways/IService.js +1 -0
  139. package/es/library/behaviours/float-pagination/applications/interfaces/input/DestructInputModel.js +1 -0
  140. package/es/library/behaviours/float-pagination/applications/interfaces/input/FloatPaginationInputModel.js +1 -0
  141. package/es/library/behaviours/float-pagination/applications/interfaces/input/InitializeInputModel.js +1 -0
  142. package/es/library/behaviours/float-pagination/applications/interfaces/input/ScrollTopInputModel.js +1 -0
  143. package/es/library/behaviours/float-pagination/applications/interfaces/input/ScrollbottomInputModel.js +1 -0
  144. package/es/library/behaviours/float-pagination/applications/interfaces/input/UpdateIndexInputModel.js +1 -0
  145. package/es/library/behaviours/float-pagination/applications/interfaces/output/FloatPaginationOutputModel.js +1 -0
  146. package/es/library/behaviours/float-pagination/applications/interfaces/output/IPresenter.js +1 -0
  147. package/es/library/behaviours/float-pagination/applications/usecases/AbstractUseCase.js +17 -0
  148. package/es/library/behaviours/float-pagination/applications/usecases/DestructUsecase.js +15 -0
  149. package/es/library/behaviours/float-pagination/applications/usecases/FloatPaginationUseCase.js +31 -0
  150. package/es/library/behaviours/float-pagination/applications/usecases/InitializeUsecase.js +16 -0
  151. package/es/library/behaviours/float-pagination/applications/usecases/ScrollBottomUseCase.js +23 -0
  152. package/es/library/behaviours/float-pagination/applications/usecases/ScrollTopUseCase.js +23 -0
  153. package/es/library/behaviours/float-pagination/applications/usecases/UpdateIndexUseCase.js +28 -0
  154. package/es/library/behaviours/float-pagination/domain/entities/FloatPagination.js +28 -0
  155. package/es/library/behaviours/float-pagination/domain/entities/interfaces/IFloatPagination.js +1 -0
  156. package/es/library/behaviours/float-pagination/frameworks/ui/ActionsHandlerFactory.js +37 -0
  157. package/es/library/behaviours/float-pagination/frameworks/ui/FloatPaginationBehaviourFactory.js +21 -0
  158. package/es/library/behaviours/float-pagination/frameworks/utils.js +70 -0
  159. package/es/library/behaviours/keyboard-controls/adapters/gateways/Repository.js +2 -1
  160. package/es/library/behaviours/keyboard-controls/applications/usecases/SpacePress.js +1 -1
  161. package/es/library/behaviours/keyboard-controls/domain/entities/KeyboardControls.js +6 -1
  162. package/es/library/behaviours/list-selection/domain/entities/ListItemSelection.js +21 -18
  163. package/es/library/behaviours/search/adapters/controllers/AbstractController.js +9 -0
  164. package/es/library/behaviours/search/adapters/controllers/SearchController.js +26 -0
  165. package/es/library/behaviours/search/adapters/controllers/UpdatePropertiesController.js +32 -0
  166. package/es/library/behaviours/search/adapters/gateway/Repository.js +20 -0
  167. package/es/library/behaviours/search/adapters/gateway/Service.js +12 -0
  168. package/es/library/behaviours/search/adapters/presenter/Presenter.js +16 -0
  169. package/es/library/behaviours/search/adapters/presenter/SearchTranslator.js +6 -0
  170. package/es/library/behaviours/search/applications/interfaces/UseCaseDependencies.js +1 -0
  171. package/es/library/behaviours/search/applications/interfaces/gateways/IRepository.js +1 -0
  172. package/es/library/behaviours/search/applications/interfaces/gateways/IService.js +1 -0
  173. package/es/library/behaviours/search/applications/interfaces/input/SearchInputModel.js +1 -0
  174. package/es/library/behaviours/search/applications/interfaces/input/UpdatePropertiesInputModel.js +1 -0
  175. package/es/library/behaviours/search/applications/interfaces/output/IPresenter.js +1 -0
  176. package/es/library/behaviours/search/applications/interfaces/output/SearchOutputModel.js +1 -0
  177. package/es/library/behaviours/search/applications/usecases/AbstractUseCase.js +17 -0
  178. package/es/library/behaviours/search/applications/usecases/SearchUseCase.js +28 -0
  179. package/es/library/behaviours/search/applications/usecases/UpdatePropertiesUsecase.js +25 -0
  180. package/es/library/behaviours/search/domain/entities/Search.js +23 -0
  181. package/es/library/behaviours/search/domain/entities/interfaces/ISearch.js +1 -0
  182. package/es/library/behaviours/search/frameworks/ui/EventHandlerFactory.js +25 -0
  183. package/es/library/behaviours/search/frameworks/ui/SearchStringStoreBehaviourFactory.js +26 -0
  184. package/es/library/behaviours/search-box/adapters/controllers/AbstractController.js +9 -0
  185. package/es/library/behaviours/search-box/adapters/controllers/ClearSearchController.js +21 -0
  186. package/es/library/behaviours/search-box/adapters/controllers/SearchController.js +26 -0
  187. package/es/library/behaviours/search-box/adapters/gateway/Repository.js +28 -0
  188. package/es/library/behaviours/search-box/adapters/gateway/Service.js +12 -0
  189. package/es/library/behaviours/search-box/adapters/presenter/Presenter.js +21 -0
  190. package/es/library/behaviours/search-box/applications/interfaces/UseCaseDependencies.js +1 -0
  191. package/es/library/behaviours/search-box/applications/interfaces/gateways/IRepository.js +1 -0
  192. package/es/library/behaviours/search-box/applications/interfaces/gateways/IService.js +1 -0
  193. package/es/library/behaviours/search-box/applications/interfaces/input/ClearSearchInputModel.js +1 -0
  194. package/es/library/behaviours/search-box/applications/interfaces/input/SearchInputModel.js +1 -0
  195. package/es/library/behaviours/search-box/applications/interfaces/output/IPresenter.js +1 -0
  196. package/es/library/behaviours/search-box/applications/interfaces/output/SearchOutputModel.js +1 -0
  197. package/es/library/behaviours/search-box/applications/usecases/AbstractUseCase.js +17 -0
  198. package/es/library/behaviours/search-box/applications/usecases/ClearSearchUseCase.js +24 -0
  199. package/es/library/behaviours/search-box/applications/usecases/SearchUseCase.js +25 -0
  200. package/es/library/behaviours/search-box/domain/entities/Search.js +22 -0
  201. package/es/library/behaviours/search-box/domain/entities/interfaces/ISearch.js +1 -0
  202. package/es/library/behaviours/search-box/frameworks/ui/ActionsHandlerFactory.js +24 -0
  203. package/es/library/behaviours/search-box/frameworks/ui/SearchBehaviourFactory.js +26 -0
  204. package/es/library/behaviours/sort-by/adapters/controllers/{SortBy.js → SortByController.js} +6 -6
  205. package/es/library/behaviours/sort-by/adapters/gateway/Repository.js +18 -6
  206. package/es/library/behaviours/sort-by/adapters/gateway/Service.js +2 -2
  207. package/es/library/behaviours/sort-by/adapters/presenter/Presenter.js +8 -1
  208. package/es/library/behaviours/sort-by/applications/interfaces/input/UpdateSortByUseCaseInputModel.js +1 -0
  209. package/es/library/behaviours/sort-by/applications/interfaces/output/SearchOutputModel.js +1 -0
  210. package/es/library/behaviours/sort-by/applications/usecases/{SortBy.js → SortByUseCase.js} +12 -13
  211. package/es/library/behaviours/sort-by/applications/usecases/UpdateSortByUseCase.js +25 -0
  212. package/es/library/behaviours/sort-by/domain/entities/SortBy.js +11 -25
  213. package/es/library/behaviours/sort-by/frameworks/ui/ActionsHandlerFactory.js +7 -5
  214. package/es/library/behaviours/sort-by/frameworks/ui/SortByBehaviourFactory.js +17 -7
  215. package/es/library/custom-component/adapters/gateways/event-manager/EventManager.js +9 -3
  216. package/es/library/custom-component/applications/usecases/DispatchUseCase.js +1 -0
  217. package/es/library/custom-component/applications/usecases/InitializeUseCase.js +1 -0
  218. package/es/library/custom-component/applications/usecases/MountUseCase.js +1 -0
  219. package/es/library/custom-component/applications/usecases/SetRefUseCase.js +7 -0
  220. package/es/library/custom-component/applications/usecases/UnmountUseCase.js +1 -0
  221. package/es/library/custom-component/applications/usecases/UpdatePropertyUseCase.js +1 -0
  222. package/es/library/custom-component/domain/entities/Component.js +1 -0
  223. package/es/library/custom-component/domain/entities/ComponentProperties.js +1 -1
  224. package/es/library/custom-component/domain/entities/Logger.js +7 -12
  225. package/es/library/dot/components/action-location/frameworks/ui/ActionComponentMapping.js +7 -1
  226. package/es/library/dot/components/form-fields/currency/frameworks/ui/CurrencyView.js +2 -0
  227. package/es/library/dot/components/form-fields/decimal/frameworks/ui/DecimalView.js +2 -0
  228. package/es/library/dot/components/form-fields/email/frameworks/ui/Email.js +1 -1
  229. package/es/library/dot/components/form-fields/email/frameworks/ui/EmailView.js +2 -0
  230. package/es/library/dot/components/form-fields/number/frameworks/ui/NumberView.js +2 -0
  231. package/es/library/dot/components/form-fields/phone/frameworks/ui/PhoneView.js +2 -0
  232. package/es/library/dot/components/form-fields/textarea/frameworks/ui/TextArea.js +1 -1
  233. package/es/library/dot/components/form-fields/textarea/frameworks/ui/TextAreaView.js +4 -2
  234. package/es/library/dot/components/form-fields/textbox/frameworks/ui/TextBoxView.js +2 -0
  235. package/es/library/dot/components/form-fields/url/frameworks/ui/UrlView.js +2 -0
  236. package/es/library/dot/components/table-list/adapters/controllers/ScrollController.js +2 -2
  237. package/es/library/dot/components/table-list/adapters/controllers/index.js +0 -2
  238. package/es/library/dot/components/table-list/frameworks/ui/EventHandlersFactory.js +1 -2
  239. package/es/library/dot/components/table-list/frameworks/ui/TableListView.js +24 -1
  240. package/es/library/dot/components/table-list/frameworks/ui/css/TableList.module.css +19 -2
  241. package/es/library/dot/components/table-list/frameworks/ui/sub-components/header/HeaderData.js +1 -1
  242. package/es/library/dot/components/table-list/frameworks/ui/sub-components/row/Row.js +4 -6
  243. package/es/library/dot/legacy-to-new-arch/action-band-components/search/frameworks/ui/Search.js +41 -0
  244. package/es/library/dot/legacy-to-new-arch/action-band-components/search/frameworks/ui/SearchTranslator.js +16 -0
  245. package/es/library/dot/legacy-to-new-arch/action-band-components/search/frameworks/ui/SearchView.js +37 -0
  246. package/es/library/dot/legacy-to-new-arch/action-icon/frameworks/ui/ActionIconView.js +5 -1
  247. package/es/library/dot/legacy-to-new-arch/email/frameworks/ui/EmailView.js +4 -2
  248. package/es/library/dot/legacy-to-new-arch/floating-pagination/frameworks/ui/FloatingPagination.js +10 -0
  249. package/es/library/dot/legacy-to-new-arch/floating-pagination/frameworks/ui/FloatingPaginationView.js +47 -0
  250. package/es/library/dot/legacy-to-new-arch/highlighted-value/frameworks/ui/HighlightedValueView.js +6 -1
  251. package/es/library/dot/legacy-to-new-arch/index.js +3 -1
  252. package/es/library/dot/legacy-to-new-arch/link/frameworks/ui/LinkView.js +4 -2
  253. package/es/library/dot/legacy-to-new-arch/list-item/frameworks/ui/ListItemView.js +4 -0
  254. package/es/library/dot/legacy-to-new-arch/radio-dropdown/frameworks/ui/RadioDropdown.js +12 -0
  255. package/es/library/dot/legacy-to-new-arch/radio-dropdown/frameworks/ui/RadioDropdownView.js +125 -0
  256. package/es/library/dot/legacy-to-new-arch/radio-dropdown/frameworks/ui/css/RadioDropdown.module.css +23 -0
  257. package/es/library/dot/legacy-to-new-arch/ribbon/frameworks/ui/Ribbon.js +10 -0
  258. package/es/library/dot/legacy-to-new-arch/ribbon/frameworks/ui/RibbonView.js +37 -0
  259. package/es/library/dot/legacy-to-new-arch/sort-dropdown/frameworks/ui/SortDropdown.js +31 -0
  260. package/es/library/dot/legacy-to-new-arch/sort-dropdown/frameworks/ui/SortDropdownTranslator.js +33 -0
  261. package/es/library/dot/legacy-to-new-arch/sort-dropdown/frameworks/ui/SortDropdownView.js +83 -0
  262. package/es/library/dot/legacy-to-new-arch/table-field-components/checkbox-field/frameworks/ui/CheckboxField.js +12 -2
  263. package/es/library/dot/legacy-to-new-arch/table-field-components/checkbox-field/frameworks/ui/CheckboxFieldView.js +8 -5
  264. package/es/library/dot/legacy-to-new-arch/table-field-components/checkbox-field/frameworks/ui/EventHandlersFactory.js +3 -3
  265. package/es/library/dot/legacy-to-new-arch/table-field-components/email-field/frameworks/ui/EmailField.js +3 -3
  266. package/es/library/dot/legacy-to-new-arch/table-field-components/email-field/frameworks/ui/EmailFieldView.js +8 -6
  267. package/es/library/dot/legacy-to-new-arch/table-field-components/highlighted-value-field/frameworks/ui/EventHandlersFactory.js +26 -0
  268. package/es/library/dot/legacy-to-new-arch/table-field-components/highlighted-value-field/frameworks/ui/HighlightedValueField.js +23 -0
  269. package/es/library/dot/legacy-to-new-arch/table-field-components/highlighted-value-field/frameworks/ui/HighlightedValueFieldView.js +24 -0
  270. package/es/library/dot/legacy-to-new-arch/table-field-components/index.js +22 -5
  271. package/es/library/dot/legacy-to-new-arch/table-field-components/labeled-avatar-field/frameworks/ui/EventHandlersFactory.js +26 -0
  272. package/es/library/dot/legacy-to-new-arch/table-field-components/labeled-avatar-field/frameworks/ui/LabeledAvatarField.js +23 -0
  273. package/es/library/dot/legacy-to-new-arch/table-field-components/labeled-avatar-field/frameworks/ui/LabeledAvatarFieldView.js +22 -0
  274. package/es/library/dot/legacy-to-new-arch/table-field-components/link-field/frameworks/ui/EventHandlersFactory.js +26 -0
  275. package/es/library/dot/legacy-to-new-arch/table-field-components/link-field/frameworks/ui/LinkField.js +23 -0
  276. package/es/library/dot/legacy-to-new-arch/table-field-components/link-field/frameworks/ui/LinkFieldView.js +26 -0
  277. package/es/library/dot/legacy-to-new-arch/table-field-components/lookup-field/frameworks/ui/LookupFieldView.js +1 -1
  278. package/es/library/dot/legacy-to-new-arch/table-field-components/phone-field/frameworks/ui/PhoneFieldView.js +1 -1
  279. package/es/library/dot/legacy-to-new-arch/table-field-components/radio-dropdown-field/frameworks/ui/EventHandlersFactory.js +46 -0
  280. package/es/library/dot/legacy-to-new-arch/table-field-components/radio-dropdown-field/frameworks/ui/RadioDropdownField.js +49 -0
  281. package/es/library/dot/legacy-to-new-arch/table-field-components/radio-dropdown-field/frameworks/ui/RadioDropdownFieldView.js +43 -0
  282. package/es/library/dot/legacy-to-new-arch/table-field-components/radio-dropdown-field/frameworks/ui/css/RadioDropdownField.module.css +3 -0
  283. package/es/library/dot/legacy-to-new-arch/table-field-components/switch-field/frameworks/ui/EventHandlersFactory.js +3 -3
  284. package/es/library/dot/legacy-to-new-arch/table-field-components/switch-field/frameworks/ui/SwitchField.js +14 -4
  285. package/es/library/dot/legacy-to-new-arch/table-field-components/switch-field/frameworks/ui/SwitchFieldView.js +8 -4
  286. package/es/library/dot/legacy-to-new-arch/table-field-components/tag-field/frameworks/ui/EventHandlersFactory.js +26 -0
  287. package/es/library/dot/legacy-to-new-arch/table-field-components/tag-field/frameworks/ui/TagField.js +23 -0
  288. package/es/library/dot/legacy-to-new-arch/table-field-components/tag-field/frameworks/ui/TagFieldView.js +34 -0
  289. package/es/library/dot/legacy-to-new-arch/table-field-components/tags-field/frameworks/ui/EventHandlersFactory.js +26 -0
  290. package/es/library/dot/legacy-to-new-arch/table-field-components/tags-field/frameworks/ui/TagsField.js +23 -0
  291. package/es/library/dot/legacy-to-new-arch/table-field-components/tags-field/frameworks/ui/TagsFieldView.js +18 -0
  292. package/es/library/dot/legacy-to-new-arch/table-field-components/tags-list-dropdown-field/frameworks/ui/TagsListDropdownField.js +44 -0
  293. package/es/library/dot/legacy-to-new-arch/table-field-components/tags-list-dropdown-field/frameworks/ui/TagsListDropdownFieldView.js +24 -0
  294. package/es/library/dot/legacy-to-new-arch/table-field-components/text-field/frameworks/ui/EventHandlersFactory.js +26 -0
  295. package/es/library/dot/legacy-to-new-arch/table-field-components/text-field/frameworks/ui/TextField.js +23 -0
  296. package/es/library/dot/legacy-to-new-arch/table-field-components/text-field/frameworks/ui/TextFieldView.js +40 -0
  297. package/es/library/dot/legacy-to-new-arch/table-field-components/url-field/frameworks/ui/UrlFieldView.js +1 -1
  298. package/es/library/dot/legacy-to-new-arch/tag/frameworks/ui/Tag.js +11 -0
  299. package/es/library/dot/legacy-to-new-arch/tag/frameworks/ui/Tag.module.css +8 -0
  300. package/es/library/dot/legacy-to-new-arch/tag/frameworks/ui/TagView.js +96 -0
  301. package/es/library/dot/legacy-to-new-arch/tags-list-dropdown/frameworks/ui/TagContractAdapter.js +24 -0
  302. package/es/library/dot/legacy-to-new-arch/tags-list-dropdown/frameworks/ui/TagsListDropdown.js +12 -0
  303. package/es/library/dot/legacy-to-new-arch/tags-list-dropdown/frameworks/ui/TagsListDropdownView.js +42 -0
  304. package/es/library/dot/legacy-to-new-arch/text/frameworks/ui/Text.js +2 -2
  305. package/es/library/dot/legacy-to-new-arch/text/frameworks/ui/TextView.js +22 -1
  306. package/es/platform/.DS_Store +0 -0
  307. package/es/platform/app-context-behaviour/adapters/controllers/AbstractController.js +9 -0
  308. package/es/platform/app-context-behaviour/adapters/controllers/UpdatePropertiesController.js +32 -0
  309. package/es/platform/app-context-behaviour/adapters/gateway/Repository.js +22 -0
  310. package/es/platform/app-context-behaviour/adapters/gateway/Service.js +10 -0
  311. package/es/platform/app-context-behaviour/adapters/presenter/Presenter.js +16 -0
  312. package/es/platform/app-context-behaviour/applications/interfaces/UseCaseDependencies.js +1 -0
  313. package/es/platform/app-context-behaviour/applications/interfaces/gateways/IRepository.js +1 -0
  314. package/es/platform/app-context-behaviour/applications/interfaces/gateways/IService.js +1 -0
  315. package/es/platform/app-context-behaviour/applications/interfaces/input/UpdatePropertiesInputModel.js +1 -0
  316. package/es/platform/app-context-behaviour/applications/interfaces/output/BehaviourOutputModel.js +1 -0
  317. package/es/platform/app-context-behaviour/applications/interfaces/output/IPresenter.js +1 -0
  318. package/es/platform/app-context-behaviour/applications/usecases/AbstractUseCase.js +17 -0
  319. package/es/platform/app-context-behaviour/applications/usecases/UpdatePropertiesUsecase.js +25 -0
  320. package/es/platform/app-context-behaviour/domain/entities/AppContext.js +44 -0
  321. package/es/platform/app-context-behaviour/domain/entities/interfaces/IAppContext.js +1 -0
  322. package/es/platform/app-context-behaviour/frameworks/AppContextBehaviourFactory.js +2 -2
  323. package/es/platform/app-context-behaviour/frameworks/EventHandlerFactory.js +22 -0
  324. package/es/platform/client-actions/components/interfaces/ActionViewModel.js +1 -0
  325. package/es/platform/client-actions/components/row-actions-renderer/frameworks/ui/RowActions/RowActionsRenderer.module.css +4 -0
  326. package/es/platform/client-scripts/bc/zclient-scripts-execution/Constants.js +2 -4
  327. package/es/platform/client-scripts/behaviour/zclient-scripts-execution/domain/entities/ClientScriptExecutor.js +33 -60
  328. package/es/platform/client-scripts/behaviour/zclient-scripts-fetch/domain/entities/interfaces/ClientScriptModel.js +5 -1
  329. package/es/platform/column-chooser/adapters/controllers/ColumnChooserOpenController.js +14 -6
  330. package/es/platform/column-chooser/adapters/controllers/ColumnChooserUpdateController.js +22 -0
  331. package/es/platform/column-chooser/adapters/gateways/Repository.js +12 -1
  332. package/es/platform/column-chooser/adapters/gateways/Service.js +2 -0
  333. package/es/platform/column-chooser/applications/interfaces/input/ColumnChooserUpdateInput.js +1 -0
  334. package/es/platform/column-chooser/applications/usecases/ColumnChooserSaveUseCase.js +8 -1
  335. package/es/platform/column-chooser/applications/usecases/ColumnChooserUpdateUseCase.js +35 -0
  336. package/es/platform/column-chooser/domain/entities/ColumnChooserImp.js +6 -0
  337. package/es/platform/column-chooser/frameworks/EventHandlersFactory.js +6 -4
  338. package/es/platform/components/index.js +2 -1
  339. package/es/platform/components/smart-action-band/adapters/presenters/ActionBandTranslator.js +132 -0
  340. package/es/platform/components/smart-action-band/adapters/presenters/translators/interfaces/ActionBandTranslatorState.js +1 -0
  341. package/es/platform/components/smart-action-band/adapters/presenters/utils/DefaultClientActions.js +179 -0
  342. package/es/platform/components/smart-action-band/adapters/resources/SmartActionBandResource.js +46 -0
  343. package/es/platform/components/smart-action-band/applications/interfaces/ISmartActionBandResource.js +1 -0
  344. package/es/platform/components/smart-action-band/applications/interfaces/State.js +1 -0
  345. package/es/platform/components/smart-action-band/applications/interfaces/UseCaseDependencies.js +1 -0
  346. package/es/platform/components/smart-action-band/applications/interfaces/output/IPresenter.js +1 -0
  347. package/es/platform/components/smart-action-band/applications/usecases/AbstractUseCase.js +18 -0
  348. package/es/platform/components/smart-action-band/domain/entities/interfaces/Properties.js +1 -0
  349. package/es/platform/components/smart-action-band/frameworks/EventHandlersFactory.js +147 -0
  350. package/es/platform/components/smart-action-band/frameworks/SmartActionBand.js +5 -0
  351. package/es/platform/components/smart-action-band/frameworks/SmartActionBandFactory.js +58 -0
  352. package/es/platform/components/smart-action-band/frameworks/SmartActionBandSdkFactory.js +24 -0
  353. package/es/platform/components/smart-action-band/frameworks/SmartActionBandView.js +48 -0
  354. package/es/platform/components/table-connected/adapters/controllers/ScrollController.js +29 -8
  355. package/es/platform/components/table-connected/adapters/controllers/ScrollEndReachedController.js +23 -0
  356. package/es/platform/components/table-connected/adapters/resources/SmartTableResource.js +224 -8
  357. package/es/platform/components/table-connected/frameworks/EventHandlersFactory.js +39 -12
  358. package/es/platform/components/table-connected/frameworks/ListSdkFactory.js +4 -2
  359. package/es/platform/components/table-connected/frameworks/TableConnectedFactory.js +7 -1
  360. package/es/platform/components/table-connected/frameworks/TableConnectedView.js +2 -0
  361. package/es/platform/data-source/http-template/fetchLookupFields.js +0 -6
  362. package/es/platform/data-source/http-template/getComponentMapping.js +17 -0
  363. package/es/platform/data-source/http-template/getRecords.js +1 -0
  364. package/es/platform/data-source/http-template/getSingleRecord.js +51 -0
  365. package/es/platform/data-source/index.js +5 -1
  366. package/es/platform/data-source/utils/validation-rules/FieldConditions.js +1 -1
  367. package/es/platform/sdk/frameworks/Sdk.js +7 -0
  368. package/es/platform/sdk-behaviour/adapters/controllers/InitializeController.js +7 -2
  369. package/es/platform/sdk-behaviour/applications/usecases/CreateResourceInstanceUseCase.js +10 -1
  370. package/es/platform/zfield/applications/usecases/FetchSuccessUseCase.js +33 -0
  371. package/es/platform/zfield/domain/entities/fields-manager/FieldsManager.js +5 -0
  372. package/es/platform/zform/adapters/controllers/GetInitialRecordSuccessController.js +31 -0
  373. package/es/platform/zform/adapters/gateway/FormRepository.js +10 -2
  374. package/es/platform/zform/adapters/gateway/Service.js +2 -0
  375. package/es/platform/zform/adapters/presenter/FormTranslator.js +9 -0
  376. package/es/platform/zform/adapters/presenter/translators/fields/CurrencyFieldTranslator.js +1 -0
  377. package/es/platform/zform/adapters/presenter/translators/fields/DecimalFieldTranslator.js +1 -0
  378. package/es/platform/zform/adapters/presenter/translators/fields/EmailFieldTranslator.js +1 -0
  379. package/es/platform/zform/adapters/presenter/translators/fields/LookUpFieldTranslator.js +11 -7
  380. package/es/platform/zform/adapters/presenter/translators/fields/NumberFieldTranslator.js +1 -0
  381. package/es/platform/zform/adapters/presenter/translators/fields/PhoneFieldTranslator.js +1 -0
  382. package/es/platform/zform/adapters/presenter/translators/fields/TextAreaFieldTranslator.js +1 -0
  383. package/es/platform/zform/adapters/presenter/translators/fields/TextFieldTranslator.js +1 -0
  384. package/es/platform/zform/adapters/presenter/translators/fields/URLFieldTranslator.js +1 -0
  385. package/es/platform/zform/adapters/presenter/utils/sanitizeHtmlString.js +2 -2
  386. package/es/platform/zform/applications/interfaces/input/GetInitialRecordSuccessUseCaseInputModel.js +1 -0
  387. package/es/platform/zform/applications/usecases/GetInitialRecordSuccessUseCase.js +132 -0
  388. package/es/platform/zform/applications/usecases/InitializeUseCase.js +54 -30
  389. package/es/platform/zform/applications/usecases/LookupFieldSuccessUseCase.js +5 -0
  390. package/es/platform/zform/applications/usecases/MyFormSuccessUseCase.js +12 -11
  391. package/es/platform/zform/applications/usecases/SubmitValidationCompletedUseCase.js +21 -8
  392. package/es/platform/zform/domain/ZField.js +7 -5
  393. package/es/platform/zform/domain/ZForm.js +97 -20
  394. package/es/platform/zform/frameworks/ui/EventHandlerFactory.js +23 -5
  395. package/es/platform/zform/frameworks/ui/ZFormBehaviourFactory.js +2 -0
  396. package/es/platform/zlist/adapters/controllers/RefreshRecordsRequestedController.js +21 -0
  397. package/es/platform/zlist/adapters/controllers/SortController.js +2 -2
  398. package/es/platform/zlist/adapters/gateways/Repository.js +6 -11
  399. package/es/platform/zlist/adapters/gateways/Service.js +2 -0
  400. package/es/platform/zlist/adapters/presenters/TableTranslator.js +57 -13
  401. package/es/platform/zlist/adapters/presenters/translators/ColumnTranslator.js +57 -49
  402. package/es/platform/zlist/adapters/presenters/translators/FieldVariations.js +25 -0
  403. package/es/platform/zlist/adapters/presenters/translators/Header.js +29 -21
  404. package/es/platform/zlist/adapters/presenters/translators/HeadersTranslator.js +3 -3
  405. package/es/platform/zlist/adapters/presenters/translators/Row.js +16 -2
  406. package/es/platform/zlist/adapters/presenters/translators/RowsTranslator.js +3 -1
  407. package/es/platform/zlist/adapters/presenters/translators/fields/BooleanFieldTranslator.js +87 -12
  408. package/es/platform/zlist/adapters/presenters/translators/fields/CurrencyFieldTranslator.js +66 -11
  409. package/es/platform/zlist/adapters/presenters/translators/fields/DateFieldTranslator.js +33 -8
  410. package/es/platform/zlist/adapters/presenters/translators/fields/DateTimeFieldTranslator.js +33 -8
  411. package/es/platform/zlist/adapters/presenters/translators/fields/DecimalFieldTranslator.js +16 -9
  412. package/es/platform/zlist/adapters/presenters/translators/fields/EmailFieldTranslator.js +29 -9
  413. package/es/platform/zlist/adapters/presenters/translators/fields/FormulaFieldTranslator.js +23 -27
  414. package/es/platform/zlist/adapters/presenters/translators/fields/LookUpFieldTranslator.js +106 -17
  415. package/es/platform/zlist/adapters/presenters/translators/fields/MultiLineFieldTranslator.js +16 -9
  416. package/es/platform/zlist/adapters/presenters/translators/fields/MultiSelectFieldTranslator.js +100 -26
  417. package/es/platform/zlist/adapters/presenters/translators/fields/NumberFieldTranslator.js +16 -9
  418. package/es/platform/zlist/adapters/presenters/translators/fields/PercentageFieldTranslator.js +16 -9
  419. package/es/platform/zlist/adapters/presenters/translators/fields/PhoneFieldTranslator.js +32 -9
  420. package/es/platform/zlist/adapters/presenters/translators/fields/PickListFieldTranslator.js +167 -26
  421. package/es/platform/zlist/adapters/presenters/translators/fields/SingleLineFieldTranslator.js +16 -9
  422. package/es/platform/zlist/adapters/presenters/translators/fields/URLFieldTranslator.js +32 -9
  423. package/es/platform/zlist/adapters/presenters/utils/DateAndTimeFormat.js +25 -0
  424. package/es/platform/zlist/adapters/presenters/utils/DefaultClientActions.js +7 -4
  425. package/es/platform/zlist/adapters/presenters/utils/fieldSortLabels.js +38 -0
  426. package/es/platform/zlist/applications/entities-factory/ListFactory.js +2 -2
  427. package/es/platform/zlist/applications/interfaces/input/GetSortConfigUseCaseInputModel.js +1 -0
  428. package/es/platform/zlist/applications/interfaces/input/RefreshRecordsRequestedUseCaseInputModel.js +1 -0
  429. package/es/platform/zlist/applications/interfaces/input/SetSortConfigUseCaseInputModel.js +1 -0
  430. package/es/platform/zlist/applications/usecases/GetSortConfigUseCase.js +17 -0
  431. package/es/platform/zlist/applications/usecases/RecordSuccessCallbackUsecase.js +1 -1
  432. package/es/platform/zlist/applications/usecases/RefreshRecordsRequestedUseCase.js +17 -0
  433. package/es/platform/zlist/applications/usecases/SetSortConfigUseCase.js +26 -0
  434. package/es/platform/zlist/applications/usecases/SortUseCase.js +6 -6
  435. package/es/platform/zlist/domain/entities/List.js +32 -16
  436. package/es/platform/zlist/domain/entities/interfaces/Properties.js +5 -5
  437. package/es/platform/zlist/frameworks/EventHandlersFactory.js +3 -4
  438. package/es/platform/zlist/frameworks/ZListBehaviourFactory.js +15 -13
  439. package/es/platform/zrecord/adapters/controllers/FilterRecordLocalController.js +28 -0
  440. package/es/platform/zrecord/adapters/controllers/UpdateRecordController.js +30 -0
  441. package/es/platform/zrecord/adapters/gateways/Repository.js +5 -2
  442. package/es/platform/zrecord/adapters/gateways/Service.js +4 -0
  443. package/es/platform/zrecord/applications/entities-factory/RecordsManagerFactory.js +2 -2
  444. package/es/platform/zrecord/applications/interfaces/input/ClearAllFiltersUseCaseInputModel.js +1 -0
  445. package/es/platform/zrecord/applications/interfaces/input/FilterRecordInputModel.js +1 -0
  446. package/es/platform/zrecord/applications/interfaces/input/GetFilterConditionUseCaseInputModel.js +1 -0
  447. package/es/platform/zrecord/applications/interfaces/input/GetFilterConfigUseCaseInputModel.js +1 -0
  448. package/es/platform/zrecord/applications/interfaces/input/RefreshRecordsUseCaseInputModel.js +1 -0
  449. package/es/platform/zrecord/applications/interfaces/input/SetFilterUseCaseInputModel.js +1 -0
  450. package/es/platform/zrecord/applications/interfaces/input/UpdateRecordInputModel.js +0 -0
  451. package/es/platform/zrecord/applications/usecases/ClearAllFiltersUseCase.js +24 -0
  452. package/es/platform/zrecord/applications/usecases/FilterRecordUseCase.js +21 -0
  453. package/es/platform/zrecord/applications/usecases/GetFilterConditionUseCase.js +15 -0
  454. package/es/platform/zrecord/applications/usecases/GetFilterConfigUseCase.js +15 -0
  455. package/es/platform/zrecord/applications/usecases/RefreshRecordsUseCase.js +14 -0
  456. package/es/platform/zrecord/applications/usecases/SetFilterUseCase.js +29 -0
  457. package/es/platform/zrecord/applications/usecases/UpdateRecordUseCase.js +30 -0
  458. package/es/platform/zrecord/domain/entities/Filter.js +247 -0
  459. package/es/platform/zrecord/domain/entities/RecordsManager.js +43 -1
  460. package/es/platform/zrecord/domain/entities/interfaces/IFilter.js +1 -0
  461. package/es/platform/zrecord/frameworks/ActionsHandlersFactory.js +7 -1
  462. package/es/platform/zrecord/frameworks/RecordBehaviourFactory.js +11 -1
  463. package/package.json +26 -28
  464. package/es/bc/sort-by/SortOrderEnum.js +0 -8
  465. package/es/library/behaviours/sort-by/frameworks/ui/DemoBehaviour.js +0 -20
  466. package/es/library/dot/components/table-list/adapters/controllers/SortByController.js +0 -25
  467. package/es/library/dot/components/table-list/adapters/controllers/SortedController.js +0 -18
  468. package/es/library/dot/components/table-list/frameworks/ui/handlers/HandleSortClick.js +0 -12
  469. package/es/platform/components/table-connected/adapters/controllers/ColumnChooserOpenedController.js +0 -28
  470. package/es/platform/components/table-connected/adapters/controllers/ColumnChooserUpdateController.js +0 -31
  471. package/es/platform/zlist/adapters/gateways/SortBy.js +0 -38
  472. package/es/platform/zlist/domain/entities/SortBy.js +0 -58
  473. /package/es/{library/behaviours/sort-by/applications/interfaces/output/SortByOutputModel.js → bc/float-pagination/types/FloatPaginationBehaviourState.js} +0 -0
  474. /package/es/{platform/zlist/applications/interfaces/gateways/ISortBy.js → bc/list-selection/Types.js} +0 -0
  475. /package/es/{platform/zlist/domain/entities/interfaces/ISortBy.js → bc/search-box/types/SearchBehaviourState.js} +0 -0
@@ -0,0 +1,33 @@
1
+ import SearchTranslator from "../../../../../behaviours/search/adapters/presenter/SearchTranslator";
2
+ export default class SortDropdownTranslator {
3
+ static transformState(state) {
4
+ const {
5
+ searchString
6
+ } = state.behaviours.search;
7
+ const {
8
+ taggedOption,
9
+ options,
10
+ selectedOption
11
+ } = state.properties;
12
+ const transformedOptions = options.map(option => ({
13
+ id: option.name,
14
+ value: option.label,
15
+ ...option
16
+ }));
17
+ return { ...state,
18
+ viewModel: { ...state.properties,
19
+ ...state.viewModel,
20
+ taggedOption: {
21
+ id: taggedOption
22
+ },
23
+ selectedOption: {
24
+ id: selectedOption.name,
25
+ value: selectedOption.label,
26
+ ...selectedOption
27
+ },
28
+ options: SearchTranslator(searchString, 'value', transformedOptions)
29
+ }
30
+ };
31
+ }
32
+
33
+ }
@@ -0,0 +1,83 @@
1
+ import React from "react";
2
+ import SortDropdown from "@zohodesk-private/desk-components/es/SortDropdown/SortDropdown";
3
+ import SortDropdownConstants from "../../../../../../cc/sort-dropdown/Constants";
4
+
5
+ function SortDropdownView(_ref, ref) {
6
+ let {
7
+ state,
8
+ helpers
9
+ } = _ref;
10
+ const {
11
+ dispatch
12
+ } = helpers;
13
+ const {
14
+ options,
15
+ selectedOption,
16
+ taggedOption,
17
+ optionTagLabel,
18
+ dropdownTooltip,
19
+ iconTooltip,
20
+ hasSearch,
21
+ searchPlaceholder,
22
+ footerButtonLabel,
23
+ emptyListMessage,
24
+ isLoading,
25
+ isResetDisabled
26
+ } = state.viewModel;
27
+
28
+ const handleSort = sortOption => {
29
+ dispatch({
30
+ type: SortDropdownConstants.SORT_DROPDOWN_SORT_REQUESTED,
31
+ payload: {
32
+ name: sortOption.id,
33
+ label: sortOption.value,
34
+ order: sortOption.order
35
+ }
36
+ });
37
+ };
38
+
39
+ const handleSearch = searchValue => {
40
+ dispatch({
41
+ type: SortDropdownConstants.SORT_DROPDOWN_SEARCH_REQUESTED,
42
+ payload: {
43
+ searchValue
44
+ }
45
+ });
46
+ };
47
+
48
+ const handleReset = () => {
49
+ dispatch({
50
+ type: SortDropdownConstants.SORT_DROPDOWN_RESET_REQUESTED,
51
+ payload: {}
52
+ });
53
+ };
54
+
55
+ return /*#__PURE__*/React.createElement(SortDropdown, {
56
+ options: options,
57
+ selectedOption: selectedOption,
58
+ taggedOption: taggedOption,
59
+ optionTagLabel: optionTagLabel,
60
+ dropdownTooltip: dropdownTooltip,
61
+ iconTooltip: iconTooltip,
62
+ hasSearch: hasSearch,
63
+ searchPlaceholder: searchPlaceholder,
64
+ footerButtonLabel: footerButtonLabel,
65
+ emptyListMessage: emptyListMessage,
66
+ isLoading: isLoading,
67
+ isResetDisabled: isResetDisabled,
68
+ onSort: handleSort,
69
+ onSearch: handleSearch,
70
+ onReset: handleReset,
71
+ customProps: {
72
+ container: {
73
+ ref: ref
74
+ },
75
+ iconButton: {
76
+ dataId: "sortDropdown"
77
+ }
78
+ },
79
+ testId: "sortDropdown"
80
+ });
81
+ }
82
+
83
+ export default SortDropdownView;
@@ -1,12 +1,22 @@
1
1
  import { createCustomComponent } from "../../../../../../custom-component";
2
- import BooleanProperties from "../../../../../../../cc/fields/boolean/Properties";
2
+ import CheckboxProperties from "../../../../../../../cc/checkbox/Properties";
3
3
  import BooleanEvents from "../../../../../../../cc/fields/boolean/Events";
4
4
  import CheckboxFieldView from "./CheckboxFieldView";
5
5
  import { EventHandlersFactory } from "./EventHandlersFactory";
6
6
  const CheckboxField = createCustomComponent({
7
7
  name: 'CheckboxField',
8
8
  View: CheckboxFieldView,
9
- properties: BooleanProperties,
9
+ properties: { ...CheckboxProperties,
10
+ fieldName: {
11
+ required: false,
12
+ defaultValue: '',
13
+ typeMetadata: {
14
+ schema: {
15
+ type: 'string'
16
+ }
17
+ }
18
+ }
19
+ },
10
20
  events: BooleanEvents,
11
21
  eventHandlers: EventHandlersFactory.create()
12
22
  });
@@ -5,14 +5,17 @@ export default function CheckboxFieldView(_ref, ref) {
5
5
  state
6
6
  } = _ref;
7
7
  const {
8
- value
8
+ checked,
9
+ disabled,
10
+ readonly,
11
+ tooltip
9
12
  } = state.properties;
10
13
  return /*#__PURE__*/React.createElement(Checkbox, {
11
14
  getRef: ref,
12
- checked: value,
13
- disabled: false,
14
- readonly: false,
15
+ checked: checked,
16
+ disabled: disabled,
17
+ readonly: readonly,
15
18
  label: "",
16
- tooltip: ""
19
+ tooltip: tooltip
17
20
  });
18
21
  }
@@ -8,10 +8,10 @@ export class EventHandlersFactory {
8
8
  dispatch
9
9
  } = input;
10
10
  const {
11
- name: fieldName,
12
- value: currentValue
11
+ fieldName,
12
+ checked
13
13
  } = state.properties;
14
- const toggledValue = !currentValue;
14
+ const toggledValue = !checked;
15
15
  dispatch({
16
16
  type: FieldConstants.FIELD_CHANGED,
17
17
  payload: {
@@ -1,12 +1,12 @@
1
1
  import { createCustomComponent } from "../../../../../../custom-component";
2
- import EmailProperties from "../../../../../../../cc/fields/email/Properties";
3
- import EmailEvents from "../../../../../../../cc/fields/email/Events";
2
+ import EmailProperties from "../../../../../../../cc/email/Properties";
3
+ import FieldEvents from "../../../../../../../cc/fields/field/Events";
4
4
  import { EmailFieldView } from "./EmailFieldView";
5
5
  const EmailField = createCustomComponent({
6
6
  name: 'EmailField',
7
7
  View: EmailFieldView,
8
8
  properties: EmailProperties,
9
- events: EmailEvents,
9
+ events: FieldEvents,
10
10
  eventHandlers: {}
11
11
  });
12
12
  export default EmailField;
@@ -5,14 +5,16 @@ export function EmailFieldView(_ref, ref) {
5
5
  state
6
6
  } = _ref;
7
7
  const {
8
- value,
9
- textOverflowMode,
10
- isRead
8
+ email,
9
+ isDotted,
10
+ weight,
11
+ tooltip
11
12
  } = state.properties;
12
13
  return /*#__PURE__*/React.createElement(Email, {
13
14
  getRef: ref,
14
- email: value,
15
- isDotted: textOverflowMode === 'clip',
16
- weight: isRead ? undefined : 'bold'
15
+ email: email,
16
+ isDotted: isDotted,
17
+ weight: weight,
18
+ tooltip: tooltip
17
19
  });
18
20
  }
@@ -0,0 +1,26 @@
1
+ import HighlightedValueConstants from "../../../../../../../cc/highlighted-value/Constants";
2
+ import FieldConstants from "../../../../../../../cc/fields/field/Constants";
3
+ export class EventHandlersFactory {
4
+ static create() {
5
+ const clickHandler = input => {
6
+ const {
7
+ state,
8
+ dispatch
9
+ } = input;
10
+ const {
11
+ fieldName
12
+ } = state.properties;
13
+ dispatch({
14
+ type: FieldConstants.FIELD_CLICKED,
15
+ payload: {
16
+ fieldName
17
+ }
18
+ });
19
+ };
20
+
21
+ return {
22
+ [HighlightedValueConstants.HIGHLIGHTED_VALUE_CLICKED]: clickHandler
23
+ };
24
+ }
25
+
26
+ }
@@ -0,0 +1,23 @@
1
+ import { createCustomComponent } from "../../../../../../custom-component";
2
+ import HighlightedValueProperties from "../../../../../../../cc/highlighted-value/Properties";
3
+ import FieldEvents from "../../../../../../../cc/fields/field/Events";
4
+ import HighlightedValueFieldView from "./HighlightedValueFieldView";
5
+ import { EventHandlersFactory } from "./EventHandlersFactory";
6
+ const HighlightedValueField = createCustomComponent({
7
+ name: 'HighlightedValueField',
8
+ View: HighlightedValueFieldView,
9
+ properties: { ...HighlightedValueProperties,
10
+ fieldName: {
11
+ required: false,
12
+ defaultValue: '',
13
+ typeMetadata: {
14
+ schema: {
15
+ type: 'string'
16
+ }
17
+ }
18
+ }
19
+ },
20
+ events: FieldEvents,
21
+ eventHandlers: EventHandlersFactory.create()
22
+ });
23
+ export default HighlightedValueField;
@@ -0,0 +1,24 @@
1
+ import React from 'react';
2
+ import HighlightedValue from "../../../../highlighted-value/frameworks/ui/HighlightedValue";
3
+ export default function HighlightedValueFieldView(_ref, ref) {
4
+ let {
5
+ state
6
+ } = _ref;
7
+ const {
8
+ text,
9
+ color,
10
+ tooltip,
11
+ weight,
12
+ isDotted,
13
+ cursor
14
+ } = state.properties;
15
+ return /*#__PURE__*/React.createElement(HighlightedValue, {
16
+ getRef: ref,
17
+ text: text,
18
+ color: color,
19
+ tooltip: tooltip,
20
+ cursor: cursor,
21
+ weight: weight,
22
+ isDotted: isDotted
23
+ });
24
+ }
@@ -1,7 +1,6 @@
1
1
  import FieldTypes from "../../../../cc/fields/field/Types";
2
2
  import PrimaryField from "./primary-field/frameworks/ui/PrimaryField";
3
3
  import CheckboxField from "./checkbox-field/frameworks/ui/CheckboxField";
4
- import SwitchField from "./switch-field/frameworks/ui/SwitchField";
5
4
  import SingleLineField from "./singleline-field/frameworks/ui/SingleLineField";
6
5
  import EmailField from "./email-field/frameworks/ui/EmailField";
7
6
  import UrlField from "./url-field/frameworks/ui/UrlField";
@@ -17,11 +16,18 @@ import DateTimeField from "./datetime-field/frameworks/ui/DateTimeField";
17
16
  import NumberField from "./number-field/frameworks/ui/NumberField";
18
17
  import DecimalField from "./decimal-field/frameworks/ui/DecimalField";
19
18
  import MultiSelectField from "./multiselect-field/frameworks/ui/MultiSelectField";
19
+ import TextField from "./text-field/frameworks/ui/TextField";
20
+ import SwitchField from "./switch-field/frameworks/ui/SwitchField";
21
+ import LinkField from "./link-field/frameworks/ui/LinkField";
22
+ import TagField from "./tag-field/frameworks/ui/TagField";
23
+ import TagsField from "./tags-field/frameworks/ui/TagsField";
24
+ import TagsListDropdownField from "./tags-list-dropdown-field/frameworks/ui/TagsListDropdownField";
25
+ import RadioDropdownField from "./radio-dropdown-field/frameworks/ui/RadioDropdownField";
26
+ import LabeledAvatarField from "./labeled-avatar-field/frameworks/ui/LabeledAvatarField";
27
+ import HighlightedValueField from "./highlighted-value-field/frameworks/ui/HighlightedValueField";
20
28
  const FieldComponents = {
29
+ // Default Field Variants
21
30
  [FieldTypes.PrimaryField]: PrimaryField,
22
- [FieldTypes.CheckboxField]: CheckboxField,
23
- [FieldTypes.SwitchField]: SwitchField,
24
- // TODO: Need to register SwitchField
25
31
  [FieldTypes.SingleLineField]: SingleLineField,
26
32
  [FieldTypes.EmailField]: EmailField,
27
33
  [FieldTypes.URLField]: UrlField,
@@ -36,6 +42,17 @@ const FieldComponents = {
36
42
  [FieldTypes.DateTimeField]: DateTimeField,
37
43
  [FieldTypes.NumberField]: NumberField,
38
44
  [FieldTypes.DecimalField]: DecimalField,
39
- [FieldTypes.MultiSelectField]: MultiSelectField
45
+ [FieldTypes.MultiSelectField]: MultiSelectField,
46
+ // Custom Field Variants
47
+ [FieldTypes.TextField]: TextField,
48
+ [FieldTypes.CheckboxField]: CheckboxField,
49
+ [FieldTypes.SwitchField]: SwitchField,
50
+ [FieldTypes.LinkField]: LinkField,
51
+ [FieldTypes.TagField]: TagField,
52
+ [FieldTypes.TagsField]: TagsField,
53
+ [FieldTypes.TagsListDropdownField]: TagsListDropdownField,
54
+ [FieldTypes.RadioDropdownField]: RadioDropdownField,
55
+ [FieldTypes.LabeledAvatarField]: LabeledAvatarField,
56
+ [FieldTypes.HighlightedValueField]: HighlightedValueField
40
57
  };
41
58
  export default FieldComponents;
@@ -0,0 +1,26 @@
1
+ import AvatarConstants from "../../../../../../../cc/avatar/Constants";
2
+ import FieldConstants from "../../../../../../../cc/fields/field/Constants";
3
+ export class EventHandlersFactory {
4
+ static create() {
5
+ const clickHandler = input => {
6
+ const {
7
+ state,
8
+ dispatch
9
+ } = input;
10
+ const {
11
+ fieldName
12
+ } = state.properties;
13
+ dispatch({
14
+ type: FieldConstants.FIELD_CLICKED,
15
+ payload: {
16
+ fieldName
17
+ }
18
+ });
19
+ };
20
+
21
+ return {
22
+ [AvatarConstants.AVATAR_CLICKED]: clickHandler
23
+ };
24
+ }
25
+
26
+ }
@@ -0,0 +1,23 @@
1
+ import { createCustomComponent } from "../../../../../../custom-component";
2
+ import AvatarProperties from "../../../../../../../cc/avatar/Properties";
3
+ import FieldEvents from "../../../../../../../cc/fields/field/Events";
4
+ import LabeledAvatarFieldView from "./LabeledAvatarFieldView";
5
+ import { EventHandlersFactory } from "./EventHandlersFactory";
6
+ const LabeledAvatarField = createCustomComponent({
7
+ name: 'LabeledAvatarField',
8
+ View: LabeledAvatarFieldView,
9
+ properties: { ...AvatarProperties,
10
+ fieldName: {
11
+ required: false,
12
+ defaultValue: '',
13
+ typeMetadata: {
14
+ schema: {
15
+ type: 'string'
16
+ }
17
+ }
18
+ }
19
+ },
20
+ events: FieldEvents,
21
+ eventHandlers: EventHandlersFactory.create()
22
+ });
23
+ export default LabeledAvatarField;
@@ -0,0 +1,22 @@
1
+ import React from 'react';
2
+ import { Avatar } from "../../../..";
3
+ export default function LabeledAvatarFieldView(_ref, ref) {
4
+ let {
5
+ state
6
+ } = _ref;
7
+ const {
8
+ name,
9
+ imageSrc,
10
+ size,
11
+ label,
12
+ tooltip
13
+ } = state.properties;
14
+ return /*#__PURE__*/React.createElement(Avatar, {
15
+ getRef: ref,
16
+ name: name,
17
+ imageSrc: imageSrc,
18
+ size: size,
19
+ label: label,
20
+ tooltip: tooltip
21
+ });
22
+ }
@@ -0,0 +1,26 @@
1
+ import LinkConstants from "../../../../../../../cc/link/Constants";
2
+ import FieldConstants from "../../../../../../../cc/fields/field/Constants";
3
+ export class EventHandlersFactory {
4
+ static create() {
5
+ const clickHandler = input => {
6
+ const {
7
+ state,
8
+ dispatch
9
+ } = input;
10
+ const {
11
+ fieldName
12
+ } = state.properties;
13
+ dispatch({
14
+ type: FieldConstants.FIELD_CLICKED,
15
+ payload: {
16
+ fieldName
17
+ }
18
+ });
19
+ };
20
+
21
+ return {
22
+ [LinkConstants.LINK_CLICKED]: clickHandler
23
+ };
24
+ }
25
+
26
+ }
@@ -0,0 +1,23 @@
1
+ import { createCustomComponent } from "../../../../../../custom-component";
2
+ import LinkProperties from "../../../../../../../cc/link/Properties";
3
+ import FieldEvents from "../../../../../../../cc/fields/field/Events";
4
+ import LinkFieldView from "./LinkFieldView";
5
+ import { EventHandlersFactory } from "./EventHandlersFactory";
6
+ const LinkField = createCustomComponent({
7
+ name: 'LinkField',
8
+ View: LinkFieldView,
9
+ properties: { ...LinkProperties,
10
+ fieldName: {
11
+ required: false,
12
+ defaultValue: '',
13
+ typeMetadata: {
14
+ schema: {
15
+ type: 'string'
16
+ }
17
+ }
18
+ }
19
+ },
20
+ events: FieldEvents,
21
+ eventHandlers: EventHandlersFactory.create()
22
+ });
23
+ export default LinkField;
@@ -0,0 +1,26 @@
1
+ import React from 'react';
2
+ import Link from "../../../../link/frameworks/ui/Link";
3
+ export default function LinkFieldView(_ref, ref) {
4
+ let {
5
+ state
6
+ } = _ref;
7
+ let {
8
+ text,
9
+ variant,
10
+ isDotted,
11
+ weight,
12
+ href,
13
+ tooltip,
14
+ opensNewTab
15
+ } = state.properties;
16
+ return /*#__PURE__*/React.createElement(Link, {
17
+ getRef: ref,
18
+ text: text,
19
+ variant: variant,
20
+ href: href,
21
+ isDotted: isDotted,
22
+ weight: weight,
23
+ tooltip: tooltip,
24
+ opensNewTab: opensNewTab
25
+ });
26
+ }
@@ -15,7 +15,7 @@ export function LookupFieldView(_ref, ref) {
15
15
  } = value;
16
16
  return /*#__PURE__*/React.createElement(Link, {
17
17
  getRef: ref,
18
- label: name,
18
+ text: name,
19
19
  variant: "secondary",
20
20
  href: url,
21
21
  isDotted: textOverflowMode === 'clip',
@@ -13,7 +13,7 @@ function PhoneFieldView(_ref, ref) {
13
13
  const href = `tel:${value}`;
14
14
  return /*#__PURE__*/React.createElement(Link, {
15
15
  getRef: ref,
16
- label: value,
16
+ text: value,
17
17
  href: href,
18
18
  variant: "secondary",
19
19
  weight: isRead ? undefined : 'bold',
@@ -0,0 +1,46 @@
1
+ import RadioDropdownConstants from "../../../../../../../cc/radio-dropdown/Constants";
2
+ import FieldConstants from "../../../../../../../cc/fields/field/Constants";
3
+ import { SEARCH_REQUESTED } from "../../../../../../../bc/search/Constants";
4
+ import Constants from "../../../../../../../cc/radio-dropdown/Constants";
5
+ export class EventHandlersFactory {
6
+ static create() {
7
+ const changeHandler = input => {
8
+ const {
9
+ state,
10
+ dispatch,
11
+ action
12
+ } = input;
13
+ const {
14
+ fieldName,
15
+ fieldType
16
+ } = state.properties;
17
+ const {
18
+ id
19
+ } = action.payload;
20
+ dispatch({
21
+ type: FieldConstants.FIELD_CHANGED,
22
+ payload: {
23
+ fieldName,
24
+ value: fieldType === 'Boolean' ? id === 'true' : id
25
+ }
26
+ });
27
+ };
28
+
29
+ return {
30
+ [Constants.RADIO_DROPDOWN_SEARCHED]: _ref => {
31
+ let {
32
+ dispatch,
33
+ action
34
+ } = _ref;
35
+ dispatch({
36
+ type: SEARCH_REQUESTED,
37
+ payload: {
38
+ searchString: action.payload.value
39
+ }
40
+ });
41
+ },
42
+ [RadioDropdownConstants.RADIO_DROPDOWN_VALUE_CHANGED]: changeHandler
43
+ };
44
+ }
45
+
46
+ }
@@ -0,0 +1,49 @@
1
+ import { createCustomComponent } from "../../../../../../custom-component";
2
+ import RadioDropdownProperties from "../../../../../../../cc/radio-dropdown/Properties";
3
+ import FieldEvents from "../../../../../../../cc/fields/field/Events";
4
+ import RadioDropdownFieldView from "./RadioDropdownFieldView";
5
+ import { EventHandlersFactory } from "./EventHandlersFactory";
6
+ import SearchTranslator from "../../../../../../behaviours/search/adapters/presenter/SearchTranslator";
7
+ import SearchBehaviourFactory from "../../../../../../behaviours/search/frameworks/ui/SearchStringStoreBehaviourFactory";
8
+ const RadioDropdownField = createCustomComponent({
9
+ name: 'RadioDropdownField',
10
+ View: RadioDropdownFieldView,
11
+ transformState,
12
+ behaviours: [SearchBehaviourFactory.create()],
13
+ properties: { ...RadioDropdownProperties,
14
+ fieldType: {
15
+ required: false,
16
+ defaultValue: 'Picklist',
17
+ typeMetadata: {
18
+ schema: {
19
+ type: 'string'
20
+ }
21
+ }
22
+ },
23
+ fieldName: {
24
+ required: false,
25
+ defaultValue: '',
26
+ typeMetadata: {
27
+ schema: {
28
+ type: 'string'
29
+ }
30
+ }
31
+ }
32
+ },
33
+ events: FieldEvents,
34
+ eventHandlers: EventHandlersFactory.create()
35
+ });
36
+
37
+ function transformState(state) {
38
+ const {
39
+ searchString
40
+ } = state.behaviours.search;
41
+ return { ...state,
42
+ viewModel: { ...state.properties,
43
+ ...state.viewModel,
44
+ options: SearchTranslator(searchString, 'value', state.properties.options)
45
+ }
46
+ };
47
+ }
48
+
49
+ export default RadioDropdownField;
@@ -0,0 +1,43 @@
1
+ import React from 'react';
2
+ import Flex from '@zohodesk/layout/es/Flex/Flex';
3
+ import RadioDropdown from "../../../../radio-dropdown/frameworks/ui/RadioDropdown"; // @ts-ignore
4
+
5
+ import style from "./css/RadioDropdownField.module.css";
6
+ export default function RadioDropdownFieldView(_ref, ref) {
7
+ let {
8
+ state
9
+ } = _ref;
10
+ const {
11
+ options,
12
+ color,
13
+ isDotted,
14
+ weight,
15
+ selectedId,
16
+ selectedValue,
17
+ dropdownHeading,
18
+ hasSearch,
19
+ searchPlaceholder,
20
+ emptyStateTitle,
21
+ isDisabled,
22
+ isReadOnly
23
+ } = state.viewModel;
24
+ return /*#__PURE__*/React.createElement(Flex, {
25
+ $ui_displayMode: "flex",
26
+ $ui_className: color === 'none' ? style.wrapper : ''
27
+ }, /*#__PURE__*/React.createElement(RadioDropdown, {
28
+ getRef: ref,
29
+ hoverVariant: "border",
30
+ options: options,
31
+ selectedId: selectedId,
32
+ selectedValue: selectedValue,
33
+ color: color,
34
+ isDotted: isDotted,
35
+ weight: weight,
36
+ dropdownHeading: dropdownHeading,
37
+ hasSearch: hasSearch,
38
+ searchPlaceholder: searchPlaceholder,
39
+ emptyStateTitle: emptyStateTitle,
40
+ isDisabled: isDisabled,
41
+ isReadOnly: isReadOnly
42
+ }));
43
+ }
@@ -0,0 +1,3 @@
1
+ .wrapper {
2
+ margin-inline-start: calc( var(--zd_size11) * -1 )
3
+ }