@terrestris/shogun-admin 16.1.0-next.1 → 17.0.0-next.10

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 (260) hide show
  1. package/README.md +4 -0
  2. package/package.json +116 -107
  3. package/dist/build/assets/App-BP74CNP_.js +0 -1258
  4. package/dist/build/assets/__federation_shared_react-CvClEUjg.js +0 -9
  5. package/dist/build/assets/__federation_shared_react-dom-BxqGBSTk.js +0 -24
  6. package/dist/build/assets/__federation_shared_react-i18next-MD_bYxcL.js +0 -1
  7. package/dist/build/assets/__federation_shared_react-router-dom-Vy7O6TNk.js +0 -2
  8. package/dist/build/assets/_commonjsHelpers-BosuxZz1.js +0 -1
  9. package/dist/build/assets/_virtual___federation_fn_import-PJHfB1tr.js +0 -1
  10. package/dist/build/assets/abap-DRC6TkPh.js +0 -6
  11. package/dist/build/assets/apex-BuapDI9Y.js +0 -6
  12. package/dist/build/assets/azcli-BypH-vXm.js +0 -6
  13. package/dist/build/assets/bat-BY6pwuIY.js +0 -6
  14. package/dist/build/assets/bicep-gRuQeaLk.js +0 -7
  15. package/dist/build/assets/cameligo-ul-Lp4lw.js +0 -6
  16. package/dist/build/assets/clojure-DeYg-96x.js +0 -6
  17. package/dist/build/assets/codicon-DCmgc-ay.ttf +0 -0
  18. package/dist/build/assets/coffee-CfnpWUYo.js +0 -6
  19. package/dist/build/assets/cpp-C9L3yaDO.js +0 -6
  20. package/dist/build/assets/csharp-DWGz5Zuj.js +0 -6
  21. package/dist/build/assets/csp-DrRCxMg5.js +0 -6
  22. package/dist/build/assets/css-BfLuTCmN.js +0 -8
  23. package/dist/build/assets/css.worker-BAJD-bzR.js +0 -83
  24. package/dist/build/assets/cssMode-Btzqpc23.js +0 -4
  25. package/dist/build/assets/cypher-DoFvH58O.js +0 -6
  26. package/dist/build/assets/dart-DIovg4uR.js +0 -6
  27. package/dist/build/assets/dockerfile-D2PfwrvU.js +0 -6
  28. package/dist/build/assets/ecl-C_scCXcs.js +0 -6
  29. package/dist/build/assets/editor.worker-MnaSPjGA.js +0 -11
  30. package/dist/build/assets/elixir-BRk-K-rg.js +0 -6
  31. package/dist/build/assets/favicon-CwZoocDV.ico +0 -0
  32. package/dist/build/assets/flow9-DLs3tTet.js +0 -6
  33. package/dist/build/assets/freemarker2-CoZuEXJi.js +0 -3
  34. package/dist/build/assets/fsharp-D0UiDa5C.js +0 -6
  35. package/dist/build/assets/go-CyVeKkvQ.js +0 -6
  36. package/dist/build/assets/graphql-BygKL3ZF.js +0 -6
  37. package/dist/build/assets/handlebars-BQ2vXFqT.js +0 -1
  38. package/dist/build/assets/hcl-D_OY6ada.js +0 -6
  39. package/dist/build/assets/html-S9BExIX4.js +0 -1
  40. package/dist/build/assets/html.worker-Bp7pNElH.js +0 -460
  41. package/dist/build/assets/htmlMode-D6oh_W-n.js +0 -4
  42. package/dist/build/assets/index-D5X_Cuhy.js +0 -139
  43. package/dist/build/assets/ini-BTpWsGps.js +0 -6
  44. package/dist/build/assets/java-3TATJI7h.js +0 -6
  45. package/dist/build/assets/javascript-C_BsKwTq.js +0 -1
  46. package/dist/build/assets/json.worker-BfIkrIax.js +0 -48
  47. package/dist/build/assets/jsonMode-CFQnTUoH.js +0 -10
  48. package/dist/build/assets/julia-DDpSJMW6.js +0 -6
  49. package/dist/build/assets/kotlin-DVYH6Lj_.js +0 -6
  50. package/dist/build/assets/less-CuFlys0T.js +0 -7
  51. package/dist/build/assets/lexon-m09vb5r-.js +0 -6
  52. package/dist/build/assets/liquid-CsJvQ-Gd.js +0 -1
  53. package/dist/build/assets/lua-D2Z7JJdl.js +0 -6
  54. package/dist/build/assets/m3-B2Cf9XSq.js +0 -6
  55. package/dist/build/assets/markdown-BXYnMxBe.js +0 -6
  56. package/dist/build/assets/mdx-CcsV6KQM.js +0 -1
  57. package/dist/build/assets/mips-Ckkbw-AO.js +0 -6
  58. package/dist/build/assets/msdax-B5uW3Zvf.js +0 -6
  59. package/dist/build/assets/mysql-B8ssZoUh.js +0 -6
  60. package/dist/build/assets/objective-c-CrrKwR0a.js +0 -6
  61. package/dist/build/assets/pascal-BWBTHuhh.js +0 -6
  62. package/dist/build/assets/pascaligo-BGLI1Hdo.js +0 -6
  63. package/dist/build/assets/perl-DDrv2Hr-.js +0 -6
  64. package/dist/build/assets/pgsql-DLPipH_Q.js +0 -6
  65. package/dist/build/assets/php-CTNlIIiR.js +0 -6
  66. package/dist/build/assets/pla-2oJWbEOo.js +0 -6
  67. package/dist/build/assets/postiats-DOk3G3cc.js +0 -6
  68. package/dist/build/assets/powerquery-Dgyr3wWZ.js +0 -6
  69. package/dist/build/assets/powershell-B_i9asfM.js +0 -6
  70. package/dist/build/assets/protobuf-CV9EbfTh.js +0 -7
  71. package/dist/build/assets/pug-CCBS_C5_.js +0 -6
  72. package/dist/build/assets/python-BNsLUA-F.js +0 -1
  73. package/dist/build/assets/qsharp-BLuZWbUW.js +0 -6
  74. package/dist/build/assets/r-CzF1MCbP.js +0 -6
  75. package/dist/build/assets/razor-CwLyy1uA.js +0 -1
  76. package/dist/build/assets/redis-C75U4IDy.js +0 -6
  77. package/dist/build/assets/redshift-Bc5xkKR1.js +0 -6
  78. package/dist/build/assets/restructuredtext-DmdQbaLT.js +0 -6
  79. package/dist/build/assets/ruby-DB0RB20n.js +0 -6
  80. package/dist/build/assets/rust-UMmp-gVE.js +0 -6
  81. package/dist/build/assets/sb-DVG02705.js +0 -6
  82. package/dist/build/assets/scala-DvSxYeG4.js +0 -6
  83. package/dist/build/assets/scheme-yf5bffbF.js +0 -6
  84. package/dist/build/assets/scss-Bzb7OGdO.js +0 -8
  85. package/dist/build/assets/shell-FNqbgIOG.js +0 -6
  86. package/dist/build/assets/shogun-spinner-BmOUi9Ar.gif +0 -0
  87. package/dist/build/assets/shogun_logo-B9ohJOpL.png +0 -0
  88. package/dist/build/assets/solidity-DyKutqhl.js +0 -6
  89. package/dist/build/assets/sophia-B4VqtPa2.js +0 -6
  90. package/dist/build/assets/sparql-B7alP455.js +0 -6
  91. package/dist/build/assets/sql-D7lU1fdU.js +0 -6
  92. package/dist/build/assets/st-VuadG5SK.js +0 -6
  93. package/dist/build/assets/style-CJpWC7V3.css +0 -1
  94. package/dist/build/assets/swift-BYtUz8ZP.js +0 -8
  95. package/dist/build/assets/systemverilog-DOAuugfS.js +0 -6
  96. package/dist/build/assets/tcl-CXKOl_mN.js +0 -6
  97. package/dist/build/assets/ts.worker-BBBnYv8q.js +0 -51333
  98. package/dist/build/assets/tsMode-meseu6bK.js +0 -11
  99. package/dist/build/assets/twig-D9yiNO04.js +0 -6
  100. package/dist/build/assets/typescript-BuOvk1sq.js +0 -1
  101. package/dist/build/assets/typespec-BupSXVCO.js +0 -6
  102. package/dist/build/assets/vb-ZlaFEk-P.js +0 -6
  103. package/dist/build/assets/wgsl-DrbANKle.js +0 -303
  104. package/dist/build/assets/xml-BXx9C-xA.js +0 -1
  105. package/dist/build/assets/yaml-CuMedh6B.js +0 -1
  106. package/dist/build/index.html +0 -24
  107. package/dist/lib/App.d.ts +0 -4
  108. package/dist/lib/App.js +0 -122
  109. package/dist/lib/Component/Dashboard/Dashboard.d.ts +0 -12
  110. package/dist/lib/Component/Dashboard/Dashboard.js +0 -10
  111. package/dist/lib/Component/Dashboard/DashboardCard/DashboardCard.d.ts +0 -13
  112. package/dist/lib/Component/Dashboard/DashboardCard/DashboardCard.js +0 -7
  113. package/dist/lib/Component/Dashboard/DashboardStatistics/DashboardStatistics.d.ts +0 -15
  114. package/dist/lib/Component/Dashboard/DashboardStatistics/DashboardStatistics.js +0 -30
  115. package/dist/lib/Component/EvictCache/EvictCache.d.ts +0 -6
  116. package/dist/lib/Component/EvictCache/EvictCache.js +0 -28
  117. package/dist/lib/Component/FormField/DisplayField/DisplayField.d.ts +0 -13
  118. package/dist/lib/Component/FormField/DisplayField/DisplayField.js +0 -32
  119. package/dist/lib/Component/FormField/JSONEditor/JSONEditor.d.ts +0 -13
  120. package/dist/lib/Component/FormField/JSONEditor/JSONEditor.js +0 -90
  121. package/dist/lib/Component/FormField/JSONEditor/UserWorker.d.ts +0 -1
  122. package/dist/lib/Component/FormField/JSONEditor/UserWorker.js +0 -26
  123. package/dist/lib/Component/FormField/LinkField/LinkField.d.ts +0 -11
  124. package/dist/lib/Component/FormField/LinkField/LinkField.js +0 -15
  125. package/dist/lib/Component/FormField/MarkdownEditor/MarkdownEditor.d.ts +0 -10
  126. package/dist/lib/Component/FormField/MarkdownEditor/MarkdownEditor.js +0 -23
  127. package/dist/lib/Component/FormField/Permission/GroupPermissionGrid/GroupPermissionGrid.d.ts +0 -7
  128. package/dist/lib/Component/FormField/Permission/GroupPermissionGrid/GroupPermissionGrid.js +0 -73
  129. package/dist/lib/Component/FormField/Permission/InstancePermissionGrid/InstancePermissionGrid.d.ts +0 -30
  130. package/dist/lib/Component/FormField/Permission/InstancePermissionGrid/InstancePermissionGrid.js +0 -151
  131. package/dist/lib/Component/FormField/Permission/PermissionModal/PermissionModal.d.ts +0 -28
  132. package/dist/lib/Component/FormField/Permission/PermissionModal/PermissionModal.js +0 -103
  133. package/dist/lib/Component/FormField/Permission/PermissionSelect/PermissionSelect.d.ts +0 -6
  134. package/dist/lib/Component/FormField/Permission/PermissionSelect/PermissionSelect.js +0 -21
  135. package/dist/lib/Component/FormField/Permission/RolePermissionGrid/RolePermissionGrid.d.ts +0 -7
  136. package/dist/lib/Component/FormField/Permission/RolePermissionGrid/RolePermissionGrid.js +0 -81
  137. package/dist/lib/Component/FormField/Permission/UserPermissionGrid/UserPermissionGrid.d.ts +0 -8
  138. package/dist/lib/Component/FormField/Permission/UserPermissionGrid/UserPermissionGrid.js +0 -87
  139. package/dist/lib/Component/FormField/VerifyProviderDetailsField/VerifyProviderDetailsField.d.ts +0 -13
  140. package/dist/lib/Component/FormField/VerifyProviderDetailsField/VerifyProviderDetailsField.js +0 -14
  141. package/dist/lib/Component/FormField/YesOrNoField/YesOrNoField.d.ts +0 -8
  142. package/dist/lib/Component/FormField/YesOrNoField/YesOrNoField.js +0 -10
  143. package/dist/lib/Component/FullscreenWrapper/FullscreenWrapper.d.ts +0 -4
  144. package/dist/lib/Component/FullscreenWrapper/FullscreenWrapper.js +0 -48
  145. package/dist/lib/Component/GeneralEntity/GeneralEntityForm/GeneralEntityForm.d.ts +0 -43
  146. package/dist/lib/Component/GeneralEntity/GeneralEntityForm/GeneralEntityForm.js +0 -145
  147. package/dist/lib/Component/GeneralEntity/GeneralEntityRoot/GeneralEntityRoot.d.ts +0 -22
  148. package/dist/lib/Component/GeneralEntity/GeneralEntityRoot/GeneralEntityRoot.js +0 -527
  149. package/dist/lib/Component/GeneralEntity/GeneralEntityTable/GeneralEntityTable.d.ts +0 -46
  150. package/dist/lib/Component/GeneralEntity/GeneralEntityTable/GeneralEntityTable.js +0 -179
  151. package/dist/lib/Component/GlobalSettings/GlobalSettingsRoot/GlobalSettingsRoot.d.ts +0 -5
  152. package/dist/lib/Component/GlobalSettings/GlobalSettingsRoot/GlobalSettingsRoot.js +0 -15
  153. package/dist/lib/Component/Header/Header.d.ts +0 -8
  154. package/dist/lib/Component/Header/Header.js +0 -16
  155. package/dist/lib/Component/ImageFile/ImageFileForm/ImageFileForm.d.ts +0 -7
  156. package/dist/lib/Component/ImageFile/ImageFileForm/ImageFileForm.js +0 -94
  157. package/dist/lib/Component/ImageFile/ImageFileRoot/ImageFileRoot.d.ts +0 -7
  158. package/dist/lib/Component/ImageFile/ImageFileRoot/ImageFileRoot.js +0 -44
  159. package/dist/lib/Component/ImageFile/ImageFileTable/ImageFileTable.d.ts +0 -9
  160. package/dist/lib/Component/ImageFile/ImageFileTable/ImageFileTable.js +0 -157
  161. package/dist/lib/Component/LanguageSelector/index.d.ts +0 -4
  162. package/dist/lib/Component/LanguageSelector/index.js +0 -15
  163. package/dist/lib/Component/Layer/LayerTypeSelect/LayerTypeSelect.d.ts +0 -11
  164. package/dist/lib/Component/Layer/LayerTypeSelect/LayerTypeSelect.js +0 -33
  165. package/dist/lib/Component/LayerPreview/LayerPreview.d.ts +0 -9
  166. package/dist/lib/Component/LayerPreview/LayerPreview.js +0 -159
  167. package/dist/lib/Component/LayerPreview/MapComponent/MapComponent.d.ts +0 -10
  168. package/dist/lib/Component/LayerPreview/MapComponent/MapComponent.js +0 -22
  169. package/dist/lib/Component/LogSettings/LogLevelSelect/LogLevelSelect.d.ts +0 -7
  170. package/dist/lib/Component/LogSettings/LogLevelSelect/LogLevelSelect.js +0 -20
  171. package/dist/lib/Component/LogSettings/LogLevelTable/LogLevelTable.d.ts +0 -12
  172. package/dist/lib/Component/LogSettings/LogLevelTable/LogLevelTable.js +0 -73
  173. package/dist/lib/Component/LogSettings/LogSettingsRoot/LogSettingsRoot.d.ts +0 -4
  174. package/dist/lib/Component/LogSettings/LogSettingsRoot/LogSettingsRoot.js +0 -11
  175. package/dist/lib/Component/Logs/Logs.d.ts +0 -5
  176. package/dist/lib/Component/Logs/Logs.js +0 -58
  177. package/dist/lib/Component/Menu/Navigation/Navigation.d.ts +0 -10
  178. package/dist/lib/Component/Menu/Navigation/Navigation.js +0 -96
  179. package/dist/lib/Component/Menu/User/User.d.ts +0 -7
  180. package/dist/lib/Component/Menu/User/User.js +0 -91
  181. package/dist/lib/Component/Metrics/JdbcConnectionsActive/JdbcConnectionsActive.d.ts +0 -6
  182. package/dist/lib/Component/Metrics/JdbcConnectionsActive/JdbcConnectionsActive.js +0 -7
  183. package/dist/lib/Component/Metrics/JvmMemoryUsed/JvmMemoryUsed.d.ts +0 -6
  184. package/dist/lib/Component/Metrics/JvmMemoryUsed/JvmMemoryUsed.js +0 -13
  185. package/dist/lib/Component/Metrics/JvmThreadsLive/JvmThreadsLive.d.ts +0 -6
  186. package/dist/lib/Component/Metrics/JvmThreadsLive/JvmThreadsLive.js +0 -7
  187. package/dist/lib/Component/Metrics/MetricEntry/MetricEntry.d.ts +0 -13
  188. package/dist/lib/Component/Metrics/MetricEntry/MetricEntry.js +0 -54
  189. package/dist/lib/Component/Metrics/MetricsRoot/MetricsRoot.d.ts +0 -12
  190. package/dist/lib/Component/Metrics/MetricsRoot/MetricsRoot.js +0 -28
  191. package/dist/lib/Component/Metrics/ProcessCpuUsage/ProcessCpuUsage.d.ts +0 -6
  192. package/dist/lib/Component/Metrics/ProcessCpuUsage/ProcessCpuUsage.js +0 -7
  193. package/dist/lib/Component/Metrics/ProcessStartTime/ProcessStartTime.d.ts +0 -6
  194. package/dist/lib/Component/Metrics/ProcessStartTime/ProcessStartTime.js +0 -12
  195. package/dist/lib/Component/Metrics/ProcessUptime/ProcessUptime.d.ts +0 -6
  196. package/dist/lib/Component/Metrics/ProcessUptime/ProcessUptime.js +0 -15
  197. package/dist/lib/Component/Metrics/SystemCpuCount/SystemCpuCount.d.ts +0 -6
  198. package/dist/lib/Component/Metrics/SystemCpuCount/SystemCpuCount.js +0 -7
  199. package/dist/lib/Component/Metrics/SystemCpuUsage/SystemCpuUsage.d.ts +0 -6
  200. package/dist/lib/Component/Metrics/SystemCpuUsage/SystemCpuUsage.js +0 -7
  201. package/dist/lib/Component/Metrics/SystemLoadAverage/SystemLoadAverage.d.ts +0 -6
  202. package/dist/lib/Component/Metrics/SystemLoadAverage/SystemLoadAverage.js +0 -7
  203. package/dist/lib/Component/Modal/ApplicationInfo/ApplicationInfo.d.ts +0 -7
  204. package/dist/lib/Component/Modal/ApplicationInfo/ApplicationInfo.js +0 -18
  205. package/dist/lib/Component/ShogunSpinner/ShogunSpinner.d.ts +0 -5
  206. package/dist/lib/Component/ShogunSpinner/ShogunSpinner.js +0 -7
  207. package/dist/lib/Component/UserAvatar/UserAvatar.d.ts +0 -9
  208. package/dist/lib/Component/UserAvatar/UserAvatar.js +0 -13
  209. package/dist/lib/Component/WelcomeDashboard/WelcomeDashboard.d.ts +0 -5
  210. package/dist/lib/Component/WelcomeDashboard/WelcomeDashboard.js +0 -35
  211. package/dist/lib/Context/PluginContext.d.ts +0 -9
  212. package/dist/lib/Context/PluginContext.js +0 -7
  213. package/dist/lib/Context/SHOGunAPIClientContext.d.ts +0 -9
  214. package/dist/lib/Context/SHOGunAPIClientContext.js +0 -7
  215. package/dist/lib/Controller/ControllerUtil.d.ts +0 -27
  216. package/dist/lib/Controller/ControllerUtil.js +0 -60
  217. package/dist/lib/Controller/GenericEntityController.d.ts +0 -169
  218. package/dist/lib/Controller/GenericEntityController.js +0 -368
  219. package/dist/lib/Hooks/useClientVersion.d.ts +0 -1
  220. package/dist/lib/Hooks/useClientVersion.js +0 -3
  221. package/dist/lib/Hooks/usePlugins.d.ts +0 -3
  222. package/dist/lib/Hooks/usePlugins.js +0 -6
  223. package/dist/lib/Hooks/useSHOGunAPIClient.d.ts +0 -3
  224. package/dist/lib/Hooks/useSHOGunAPIClient.js +0 -6
  225. package/dist/lib/Logger.d.ts +0 -2
  226. package/dist/lib/Logger.js +0 -23
  227. package/dist/lib/Page/Portal/Portal.d.ts +0 -7
  228. package/dist/lib/Page/Portal/Portal.js +0 -74
  229. package/dist/lib/Service/GenericServiceImpl/GenericServiceImpl.d.ts +0 -5
  230. package/dist/lib/Service/GenericServiceImpl/GenericServiceImpl.js +0 -7
  231. package/dist/lib/Service/LogService/LogService.d.ts +0 -18
  232. package/dist/lib/Service/LogService/LogService.js +0 -79
  233. package/dist/lib/Service/MetricService/MetricService.d.ts +0 -26
  234. package/dist/lib/Service/MetricService/MetricService.js +0 -25
  235. package/dist/lib/State/atoms.d.ts +0 -7
  236. package/dist/lib/State/atoms.js +0 -25
  237. package/dist/lib/State/static.d.ts +0 -3
  238. package/dist/lib/State/static.js +0 -10
  239. package/dist/lib/Util/FileUtil.d.ts +0 -3
  240. package/dist/lib/Util/FileUtil.js +0 -10
  241. package/dist/lib/Util/JsonUtil.d.ts +0 -11
  242. package/dist/lib/Util/JsonUtil.js +0 -22
  243. package/dist/lib/Util/OpenAPIUtil.d.ts +0 -25
  244. package/dist/lib/Util/OpenAPIUtil.js +0 -230
  245. package/dist/lib/Util/TableUtil.d.ts +0 -14
  246. package/dist/lib/Util/TableUtil.js +0 -71
  247. package/dist/lib/Util/TranslationUtil.d.ts +0 -3
  248. package/dist/lib/Util/TranslationUtil.js +0 -23
  249. package/dist/lib/Util/UserUtil.d.ts +0 -22
  250. package/dist/lib/Util/UserUtil.js +0 -32
  251. package/dist/lib/i18n/index.d.ts +0 -2
  252. package/dist/lib/i18n/index.js +0 -17
  253. package/dist/lib/i18n/translations.d.ts +0 -508
  254. package/dist/lib/i18n/translations.js +0 -512
  255. package/dist/lib/index.d.ts +0 -1
  256. package/dist/lib/index.js +0 -172
  257. package/dist/lib/plugin/index.d.ts +0 -58
  258. package/dist/lib/plugin/index.js +0 -3
  259. package/dist/lib/test-util.d.ts +0 -6
  260. package/dist/lib/test-util.js +0 -16
