@finsemble/finsemble-ui 6.5.2 → 6.6.0-beta.3

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 (555) hide show
  1. package/index.d.ts +1 -0
  2. package/package.json +18 -15
  3. package/react/actions/smartDesktopDesignerActions.d.ts +3 -3
  4. package/react/actions/smartDesktopDesignerActions.js.map +1 -1
  5. package/react/assets/css/finsemble.css +0 -1
  6. package/react/assets/css/toolbar.css +0 -4
  7. package/react/assets/css/userPreferences.css +39 -4
  8. package/react/componentTemplateGenerator.js +1 -1
  9. package/react/componentTemplateGenerator.js.map +1 -1
  10. package/react/components/appCatalog/AppCatalogComponent.d.ts +1 -1
  11. package/react/components/appCatalog/components/Showcase/ImageCarousel.d.ts +3 -3
  12. package/react/components/appCatalog/components/Showcase/SupportNotes.d.ts +1 -1
  13. package/react/components/appCatalog/stores/storeActions.d.ts +1 -1
  14. package/react/components/common/DropdownButton.js.map +1 -1
  15. package/react/components/common/FileInput.d.ts +2 -1
  16. package/react/components/common/FileInput.js +2 -2
  17. package/react/components/common/FileInput.js.map +1 -1
  18. package/react/components/common/FinsembleToggle.d.ts +3 -1
  19. package/react/components/common/FinsembleToggle.js +12 -4
  20. package/react/components/common/FinsembleToggle.js.map +1 -1
  21. package/react/components/common/ImagePreview.js +1 -1
  22. package/react/components/common/ImagePreview.js.map +1 -1
  23. package/react/components/common/TimeSelect.d.ts +16 -0
  24. package/react/components/common/TimeSelect.js +143 -0
  25. package/react/components/common/TimeSelect.js.map +1 -0
  26. package/react/components/common/css/accordion.css +3 -5
  27. package/react/components/common/css/application-edit-page.css +4 -1
  28. package/react/components/common/css/time-select.css +8 -0
  29. package/react/components/common/css/toggle.css +39 -3
  30. package/react/components/common/helpers.js +1 -0
  31. package/react/components/common/helpers.js.map +1 -1
  32. package/react/components/common/stories/FileInput.stories.d.ts +2 -1
  33. package/react/components/common/stories/FileInput.stories.js +6 -0
  34. package/react/components/common/stories/FileInput.stories.js.map +1 -1
  35. package/react/components/common/stories/FinsembleToggle.stories.d.ts +3 -1
  36. package/react/components/common/stories/FinsembleToggle.stories.js +12 -0
  37. package/react/components/common/stories/FinsembleToggle.stories.js.map +1 -1
  38. package/react/components/common/stories/TimeSelect.stories.d.ts +11 -0
  39. package/react/components/common/stories/TimeSelect.stories.js +20 -0
  40. package/react/components/common/stories/TimeSelect.stories.js.map +1 -0
  41. package/react/components/common/tests/Accordion.spec.js +1 -1
  42. package/react/components/common/tests/Accordion.spec.js.map +1 -1
  43. package/react/components/common/tests/FileInput.spec.js +8 -1
  44. package/react/components/common/tests/FileInput.spec.js.map +1 -1
  45. package/react/components/common/tests/FinsembleSelect.spec.js +1 -1
  46. package/react/components/common/tests/FinsembleSelect.spec.js.map +1 -1
  47. package/react/components/common/tests/FinsembleToggle.spec.js +8 -3
  48. package/react/components/common/tests/FinsembleToggle.spec.js.map +1 -1
  49. package/react/components/{smartDesktopDesigner/tests/AppEditPage.spec.d.ts → common/tests/TimeSelect.spec.d.ts} +0 -0
  50. package/react/components/common/tests/TimeSelect.spec.js +71 -0
  51. package/react/components/common/tests/TimeSelect.spec.js.map +1 -0
  52. package/react/components/favorites/FavoriteMaker.js.map +1 -1
  53. package/react/components/favorites/FavoritesShell.spec.js +1 -1
  54. package/react/components/favorites/FavoritesShell.spec.js.map +1 -1
  55. package/react/components/fdc3Resolver/ResolverDialog.spec.js +1 -1
  56. package/react/components/fdc3Resolver/ResolverDialog.spec.js.map +1 -1
  57. package/react/components/icon/Icon.d.ts +4 -3
  58. package/react/components/icon/Icon.js +22 -12
  59. package/react/components/icon/Icon.js.map +1 -1
  60. package/react/components/legacyControls/tests/FinsembleDialogTextInput.spec.js +1 -1
  61. package/react/components/legacyControls/tests/FinsembleDialogTextInput.spec.js.map +1 -1
  62. package/react/components/linker/LinkerMenu.js.map +1 -1
  63. package/react/components/menu/MenuPortal.js +1 -1
  64. package/react/components/menu/MenuPortal.js.map +1 -1
  65. package/react/components/processMonitor/ProcessMonitorTypes.d.ts +4 -11
  66. package/react/components/processMonitor/ProcessMonitorTypes.js.map +1 -1
  67. package/react/components/processMonitor/components/ChildWindow.js +5 -10
  68. package/react/components/processMonitor/components/ChildWindow.js.map +1 -1
  69. package/react/components/processMonitor/components/ProcessStatistics.js +8 -10
  70. package/react/components/processMonitor/components/ProcessStatistics.js.map +1 -1
  71. package/react/components/processMonitor/constants.d.ts +0 -2
  72. package/react/components/processMonitor/constants.js +0 -2
  73. package/react/components/processMonitor/constants.js.map +1 -1
  74. package/react/components/processMonitor/helpers.d.ts +0 -11
  75. package/react/components/processMonitor/helpers.js +1 -9
  76. package/react/components/processMonitor/helpers.js.map +1 -1
  77. package/react/components/processMonitor/stores/ProcessMonitorStore.d.ts +3 -11
  78. package/react/components/processMonitor/stores/ProcessMonitorStore.js +22 -62
  79. package/react/components/processMonitor/stores/ProcessMonitorStore.js.map +1 -1
  80. package/react/components/{smartDesktopDesigner → sdd}/AddApp.d.ts +0 -0
  81. package/react/components/{smartDesktopDesigner → sdd}/AddApp.js +0 -0
  82. package/react/components/sdd/AddApp.js.map +1 -0
  83. package/react/components/{smartDesktopDesigner → sdd}/AppEditAccess.d.ts +0 -0
  84. package/react/components/{smartDesktopDesigner → sdd}/AppEditAccess.js +0 -0
  85. package/react/components/sdd/AppEditAccess.js.map +1 -0
  86. package/react/components/{smartDesktopDesigner → sdd}/AppEditPage.d.ts +0 -0
  87. package/react/components/{smartDesktopDesigner → sdd}/AppEditPage.js +7 -1
  88. package/react/components/sdd/AppEditPage.js.map +1 -0
  89. package/react/components/{smartDesktopDesigner → sdd}/Appearance.css +0 -0
  90. package/react/components/{smartDesktopDesigner → sdd}/Appearance.d.ts +0 -0
  91. package/react/components/{smartDesktopDesigner → sdd}/Appearance.helpers.d.ts +0 -0
  92. package/react/components/{smartDesktopDesigner → sdd}/Appearance.helpers.js +0 -0
  93. package/react/components/sdd/Appearance.helpers.js.map +1 -0
  94. package/react/components/{smartDesktopDesigner → sdd}/Appearance.js +0 -0
  95. package/react/components/sdd/Appearance.js.map +1 -0
  96. package/react/components/{smartDesktopDesigner → sdd}/Application.d.ts +1 -2
  97. package/react/components/{smartDesktopDesigner → sdd}/Application.js +37 -39
  98. package/react/components/sdd/Application.js.map +1 -0
  99. package/react/components/{smartDesktopDesigner → sdd}/Applications.d.ts +0 -0
  100. package/react/components/{smartDesktopDesigner → sdd}/Applications.js +2 -2
  101. package/react/components/sdd/Applications.js.map +1 -0
  102. package/react/components/{smartDesktopDesigner → sdd}/AssetsPage.css +0 -0
  103. package/react/components/{smartDesktopDesigner → sdd}/AssetsPage.d.ts +0 -0
  104. package/react/components/{smartDesktopDesigner → sdd}/AssetsPage.js +0 -0
  105. package/react/components/sdd/AssetsPage.js.map +1 -0
  106. package/react/components/{smartDesktopDesigner → sdd}/Authentication.d.ts +0 -0
  107. package/react/components/{smartDesktopDesigner → sdd}/Authentication.js +1 -1
  108. package/react/components/sdd/Authentication.js.map +1 -0
  109. package/react/components/{smartDesktopDesigner → sdd}/AuthenticationProviderConfig.d.ts +0 -0
  110. package/react/components/{smartDesktopDesigner → sdd}/AuthenticationProviderConfig.js +0 -0
  111. package/react/components/sdd/AuthenticationProviderConfig.js.map +1 -0
  112. package/react/components/{smartDesktopDesigner → sdd}/Content.d.ts +0 -0
  113. package/react/components/{smartDesktopDesigner → sdd}/Content.js +0 -0
  114. package/react/components/sdd/Content.js.map +1 -0
  115. package/react/components/{smartDesktopDesigner → sdd}/ContentHeader.d.ts +0 -0
  116. package/react/components/{smartDesktopDesigner → sdd}/ContentHeader.js +0 -0
  117. package/react/components/sdd/ContentHeader.js.map +1 -0
  118. package/react/components/{smartDesktopDesigner → sdd}/CurrentView.d.ts +0 -0
  119. package/react/components/{smartDesktopDesigner → sdd}/CurrentView.js +0 -0
  120. package/react/components/sdd/CurrentView.js.map +1 -0
  121. package/react/components/{smartDesktopDesigner → sdd}/EditPreload.d.ts +5 -7
  122. package/react/components/sdd/EditPreload.js +156 -0
  123. package/react/components/sdd/EditPreload.js.map +1 -0
  124. package/react/components/{smartDesktopDesigner → sdd}/Export.d.ts +0 -0
  125. package/react/components/{smartDesktopDesigner → sdd}/Export.js +0 -0
  126. package/react/components/sdd/Export.js.map +1 -0
  127. package/react/components/{smartDesktopDesigner → sdd}/ExportCloud.d.ts +0 -0
  128. package/react/components/{smartDesktopDesigner → sdd}/ExportCloud.js +0 -0
  129. package/react/components/sdd/ExportCloud.js.map +1 -0
  130. package/react/components/{smartDesktopDesigner → sdd}/ExportDeployInfo.d.ts +0 -0
  131. package/react/components/{smartDesktopDesigner → sdd}/ExportDeployInfo.js +0 -0
  132. package/react/components/sdd/ExportDeployInfo.js.map +1 -0
  133. package/react/components/{smartDesktopDesigner → sdd}/ExportZip.d.ts +0 -0
  134. package/react/components/{smartDesktopDesigner → sdd}/ExportZip.js +0 -0
  135. package/react/components/sdd/ExportZip.js.map +1 -0
  136. package/react/components/{smartDesktopDesigner → sdd}/GettingStarted.d.ts +0 -0
  137. package/react/components/{smartDesktopDesigner → sdd}/GettingStarted.js +0 -0
  138. package/react/components/sdd/GettingStarted.js.map +1 -0
  139. package/react/components/{smartDesktopDesigner → sdd}/ItemList.d.ts +0 -0
  140. package/react/components/{smartDesktopDesigner → sdd}/ItemList.js +0 -0
  141. package/react/components/sdd/ItemList.js.map +1 -0
  142. package/react/components/{smartDesktopDesigner → sdd}/Navigation.d.ts +0 -0
  143. package/react/components/{smartDesktopDesigner → sdd}/Navigation.js +0 -0
  144. package/react/components/sdd/Navigation.js.map +1 -0
  145. package/react/components/{smartDesktopDesigner → sdd}/OptionalSettingsView.d.ts +1 -3
  146. package/react/components/sdd/OptionalSettingsView.js +56 -0
  147. package/react/components/sdd/OptionalSettingsView.js.map +1 -0
  148. package/react/components/sdd/Preloads.d.ts +6 -0
  149. package/react/components/sdd/Preloads.js +24 -0
  150. package/react/components/sdd/Preloads.js.map +1 -0
  151. package/react/components/{smartDesktopDesigner → sdd}/ProjectErrors.d.ts +0 -0
  152. package/react/components/{smartDesktopDesigner → sdd}/ProjectErrors.js +0 -0
  153. package/react/components/sdd/ProjectErrors.js.map +1 -0
  154. package/react/components/{smartDesktopDesigner → sdd}/Publish.d.ts +0 -0
  155. package/react/components/{smartDesktopDesigner → sdd}/Publish.js +0 -0
  156. package/react/components/sdd/Publish.js.map +1 -0
  157. package/react/components/{smartDesktopDesigner → sdd}/PublishProgress.d.ts +0 -0
  158. package/react/components/{smartDesktopDesigner → sdd}/PublishProgress.js +0 -0
  159. package/react/components/sdd/PublishProgress.js.map +1 -0
  160. package/react/components/sdd/SmartDesktopDesigner.d.ts +29 -0
  161. package/react/components/sdd/SmartDesktopDesigner.js +122 -0
  162. package/react/components/sdd/SmartDesktopDesigner.js.map +1 -0
  163. package/react/components/{smartDesktopDesigner → sdd}/ThemePage.css +0 -0
  164. package/react/components/{smartDesktopDesigner → sdd}/ThemePage.d.ts +0 -0
  165. package/react/components/{smartDesktopDesigner → sdd}/ThemePage.js +0 -0
  166. package/react/components/sdd/ThemePage.js.map +1 -0
  167. package/react/components/{smartDesktopDesigner → sdd}/Themes.d.ts +0 -0
  168. package/react/components/{smartDesktopDesigner → sdd}/Themes.js +0 -0
  169. package/react/components/sdd/Themes.js.map +1 -0
  170. package/react/components/{smartDesktopDesigner → sdd}/Toolbar.d.ts +0 -0
  171. package/react/components/{smartDesktopDesigner → sdd}/Toolbar.js +9 -7
  172. package/react/components/sdd/Toolbar.js.map +1 -0
  173. package/react/components/{smartDesktopDesigner → sdd}/View.d.ts +0 -0
  174. package/react/components/{smartDesktopDesigner → sdd}/View.js +0 -0
  175. package/react/components/sdd/View.js.map +1 -0
  176. package/react/components/{smartDesktopDesigner → sdd}/common/fsbl_functions.d.ts +0 -0
  177. package/react/components/{smartDesktopDesigner → sdd}/common/fsbl_functions.js +0 -0
  178. package/react/components/sdd/common/fsbl_functions.js.map +1 -0
  179. package/react/components/{smartDesktopDesigner → sdd}/common/getCSSVars.d.ts +0 -0
  180. package/react/components/{smartDesktopDesigner → sdd}/common/getCSSVars.js +0 -0
  181. package/react/components/sdd/common/getCSSVars.js.map +1 -0
  182. package/react/components/sdd/common/setPreloadDefaults.d.ts +1 -0
  183. package/react/components/sdd/common/setPreloadDefaults.js +21 -0
  184. package/react/components/sdd/common/setPreloadDefaults.js.map +1 -0
  185. package/react/components/{smartDesktopDesigner/fixtures → sdd/common}/views.d.ts +0 -0
  186. package/react/components/sdd/common/views.js +202 -0
  187. package/react/components/sdd/common/views.js.map +1 -0
  188. package/react/components/{smartDesktopDesigner → sdd}/css/appearance.css +0 -0
  189. package/react/components/{smartDesktopDesigner → sdd}/css/applications.css +0 -0
  190. package/react/components/{smartDesktopDesigner → sdd}/css/authentication.css +5 -1
  191. package/react/components/{smartDesktopDesigner → sdd}/css/buttons.css +0 -0
  192. package/react/components/{smartDesktopDesigner → sdd}/css/export.css +0 -0
  193. package/react/components/{smartDesktopDesigner → sdd}/css/getting-started.css +0 -0
  194. package/react/components/{smartDesktopDesigner → sdd}/css/nav.css +0 -0
  195. package/react/components/{smartDesktopDesigner → sdd}/css/project-errors.css +0 -0
  196. package/react/components/{smartDesktopDesigner → sdd}/css/project-header.css +0 -0
  197. package/react/components/{smartDesktopDesigner → sdd}/css/styles.css +0 -0
  198. package/react/components/{smartDesktopDesigner → sdd}/css/views.css +0 -1
  199. package/react/components/{smartDesktopDesigner → sdd}/fixtures/apps.d.ts +0 -0
  200. package/react/components/{smartDesktopDesigner → sdd}/fixtures/apps.js +10 -10
  201. package/react/components/sdd/fixtures/apps.js.map +1 -0
  202. package/react/components/{smartDesktopDesigner → sdd}/fixtures/authenticationProps.d.ts +0 -0
  203. package/react/components/{smartDesktopDesigner → sdd}/fixtures/authenticationProps.js +0 -0
  204. package/react/components/sdd/fixtures/authenticationProps.js.map +1 -0
  205. package/react/components/{smartDesktopDesigner → sdd}/fixtures/configTemplate.d.ts +1 -1
  206. package/react/components/{smartDesktopDesigner → sdd}/fixtures/configTemplate.js +1 -1
  207. package/react/components/sdd/fixtures/configTemplate.js.map +1 -0
  208. package/react/components/{smartDesktopDesigner → sdd}/fixtures/exportProps.d.ts +0 -0
  209. package/react/components/{smartDesktopDesigner → sdd}/fixtures/exportProps.js +0 -0
  210. package/react/components/sdd/fixtures/exportProps.js.map +1 -0
  211. package/react/components/sdd/fixtures/preloads.d.ts +3 -0
  212. package/react/components/sdd/fixtures/preloads.js +57 -0
  213. package/react/components/sdd/fixtures/preloads.js.map +1 -0
  214. package/react/components/{smartDesktopDesigner → sdd}/fixtures/projectErrorsProps.d.ts +0 -0
  215. package/react/components/{smartDesktopDesigner → sdd}/fixtures/projectErrorsProps.js +0 -0
  216. package/react/components/sdd/fixtures/projectErrorsProps.js.map +1 -0
  217. package/react/components/{smartDesktopDesigner → sdd}/fixtures/publishProgress.d.ts +0 -0
  218. package/react/components/{smartDesktopDesigner → sdd}/fixtures/publishProgress.js +0 -0
  219. package/react/components/sdd/fixtures/publishProgress.js.map +1 -0
  220. package/react/components/{smartDesktopDesigner → sdd}/fixtures/themeProps.d.ts +0 -0
  221. package/react/components/{smartDesktopDesigner → sdd}/fixtures/themeProps.js +0 -0
  222. package/react/components/sdd/fixtures/themeProps.js.map +1 -0
  223. package/react/components/sdd/fixtures/views.d.ts +3 -0
  224. package/react/components/{smartDesktopDesigner → sdd}/fixtures/views.js +0 -0
  225. package/react/components/sdd/fixtures/views.js.map +1 -0
  226. package/react/components/{smartDesktopDesigner → sdd}/sdd_helpers.d.ts +0 -0
  227. package/react/components/{smartDesktopDesigner → sdd}/sdd_helpers.js +0 -0
  228. package/react/components/sdd/sdd_helpers.js.map +1 -0
  229. package/react/components/{smartDesktopDesigner → sdd}/stories/AppEditPage.stories.d.ts +0 -0
  230. package/react/components/{smartDesktopDesigner → sdd}/stories/AppEditPage.stories.js +0 -0
  231. package/react/components/sdd/stories/AppEditPage.stories.js.map +1 -0
  232. package/react/components/{smartDesktopDesigner → sdd}/stories/Appearance.stories.d.ts +0 -0
  233. package/react/components/{smartDesktopDesigner → sdd}/stories/Appearance.stories.js +0 -0
  234. package/react/components/sdd/stories/Appearance.stories.js.map +1 -0
  235. package/react/components/{smartDesktopDesigner → sdd}/stories/Applications.stories.d.ts +0 -0
  236. package/react/components/{smartDesktopDesigner → sdd}/stories/Applications.stories.js +0 -0
  237. package/react/components/sdd/stories/Applications.stories.js.map +1 -0
  238. package/react/components/{smartDesktopDesigner → sdd}/stories/AssetsPage.stories.d.ts +0 -0
  239. package/react/components/{smartDesktopDesigner → sdd}/stories/AssetsPage.stories.js +0 -0
  240. package/react/components/sdd/stories/AssetsPage.stories.js.map +1 -0
  241. package/react/components/{smartDesktopDesigner → sdd}/stories/Authentication.stories.d.ts +0 -0
  242. package/react/components/{smartDesktopDesigner → sdd}/stories/Authentication.stories.js +0 -0
  243. package/react/components/sdd/stories/Authentication.stories.js.map +1 -0
  244. package/react/components/{smartDesktopDesigner → sdd}/stories/ContentHeader.stories.d.ts +0 -0
  245. package/react/components/{smartDesktopDesigner → sdd}/stories/ContentHeader.stories.js +0 -0
  246. package/react/components/sdd/stories/ContentHeader.stories.js.map +1 -0
  247. package/react/components/{smartDesktopDesigner → sdd}/stories/Export.stories.d.ts +0 -0
  248. package/react/components/{smartDesktopDesigner → sdd}/stories/Export.stories.js +0 -0
  249. package/react/components/sdd/stories/Export.stories.js.map +1 -0
  250. package/react/components/{smartDesktopDesigner → sdd}/stories/ExportCloud.stories.d.ts +0 -0
  251. package/react/components/{smartDesktopDesigner → sdd}/stories/ExportCloud.stories.js +0 -0
  252. package/react/components/sdd/stories/ExportCloud.stories.js.map +1 -0
  253. package/react/components/{smartDesktopDesigner → sdd}/stories/ExportZip.stories.d.ts +0 -0
  254. package/react/components/{smartDesktopDesigner → sdd}/stories/ExportZip.stories.js +0 -0
  255. package/react/components/sdd/stories/ExportZip.stories.js.map +1 -0
  256. package/react/components/{smartDesktopDesigner → sdd}/stories/GettingStarted.stories.d.ts +0 -0
  257. package/react/components/{smartDesktopDesigner → sdd}/stories/GettingStarted.stories.js +0 -0
  258. package/react/components/sdd/stories/GettingStarted.stories.js.map +1 -0
  259. package/react/components/{smartDesktopDesigner → sdd}/stories/ItemList.stories.d.ts +0 -0
  260. package/react/components/{smartDesktopDesigner → sdd}/stories/ItemList.stories.js +0 -0
  261. package/react/components/sdd/stories/ItemList.stories.js.map +1 -0
  262. package/react/components/{smartDesktopDesigner → sdd}/stories/Navigation.stories.d.ts +0 -0
  263. package/react/components/{smartDesktopDesigner → sdd}/stories/Navigation.stories.js +0 -0
  264. package/react/components/sdd/stories/Navigation.stories.js.map +1 -0
  265. package/react/components/{smartDesktopDesigner → sdd}/stories/OptionalSettingsView.stories.d.ts +3 -2
  266. package/react/components/sdd/stories/OptionalSettingsView.stories.js +27 -0
  267. package/react/components/sdd/stories/OptionalSettingsView.stories.js.map +1 -0
  268. package/react/components/{smartDesktopDesigner → sdd}/stories/ProjectErrors.stories.d.ts +0 -0
  269. package/react/components/{smartDesktopDesigner → sdd}/stories/ProjectErrors.stories.js +0 -0
  270. package/react/components/sdd/stories/ProjectErrors.stories.js.map +1 -0
  271. package/react/components/{smartDesktopDesigner → sdd}/stories/Publish.stories.d.ts +0 -0
  272. package/react/components/{smartDesktopDesigner → sdd}/stories/Publish.stories.js +0 -0
  273. package/react/components/sdd/stories/Publish.stories.js.map +1 -0
  274. package/react/components/{smartDesktopDesigner → sdd}/stories/PublishProgress.stories.d.ts +0 -0
  275. package/react/components/{smartDesktopDesigner → sdd}/stories/PublishProgress.stories.js +0 -0
  276. package/react/components/sdd/stories/PublishProgress.stories.js.map +1 -0
  277. package/react/components/{smartDesktopDesigner → sdd}/stories/SmartDesktopDesigner.stories.d.ts +0 -0
  278. package/react/components/{smartDesktopDesigner → sdd}/stories/SmartDesktopDesigner.stories.js +1 -0
  279. package/react/components/sdd/stories/SmartDesktopDesigner.stories.js.map +1 -0
  280. package/react/components/{smartDesktopDesigner → sdd}/stories/ThemePage.stories.d.ts +0 -0
  281. package/react/components/{smartDesktopDesigner → sdd}/stories/ThemePage.stories.js +0 -0
  282. package/react/components/sdd/stories/ThemePage.stories.js.map +1 -0
  283. package/react/components/{smartDesktopDesigner → sdd}/stories/Themes.stories.d.ts +0 -0
  284. package/react/components/{smartDesktopDesigner → sdd}/stories/Themes.stories.js +0 -0
  285. package/react/components/sdd/stories/Themes.stories.js.map +1 -0
  286. package/react/components/{smartDesktopDesigner → sdd}/stories/Toolbar.stories.d.ts +0 -0
  287. package/react/components/{smartDesktopDesigner → sdd}/stories/Toolbar.stories.js +0 -0
  288. package/react/components/sdd/stories/Toolbar.stories.js.map +1 -0
  289. package/react/components/{smartDesktopDesigner/tests/Application.spec.d.ts → sdd/tests/AppEditPage.spec.d.ts} +0 -0
  290. package/react/components/{smartDesktopDesigner → sdd}/tests/AppEditPage.spec.js +0 -0
  291. package/react/components/sdd/tests/AppEditPage.spec.js.map +1 -0
  292. package/react/components/{smartDesktopDesigner/tests/Authentication.spec.d.ts → sdd/tests/Application.spec.d.ts} +0 -0
  293. package/react/components/{smartDesktopDesigner → sdd}/tests/Application.spec.js +13 -31
  294. package/react/components/sdd/tests/Application.spec.js.map +1 -0
  295. package/react/components/{smartDesktopDesigner → sdd}/tests/Applications.spec.d.ts +0 -0
  296. package/react/components/{smartDesktopDesigner → sdd}/tests/Applications.spec.js +0 -0
  297. package/react/components/sdd/tests/Applications.spec.js.map +1 -0
  298. package/react/components/{smartDesktopDesigner/tests/ContentHeader.spec.d.ts → sdd/tests/Authentication.spec.d.ts} +0 -0
  299. package/react/components/{smartDesktopDesigner → sdd}/tests/Authentication.spec.js +0 -0
  300. package/react/components/sdd/tests/Authentication.spec.js.map +1 -0
  301. package/react/components/{smartDesktopDesigner/tests/EditPreload.spec.d.ts → sdd/tests/ContentHeader.spec.d.ts} +0 -0
  302. package/react/components/{smartDesktopDesigner → sdd}/tests/ContentHeader.spec.js +0 -0
  303. package/react/components/sdd/tests/ContentHeader.spec.js.map +1 -0
  304. package/react/components/{smartDesktopDesigner/tests/Export.spec.d.ts → sdd/tests/EditPreload.spec.d.ts} +0 -0
  305. package/react/components/{smartDesktopDesigner → sdd}/tests/EditPreload.spec.js +8 -10
  306. package/react/components/sdd/tests/EditPreload.spec.js.map +1 -0
  307. package/react/components/{smartDesktopDesigner/tests/ExportZip.spec.d.ts → sdd/tests/Export.spec.d.ts} +0 -0
  308. package/react/components/{smartDesktopDesigner → sdd}/tests/Export.spec.js +0 -0
  309. package/react/components/sdd/tests/Export.spec.js.map +1 -0
  310. package/react/components/{smartDesktopDesigner/tests/ItemList.spec.d.ts → sdd/tests/ExportZip.spec.d.ts} +0 -0
  311. package/react/components/{smartDesktopDesigner → sdd}/tests/ExportZip.spec.js +0 -0
  312. package/react/components/sdd/tests/ExportZip.spec.js.map +1 -0
  313. package/react/components/{smartDesktopDesigner/tests/Navigation.spec.d.ts → sdd/tests/ItemList.spec.d.ts} +0 -0
  314. package/react/components/{smartDesktopDesigner → sdd}/tests/ItemList.spec.js +0 -0
  315. package/react/components/sdd/tests/ItemList.spec.js.map +1 -0
  316. package/react/components/{smartDesktopDesigner/tests/Preloads.spec.d.ts → sdd/tests/Navigation.spec.d.ts} +0 -0
  317. package/react/components/{smartDesktopDesigner → sdd}/tests/Navigation.spec.js +0 -0
  318. package/react/components/sdd/tests/Navigation.spec.js.map +1 -0
  319. package/react/components/{smartDesktopDesigner/tests/ProjectErrors.spec.d.ts → sdd/tests/OptionalSettingsView.spec.d.ts} +0 -0
  320. package/react/components/sdd/tests/OptionalSettingsView.spec.js +22 -0
  321. package/react/components/sdd/tests/OptionalSettingsView.spec.js.map +1 -0
  322. package/react/components/{smartDesktopDesigner/tests/Publish.spec.d.ts → sdd/tests/ProjectErrors.spec.d.ts} +0 -0
  323. package/react/components/{smartDesktopDesigner → sdd}/tests/ProjectErrors.spec.js +0 -0
  324. package/react/components/sdd/tests/ProjectErrors.spec.js.map +1 -0
  325. package/react/components/{smartDesktopDesigner/tests/PublishProgess.spec.d.ts → sdd/tests/Publish.spec.d.ts} +0 -0
  326. package/react/components/{smartDesktopDesigner → sdd}/tests/Publish.spec.js +0 -0
  327. package/react/components/sdd/tests/Publish.spec.js.map +1 -0
  328. package/react/components/{smartDesktopDesigner/tests/SmartDesktopDesigner.spec.d.ts → sdd/tests/PublishProgess.spec.d.ts} +0 -0
  329. package/react/components/{smartDesktopDesigner → sdd}/tests/PublishProgess.spec.js +0 -0
  330. package/react/components/sdd/tests/PublishProgess.spec.js.map +1 -0
  331. package/react/components/{smartDesktopDesigner/tests/Themes.spec.d.ts → sdd/tests/SmartDesktopDesigner.spec.d.ts} +0 -0
  332. package/react/components/{smartDesktopDesigner → sdd}/tests/SmartDesktopDesigner.spec.js +1 -1
  333. package/react/components/sdd/tests/SmartDesktopDesigner.spec.js.map +1 -0
  334. package/react/components/{smartDesktopDesigner/tests/sdd_helpers.spec.d.ts → sdd/tests/Themes.spec.d.ts} +0 -0
  335. package/react/components/{smartDesktopDesigner → sdd}/tests/Themes.spec.js +0 -0
  336. package/react/components/sdd/tests/Themes.spec.js.map +1 -0
  337. package/react/components/{smartDesktopDesigner → sdd}/tests/Toolbar.spec.d.ts +0 -0
  338. package/react/components/{smartDesktopDesigner → sdd}/tests/Toolbar.spec.js +0 -0
  339. package/react/components/sdd/tests/Toolbar.spec.js.map +1 -0
  340. package/react/components/{smartDesktopDesigner → sdd}/tests/a11y_helper.d.ts +0 -0
  341. package/react/components/{smartDesktopDesigner → sdd}/tests/a11y_helper.js +0 -0
  342. package/react/components/sdd/tests/a11y_helper.js.map +1 -0
  343. package/react/components/{userPreferences/tests/ScheduledRestart.spec.d.ts → sdd/tests/sdd_helpers.spec.d.ts} +0 -0
  344. package/react/components/{smartDesktopDesigner → sdd}/tests/sdd_helpers.spec.js +0 -0
  345. package/react/components/sdd/tests/sdd_helpers.spec.js.map +1 -0
  346. package/react/components/{smartDesktopDesigner → sdd}/themeDefinitions.d.ts +0 -0
  347. package/react/components/{smartDesktopDesigner → sdd}/themeDefinitions.js +0 -0
  348. package/react/components/sdd/themeDefinitions.js.map +1 -0
  349. package/react/components/search/SearchBestMatch.js.map +1 -1
  350. package/react/components/search/SearchProviderResults.d.ts +3 -1
  351. package/react/components/search/SearchProviderResults.js.map +1 -1
  352. package/react/components/search/SearchResult.d.ts +3 -1
  353. package/react/components/search/SearchResult.js +9 -7
  354. package/react/components/search/SearchResult.js.map +1 -1
  355. package/react/components/shared/DefaultDropdownButton.js +5 -4
  356. package/react/components/shared/DefaultDropdownButton.js.map +1 -1
  357. package/react/components/shared/tests/DefaultDropdownButton.spec.js +9 -0
  358. package/react/components/shared/tests/DefaultDropdownButton.spec.js.map +1 -1
  359. package/react/components/singleInputDialog/SingleInputDialog.spec.js +1 -1
  360. package/react/components/singleInputDialog/SingleInputDialog.spec.js.map +1 -1
  361. package/react/components/smartDesktopDesigner/SmartDesktopDesigner.d.ts +0 -11
  362. package/react/components/smartDesktopDesigner/SmartDesktopDesigner.js +2 -116
  363. package/react/components/smartDesktopDesigner/SmartDesktopDesigner.js.map +1 -1
  364. package/react/components/smartDesktopDesigner/common/views.js +1 -203
  365. package/react/components/smartDesktopDesigner/common/views.js.map +1 -1
  366. package/react/components/toolbar/AutoArrange.js +1 -1
  367. package/react/components/toolbar/AutoArrange.js.map +1 -1
  368. package/react/components/toolbar/AutoArrange.spec.d.ts +1 -0
  369. package/react/components/toolbar/AutoArrange.spec.js +48 -0
  370. package/react/components/toolbar/AutoArrange.spec.js.map +1 -0
  371. package/react/components/toolbar/AutoArrange.stories.d.ts +11 -0
  372. package/react/components/toolbar/AutoArrange.stories.js +21 -0
  373. package/react/components/toolbar/AutoArrange.stories.js.map +1 -0
  374. package/react/components/toolbar/SddButton.d.ts +2 -0
  375. package/react/components/toolbar/SddButton.js +23 -0
  376. package/react/components/toolbar/SddButton.js.map +1 -0
  377. package/react/components/toolbar/ToolbarShell.js +4 -1
  378. package/react/components/toolbar/ToolbarShell.js.map +1 -1
  379. package/react/components/toolbar/advancedAppLauncher/components/AppActionsMenu.js +2 -1
  380. package/react/components/toolbar/advancedAppLauncher/components/AppActionsMenu.js.map +1 -1
  381. package/react/components/toolbar/advancedAppLauncher/components/AppDefinition.d.ts +3 -2
  382. package/react/components/toolbar/advancedAppLauncher/components/AppDefinition.js.map +1 -1
  383. package/react/components/toolbar/advancedAppLauncher/stores/StoreActions.js.map +1 -1
  384. package/react/components/toolbar/appLauncher/AppLauncherMenu.js +15 -4
  385. package/react/components/toolbar/appLauncher/AppLauncherMenu.js.map +1 -1
  386. package/react/components/toolbar/appLauncher/components/componentList.js +3 -4
  387. package/react/components/toolbar/appLauncher/components/componentList.js.map +1 -1
  388. package/react/components/toolbar/dashbar/Dashbar.js +2 -0
  389. package/react/components/toolbar/dashbar/Dashbar.js.map +1 -1
  390. package/react/components/toolbar/workspaceManagementMenu/stores/workspaceManagementMenuStore.js +71 -12
  391. package/react/components/toolbar/workspaceManagementMenu/stores/workspaceManagementMenuStore.js.map +1 -1
  392. package/react/components/userPreferences/UserPreferenceTypes.d.ts +3 -2
  393. package/react/components/userPreferences/UserPreferenceTypes.js.map +1 -1
  394. package/react/components/userPreferences/components/content/General.d.ts +2 -5
  395. package/react/components/userPreferences/components/content/General.js +31 -11
  396. package/react/components/userPreferences/components/content/General.js.map +1 -1
  397. package/react/components/userPreferences/components/content/Workspaces.d.ts +5 -0
  398. package/react/components/userPreferences/components/content/Workspaces.js +58 -17
  399. package/react/components/userPreferences/components/content/Workspaces.js.map +1 -1
  400. package/react/components/userPreferences/components/general/ScheduledClose.d.ts +10 -0
  401. package/react/components/userPreferences/components/general/ScheduledClose.js +95 -0
  402. package/react/components/userPreferences/components/general/ScheduledClose.js.map +1 -0
  403. package/react/components/userPreferences/stores/UserPreferencesStore.d.ts +6 -2
  404. package/react/components/userPreferences/stores/UserPreferencesStore.js +19 -3
  405. package/react/components/userPreferences/stores/UserPreferencesStore.js.map +1 -1
  406. package/react/components/userPreferences/stories/General.stories.d.ts +6 -2
  407. package/react/components/userPreferences/stories/ScheduledClose.stories.d.ts +12 -0
  408. package/react/components/userPreferences/stories/ScheduledClose.stories.js +53 -0
  409. package/react/components/userPreferences/stories/ScheduledClose.stories.js.map +1 -0
  410. package/react/components/userPreferences/tests/General.spec.js +4 -17
  411. package/react/components/userPreferences/tests/General.spec.js.map +1 -1
  412. package/react/components/userPreferences/tests/ScheduledClose.spec.d.ts +1 -0
  413. package/react/components/userPreferences/tests/ScheduledClose.spec.js +47 -0
  414. package/react/components/userPreferences/tests/ScheduledClose.spec.js.map +1 -0
  415. package/react/components/windowTitleBar/WindowTitleBarShell.d.ts +1 -0
  416. package/react/components/windowTitleBar/WindowTitleBarShell.js +16 -6
  417. package/react/components/windowTitleBar/WindowTitleBarShell.js.map +1 -1
  418. package/react/components/windowTitleBar/components/center/TabList.js +2 -2
  419. package/react/components/windowTitleBar/components/center/TabList.js.map +1 -1
  420. package/react/components/windowTitleBar/components/left/LinkerButton.js.map +1 -1
  421. package/react/components/windowTitleBar/components/windowTitle.js +11 -10
  422. package/react/components/windowTitleBar/components/windowTitle.js.map +1 -1
  423. package/react/components/windowTitleBar/stores/windowTitleBarStore.js +12 -9
  424. package/react/components/windowTitleBar/stores/windowTitleBarStore.js.map +1 -1
  425. package/react/components/yesNoDialog/Timer.spec.js +1 -1
  426. package/react/components/yesNoDialog/Timer.spec.js.map +1 -1
  427. package/react/components/yesNoDialog/YesNoDialog.spec.js +1 -1
  428. package/react/components/yesNoDialog/YesNoDialog.spec.js.map +1 -1
  429. package/react/hooks/useSearch.d.ts +2 -1
  430. package/react/hooks/useSearch.js.map +1 -1
  431. package/react/hooks/useToolbar.js +6 -0
  432. package/react/hooks/useToolbar.js.map +1 -1
  433. package/react/reducers/rootReducer.d.ts +1 -1
  434. package/react/reducers/smartDesktopDesignerReducer.js +1 -1
  435. package/react/reducers/smartDesktopDesignerReducer.js.map +1 -1
  436. package/react/store.d.ts +2 -2
  437. package/react/types/advancedAppLauncherTypes.d.ts +5 -3
  438. package/react/types/advancedAppLauncherTypes.js.map +1 -1
  439. package/react/types/favoriteTypes.d.ts +4 -2
  440. package/react/types/favoriteTypes.js.map +1 -1
  441. package/react/types/smartDesktopDesignerTypes.d.ts +9 -1
  442. package/react/types/smartDesktopDesignerTypes.js.map +1 -1
  443. package/react/components/smartDesktopDesigner/AddApp.js.map +0 -1
  444. package/react/components/smartDesktopDesigner/AppEditAccess.js.map +0 -1
  445. package/react/components/smartDesktopDesigner/AppEditPage.js.map +0 -1
  446. package/react/components/smartDesktopDesigner/Appearance.helpers.js.map +0 -1
  447. package/react/components/smartDesktopDesigner/Appearance.js.map +0 -1
  448. package/react/components/smartDesktopDesigner/Application.js.map +0 -1
  449. package/react/components/smartDesktopDesigner/Applications.js.map +0 -1
  450. package/react/components/smartDesktopDesigner/AssetsPage.js.map +0 -1
  451. package/react/components/smartDesktopDesigner/Authentication.js.map +0 -1
  452. package/react/components/smartDesktopDesigner/AuthenticationProviderConfig.js.map +0 -1
  453. package/react/components/smartDesktopDesigner/Content.js.map +0 -1
  454. package/react/components/smartDesktopDesigner/ContentHeader.js.map +0 -1
  455. package/react/components/smartDesktopDesigner/CurrentView.js.map +0 -1
  456. package/react/components/smartDesktopDesigner/EditPreload.js +0 -169
  457. package/react/components/smartDesktopDesigner/EditPreload.js.map +0 -1
  458. package/react/components/smartDesktopDesigner/Export.js.map +0 -1
  459. package/react/components/smartDesktopDesigner/ExportCloud.js.map +0 -1
  460. package/react/components/smartDesktopDesigner/ExportDeployInfo.js.map +0 -1
  461. package/react/components/smartDesktopDesigner/ExportZip.js.map +0 -1
  462. package/react/components/smartDesktopDesigner/GettingStarted.js.map +0 -1
  463. package/react/components/smartDesktopDesigner/ItemList.js.map +0 -1
  464. package/react/components/smartDesktopDesigner/Navigation.js.map +0 -1
  465. package/react/components/smartDesktopDesigner/OptionalSettingsView.js +0 -71
  466. package/react/components/smartDesktopDesigner/OptionalSettingsView.js.map +0 -1
  467. package/react/components/smartDesktopDesigner/Preloads.d.ts +0 -8
  468. package/react/components/smartDesktopDesigner/Preloads.js +0 -26
  469. package/react/components/smartDesktopDesigner/Preloads.js.map +0 -1
  470. package/react/components/smartDesktopDesigner/ProjectErrors.js.map +0 -1
  471. package/react/components/smartDesktopDesigner/Publish.js.map +0 -1
  472. package/react/components/smartDesktopDesigner/PublishProgress.js.map +0 -1
  473. package/react/components/smartDesktopDesigner/ThemePage.js.map +0 -1
  474. package/react/components/smartDesktopDesigner/Themes.js.map +0 -1
  475. package/react/components/smartDesktopDesigner/Toolbar.js.map +0 -1
  476. package/react/components/smartDesktopDesigner/View.js.map +0 -1
  477. package/react/components/smartDesktopDesigner/common/fsbl_functions.js.map +0 -1
  478. package/react/components/smartDesktopDesigner/common/getCSSVars.js.map +0 -1
  479. package/react/components/smartDesktopDesigner/fixtures/apps.js.map +0 -1
  480. package/react/components/smartDesktopDesigner/fixtures/authenticationProps.js.map +0 -1
  481. package/react/components/smartDesktopDesigner/fixtures/configTemplate.js.map +0 -1
  482. package/react/components/smartDesktopDesigner/fixtures/exportProps.js.map +0 -1
  483. package/react/components/smartDesktopDesigner/fixtures/preloads.d.ts +0 -22
  484. package/react/components/smartDesktopDesigner/fixtures/preloads.js +0 -40
  485. package/react/components/smartDesktopDesigner/fixtures/preloads.js.map +0 -1
  486. package/react/components/smartDesktopDesigner/fixtures/projectErrorsProps.js.map +0 -1
  487. package/react/components/smartDesktopDesigner/fixtures/publishProgress.js.map +0 -1
  488. package/react/components/smartDesktopDesigner/fixtures/themeProps.js.map +0 -1
  489. package/react/components/smartDesktopDesigner/fixtures/views.js.map +0 -1
  490. package/react/components/smartDesktopDesigner/sdd_helpers.js.map +0 -1
  491. package/react/components/smartDesktopDesigner/stories/AppEditPage.stories.js.map +0 -1
  492. package/react/components/smartDesktopDesigner/stories/Appearance.stories.js.map +0 -1
  493. package/react/components/smartDesktopDesigner/stories/Applications.stories.js.map +0 -1
  494. package/react/components/smartDesktopDesigner/stories/AssetsPage.stories.js.map +0 -1
  495. package/react/components/smartDesktopDesigner/stories/Authentication.stories.js.map +0 -1
  496. package/react/components/smartDesktopDesigner/stories/ContentHeader.stories.js.map +0 -1
  497. package/react/components/smartDesktopDesigner/stories/EditPreload.stories.d.ts +0 -11
  498. package/react/components/smartDesktopDesigner/stories/EditPreload.stories.js +0 -35
  499. package/react/components/smartDesktopDesigner/stories/EditPreload.stories.js.map +0 -1
  500. package/react/components/smartDesktopDesigner/stories/Export.stories.js.map +0 -1
  501. package/react/components/smartDesktopDesigner/stories/ExportCloud.stories.js.map +0 -1
  502. package/react/components/smartDesktopDesigner/stories/ExportZip.stories.js.map +0 -1
  503. package/react/components/smartDesktopDesigner/stories/GettingStarted.stories.js.map +0 -1
  504. package/react/components/smartDesktopDesigner/stories/ItemList.stories.js.map +0 -1
  505. package/react/components/smartDesktopDesigner/stories/Navigation.stories.js.map +0 -1
  506. package/react/components/smartDesktopDesigner/stories/OptionalSettingsView.stories.js +0 -28
  507. package/react/components/smartDesktopDesigner/stories/OptionalSettingsView.stories.js.map +0 -1
  508. package/react/components/smartDesktopDesigner/stories/Preloads.stories.d.ts +0 -11
  509. package/react/components/smartDesktopDesigner/stories/Preloads.stories.js +0 -31
  510. package/react/components/smartDesktopDesigner/stories/Preloads.stories.js.map +0 -1
  511. package/react/components/smartDesktopDesigner/stories/ProjectErrors.stories.js.map +0 -1
  512. package/react/components/smartDesktopDesigner/stories/Publish.stories.js.map +0 -1
  513. package/react/components/smartDesktopDesigner/stories/PublishProgress.stories.js.map +0 -1
  514. package/react/components/smartDesktopDesigner/stories/SmartDesktopDesigner.stories.js.map +0 -1
  515. package/react/components/smartDesktopDesigner/stories/ThemePage.stories.js.map +0 -1
  516. package/react/components/smartDesktopDesigner/stories/Themes.stories.js.map +0 -1
  517. package/react/components/smartDesktopDesigner/stories/Toolbar.stories.js.map +0 -1
  518. package/react/components/smartDesktopDesigner/tests/AppEditPage.spec.js.map +0 -1
  519. package/react/components/smartDesktopDesigner/tests/Application.spec.js.map +0 -1
  520. package/react/components/smartDesktopDesigner/tests/Applications.spec.js.map +0 -1
  521. package/react/components/smartDesktopDesigner/tests/Authentication.spec.js.map +0 -1
  522. package/react/components/smartDesktopDesigner/tests/ContentHeader.spec.js.map +0 -1
  523. package/react/components/smartDesktopDesigner/tests/EditPreload.spec.js.map +0 -1
  524. package/react/components/smartDesktopDesigner/tests/Export.spec.js.map +0 -1
  525. package/react/components/smartDesktopDesigner/tests/ExportZip.spec.js.map +0 -1
  526. package/react/components/smartDesktopDesigner/tests/ItemList.spec.js.map +0 -1
  527. package/react/components/smartDesktopDesigner/tests/Navigation.spec.js.map +0 -1
  528. package/react/components/smartDesktopDesigner/tests/Preloads.spec.js +0 -47
  529. package/react/components/smartDesktopDesigner/tests/Preloads.spec.js.map +0 -1
  530. package/react/components/smartDesktopDesigner/tests/ProjectErrors.spec.js.map +0 -1
  531. package/react/components/smartDesktopDesigner/tests/Publish.spec.js.map +0 -1
  532. package/react/components/smartDesktopDesigner/tests/PublishProgess.spec.js.map +0 -1
  533. package/react/components/smartDesktopDesigner/tests/SmartDesktopDesigner.spec.js.map +0 -1
  534. package/react/components/smartDesktopDesigner/tests/Themes.spec.js.map +0 -1
  535. package/react/components/smartDesktopDesigner/tests/Toolbar.spec.js.map +0 -1
  536. package/react/components/smartDesktopDesigner/tests/a11y_helper.js.map +0 -1
  537. package/react/components/smartDesktopDesigner/tests/sdd_helpers.spec.js.map +0 -1
  538. package/react/components/smartDesktopDesigner/themeDefinitions.js.map +0 -1
  539. package/react/components/toolbar/appLauncher/DynamicAppLauncher.d.ts +0 -6
  540. package/react/components/toolbar/appLauncher/DynamicAppLauncher.js +0 -23
  541. package/react/components/toolbar/appLauncher/DynamicAppLauncher.js.map +0 -1
  542. package/react/components/userPreferences/components/general/ScheduledRestart.d.ts +0 -27
  543. package/react/components/userPreferences/components/general/ScheduledRestart.js +0 -190
  544. package/react/components/userPreferences/components/general/ScheduledRestart.js.map +0 -1
  545. package/react/components/userPreferences/tests/ScheduledRestart.spec.js +0 -70
  546. package/react/components/userPreferences/tests/ScheduledRestart.spec.js.map +0 -1
  547. package/react/hooks/useWorkspace.d.ts +0 -5
  548. package/react/hooks/useWorkspace.js +0 -26
  549. package/react/hooks/useWorkspace.js.map +0 -1
  550. package/react/types/iconTypes.d.ts +0 -11
  551. package/react/types/iconTypes.js +0 -2
  552. package/react/types/iconTypes.js.map +0 -1
  553. package/react/types/searchTypes.d.ts +0 -22
  554. package/react/types/searchTypes.js +0 -2
  555. package/react/types/searchTypes.js.map +0 -1
