@intlayer/design-system 4.1.7 → 4.1.9

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 (304) hide show
  1. package/dist/.vite/manifest.json +12 -12
  2. package/dist/components/Auth/ExternalsLoginButtons/ExternalsLoginButtons.cjs +2 -1
  3. package/dist/components/Auth/ExternalsLoginButtons/ExternalsLoginButtons.cjs.map +1 -1
  4. package/dist/components/Auth/ExternalsLoginButtons/ExternalsLoginButtons.mjs +2 -1
  5. package/dist/components/Auth/ExternalsLoginButtons/ExternalsLoginButtons.mjs.map +1 -1
  6. package/dist/components/Auth/useAuth/useOAuth2.d.ts +1 -1
  7. package/dist/components/DictionaryFieldEditor/DictionaryCreationForm/DictionaryCreationForm.cjs +2 -2
  8. package/dist/components/DictionaryFieldEditor/DictionaryCreationForm/DictionaryCreationForm.mjs +2 -2
  9. package/dist/components/DictionaryFieldEditor/DictionaryDetails/DictionaryDetailsForm.cjs +2 -2
  10. package/dist/components/DictionaryFieldEditor/DictionaryDetails/DictionaryDetailsForm.mjs +2 -2
  11. package/dist/components/DictionaryFieldEditor/SaveForm/SaveForm.cjs +2 -2
  12. package/dist/components/DictionaryFieldEditor/SaveForm/SaveForm.mjs +2 -2
  13. package/dist/{index-CKhNmnU1.cjs → index-NyRxk54x.cjs} +2 -4
  14. package/dist/index-NyRxk54x.cjs.map +1 -0
  15. package/dist/{index-B0Lvoony.js → index-ikcnTPvJ.js} +2 -4
  16. package/dist/index-ikcnTPvJ.js.map +1 -0
  17. package/package.json +22 -19
  18. package/dist/CodeBlockShiki-BlmZyrr7.cjs +0 -29
  19. package/dist/CodeBlockShiki-BlmZyrr7.cjs.map +0 -1
  20. package/dist/CodeBlockShiki-CcpV9SVi.js +0 -29
  21. package/dist/CodeBlockShiki-CcpV9SVi.js.map +0 -1
  22. package/dist/CopyButton-Cxu3goRg.cjs +0 -59
  23. package/dist/CopyButton-Cxu3goRg.cjs.map +0 -1
  24. package/dist/CopyButton-DlcDlf6U.js +0 -60
  25. package/dist/CopyButton-DlcDlf6U.js.map +0 -1
  26. package/dist/Form-0D7KBafQ.cjs +0 -311
  27. package/dist/Form-0D7KBafQ.cjs.map +0 -1
  28. package/dist/Form-7BqwvjVI.cjs +0 -320
  29. package/dist/Form-7BqwvjVI.cjs.map +0 -1
  30. package/dist/Form-B2UufQRJ.cjs +0 -319
  31. package/dist/Form-B2UufQRJ.cjs.map +0 -1
  32. package/dist/Form-BB0kpER9.cjs +0 -301
  33. package/dist/Form-BB0kpER9.cjs.map +0 -1
  34. package/dist/Form-BDcoNTLV.cjs +0 -300
  35. package/dist/Form-BDcoNTLV.cjs.map +0 -1
  36. package/dist/Form-BTogr-fp.js +0 -312
  37. package/dist/Form-BTogr-fp.js.map +0 -1
  38. package/dist/Form-BVkkvSKP.js +0 -312
  39. package/dist/Form-BVkkvSKP.js.map +0 -1
  40. package/dist/Form-Be6Uhb5-.js +0 -312
  41. package/dist/Form-Be6Uhb5-.js.map +0 -1
  42. package/dist/Form-BmQQnl-6.js +0 -312
  43. package/dist/Form-BmQQnl-6.js.map +0 -1
  44. package/dist/Form-BoWOdiwq.js +0 -321
  45. package/dist/Form-BoWOdiwq.js.map +0 -1
  46. package/dist/Form-Bp_ubH9I.cjs +0 -311
  47. package/dist/Form-Bp_ubH9I.cjs.map +0 -1
  48. package/dist/Form-BtqRbgLu.cjs +0 -311
  49. package/dist/Form-BtqRbgLu.cjs.map +0 -1
  50. package/dist/Form-COVZyto7.cjs +0 -311
  51. package/dist/Form-COVZyto7.cjs.map +0 -1
  52. package/dist/Form-CVD_3nCD.js +0 -312
  53. package/dist/Form-CVD_3nCD.js.map +0 -1
  54. package/dist/Form-Cfklj1_H.js +0 -320
  55. package/dist/Form-Cfklj1_H.js.map +0 -1
  56. package/dist/Form-ClAAiVNm.cjs +0 -311
  57. package/dist/Form-ClAAiVNm.cjs.map +0 -1
  58. package/dist/Form-DGLgTAdY.js +0 -302
  59. package/dist/Form-DGLgTAdY.js.map +0 -1
  60. package/dist/Form-DhsgC7kB.js +0 -301
  61. package/dist/Form-DhsgC7kB.js.map +0 -1
  62. package/dist/Form-Dv0uHqbL.cjs +0 -320
  63. package/dist/Form-Dv0uHqbL.cjs.map +0 -1
  64. package/dist/Form-OK9zfg6E.js +0 -321
  65. package/dist/Form-OK9zfg6E.js.map +0 -1
  66. package/dist/components/ContentEditor/ContentEditorCode.cjs +0 -78
  67. package/dist/components/ContentEditor/ContentEditorCode.cjs.map +0 -1
  68. package/dist/components/ContentEditor/ContentEditorCode.d.ts +0 -11
  69. package/dist/components/ContentEditor/ContentEditorCode.d.ts.map +0 -1
  70. package/dist/components/ContentEditor/ContentEditorCode.mjs +0 -78
  71. package/dist/components/ContentEditor/ContentEditorCode.mjs.map +0 -1
  72. package/dist/components/DictionaryEditor/useEditedContentStore.cjs +0 -490
  73. package/dist/components/DictionaryEditor/useEditedContentStore.cjs.map +0 -1
  74. package/dist/components/DictionaryEditor/useEditedContentStore.d.ts +0 -28
  75. package/dist/components/DictionaryEditor/useEditedContentStore.d.ts.map +0 -1
  76. package/dist/components/DictionaryEditor/useEditedContentStore.mjs +0 -490
  77. package/dist/components/DictionaryEditor/useEditedContentStore.mjs.map +0 -1
  78. package/dist/components/DictionaryEditor/useEditionPanelStore.cjs +0 -15
  79. package/dist/components/DictionaryEditor/useEditionPanelStore.cjs.map +0 -1
  80. package/dist/components/DictionaryEditor/useEditionPanelStore.d.ts +0 -15
  81. package/dist/components/DictionaryEditor/useEditionPanelStore.d.ts.map +0 -1
  82. package/dist/components/DictionaryEditor/useEditionPanelStore.mjs +0 -15
  83. package/dist/components/DictionaryEditor/useEditionPanelStore.mjs.map +0 -1
  84. package/dist/components/DictionaryFieldEditor/LocaleSelector/LocaleSelector.d.ts +0 -8
  85. package/dist/components/DictionaryFieldEditor/LocaleSelector/LocaleSelector.d.ts.map +0 -1
  86. package/dist/components/DictionaryFieldEditor/LocaleSelector/LocaleSelectorContext.d.ts +0 -13
  87. package/dist/components/DictionaryFieldEditor/LocaleSelector/LocaleSelectorContext.d.ts.map +0 -1
  88. package/dist/components/DictionaryFieldEditor/LocaleSelector/localeSelector.content.d.ts +0 -9
  89. package/dist/components/DictionaryFieldEditor/LocaleSelector/localeSelector.content.d.ts.map +0 -1
  90. package/dist/components/DropDown/types.cjs +0 -2
  91. package/dist/components/DropDown/types.cjs.map +0 -1
  92. package/dist/components/DropDown/types.d.ts +0 -19
  93. package/dist/components/DropDown/types.d.ts.map +0 -1
  94. package/dist/components/DropDown/types.mjs +0 -2
  95. package/dist/components/DropDown/types.mjs.map +0 -1
  96. package/dist/components/IDE/CodeBlock.cjs +0 -54
  97. package/dist/components/IDE/CodeBlock.cjs.map +0 -1
  98. package/dist/components/IDE/CodeBlock.d.ts +0 -12
  99. package/dist/components/IDE/CodeBlock.d.ts.map +0 -1
  100. package/dist/components/IDE/CodeBlock.mjs +0 -54
  101. package/dist/components/IDE/CodeBlock.mjs.map +0 -1
  102. package/dist/components/IDE/CodeBlockLoader.cjs +0 -28
  103. package/dist/components/IDE/CodeBlockLoader.cjs.map +0 -1
  104. package/dist/components/IDE/CodeBlockLoader.d.ts +0 -4
  105. package/dist/components/IDE/CodeBlockLoader.d.ts.map +0 -1
  106. package/dist/components/IDE/CodeBlockLoader.mjs +0 -28
  107. package/dist/components/IDE/CodeBlockLoader.mjs.map +0 -1
  108. package/dist/components/IDE/CodeBlockShiki.d.ts +0 -3
  109. package/dist/components/IDE/CodeBlockShiki.d.ts.map +0 -1
  110. package/dist/components/IDE/CodeRender copy.cjs +0 -141
  111. package/dist/components/IDE/CodeRender copy.cjs.map +0 -1
  112. package/dist/components/IDE/CodeRender copy.d.ts +0 -14
  113. package/dist/components/IDE/CodeRender copy.d.ts.map +0 -1
  114. package/dist/components/IDE/CodeRender copy.mjs +0 -141
  115. package/dist/components/IDE/CodeRender copy.mjs.map +0 -1
  116. package/dist/components/IDE/CodeRender.cjs +0 -49
  117. package/dist/components/IDE/CodeRender.cjs.map +0 -1
  118. package/dist/components/IDE/CodeRender.d.ts +0 -9
  119. package/dist/components/IDE/CodeRender.d.ts.map +0 -1
  120. package/dist/components/IDE/CodeRender.mjs +0 -49
  121. package/dist/components/IDE/CodeRender.mjs.map +0 -1
  122. package/dist/components/IDE/CodeRenderer.cjs +0 -27
  123. package/dist/components/IDE/CodeRenderer.cjs.map +0 -1
  124. package/dist/components/IDE/CodeRenderer.d.ts +0 -5
  125. package/dist/components/IDE/CodeRenderer.d.ts.map +0 -1
  126. package/dist/components/IDE/CodeRenderer.mjs +0 -27
  127. package/dist/components/IDE/CodeRenderer.mjs.map +0 -1
  128. package/dist/components/IDE/EditableCodeBlock.d.ts +0 -9
  129. package/dist/components/IDE/EditableCodeBlock.d.ts.map +0 -1
  130. package/dist/components/LocaleSwitcherContentDropDown/LocaleSelectorContext.d.ts +0 -13
  131. package/dist/components/LocaleSwitcherContentDropDown/LocaleSelectorContext.d.ts.map +0 -1
  132. package/dist/design-system.css +0 -235
  133. package/dist/index-Ai6eeqZH.js +0 -702
  134. package/dist/index-Ai6eeqZH.js.map +0 -1
  135. package/dist/index-B-VAyQ9R.js +0 -673
  136. package/dist/index-B-VAyQ9R.js.map +0 -1
  137. package/dist/index-B0Lvoony.js.map +0 -1
  138. package/dist/index-B1nU1-65.cjs +0 -690
  139. package/dist/index-B1nU1-65.cjs.map +0 -1
  140. package/dist/index-B2UElBcQ.cjs +0 -200
  141. package/dist/index-B2UElBcQ.cjs.map +0 -1
  142. package/dist/index-BIV0x_z2.js +0 -206
  143. package/dist/index-BIV0x_z2.js.map +0 -1
  144. package/dist/index-BIyA5LAs.js +0 -691
  145. package/dist/index-BIyA5LAs.js.map +0 -1
  146. package/dist/index-BMzh1_UJ.js +0 -201
  147. package/dist/index-BMzh1_UJ.js.map +0 -1
  148. package/dist/index-BNH9wXVj.cjs +0 -205
  149. package/dist/index-BNH9wXVj.cjs.map +0 -1
  150. package/dist/index-BbqOa6BU.cjs +0 -701
  151. package/dist/index-BbqOa6BU.cjs.map +0 -1
  152. package/dist/index-BdTa-9zc.js +0 -201
  153. package/dist/index-BdTa-9zc.js.map +0 -1
  154. package/dist/index-BqZwP4Lr.js +0 -691
  155. package/dist/index-BqZwP4Lr.js.map +0 -1
  156. package/dist/index-BtZWYJhL.cjs +0 -200
  157. package/dist/index-BtZWYJhL.cjs.map +0 -1
  158. package/dist/index-Buecpjbh.cjs +0 -690
  159. package/dist/index-Buecpjbh.cjs.map +0 -1
  160. package/dist/index-CDEJjmId.js +0 -694
  161. package/dist/index-CDEJjmId.js.map +0 -1
  162. package/dist/index-CKhNmnU1.cjs.map +0 -1
  163. package/dist/index-CTAyk6RY.cjs +0 -693
  164. package/dist/index-CTAyk6RY.cjs.map +0 -1
  165. package/dist/index-CVC2sfEj.js +0 -693
  166. package/dist/index-CVC2sfEj.js.map +0 -1
  167. package/dist/index-CVz0RdK6.js +0 -691
  168. package/dist/index-CVz0RdK6.js.map +0 -1
  169. package/dist/index-CjF2ksU7.cjs +0 -693
  170. package/dist/index-CjF2ksU7.cjs.map +0 -1
  171. package/dist/index-CuQs5759.cjs +0 -692
  172. package/dist/index-CuQs5759.cjs.map +0 -1
  173. package/dist/index-D69JRZcQ.js +0 -206
  174. package/dist/index-D69JRZcQ.js.map +0 -1
  175. package/dist/index-D9oaKvKC.js +0 -201
  176. package/dist/index-D9oaKvKC.js.map +0 -1
  177. package/dist/index-DFc7og1d.cjs +0 -671
  178. package/dist/index-DFc7og1d.cjs.map +0 -1
  179. package/dist/index-DTCehvKe.cjs +0 -200
  180. package/dist/index-DTCehvKe.cjs.map +0 -1
  181. package/dist/index-D_MDocy7.cjs +0 -690
  182. package/dist/index-D_MDocy7.cjs.map +0 -1
  183. package/dist/index-DcWYZrJW.js +0 -672
  184. package/dist/index-DcWYZrJW.js.map +0 -1
  185. package/dist/index-Djo2Jnua.cjs +0 -693
  186. package/dist/index-Djo2Jnua.cjs.map +0 -1
  187. package/dist/index-LFTthFne.js +0 -694
  188. package/dist/index-LFTthFne.js.map +0 -1
  189. package/dist/index-SOIahRpS.cjs +0 -205
  190. package/dist/index-SOIahRpS.cjs.map +0 -1
  191. package/dist/index-T-TjVQoD.js +0 -671
  192. package/dist/index-T-TjVQoD.js.map +0 -1
  193. package/dist/index-f8_VC6c8.cjs +0 -672
  194. package/dist/index-f8_VC6c8.cjs.map +0 -1
  195. package/dist/index-llGIfxqV.cjs +0 -670
  196. package/dist/index-llGIfxqV.cjs.map +0 -1
  197. package/dist/index-xZoGTokf.js +0 -694
  198. package/dist/index-xZoGTokf.js.map +0 -1
  199. package/dist/jsx-runtime-CL03FswV.cjs +0 -506
  200. package/dist/jsx-runtime-CL03FswV.cjs.map +0 -1
  201. package/dist/jsx-runtime-DaNGiM0W.js +0 -945
  202. package/dist/jsx-runtime-DaNGiM0W.js.map +0 -1
  203. package/dist/jsx-runtime-XHKiWCTo.cjs +0 -944
  204. package/dist/jsx-runtime-XHKiWCTo.cjs.map +0 -1
  205. package/dist/jsx-runtime-kmx34TxC.js +0 -507
  206. package/dist/jsx-runtime-kmx34TxC.js.map +0 -1
  207. package/dist/libs/index.cjs +0 -6
  208. package/dist/libs/index.cjs.map +0 -1
  209. package/dist/libs/index.d.ts +0 -2
  210. package/dist/libs/index.d.ts.map +0 -1
  211. package/dist/libs/index.mjs +0 -6
  212. package/dist/libs/index.mjs.map +0 -1
  213. package/dist/libs/intlayer-api/ai.cjs +0 -64
  214. package/dist/libs/intlayer-api/ai.cjs.map +0 -1
  215. package/dist/libs/intlayer-api/ai.d.ts +0 -18
  216. package/dist/libs/intlayer-api/ai.d.ts.map +0 -1
  217. package/dist/libs/intlayer-api/ai.mjs +0 -64
  218. package/dist/libs/intlayer-api/ai.mjs.map +0 -1
  219. package/dist/libs/intlayer-api/auth.cjs +0 -141
  220. package/dist/libs/intlayer-api/auth.cjs.map +0 -1
  221. package/dist/libs/intlayer-api/auth.d.ts +0 -38
  222. package/dist/libs/intlayer-api/auth.d.ts.map +0 -1
  223. package/dist/libs/intlayer-api/auth.mjs +0 -141
  224. package/dist/libs/intlayer-api/auth.mjs.map +0 -1
  225. package/dist/libs/intlayer-api/dictionary.cjs +0 -78
  226. package/dist/libs/intlayer-api/dictionary.cjs.map +0 -1
  227. package/dist/libs/intlayer-api/dictionary.d.ts +0 -22
  228. package/dist/libs/intlayer-api/dictionary.d.ts.map +0 -1
  229. package/dist/libs/intlayer-api/dictionary.mjs +0 -78
  230. package/dist/libs/intlayer-api/dictionary.mjs.map +0 -1
  231. package/dist/libs/intlayer-api/fetcher.cjs +0 -73
  232. package/dist/libs/intlayer-api/fetcher.cjs.map +0 -1
  233. package/dist/libs/intlayer-api/fetcher.d.ts +0 -70
  234. package/dist/libs/intlayer-api/fetcher.d.ts.map +0 -1
  235. package/dist/libs/intlayer-api/fetcher.mjs +0 -73
  236. package/dist/libs/intlayer-api/fetcher.mjs.map +0 -1
  237. package/dist/libs/intlayer-api/index.cjs +0 -24
  238. package/dist/libs/intlayer-api/index.cjs.map +0 -1
  239. package/dist/libs/intlayer-api/index.d.ts +0 -157
  240. package/dist/libs/intlayer-api/index.d.ts.map +0 -1
  241. package/dist/libs/intlayer-api/index.mjs +0 -24
  242. package/dist/libs/intlayer-api/index.mjs.map +0 -1
  243. package/dist/libs/intlayer-api/organization.cjs +0 -96
  244. package/dist/libs/intlayer-api/organization.cjs.map +0 -1
  245. package/dist/libs/intlayer-api/organization.d.ts +0 -26
  246. package/dist/libs/intlayer-api/organization.d.ts.map +0 -1
  247. package/dist/libs/intlayer-api/organization.mjs +0 -96
  248. package/dist/libs/intlayer-api/organization.mjs.map +0 -1
  249. package/dist/libs/intlayer-api/project.cjs +0 -110
  250. package/dist/libs/intlayer-api/project.cjs.map +0 -1
  251. package/dist/libs/intlayer-api/project.d.ts +0 -28
  252. package/dist/libs/intlayer-api/project.d.ts.map +0 -1
  253. package/dist/libs/intlayer-api/project.mjs +0 -110
  254. package/dist/libs/intlayer-api/project.mjs.map +0 -1
  255. package/dist/libs/intlayer-api/stripe.cjs +0 -31
  256. package/dist/libs/intlayer-api/stripe.cjs.map +0 -1
  257. package/dist/libs/intlayer-api/stripe.d.ts +0 -8
  258. package/dist/libs/intlayer-api/stripe.d.ts.map +0 -1
  259. package/dist/libs/intlayer-api/stripe.mjs +0 -31
  260. package/dist/libs/intlayer-api/stripe.mjs.map +0 -1
  261. package/dist/libs/intlayer-api/tag.cjs +0 -52
  262. package/dist/libs/intlayer-api/tag.cjs.map +0 -1
  263. package/dist/libs/intlayer-api/tag.d.ts +0 -16
  264. package/dist/libs/intlayer-api/tag.d.ts.map +0 -1
  265. package/dist/libs/intlayer-api/tag.mjs +0 -52
  266. package/dist/libs/intlayer-api/tag.mjs.map +0 -1
  267. package/dist/libs/intlayer-api/user.cjs +0 -70
  268. package/dist/libs/intlayer-api/user.cjs.map +0 -1
  269. package/dist/libs/intlayer-api/user.d.ts +0 -22
  270. package/dist/libs/intlayer-api/user.d.ts.map +0 -1
  271. package/dist/libs/intlayer-api/user.mjs +0 -70
  272. package/dist/libs/intlayer-api/user.mjs.map +0 -1
  273. package/dist/navigation-CE0LMHcY.cjs +0 -8538
  274. package/dist/navigation-CE0LMHcY.cjs.map +0 -1
  275. package/dist/navigation-DFabQmdZ.js +0 -914
  276. package/dist/navigation-DFabQmdZ.js.map +0 -1
  277. package/dist/navigation-DRtAVQJF.js +0 -8521
  278. package/dist/navigation-DRtAVQJF.js.map +0 -1
  279. package/dist/navigation-a7EfWhxz.cjs +0 -913
  280. package/dist/navigation-a7EfWhxz.cjs.map +0 -1
  281. package/dist/shallow-lhDIFtEp.cjs +0 -48
  282. package/dist/shallow-lhDIFtEp.cjs.map +0 -1
  283. package/dist/shallow-m9BpCkKh.js +0 -49
  284. package/dist/shallow-m9BpCkKh.js.map +0 -1
  285. package/dist/useGetAllDictionaries-B1sqs2IB.cjs +0 -34
  286. package/dist/useGetAllDictionaries-B1sqs2IB.cjs.map +0 -1
  287. package/dist/useGetAllDictionaries-BbH8vTkY.js +0 -35
  288. package/dist/useGetAllDictionaries-BbH8vTkY.js.map +0 -1
  289. package/dist/useGetAllDictionaries-Bgkytpa2.cjs +0 -34
  290. package/dist/useGetAllDictionaries-Bgkytpa2.cjs.map +0 -1
  291. package/dist/useGetAllDictionaries-D8ma3h41.cjs +0 -33
  292. package/dist/useGetAllDictionaries-D8ma3h41.cjs.map +0 -1
  293. package/dist/useGetAllDictionaries-DHgHEbD5.js +0 -34
  294. package/dist/useGetAllDictionaries-DHgHEbD5.js.map +0 -1
  295. package/dist/useGetAllDictionaries-DUzm0rIa.js +0 -35
  296. package/dist/useGetAllDictionaries-DUzm0rIa.js.map +0 -1
  297. package/dist/utils/dictionary.cjs +0 -158
  298. package/dist/utils/dictionary.cjs.map +0 -1
  299. package/dist/utils/dictionary.d.ts +0 -7
  300. package/dist/utils/dictionary.d.ts.map +0 -1
  301. package/dist/utils/dictionary.mjs +0 -158
  302. package/dist/utils/dictionary.mjs.map +0 -1
  303. /package/dist/components/IDE/{CodeBlockclient.d.ts → CodeBlockClient.d.ts} +0 -0
  304. /package/dist/components/IDE/{CodeBlockclient.d.ts.map → CodeBlockClient.d.ts.map} +0 -0
