@verdaccio/ui-components 4.0.0-next-8.12 → 4.0.0-next-8.13

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 (667) hide show
  1. package/README.md +23 -49
  2. package/build/AppTest/AppRoute.d.ts +1 -3
  3. package/build/AppTest/AppRoute.js +13 -40
  4. package/build/AppTest/AppRoute.js.map +1 -1
  5. package/build/Theme/ResetStyles.js +42 -32
  6. package/build/Theme/ResetStyles.js.map +1 -1
  7. package/build/Theme/StyleBaseline.js +15 -6
  8. package/build/Theme/StyleBaseline.js.map +1 -1
  9. package/build/Theme/ThemeProvider.js +38 -22
  10. package/build/Theme/ThemeProvider.js.map +1 -1
  11. package/build/Theme/colors.d.ts +11 -0
  12. package/build/Theme/colors.js +19 -1
  13. package/build/Theme/colors.js.map +1 -1
  14. package/build/Theme/index.d.ts +2 -1
  15. package/build/Theme/index.js +57 -5
  16. package/build/Theme/index.js.map +1 -1
  17. package/build/Theme/modes.d.ts +3 -0
  18. package/build/Theme/modes.js +40 -0
  19. package/build/Theme/modes.js.map +1 -0
  20. package/build/Theme/theme.d.ts +5 -149
  21. package/build/Theme/theme.js +16 -95
  22. package/build/Theme/theme.js.map +1 -1
  23. package/build/Theme/tokens.d.ts +57 -0
  24. package/build/Theme/tokens.js +35 -0
  25. package/build/Theme/tokens.js.map +1 -0
  26. package/build/api/use-data-mutation.d.ts +19 -0
  27. package/build/api/use-data-mutation.js +99 -0
  28. package/build/api/use-data-mutation.js.map +1 -0
  29. package/build/api/use-data.d.ts +3 -0
  30. package/build/api/use-data.js +36 -0
  31. package/build/api/use-data.js.map +1 -0
  32. package/build/components/ActionBar/ActionBar.js +49 -30
  33. package/build/components/ActionBar/ActionBar.js.map +1 -1
  34. package/build/components/ActionBar/ActionBarAction.js +72 -57
  35. package/build/components/ActionBar/ActionBarAction.js.map +1 -1
  36. package/build/components/ActionBar/index.js +13 -1
  37. package/build/components/ActionBar/index.js.map +1 -1
  38. package/build/components/AppRoute/AppRoute.d.ts +3 -0
  39. package/build/components/AppRoute/AppRoute.js +89 -0
  40. package/build/components/AppRoute/AppRoute.js.map +1 -0
  41. package/build/components/Author/Author.d.ts +1 -1
  42. package/build/components/Author/Author.js +25 -22
  43. package/build/components/Author/Author.js.map +1 -1
  44. package/build/components/Author/index.js +13 -1
  45. package/build/components/Author/index.js.map +1 -1
  46. package/build/components/Author/styles.js +18 -9
  47. package/build/components/Author/styles.js.map +1 -1
  48. package/build/components/CopyClipboard/CopyToClipBoard.js +31 -28
  49. package/build/components/CopyClipboard/CopyToClipBoard.js.map +1 -1
  50. package/build/components/CopyClipboard/index.js +20 -2
  51. package/build/components/CopyClipboard/index.js.map +1 -1
  52. package/build/components/CopyClipboard/utils.d.ts +1 -1
  53. package/build/components/CopyClipboard/utils.js +12 -4
  54. package/build/components/CopyClipboard/utils.js.map +1 -1
  55. package/build/components/Dependencies/Dependencies.js +52 -42
  56. package/build/components/Dependencies/Dependencies.js.map +1 -1
  57. package/build/components/Dependencies/DependencyBlock.d.ts +2 -2
  58. package/build/components/Dependencies/DependencyBlock.js +65 -49
  59. package/build/components/Dependencies/DependencyBlock.js.map +1 -1
  60. package/build/components/Dependencies/index.js +13 -1
  61. package/build/components/Dependencies/index.js.map +1 -1
  62. package/build/components/Dependencies/types.d.ts +1 -1
  63. package/build/components/Dependencies/types.js +5 -1
  64. package/build/components/Dependencies/types.js.map +1 -1
  65. package/build/components/Dependencies/utits.js +7 -1
  66. package/build/components/Dependencies/utits.js.map +1 -1
  67. package/build/components/Deprecated/Deprecated.js +13 -8
  68. package/build/components/Deprecated/Deprecated.js.map +1 -1
  69. package/build/components/Deprecated/index.js +13 -1
  70. package/build/components/Deprecated/index.js.map +1 -1
  71. package/build/components/Developers/DeveloperType.js +7 -1
  72. package/build/components/Developers/DeveloperType.js.map +1 -1
  73. package/build/components/Developers/Developers.d.ts +1 -1
  74. package/build/components/Developers/Developers.js +62 -39
  75. package/build/components/Developers/Developers.js.map +1 -1
  76. package/build/components/Developers/Title.js +25 -23
  77. package/build/components/Developers/Title.js.map +1 -1
  78. package/build/components/Developers/get-unique-developer-values.d.ts +1 -1
  79. package/build/components/Developers/get-unique-developer-values.js +18 -2
  80. package/build/components/Developers/get-unique-developer-values.js.map +1 -1
  81. package/build/components/Developers/index.js +20 -2
  82. package/build/components/Developers/index.js.map +1 -1
  83. package/build/components/Distribution/Dist.d.ts +2 -2
  84. package/build/components/Distribution/Dist.js +31 -30
  85. package/build/components/Distribution/Dist.js.map +1 -1
  86. package/build/components/Distribution/index.js +13 -1
  87. package/build/components/Distribution/index.js.map +1 -1
  88. package/build/components/Distribution/styles.js +22 -13
  89. package/build/components/Distribution/styles.js.map +1 -1
  90. package/build/components/Engines/Engines.d.ts +1 -1
  91. package/build/components/Engines/Engines.js +37 -36
  92. package/build/components/Engines/Engines.js.map +1 -1
  93. package/build/components/Engines/index.js +13 -1
  94. package/build/components/Engines/index.js.map +1 -1
  95. package/build/components/Engines/styles.js +19 -10
  96. package/build/components/Engines/styles.js.map +1 -1
  97. package/build/components/ErrorBoundary/ErrorBoundary.d.ts +11 -9
  98. package/build/components/ErrorBoundary/ErrorBoundary.js +63 -28
  99. package/build/components/ErrorBoundary/ErrorBoundary.js.map +1 -1
  100. package/build/components/ErrorBoundary/index.js +13 -1
  101. package/build/components/ErrorBoundary/index.js.map +1 -1
  102. package/build/components/Forbidden/Forbidden.d.ts +3 -2
  103. package/build/components/Forbidden/Forbidden.js +55 -52
  104. package/build/components/Forbidden/Forbidden.js.map +1 -1
  105. package/build/components/Forbidden/index.js +13 -1
  106. package/build/components/Forbidden/index.js.map +1 -1
  107. package/build/components/FundButton/FundButton.js +33 -34
  108. package/build/components/FundButton/FundButton.js.map +1 -1
  109. package/build/components/FundButton/index.js +13 -1
  110. package/build/components/FundButton/index.js.map +1 -1
  111. package/build/components/HeaderInfoDialog/HeaderInfoDialog.js +45 -32
  112. package/build/components/HeaderInfoDialog/HeaderInfoDialog.js.map +1 -1
  113. package/build/components/HeaderInfoDialog/index.js +13 -1
  114. package/build/components/HeaderInfoDialog/index.js.map +1 -1
  115. package/build/components/Heading/Heading.d.ts +5 -2
  116. package/build/components/Heading/Heading.js +17 -11
  117. package/build/components/Heading/Heading.js.map +1 -1
  118. package/build/components/Heading/index.js +13 -1
  119. package/build/components/Heading/index.js.map +1 -1
  120. package/build/components/Help/Help.js +32 -26
  121. package/build/components/Help/Help.js.map +1 -1
  122. package/build/components/Help/index.js +13 -1
  123. package/build/components/Help/index.js.map +1 -1
  124. package/build/components/Help/styles.js +10 -3
  125. package/build/components/Help/styles.js.map +1 -1
  126. package/build/components/Icons/DevsIcons/CommonJS.js +10 -3
  127. package/build/components/Icons/DevsIcons/CommonJS.js.map +1 -1
  128. package/build/components/Icons/DevsIcons/ES6Module.js +10 -3
  129. package/build/components/Icons/DevsIcons/ES6Module.js.map +1 -1
  130. package/build/components/Icons/DevsIcons/Git.js +10 -3
  131. package/build/components/Icons/DevsIcons/Git.js.map +1 -1
  132. package/build/components/Icons/DevsIcons/NodeJS.js +10 -3
  133. package/build/components/Icons/DevsIcons/NodeJS.js.map +1 -1
  134. package/build/components/Icons/DevsIcons/TypeScript.js +10 -3
  135. package/build/components/Icons/DevsIcons/TypeScript.js.map +1 -1
  136. package/build/components/Icons/DevsIcons/index.js +40 -5
  137. package/build/components/Icons/DevsIcons/index.js.map +1 -1
  138. package/build/components/Icons/Earth.d.ts +5 -5
  139. package/build/components/Icons/Earth.js +25 -14
  140. package/build/components/Icons/Earth.js.map +1 -1
  141. package/build/components/Icons/FileBinary.d.ts +5 -5
  142. package/build/components/Icons/FileBinary.js +23 -16
  143. package/build/components/Icons/FileBinary.js.map +1 -1
  144. package/build/components/Icons/Law.d.ts +5 -5
  145. package/build/components/Icons/Law.js +24 -17
  146. package/build/components/Icons/Law.js.map +1 -1
  147. package/build/components/Icons/License.d.ts +7 -5
  148. package/build/components/Icons/License.js +19 -8
  149. package/build/components/Icons/License.js.map +1 -1
  150. package/build/components/Icons/Managers/Npm.js +10 -3
  151. package/build/components/Icons/Managers/Npm.js.map +1 -1
  152. package/build/components/Icons/Managers/Pnpm.js +10 -3
  153. package/build/components/Icons/Managers/Pnpm.js.map +1 -1
  154. package/build/components/Icons/Managers/Yarn.js +10 -3
  155. package/build/components/Icons/Managers/Yarn.js.map +1 -1
  156. package/build/components/Icons/Managers/index.js +26 -3
  157. package/build/components/Icons/Managers/index.js.map +1 -1
  158. package/build/components/Icons/SvgIcon.d.ts +8 -2
  159. package/build/components/Icons/SvgIcon.js +26 -22
  160. package/build/components/Icons/SvgIcon.js.map +1 -1
  161. package/build/components/Icons/Time.d.ts +5 -5
  162. package/build/components/Icons/Time.js +20 -9
  163. package/build/components/Icons/Time.js.map +1 -1
  164. package/build/components/Icons/Version.d.ts +5 -5
  165. package/build/components/Icons/Version.js +18 -7
  166. package/build/components/Icons/Version.js.map +1 -1
  167. package/build/components/Icons/index.js +79 -8
  168. package/build/components/Icons/index.js.map +1 -1
  169. package/build/components/Install/Install.d.ts +2 -2
  170. package/build/components/Install/Install.js +41 -33
  171. package/build/components/Install/Install.js.map +1 -1
  172. package/build/components/Install/InstallListItem.js +48 -43
  173. package/build/components/Install/InstallListItem.js.map +1 -1
  174. package/build/components/Install/index.js +13 -1
  175. package/build/components/Install/index.js.map +1 -1
  176. package/build/components/Keywords/KeywordListItems.js +25 -17
  177. package/build/components/Keywords/KeywordListItems.js.map +1 -1
  178. package/build/components/Keywords/Keywords.d.ts +1 -1
  179. package/build/components/Keywords/Keywords.js +22 -18
  180. package/build/components/Keywords/Keywords.js.map +1 -1
  181. package/build/components/Keywords/index.js +13 -1
  182. package/build/components/Keywords/index.js.map +1 -1
  183. package/build/components/Label/Label.d.ts +1 -1
  184. package/build/components/Label/Label.js +25 -17
  185. package/build/components/Label/Label.js.map +1 -1
  186. package/build/components/Label/index.js +13 -1
  187. package/build/components/Label/index.js.map +1 -1
  188. package/build/components/Link/Link.d.ts +1 -1
  189. package/build/components/Link/Link.js +26 -19
  190. package/build/components/Link/Link.js.map +1 -1
  191. package/build/components/Link/index.js +13 -1
  192. package/build/components/Link/index.js.map +1 -1
  193. package/build/components/LinkExternal/LinkExternal.d.ts +1 -1
  194. package/build/components/LinkExternal/LinkExternal.js +28 -24
  195. package/build/components/LinkExternal/LinkExternal.js.map +1 -1
  196. package/build/components/LinkExternal/index.js +13 -1
  197. package/build/components/LinkExternal/index.js.map +1 -1
  198. package/build/components/Loading/Loading.js +21 -12
  199. package/build/components/Loading/Loading.js.map +1 -1
  200. package/build/components/Loading/Spinner/Spinner.js +31 -26
  201. package/build/components/Loading/Spinner/Spinner.js.map +1 -1
  202. package/build/components/Loading/Spinner/index.js +13 -1
  203. package/build/components/Loading/Spinner/index.js.map +1 -1
  204. package/build/components/Loading/index.js +13 -1
  205. package/build/components/Loading/index.js.map +1 -1
  206. package/build/components/Loading/styles.d.ts +1 -2
  207. package/build/components/Loading/styles.js +14 -9
  208. package/build/components/Loading/styles.js.map +1 -1
  209. package/build/components/LoginDialog/LoginDialog.js +29 -77
  210. package/build/components/LoginDialog/LoginDialog.js.map +1 -1
  211. package/build/components/LoginDialog/LoginDialogCloseButton.js +24 -22
  212. package/build/components/LoginDialog/LoginDialogCloseButton.js.map +1 -1
  213. package/build/components/LoginDialog/LoginDialogForm.d.ts +2 -11
  214. package/build/components/LoginDialog/LoginDialogForm.js +25 -111
  215. package/build/components/LoginDialog/LoginDialogForm.js.map +1 -1
  216. package/build/components/LoginDialog/LoginDialogFormError.d.ts +1 -6
  217. package/build/components/LoginDialog/LoginDialogFormError.js +31 -26
  218. package/build/components/LoginDialog/LoginDialogFormError.js.map +1 -1
  219. package/build/components/LoginDialog/index.js +13 -1
  220. package/build/components/LoginDialog/index.js.map +1 -1
  221. package/build/components/LoginForm/Login.d.ts +15 -0
  222. package/build/components/LoginForm/Login.js +87 -0
  223. package/build/components/LoginForm/Login.js.map +1 -0
  224. package/build/components/LoginForm/PasswordField.d.ts +9 -0
  225. package/build/components/LoginForm/PasswordField.js +51 -0
  226. package/build/components/LoginForm/PasswordField.js.map +1 -0
  227. package/build/components/LoginForm/UsernameField.d.ts +9 -0
  228. package/build/components/LoginForm/UsernameField.js +49 -0
  229. package/build/components/LoginForm/UsernameField.js.map +1 -0
  230. package/build/components/LoginForm/styles.d.ts +6 -0
  231. package/build/components/LoginForm/styles.js +60 -0
  232. package/build/components/LoginForm/styles.js.map +1 -0
  233. package/build/components/LoginForm/useLoginForm.d.ts +78 -0
  234. package/build/components/LoginForm/useLoginForm.js +66 -0
  235. package/build/components/LoginForm/useLoginForm.js.map +1 -0
  236. package/build/components/Logo/Logo.js +34 -29
  237. package/build/components/Logo/Logo.js.map +1 -1
  238. package/build/components/Logo/index.js +13 -1
  239. package/build/components/Logo/index.js.map +1 -1
  240. package/build/components/MenuItem/MenuItem.d.ts +4 -2
  241. package/build/components/MenuItem/MenuItem.js +24 -11
  242. package/build/components/MenuItem/MenuItem.js.map +1 -1
  243. package/build/components/MenuItem/index.js +13 -1
  244. package/build/components/MenuItem/index.js.map +1 -1
  245. package/build/components/NoItems/NoItems.js +15 -10
  246. package/build/components/NoItems/NoItems.js.map +1 -1
  247. package/build/components/NoItems/index.js +13 -1
  248. package/build/components/NoItems/index.js.map +1 -1
  249. package/build/components/NotFound/NotFound.js +37 -32
  250. package/build/components/NotFound/NotFound.js.map +1 -1
  251. package/build/components/NotFound/index.js +13 -1
  252. package/build/components/NotFound/index.js.map +1 -1
  253. package/build/components/Package/Package.d.ts +2 -1
  254. package/build/components/Package/Package.js +187 -155
  255. package/build/components/Package/Package.js.map +1 -1
  256. package/build/components/Package/index.js +13 -1
  257. package/build/components/Package/index.js.map +1 -1
  258. package/build/components/Package/styles.d.ts +2 -3
  259. package/build/components/Package/styles.js +73 -72
  260. package/build/components/Package/styles.js.map +1 -1
  261. package/build/components/PackageList/PackageList.d.ts +2 -1
  262. package/build/components/PackageList/PackageList.js +55 -59
  263. package/build/components/PackageList/PackageList.js.map +1 -1
  264. package/build/components/PackageList/index.js +13 -1
  265. package/build/components/PackageList/index.js.map +1 -1
  266. package/build/components/Person/Person.d.ts +1 -1
  267. package/build/components/Person/Person.js +28 -22
  268. package/build/components/Person/Person.js.map +1 -1
  269. package/build/components/Person/PersonTooltip.d.ts +1 -1
  270. package/build/components/Person/PersonTooltip.js +18 -13
  271. package/build/components/Person/PersonTooltip.js.map +1 -1
  272. package/build/components/Person/index.js +13 -1
  273. package/build/components/Person/index.js.map +1 -1
  274. package/build/components/Person/utils.d.ts +1 -1
  275. package/build/components/Person/utils.js +14 -6
  276. package/build/components/Person/utils.js.map +1 -1
  277. package/build/components/RawViewer/RawViewer.js +38 -34
  278. package/build/components/RawViewer/RawViewer.js.map +1 -1
  279. package/build/components/RawViewer/index.js +13 -1
  280. package/build/components/RawViewer/index.js.map +1 -1
  281. package/build/components/Readme/Readme.d.ts +1 -1
  282. package/build/components/Readme/Readme.js +26 -22
  283. package/build/components/Readme/Readme.js.map +1 -1
  284. package/build/components/Readme/index.js +13 -1
  285. package/build/components/Readme/index.js.map +1 -1
  286. package/build/components/Readme/types.js +5 -1
  287. package/build/components/Readme/utils.js +15 -8
  288. package/build/components/Readme/utils.js.map +1 -1
  289. package/build/components/RegistryInfoDialog/RegistryInfoDialog.d.ts +1 -1
  290. package/build/components/RegistryInfoDialog/RegistryInfoDialog.js +25 -19
  291. package/build/components/RegistryInfoDialog/RegistryInfoDialog.js.map +1 -1
  292. package/build/components/RegistryInfoDialog/index.js +13 -1
  293. package/build/components/RegistryInfoDialog/index.js.map +1 -1
  294. package/build/components/RegistryInfoDialog/styles.d.ts +1 -2
  295. package/build/components/RegistryInfoDialog/styles.js +26 -24
  296. package/build/components/RegistryInfoDialog/styles.js.map +1 -1
  297. package/build/components/RegistryInfoDialog/types.d.ts +1 -1
  298. package/build/components/RegistryInfoDialog/types.js +5 -1
  299. package/build/components/RegistryInfoDialog/types.js.map +1 -1
  300. package/build/components/Repository/Repository.js +47 -42
  301. package/build/components/Repository/Repository.js.map +1 -1
  302. package/build/components/Repository/index.js +13 -1
  303. package/build/components/Repository/index.js.map +1 -1
  304. package/build/components/Search/AutoComplete/AutoComplete.d.ts +5 -4
  305. package/build/components/Search/AutoComplete/AutoComplete.js +44 -26
  306. package/build/components/Search/AutoComplete/AutoComplete.js.map +1 -1
  307. package/build/components/Search/AutoComplete/index.js +13 -1
  308. package/build/components/Search/AutoComplete/index.js.map +1 -1
  309. package/build/components/Search/AutoComplete/styles.d.ts +0 -1
  310. package/build/components/Search/AutoComplete/styles.js +9 -2
  311. package/build/components/Search/AutoComplete/styles.js.map +1 -1
  312. package/build/components/Search/Search.d.ts +2 -5
  313. package/build/components/Search/Search.js +133 -123
  314. package/build/components/Search/Search.js.map +1 -1
  315. package/build/components/Search/SearchItem.d.ts +1 -1
  316. package/build/components/Search/SearchItem.js +92 -97
  317. package/build/components/Search/SearchItem.js.map +1 -1
  318. package/build/components/Search/index.js +13 -1
  319. package/build/components/Search/index.js.map +1 -1
  320. package/build/components/Search/styles.d.ts +5 -4
  321. package/build/components/Search/styles.js +46 -33
  322. package/build/components/Search/styles.js.map +1 -1
  323. package/build/components/Search/utils.js +7 -1
  324. package/build/components/Search/utils.js.map +1 -1
  325. package/build/components/SettingsMenu/SettingsMenu.js +60 -52
  326. package/build/components/SettingsMenu/SettingsMenu.js.map +1 -1
  327. package/build/components/SettingsMenu/index.js +13 -1
  328. package/build/components/SettingsMenu/index.js.map +1 -1
  329. package/build/components/SideBarTitle/SideBarTitle.js +52 -52
  330. package/build/components/SideBarTitle/SideBarTitle.js.map +1 -1
  331. package/build/components/SideBarTitle/index.js +13 -1
  332. package/build/components/SideBarTitle/index.js.map +1 -1
  333. package/build/components/SideBarTitle/utils.js +15 -6
  334. package/build/components/SideBarTitle/utils.js.map +1 -1
  335. package/build/components/UnAuthorized/UnAuthorized.d.ts +3 -0
  336. package/build/components/UnAuthorized/UnAuthorized.js +75 -0
  337. package/build/components/UnAuthorized/UnAuthorized.js.map +1 -0
  338. package/build/components/UnAuthorized/index.d.ts +1 -0
  339. package/build/components/UnAuthorized/index.js +14 -0
  340. package/build/components/UnAuthorized/index.js.map +1 -0
  341. package/build/components/UpLinks/UpLinks.js +46 -42
  342. package/build/components/UpLinks/UpLinks.js.map +1 -1
  343. package/build/components/UpLinks/UplinkLink.js +17 -12
  344. package/build/components/UpLinks/UplinkLink.js.map +1 -1
  345. package/build/components/UpLinks/index.js +13 -1
  346. package/build/components/UpLinks/index.js.map +1 -1
  347. package/build/components/UpLinks/styles.d.ts +1 -2
  348. package/build/components/UpLinks/styles.js +26 -20
  349. package/build/components/UpLinks/styles.js.map +1 -1
  350. package/build/components/Versions/HistoryList.d.ts +1 -1
  351. package/build/components/Versions/HistoryList.js +44 -37
  352. package/build/components/Versions/HistoryList.js.map +1 -1
  353. package/build/components/Versions/TagList.d.ts +1 -1
  354. package/build/components/Versions/TagList.js +33 -26
  355. package/build/components/Versions/TagList.js.map +1 -1
  356. package/build/components/Versions/Versions.js +67 -50
  357. package/build/components/Versions/Versions.js.map +1 -1
  358. package/build/components/Versions/index.js +13 -1
  359. package/build/components/Versions/index.js.map +1 -1
  360. package/build/components/Versions/styles.d.ts +1 -2
  361. package/build/components/Versions/styles.js +19 -15
  362. package/build/components/Versions/styles.js.map +1 -1
  363. package/build/components/Versions/types.d.ts +1 -1
  364. package/build/components/Versions/types.js +5 -1
  365. package/build/components/Versions/types.js.map +1 -1
  366. package/build/configuration.d.ts +2 -0
  367. package/build/configuration.js +23 -0
  368. package/build/configuration.js.map +1 -0
  369. package/build/hooks/index.js +20 -2
  370. package/build/hooks/index.js.map +1 -1
  371. package/build/hooks/useLocalStorage.js +31 -18
  372. package/build/hooks/useLocalStorage.js.map +1 -1
  373. package/build/hooks/useOnClickOutside.d.ts +1 -1
  374. package/build/hooks/useOnClickOutside.js +10 -5
  375. package/build/hooks/useOnClickOutside.js.map +1 -1
  376. package/build/index.d.ts +6 -14
  377. package/build/index.js +481 -66
  378. package/build/index.js.map +1 -1
  379. package/build/layouts/Security/Dialog.js +16 -11
  380. package/build/layouts/Security/Dialog.js.map +1 -1
  381. package/build/layouts/Version/Version.js +16 -9
  382. package/build/layouts/Version/Version.js.map +1 -1
  383. package/build/layouts/Version/index.js +13 -1
  384. package/build/layouts/Version/index.js.map +1 -1
  385. package/build/pages/Front/Home.d.ts +2 -0
  386. package/build/pages/Front/Home.js +9 -0
  387. package/build/pages/Front/Home.js.map +1 -0
  388. package/build/pages/Front/index.js +14 -0
  389. package/build/pages/Front/index.js.map +1 -0
  390. package/build/pages/Security/AddUser.d.ts +2 -0
  391. package/build/pages/Security/AddUser.js +9 -0
  392. package/build/pages/Security/AddUser.js.map +1 -0
  393. package/build/pages/Security/ChangePassword.d.ts +2 -0
  394. package/build/pages/Security/ChangePassword.js +9 -0
  395. package/build/pages/Security/ChangePassword.js.map +1 -0
  396. package/build/pages/Security/Login.d.ts +2 -0
  397. package/build/pages/Security/Login.js +9 -0
  398. package/build/pages/Security/Login.js.map +1 -0
  399. package/build/pages/Security/Success.d.ts +2 -0
  400. package/build/pages/Security/Success.js +9 -0
  401. package/build/pages/Security/Success.js.map +1 -0
  402. package/build/pages/Security/index.js +35 -0
  403. package/build/pages/Security/index.js.map +1 -0
  404. package/build/pages/Version/Version.js +32 -0
  405. package/build/pages/Version/Version.js.map +1 -0
  406. package/build/pages/Version/index.js +14 -0
  407. package/build/pages/Version/index.js.map +1 -0
  408. package/build/providers/AppConfigurationProvider/AppConfigurationProvider.d.ts +8 -6
  409. package/build/providers/AppConfigurationProvider/AppConfigurationProvider.js +67 -46
  410. package/build/providers/AppConfigurationProvider/AppConfigurationProvider.js.map +1 -1
  411. package/build/providers/AppConfigurationProvider/index.d.ts +1 -1
  412. package/build/providers/AppConfigurationProvider/index.js +18 -1
  413. package/build/providers/AppConfigurationProvider/index.js.map +1 -1
  414. package/build/providers/AuthProvider/AuthProvider.d.ts +18 -0
  415. package/build/providers/AuthProvider/AuthProvider.js +102 -0
  416. package/build/providers/AuthProvider/AuthProvider.js.map +1 -0
  417. package/build/providers/AuthProvider/index.d.ts +1 -0
  418. package/build/providers/AuthProvider/index.js +17 -0
  419. package/build/providers/AuthProvider/index.js.map +1 -0
  420. package/build/providers/AuthProvider/types.d.ts +15 -0
  421. package/build/providers/AuthProvider/types.js +6 -0
  422. package/build/providers/AuthProvider/types.js.map +1 -0
  423. package/build/providers/AuthProvider/utils.d.ts +3 -0
  424. package/build/providers/AuthProvider/utils.js +27 -0
  425. package/build/providers/AuthProvider/utils.js.map +1 -0
  426. package/build/providers/DownloadProvider/DownloadProvider.d.ts +13 -0
  427. package/build/providers/DownloadProvider/DownloadProvider.js +73 -0
  428. package/build/providers/DownloadProvider/DownloadProvider.js.map +1 -0
  429. package/build/providers/DownloadProvider/index.d.ts +1 -0
  430. package/build/providers/DownloadProvider/index.js +19 -0
  431. package/build/providers/DownloadProvider/index.js.map +1 -0
  432. package/build/providers/ManifestsProvider/ManifestsProvider.d.ts +26 -0
  433. package/build/providers/ManifestsProvider/ManifestsProvider.js +33 -0
  434. package/build/providers/ManifestsProvider/ManifestsProvider.js.map +1 -0
  435. package/build/providers/ManifestsProvider/README.md +22 -0
  436. package/build/providers/ManifestsProvider/index.d.ts +1 -0
  437. package/build/providers/ManifestsProvider/index.js +21 -0
  438. package/build/providers/ManifestsProvider/index.js.map +1 -0
  439. package/build/providers/PersistenceSettingProvider/PersistenceSettingProvider.d.ts +3 -2
  440. package/build/providers/PersistenceSettingProvider/PersistenceSettingProvider.js +39 -17
  441. package/build/providers/PersistenceSettingProvider/PersistenceSettingProvider.js.map +1 -1
  442. package/build/providers/PersistenceSettingProvider/index.d.ts +1 -1
  443. package/build/providers/PersistenceSettingProvider/index.js +18 -1
  444. package/build/providers/PersistenceSettingProvider/index.js.map +1 -1
  445. package/build/providers/SearchProvider/SearchProvider.d.ts +19 -0
  446. package/build/providers/SearchProvider/SearchProvider.js +97 -0
  447. package/build/providers/SearchProvider/SearchProvider.js.map +1 -0
  448. package/build/providers/SearchProvider/index.d.ts +1 -0
  449. package/build/providers/SearchProvider/index.js +25 -0
  450. package/build/providers/SearchProvider/index.js.map +1 -0
  451. package/build/providers/TranslatorProvider/TranslatorProvider.d.ts +3 -2
  452. package/build/providers/TranslatorProvider/TranslatorProvider.js +52 -25
  453. package/build/providers/TranslatorProvider/TranslatorProvider.js.map +1 -1
  454. package/build/providers/TranslatorProvider/index.js +20 -1
  455. package/build/providers/TranslatorProvider/index.js.map +1 -1
  456. package/build/providers/VersionProvider/VersionProvider.d.ts +13 -31
  457. package/build/providers/VersionProvider/VersionProvider.js +55 -69
  458. package/build/providers/VersionProvider/VersionProvider.js.map +1 -1
  459. package/build/providers/VersionProvider/index.js +20 -1
  460. package/build/providers/VersionProvider/index.js.map +1 -1
  461. package/build/providers/index.d.ts +5 -0
  462. package/build/providers/index.js +93 -3
  463. package/build/providers/index.js.map +1 -1
  464. package/build/routes/SecurityRoutes.d.ts +3 -0
  465. package/build/routes/SecurityRoutes.js +36 -0
  466. package/build/routes/SecurityRoutes.js.map +1 -0
  467. package/build/sections/Detail/ContainerContent.js +40 -22
  468. package/build/sections/Detail/ContainerContent.js.map +1 -1
  469. package/build/sections/Detail/Detail.js +42 -23
  470. package/build/sections/Detail/Detail.js.map +1 -1
  471. package/build/sections/Detail/ReadmeSection.js +13 -8
  472. package/build/sections/Detail/ReadmeSection.js.map +1 -1
  473. package/build/sections/Detail/Tabs.js +29 -23
  474. package/build/sections/Detail/Tabs.js.map +1 -1
  475. package/build/sections/Detail/index.js +13 -1
  476. package/build/sections/Detail/index.js.map +1 -1
  477. package/build/sections/Footer/Footer.js +62 -61
  478. package/build/sections/Footer/Footer.js.map +1 -1
  479. package/build/sections/Footer/index.js +13 -1
  480. package/build/sections/Footer/index.js.map +1 -1
  481. package/build/sections/Footer/styles.d.ts +1 -2
  482. package/build/sections/Footer/styles.js +47 -47
  483. package/build/sections/Footer/styles.js.map +1 -1
  484. package/build/sections/Header/Header.js +106 -65
  485. package/build/sections/Header/Header.js.map +1 -1
  486. package/build/sections/Header/HeaderGreetings.js +17 -13
  487. package/build/sections/Header/HeaderGreetings.js.map +1 -1
  488. package/build/sections/Header/HeaderLeft.js +19 -14
  489. package/build/sections/Header/HeaderLeft.js.map +1 -1
  490. package/build/sections/Header/HeaderMenu.d.ts +2 -1
  491. package/build/sections/Header/HeaderMenu.js +29 -24
  492. package/build/sections/Header/HeaderMenu.js.map +1 -1
  493. package/build/sections/Header/HeaderRight.js +61 -44
  494. package/build/sections/Header/HeaderRight.js.map +1 -1
  495. package/build/sections/Header/HeaderSettingsDialog.js +58 -53
  496. package/build/sections/Header/HeaderSettingsDialog.js.map +1 -1
  497. package/build/sections/Header/HeaderToolTip.d.ts +1 -1
  498. package/build/sections/Header/HeaderToolTip.js +14 -9
  499. package/build/sections/Header/HeaderToolTip.js.map +1 -1
  500. package/build/sections/Header/HeaderToolTipIcon.d.ts +4 -1
  501. package/build/sections/Header/HeaderToolTipIcon.js +30 -26
  502. package/build/sections/Header/HeaderToolTipIcon.js.map +1 -1
  503. package/build/sections/Header/LanguageSwitch.js +64 -56
  504. package/build/sections/Header/LanguageSwitch.js.map +1 -1
  505. package/build/sections/Header/RegistryInfoContent/RegistryInfoContent.d.ts +2 -1
  506. package/build/sections/Header/RegistryInfoContent/RegistryInfoContent.js +77 -74
  507. package/build/sections/Header/RegistryInfoContent/RegistryInfoContent.js.map +1 -1
  508. package/build/sections/Header/RegistryInfoContent/index.js +13 -1
  509. package/build/sections/Header/RegistryInfoContent/index.js.map +1 -1
  510. package/build/sections/Header/RegistryInfoContent/styles.d.ts +1 -2
  511. package/build/sections/Header/RegistryInfoContent/styles.js +20 -13
  512. package/build/sections/Header/RegistryInfoContent/styles.js.map +1 -1
  513. package/build/sections/Header/index.js +13 -1
  514. package/build/sections/Header/index.js.map +1 -1
  515. package/build/sections/Header/styles.d.ts +1 -2
  516. package/build/sections/Header/styles.js +60 -50
  517. package/build/sections/Header/styles.js.map +1 -1
  518. package/build/sections/Home/Home.js +19 -19
  519. package/build/sections/Home/Home.js.map +1 -1
  520. package/build/sections/Home/index.js +13 -1
  521. package/build/sections/Home/index.js.map +1 -1
  522. package/build/sections/Security/AddUser.js +146 -85
  523. package/build/sections/Security/AddUser.js.map +1 -1
  524. package/build/sections/Security/ChangePassword.js +150 -95
  525. package/build/sections/Security/ChangePassword.js.map +1 -1
  526. package/build/sections/Security/Login.js +126 -87
  527. package/build/sections/Security/Login.js.map +1 -1
  528. package/build/sections/Security/Success.js +25 -19
  529. package/build/sections/Security/Success.js.map +1 -1
  530. package/build/sections/Security/index.js +34 -4
  531. package/build/sections/Security/index.js.map +1 -1
  532. package/build/sections/Security/styles.js +15 -15
  533. package/build/sections/Security/styles.js.map +1 -1
  534. package/build/sections/Security/utils.js +16 -8
  535. package/build/sections/Security/utils.js.map +1 -1
  536. package/build/sections/SideBar/Sidebar.js +49 -40
  537. package/build/sections/SideBar/Sidebar.js.map +1 -1
  538. package/build/sections/SideBar/index.js +13 -1
  539. package/build/sections/SideBar/index.js.map +1 -1
  540. package/build/sections/index.js +20 -2
  541. package/build/sections/index.js.map +1 -1
  542. package/build/store/api.d.ts +1 -1
  543. package/build/store/api.js +89 -48
  544. package/build/store/api.js.map +1 -1
  545. package/build/store/index.d.ts +0 -6
  546. package/build/store/index.js +13 -2
  547. package/build/store/index.js.map +1 -1
  548. package/build/store/{models/routes.d.ts → routes.d.ts} +4 -0
  549. package/build/store/{models/routes.js → routes.js} +11 -1
  550. package/build/store/routes.js.map +1 -0
  551. package/build/store/storage.d.ts +6 -0
  552. package/build/store/storage.js +28 -4
  553. package/build/store/storage.js.map +1 -1
  554. package/build/store/utils.js +14 -0
  555. package/build/store/utils.js.map +1 -0
  556. package/build/test/i18n-config.js +12 -4
  557. package/build/test/i18n-config.js.map +1 -1
  558. package/build/test/test-react-testing-library.d.ts +19 -4
  559. package/build/test/test-react-testing-library.js +140 -28
  560. package/build/test/test-react-testing-library.js.map +1 -1
  561. package/build/types/external-modules.d.js +2 -0
  562. package/build/types/external-modules.d.js.map +1 -0
  563. package/build/types/index.d.ts +1 -1
  564. package/build/types/index.js +5 -1
  565. package/build/types/index.js.map +1 -1
  566. package/build/types/packageMeta.d.ts +1 -6
  567. package/build/types/packageMeta.js +5 -1
  568. package/build/types/packageMeta.js.map +1 -1
  569. package/build/utils/cli-utils.d.ts +1 -1
  570. package/build/utils/cli-utils.js +30 -18
  571. package/build/utils/cli-utils.js.map +1 -1
  572. package/build/utils/index.js +74 -8
  573. package/build/utils/index.js.map +1 -1
  574. package/build/utils/loadable.js +15 -7
  575. package/build/utils/loadable.js.map +1 -1
  576. package/build/utils/routes.d.ts +11 -3
  577. package/build/utils/routes.js +20 -4
  578. package/build/utils/routes.js.map +1 -1
  579. package/build/utils/schemas.d.ts +34 -0
  580. package/build/utils/schemas.js +30 -0
  581. package/build/utils/schemas.js.map +1 -0
  582. package/build/utils/token-generate.js +17 -6
  583. package/build/utils/token-generate.js.map +1 -1
  584. package/build/utils/token.js +23 -9
  585. package/build/utils/token.js.map +1 -1
  586. package/build/utils/url.js +20 -10
  587. package/build/utils/url.js.map +1 -1
  588. package/build/utils/utils.d.ts +2 -2
  589. package/build/utils/utils.js +48 -29
  590. package/build/utils/utils.js.map +1 -1
  591. package/package.json +28 -29
  592. package/build/AppTest/pages/Front/Home.d.ts +0 -2
  593. package/build/AppTest/pages/Front/Home.js +0 -3
  594. package/build/AppTest/pages/Front/Home.js.map +0 -1
  595. package/build/AppTest/pages/Front/index.js +0 -2
  596. package/build/AppTest/pages/Front/index.js.map +0 -1
  597. package/build/AppTest/pages/Security/AddUser.d.ts +0 -2
  598. package/build/AppTest/pages/Security/AddUser.js +0 -3
  599. package/build/AppTest/pages/Security/AddUser.js.map +0 -1
  600. package/build/AppTest/pages/Security/ChangePassword.d.ts +0 -2
  601. package/build/AppTest/pages/Security/ChangePassword.js +0 -3
  602. package/build/AppTest/pages/Security/ChangePassword.js.map +0 -1
  603. package/build/AppTest/pages/Security/Login.d.ts +0 -2
  604. package/build/AppTest/pages/Security/Login.js +0 -3
  605. package/build/AppTest/pages/Security/Login.js.map +0 -1
  606. package/build/AppTest/pages/Security/Success.d.ts +0 -2
  607. package/build/AppTest/pages/Security/Success.js +0 -3
  608. package/build/AppTest/pages/Security/Success.js.map +0 -1
  609. package/build/AppTest/pages/Security/index.js +0 -5
  610. package/build/AppTest/pages/Security/index.js.map +0 -1
  611. package/build/AppTest/pages/Version/Version.js +0 -27
  612. package/build/AppTest/pages/Version/Version.js.map +0 -1
  613. package/build/AppTest/pages/Version/index.js +0 -2
  614. package/build/AppTest/pages/Version/index.js.map +0 -1
  615. package/build/components/LoginDialog/LoginDialogHeader.d.ts +0 -6
  616. package/build/components/LoginDialog/LoginDialogHeader.js +0 -59
  617. package/build/components/LoginDialog/LoginDialogHeader.js.map +0 -1
  618. package/build/components/TextField/TextField.d.ts +0 -3
  619. package/build/components/TextField/TextField.js +0 -30
  620. package/build/components/TextField/TextField.js.map +0 -1
  621. package/build/components/TextField/index.d.ts +0 -1
  622. package/build/components/TextField/index.js +0 -2
  623. package/build/components/TextField/index.js.map +0 -1
  624. package/build/sections/Security/LoginError.d.ts +0 -7
  625. package/build/sections/Security/LoginError.js +0 -38
  626. package/build/sections/Security/LoginError.js.map +0 -1
  627. package/build/store/models/add-user.d.ts +0 -45
  628. package/build/store/models/add-user.js +0 -103
  629. package/build/store/models/add-user.js.map +0 -1
  630. package/build/store/models/change-password.d.ts +0 -44
  631. package/build/store/models/change-password.js +0 -118
  632. package/build/store/models/change-password.js.map +0 -1
  633. package/build/store/models/configuration.d.ts +0 -24
  634. package/build/store/models/configuration.js +0 -46
  635. package/build/store/models/configuration.js.map +0 -1
  636. package/build/store/models/download.d.ts +0 -16
  637. package/build/store/models/download.js +0 -38
  638. package/build/store/models/download.js.map +0 -1
  639. package/build/store/models/index.d.ts +0 -22
  640. package/build/store/models/index.js +0 -21
  641. package/build/store/models/index.js.map +0 -1
  642. package/build/store/models/login-v1.d.ts +0 -44
  643. package/build/store/models/login-v1.js +0 -111
  644. package/build/store/models/login-v1.js.map +0 -1
  645. package/build/store/models/login.d.ts +0 -69
  646. package/build/store/models/login.js +0 -102
  647. package/build/store/models/login.js.map +0 -1
  648. package/build/store/models/manifest.d.ts +0 -54
  649. package/build/store/models/manifest.js +0 -117
  650. package/build/store/models/manifest.js.map +0 -1
  651. package/build/store/models/packages.d.ts +0 -28
  652. package/build/store/models/packages.js +0 -47
  653. package/build/store/models/packages.js.map +0 -1
  654. package/build/store/models/routes.js.map +0 -1
  655. package/build/store/models/search.d.ts +0 -42
  656. package/build/store/models/search.js +0 -92
  657. package/build/store/models/search.js.map +0 -1
  658. package/build/store/models/utils.js +0 -7
  659. package/build/store/models/utils.js.map +0 -1
  660. package/build/store/store.d.ts +0 -9
  661. package/build/store/store.js +0 -8
  662. package/build/store/store.js.map +0 -1
  663. /package/build/{AppTest/pages → pages}/Front/index.d.ts +0 -0
  664. /package/build/{AppTest/pages → pages}/Security/index.d.ts +0 -0
  665. /package/build/{AppTest/pages → pages}/Version/Version.d.ts +0 -0
  666. /package/build/{AppTest/pages → pages}/Version/index.d.ts +0 -0
  667. /package/build/store/{models/utils.d.ts → utils.d.ts} +0 -0