@@ -0,0 +1,143 @@
1
+ import React, { useEffect, useState } from "react";
2
+ import "./css/time-select.css";
3
+ import DefaultDropdownButton from "../shared/DefaultDropdownButton";
4
+ const DEFAULT_VALUE = {
5
+ hour: 4,
6
+ minute: 0,
7
+ meridiem: "AM",
8
+ };
9
+ export const TimeSelect = ({ initialTime, enabled = true, label = "Time:", onChange, className = "", minuteInterval = 15, }) => {
10
+ const [changed, setChanged] = useState(false);
11
+ const [time, setTime] = useState(initialTime !== null && initialTime !== void 0 ? initialTime : DEFAULT_VALUE);
12
+ let wrapClasses = `time-select ${className}`;
13
+ if (!enabled) {
14
+ wrapClasses = `${wrapClasses} disabled-time-select`;
15
+ }
16
+ let HOURS = [];
17
+ for (let i = 1; i < 13; i++) {
18
+ HOURS.push(i);
19
+ }
20
+ let MINUTES = ["00"];
21
+ for (let i = 1; i < 60; i++) {
22
+ if (i % minuteInterval == 0) {
23
+ MINUTES.push(i);
24
+ }
25
+ }
26
+ const setHour = (e) => {
27
+ let hour = Number(e);
28
+ if (hour < 12 && time.meridiem === "PM") {
29
+ hour = hour + 12;
30
+ }
31
+ else if (hour > 12 && time.meridiem === "AM") {
32
+ hour = hour - 12;
33
+ }
34
+ else if (time.meridiem === "AM" && hour === 12) {
35
+ hour = 0;
36
+ }
37
+ setTime(Object.assign(Object.assign({}, time), { hour }));
38
+ };
39
+ const setMinute = (e) => {
40
+ const minute = Number(e);
41
+ time.minute = minute;
42
+ setTime(Object.assign(Object.assign({}, time), { minute }));
43
+ };
44
+ const setMeridiem = (e) => {
45
+ const meridiem = e;
46
+ setTime(Object.assign(Object.assign({}, time), { meridiem }));
47
+ };
48
+ const correctMeridiem = () => {
49
+ if (!time.meridiem) {
50
+ let localMeridiem = "AM";
51
+ if (time.hour > 12 || (time.hour == 0 && time.minute == 0)) {
52
+ localMeridiem = "PM";
53
+ }
54
+ setMeridiem(localMeridiem);
55
+ }
56
+ };
57
+ useEffect(() => {
58
+ setHour(time.hour);
59
+ }, [time.meridiem]);
60
+ useEffect(() => {
61
+ correctMeridiem();
62
+ if (enabled && onChange && changed) {
63
+ onChange(time);
64
+ }
65
+ }, [time.hour, time.minute]);
66
+ const hourOptions = HOURS.map((hour) => {
67
+ return {
68
+ optionLabel: hour,
69
+ optionValue: hour,
70
+ clickHandler: () => {
71
+ setChanged(true);
72
+ setHour(hour);
73
+ },
74
+ };
75
+ });
76
+ const minuteOptions = MINUTES.map((minute) => {
77
+ return {
78
+ optionLabel: minute,
79
+ optionValue: minute,
80
+ clickHandler: () => {
81
+ setChanged(true);
82
+ setMinute(minute);
83
+ },
84
+ };
85
+ });
86
+ const getDisplayHour = () => {
87
+ if (time.meridiem === "AM" && time.hour === 0) {
88
+ return 12;
89
+ }
90
+ else if (time.meridiem === "PM" && time.hour > 12) {
91
+ return time.hour - 12;
92
+ }
93
+ else {
94
+ return time.hour;
95
+ }
96
+ };
97
+ return (React.createElement("div", { className: wrapClasses, style: { display: "flex" } },
98
+ React.createElement("span", { className: "time-select-label" }, label),
99
+ React.createElement("div", { className: "row-section", style: { width: "10px", marginRight: "40px" } },
100
+ React.createElement(DefaultDropdownButton, { classNames: "push-right", allowEmpty: false, caretLocation: "right", buttonOptions: hourOptions, defaultSelection: {
101
+ optionLabel: getDisplayHour().toString(),
102
+ optionValue: getDisplayHour(),
103
+ clickHandler: () => {
104
+ setHour(getDisplayHour());
105
+ },
106
+ }, enabled: enabled })),
107
+ React.createElement("div", { className: "row-section", style: { marginLeft: 30, marginRight: 10, marginTop: 5 } }, "\u00A0:\u00A0"),
108
+ React.createElement("div", { style: { width: "10px", marginRight: "65px" } },
109
+ React.createElement(DefaultDropdownButton, { classNames: "push-right", allowEmpty: false, caretLocation: "right", buttonOptions: minuteOptions, defaultSelection: {
110
+ optionLabel: (time.minute === 0 ? "00" : time.minute),
111
+ optionValue: time.minute,
112
+ clickHandler: () => {
113
+ setMinute(time.minute);
114
+ },
115
+ }, enabled: enabled })),
116
+ "\u00A0",
117
+ React.createElement("div", { className: "row-section", style: { width: "10px" } },
118
+ React.createElement(DefaultDropdownButton, { classNames: "push-right", allowEmpty: false, caretLocation: "right", buttonOptions: [
119
+ {
120
+ optionLabel: "AM",
121
+ optionValue: "AM",
122
+ clickHandler: () => {
123
+ setChanged(true);
124
+ setMeridiem("AM");
125
+ },
126
+ },
127
+ {
128
+ optionLabel: "PM",
129
+ optionValue: "PM",
130
+ clickHandler: () => {
131
+ setChanged(true);
132
+ setMeridiem("PM");
133
+ },
134
+ },
135
+ ], defaultSelection: {
136
+ optionLabel: time.meridiem,
137
+ optionValue: time.meridiem,
138
+ clickHandler: () => {
139
+ setHour(time.meridiem);
140
+ },
141
+ }, enabled: enabled }))));
142
+ };
143
+ //# sourceMappingURL=TimeSelect.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TimeSelect.js","sourceRoot":"","sources":["../../../src/components/common/TimeSelect.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAC;AACnD,OAAO,uBAAuB,CAAC;AAC/B,OAAO,qBAAqB,MAAM,iCAAiC,CAAC;AAiBpE,MAAM,aAAa,GAAmB;IACrC,IAAI,EAAE,CAAC;IACP,MAAM,EAAE,CAAC;IACT,QAAQ,EAAE,IAAI;CACd,CAAC;AAEF,MAAM,CAAC,MAAM,UAAU,GAA6C,CAAC,EACpE,WAAW,EACX,OAAO,GAAG,IAAI,EACd,KAAK,GAAG,OAAO,EACf,QAAQ,EACR,SAAS,GAAG,EAAE,EACd,cAAc,GAAG,EAAE,GACnB,EA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;wBACjB,WAAW,EAAE,IAAI;wBACjB,YAAY,EAAE,GAAG,EAAE;4BAClB,UAAU,CAAC,IAAI,CAAC,CAAC;4BACjB,WAAW,CAAC,IAAI,CAAC,CAAC;wBACnB,CAAC;qBACD;iBACD,EACD,gBAAgB,EAAE;oBACjB,WAAW,EAAE,IAAI,CAAC,QAAkB;oBACpC,WAAW,EAAE,IAAI,CAAC,QAAQ;oBAC1B,YAAY,EAAE,GAAG,EAAE;wBAClB,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;oBACxB,CAAC;iBACD,EACD,OAAO,EAAE,OAAO,GACf,CACG,CACD,CACN,CAAC;AACH,CAAC,CAAC","sourcesContent":["import React, { useEffect, useState } from \"react\";\nimport \"./css/time-select.css\";\nimport DefaultDropdownButton from \"../shared/DefaultDropdownButton\";\n\nexport interface TimeSelectProps {\n\tlabel?: string;\n\tinitialTime?: TimeSelectTime;\n\tonChange?: (time: TimeSelectTime) => void;\n\tenabled?: boolean;\n\tclassName?: string;\n\tminuteInterval?: number;\n}\n\nexport type TimeSelectTime = {\n\thour: number;\n\tminute: number;\n\tmeridiem?: string;\n};\n\nconst DEFAULT_VALUE: TimeSelectTime = {\n\thour: 4,\n\tminute: 0,\n\tmeridiem: \"AM\",\n};\n\nexport const TimeSelect: React.FunctionComponent<TimeSelectProps> = ({\n\tinitialTime,\n\tenabled = true,\n\tlabel = \"Time:\",\n\tonChange,\n\tclassName = \"\",\n\tminuteInterval = 15,\n}) => {\n\t/**\n\t * Prevents change event from triggering on initial setup\n\t */\n\tconst [changed, setChanged] = useState<boolean>(false);\n\tconst [time, setTime] = useState<TimeSelectTime>(initialTime ?? DEFAULT_VALUE);\n\n\tlet wrapClasses = `time-select ${className}`;\n\tif (!enabled) {\n\t\twrapClasses = `${wrapClasses} disabled-time-select`;\n\t}\n\n\t// Create an array 1-12.\n\tlet HOURS: Array<number> = [];\n\tfor (let i = 1; i < 13; i++) {\n\t\tHOURS.push(i);\n\t}\n\n\tlet MINUTES: any = [\"00\"];\n\tfor (let i = 1; i < 60; i++) {\n\t\tif (i % minuteInterval == 0) {\n\t\t\tMINUTES.push(i);\n\t\t}\n\t}\n\n\t/**\n\t * This method will transform 8 PM into 20:00. It also handles when the user changes the meridiem.\n\t * e.g., 8PM (20) => 8AM (8).\n\t * Set the minute, then set the 'finsemble.scheduledRestart' preference via the method on the Actions object.\n\t * @param {event} e\n\t */\n\tconst setHour = (e: any) => {\n\t\tlet hour = Number(e);\n\t\tif (hour < 12 && time.meridiem === \"PM\") {\n\t\t\thour = hour + 12;\n\t\t} else if (hour > 12 && time.meridiem === \"AM\") {\n\t\t\thour = hour - 12;\n\t\t} else if (time.meridiem === \"AM\" && hour === 12) {\n\t\t\thour = 0;\n\t\t}\n\n\t\tsetTime({ ...time, hour });\n\t};\n\n\t/**\n\t * Set the minute, then set the 'finsemble.scheduledRestart' preference via the method on the Actions object.\n\t * @param {event} e\n\t */\n\tconst setMinute = (e: any) => {\n\t\tconst minute = Number(e);\n\t\ttime.minute = minute;\n\t\tsetTime({ ...time, minute });\n\t};\n\n\t/**\n\t * Sets the meridiem for the time (AM or PM). This will trigger setHour to be called in a hook\n\t * @param {event} e\n\t */\n\tconst setMeridiem = (e: any) => {\n\t\tconst meridiem = e;\n\t\tsetTime({ ...time, meridiem });\n\t};\n\n\tconst correctMeridiem = () => {\n\t\tif (!time.meridiem) {\n\t\t\tlet localMeridiem = \"AM\";\n\t\t\tif (time.hour > 12 || (time.hour == 0 && time.minute == 0)) {\n\t\t\t\tlocalMeridiem = \"PM\";\n\t\t\t}\n\t\t\tsetMeridiem(localMeridiem);\n\t\t}\n\t};\n\n\t/**\n\t * The meridiem has changed, update the hour\n\t */\n\tuseEffect(() => {\n\t\tsetHour(time.hour);\n\t}, [time.meridiem]);\n\n\t/**\n\t * Call on change when the hour and minute values have changed\n\t */\n\tuseEffect(() => {\n\t\tcorrectMeridiem();\n\t\tif (enabled && onChange && changed) {\n\t\t\tonChange(time);\n\t\t}\n\t}, [time.hour, time.minute]);\n\n\tconst hourOptions: Array<any> = HOURS.map((hour: number) => {\n\t\treturn {\n\t\t\toptionLabel: hour,\n\t\t\toptionValue: hour,\n\t\t\tclickHandler: () => {\n\t\t\t\tsetChanged(true);\n\t\t\t\tsetHour(hour);\n\t\t\t},\n\t\t};\n\t});\n\tconst minuteOptions: Array<any> = MINUTES.map((minute: any) => {\n\t\treturn {\n\t\t\toptionLabel: minute,\n\t\t\toptionValue: minute,\n\t\t\tclickHandler: () => {\n\t\t\t\tsetChanged(true);\n\t\t\t\tsetMinute(minute);\n\t\t\t},\n\t\t};\n\t});\n\n\tconst getDisplayHour = () => {\n\t\tif (time.meridiem === \"AM\" && time.hour === 0) {\n\t\t\treturn 12;\n\t\t} else if (time.meridiem === \"PM\" && time.hour > 12) {\n\t\t\treturn time.hour - 12;\n\t\t} else {\n\t\t\treturn time.hour;\n\t\t}\n\t};\n\n\treturn (\n\t\t<div className={wrapClasses} style={{ display: \"flex\" }}>\n\t\t\t<span className=\"time-select-label\">{label}</span>\n\t\t\t{/* HOURS */}\n\t\t\t<div className=\"row-section\" style={{ width: \"10px\", marginRight: \"40px\" }}>\n\t\t\t\t<DefaultDropdownButton\n\t\t\t\t\tclassNames={\"push-right\"}\n\t\t\t\t\tallowEmpty={false}\n\t\t\t\t\tcaretLocation={\"right\"}\n\t\t\t\t\tbuttonOptions={hourOptions}\n\t\t\t\t\tdefaultSelection={{\n\t\t\t\t\t\toptionLabel: getDisplayHour().toString(),\n\t\t\t\t\t\toptionValue: getDisplayHour(),\n\t\t\t\t\t\tclickHandler: () => {\n\t\t\t\t\t\t\tsetHour(getDisplayHour());\n\t\t\t\t\t\t},\n\t\t\t\t\t}}\n\t\t\t\t\tenabled={enabled}\n\t\t\t\t/>\n\t\t\t</div>\n\t\t\t<div className=\"row-section\" style={{ marginLeft: 30, marginRight: 10, marginTop: 5 }}>\n\t\t\t\t&nbsp;:&nbsp;\n\t\t\t</div>\n\t\t\t{/* MINUTES */}\n\t\t\t<div style={{ width: \"10px\", marginRight: \"65px\" }}>\n\t\t\t\t<DefaultDropdownButton\n\t\t\t\t\tclassNames={\"push-right\"}\n\t\t\t\t\tallowEmpty={false}\n\t\t\t\t\tcaretLocation={\"right\"}\n\t\t\t\t\tbuttonOptions={minuteOptions}\n\t\t\t\t\tdefaultSelection={{\n\t\t\t\t\t\toptionLabel: (time.minute === 0 ? \"00\" : time.minute) as string,\n\t\t\t\t\t\toptionValue: time.minute,\n\t\t\t\t\t\tclickHandler: () => {\n\t\t\t\t\t\t\tsetMinute(time.minute);\n\t\t\t\t\t\t},\n\t\t\t\t\t}}\n\t\t\t\t\tenabled={enabled}\n\t\t\t\t/>\n\t\t\t</div>\n\t\t\t&nbsp;\n\t\t\t{/* MERIDIEM */}\n\t\t\t<div className=\"row-section\" style={{ width: \"10px\" }}>\n\t\t\t\t<DefaultDropdownButton\n\t\t\t\t\tclassNames={\"push-right\"}\n\t\t\t\t\tallowEmpty={false}\n\t\t\t\t\tcaretLocation={\"right\"}\n\t\t\t\t\tbuttonOptions={[\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\toptionLabel: \"AM\",\n\t\t\t\t\t\t\toptionValue: \"AM\",\n\t\t\t\t\t\t\tclickHandler: () => {\n\t\t\t\t\t\t\t\tsetChanged(true);\n\t\t\t\t\t\t\t\tsetMeridiem(\"AM\");\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\toptionLabel: \"PM\",\n\t\t\t\t\t\t\toptionValue: \"PM\",\n\t\t\t\t\t\t\tclickHandler: () => {\n\t\t\t\t\t\t\t\tsetChanged(true);\n\t\t\t\t\t\t\t\tsetMeridiem(\"PM\");\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t]}\n\t\t\t\t\tdefaultSelection={{\n\t\t\t\t\t\toptionLabel: time.meridiem as string,\n\t\t\t\t\t\toptionValue: time.meridiem,\n\t\t\t\t\t\tclickHandler: () => {\n\t\t\t\t\t\t\tsetHour(time.meridiem);\n\t\t\t\t\t\t},\n\t\t\t\t\t}}\n\t\t\t\t\tenabled={enabled}\n\t\t\t\t/>\n\t\t\t</div>\n\t\t</div>\n\t);\n};\n"]}
@@ -26,14 +26,12 @@
26
26
  }