@@ -1,52 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const client = require("@intlayer/config/client");
4
- const libs_intlayerApi_fetcher = require("./fetcher.cjs");
5
- const getTagAPI = (authAPIOptions = {}, intlayerConfig) => {
6
- const { backendURL } = (intlayerConfig ?? client.getConfiguration()).editor;
7
- const PROJECT_API_ROUTE = `${backendURL}/api/tag`;
8
- const getTags = async (filters, otherOptions = {}) => await libs_intlayerApi_fetcher.fetcher(
9
- PROJECT_API_ROUTE,
10
- authAPIOptions,
11
- otherOptions,
12
- {
13
- params: filters
14
- }
15
- );
16
- const addTag = async (tag, otherOptions = {}) => await libs_intlayerApi_fetcher.fetcher(
17
- `${PROJECT_API_ROUTE}`,
18
- authAPIOptions,
19
- otherOptions,
20
- {
21
- method: "POST",
22
- body: tag
23
- }
24
- );
25
- const updateTag = async (tagId, tag, otherOptions = {}) => await libs_intlayerApi_fetcher.fetcher(
26
- `${PROJECT_API_ROUTE}/${tagId}`,
27
- authAPIOptions,
28
- otherOptions,
29
- {
30
- method: "PUT",
31
- body: tag
32
- }
33
- );
34
- const deleteTag = async (tagId, otherOptions = {}) => await libs_intlayerApi_fetcher.fetcher(
35
- `${PROJECT_API_ROUTE}/${tagId}`,
36
- authAPIOptions,
37
- otherOptions,
38
- {
39
- method: "DELETE"
40
- }
41
- );
42
- return {
43
- getTags,
44
- addTag,
45
- updateTag,
46
- deleteTag
47
- };
48
- };
49
- const tagAPI = getTagAPI();
50
- exports.getTagAPI = getTagAPI;
51
- exports.tagAPI = tagAPI;
52
- //# sourceMappingURL=tag.cjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"tag.cjs","sources":["../../../src/libs/intlayer-api/tag.ts"],"sourcesContent":["import type {\n AddTagBody,\n AddTagResult,\n DeleteTagParams,\n DeleteTagResult,\n GetTagsParams,\n GetTagsResult,\n UpdateTagBody,\n UpdateTagParams,\n UpdateTagResult,\n} from '@intlayer/backend';\nimport { getConfiguration, type IntlayerConfig } from '@intlayer/config/client';\nimport { fetcher, type FetcherOptions } from './fetcher';\n\nexport const getTagAPI = (\n authAPIOptions: FetcherOptions = {},\n intlayerConfig?: IntlayerConfig\n) => {\n const { backendURL } = (intlayerConfig ?? getConfiguration()).editor;\n const PROJECT_API_ROUTE = `${backendURL}/api/tag`;\n\n /**\n * Retrieves a list of tags based on filters and pagination.\n * @param filters - Filters and pagination options.\n */\n const getTags = async (\n filters?: GetTagsParams,\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<GetTagsResult>(\n PROJECT_API_ROUTE,\n authAPIOptions,\n otherOptions,\n {\n params: filters,\n }\n );\n\n /**\n * Adds a new tag to the database.\n * @param tag - Tag data.\n */\n const addTag = async (tag: AddTagBody, otherOptions: FetcherOptions = {}) =>\n await fetcher<AddTagResult>(\n `${PROJECT_API_ROUTE}`,\n authAPIOptions,\n otherOptions,\n {\n method: 'POST',\n body: tag,\n }\n );\n\n /**\n * Updates an existing tag in the database.\n * @param tag - Updated tag data.\n */\n const updateTag = async (\n tagId: UpdateTagParams['tagId'],\n tag: UpdateTagBody,\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<UpdateTagResult>(\n `${PROJECT_API_ROUTE}/${tagId}`,\n authAPIOptions,\n otherOptions,\n {\n method: 'PUT',\n body: tag,\n }\n );\n\n /**\n * Deletes a tag from the database by its ID.\n * @param tagId - Tag ID.\n */\n const deleteTag = async (\n tagId: DeleteTagParams['tagId'],\n\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<DeleteTagResult>(\n `${PROJECT_API_ROUTE}/${tagId}`,\n authAPIOptions,\n otherOptions,\n {\n method: 'DELETE',\n }\n );\n\n return {\n getTags,\n addTag,\n updateTag,\n deleteTag,\n };\n};\n\nexport const tagAPI = getTagAPI();\n"],"names":["getConfiguration","fetcher"],"mappings":";;;;AAcO,MAAM,YAAY,CACvB,iBAAiC,IACjC,mBACG;AACH,QAAM,EAAE,WAAgB,KAAA,kBAAkBA,OAAAA,iBAAoB,GAAA;AACxD,QAAA,oBAAoB,GAAG,UAAU;AAMvC,QAAM,UAAU,OACd,SACA,eAA+B,CAAA,MAE/B,MAAMC,yBAAA;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,IAAA;AAAA,EAEZ;AAMF,QAAM,SAAS,OAAO,KAAiB,eAA+B,CAAA,MACpE,MAAMA,yBAAA;AAAA,IACJ,GAAG,iBAAiB;AAAA,IACpB;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,MACR,MAAM;AAAA,IAAA;AAAA,EAEV;AAMF,QAAM,YAAY,OAChB,OACA,KACA,eAA+B,OAE/B,MAAMA,yBAAA;AAAA,IACJ,GAAG,iBAAiB,IAAI,KAAK;AAAA,IAC7B;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,MACR,MAAM;AAAA,IAAA;AAAA,EAEV;AAMF,QAAM,YAAY,OAChB,OAEA,eAA+B,CAAA,MAE/B,MAAMA,yBAAA;AAAA,IACJ,GAAG,iBAAiB,IAAI,KAAK;AAAA,IAC7B;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,IAAA;AAAA,EAEZ;AAEK,SAAA;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF;AACF;AAEO,MAAM,SAAS,UAAU;;;"}
@@ -1,16 +0,0 @@
1
- import { AddTagBody, AddTagResult, DeleteTagParams, DeleteTagResult, GetTagsParams, GetTagsResult, UpdateTagBody, UpdateTagParams, UpdateTagResult } from '@intlayer/backend';
2
- import { IntlayerConfig } from '@intlayer/config/client';
3
- import { FetcherOptions } from './fetcher';
4
- export declare const getTagAPI: (authAPIOptions?: FetcherOptions, intlayerConfig?: IntlayerConfig) => {
5
- getTags: (filters?: GetTagsParams, otherOptions?: FetcherOptions) => Promise<GetTagsResult>;
6
- addTag: (tag: AddTagBody, otherOptions?: FetcherOptions) => Promise<AddTagResult>;
7
- updateTag: (tagId: UpdateTagParams["tagId"], tag: UpdateTagBody, otherOptions?: FetcherOptions) => Promise<UpdateTagResult>;
8
- deleteTag: (tagId: DeleteTagParams["tagId"], otherOptions?: FetcherOptions) => Promise<DeleteTagResult>;
9
- };
10
- export declare const tagAPI: {
11
- getTags: (filters?: GetTagsParams, otherOptions?: FetcherOptions) => Promise<GetTagsResult>;
12
- addTag: (tag: AddTagBody, otherOptions?: FetcherOptions) => Promise<AddTagResult>;
13
- updateTag: (tagId: UpdateTagParams["tagId"], tag: UpdateTagBody, otherOptions?: FetcherOptions) => Promise<UpdateTagResult>;
14
- deleteTag: (tagId: DeleteTagParams["tagId"], otherOptions?: FetcherOptions) => Promise<DeleteTagResult>;
15
- };
16
- //# sourceMappingURL=tag.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"tag.d.ts","sourceRoot":"","sources":["../../../src/libs/intlayer-api/tag.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,UAAU,EACV,YAAY,EACZ,eAAe,EACf,eAAe,EACf,aAAa,EACb,aAAa,EACb,aAAa,EACb,eAAe,EACf,eAAe,EAChB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAoB,KAAK,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAChF,OAAO,EAAW,KAAK,cAAc,EAAE,MAAM,WAAW,CAAC;AAEzD,eAAO,MAAM,SAAS,oBACJ,cAAc,mBACb,cAAc;wBAUnB,aAAa,iBACT,cAAc;kBAeH,UAAU,iBAAgB,cAAc;uBAgB1D,eAAe,CAAC,OAAO,CAAC,OAC1B,aAAa,iBACJ,cAAc;uBAiBrB,eAAe,CAAC,OAAO,CAAC,iBAEjB,cAAc;CAiB/B,CAAC;AAEF,eAAO,MAAM,MAAM;wBAxEL,aAAa,iBACT,cAAc;kBAeH,UAAU,iBAAgB,cAAc;uBAgB1D,eAAe,CAAC,OAAO,CAAC,OAC1B,aAAa,iBACJ,cAAc;uBAiBrB,eAAe,CAAC,OAAO,CAAC,iBAEjB,cAAc;CAmBC,CAAC"}
@@ -1,52 +0,0 @@
1
- import { getConfiguration } from "@intlayer/config/client";
2
- import { fetcher } from "./fetcher.mjs";
3
- const getTagAPI = (authAPIOptions = {}, intlayerConfig) => {
4
- const { backendURL } = (intlayerConfig ?? getConfiguration()).editor;
5
- const PROJECT_API_ROUTE = `${backendURL}/api/tag`;
6
- const getTags = async (filters, otherOptions = {}) => await fetcher(
7
- PROJECT_API_ROUTE,
8
- authAPIOptions,
9
- otherOptions,
10
- {
11
- params: filters
12
- }
13
- );
14
- const addTag = async (tag, otherOptions = {}) => await fetcher(
15
- `${PROJECT_API_ROUTE}`,
16
- authAPIOptions,
17
- otherOptions,
18
- {
19
- method: "POST",
20
- body: tag
21
- }
22
- );
23
- const updateTag = async (tagId, tag, otherOptions = {}) => await fetcher(
24
- `${PROJECT_API_ROUTE}/${tagId}`,
25
- authAPIOptions,
26
- otherOptions,
27
- {
28
- method: "PUT",
29
- body: tag
30
- }
31
- );
32
- const deleteTag = async (tagId, otherOptions = {}) => await fetcher(
33
- `${PROJECT_API_ROUTE}/${tagId}`,
34
- authAPIOptions,
35
- otherOptions,
36
- {
37
- method: "DELETE"
38
- }
39
- );
40
- return {
41
- getTags,
42
- addTag,
43
- updateTag,
44
- deleteTag
45
- };
46
- };
47
- const tagAPI = getTagAPI();
48
- export {
49
- getTagAPI,
50
- tagAPI
51
- };
52
- //# sourceMappingURL=tag.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"tag.mjs","sources":["../../../src/libs/intlayer-api/tag.ts"],"sourcesContent":["import type {\n AddTagBody,\n AddTagResult,\n DeleteTagParams,\n DeleteTagResult,\n GetTagsParams,\n GetTagsResult,\n UpdateTagBody,\n UpdateTagParams,\n UpdateTagResult,\n} from '@intlayer/backend';\nimport { getConfiguration, type IntlayerConfig } from '@intlayer/config/client';\nimport { fetcher, type FetcherOptions } from './fetcher';\n\nexport const getTagAPI = (\n authAPIOptions: FetcherOptions = {},\n intlayerConfig?: IntlayerConfig\n) => {\n const { backendURL } = (intlayerConfig ?? getConfiguration()).editor;\n const PROJECT_API_ROUTE = `${backendURL}/api/tag`;\n\n /**\n * Retrieves a list of tags based on filters and pagination.\n * @param filters - Filters and pagination options.\n */\n const getTags = async (\n filters?: GetTagsParams,\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<GetTagsResult>(\n PROJECT_API_ROUTE,\n authAPIOptions,\n otherOptions,\n {\n params: filters,\n }\n );\n\n /**\n * Adds a new tag to the database.\n * @param tag - Tag data.\n */\n const addTag = async (tag: AddTagBody, otherOptions: FetcherOptions = {}) =>\n await fetcher<AddTagResult>(\n `${PROJECT_API_ROUTE}`,\n authAPIOptions,\n otherOptions,\n {\n method: 'POST',\n body: tag,\n }\n );\n\n /**\n * Updates an existing tag in the database.\n * @param tag - Updated tag data.\n */\n const updateTag = async (\n tagId: UpdateTagParams['tagId'],\n tag: UpdateTagBody,\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<UpdateTagResult>(\n `${PROJECT_API_ROUTE}/${tagId}`,\n authAPIOptions,\n otherOptions,\n {\n method: 'PUT',\n body: tag,\n }\n );\n\n /**\n * Deletes a tag from the database by its ID.\n * @param tagId - Tag ID.\n */\n const deleteTag = async (\n tagId: DeleteTagParams['tagId'],\n\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<DeleteTagResult>(\n `${PROJECT_API_ROUTE}/${tagId}`,\n authAPIOptions,\n otherOptions,\n {\n method: 'DELETE',\n }\n );\n\n return {\n getTags,\n addTag,\n updateTag,\n deleteTag,\n };\n};\n\nexport const tagAPI = getTagAPI();\n"],"names":[],"mappings":";;AAcO,MAAM,YAAY,CACvB,iBAAiC,IACjC,mBACG;AACH,QAAM,EAAE,WAAgB,KAAA,kBAAkB,iBAAoB,GAAA;AACxD,QAAA,oBAAoB,GAAG,UAAU;AAMvC,QAAM,UAAU,OACd,SACA,eAA+B,CAAA,MAE/B,MAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,IAAA;AAAA,EAEZ;AAMF,QAAM,SAAS,OAAO,KAAiB,eAA+B,CAAA,MACpE,MAAM;AAAA,IACJ,GAAG,iBAAiB;AAAA,IACpB;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,MACR,MAAM;AAAA,IAAA;AAAA,EAEV;AAMF,QAAM,YAAY,OAChB,OACA,KACA,eAA+B,OAE/B,MAAM;AAAA,IACJ,GAAG,iBAAiB,IAAI,KAAK;AAAA,IAC7B;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,MACR,MAAM;AAAA,IAAA;AAAA,EAEV;AAMF,QAAM,YAAY,OAChB,OAEA,eAA+B,CAAA,MAE/B,MAAM;AAAA,IACJ,GAAG,iBAAiB,IAAI,KAAK;AAAA,IAC7B;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,IAAA;AAAA,EAEZ;AAEK,SAAA;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF;AACF;AAEO,MAAM,SAAS,UAAU;"}
@@ -1,70 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const client = require("@intlayer/config/client");
4
- const libs_intlayerApi_fetcher = require("./fetcher.cjs");
5
- const getUserAPI = (authAPIOptions = {}, intlayerConfig) => {
6
- const { backendURL } = (intlayerConfig ?? client.getConfiguration()).editor;
7
- const USER_API_ROUTE = `${backendURL}/api/user`;
8
- const getUsers = async (filters, otherOptions = {}) => await libs_intlayerApi_fetcher.fetcher(
9
- USER_API_ROUTE,
10
- authAPIOptions,
11
- otherOptions,
12
- {
13
- params: filters
14
- }
15
- );
16
- const getUserById = async (userId, otherOptions = {}) => await libs_intlayerApi_fetcher.fetcher(
17
- `${USER_API_ROUTE}/${userId}`,
18
- authAPIOptions,
19
- otherOptions
20
- );
21
- const getUserByEmail = async (email, otherOptions = {}) => await libs_intlayerApi_fetcher.fetcher(
22
- `${USER_API_ROUTE}/email/${email}`,
23
- authAPIOptions,
24
- otherOptions
25
- );
26
- const getUserByAccount = async (providerAccountId, provider, otherOptions = {}) => await libs_intlayerApi_fetcher.fetcher(
27
- `${USER_API_ROUTE}/account/${provider}/${providerAccountId}`,
28
- authAPIOptions,
29
- otherOptions
30
- );
31
- const createUser = async (user, otherOptions = {}) => await libs_intlayerApi_fetcher.fetcher(
32
- `${USER_API_ROUTE}/`,
33
- authAPIOptions,
34
- otherOptions,
35
- {
36
- method: "POST",
37
- body: user
38
- }
39
- );
40
- const updateUser = async (user, otherOptions = {}) => await libs_intlayerApi_fetcher.fetcher(
41
- `${USER_API_ROUTE}`,
42
- authAPIOptions,
43
- otherOptions,
44
- {
45
- method: "PUT",
46
- body: user
47
- }
48
- );
49
- const deleteUser = async (userId, otherOptions = {}) => await libs_intlayerApi_fetcher.fetcher(
50
- `${USER_API_ROUTE}/${userId}`,
51
- authAPIOptions,
52
- otherOptions,
53
- {
54
- method: "DELETE"
55
- }
56
- );
57
- return {
58
- createUser,
59
- getUsers,
60
- getUserById,
61
- getUserByAccount,
62
- getUserByEmail,
63
- updateUser,
64
- deleteUser
65
- };
66
- };
67
- const userAPI = getUserAPI();
68
- exports.getUserAPI = getUserAPI;
69
- exports.userAPI = userAPI;
70
- //# sourceMappingURL=user.cjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"user.cjs","sources":["../../../src/libs/intlayer-api/user.ts"],"sourcesContent":["import type {\n CreateUserBody,\n CreateUserResult,\n GetUserByAccountParams,\n GetUserByAccountResult,\n GetUserByEmailParams,\n GetUserByEmailResult,\n GetUserByIdParams,\n GetUserByIdResult,\n GetUsersParams,\n GetUsersResult,\n UpdateUserBody,\n UpdateUserResult,\n} from '@intlayer/backend';\nimport { getConfiguration, type IntlayerConfig } from '@intlayer/config/client';\nimport { fetcher, type FetcherOptions } from './fetcher';\n\nexport const getUserAPI = (\n authAPIOptions: FetcherOptions = {},\n intlayerConfig?: IntlayerConfig\n) => {\n const { backendURL } = (intlayerConfig ?? getConfiguration()).editor;\n const USER_API_ROUTE = `${backendURL}/api/user`;\n\n /**\n * Retrieves a list of users based on filters and pagination.\n * @param filters - Filters and pagination options.\n * @returns List of users.\n */\n const getUsers = async (\n filters?: GetUsersParams,\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<GetUsersResult>(\n USER_API_ROUTE,\n authAPIOptions,\n otherOptions,\n {\n params: filters,\n }\n );\n\n /**\n * Retrieves a user by ID.\n * @param userId - User ID.\n * @returns User object.\n */\n const getUserById = async (\n userId: GetUserByIdParams['userId'],\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<GetUserByIdResult>(\n `${USER_API_ROUTE}/${userId}`,\n authAPIOptions,\n otherOptions\n );\n\n /**\n * Retrieves a user by email.\n * @param email - User email.\n * @returns User object.\n */\n const getUserByEmail = async (\n email: GetUserByEmailParams['email'],\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<GetUserByEmailResult>(\n `${USER_API_ROUTE}/email/${email}`,\n authAPIOptions,\n otherOptions\n );\n\n /**\n * Retrieves a user by account.\n * @param providerAccountId - The provider account ID.\n * @param provider - The provider of the account.\n */\n const getUserByAccount = async (\n providerAccountId: GetUserByAccountParams['providerAccountId'],\n provider: GetUserByAccountParams['provider'],\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<GetUserByAccountResult>(\n `${USER_API_ROUTE}/account/${provider}/${providerAccountId}`,\n authAPIOptions,\n otherOptions\n );\n\n /**\n * Creates a new user.\n * @param user - User credentials.\n * @returns User object.\n */\n const createUser = async (\n user: CreateUserBody,\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<CreateUserResult>(\n `${USER_API_ROUTE}/`,\n authAPIOptions,\n otherOptions,\n {\n method: 'POST',\n body: user,\n }\n );\n\n /**\n * Updates the user with the provided data.\n * @param user - Updated user data.\n * @returns User object.\n */\n const updateUser = async (\n user: UpdateUserBody,\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<UpdateUserResult>(\n `${USER_API_ROUTE}`,\n authAPIOptions,\n otherOptions,\n {\n method: 'PUT',\n body: user,\n }\n );\n\n /**\n * Deletes a user with the provided ID.\n * @param userId - User ID.\n * @returns User object.\n */\n const deleteUser = async (\n userId: string,\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<UpdateUserResult>(\n `${USER_API_ROUTE}/${userId}`,\n authAPIOptions,\n otherOptions,\n {\n method: 'DELETE',\n }\n );\n\n return {\n createUser,\n getUsers,\n getUserById,\n getUserByAccount,\n getUserByEmail,\n updateUser,\n deleteUser,\n };\n};\n\nexport const userAPI = getUserAPI();\n"],"names":["getConfiguration","fetcher"],"mappings":";;;;AAiBO,MAAM,aAAa,CACxB,iBAAiC,IACjC,mBACG;AACH,QAAM,EAAE,WAAgB,KAAA,kBAAkBA,OAAAA,iBAAoB,GAAA;AACxD,QAAA,iBAAiB,GAAG,UAAU;AAOpC,QAAM,WAAW,OACf,SACA,eAA+B,CAAA,MAE/B,MAAMC,yBAAA;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,IAAA;AAAA,EAEZ;AAOF,QAAM,cAAc,OAClB,QACA,eAA+B,CAAA,MAE/B,MAAMA,yBAAA;AAAA,IACJ,GAAG,cAAc,IAAI,MAAM;AAAA,IAC3B;AAAA,IACA;AAAA,EACF;AAOF,QAAM,iBAAiB,OACrB,OACA,eAA+B,CAAA,MAE/B,MAAMA,yBAAA;AAAA,IACJ,GAAG,cAAc,UAAU,KAAK;AAAA,IAChC;AAAA,IACA;AAAA,EACF;AAOF,QAAM,mBAAmB,OACvB,mBACA,UACA,eAA+B,OAE/B,MAAMA,yBAAA;AAAA,IACJ,GAAG,cAAc,YAAY,QAAQ,IAAI,iBAAiB;AAAA,IAC1D;AAAA,IACA;AAAA,EACF;AAOF,QAAM,aAAa,OACjB,MACA,eAA+B,CAAA,MAE/B,MAAMA,yBAAA;AAAA,IACJ,GAAG,cAAc;AAAA,IACjB;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,MACR,MAAM;AAAA,IAAA;AAAA,EAEV;AAOF,QAAM,aAAa,OACjB,MACA,eAA+B,CAAA,MAE/B,MAAMA,yBAAA;AAAA,IACJ,GAAG,cAAc;AAAA,IACjB;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,MACR,MAAM;AAAA,IAAA;AAAA,EAEV;AAOF,QAAM,aAAa,OACjB,QACA,eAA+B,CAAA,MAE/B,MAAMA,yBAAA;AAAA,IACJ,GAAG,cAAc,IAAI,MAAM;AAAA,IAC3B;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,IAAA;AAAA,EAEZ;AAEK,SAAA;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF;AACF;AAEO,MAAM,UAAU,WAAW;;;"}
@@ -1,22 +0,0 @@
1
- import { CreateUserBody, CreateUserResult, GetUserByAccountParams, GetUserByAccountResult, GetUserByEmailParams, GetUserByEmailResult, GetUserByIdParams, GetUserByIdResult, GetUsersParams, GetUsersResult, UpdateUserBody, UpdateUserResult } from '@intlayer/backend';
2
- import { IntlayerConfig } from '@intlayer/config/client';
3
- import { FetcherOptions } from './fetcher';
4
- export declare const getUserAPI: (authAPIOptions?: FetcherOptions, intlayerConfig?: IntlayerConfig) => {
5
- createUser: (user: CreateUserBody, otherOptions?: FetcherOptions) => Promise<CreateUserResult>;
6
- getUsers: (filters?: GetUsersParams, otherOptions?: FetcherOptions) => Promise<GetUsersResult>;
7
- getUserById: (userId: GetUserByIdParams["userId"], otherOptions?: FetcherOptions) => Promise<GetUserByIdResult>;
8
- getUserByAccount: (providerAccountId: GetUserByAccountParams["providerAccountId"], provider: GetUserByAccountParams["provider"], otherOptions?: FetcherOptions) => Promise<GetUserByAccountResult>;
9
- getUserByEmail: (email: GetUserByEmailParams["email"], otherOptions?: FetcherOptions) => Promise<GetUserByEmailResult>;
10
- updateUser: (user: UpdateUserBody, otherOptions?: FetcherOptions) => Promise<UpdateUserResult>;
11
- deleteUser: (userId: string, otherOptions?: FetcherOptions) => Promise<UpdateUserResult>;
12
- };
13
- export declare const userAPI: {
14
- createUser: (user: CreateUserBody, otherOptions?: FetcherOptions) => Promise<CreateUserResult>;
15
- getUsers: (filters?: GetUsersParams, otherOptions?: FetcherOptions) => Promise<GetUsersResult>;
16
- getUserById: (userId: GetUserByIdParams["userId"], otherOptions?: FetcherOptions) => Promise<GetUserByIdResult>;
17
- getUserByAccount: (providerAccountId: GetUserByAccountParams["providerAccountId"], provider: GetUserByAccountParams["provider"], otherOptions?: FetcherOptions) => Promise<GetUserByAccountResult>;
18
- getUserByEmail: (email: GetUserByEmailParams["email"], otherOptions?: FetcherOptions) => Promise<GetUserByEmailResult>;
19
- updateUser: (user: UpdateUserBody, otherOptions?: FetcherOptions) => Promise<UpdateUserResult>;
20
- deleteUser: (userId: string, otherOptions?: FetcherOptions) => Promise<UpdateUserResult>;
21
- };
22
- //# sourceMappingURL=user.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"user.d.ts","sourceRoot":"","sources":["../../../src/libs/intlayer-api/user.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,cAAc,EACd,gBAAgB,EAChB,sBAAsB,EACtB,sBAAsB,EACtB,oBAAoB,EACpB,oBAAoB,EACpB,iBAAiB,EACjB,iBAAiB,EACjB,cAAc,EACd,cAAc,EACd,cAAc,EACd,gBAAgB,EACjB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAoB,KAAK,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAChF,OAAO,EAAW,KAAK,cAAc,EAAE,MAAM,WAAW,CAAC;AAEzD,eAAO,MAAM,UAAU,oBACL,cAAc,mBACb,cAAc;uBA2EvB,cAAc,iBACN,cAAc;yBAjElB,cAAc,iBACV,cAAc;0BAiBpB,iBAAiB,CAAC,QAAQ,CAAC,iBACrB,cAAc;0CA6BT,sBAAsB,CAAC,mBAAmB,CAAC,YACpD,sBAAsB,CAAC,UAAU,CAAC,iBAC9B,cAAc;4BAjBrB,oBAAoB,CAAC,OAAO,CAAC,iBACtB,cAAc;uBAiDtB,cAAc,iBACN,cAAc;yBAkBpB,MAAM,iBACA,cAAc;CAoB/B,CAAC;AAEF,eAAO,MAAM,OAAO;uBA7DV,cAAc,iBACN,cAAc;yBAjElB,cAAc,iBACV,cAAc;0BAiBpB,iBAAiB,CAAC,QAAQ,CAAC,iBACrB,cAAc;0CA6BT,sBAAsB,CAAC,mBAAmB,CAAC,YACpD,sBAAsB,CAAC,UAAU,CAAC,iBAC9B,cAAc;4BAjBrB,oBAAoB,CAAC,OAAO,CAAC,iBACtB,cAAc;uBAiDtB,cAAc,iBACN,cAAc;yBAkBpB,MAAM,iBACA,cAAc;CAsBG,CAAC"}
@@ -1,70 +0,0 @@
1
- import { getConfiguration } from "@intlayer/config/client";
2
- import { fetcher } from "./fetcher.mjs";
3
- const getUserAPI = (authAPIOptions = {}, intlayerConfig) => {
4
- const { backendURL } = (intlayerConfig ?? getConfiguration()).editor;
5
- const USER_API_ROUTE = `${backendURL}/api/user`;
6
- const getUsers = async (filters, otherOptions = {}) => await fetcher(
7
- USER_API_ROUTE,
8
- authAPIOptions,
9
- otherOptions,
10
- {
11
- params: filters
12
- }
13
- );
14
- const getUserById = async (userId, otherOptions = {}) => await fetcher(
15
- `${USER_API_ROUTE}/${userId}`,
16
- authAPIOptions,
17
- otherOptions
18
- );
19
- const getUserByEmail = async (email, otherOptions = {}) => await fetcher(
20
- `${USER_API_ROUTE}/email/${email}`,
21
- authAPIOptions,
22
- otherOptions
23
- );
24
- const getUserByAccount = async (providerAccountId, provider, otherOptions = {}) => await fetcher(
25
- `${USER_API_ROUTE}/account/${provider}/${providerAccountId}`,
26
- authAPIOptions,
27
- otherOptions
28
- );
29
- const createUser = async (user, otherOptions = {}) => await fetcher(
30
- `${USER_API_ROUTE}/`,
31
- authAPIOptions,
32
- otherOptions,
33
- {
34
- method: "POST",
35
- body: user
36
- }
37
- );
38
- const updateUser = async (user, otherOptions = {}) => await fetcher(
39
- `${USER_API_ROUTE}`,
40
- authAPIOptions,
41
- otherOptions,
42
- {
43
- method: "PUT",
44
- body: user
45
- }
46
- );
47
- const deleteUser = async (userId, otherOptions = {}) => await fetcher(
48
- `${USER_API_ROUTE}/${userId}`,
49
- authAPIOptions,
50
- otherOptions,
51
- {
52
- method: "DELETE"
53
- }
54
- );
55
- return {
56
- createUser,
57
- getUsers,
58
- getUserById,
59
- getUserByAccount,
60
- getUserByEmail,
61
- updateUser,
62
- deleteUser
63
- };
64
- };
65
- const userAPI = getUserAPI();
66
- export {
67
- getUserAPI,
68
- userAPI
69
- };
70
- //# sourceMappingURL=user.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"user.mjs","sources":["../../../src/libs/intlayer-api/user.ts"],"sourcesContent":["import type {\n CreateUserBody,\n CreateUserResult,\n GetUserByAccountParams,\n GetUserByAccountResult,\n GetUserByEmailParams,\n GetUserByEmailResult,\n GetUserByIdParams,\n GetUserByIdResult,\n GetUsersParams,\n GetUsersResult,\n UpdateUserBody,\n UpdateUserResult,\n} from '@intlayer/backend';\nimport { getConfiguration, type IntlayerConfig } from '@intlayer/config/client';\nimport { fetcher, type FetcherOptions } from './fetcher';\n\nexport const getUserAPI = (\n authAPIOptions: FetcherOptions = {},\n intlayerConfig?: IntlayerConfig\n) => {\n const { backendURL } = (intlayerConfig ?? getConfiguration()).editor;\n const USER_API_ROUTE = `${backendURL}/api/user`;\n\n /**\n * Retrieves a list of users based on filters and pagination.\n * @param filters - Filters and pagination options.\n * @returns List of users.\n */\n const getUsers = async (\n filters?: GetUsersParams,\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<GetUsersResult>(\n USER_API_ROUTE,\n authAPIOptions,\n otherOptions,\n {\n params: filters,\n }\n );\n\n /**\n * Retrieves a user by ID.\n * @param userId - User ID.\n * @returns User object.\n */\n const getUserById = async (\n userId: GetUserByIdParams['userId'],\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<GetUserByIdResult>(\n `${USER_API_ROUTE}/${userId}`,\n authAPIOptions,\n otherOptions\n );\n\n /**\n * Retrieves a user by email.\n * @param email - User email.\n * @returns User object.\n */\n const getUserByEmail = async (\n email: GetUserByEmailParams['email'],\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<GetUserByEmailResult>(\n `${USER_API_ROUTE}/email/${email}`,\n authAPIOptions,\n otherOptions\n );\n\n /**\n * Retrieves a user by account.\n * @param providerAccountId - The provider account ID.\n * @param provider - The provider of the account.\n */\n const getUserByAccount = async (\n providerAccountId: GetUserByAccountParams['providerAccountId'],\n provider: GetUserByAccountParams['provider'],\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<GetUserByAccountResult>(\n `${USER_API_ROUTE}/account/${provider}/${providerAccountId}`,\n authAPIOptions,\n otherOptions\n );\n\n /**\n * Creates a new user.\n * @param user - User credentials.\n * @returns User object.\n */\n const createUser = async (\n user: CreateUserBody,\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<CreateUserResult>(\n `${USER_API_ROUTE}/`,\n authAPIOptions,\n otherOptions,\n {\n method: 'POST',\n body: user,\n }\n );\n\n /**\n * Updates the user with the provided data.\n * @param user - Updated user data.\n * @returns User object.\n */\n const updateUser = async (\n user: UpdateUserBody,\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<UpdateUserResult>(\n `${USER_API_ROUTE}`,\n authAPIOptions,\n otherOptions,\n {\n method: 'PUT',\n body: user,\n }\n );\n\n /**\n * Deletes a user with the provided ID.\n * @param userId - User ID.\n * @returns User object.\n */\n const deleteUser = async (\n userId: string,\n otherOptions: FetcherOptions = {}\n ) =>\n await fetcher<UpdateUserResult>(\n `${USER_API_ROUTE}/${userId}`,\n authAPIOptions,\n otherOptions,\n {\n method: 'DELETE',\n }\n );\n\n return {\n createUser,\n getUsers,\n getUserById,\n getUserByAccount,\n getUserByEmail,\n updateUser,\n deleteUser,\n };\n};\n\nexport const userAPI = getUserAPI();\n"],"names":[],"mappings":";;AAiBO,MAAM,aAAa,CACxB,iBAAiC,IACjC,mBACG;AACH,QAAM,EAAE,WAAgB,KAAA,kBAAkB,iBAAoB,GAAA;AACxD,QAAA,iBAAiB,GAAG,UAAU;AAOpC,QAAM,WAAW,OACf,SACA,eAA+B,CAAA,MAE/B,MAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,IAAA;AAAA,EAEZ;AAOF,QAAM,cAAc,OAClB,QACA,eAA+B,CAAA,MAE/B,MAAM;AAAA,IACJ,GAAG,cAAc,IAAI,MAAM;AAAA,IAC3B;AAAA,IACA;AAAA,EACF;AAOF,QAAM,iBAAiB,OACrB,OACA,eAA+B,CAAA,MAE/B,MAAM;AAAA,IACJ,GAAG,cAAc,UAAU,KAAK;AAAA,IAChC;AAAA,IACA;AAAA,EACF;AAOF,QAAM,mBAAmB,OACvB,mBACA,UACA,eAA+B,OAE/B,MAAM;AAAA,IACJ,GAAG,cAAc,YAAY,QAAQ,IAAI,iBAAiB;AAAA,IAC1D;AAAA,IACA;AAAA,EACF;AAOF,QAAM,aAAa,OACjB,MACA,eAA+B,CAAA,MAE/B,MAAM;AAAA,IACJ,GAAG,cAAc;AAAA,IACjB;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,MACR,MAAM;AAAA,IAAA;AAAA,EAEV;AAOF,QAAM,aAAa,OACjB,MACA,eAA+B,CAAA,MAE/B,MAAM;AAAA,IACJ,GAAG,cAAc;AAAA,IACjB;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,MACR,MAAM;AAAA,IAAA;AAAA,EAEV;AAOF,QAAM,aAAa,OACjB,QACA,eAA+B,CAAA,MAE/B,MAAM;AAAA,IACJ,GAAG,cAAc,IAAI,MAAM;AAAA,IAC3B;AAAA,IACA;AAAA,IACA;AAAA,MACE,QAAQ;AAAA,IAAA;AAAA,EAEZ;AAEK,SAAA;AAAA,IACL;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF;AACF;AAEO,MAAM,UAAU,WAAW;"}