@@ -1,7 +0,0 @@
1
- import { AppInfo } from '@terrestris/shogun-util/dist/model/AppInfo';
2
- import Layer from '@terrestris/shogun-util/dist/model/Layer';
3
- import User from '@terrestris/shogun-util/dist/model/User';
4
- export declare const appInfoAtom: import("recoil").RecoilState<AppInfo>;
5
- export declare const userInfoAtom: import("recoil").RecoilState<User<import("@terrestris/shogun-util/dist/model/User").KeycloakUserRepresentation>>;
6
- export declare const shogunInfoModalVisibleAtom: import("recoil").RecoilState<boolean>;
7
- export declare const layerSuggestionListAtom: import("recoil").RecoilState<Layer[]>;
@@ -1,25 +0,0 @@
1
- import { atom } from 'recoil';
2
- export const appInfoAtom = atom({
3
- key: 'appInfo',
4
- default: {
5
- commitHash: '',
6
- version: '',
7
- buildTime: '',
8
- userId: -1,
9
- authorities: []
10
- }
11
- });
12
- export const userInfoAtom = atom({
13
- key: 'userInfo',
14
- default: {
15
- authProviderId: 'peter@pan.de'
16
- }
17
- });
18
- export const shogunInfoModalVisibleAtom = atom({
19
- key: 'shogunInfoVisible',
20
- default: false
21
- });
22
- export const layerSuggestionListAtom = atom({
23
- key: 'layerSuggestionList',
24
- default: undefined
25
- });
@@ -1,3 +0,0 @@
1
- import { OpenAPIV3 } from 'openapi-types';
2
- export declare let swaggerDocs: OpenAPIV3.Document;
3
- export declare const setSwaggerDocs: (docs: OpenAPIV3.Document) => void;
@@ -1,10 +0,0 @@
1
- import Logger from 'js-logger';
2
- export let swaggerDocs;
3
- export const setSwaggerDocs = (docs) => {
4
- if (!swaggerDocs) {
5
- swaggerDocs = docs;
6
- }
7
- else {
8
- Logger.warn('Attemp to set static swagger docs denied.');
9
- }
10
- };
@@ -1,3 +0,0 @@
1
- export default class FileUtil {
2
- static getBase64: (file: File | Blob) => Promise<unknown>;
3
- }
@@ -1,10 +0,0 @@
1
- export default class FileUtil {
2
- static getBase64 = (file) => {
3
- return new Promise((resolve, reject) => {
4
- const reader = new FileReader();
5
- reader.readAsDataURL(file);
6
- reader.onload = () => resolve(reader.result);
7
- reader.onerror = error => reject(error);
8
- });
9
- };
10
- }
@@ -1,11 +0,0 @@
1
- export default class JsonUtil {
2
- /**
3
- * Circular replacer that filters circular references.
4
- *
5
- * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Errors/Cyclic_object_value
6
- *
7
- * @static
8
- * @memberof JsonUtil
9
- */
10
- static getCircularReplacer: () => (key: string, value: any) => any;
11
- }
@@ -1,22 +0,0 @@
1
- export default class JsonUtil {
2
- /**
3
- * Circular replacer that filters circular references.
4
- *
5
- * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Errors/Cyclic_object_value
6
- *
7
- * @static
8
- * @memberof JsonUtil
9
- */
10
- static getCircularReplacer = () => {
11
- const seen = new WeakSet();
12
- return (key, value) => {
13
- if (typeof value === 'object' && value !== null) {
14
- if (seen.has(value)) {
15
- return;
16
- }
17
- seen.add(value);
18
- }
19
- return value;
20
- };
21
- };
22
- }
@@ -1,25 +0,0 @@
1
- import { JSONSchema7, JSONSchema7Definition } from 'json-schema';
2
- import { OpenAPIV3 } from 'openapi-types';
3
- export type JSONSchemaDefinition = {
4
- [key: string]: JSONSchema7Definition;
5
- };
6
- export type OpenAPIUtilOpts = {
7
- document: OpenAPIV3.Document;
8
- };
9
- export declare class OpenAPIUtil {
10
- private document;
11
- constructor(opts: OpenAPIUtilOpts);
12
- getEntityDefinition: (entity: string) => OpenAPIV3.ReferenceObject | OpenAPIV3.SchemaObject | undefined;
13
- getPropertyDefinition: (entity: string, property: string) => OpenAPIV3.ReferenceObject | OpenAPIV3.SchemaObject | undefined;
14
- getPropertyRefName: (entity: string, property: string) => string | undefined;
15
- getPropertyType: (entity: string, property: string) => string | undefined;
16
- getJSONSchemaFromDocument: (schemaName: string, entity: string, property: string) => JSONSchema7;
17
- private createDefinitions;
18
- private getRefName;
19
- private replaceRefs;
20
- private replaceRef;
21
- private replaceRefString;
22
- private applyDiscriminator;
23
- private walkSchemaDefinition;
24
- }
25
- export default OpenAPIUtil;
@@ -1,230 +0,0 @@
1
- import Logger from 'js-logger';
2
- import { validate } from 'json-schema';
3
- import cloneDeep from 'lodash/cloneDeep';
4
- import _isNil from 'lodash/isNil';
5
- export class OpenAPIUtil {
6
- document;
7
- constructor(opts) {
8
- this.document = opts.document;
9
- }
10
- ;
11
- getEntityDefinition = (entity) => {
12
- if (_isNil(this.document?.components?.schemas)) {
13
- return undefined;
14
- }
15
- const entry = Object.entries(this.document?.components?.schemas ?? {})
16
- .find(([definitionKey]) => definitionKey.toLowerCase() === entity.toLowerCase());
17
- if (!entry) {
18
- Logger.warn(`The entity definition for ${entity} does not exist ` +
19
- 'in the OpenAPI specification');
20
- return undefined;
21
- }
22
- return entry[1];
23
- };
24
- getPropertyDefinition = (entity, property) => {
25
- const entityDefinition = this.getEntityDefinition(entity);
26
- if (!entityDefinition) {
27
- return undefined;
28
- }
29
- const schemaObject = entityDefinition;
30
- if (!schemaObject.properties || !schemaObject.properties[property]) {
31
- Logger.warn(`The property definition ${property} for ${entity} ` +
32
- 'does not exist in the OpenAPI specification');
33
- return undefined;
34
- }
35
- return schemaObject.properties[property];
36
- };
37
- getPropertyRefName = (entity, property) => {
38
- const propertyDefinition = this.getPropertyDefinition(entity, property);
39
- if (_isNil(propertyDefinition)) {
40
- return;
41
- }
42
- if (Object.hasOwn(propertyDefinition, '$ref')) {
43
- return this.getRefName(propertyDefinition);
44
- }
45
- if (Object.hasOwn(propertyDefinition, 'items')) {
46
- const schemaObject = propertyDefinition;
47
- if (Object.hasOwn(schemaObject.items, '$ref')) {
48
- return this.getRefName(schemaObject.items);
49
- }
50
- }
51
- return property;
52
- };
53
- getPropertyType = (entity, property) => {
54
- const propertyDefinition = this.getPropertyDefinition(entity, property);
55
- if (_isNil(propertyDefinition)) {
56
- return;
57
- }
58
- if (Object.hasOwn(propertyDefinition, 'type')) {
59
- return propertyDefinition.type;
60
- }
61
- return 'object';
62
- };
63
- getJSONSchemaFromDocument = (schemaName, entity, property) => {
64
- const schemaId = `http://shogun/shogun-schema-${schemaName.toLocaleLowerCase()}.json`;
65
- const schemaDialect = 'http://json-schema.org/2020-12/schema#';
66
- const definitions = this.createDefinitions();
67
- const type = this.getPropertyType(entity, property);
68
- let schema = {
69
- $id: schemaId,
70
- $schema: schemaDialect,
71
- definitions: definitions
72
- };
73
- let isValid = undefined;
74
- if (type === 'object' && !_isNil(definitions)) {
75
- schema = {
76
- ...schema,
77
- ...definitions[schemaName]
78
- };
79
- isValid = validate({}, schema);
80
- }
81
- if (type === 'array' && !_isNil(definitions)) {
82
- schema.items = definitions[schemaName];
83
- schema.type = 'array';
84
- isValid = validate([], schema);
85
- }
86
- if (_isNil(isValid) || !isValid?.valid) {
87
- Logger.error('Invalid JSON schema detected: ', isValid?.errors);
88
- }
89
- return schema;
90
- };
91
- createDefinitions = () => {
92
- const definitions = {};
93
- if (_isNil(this.document?.components?.schemas)) {
94
- return undefined;
95
- }
96
- for (const schemaName in this.document?.components?.schemas) {
97
- // Ignore the revision types, e.g. Revisions«int,Application»
98
- if (schemaName.match(/^(.+)«(.+)»$/)) {
99
- continue;
100
- }
101
- let definition = cloneDeep(this.document.components.schemas[schemaName]);
102
- this.replaceRefs(definition);
103
- this.applyDiscriminator(definition);
104
- definitions[schemaName] = definition;
105
- }
106
- return definitions;
107
- };
108
- getRefName = (definition) => {
109
- const splitParts = definition.$ref?.split('/');
110
- return splitParts[splitParts.length - 1];
111
- };
112
- replaceRefs = (definition) => {
113
- const replace = (def) => {
114
- if (Object.hasOwn(def, '$ref')) {
115
- this.replaceRef(def);
116
- }
117
- };
118
- this.walkSchemaDefinition(definition, replace);
119
- };
120
- replaceRef = (referenceObject) => {
121
- referenceObject.$ref = this.replaceRefString(referenceObject.$ref);
122
- };
123
- replaceRefString = (reference) => {
124
- const splitParts = reference.split('/');
125
- return `#/definitions/${splitParts[splitParts.length - 1]}`;
126
- };
127
- applyDiscriminator = (definition) => {
128
- let discriminator;
129
- const findDiscriminator = (def) => {
130
- if (Object.hasOwn(def, '$ref')) {
131
- const referenceObject = def;
132
- const nextDef = this.getEntityDefinition(this.getRefName(referenceObject));
133
- if (!_isNil(nextDef)) {
134
- this.walkSchemaDefinition(nextDef, findDiscriminator);
135
- }
136
- else {
137
- Logger.warn(`Schema definition of ${def} is not defined.`);
138
- }
139
- }
140
- else {
141
- const schemaObject = def;
142
- if (schemaObject.discriminator) {
143
- discriminator = schemaObject.discriminator;
144
- }
145
- }
146
- };
147
- const findOneOf = (def) => {
148
- if (Object.hasOwn(def, '$ref') || !Object.hasOwn(def, 'oneOf')) {
149
- return;
150
- }
151
- let schemaObject = def;
152
- if (_isNil(schemaObject?.oneOf)) {
153
- return;
154
- }
155
- const allOf = [];
156
- for (const d of schemaObject.oneOf) {
157
- this.walkSchemaDefinition(d, findDiscriminator);
158
- if (!discriminator) {
159
- continue;
160
- }
161
- const discriminatorProperty = discriminator.propertyName;
162
- const discriminatorMapping = discriminator.mapping;
163
- if (!discriminatorMapping) {
164
- continue;
165
- }
166
- for (const [value, schema] of Object.entries(discriminatorMapping)) {
167
- const condition = {
168
- if: {
169
- properties: {},
170
- required: []
171
- },
172
- then: {
173
- '$ref': undefined
174
- }
175
- };
176
- condition.if.properties[discriminatorProperty] = {};
177
- condition.if.properties[discriminatorProperty].const = value;
178
- if (!_isNil(condition?.if?.required)) {
179
- condition.if.required.push(discriminatorProperty);
180
- }
181
- condition.then.$ref = this.replaceRefString(schema);
182
- allOf.push(condition);
183
- }
184
- }
185
- if (allOf.length > 0) {
186
- delete schemaObject.oneOf;
187
- // @ts-ignore
188
- schemaObject.allOf = allOf;
189
- }
190
- };
191
- this.walkSchemaDefinition(definition, findOneOf);
192
- };
193
- walkSchemaDefinition = (definition, callback) => {
194
- if (callback) {
195
- callback(definition);
196
- }
197
- if (Object.hasOwn(definition, '$ref')) {
198
- return;
199
- }
200
- const schemaObject = definition;
201
- const type = schemaObject.type;
202
- if (schemaObject.properties) {
203
- for (const property of Object.values(schemaObject.properties)) {
204
- this.walkSchemaDefinition(property, callback);
205
- }
206
- }
207
- if (schemaObject.allOf) {
208
- for (const def of schemaObject.allOf) {
209
- this.walkSchemaDefinition(def, callback);
210
- }
211
- }
212
- if (schemaObject.anyOf) {
213
- for (const def of schemaObject.anyOf) {
214
- this.walkSchemaDefinition(def, callback);
215
- }
216
- }
217
- if (schemaObject.oneOf) {
218
- for (const def of schemaObject.oneOf) {
219
- this.walkSchemaDefinition(def, callback);
220
- }
221
- }
222
- if (schemaObject.not) {
223
- this.walkSchemaDefinition(schemaObject.not, callback);
224
- }
225
- if (type === 'array') {
226
- this.walkSchemaDefinition(schemaObject.items, callback);
227
- }
228
- };
229
- }
230
- export default OpenAPIUtil;
@@ -1,14 +0,0 @@
1
- import React from 'react';
2
- import { FilterDropdownProps } from 'antd/es/table/interface';
3
- import { FilterConfirmProps } from 'antd/lib/table/interface';
4
- export default class TableUtil {
5
- static getColumnSearchProps<T>(dataIndex: string | string[], handleSearch?: (selectedKeys: React.Key[], confirm?: (param?: FilterConfirmProps | undefined) => void) => void, handleReset?: (clearFilters?: () => void) => void): {
6
- filterDropdown: ({ setSelectedKeys, selectedKeys, confirm, clearFilters }: FilterDropdownProps) => import("react/jsx-runtime").JSX.Element;
7
- filterIcon: (filtered: boolean) => import("react/jsx-runtime").JSX.Element;
8
- onFilter: (value: string | number | boolean, record: T) => boolean;
9
- onFilterDropdownOpenChange: (visible: boolean) => void;
10
- };
11
- static getSorter<T>(dataIndex: string): (a: T, b: T) => number;
12
- static handleSearch: (selectedKeys: React.Key[], confirm?: (param?: FilterConfirmProps | undefined) => void) => void;
13
- static handleReset: (clearFilters?: () => void) => void;
14
- }
@@ -1,71 +0,0 @@
1
- import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
- import { SearchOutlined } from '@ant-design/icons';
3
- import { Button, Input } from 'antd';
4
- import _get from 'lodash/get';
5
- import _isFunction from 'lodash/isFunction';
6
- import _isNil from 'lodash/isNil';
7
- import i18n from '../i18n';
8
- export default class TableUtil {
9
- static getColumnSearchProps(dataIndex, handleSearch = TableUtil.handleSearch, handleReset = TableUtil.handleReset) {
10
- let searchInput;
11
- return {
12
- filterDropdown: ({ setSelectedKeys, selectedKeys, confirm, clearFilters }) => (_jsxs("div", { style: {
13
- padding: '8px',
14
- display: 'flex',
15
- flexDirection: 'column',
16
- alignItems: 'stretch'
17
- }, children: [_jsx(Input, { ref: node => { searchInput = node; }, placeholder: `${i18n.t('GeneralEntityTable.popupSearch')} ${dataIndex}`, value: (selectedKeys.length === 0 || _isNil(selectedKeys[0])) ? '' : `${selectedKeys[0]}`, onChange: e => setSelectedKeys(e.target.value ? [e.target.value] : []), onPressEnter: () => handleSearch(selectedKeys, confirm), style: {
18
- flex: 1,
19
- marginBottom: 8,
20
- } }), _jsxs("div", { style: { display: 'flex' }, children: [_jsx(Button, { type: "primary", onClick: () => handleSearch(selectedKeys, confirm), icon: _jsx(SearchOutlined, {}), size: "small", style: {
21
- flex: 1,
22
- marginRight: 8
23
- }, children: `${i18n.t('GeneralEntityTable.popupFilter')}` }), _jsx(Button, { onClick: () => {
24
- handleReset(clearFilters);
25
- handleSearch(selectedKeys, confirm);
26
- }, size: "small", style: { flex: 1 }, children: `${i18n.t('GeneralEntityTable.popupReset')}` })] })] })),
27
- filterIcon: (filtered) => _jsx(SearchOutlined, { style: { color: filtered ? '#1890ff' : undefined } }),
28
- onFilter: (value, record) => {
29
- let recVal;
30
- if (Array.isArray(dataIndex)) {
31
- let a;
32
- dataIndex.forEach((key, i) => i === 0 ? a = _get(record, key) : a = _get(a, key));
33
- recVal = a;
34
- }
35
- else {
36
- recVal = _get(record, dataIndex.split(','));
37
- }
38
- return `${recVal}`
39
- .toLowerCase()
40
- .includes(`${value}`.toLowerCase());
41
- },
42
- onFilterDropdownOpenChange: (visible) => {
43
- if (visible) {
44
- setTimeout(() => searchInput?.select());
45
- }
46
- }
47
- };
48
- }
49
- ;
50
- static getSorter(dataIndex) {
51
- return (a, b) => {
52
- const valA = _get(a, dataIndex)?.toString();
53
- const valB = _get(b, dataIndex)?.toString();
54
- return valA?.localeCompare(valB, undefined, {
55
- numeric: true,
56
- sensitivity: 'base'
57
- });
58
- };
59
- }
60
- ;
61
- static handleSearch = (selectedKeys, confirm) => {
62
- if (_isFunction(confirm)) {
63
- confirm();
64
- }
65
- };
66
- static handleReset = (clearFilters) => {
67
- if (_isFunction(clearFilters)) {
68
- clearFilters();
69
- }
70
- };
71
- }
@@ -1,3 +0,0 @@
1
- export default class TranslationUtil {
2
- static getTranslationFromConfig: (key?: string, i18n?: FormTranslations) => any;
3
- }
@@ -1,23 +0,0 @@
1
- import _isNil from 'lodash/isNil';
2
- import lng from '../i18n/index';
3
- export default class TranslationUtil {
4
- static getTranslationFromConfig = (key, i18n) => {
5
- const language = lng.language;
6
- const substring = '#i18n.';
7
- if (_isNil(i18n) || _isNil(key)) {
8
- return {};
9
- }
10
- if (key && key.startsWith(substring)) {
11
- if (i18n[language]) {
12
- key = key.split(substring)[1];
13
- return i18n[language][key];
14
- }
15
- else {
16
- return key;
17
- }
18
- }
19
- else {
20
- return key;
21
- }
22
- };
23
- }
@@ -1,22 +0,0 @@
1
- import User from '@terrestris/shogun-util/dist/model/User';
2
- export interface GravatarProps {
3
- email: string;
4
- size?: number;
5
- rating?: 'g' | 'pg' | 'r' | 'x';
6
- defaultImage?: '404' | 'mp' | 'identicon' | 'monsterid' | 'wavatar' | 'retro' | 'robohash' | 'blank';
7
- force?: boolean;
8
- }
9
- export default class UserUtil {
10
- /**
11
- * Determine initials for a given user name. The username will be splitted by
12
- * a whitespace and the first character of each part (capital letter) is added
13
- * to the initials.
14
- * e.g. 'John Doe' leads to 'JD'
15
- *
16
- * @return Initials if the user name.
17
- *
18
- * @method getInitials
19
- */
20
- static getInitials(user: User): string;
21
- static getGravatarUrl({ email, size, rating, defaultImage, force }: GravatarProps): string;
22
- }
@@ -1,32 +0,0 @@
1
- import { md5 } from 'js-md5';
2
- import _isNil from 'lodash/isNil';
3
- const GRAVATAR_BASE_URL = 'https://www.gravatar.com/avatar/';
4
- export default class UserUtil {
5
- /**
6
- * Determine initials for a given user name. The username will be splitted by
7
- * a whitespace and the first character of each part (capital letter) is added
8
- * to the initials.
9
- * e.g. 'John Doe' leads to 'JD'
10
- *
11
- * @return Initials if the user name.
12
- *
13
- * @method getInitials
14
- */
15
- static getInitials(user) {
16
- const firstNameLetter = user?.providerDetails?.firstName?.charAt(0);
17
- const lastNameLetter = user?.providerDetails?.lastName?.charAt(0);
18
- if (_isNil(firstNameLetter) || _isNil(lastNameLetter)) {
19
- return '🔧';
20
- }
21
- return firstNameLetter.toUpperCase() + lastNameLetter.toUpperCase();
22
- }
23
- static getGravatarUrl({ email = '', size = 80, rating = 'g', defaultImage = 'identicon', force = false }) {
24
- const lowerCaseEmail = email.toLowerCase();
25
- const hash = md5(lowerCaseEmail);
26
- let url = `${GRAVATAR_BASE_URL}${hash}?s=${size}&r=${rating}&d=${defaultImage}`;
27
- if (force) {
28
- url = `${url}&f=y`;
29
- }
30
- return url;
31
- }
32
- }
@@ -1,2 +0,0 @@
1
- import i18n from 'i18next';
2
- export default i18n;
@@ -1,17 +0,0 @@
1
- import i18n from 'i18next';
2
- import LanguageDetector from 'i18next-browser-languagedetector';
3
- import { initReactI18next } from 'react-i18next';
4
- import resources from './translations';
5
- i18n
6
- .use(LanguageDetector)
7
- .use(initReactI18next)
8
- .init({
9
- resources,
10
- fallbackLng: 'en',
11
- debug: false,
12
- interpolation: {
13
- escapeValue: false
14
- },
15
- supportedLngs: ['de', 'en']
16
- });
17
- export default i18n;