27
27
 
28
28
  .accordion > .accordion-summary {
29
- margin: 0.5em 24px;
30
- margin-top: 0px;
29
+ margin: 0 24px 0.5em;
31
30
  }
32
31
 
33
32
  .accordion > .accordion-content {
34
- margin: 0.5em 22px;
35
- padding-bottom: 0px;
36
- margin-bottom: 0px;
33
+ margin: 0.5em 22px 0;
34
+ padding-bottom: 0;
37
35
  }
38
36
 
39
37
  .accordion > button .accordion-caret {
@@ -11,7 +11,10 @@
11
11
  .app-edit-actions {
12
12
  display: flex;
13
13
  justify-content: space-between;
14
- margin: 0.65em 3em;
14
+ margin-top: 0.65em;
15
+ margin-bottom: 0.65em;
16
+ margin-left: 22px;
17
+ margin-right: 3em;
15
18
  }
16
19
 
17
20
  .app-actions-right-wrapper {
@@ -0,0 +1,8 @@
1
+ .time-select-label {
2
+ margin-top: 0.45em;
3
+ margin-right: 0.5em;
4
+ }
5
+
6
+ .disabled-time-select {
7
+ color: var(--content-nav-highlighter) !important;
8
+ }
@@ -5,14 +5,46 @@
5
5
  }
6
6
 
7
7
  .finsembleToggle input[type="checkbox"] {
8
- margin: 0px;
8
+ margin: 0;
9
9
  width: 100%;
10
10
  height: 100%;
11
11
  z-index: 1;
12
12
  position: absolute;
13
- top: 0px;
14
- left: 0px;
13
+ top: 0;
14
+ left: 0;
15
15
  opacity: 0;
16
+ cursor: pointer;
17
+ }
18
+
19
+ .finsembleToggle.disabled input[type="checkbox"] {
20
+ cursor: default;
21
+ }
22
+
23
+ .toggle-text-label-wrapper {
24
+ display: flex;
25
+ width: 100%;
26
+ }
27
+
28
+ .toggle-text-label {
29
+ background: #22262f;
30
+ padding: 2px 10px;
31
+ border-radius: 2px;
32
+ }
33
+
34
+ .finsembleToggle-on .toggle-text-label_on {
35
+ background-color: #0a8cf4;
36
+ }
37
+
38
+ .finsembleToggle-off .toggle-text-label_off {
39
+ background-color: #0a8cf4;
40
+ }
41
+
42
+ .finsembleToggle-on:hover .toggle-text-label_off {
43
+ background-color: #3d4455;
44
+ }
45
+
46
+ .finsembleToggle-off:hover .toggle-text-label_on {
47
+ background-color: #3d4455;
16
48
  }
17
49
 
18
50
  .finsembleToggle-off .finsembleToggle-icon {
@@ -27,6 +59,10 @@
27
59
  color: #087ddb;
28
60
  }
29
61
 
62
+ .finsembleToggle.disabled {
63
+ filter: grayscale(10%) brightness(65%);
64
+ }
65
+
30
66
  .finsembleToggle .finsembleToggle-icon {
31
67
  font-size: 1.7rem;
32
68
  }
@@ -65,6 +65,7 @@ export const initFSBL = (windowObject) => {
65
65
  RouterClient: {
66
66
  transmit: () => { },
67
67
  addListener: () => { },
68
+ subscribe: () => { },
68
69
  },
69
70
  StorageClient: {
70
71
  save: () => { },
@@ -1 +1 @@
1
- {"version":3,"file":"helpers.js","sourceRoot":"","sources":["../../../src/components/common/helpers.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1C,MAAM,CAAC,MAAM,cAAc,GAAsB,CAAC,UAAgB,EAAE,EAAE,CACrE,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;IACvB,OAAO,CAAC;QACP,GAAG,EAAE,EAAE;QACP,IAAI,EAAE,UAAU,CAAC,IAAI;KACrB,CAAC,CAAC;AACJ,CAAC,CAAC,CAAC;AAEJ,MAAM,CAAC,MAAM,QAAQ,GAAG,CAAC,YAAkB,EAAE,EAAE;IAE9C,MAAM,WAAW,GAAQ,MAAM,CAAC;IAEhC,IAAI,CAAC,YAAY,EAAE;QAClB,YAAY,GAAG,WAAW,CAAC,MAAM,GAAG,EAA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M,CAAC;IAET,WAAW,CAAC,IAAI,CAAC,OAAO,mCACpB,WAAW,CAAC,IAAI,CAAC,OAAO,KAC3B,YAAY,EAAE;YACb,QAAQ,EAAE,GAAG,EAAE,GAAE,CAAC;SACX,GACR,CAAC;IAEF,WAAW,CAAC,eAAe,GAAG,YAAY,CAAC,eAAe,GAAG;QAC5D,cAAc,EAAE,GAAG,EAAE,GAAE,CAAC;QACxB,gBAAgB,EAAE,GAAG,EAAE,GAAE,CAAC;QAC1B,mBAAmB,EAAE,GAAG,EAAE,GAAE,CAAC;KAC7B,CAAC;AACH,CAAC,CAAC;AAEF,MAAM,UAAU,WAAW,CAAI,SAAmB,EAAE,IAAO;IAC1D,MAAM,QAAQ,GAAa,CAAC,KAAQ,EAAE,EAAE;QACvC,QAAQ,CAAC,MAAM,CAAC,CAAC;QAEjB,OAAO,CACN,oBAAC,QAAQ,IAAC,KAAK,EAAE,WAAW,EAAE;YAC7B,oBAAC,SAAS,oDAAU,IAAI,GAAK,KAAK,GAAM,CAC9B,CACX,CAAC;IACH,CAAC,CAAC;IAEF,QAAQ,CAAC,IAAI,GAAG,IAAI,CAAC;IAErB,OAAO,QAAQ,CAAC;AACjB,CAAC","sourcesContent":["import React from \"react\";\nimport { FileInputUploadCb } from \"./FileInput\";\nimport { Story } from \"@storybook/react/types-6-0\";\n\nimport { SDServerInfo } from \"../../types/smartDesktopDesignerTypes\";\nimport { Provider } from \"react-redux\";\nimport { createStore } from \"../../store\";\n\nexport const uploadFunction: FileInputUploadCb = (fileObject: File) =>\n\tnew Promise((resolve) => {\n\t\tresolve({\n\t\t\terr: \"\",\n\t\t\tpath: fileObject.name,\n\t\t});\n\t});\n\nexport const initFSBL = (windowObject?: any) => {\n\t// Poor man's global that can take any appendage\n\tconst globalAsAny: any = global;\n\n\tif (!windowObject) {\n\t\twindowObject = globalAsAny.window = {} as any;\n\t} else {\n\t\twindowObject = window;\n\n\t\tsetTimeout(() => {\n\t\t\tconst event = window.document.createEvent(\"Event\");\n\n\t\t\tevent?.initEvent(\"FSBLReady\", true, true);\n\n\t\t\twindow.dispatchEvent(event);\n\t\t});\n\t}\n\n\tglobalAsAny.FSBL = windowObject.FSBL = {\n\t\taddEventListener: (name: String, callback: () => void) => {\n\t\t\tcallback();\n\t\t},\n\t\tClients: {\n\t\t\tSmartDesktopClient: {\n\t\t\t\tcheckValidURL(url: string) {\n\t\t\t\t\tif (url.length === 0) {\n\t\t\t\t\t\treturn true;\n\t\t\t\t\t}\n\t\t\t\t\treturn /^https?:\\/\\/[^\\s]+$/.test(url);\n\t\t\t\t},\n\t\t\t\tcheckValidProjectName(name: string) {\n\t\t\t\t\treturn /^[a-zA-Z0-9 \\-_.]{1,}$/.test(name) && /[a-zA-Z0-9]{1,}/.test(name);\n\t\t\t\t},\n\t\t\t} as unknown,\n\t\t\tConfigClient: {\n\t\t\t\tsetPreference: () => {},\n\t\t\t\tgetValues: () => {},\n\t\t\t\tgetPreferences: () => {},\n\t\t\t},\n\t\t\tDialogManager: {\n\t\t\t\tspawnDialog: (obj1: any) => {\n\t\t\t\t\tconsole.table(obj1);\n\t\t\t\t},\n\t\t\t\tregisterDialogCallback: () => {},\n\t\t\t\trespondToOpener: () => {},\n\t\t\t},\n\t\t\tLauncherClient: {\n\t\t\t\tshowWindow: () => {},\n\t\t\t},\n\t\t\tLogger: {\n\t\t\t\tlog: () => {},\n\t\t\t\terror: () => {},\n\t\t\t\tsystem: {\n\t\t\t\t\tdebug: () => {},\n\t\t\t\t\tlog: () => {},\n\t\t\t\t\terror: () => {},\n\t\t\t\t\tverbose: () => {},\n\t\t\t\t\tdeprecated: () => {},\n\t\t\t\t},\n\t\t\t},\n\t\t\tRouterClient: {\n\t\t\t\ttransmit: () => {},\n\t\t\t\taddListener: () => {},\n\t\t\t},\n\t\t\tStorageClient: {\n\t\t\t\tsave: () => {},\n\t\t\t\tclearCache: () => {},\n\t\t\t},\n\t\t\tWindowClient: {\n\t\t\t\tfitToDOM: () => {},\n\t\t\t},\n\t\t\tWorkspaceClient: {\n\t\t\t\tbringWindowsToFront: () => {},\n\t\t\t\tminimizeAll: () => {},\n\t\t\t\tactiveWorkspace: {\n\t\t\t\t\tname: \" \",\n\t\t\t\t},\n\t\t\t\tgetWorkspaceDefinition: (obj: Object, cb: Function) => {\n\t\t\t\t\tcb(null, null);\n\t\t\t\t},\n\t\t\t},\n\t\t},\n\t\tonShutdown: () => {},\n\t\tSystem: {\n\t\t\tgetSDServerInfo: () =>\n\t\t\t\tnew Promise((resolve) => {\n\t\t\t\t\tresolve({} as SDServerInfo);\n\t\t\t\t}),\n\t\t},\n\t\tSystemManagerClient: {\n\t\t\tpublishCheckpointState: () => {},\n\t\t},\n\t} as any;\n\n\tglobalAsAny.FSBL.Clients = {\n\t\t...globalAsAny.FSBL.Clients,\n\t\tWindowClient: {\n\t\t\tfitToDOM: () => {},\n\t\t} as any,\n\t};\n\n\tglobalAsAny.finsembleWindow = windowObject.finsembleWindow = {\n\t\tsetAlwaysOnTop: () => {},\n\t\taddEventListener: () => {},\n\t\tremoveEventListener: () => {},\n\t};\n};\n\nexport function createStory<T>(Component: Function, args: T) {\n\tconst template: Story<T> = (props: T) => {\n\t\tinitFSBL(window);\n\n\t\treturn (\n\t\t\t<Provider store={createStore()}>\n\t\t\t\t<Component {...{ ...args, ...props }} />\n\t\t\t</Provider>\n\t\t);\n\t};\n\n\ttemplate.args = args;\n\n\treturn template;\n}\n"]}
1
+ {"version":3,"file":"helpers.js","sourceRoot":"","sources":["../../../src/components/common/helpers.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAK1B,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAE1C,MAAM,CAAC,MAAM,cAAc,GAAsB,CAAC,UAAgB,EAAE,EAAE,CACrE,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;IACvB,OAAO,CAAC;QACP,GAAG,E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AAI,CAAC,CAAC;gBAChB,CAAC;aACD;SACD;QACD,UAAU,EAAE,GAAG,EAAE,GAAE,CAAC;QACpB,MAAM,EAAE;YACP,eAAe,EAAE,GAAG,EAAE,CACrB,IAAI,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;gBACvB,OAAO,CAAC,EAAkB,CAAC,CAAC;YAC7B,CAAC,CAAC;SACH;QACD,mBAAmB,EAAE;YACpB,sBAAsB,EAAE,GAAG,EAAE,GAAE,CAAC;SAChC;KACM,CAAC;IAET,WAAW,CAAC,IAAI,CAAC,OAAO,mCACpB,WAAW,CAAC,IAAI,CAAC,OAAO,KAC3B,YAAY,EAAE;YACb,QAAQ,EAAE,GAAG,EAAE,GAAE,CAAC;SACX,GACR,CAAC;IAEF,WAAW,CAAC,eAAe,GAAG,YAAY,CAAC,eAAe,GAAG;QAC5D,cAAc,EAAE,GAAG,EAAE,GAAE,CAAC;QACxB,gBAAgB,EAAE,GAAG,EAAE,GAAE,CAAC;QAC1B,mBAAmB,EAAE,GAAG,EAAE,GAAE,CAAC;KAC7B,CAAC;AACH,CAAC,CAAC;AAEF,MAAM,UAAU,WAAW,CAAI,SAAmB,EAAE,IAAO;IAC1D,MAAM,QAAQ,GAAa,CAAC,KAAQ,EAAE,EAAE;QACvC,QAAQ,CAAC,MAAM,CAAC,CAAC;QAEjB,OAAO,CACN,oBAAC,QAAQ,IAAC,KAAK,EAAE,WAAW,EAAE;YAC7B,oBAAC,SAAS,oDAAU,IAAI,GAAK,KAAK,GAAM,CAC9B,CACX,CAAC;IACH,CAAC,CAAC;IAEF,QAAQ,CAAC,IAAI,GAAG,IAAI,CAAC;IAErB,OAAO,QAAQ,CAAC;AACjB,CAAC","sourcesContent":["import React from \"react\";\nimport { FileInputUploadCb } from \"./FileInput\";\nimport { Story } from \"@storybook/react/types-6-0\";\n\nimport { SDServerInfo } from \"../../types/smartDesktopDesignerTypes\";\nimport { Provider } from \"react-redux\";\nimport { createStore } from \"../../store\";\n\nexport const uploadFunction: FileInputUploadCb = (fileObject: File) =>\n\tnew Promise((resolve) => {\n\t\tresolve({\n\t\t\terr: \"\",\n\t\t\tpath: fileObject.name,\n\t\t});\n\t});\n\nexport const initFSBL = (windowObject?: any) => {\n\t// Poor man's global that can take any appendage\n\tconst globalAsAny: any = global;\n\n\tif (!windowObject) {\n\t\twindowObject = globalAsAny.window = {} as any;\n\t} else {\n\t\twindowObject = window;\n\n\t\tsetTimeout(() => {\n\t\t\tconst event = window.document.createEvent(\"Event\");\n\n\t\t\tevent?.initEvent(\"FSBLReady\", true, true);\n\n\t\t\twindow.dispatchEvent(event);\n\t\t});\n\t}\n\n\tglobalAsAny.FSBL = windowObject.FSBL = {\n\t\taddEventListener: (name: String, callback: () => void) => {\n\t\t\tcallback();\n\t\t},\n\t\tClients: {\n\t\t\tSmartDesktopClient: {\n\t\t\t\tcheckValidURL(url: string) {\n\t\t\t\t\tif (url.length === 0) {\n\t\t\t\t\t\treturn true;\n\t\t\t\t\t}\n\t\t\t\t\treturn /^https?:\\/\\/[^\\s]+$/.test(url);\n\t\t\t\t},\n\t\t\t\tcheckValidProjectName(name: string) {\n\t\t\t\t\treturn /^[a-zA-Z0-9 \\-_.]{1,}$/.test(name) && /[a-zA-Z0-9]{1,}/.test(name);\n\t\t\t\t},\n\t\t\t} as unknown,\n\t\t\tConfigClient: {\n\t\t\t\tsetPreference: () => {},\n\t\t\t\tgetValues: () => {},\n\t\t\t\tgetPreferences: () => {},\n\t\t\t},\n\t\t\tDialogManager: {\n\t\t\t\tspawnDialog: (obj1: any) => {\n\t\t\t\t\tconsole.table(obj1);\n\t\t\t\t},\n\t\t\t\tregisterDialogCallback: () => {},\n\t\t\t\trespondToOpener: () => {},\n\t\t\t},\n\t\t\tLauncherClient: {\n\t\t\t\tshowWindow: () => {},\n\t\t\t},\n\t\t\tLogger: {\n\t\t\t\tlog: () => {},\n\t\t\t\terror: () => {},\n\t\t\t\tsystem: {\n\t\t\t\t\tdebug: () => {},\n\t\t\t\t\tlog: () => {},\n\t\t\t\t\terror: () => {},\n\t\t\t\t\tverbose: () => {},\n\t\t\t\t\tdeprecated: () => {},\n\t\t\t\t},\n\t\t\t},\n\t\t\tRouterClient: {\n\t\t\t\ttransmit: () => {},\n\t\t\t\taddListener: () => {},\n\t\t\t\tsubscribe: () => {},\n\t\t\t},\n\t\t\tStorageClient: {\n\t\t\t\tsave: () => {},\n\t\t\t\tclearCache: () => {},\n\t\t\t},\n\t\t\tWindowClient: {\n\t\t\t\tfitToDOM: () => {},\n\t\t\t},\n\t\t\tWorkspaceClient: {\n\t\t\t\tbringWindowsToFront: () => {},\n\t\t\t\tminimizeAll: () => {},\n\t\t\t\tactiveWorkspace: {\n\t\t\t\t\tname: \" \",\n\t\t\t\t},\n\t\t\t\tgetWorkspaceDefinition: (obj: Object, cb: Function) => {\n\t\t\t\t\tcb(null, null);\n\t\t\t\t},\n\t\t\t},\n\t\t},\n\t\tonShutdown: () => {},\n\t\tSystem: {\n\t\t\tgetSDServerInfo: () =>\n\t\t\t\tnew Promise((resolve) => {\n\t\t\t\t\tresolve({} as SDServerInfo);\n\t\t\t\t}),\n\t\t},\n\t\tSystemManagerClient: {\n\t\t\tpublishCheckpointState: () => {},\n\t\t},\n\t} as any;\n\n\tglobalAsAny.FSBL.Clients = {\n\t\t...globalAsAny.FSBL.Clients,\n\t\tWindowClient: {\n\t\t\tfitToDOM: () => {},\n\t\t} as any,\n\t};\n\n\tglobalAsAny.finsembleWindow = windowObject.finsembleWindow = {\n\t\tsetAlwaysOnTop: () => {},\n\t\taddEventListener: () => {},\n\t\tremoveEventListener: () => {},\n\t};\n};\n\nexport function createStory<T>(Component: Function, args: T) {\n\tconst template: Story<T> = (props: T) => {\n\t\tinitFSBL(window);\n\n\t\treturn (\n\t\t\t<Provider store={createStore()}>\n\t\t\t\t<Component {...{ ...args, ...props }} />\n\t\t\t</Provider>\n\t\t);\n\t};\n\n\ttemplate.args = args;\n\n\treturn template;\n}\n"]}
@@ -4,7 +4,7 @@ import "../../../assets/css/finsemble.css";
4
4
  import "../css/styles.css";
5
5
  declare const _default: {
6
6
  title: string;
7
- component: ({ acceptTypes, value, onSetValue, id, shouldUpload, uploadFunction, presetFile, suppressDropzone, disabled, }: FileInputProps) => JSX.Element;
7
+ component: ({ acceptTypes, value, onSetValue, id, shouldUpload, uploadFunction, presetFile, suppressDropzone, disabled, allowClearing, }: FileInputProps) => JSX.Element;
8
8
  };
9
9
  export default _default;
10
10
  export declare const EmptyField: import("@storybook/react").Story<FileInputProps>;
@@ -13,3 +13,4 @@ export declare const PreFilledField: import("@storybook/react").Story<FileInputP
13
13
  export declare const PreFilledInvalidField: import("@storybook/react").Story<FileInputProps>;
14
14
  export declare const anyField: import("@storybook/react").Story<FileInputProps>;
15
15
  export declare const hasId: import("@storybook/react").Story<FileInputProps>;
16
+ export declare const PreFilledFieldNoClearing: import("@storybook/react").Story<FileInputProps>;
@@ -38,4 +38,10 @@ export const hasId = createStory(FileInput, {
38
38
  uploadFunction,
39
39
  id: "myId",
40
40
  });
41
+ export const PreFilledFieldNoClearing = createStory(FileInput, {
42
+ acceptTypes: ["image/png"],
43
+ value: "ThisIsATest.png",
44
+ uploadFunction,
45
+ allowClearing: false,
46
+ });
41
47
  //# sourceMappingURL=FileInput.stories.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"FileInput.stories.js","sourceRoot":"","sources":["../../../../src/components/common/stories/FileInput.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AACzD,OAAO,EAAE,SAAS,EAAkB,MAAM,cAAc,CAAC;AACzD,OAAO,mCAAmC,CAAC;AAC3C,OAAO,mBAAmB,CAAC;AAE3B,eAAe;IACd,KAAK,EAAE,kBAAkB;IACzB,SAAS,EAAE,SAAS;CACpB,CAAC;AAEF,MAAM,CAAC,MAAM,UAAU,GAAG,WAAW,CAAiB,SAAS,EAAE;IAChE,KAAK,EAAE,EAAE;IACT,WAAW,EAAE,CAAC,WAAW,CAAC;IAC1B,cAAc;CACd,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,QAAQ,GAAG,WAAW,CAAiB,SAAS,EAAE;IAC9D,KAAK,EAAE,EAAE;IACT,WAAW,EAAE,CAAC,WAAW,CAAC;IAC1B,cAAc;IACd,QAAQ,EAAE,IAAI;CACd,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,cAAc,GAAG,WAAW,CAAiB,SAAS,EAAE;IACpE,WAAW,EAAE,CAAC,WAAW,CAAC;IAC1B,KAAK,EAAE,iBAAiB;IACxB,cAAc;CACd,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,qBAAqB,GAAG,WAAW,CAAiB,SAAS,EAAE;IAC3E,WAAW,EAAE,CAAC,WAAW,CAAC;IAC1B,KAAK,EAAE,eAAe;IACtB,cAAc;CACd,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,QAAQ,GAAG,WAAW,CAAiB,SAAS,EAAE;IAC9D,WAAW,EAAE,CAAC,GAAG,CAAC;IAClB,KAAK,EAAE,SAAS;IAChB,cAAc;CACd,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,KAAK,GAAG,WAAW,CAAiB,SAAS,EAAE;IAC3D,WAAW,EAAE,CAAC,GAAG,CAAC;IAClB,KAAK,EAAE,EAAE;IACT,cAAc;IACd,EAAE,EAAE,MAAM;CACV,CAAC,CAAC","sourcesContent":["import { createStory, uploadFunction } from \"../helpers\";\nimport { FileInput, FileInputProps } from \"../FileInput\";\nimport \"../../../assets/css/finsemble.css\";\nimport \"../css/styles.css\";\n\nexport default {\n\ttitle: \"Common/FileInput\",\n\tcomponent: FileInput,\n};\n\nexport const EmptyField = createStory<FileInputProps>(FileInput, {\n\tvalue: \"\",\n\tacceptTypes: [\"image/png\"],\n\tuploadFunction,\n});\n\nexport const Disabled = createStory<FileInputProps>(FileInput, {\n\tvalue: \"\",\n\tacceptTypes: [\"image/png\"],\n\tuploadFunction,\n\tdisabled: true,\n});\n\nexport const PreFilledField = createStory<FileInputProps>(FileInput, {\n\tacceptTypes: [\"image/png\"],\n\tvalue: \"ThisIsATest.png\",\n\tuploadFunction,\n});\n\nexport const PreFilledInvalidField = createStory<FileInputProps>(FileInput, {\n\tacceptTypes: [\"image/png\"],\n\tvalue: \"MyBadPath.jpg\",\n\tuploadFunction,\n});\n\nexport const anyField = createStory<FileInputProps>(FileInput, {\n\tacceptTypes: [\"*\"],\n\tvalue: \"abc.exe\",\n\tuploadFunction,\n});\n\nexport const hasId = createStory<FileInputProps>(FileInput, {\n\tacceptTypes: [\"*\"],\n\tvalue: \"\",\n\tuploadFunction,\n\tid: \"myId\",\n});\n"]}
1
+ {"version":3,"file":"FileInput.stories.js","sourceRoot":"","sources":["../../../../src/components/common/stories/FileInput.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AACzD,OAAO,EAAE,SAAS,EAAkB,MAAM,cAAc,CAAC;AACzD,OAAO,mCAAmC,CAAC;AAC3C,OAAO,mBAAmB,CAAC;AAE3B,eAAe;IACd,KAAK,EAAE,kBAAkB;IACzB,SAAS,EAAE,SAAS;CACpB,CAAC;AAEF,MAAM,CAAC,MAAM,UAAU,GAAG,WAAW,CAAiB,SAAS,EAAE;IAChE,KAAK,EAAE,EAAE;IACT,WAAW,EAAE,CAAC,WAAW,CAAC;IAC1B,cAAc;CACd,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,QAAQ,GAAG,WAAW,CAAiB,SAAS,EAAE;IAC9D,KAAK,EAAE,EAAE;IACT,WAAW,EAAE,CAAC,WAAW,CAAC;IAC1B,cAAc;IACd,QAAQ,EAAE,IAAI;CACd,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,cAAc,GAAG,WAAW,CAAiB,SAAS,EAAE;IACpE,WAAW,EAAE,CAAC,WAAW,CAAC;IAC1B,KAAK,EAAE,iBAAiB;IACxB,cAAc;CACd,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,qBAAqB,GAAG,WAAW,CAAiB,SAAS,EAAE;IAC3E,WAAW,EAAE,CAAC,WAAW,CAAC;IAC1B,KAAK,EAAE,eAAe;IACtB,cAAc;CACd,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,QAAQ,GAAG,WAAW,CAAiB,SAAS,EAAE;IAC9D,WAAW,EAAE,CAAC,GAAG,CAAC;IAClB,KAAK,EAAE,SAAS;IAChB,cAAc;CACd,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,KAAK,GAAG,WAAW,CAAiB,SAAS,EAAE;IAC3D,WAAW,EAAE,CAAC,GAAG,CAAC;IAClB,KAAK,EAAE,EAAE;IACT,cAAc;IACd,EAAE,EAAE,MAAM;CACV,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,wBAAwB,GAAG,WAAW,CAAiB,SAAS,EAAE;IAC9E,WAAW,EAAE,CAAC,WAAW,CAAC;IAC1B,KAAK,EAAE,iBAAiB;IACxB,cAAc;IACd,aAAa,EAAE,KAAK;CACpB,CAAC,CAAC","sourcesContent":["import { createStory, uploadFunction } from \"../helpers\";\nimport { FileInput, FileInputProps } from \"../FileInput\";\nimport \"../../../assets/css/finsemble.css\";\nimport \"../css/styles.css\";\n\nexport default {\n\ttitle: \"Common/FileInput\",\n\tcomponent: FileInput,\n};\n\nexport const EmptyField = createStory<FileInputProps>(FileInput, {\n\tvalue: \"\",\n\tacceptTypes: [\"image/png\"],\n\tuploadFunction,\n});\n\nexport const Disabled = createStory<FileInputProps>(FileInput, {\n\tvalue: \"\",\n\tacceptTypes: [\"image/png\"],\n\tuploadFunction,\n\tdisabled: true,\n});\n\nexport const PreFilledField = createStory<FileInputProps>(FileInput, {\n\tacceptTypes: [\"image/png\"],\n\tvalue: \"ThisIsATest.png\",\n\tuploadFunction,\n});\n\nexport const PreFilledInvalidField = createStory<FileInputProps>(FileInput, {\n\tacceptTypes: [\"image/png\"],\n\tvalue: \"MyBadPath.jpg\",\n\tuploadFunction,\n});\n\nexport const anyField = createStory<FileInputProps>(FileInput, {\n\tacceptTypes: [\"*\"],\n\tvalue: \"abc.exe\",\n\tuploadFunction,\n});\n\nexport const hasId = createStory<FileInputProps>(FileInput, {\n\tacceptTypes: [\"*\"],\n\tvalue: \"\",\n\tuploadFunction,\n\tid: \"myId\",\n});\n\nexport const PreFilledFieldNoClearing = createStory<FileInputProps>(FileInput, {\n\tacceptTypes: [\"image/png\"],\n\tvalue: \"ThisIsATest.png\",\n\tuploadFunction,\n\tallowClearing: false,\n});\n"]}
@@ -5,8 +5,10 @@ import "../css/styles.css";
5
5
  import { Story } from "@storybook/react/types-6-0";
6
6
  declare const _default: {
7
7
  title: string;
8
- component: ({ checked, onChange, label }: FinsembleToggleProps) => JSX.Element;
8
+ component: ({ checked, onChange, label, enabled, textToggle }: FinsembleToggleProps) => JSX.Element;
9
9
  };
10
10
  export default _default;
11
11
  export declare const Unchecked: Story<FinsembleToggleProps>;
12
12
  export declare const Checked: Story<FinsembleToggleProps>;
13
+ export declare const Disabled: Story<FinsembleToggleProps>;
14
+ export declare const TextLabels: Story<FinsembleToggleProps>;
@@ -20,4 +20,16 @@ Checked.args = {
20
20
  onChange: action("Selected values"),
21
21
  label: "Pre-checked test",
22
22
  };
23
+ export const Disabled = Template.bind({});
24
+ Disabled.args = {
25
+ enabled: false,
26
+ label: "Pre-checked test",
27
+ };
28
+ export const TextLabels = Template.bind({});
29
+ TextLabels.args = {
30
+ checked: true,
31
+ onChange: action("Selected values"),
32
+ label: "Pre-checked test",
33
+ textToggle: ["Daily", "Weekly"],
34
+ };
23
35
  //# sourceMappingURL=FinsembleToggle.stories.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"FinsembleToggle.stories.js","sourceRoot":"","sources":["../../../../src/components/common/stories/FinsembleToggle.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,eAAe,EAAwB,MAAM,oBAAoB,CAAC;AAC3E,OAAO,mCAAmC,CAAC;AAC3C,OAAO,mBAAmB,CAAC;AAE3B,OAAO,EAAE,MAAM,EAAE,MAAM,0BAA0B,CAAC;AAElD,eAAe;IACd,KAAK,EAAE,wBAAwB;IAC/B,SAAS,EAAE,eAAe;CAC1B,CAAC;AAEF,MAAM,QAAQ,GAAgC,CAAC,IAA0B,EAAE,EAAE,CAAC,oBAAC,eAAe,oBAAK,IAAI,EAAI,CAAC;AAE5G,MAAM,CAAC,MAAM,SAAS,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AAC3C,SAAS,CAAC,IAAI,GAAG;IAChB,OAAO,EAAE,KAAK;IACd,QAAQ,EAAE,MAAM,CAAC,iBAAiB,CAAC;IACnC,KAAK,EAAE,MAAM;CACb,CAAC;AACF,MAAM,CAAC,MAAM,OAAO,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AACzC,OAAO,CAAC,IAAI,GAAG;IACd,OAAO,EAAE,IAAI;IACb,QAAQ,EAAE,MAAM,CAAC,iBAAiB,CAAC;IACnC,KAAK,EAAE,kBAAkB;CACzB,CAAC","sourcesContent":["import React from \"react\";\nimport { FinsembleToggle, FinsembleToggleProps } from \"../FinsembleToggle\";\nimport \"../../../assets/css/finsemble.css\";\nimport \"../css/styles.css\";\nimport { Story } from \"@storybook/react/types-6-0\";\nimport { action } from \"@storybook/addon-actions\";\n\nexport default {\n\ttitle: \"Common/FinsembleToggle\",\n\tcomponent: FinsembleToggle,\n};\n\nconst Template: Story<FinsembleToggleProps> = (args: FinsembleToggleProps) => <FinsembleToggle {...args} />;\n\nexport const Unchecked = Template.bind({});\nUnchecked.args = {\n\tchecked: false,\n\tonChange: action(\"Selected values\"),\n\tlabel: \"Test\",\n};\nexport const Checked = Template.bind({});\nChecked.args = {\n\tchecked: true,\n\tonChange: action(\"Selected values\"),\n\tlabel: \"Pre-checked test\",\n};\n"]}
1
+ {"version":3,"file":"FinsembleToggle.stories.js","sourceRoot":"","sources":["../../../../src/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AAE,CAAC,OAAO,EAAE,QAAQ,CAAC;CAC/B,CAAC","sourcesContent":["import React from \"react\";\nimport { FinsembleToggle, FinsembleToggleProps } from \"../FinsembleToggle\";\nimport \"../../../assets/css/finsemble.css\";\nimport \"../css/styles.css\";\nimport { Story } from \"@storybook/react/types-6-0\";\nimport { action } from \"@storybook/addon-actions\";\n\nexport default {\n\ttitle: \"Common/FinsembleToggle\",\n\tcomponent: FinsembleToggle,\n};\n\nconst Template: Story<FinsembleToggleProps> = (args: FinsembleToggleProps) => <FinsembleToggle {...args} />;\n\nexport const Unchecked = Template.bind({});\nUnchecked.args = {\n\tchecked: false,\n\tonChange: action(\"Selected values\"),\n\tlabel: \"Test\",\n};\nexport const Checked = Template.bind({});\nChecked.args = {\n\tchecked: true,\n\tonChange: action(\"Selected values\"),\n\tlabel: \"Pre-checked test\",\n};\n\nexport const Disabled = Template.bind({});\nDisabled.args = {\n\tenabled: false,\n\tlabel: \"Pre-checked test\",\n};\n\nexport const TextLabels = Template.bind({});\nTextLabels.args = {\n\tchecked: true,\n\tonChange: action(\"Selected values\"),\n\tlabel: \"Pre-checked test\",\n\ttextToggle: [\"Daily\", \"Weekly\"],\n};\n"]}
@@ -0,0 +1,11 @@
1
+ import React from "react";
2
+ import { TimeSelectProps } from "../TimeSelect";
3
+ import { Story } from "@storybook/react/types-6-0";
4
+ import "../../../assets/css/finsemble.css";
5
+ declare const _default: {
6
+ title: string;
7
+ component: React.FunctionComponent<TimeSelectProps>;
8
+ };
9
+ export default _default;
10
+ export declare const Default: Story<TimeSelectProps>;
11
+ export declare const Disabled: Story<TimeSelectProps>;
@@ -0,0 +1,20 @@
1
+ import React from "react";
2
+ import { TimeSelect } from "../TimeSelect";
3
+ import "../../../assets/css/finsemble.css";
4
+ export default {
5
+ title: "Common/TimeSelect",
6
+ component: TimeSelect,
7
+ };
8
+ const Template = (args) => React.createElement(TimeSelect, Object.assign({}, args));
9
+ export const Default = Template.bind({});
10
+ Default.args = {
11
+ initialTime: {
12
+ hour: 22,
13
+ minute: 15,
14
+ },
15
+ };
16
+ export const Disabled = Template.bind({});
17
+ Disabled.args = {
18
+ enabled: false,
19
+ };
20
+ //# sourceMappingURL=TimeSelect.stories.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TimeSelect.stories.js","sourceRoot":"","sources":["../../../../src/components/common/stories/TimeSelect.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,UAAU,EAAmB,MAAM,eAAe,CAAC;AAE5D,OAAO,mCAAmC,CAAC;AAE3C,eAAe;IACd,KAAK,EAAE,mBAAmB;IAC1B,SAAS,EAAE,UAAU;CACrB,CAAC;AAEF,MAAM,QAAQ,GAA2B,CAAC,IAAqB,EAAE,EAAE,CAAC,oBAAC,UAAU,oBAAK,IAAI,EAAI,CAAC;AAE7F,MAAM,CAAC,MAAM,OAAO,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AACzC,OAAO,CAAC,IAAI,GAAG;IACd,WAAW,EAAE;QACZ,IAAI,EAAE,EAAE;QACR,MAAM,EAAE,EAAE;KACV;CACD,CAAC;AAEF,MAAM,CAAC,MAAM,QAAQ,GAAG,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;AAC1C,QAAQ,CAAC,IAAI,GAAG;IACf,OAAO,EAAE,KAAK;CACd,CAAC","sourcesContent":["import React from \"react\";\nimport { TimeSelect, TimeSelectProps } from \"../TimeSelect\";\nimport { Story } from \"@storybook/react/types-6-0\";\nimport \"../../../assets/css/finsemble.css\";\n\nexport default {\n\ttitle: \"Common/TimeSelect\",\n\tcomponent: TimeSelect,\n};\n\nconst Template: Story<TimeSelectProps> = (args: TimeSelectProps) => <TimeSelect {...args} />;\n\nexport const Default = Template.bind({});\nDefault.args = {\n\tinitialTime: {\n\t\thour: 22,\n\t\tminute: 15,\n\t},\n};\n\nexport const Disabled = Template.bind({});\nDisabled.args = {\n\tenabled: false,\n};\n"]}
@@ -3,7 +3,7 @@ import { mount } from "enzyme";
3
3
  import { describe, it, afterEach } from "mocha";
4
4
  import { expect } from "chai";
5
5
  import { BasicAccordion, BasicAccordionOpen, BasicAccordionWithSummary, NestedAccordion, } from "../stories/Accordion.stories";
6
- import { accessibilityAssessor } from "../../smartDesktopDesigner/tests/a11y_helper";
6
+ import { accessibilityAssessor } from "../../sdd/tests/a11y_helper";
7
7
  import sinon from "sinon";
8
8
  import addons, { mockChannel } from "@storybook/addons";
9
9
  addons.setChannel(mockChannel());
@@ -1 +1 @@
1
- {"version":3,"file":"Accordion.spec.js","sourceRoot":"","sources":["../../../../src/components/common/tests/Accordion.spec.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,KAAK,EAAE,MAAM,QAAQ,CAAC;AAC/B,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAChD,OAAO,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAE9B,OAAO,EACN,cAAc,EACd,kBAAkB,EAClB,yBAAyB,EACzB,eAAe,GACf,MAAM,8BAA8B,CAAC;AAGtC,OAAO,EAAE,qBAAqB,EAAE,MAAM,8CAA8C,CAAC;AAGrF,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,MAAM,EAAE,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AACxD,MAAM,CAAC,UAAU,CAAC,WAAW,EAAE,CAAC,CAAC;AAEjC,QAAQ,CAAC,cAAc,EAAE,GAAG,EAAE;IAE7B,SAAS,CAAC,GAAG,EAAE;QACd,KAAK,CAAC,OAAO,EAAE,CAAC;IACjB,CAAC,CAAC,CAAC;IAGH,EAAE,CAAC,0BAA0B,EAAE,GAAG,EAAE;QACnC,MAAM,OAAO,GAAG,KAAK,CAAC,oBAAC,cAAc,oBAAM,cAAc,CAAC,IAAuB,EAAI,CAAC,CAAC;QAEvF,M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CAAC;QACpD,MAAM,CAAC,QAAQ,CAAC,KAAK,EAAE,CAAC,OAAO,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;IACjD,CAAC,CAAC,CAAC;IAGH,EAAE,CAAC,iCAAiC,EAAE,KAAK,IAAI,EAAE;QAChD,MAAM,OAAO,GAAG,KAAK,CAAC,oBAAC,eAAe,oBAAM,eAAe,CAAC,IAAuB,EAAI,CAAC,CAAC;QAEzF,MAAM,CAAC,MAAM,qBAAqB,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,IAAI,CAAC;IACzD,CAAC,CAAC,CAAC;AACJ,CAAC,CAAC,CAAC","sourcesContent":["import * as React from \"react\";\nimport { mount } from \"enzyme\";\nimport { describe, it, afterEach } from \"mocha\";\nimport { expect } from \"chai\";\nimport { AccordionProps } from \"../Accordion\";\nimport {\n\tBasicAccordion,\n\tBasicAccordionOpen,\n\tBasicAccordionWithSummary,\n\tNestedAccordion,\n} from \"../stories/Accordion.stories\";\n\n// For running accessibility scans\nimport { accessibilityAssessor } from \"../../smartDesktopDesigner/tests/a11y_helper\";\n\n// For testing user interactions (like click events):\nimport sinon from \"sinon\";\n// Necessary to allow sinon to work with mocked actions (which are shown in the Actions panel in Storybook)\nimport addons, { mockChannel } from \"@storybook/addons\";\naddons.setChannel(mockChannel());\n\ndescribe(\"<Accordion/>\", () => {\n\t// Used to clear after each interactive test using sinon\n\tafterEach(() => {\n\t\tsinon.restore();\n\t});\n\n\t// Example basic test\n\tit(\"should display the label\", () => {\n\t\tconst wrapper = mount(<BasicAccordion {...(BasicAccordion.args as AccordionProps)} />);\n\n\t\texpect(wrapper.find(\".accordion-summary\").exists(), \"The does not exist\").to.be.false;\n\t\texpect(wrapper.find(\"button\").exists(), \"The button exists\").to.be.true;\n\t\texpect(wrapper.find(\"button\").text(), \"The button's text\").to.equal(\"Accordion Label\");\n\t});\n\n\tit(\"should display the summary\", () => {\n\t\tconst wrapper = mount(<BasicAccordionWithSummary {...(BasicAccordionWithSummary.args as AccordionProps)} />);\n\n\t\texpect(wrapper.find(\".accordion-summary\").exists(), \"The summary exists\").to.be.true;\n\t\texpect(wrapper.find(\".accordion-summary\").text(), \"The Summary text\").to.equal(\n\t\t\t\"A summary of what the accordion contains\"\n\t\t);\n\t});\n\n\tit(\"should accept react as a summary\", () => {\n\t\tconst summary = (\n\t\t\t<div>\n\t\t\t\tI am a summary <a>Link</a>\n\t\t\t</div>\n\t\t);\n\t\tconst props = { ...(BasicAccordionOpen.args as AccordionProps), summary };\n\t\tconst wrapper = mount(<BasicAccordionOpen {...props} />);\n\n\t\texpect(wrapper.find(\".accordion-summary\").exists(), \"The summary exists\").to.be.true;\n\t\texpect(wrapper.find(\"a\").exists(), \"link exists in the summary\").to.be.true;\n\t\texpect(wrapper.find(\".accordion-summary\").text(), \"The Summary text\").to.equal(\"I am a summary Link\");\n\t});\n\n\tit(\"should change state when clicked\", () => {\n\t\tconst wrapper = mount(<BasicAccordion {...(BasicAccordion.args as AccordionProps)} />);\n\n\t\tlet checkbox = wrapper.find({ type: \"checkbox\" });\n\t\texpect(checkbox.props().checked).to.equal(false);\n\t\twrapper.find(\"button\").simulate(\"click\");\n\t\tcheckbox = wrapper.find({ type: \"checkbox\" });\n\t\texpect(checkbox.props().checked).to.equal(true);\n\t});\n\n\tit(\"should start open\", () => {\n\t\tconst wrapper = mount(<BasicAccordionOpen {...(BasicAccordionOpen.args as AccordionProps)} />);\n\n\t\tconst checkbox = wrapper.find({ type: \"checkbox\" });\n\t\texpect(checkbox.props().checked).to.equal(true);\n\t});\n\n\t// Example accessibility scan\n\tit(\"should pass accessibility scans\", async () => {\n\t\tconst wrapper = mount(<NestedAccordion {...(NestedAccordion.args as AccordionProps)} />);\n\n\t\texpect(await accessibilityAssessor(wrapper)).to.be.true;\n\t});\n});\n"]}
1
+ {"version":3,"file":"Accordion.spec.js","sourceRoot":"","sources":["../../../../src/components/common/tests/Accordion.spec.tsx"],"names":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AAC","sourcesContent":["import * as React from \"react\";\nimport { mount } from \"enzyme\";\nimport { describe, it, afterEach } from \"mocha\";\nimport { expect } from \"chai\";\nimport { AccordionProps } from \"../Accordion\";\nimport {\n\tBasicAccordion,\n\tBasicAccordionOpen,\n\tBasicAccordionWithSummary,\n\tNestedAccordion,\n} from \"../stories/Accordion.stories\";\n\n// For running accessibility scans\nimport { accessibilityAssessor } from \"../../sdd/tests/a11y_helper\";\n\n// For testing user interactions (like click events):\nimport sinon from \"sinon\";\n// Necessary to allow sinon to work with mocked actions (which are shown in the Actions panel in Storybook)\nimport addons, { mockChannel } from \"@storybook/addons\";\naddons.setChannel(mockChannel());\n\ndescribe(\"<Accordion/>\", () => {\n\t// Used to clear after each interactive test using sinon\n\tafterEach(() => {\n\t\tsinon.restore();\n\t});\n\n\t// Example basic test\n\tit(\"should display the label\", () => {\n\t\tconst wrapper = mount(<BasicAccordion {...(BasicAccordion.args as AccordionProps)} />);\n\n\t\texpect(wrapper.find(\".accordion-summary\").exists(), \"The does not exist\").to.be.false;\n\t\texpect(wrapper.find(\"button\").exists(), \"The button exists\").to.be.true;\n\t\texpect(wrapper.find(\"button\").text(), \"The button's text\").to.equal(\"Accordion Label\");\n\t});\n\n\tit(\"should display the summary\", () => {\n\t\tconst wrapper = mount(<BasicAccordionWithSummary {...(BasicAccordionWithSummary.args as AccordionProps)} />);\n\n\t\texpect(wrapper.find(\".accordion-summary\").exists(), \"The summary exists\").to.be.true;\n\t\texpect(wrapper.find(\".accordion-summary\").text(), \"The Summary text\").to.equal(\n\t\t\t\"A summary of what the accordion contains\"\n\t\t);\n\t});\n\n\tit(\"should accept react as a summary\", () => {\n\t\tconst summary = (\n\t\t\t<div>\n\t\t\t\tI am a summary <a>Link</a>\n\t\t\t</div>\n\t\t);\n\t\tconst props = { ...(BasicAccordionOpen.args as AccordionProps), summary };\n\t\tconst wrapper = mount(<BasicAccordionOpen {...props} />);\n\n\t\texpect(wrapper.find(\".accordion-summary\").exists(), \"The summary exists\").to.be.true;\n\t\texpect(wrapper.find(\"a\").exists(), \"link exists in the summary\").to.be.true;\n\t\texpect(wrapper.find(\".accordion-summary\").text(), \"The Summary text\").to.equal(\"I am a summary Link\");\n\t});\n\n\tit(\"should change state when clicked\", () => {\n\t\tconst wrapper = mount(<BasicAccordion {...(BasicAccordion.args as AccordionProps)} />);\n\n\t\tlet checkbox = wrapper.find({ type: \"checkbox\" });\n\t\texpect(checkbox.props().checked).to.equal(false);\n\t\twrapper.find(\"button\").simulate(\"click\");\n\t\tcheckbox = wrapper.find({ type: \"checkbox\" });\n\t\texpect(checkbox.props().checked).to.equal(true);\n\t});\n\n\tit(\"should start open\", () => {\n\t\tconst wrapper = mount(<BasicAccordionOpen {...(BasicAccordionOpen.args as AccordionProps)} />);\n\n\t\tconst checkbox = wrapper.find({ type: \"checkbox\" });\n\t\texpect(checkbox.props().checked).to.equal(true);\n\t});\n\n\t// Example accessibility scan\n\tit(\"should pass accessibility scans\", async () => {\n\t\tconst wrapper = mount(<NestedAccordion {...(NestedAccordion.args as AccordionProps)} />);\n\n\t\texpect(await accessibilityAssessor(wrapper)).to.be.true;\n\t});\n});\n"]}
@@ -2,10 +2,11 @@ import * as React from "react";
2
2
  import { mount } from "enzyme";
3
3
  import { describe, it } from "mocha";
4
4
  import { expect } from "chai";
5
- import { EmptyField, PreFilledField, PreFilledInvalidField } from "../stories/FileInput.stories";
5
+ import { EmptyField, PreFilledField, PreFilledInvalidField, PreFilledFieldNoClearing, } from "../stories/FileInput.stories";
6
6
  import sinon from "sinon";
7
7
  const locators = {
8
8
  displayPath: ".file-input-value-input",
9
+ clearButton: ".finsemble-icon-times",
9
10
  };
10
11
  describe("<FileInput/>", () => {
11
12
  afterEach(() => {
@@ -18,6 +19,7 @@ describe("<FileInput/>", () => {
18
19
  it("should display the chosen file name", () => {
19
20
  const wrapper = mount(React.createElement(PreFilledField, Object.assign({}, PreFilledField.args)));
20
21
  expect(wrapper.find(locators.displayPath).text()).to.equal("ThisIsATest.png");
22
+ expect(wrapper.find(locators.clearButton).exists(), "Clear button displayed").to.be.true;
21
23
  });
22
24
  it("should display an error for invalid file types", () => {
23
25
  const wrapper = mount(React.createElement(PreFilledInvalidField, Object.assign({}, PreFilledInvalidField.args)));
@@ -39,5 +41,10 @@ describe("<FileInput/>", () => {
39
41
  expect(spy.args[0], "onSetValue returned with a value of an empty string").to.deep.equal([""]);
40
42
  expect(wrapper.find(".file-input-value-input").text(), "The filename field was emptied").to.be.empty;
41
43
  });
44
+ it("should not display the clear button when allowClearing=false", () => {
45
+ const wrapper = mount(React.createElement(PreFilledFieldNoClearing, Object.assign({}, PreFilledFieldNoClearing.args)));
46
+ expect(wrapper.find(locators.displayPath).text()).to.equal("ThisIsATest.png");
47
+ expect(wrapper.find(locators.clearButton).exists()).to.be.false;
48
+ });
42
49
  });
43
50
  //# sourceMappingURL=FileInput.spec.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"FileInput.spec.js","sourceRoot":"","sources":["../../../../src/components/common/tests/FileInput.spec.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,KAAK,EAAE,MAAM,QAAQ,CAAC;AAC/B,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AACrC,OAAO,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAE9B,OAAO,EAAE,UAAU,EAAE,cAAc,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AAGjG,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,MAAM,QAAQ,GAAG;IAChB,WAAW,EAAE,yBAAyB;CACtC,CAAC;AAEF,QAAQ,CAAC,cAAc,EAAE,GAAG,EAAE;IAE7B,SAAS,CAAC,GAAG,EAAE;QACd,KAAK,CAAC,OAAO,EAAE,CAAC;IACjB,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,qDAAqD,EAAE,GAAG,EAAE;QAC9D,MAAM,OAAO,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AAG,KAAK,CAAC,oBAAC,UAAU,oBAAM,UAAU,CAAC,IAAuB,EAAI,CAAC,CAAC;QAC/E,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC,EAAE,CAAC,UAAU,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,KAAK,CAAC;IACvE,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,6CAA6C,EAAE,GAAG,EAAE;QACtD,MAAM,GAAG,GAAG,KAAK,CAAC,GAAG,EAAE,CAAC;QACxB,MAAM,OAAO,GAAG,KAAK,CAAC,oBAAC,cAAc,kBAAC,UAAU,EAAE,GAAG,IAAO,cAAc,CAAC,IAAuB,EAAI,CAAC,CAAC;QACxG,OAAO,CAAC,IAAI,CAAC,+BAA+B,CAAC,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;QAEhE,MAAM,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,IAAI,CAAC;QAClC,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,qDAAqD,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;QAC/F,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,yBAAyB,CAAC,CAAC,IAAI,EAAE,EAAE,gCAAgC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,KAAK,CAAC;IACtG,CAAC,CAAC,CAAC;AAyBJ,CAAC,CAAC,CAAC","sourcesContent":["import * as React from \"react\";\nimport { mount } from \"enzyme\";\nimport { describe, it } from \"mocha\";\nimport { expect } from \"chai\";\nimport { FileInputProps } from \"../FileInput\";\nimport { EmptyField, PreFilledField, PreFilledInvalidField } from \"../stories/FileInput.stories\";\n\n// For testing user interactions (like click events):\nimport sinon from \"sinon\";\n\nconst locators = {\n\tdisplayPath: \".file-input-value-input\",\n};\n\ndescribe(\"<FileInput/>\", () => {\n\t// Used to clear after each interactive test using sinon\n\tafterEach(() => {\n\t\tsinon.restore();\n\t});\n\n\tit(\"should display an empty string in its default state\", () => {\n\t\tconst wrapper = mount(<EmptyField {...(EmptyField.args as FileInputProps)} />);\n\t\texpect(wrapper.find(locators.displayPath).text()).to.equal(\"\");\n\t});\n\n\tit(\"should display the chosen file name\", () => {\n\t\tconst wrapper = mount(<PreFilledField {...(PreFilledField.args as FileInputProps)} />);\n\t\texpect(wrapper.find(locators.displayPath).text()).to.equal(\"ThisIsATest.png\");\n\t});\n\n\tit(\"should display an error for invalid file types\", () => {\n\t\tconst wrapper = mount(<PreFilledInvalidField {...(PreFilledInvalidField.args as FileInputProps)} />);\n\t\texpect(wrapper.find(locators.displayPath).is(\".invalid\")).to.be.true;\n\t});\n\n\tit(\"should display no error for valid file types\", () => {\n\t\tconst wrapper = mount(<PreFilledField {...(PreFilledField.args as FileInputProps)} />);\n\t\texpect(wrapper.find(locators.displayPath).is(\".invalid\")).to.be.false;\n\t});\n\n\tit(\"should display no error when no file is chosen\", () => {\n\t\tconst wrapper = mount(<EmptyField {...(EmptyField.args as FileInputProps)} />);\n\t\texpect(wrapper.find(locators.displayPath).is(\".invalid\")).to.be.false;\n\t});\n\n\tit(\"should call onSetValue when file is cleared\", () => {\n\t\tconst spy = sinon.spy();\n\t\tconst wrapper = mount(<PreFilledField onSetValue={spy} {...(PreFilledField.args as FileInputProps)} />);\n\t\twrapper.find(\".button-container-icon button\").simulate(\"click\");\n\n\t\texpect(spy.calledOnce).to.be.true;\n\t\texpect(spy.args[0], \"onSetValue returned with a value of an empty string\").to.deep.equal([\"\"]);\n\t\texpect(wrapper.find(\".file-input-value-input\").text(), \"The filename field was emptied\").to.be.empty;\n\t});\n\n\t// it(\"should update the display when the file is changed\", () => {\n\t// \tconst oldFileName = \"old.txt\";\n\t// \tconst newFileName = \"newimage/png\";\n\n\t// \tconst uploadFunction = (fileObject: File) =>\n\t// \t\tnew Promise((resolve) => {\n\t// \t\t\tresolve({\n\t// \t\t\t\terr: \"\",\n\t// \t\t\t\tpath: fileObject.name,\n\t// \t\t\t});\n\t// \t\t});\n\n\t// \tconst wrapper = mount(<FileInput uploadFunction value={oldFileName} acceptTypes={[\"image/png\", \"image/jpg\", \"image/ico\"]} />);\n\t// \twrapper.find(\"input[type='file']\").simulate('change', {\n\t// \t\ttarget: {\n\t// \t\t\tfiles: [\n\t// \t\t\t\tnewFileName\n\t// \t\t\t]\n\t// \t\t}\n\t// \t});\n\n\t// \texpect(wrapper.find(\"input[type='text']\").prop(\"value\")).to.equal(newFileName);\n\t// });\n});\n"]}
1
+ {"version":3,"file":"FileInput.spec.js","sourceRoot":"","sources":["../../../../src/components/common/tests/FileInput.spec.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,KAAK,EAAE,MAAM,QAAQ,CAAC;AAC/B,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,OAAO,CAAC;AACrC,OAAO,EAAE,MAAM,EAAE,MAAM,MAAM,CAAC;AAE9B,OAAO,EACN,UAAU,EACV,cAAc,EACd,qBAAqB,EACrB,wBAAwB,GACxB,MAAM,8BAA8B,CAAC;AAGtC,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,MAAM,QAAQ,GAAG;IAChB,WAAW,EAAE,yBAAyB;IACtC,WAAW,EAAE,uBAAuB;CACpC,CAAC;AAEF,QAAQ,CAAC,cAAc,EAAE,GAAG,EAAE;IAE7B,SAAS,CAAC,GAAG,EAAE;QACd,KAAK,CAAC,OAAO,EAAE,CAAC;IACjB,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,qDAAqD,EAAE,GAAG,EAAE;QAC9D,MAAM,OAAO,GAAG,KAAK,CAAC,oBAAC,UAAU,oBAAM,UAAU,CAAC,IAAuB,EAAI,CAAC,CAAC;QAC/E,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,CAA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,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,KAAK,CAAC;IACjE,CAAC,CAAC,CAAC;AAyBJ,CAAC,CAAC,CAAC","sourcesContent":["import * as React from \"react\";\nimport { mount } from \"enzyme\";\nimport { describe, it } from \"mocha\";\nimport { expect } from \"chai\";\nimport { FileInputProps } from \"../FileInput\";\nimport {\n\tEmptyField,\n\tPreFilledField,\n\tPreFilledInvalidField,\n\tPreFilledFieldNoClearing,\n} from \"../stories/FileInput.stories\";\n\n// For testing user interactions (like click events):\nimport sinon from \"sinon\";\n\nconst locators = {\n\tdisplayPath: \".file-input-value-input\",\n\tclearButton: \".finsemble-icon-times\",\n};\n\ndescribe(\"<FileInput/>\", () => {\n\t// Used to clear after each interactive test using sinon\n\tafterEach(() => {\n\t\tsinon.restore();\n\t});\n\n\tit(\"should display an empty string in its default state\", () => {\n\t\tconst wrapper = mount(<EmptyField {...(EmptyField.args as FileInputProps)} />);\n\t\texpect(wrapper.find(locators.displayPath).text()).to.equal(\"\");\n\t});\n\n\tit(\"should display the chosen file name\", () => {\n\t\tconst wrapper = mount(<PreFilledField {...(PreFilledField.args as FileInputProps)} />);\n\t\texpect(wrapper.find(locators.displayPath).text()).to.equal(\"ThisIsATest.png\");\n\t\texpect(wrapper.find(locators.clearButton).exists(), \"Clear button displayed\").to.be.true;\n\t});\n\n\tit(\"should display an error for invalid file types\", () => {\n\t\tconst wrapper = mount(<PreFilledInvalidField {...(PreFilledInvalidField.args as FileInputProps)} />);\n\t\texpect(wrapper.find(locators.displayPath).is(\".invalid\")).to.be.true;\n\t});\n\n\tit(\"should display no error for valid file types\", () => {\n\t\tconst wrapper = mount(<PreFilledField {...(PreFilledField.args as FileInputProps)} />);\n\t\texpect(wrapper.find(locators.displayPath).is(\".invalid\")).to.be.false;\n\t});\n\n\tit(\"should display no error when no file is chosen\", () => {\n\t\tconst wrapper = mount(<EmptyField {...(EmptyField.args as FileInputProps)} />);\n\t\texpect(wrapper.find(locators.displayPath).is(\".invalid\")).to.be.false;\n\t});\n\n\tit(\"should call onSetValue when file is cleared\", () => {\n\t\tconst spy = sinon.spy();\n\t\tconst wrapper = mount(<PreFilledField onSetValue={spy} {...(PreFilledField.args as FileInputProps)} />);\n\t\twrapper.find(\".button-container-icon button\").simulate(\"click\");\n\n\t\texpect(spy.calledOnce).to.be.true;\n\t\texpect(spy.args[0], \"onSetValue returned with a value of an empty string\").to.deep.equal([\"\"]);\n\t\texpect(wrapper.find(\".file-input-value-input\").text(), \"The filename field was emptied\").to.be.empty;\n\t});\n\n\tit(\"should not display the clear button when allowClearing=false\", () => {\n\t\tconst wrapper = mount(<PreFilledFieldNoClearing {...(PreFilledFieldNoClearing.args as FileInputProps)} />);\n\t\texpect(wrapper.find(locators.displayPath).text()).to.equal(\"ThisIsATest.png\");\n\t\texpect(wrapper.find(locators.clearButton).exists()).to.be.false;\n\t});\n\n\t// it(\"should update the display when the file is changed\", () => {\n\t// \tconst oldFileName = \"old.txt\";\n\t// \tconst newFileName = \"newimage/png\";\n\n\t// \tconst uploadFunction = (fileObject: File) =>\n\t// \t\tnew Promise((resolve) => {\n\t// \t\t\tresolve({\n\t// \t\t\t\terr: \"\",\n\t// \t\t\t\tpath: fileObject.name,\n\t// \t\t\t});\n\t// \t\t});\n\n\t// \tconst wrapper = mount(<FileInput uploadFunction value={oldFileName} acceptTypes={[\"image/png\", \"image/jpg\", \"image/ico\"]} />);\n\t// \twrapper.find(\"input[type='file']\").simulate('change', {\n\t// \t\ttarget: {\n\t// \t\t\tfiles: [\n\t// \t\t\t\tnewFileName\n\t// \t\t\t]\n\t// \t\t}\n\t// \t});\n\n\t// \texpect(wrapper.find(\"input[type='text']\").prop(\"value\")).to.equal(newFileName);\n\t// });\n});\n"]}
@@ -5,7 +5,7 @@ import { expect } from "chai";
5
5
  import sinon from "sinon";
6
6
  import { Sample, SeperateValuesFromText, PreSelected, PreSelectedValues, InvalidPreSelected, Searchable, } from "../stories/FinsembleSelect.stories";
7
7
  import addons, { mockChannel } from "@storybook/addons";
8
- import { waitTime } from "../../smartDesktopDesigner/sdd_helpers";
8
+ import { waitTime } from "../../sdd/sdd_helpers";
9
9
  addons.setChannel(mockChannel());
10
10
  describe("<FinsembleSelect/>", () => {
11
11
  afterEach(() => {