@@ -0,0 +1 @@
1
+ {"version":3,"file":"modes.js","names":["_colors","require","_colors2","DARK_MODE_PRIMARY","common","white","getModePalette","exports","mode","primaryColor","basePrimary","baseColors","primary","main","secondary","background","paper"],"sources":["../../src/Theme/modes.ts"],"sourcesContent":["import { common } from '@mui/material/colors';\nimport type { PaletteOptions } from '@mui/material/styles';\n\nimport { baseColors } from './colors';\n\nexport type ThemeMode = 'light' | 'dark';\n\nconst DARK_MODE_PRIMARY = common.white;\n\nexport const getModePalette = (mode: ThemeMode, primaryColor?: string): PaletteOptions => {\n const basePrimary = primaryColor || baseColors.primary.main;\n const primary = mode === 'dark' ? { main: DARK_MODE_PRIMARY } : { main: basePrimary };\n\n if (mode === 'dark') {\n return {\n mode,\n primary,\n secondary: { main: '#424242' },\n background: {\n default: '#1a202c',\n paper: '#2d3748',\n },\n };\n }\n\n return {\n mode,\n primary,\n secondary: baseColors.secondary,\n background: {\n default: '#f4f4f4',\n paper: '#ffffff',\n },\n };\n};\n"],"mappings":";;;;;;AAAA,IAAAA,OAAA,GAAAC,OAAA;AAGA,IAAAC,QAAA,GAAAD,OAAA;AAIA,IAAME,iBAAiB,GAAGC,cAAM,CAACC,KAAK;AAE/B,IAAMC,cAAc,GAAAC,OAAA,CAAAD,cAAA,GAAG,SAAjBA,cAAcA,CAAIE,IAAe,EAAEC,YAAqB,EAAqB;EACxF,IAAMC,WAAW,GAAGD,YAAY,IAAIE,mBAAU,CAACC,OAAO,CAACC,IAAI;EAC3D,IAAMD,OAAO,GAAGJ,IAAI,KAAK,MAAM,GAAG;IAAEK,IAAI,EAAEV;EAAkB,CAAC,GAAG;IAAEU,IAAI,EAAEH;EAAY,CAAC;EAErF,IAAIF,IAAI,KAAK,MAAM,EAAE;IACnB,OAAO;MACLA,IAAI,EAAJA,IAAI;MACJI,OAAO,EAAPA,OAAO;MACPE,SAAS,EAAE;QAAED,IAAI,EAAE;MAAU,CAAC;MAC9BE,UAAU,EAAE;QACV,WAAS,SAAS;QAClBC,KAAK,EAAE;MACT;IACF,CAAC;EACH;EAEA,OAAO;IACLR,IAAI,EAAJA,IAAI;IACJI,OAAO,EAAPA,OAAO;IACPE,SAAS,EAAEH,mBAAU,CAACG,SAAS;IAC/BC,UAAU,EAAE;MACV,WAAS,SAAS;MAClBC,KAAK,EAAE;IACT;EACF,CAAC;AACH,CAAC","ignoreList":[]}
@@ -1,120 +1,7 @@
1
- import { Theme as MuiTheme } from '@mui/material/styles';
2
- declare const themeModes: {
3
- light: {
4
- black: "#000";
5
- white: "#fff";
6
- red: "#d32f2f";
7
- orange: "#cd4000";
8
- greySuperLight: "#f5f5f5";
9
- greyLight: "#d3d3d3";
10
- greyLight2: "#908ba1";
11
- greyLight3: "#f3f4f2";
12
- greyDark: "#a9a9a9";
13
- greyDark2: "#586069";
14
- greyChateau: "#95989a";
15
- greyGainsboro: "#e3e3e3";
16
- greyAthens: "#d3dddd";
17
- eclipse: "#3c3c3c";
18
- paleNavy: "#e4e8f1";
19
- saltpan: "#f7f8f6";
20
- snow: "#f9f9f9";
21
- love: "#e25555";
22
- nobel01: "#999999";
23
- nobel02: "#9f9f9f";
24
- primary: "#4b5e40";
25
- secondary: "#20232a";
26
- background: "#f4f4f4";
27
- dodgerBlue: "#1ba1f2";
28
- cyanBlue: "#253341";
29
- };
30
- dark: {
31
- primary: string;
32
- secondary: string;
33
- background: string;
34
- black: "#000";
35
- white: "#fff";
36
- red: "#d32f2f";
37
- orange: "#cd4000";
38
- greySuperLight: "#f5f5f5";
39
- greyLight: "#d3d3d3";
40
- greyLight2: "#908ba1";
41
- greyLight3: "#f3f4f2";
42
- greyDark: "#a9a9a9";
43
- greyDark2: "#586069";
44
- greyChateau: "#95989a";
45
- greyGainsboro: "#e3e3e3";
46
- greyAthens: "#d3dddd";
47
- eclipse: "#3c3c3c";
48
- paleNavy: "#e4e8f1";
49
- saltpan: "#f7f8f6";
50
- snow: "#f9f9f9";
51
- love: "#e25555";
52
- nobel01: "#999999";
53
- nobel02: "#9f9f9f";
54
- dodgerBlue: "#1ba1f2";
55
- cyanBlue: "#253341";
56
- };
57
- };
58
- export type ThemeMode = keyof typeof themeModes;
59
- declare const fontSize: {
60
- readonly xxl: 26;
61
- readonly xl: 24;
62
- readonly lg: 21;
63
- readonly md: 18;
64
- readonly default: 16;
65
- readonly sm: 14;
66
- readonly ssm: 12;
67
- };
68
- export type FontSize = keyof typeof fontSize;
69
- declare const fontWeight: {
70
- readonly light: 300;
71
- readonly regular: 400;
72
- readonly semiBold: 500;
73
- readonly bold: 700;
74
- };
75
- export type FontWeight = keyof typeof fontWeight;
76
- export declare const breakPoints: {
77
- readonly xsmall: 400;
78
- readonly small: 576;
79
- readonly medium: 768;
80
- readonly large: 1024;
81
- readonly container: 1240;
82
- readonly xlarge: 1275;
83
- };
84
- export type BreakPoints = typeof breakPoints;
85
- declare const customizedTheme: {
86
- fontSize: {
87
- readonly xxl: 26;
88
- readonly xl: 24;
89
- readonly lg: 21;
90
- readonly md: 18;
91
- readonly default: 16;
92
- readonly sm: 14;
93
- readonly ssm: 12;
94
- };
95
- fontWeight: {
96
- readonly light: 300;
97
- readonly regular: 400;
98
- readonly semiBold: 500;
99
- readonly bold: 700;
100
- };
101
- breakPoints: {
102
- readonly xsmall: 400;
103
- readonly small: 576;
104
- readonly medium: 768;
105
- readonly large: 1024;
106
- readonly container: 1240;
107
- readonly xlarge: 1275;
108
- };
109
- };
110
- type CustomizedTheme = typeof customizedTheme;
111
- export interface CustomTheme {
112
- fontSize: typeof fontSize;
113
- fontWeight: typeof fontWeight;
114
- breakPoints: typeof breakPoints;
115
- }
116
- export type Theme = MuiTheme & CustomTheme;
117
- export declare const getTheme: (themeMode: ThemeMode, primaryColor?: string) => Theme;
1
+ import type { Theme as MuiTheme } from '@mui/material/styles';
2
+ import type { ThemeMode } from './modes';
3
+ import type { CustomTheme, CustomizedTheme } from './tokens';
4
+ export type Theme = MuiTheme & CustomizedTheme;
118
5
  declare module '@mui/material/styles' {
119
6
  interface Theme extends CustomTheme {
120
7
  }
@@ -127,35 +14,4 @@ declare module '@mui/material/styles/createTheme' {
127
14
  interface DeprecatedThemeOptions extends CustomizedTheme {
128
15
  }
129
16
  }
130
- declare module '@mui/material/styles/createPalette' {
131
- interface CustomPalette {
132
- black: string;
133
- white: string;
134
- red: string;
135
- orange: string;
136
- greySuperLight: string;
137
- greyLight: string;
138
- greyLight2: string;
139
- greyLight3: string;
140
- greyDark: string;
141
- greyDark2: string;
142
- greyChateau: string;
143
- greyGainsboro: string;
144
- greyAthens: string;
145
- eclipse: string;
146
- paleNavy: string;
147
- saltpan: string;
148
- snow: string;
149
- love: string;
150
- nobel01: string;
151
- nobel02: string;
152
- background: string;
153
- dodgerBlue: string;
154
- cyanBlue: string;
155
- }
156
- interface Palette extends CustomPalette {
157
- }
158
- interface PaletteOptions extends Partial<CustomPalette> {
159
- }
160
- }
161
- export {};
17
+ export declare const getTheme: (mode: ThemeMode, primaryColor?: string) => Theme;
@@ -1,103 +1,24 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.getTheme = void 0;
7
+ var _styles = require("@mui/material/styles");
8
+ var _modes = require("./modes");
9
+ var _tokens = require("./tokens");
10
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
1
11
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
2
12
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
3
13
  function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
4
- function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
5
- function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
6
- import { createTheme } from '@mui/material/styles';
7
- import { PRIMARY_COLOR } from './colors';
8
- var colors = {
9
- black: '#000',
10
- white: '#fff',
11
- red: '#d32f2f',
12
- orange: '#cd4000',
13
- greySuperLight: '#f5f5f5',
14
- greyLight: '#d3d3d3',
15
- greyLight2: '#908ba1',
16
- greyLight3: '#f3f4f2',
17
- greyDark: '#a9a9a9',
18
- greyDark2: '#586069',
19
- greyChateau: '#95989a',
20
- greyGainsboro: '#e3e3e3',
21
- greyAthens: '#d3dddd',
22
- eclipse: '#3c3c3c',
23
- paleNavy: '#e4e8f1',
24
- saltpan: '#f7f8f6',
25
- snow: '#f9f9f9',
26
- love: '#e25555',
27
- nobel01: '#999999',
28
- nobel02: '#9f9f9f',
29
- primary: PRIMARY_COLOR,
30
- secondary: '#20232a',
31
- background: '#f4f4f4',
32
- dodgerBlue: '#1ba1f2',
33
- cyanBlue: '#253341'
34
- };
35
- var themeModes = {
36
- light: _objectSpread({}, colors),
37
- dark: _objectSpread(_objectSpread({}, colors), {}, {
38
- primary: '#ffffff',
39
- secondary: '#424242',
40
- background: '#1a202c'
41
- })
42
- };
43
- function applyPrimaryColor(mode, primaryColor) {
44
- if (mode === 'light') {
45
- themeModes['light'].primary = primaryColor || PRIMARY_COLOR;
46
- }
47
- return themeModes[mode];
48
- }
49
- var fontSize = {
50
- xxl: 26,
51
- xl: 24,
52
- lg: 21,
53
- md: 18,
54
- default: 16,
55
- sm: 14,
56
- ssm: 12
57
- };
58
- var fontWeight = {
59
- light: 300,
60
- regular: 400,
61
- semiBold: 500,
62
- bold: 700
63
- };
64
- export var breakPoints = {
65
- xsmall: 400,
66
- small: 576,
67
- medium: 768,
68
- large: 1024,
69
- container: 1240,
70
- xlarge: 1275
71
- };
72
- var customizedTheme = {
73
- fontSize,
74
- fontWeight,
75
- breakPoints
76
- };
77
- export var getTheme = (themeMode, primaryColor) => {
78
- var palette = applyPrimaryColor(themeMode, primaryColor);
79
- return createTheme(_objectSpread({
14
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
15
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
16
+ var getTheme = exports.getTheme = function getTheme(mode, primaryColor) {
17
+ return (0, _styles.createTheme)(_objectSpread({
18
+ palette: (0, _modes.getModePalette)(mode, primaryColor),
80
19
  typography: {
81
20
  fontFamily: ['-apple-system', 'BlinkMacSystemFont', '"Helvetica Neue"', 'Arial', 'sans-serif'].join(',')
82
21
  },
83
- palette: _objectSpread(_objectSpread({
84
- mode: themeMode
85
- }, palette), {}, {
86
- primary: {
87
- main: palette.primary
88
- },
89
- secondary: {
90
- main: palette.secondary
91
- },
92
- error: {
93
- main: palette.red
94
- },
95
- background: {
96
- default: palette.background
97
- }
98
- }),
99
- // Looks better in darkmode without background opacity
100
- // https://mui.com/material-ui/migration/v5-component-changes/#change-dark-mode-background-opacity
101
22
  components: {
102
23
  MuiPaper: {
103
24
  styleOverrides: {
@@ -107,6 +28,6 @@ export var getTheme = (themeMode, primaryColor) => {
107
28
  }
108
29
  }
109
30
  }
110
- }, customizedTheme));
31
+ }, _tokens.customizedTheme));
111
32
  };
112
33
  //# sourceMappingURL=theme.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"theme.js","names":["createTheme","PRIMARY_COLOR","colors","black","white","red","orange","greySuperLight","greyLight","greyLight2","greyLight3","greyDark","greyDark2","greyChateau","greyGainsboro","greyAthens","eclipse","paleNavy","saltpan","snow","love","nobel01","nobel02","primary","secondary","background","dodgerBlue","cyanBlue","themeModes","light","_objectSpread","dark","applyPrimaryColor","mode","primaryColor","fontSize","xxl","xl","lg","md","default","sm","ssm","fontWeight","regular","semiBold","bold","breakPoints","xsmall","small","medium","large","container","xlarge","customizedTheme","getTheme","themeMode","palette","typography","fontFamily","join","main","error","components","MuiPaper","styleOverrides","root","backgroundImage"],"sources":["../../src/Theme/theme.ts"],"sourcesContent":["import { Theme as MuiTheme, createTheme } from '@mui/material/styles';\n\nimport { PRIMARY_COLOR } from './colors';\n\nconst colors = {\n black: '#000',\n white: '#fff',\n red: '#d32f2f',\n orange: '#cd4000',\n greySuperLight: '#f5f5f5',\n greyLight: '#d3d3d3',\n greyLight2: '#908ba1',\n greyLight3: '#f3f4f2',\n greyDark: '#a9a9a9',\n greyDark2: '#586069',\n greyChateau: '#95989a',\n greyGainsboro: '#e3e3e3',\n greyAthens: '#d3dddd',\n eclipse: '#3c3c3c',\n paleNavy: '#e4e8f1',\n saltpan: '#f7f8f6',\n snow: '#f9f9f9',\n love: '#e25555',\n nobel01: '#999999',\n nobel02: '#9f9f9f',\n primary: PRIMARY_COLOR,\n secondary: '#20232a',\n background: '#f4f4f4',\n dodgerBlue: '#1ba1f2',\n cyanBlue: '#253341',\n} as const;\n\nconst themeModes = {\n light: {\n ...colors,\n },\n dark: {\n ...colors,\n primary: '#ffffff',\n secondary: '#424242',\n background: '#1a202c',\n },\n};\n\nexport type ThemeMode = keyof typeof themeModes;\ntype ThemeColors = (typeof themeModes)[ThemeMode];\n\nfunction applyPrimaryColor(mode: ThemeMode, primaryColor?: string): ThemeColors {\n if (mode === 'light') {\n (themeModes['light'] as any).primary = primaryColor || PRIMARY_COLOR;\n }\n\n return themeModes[mode];\n}\n\nconst fontSize = {\n xxl: 26,\n xl: 24,\n lg: 21,\n md: 18,\n default: 16,\n sm: 14,\n ssm: 12,\n} as const;\n\nexport type FontSize = keyof typeof fontSize;\n\nconst fontWeight = {\n light: 300,\n regular: 400,\n semiBold: 500,\n bold: 700,\n} as const;\n\nexport type FontWeight = keyof typeof fontWeight;\n\nexport const breakPoints = {\n xsmall: 400,\n small: 576,\n medium: 768,\n large: 1024,\n container: 1240,\n xlarge: 1275,\n} as const;\n\nexport type BreakPoints = typeof breakPoints;\n\nconst customizedTheme = {\n fontSize,\n fontWeight,\n breakPoints,\n};\n\ntype CustomizedTheme = typeof customizedTheme;\n\nexport interface CustomTheme {\n fontSize: typeof fontSize;\n fontWeight: typeof fontWeight;\n breakPoints: typeof breakPoints;\n}\n\nexport type Theme = MuiTheme & CustomTheme;\n\nexport const getTheme = (themeMode: ThemeMode, primaryColor?: string): Theme => {\n const palette = applyPrimaryColor(themeMode, primaryColor);\n return createTheme({\n typography: {\n fontFamily: [\n '-apple-system',\n 'BlinkMacSystemFont',\n '\"Helvetica Neue\"',\n 'Arial',\n 'sans-serif',\n ].join(','),\n },\n palette: {\n mode: themeMode,\n ...palette,\n primary: { main: palette.primary },\n secondary: { main: palette.secondary },\n error: { main: palette.red },\n background: {\n default: palette.background,\n },\n },\n // Looks better in darkmode without background opacity\n // https://mui.com/material-ui/migration/v5-component-changes/#change-dark-mode-background-opacity\n components: {\n MuiPaper: {\n styleOverrides: { root: { backgroundImage: 'unset' } },\n },\n },\n ...customizedTheme,\n }) as Theme;\n};\n\ndeclare module '@mui/material/styles' {\n interface Theme extends CustomTheme {}\n interface ThemeOptions extends CustomTheme {}\n}\n\ndeclare module '@mui/material/styles/createTheme' {\n /* eslint-disable-next-line @typescript-eslint/no-empty-interface */\n interface Theme extends CustomizedTheme {}\n /* eslint-disable-next-line @typescript-eslint/no-empty-interface */\n interface DeprecatedThemeOptions extends CustomizedTheme {}\n}\n\ndeclare module '@mui/material/styles/createPalette' {\n interface CustomPalette {\n black: string;\n white: string;\n red: string;\n orange: string;\n greySuperLight: string;\n greyLight: string;\n greyLight2: string;\n greyLight3: string;\n greyDark: string;\n greyDark2: string;\n greyChateau: string;\n greyGainsboro: string;\n greyAthens: string;\n eclipse: string;\n paleNavy: string;\n saltpan: string;\n snow: string;\n love: string;\n nobel01: string;\n nobel02: string;\n background: string;\n dodgerBlue: string;\n cyanBlue: string;\n }\n\n /* eslint-disable-next-line @typescript-eslint/no-empty-interface */\n interface Palette extends CustomPalette {}\n /* eslint-disable-next-line @typescript-eslint/no-empty-interface */\n interface PaletteOptions extends Partial<Custom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ACVC,QAAQ,EAAE;QACRC,cAAc,EAAE;UAAEC,IAAI,EAAE;YAAEC,eAAe,EAAE;UAAQ;QAAE;MACvD;IACF;EAAC,GACEb,eAAe,CACnB,CAAC;AACJ,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"theme.js","names":["_styles","require","_modes","_tokens","_typeof","o","Symbol","iterator","constructor","prototype","ownKeys","e","r","t","Object","keys","getOwnPropertySymbols","filter","getOwnPropertyDescriptor","enumerable","push","apply","_objectSpread","arguments","length","forEach","_defineProperty","getOwnPropertyDescriptors","defineProperties","defineProperty","_toPropertyKey","value","configurable","writable","i","_toPrimitive","toPrimitive","call","TypeError","String","Number","getTheme","exports","mode","primaryColor","createTheme","palette","getModePalette","typography","fontFamily","join","components","MuiPaper","styleOverrides","root","backgroundImage","customizedTheme"],"sources":["../../src/Theme/theme.ts"],"sourcesContent":["import type { Theme as MuiTheme } from '@mui/material/styles';\nimport { createTheme } from '@mui/material/styles';\n\nimport type { ThemeMode } from './modes';\nimport { getModePalette } from './modes';\nimport type { CustomTheme, CustomizedTheme } from './tokens';\nimport { customizedTheme } from './tokens';\n\nexport type Theme = MuiTheme & CustomizedTheme;\n\ndeclare module '@mui/material/styles' {\n interface Theme extends CustomTheme {}\n interface ThemeOptions extends CustomTheme {}\n}\ndeclare module '@mui/material/styles/createTheme' {\n interface Theme extends CustomizedTheme {}\n\n interface DeprecatedThemeOptions extends CustomizedTheme {}\n}\n\nexport const getTheme = (mode: ThemeMode, primaryColor?: string): Theme => {\n return createTheme({\n palette: getModePalette(mode, primaryColor),\n\n typography: {\n fontFamily: [\n '-apple-system',\n 'BlinkMacSystemFont',\n '\"Helvetica Neue\"',\n 'Arial',\n 'sans-serif',\n ].join(','),\n },\n\n components: {\n MuiPaper: {\n styleOverrides: {\n root: {\n backgroundImage: 'unset',\n },\n },\n },\n },\n\n ...customizedTheme,\n });\n};\n"],"mappings":";;;;;;AACA,IAAAA,OAAA,GAAAC,OAAA;AAGA,IAAAC,MAAA,G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AE;QACRC,cAAc,EAAE;UACdC,IAAI,EAAE;YACJC,eAAe,EAAE;UACnB;QACF;MACF;IACF;EAAC,GAEEC,uBAAe,CACnB,CAAC;AACJ,CAAC","ignoreList":[]}
@@ -0,0 +1,57 @@
1
+ export declare const fontSize: {
2
+ readonly xxl: 26;
3
+ readonly xl: 24;
4
+ readonly lg: 21;
5
+ readonly md: 18;
6
+ readonly default: 16;
7
+ readonly sm: 14;
8
+ readonly ssm: 12;
9
+ };
10
+ export type FontSize = keyof typeof fontSize;
11
+ export declare const fontWeight: {
12
+ readonly light: 300;
13
+ readonly regular: 400;
14
+ readonly semiBold: 500;
15
+ readonly bold: 700;
16
+ };
17
+ export type FontWeight = keyof typeof fontWeight;
18
+ export declare const breakPoints: {
19
+ readonly xsmall: 400;
20
+ readonly small: 576;
21
+ readonly medium: 768;
22
+ readonly large: 1024;
23
+ readonly container: 1240;
24
+ readonly xlarge: 1275;
25
+ };
26
+ export type BreakPoints = typeof breakPoints;
27
+ export interface CustomTheme {
28
+ fontSize: typeof fontSize;
29
+ fontWeight: typeof fontWeight;
30
+ breakPoints: typeof breakPoints;
31
+ }
32
+ export declare const customizedTheme: {
33
+ fontSize: {
34
+ readonly xxl: 26;
35
+ readonly xl: 24;
36
+ readonly lg: 21;
37
+ readonly md: 18;
38
+ readonly default: 16;
39
+ readonly sm: 14;
40
+ readonly ssm: 12;
41
+ };
42
+ fontWeight: {
43
+ readonly light: 300;
44
+ readonly regular: 400;
45
+ readonly semiBold: 500;
46
+ readonly bold: 700;
47
+ };
48
+ breakPoints: {
49
+ readonly xsmall: 400;
50
+ readonly small: 576;
51
+ readonly medium: 768;
52
+ readonly large: 1024;
53
+ readonly container: 1240;
54
+ readonly xlarge: 1275;
55
+ };
56
+ };
57
+ export type CustomizedTheme = typeof customizedTheme;
@@ -0,0 +1,35 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.fontWeight = exports.fontSize = exports.customizedTheme = exports.breakPoints = void 0;
7
+ var fontSize = exports.fontSize = {
8
+ xxl: 26,
9
+ xl: 24,
10
+ lg: 21,
11
+ md: 18,
12
+ "default": 16,
13
+ sm: 14,
14
+ ssm: 12
15
+ };
16
+ var fontWeight = exports.fontWeight = {
17
+ light: 300,
18
+ regular: 400,
19
+ semiBold: 500,
20
+ bold: 700
21
+ };
22
+ var breakPoints = exports.breakPoints = {
23
+ xsmall: 400,
24
+ small: 576,
25
+ medium: 768,
26
+ large: 1024,
27
+ container: 1240,
28
+ xlarge: 1275
29
+ };
30
+ var customizedTheme = exports.customizedTheme = {
31
+ fontSize: fontSize,
32
+ fontWeight: fontWeight,
33
+ breakPoints: breakPoints
34
+ };
35
+ //# sourceMappingURL=tokens.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tokens.js","names":["fontSize","exports","xxl","xl","lg","md","sm","ssm","fontWeight","light","regular","semiBold","bold","breakPoints","xsmall","small","medium","large","container","xlarge","customizedTheme"],"sources":["../../src/Theme/tokens.ts"],"sourcesContent":["export const fontSize = {\n xxl: 26,\n xl: 24,\n lg: 21,\n md: 18,\n default: 16,\n sm: 14,\n ssm: 12,\n} as const;\n\nexport type FontSize = keyof typeof fontSize;\n\nexport const fontWeight = {\n light: 300,\n regular: 400,\n semiBold: 500,\n bold: 700,\n} as const;\n\nexport type FontWeight = keyof typeof fontWeight;\n\nexport const breakPoints = {\n xsmall: 400,\n small: 576,\n medium: 768,\n large: 1024,\n container: 1240,\n xlarge: 1275,\n} as const;\n\nexport type BreakPoints = typeof breakPoints;\n\nexport interface CustomTheme {\n fontSize: typeof fontSize;\n fontWeight: typeof fontWeight;\n breakPoints: typeof breakPoints;\n}\n\nexport const customizedTheme = {\n fontSize,\n fontWeight,\n breakPoints,\n};\n\nexport type CustomizedTheme = typeof customizedTheme;\n"],"mappings":";;;;;;AAAO,IAAMA,QAAQ,GAAAC,OAAA,CAAAD,QAAA,GAAG;EACtBE,GAAG,EAAE,EAAE;EACPC,EAAE,EAAE,EAAE;EACNC,EAAE,EAAE,EAAE;EACNC,EAAE,EAAE,EAAE;EACN,WAAS,EAAE;EACXC,EAAE,EAAE,EAAE;EACNC,GAAG,EAAE;AACP,CAAU;AAIH,IAAMC,UAAU,GAAAP,OAAA,CAAAO,UAAA,GAAG;EACxBC,KAAK,EAAE,GAAG;EACVC,OAAO,EAAE,GAAG;EACZC,QAAQ,EAAE,GAAG;EACbC,IAAI,EAAE;AACR,CAAU;AAIH,IAAMC,WAAW,GAAAZ,OAAA,CAAAY,WAAA,GAAG;EACzBC,MAAM,EAAE,GAAG;EACXC,KAAK,EAAE,GAAG;EACVC,MAAM,EAAE,GAAG;EACXC,KAAK,EAAE,IAAI;EACXC,SAAS,EAAE,IAAI;EACfC,MAAM,EAAE;AACV,CAAU;AAUH,IAAMC,eAAe,GAAAnB,OAAA,CAAAmB,eAAA,GAAG;EAC7BpB,QAAQ,EAARA,QAAQ;EACRQ,UAAU,EAAVA,UAAU;EACVK,WAAW,EAAXA;AACF,CAAC","ignoreList":[]}
@@ -0,0 +1,19 @@
1
+ import type { APIRoute } from '../store/routes';
2
+ export declare const fetcher: <T>(url: string, method: string, body: any, options?: {
3
+ signal?: AbortSignal;
4
+ }) => Promise<T>;
5
+ export declare function useDataMutation<T>(basePath: string, route: APIRoute | string, method?: string, options?: {
6
+ buildUrl?: (basePath: string, route: string) => string;
7
+ }): {
8
+ data: T | undefined;
9
+ error: any;
10
+ isMutating: boolean;
11
+ trigger: import("swr/mutation").TriggerWithOptionsArgs<T, any, string, any>;
12
+ };
13
+ export declare function useTarballDownload(): {
14
+ download: import("swr/mutation").TriggerWithArgs<Blob, any, string, {
15
+ link: string;
16
+ }>;
17
+ isDownloading: boolean;
18
+ error: any;
19
+ };
@@ -0,0 +1,99 @@
1
+ "use strict";
2
+
3
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
4
+ Object.defineProperty(exports, "__esModule", {
5
+ value: true
6
+ });
7
+ exports.fetcher = void 0;
8
+ exports.useDataMutation = useDataMutation;
9
+ exports.useTarballDownload = useTarballDownload;
10
+ var _mutation = _interopRequireDefault(require("swr/mutation"));
11
+ var _api = _interopRequireDefault(require("../store/api"));
12
+ var _utils = require("../store/utils");
13
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
14
+ function _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = "function" == typeof Symbol ? Symbol : {}, n = r.iterator || "@@iterator", o = r.toStringTag || "@@toStringTag"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, "_invoke", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError("Generator is already running"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = "next"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError("iterator result is not an object"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i["return"]) && t.call(i), c < 2 && (u = TypeError("The iterator does not provide a '" + o + "' method"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, "GeneratorFunction")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, "constructor", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = "GeneratorFunction", _regeneratorDefine2(GeneratorFunctionPrototype, o, "GeneratorFunction"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, "Generator"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, "toString", function () { return "[object Generator]"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }
15
+ function _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, "", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o("next", 0), o("throw", 1), o("return", 2)); }, _regeneratorDefine2(e, r, n, t); }
16
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
17
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
18
+ function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
19
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
20
+ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
21
+ function asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }
22
+ function _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, "next", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, "throw", n); } _next(void 0); }); }; }
23
+ var fetcher = exports.fetcher = /*#__PURE__*/function () {
24
+ var _ref = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(url, method, body, options) {
25
+ var isGet, finalUrl;
26
+ return _regenerator().w(function (_context) {
27
+ while (1) switch (_context.n) {
28
+ case 0:
29
+ isGet = method.toUpperCase() === 'GET';
30
+ finalUrl = url;
31
+ return _context.a(2, _api["default"].request(finalUrl, method, {
32
+ // Only stringify and send body if it's NOT a GET request
33
+ body: isGet ? undefined : JSON.stringify(body),
34
+ headers: _objectSpread({
35
+ Accept: _utils.HEADERS.JSON
36
+ }, isGet ? {} : {
37
+ 'Content-Type': _utils.HEADERS.JSON
38
+ }),
39
+ signal: options === null || options === void 0 ? void 0 : options.signal
40
+ }));
41
+ }
42
+ }, _callee);
43
+ }));
44
+ return function fetcher(_x, _x2, _x3, _x4) {
45
+ return _ref.apply(this, arguments);
46
+ };
47
+ }();
48
+ function useDataMutation(basePath, route) {
49
+ var method = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'POST';
50
+ var options = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};
51
+ var key = options.buildUrl ? options.buildUrl(basePath, route) : "".concat(basePath).concat(route);
52
+ var _useSWRMutation = (0, _mutation["default"])(key, function (url, _ref2) {
53
+ var arg = _ref2.arg;
54
+ return fetcher(url, method, arg !== null && arg !== void 0 ? arg : {});
55
+ }),
56
+ data = _useSWRMutation.data,
57
+ error = _useSWRMutation.error,
58
+ isMutating = _useSWRMutation.isMutating,
59
+ trigger = _useSWRMutation.trigger;
60
+ return {
61
+ data: data,
62
+ error: error,
63
+ isMutating: isMutating,
64
+ trigger: trigger
65
+ };
66
+ }
67
+ function tarballFetcher(_x5, _x6) {
68
+ return _tarballFetcher.apply(this, arguments);
69
+ }
70
+ function _tarballFetcher() {
71
+ _tarballFetcher = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee2(url, _ref3) {
72
+ var arg;
73
+ return _regenerator().w(function (_context2) {
74
+ while (1) switch (_context2.n) {
75
+ case 0:
76
+ arg = _ref3.arg;
77
+ return _context2.a(2, _api["default"].request(arg.link, 'GET', {
78
+ headers: {
79
+ accept: 'text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3'
80
+ },
81
+ credentials: 'include'
82
+ }));
83
+ }
84
+ }, _callee2);
85
+ }));
86
+ return _tarballFetcher.apply(this, arguments);
87
+ }
88
+ function useTarballDownload() {
89
+ var _useSWRMutation2 = (0, _mutation["default"])('tarball-download', tarballFetcher),
90
+ trigger = _useSWRMutation2.trigger,
91
+ isMutating = _useSWRMutation2.isMutating,
92
+ error = _useSWRMutation2.error;
93
+ return {
94
+ download: trigger,
95
+ isDownloading: isMutating,
96
+ error: error
97
+ };
98
+ }
99
+ //# sourceMappingURL=use-data-mutation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-data-mutation.js","names":["_mutation","_interopRequireDefault","require","_api","_utils","e","__esModule","_regenerator","t","r","Symbol","n","iterator","o","toStringTag","i","c","prototype","Generator","u","Object","create","_regeneratorDefine2","f","p","y","G","v","a","d","bind","length","l","TypeError","call","done","value","GeneratorFunction","GeneratorFunctionPrototype","getPrototypeOf","setPrototypeOf","__proto__","displayName","w","m","defineProperty","_regeneratorDefine","_invoke","enumerable","configurable","writable","ownKeys","keys","getOwnPropertySymbols","filter","getOwnPropertyDescriptor","push","apply","_objectSpread","arguments","forEach","_defineProperty","getOwnPropertyDescriptors","defineProperties","_toPropertyKey","_toPrimitive","_typeof","toPrimitive","String","Number","asyncGeneratorStep","Promise","resolve","then","_asyncToGenerator","_next","_throw","fetcher","exports","_ref","_callee","url","method","body","options","isGet","finalUrl","_context","toUpperCase","API","request","undefined","JSON","stringify","headers","Accept","HEADERS","signal","_x","_x2","_x3","_x4","useDataMutation","basePath","route","key","buildUrl","concat","_useSWRMutation","useSWRMutation","_ref2","arg","data","error","isMutating","trigger","tarballFetcher","_x5","_x6","_tarballFetcher","_callee2","_ref3","_context2","link","accept","credentials","useTarballDownload","_useSWRMutation2","download","isDownloading"],"sources":["../../src/api/use-data-mutation.ts"],"sourcesContent":["import useSWRMutation from 'swr/mutation';\n\nimport API from '../store/api';\nimport type { APIRoute } from '../store/routes';\nimport { HEADERS } from '../store/utils';\n\nexport const fetcher = async <T>(\n url: string,\n method: string,\n body: any,\n options?: { signal?: AbortSignal }\n): Promise<T> => {\n const isGet = method.toUpperCase() === 'GET';\n const finalUrl = url;\n\n return API.request<T>(finalUrl, method, {\n // Only stringify and send body if it's NOT a GET request\n body: isGet ? undefined : JSON.stringify(body),\n headers: {\n Accept: HEADERS.JSON,\n ...(isGet ? {} : { 'Content-Type': HEADERS.JSON }),\n },\n signal: options?.signal,\n });\n};\n\nexport function useDataMutation<T>(\n basePath: string,\n route: APIRoute | string,\n method = 'POST',\n options: { buildUrl?: (basePath: string, route: string) => string } = {}\n) {\n const key = options.buildUrl ? options.buildUrl(basePath, route) : `${basePath}${route}`;\n\n const { data, error, isMutating, trigger } = useSWRMutation<T, any, string, any>(\n key,\n (url, { arg }) => {\n return fetcher<T>(url, method, arg ?? {});\n }\n );\n\n return { data, error, isMutating, trigger };\n}\n\nasync function tarballFetcher(url: string, { arg }: { arg: { link: string } }): Promise<Blob> {\n return API.request<Blob>(arg.link, 'GET', {\n headers: {\n accept:\n 'text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3',\n },\n credentials: 'include',\n });\n}\n\nexport function useTarballDownload() {\n const { trigger, isMutating, error } = useSWRMutation<Blob, any, string, { link: string }>(\n 'tarball-download',\n tarballFetcher\n );\n\n return {\n download: trigger,\n isDownloading: isMutating,\n error,\n };\n}\n"],"mappings":";;;;;;;;;AAAA,IAAAA,SAAA,GAAAC,sBAAA,CAAAC,OAAA;AAEA,IAAAC,IAAA,GAAAF,sBAAA,CAAAC,OAAA;AAEA,IAAAE,MAAA,GAAAF,OAAA;AAAyC,SAAAD,uBAAAI,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,gBAAAA,CAAA;AAAA,SAAAE,aAAA,IAHzC,uKAAAF,CAAA,EAAAG,CAAA,EAAAC,CAAA,wBAAAC,MAAA,GAAAA,MAAA,OAAAC,CAAA,GAAAF,CAAA,CAAAG,QAAA,kBAAAC,CAAA,GAAAJ,CAAA,CAAAK,WAAA,8BAAAC,EAA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,CAAC,CAAC;MAAA;IAAA,GAAAL,QAAA;EAAA,CACH;EAAA,OAAAD,eAAA,CAAA9D,KAAA,OAAAE,SAAA;AAAA;AAEM,SAASmE,kBAAkBA,CAAA,EAAG;EACnC,IAAAC,gBAAA,GAAuC,IAAAlB,oBAAc,EACnD,kBAAkB,EAClBO,cACF,CAAC;IAHOD,OAAO,GAAAY,gBAAA,CAAPZ,OAAO;IAAED,UAAU,GAAAa,gBAAA,CAAVb,UAAU;IAAED,KAAK,GAAAc,gBAAA,CAALd,KAAK;EAKlC,OAAO;IACLe,QAAQ,EAAEb,OAAO;IACjBc,aAAa,EAAEf,UAAU;IACzBD,KAAK,EAALA;EACF,CAAC;AACH","ignoreList":[]}
@@ -0,0 +1,3 @@
1
+ import type { SWRResponse } from 'swr';
2
+ import type { APIRoute } from '../store/routes';
3
+ export declare function useData<T>(basePath: string, route: APIRoute, packageName?: string, packageVersion?: string): Pick<SWRResponse<T>, 'data' | 'error' | 'isLoading' | 'mutate'>;
@@ -0,0 +1,36 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.useData = useData;
7
+ var _swr = _interopRequireDefault(require("swr"));
8
+ var _api = _interopRequireDefault(require("../store/api"));
9
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
10
+ function buildUrl(basePath, route, packageName, packageVersion) {
11
+ var url = "".concat(basePath).concat(route);
12
+ if (packageName) {
13
+ url += packageName;
14
+ }
15
+ if (packageVersion) {
16
+ url += "?v=".concat(packageVersion);
17
+ }
18
+ return url;
19
+ }
20
+ function useData(basePath, route, packageName, packageVersion) {
21
+ var url = buildUrl(basePath, route, packageName, packageVersion);
22
+ var _useSWR = (0, _swr["default"])(url, function () {
23
+ return _api["default"].request(url);
24
+ }),
25
+ data = _useSWR.data,
26
+ error = _useSWR.error,
27
+ isLoading = _useSWR.isLoading,
28
+ mutate = _useSWR.mutate;
29
+ return {
30
+ data: data,
31
+ error: error,
32
+ isLoading: isLoading,
33
+ mutate: mutate
34
+ };
35
+ }
36
+ //# sourceMappingURL=use-data.js.map