@scalar/api-client 2.0.24 → 2.0.25

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 (166) hide show
  1. package/CHANGELOG.md +26 -0
  2. package/dist/components/AddressBar/AddressBar.vue.d.ts.map +1 -1
  3. package/dist/components/AddressBar/AddressBar.vue.js +2 -2
  4. package/dist/components/AddressBar/AddressBar.vue2.js +79 -83
  5. package/dist/components/AddressBar/AddressBarServer.vue.d.ts.map +1 -1
  6. package/dist/components/CodeInput/CodeInput.vue.d.ts +10 -0
  7. package/dist/components/CodeInput/CodeInput.vue.d.ts.map +1 -1
  8. package/dist/components/CodeInput/CodeInput.vue.js +3 -2
  9. package/dist/components/CodeInput/CodeInput.vue2.js +42 -37
  10. package/dist/components/CodeInput/codeDropdownWidget.d.ts +24 -0
  11. package/dist/components/CodeInput/codeDropdownWidget.d.ts.map +1 -0
  12. package/dist/components/CodeInput/codeDropdownWidget.js +110 -0
  13. package/dist/components/CodeInput/codeVariableWidget.d.ts +8 -0
  14. package/dist/components/CodeInput/codeVariableWidget.d.ts.map +1 -0
  15. package/dist/components/CodeInput/codeVariableWidget.js +124 -0
  16. package/dist/components/CommandPalette/CommandPaletteCollection.vue.d.ts +2 -15
  17. package/dist/components/CommandPalette/CommandPaletteCollection.vue.d.ts.map +1 -1
  18. package/dist/components/CommandPalette/CommandPaletteCollection.vue.js +51 -54
  19. package/dist/components/CommandPalette/CommandPaletteExample.vue.d.ts +4 -2
  20. package/dist/components/CommandPalette/CommandPaletteExample.vue.d.ts.map +1 -1
  21. package/dist/components/CommandPalette/CommandPaletteExample.vue.js +106 -92
  22. package/dist/components/CommandPalette/CommandPaletteFolder.vue.d.ts +2 -15
  23. package/dist/components/CommandPalette/CommandPaletteFolder.vue.d.ts.map +1 -1
  24. package/dist/components/CommandPalette/CommandPaletteFolder.vue.js +68 -74
  25. package/dist/components/CommandPalette/CommandPaletteImport.vue.d.ts +2 -15
  26. package/dist/components/CommandPalette/CommandPaletteImport.vue.d.ts.map +1 -1
  27. package/dist/components/CommandPalette/CommandPaletteImport.vue.js +56 -62
  28. package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts +2 -15
  29. package/dist/components/CommandPalette/CommandPaletteRequest.vue.d.ts.map +1 -1
  30. package/dist/components/CommandPalette/CommandPaletteRequest.vue.js +106 -99
  31. package/dist/components/CommandPalette/CommandPaletteWorkspace.vue.d.ts +7 -0
  32. package/dist/components/CommandPalette/CommandPaletteWorkspace.vue.d.ts.map +1 -0
  33. package/dist/components/CommandPalette/CommandPaletteWorkspace.vue.js +57 -0
  34. package/dist/components/CommandPalette/CommandPaletteWorkspace.vue2.js +4 -0
  35. package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts +50 -0
  36. package/dist/components/CommandPalette/TheCommandPalette.vue.d.ts.map +1 -0
  37. package/dist/components/CommandPalette/TheCommandPalette.vue.js +9 -0
  38. package/dist/components/CommandPalette/TheCommandPalette.vue2.js +198 -0
  39. package/dist/components/CommandPalette/index.d.ts +2 -0
  40. package/dist/components/CommandPalette/index.d.ts.map +1 -0
  41. package/dist/components/CommandPalette/index.js +4 -0
  42. package/dist/components/ContextBar.vue.js +4 -4
  43. package/dist/components/DataTable/DataTableInput.vue.d.ts +1 -1
  44. package/dist/components/DataTable/DataTableInput.vue.d.ts.map +1 -1
  45. package/dist/components/DataTable/DataTableInput.vue.js +3 -3
  46. package/dist/components/DataTable/DataTableInput.vue2.js +36 -49
  47. package/dist/components/SideNav/SideNav.vue.d.ts.map +1 -1
  48. package/dist/components/SideNav/SideNav.vue.js +26 -23
  49. package/dist/components/SideNav/SideNavLink.vue.d.ts +3 -2
  50. package/dist/components/SideNav/SideNavLink.vue.d.ts.map +1 -1
  51. package/dist/components/SideNav/SideNavLink.vue.js +5 -5
  52. package/dist/components/Sidebar/Sidebar.vue.d.ts +15 -2
  53. package/dist/components/Sidebar/Sidebar.vue.d.ts.map +1 -1
  54. package/dist/components/Sidebar/Sidebar.vue.js +14 -12
  55. package/dist/components/Sidebar/SidebarButton.vue.d.ts.map +1 -1
  56. package/dist/components/Sidebar/SidebarButton.vue.js +5 -5
  57. package/dist/components/TopNav/TopNav.vue.d.ts.map +1 -1
  58. package/dist/components/TopNav/TopNav.vue.js +2 -2
  59. package/dist/components/TopNav/TopNav.vue2.js +31 -28
  60. package/dist/components/TopNav/TopNavItem.vue.d.ts +7 -3
  61. package/dist/components/TopNav/TopNavItem.vue.d.ts.map +1 -1
  62. package/dist/components/TopNav/TopNavItem.vue.js +2 -2
  63. package/dist/components/TopNav/TopNavItem.vue2.js +16 -15
  64. package/dist/components/ViewLayout/ViewLayout.vue.d.ts.map +1 -1
  65. package/dist/components/ViewLayout/ViewLayout.vue.js +1 -1
  66. package/dist/components/ViewLayout/ViewLayoutCollapse.vue.d.ts.map +1 -1
  67. package/dist/components/ViewLayout/ViewLayoutCollapse.vue.js +2 -1
  68. package/dist/constants.d.ts +13 -7
  69. package/dist/constants.d.ts.map +1 -1
  70. package/dist/constants.js +4 -4
  71. package/dist/index.d.ts +2 -4
  72. package/dist/index.d.ts.map +1 -1
  73. package/dist/index.js +11 -16
  74. package/dist/layouts/App/ApiClientApp.vue.d.ts.map +1 -0
  75. package/dist/layouts/App/ApiClientApp.vue.js +72 -0
  76. package/dist/{App → layouts/App}/createApiClientApp.d.ts +1 -1
  77. package/dist/layouts/App/createApiClientApp.d.ts.map +1 -0
  78. package/dist/{App → layouts/App}/createApiClientApp.js +2 -2
  79. package/dist/layouts/App/index.d.ts.map +1 -0
  80. package/dist/{Modal → layouts/Modal}/ApiClientModal.vue.d.ts +1 -0
  81. package/dist/layouts/Modal/ApiClientModal.vue.d.ts.map +1 -0
  82. package/dist/{Modal → layouts/Modal}/ApiClientModal.vue.js +2 -2
  83. package/dist/layouts/Modal/api-client-modal.d.ts.map +1 -0
  84. package/dist/{Modal → layouts/Modal}/api-client-modal.js +2 -2
  85. package/dist/layouts/Modal/index.d.ts.map +1 -0
  86. package/dist/libs/eventBusses/command-palette.d.ts +14 -0
  87. package/dist/libs/eventBusses/command-palette.d.ts.map +1 -0
  88. package/dist/libs/eventBusses/command-palette.js +5 -0
  89. package/dist/libs/local-storage.d.ts +1 -1
  90. package/dist/libs/local-storage.d.ts.map +1 -1
  91. package/dist/libs/local-storage.js +19 -19
  92. package/dist/router.d.ts +5 -10
  93. package/dist/router.d.ts.map +1 -1
  94. package/dist/router.js +23 -19
  95. package/dist/store/topNav.d.ts +94 -82
  96. package/dist/store/topNav.d.ts.map +1 -1
  97. package/dist/store/topNav.js +21 -20
  98. package/dist/store/workspace.d.ts +314 -84
  99. package/dist/store/workspace.d.ts.map +1 -1
  100. package/dist/store/workspace.js +299 -220
  101. package/dist/style.css +1 -1
  102. package/dist/views/Collection/Collection.vue.d.ts.map +1 -1
  103. package/dist/views/Components/Schemas/Schemas.vue.d.ts.map +1 -1
  104. package/dist/views/Cookies/Cookies.vue.d.ts.map +1 -1
  105. package/dist/views/Cookies/Cookies.vue2.js +9 -12
  106. package/dist/views/Environment/Environment.vue.d.ts.map +1 -1
  107. package/dist/views/Environment/Environment.vue2.js +22 -25
  108. package/dist/views/Environment/EnvironmentVariableDropdown.vue.d.ts.map +1 -1
  109. package/dist/views/Environment/EnvironmentVariableDropdown.vue.js +38 -47
  110. package/dist/views/Request/Request.vue.d.ts.map +1 -1
  111. package/dist/views/Request/Request.vue.js +1 -1
  112. package/dist/views/Request/Request.vue2.js +122 -105
  113. package/dist/views/Request/RequestSection/RequestAuthDataTableInput.vue.d.ts +1 -1
  114. package/dist/views/Request/RequestSection/RequestAuthDataTableInput.vue.d.ts.map +1 -1
  115. package/dist/views/Request/RequestSection/RequestSection.vue.d.ts.map +1 -1
  116. package/dist/views/Request/RequestSection/RequestSection.vue.js +5 -4
  117. package/dist/views/Request/RequestSection/RequestTable.vue.d.ts.map +1 -1
  118. package/dist/views/Request/RequestSection/RequestTable.vue.js +1 -1
  119. package/dist/views/Request/RequestSection/RequestTable.vue2.js +19 -19
  120. package/dist/views/Request/RequestSection/RequestTableTooltip.vue.d.ts.map +1 -1
  121. package/dist/views/Request/RequestSection/RequestTableTooltip.vue.js +6 -5
  122. package/dist/views/Request/RequestSidebarItem.vue.d.ts.map +1 -1
  123. package/dist/views/Request/RequestSidebarItem.vue.js +2 -2
  124. package/dist/views/Request/RequestSidebarItem.vue2.js +78 -81
  125. package/dist/views/Request/RequestSidebarItemMenu.vue.d.ts.map +1 -1
  126. package/dist/views/Request/RequestSidebarItemMenu.vue.js +53 -33
  127. package/dist/views/Request/ResponseSection/ResponseSection.vue.d.ts.map +1 -1
  128. package/dist/views/Request/ResponseSection/ResponseSection.vue.js +6 -5
  129. package/dist/views/Request/components/OAuth2.vue.d.ts.map +1 -1
  130. package/dist/views/Request/components/OAuth2.vue.js +2 -0
  131. package/dist/{App.vue.d.ts → views/Request/components/WorkspaceDropdown.vue.d.ts} +1 -2
  132. package/dist/views/Request/components/WorkspaceDropdown.vue.d.ts.map +1 -0
  133. package/dist/views/Request/components/WorkspaceDropdown.vue.js +80 -0
  134. package/dist/views/Request/components/WorkspaceDropdown.vue2.js +4 -0
  135. package/dist/views/Request/components/index.d.ts +1 -0
  136. package/dist/views/Request/components/index.d.ts.map +1 -1
  137. package/dist/views/Request/components/index.js +4 -2
  138. package/dist/views/Servers/Servers.vue.d.ts.map +1 -1
  139. package/dist/views/Servers/Servers.vue2.js +12 -15
  140. package/package.json +20 -16
  141. package/dist/App/ApiClientApp.vue.d.ts.map +0 -1
  142. package/dist/App/ApiClientApp.vue.js +0 -56
  143. package/dist/App/createApiClientApp.d.ts.map +0 -1
  144. package/dist/App/index.d.ts.map +0 -1
  145. package/dist/App.vue.d.ts.map +0 -1
  146. package/dist/App.vue.js +0 -77
  147. package/dist/App.vue3.js +0 -5
  148. package/dist/Modal/ApiClientModal.vue.d.ts.map +0 -1
  149. package/dist/Modal/api-client-modal.d.ts.map +0 -1
  150. package/dist/Modal/index.d.ts.map +0 -1
  151. package/dist/components/AddressBar/AddressBarServer.vue.js +0 -113
  152. package/dist/components/AddressBar/AddressBarServer.vue2.js +0 -4
  153. package/dist/components/CommandPalette/CommandPalette.vue.d.ts +0 -17
  154. package/dist/components/CommandPalette/CommandPalette.vue.d.ts.map +0 -1
  155. package/dist/components/CommandPalette/CommandPalette.vue.js +0 -7
  156. package/dist/components/CommandPalette/CommandPalette.vue2.js +0 -185
  157. package/dist/main.d.ts +0 -2
  158. package/dist/main.d.ts.map +0 -1
  159. /package/dist/{App → layouts/App}/ApiClientApp.vue.d.ts +0 -0
  160. /package/dist/{App → layouts/App}/ApiClientApp.vue3.js +0 -0
  161. /package/dist/{App → layouts/App}/index.d.ts +0 -0
  162. /package/dist/{App → layouts/App}/index.js +0 -0
  163. /package/dist/{Modal → layouts/Modal}/ApiClientModal.vue2.js +0 -0
  164. /package/dist/{Modal → layouts/Modal}/api-client-modal.d.ts +0 -0
  165. /package/dist/{Modal → layouts/Modal}/index.d.ts +0 -0
  166. /package/dist/{Modal → layouts/Modal}/index.js +0 -0
@@ -0,0 +1 @@
1
+ {"version":3,"file":"api-client-modal.d.ts","sourceRoot":"","sources":["../../../src/layouts/Modal/api-client-modal.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAA;AAG/E,OAAO,EAAE,KAAK,aAAa,EAAe,MAAM,2BAA2B,CAAA;AAG3E,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAA;AAM7C,sDAAsD;AACtD,MAAM,MAAM,mBAAmB,GAAG;IAChC,yCAAyC;IACzC,IAAI,EAAE,iBAAiB,CAAA;IACvB,wCAAwC;IACxC,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,iCAAiC;IACjC,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB,kCAAkC;IAClC,WAAW,CAAC,EAAE,OAAO,CAAA;IACrB,4DAA4D;IAE5D,mFAAmF;IACnF,YAAY,CAAC,EACT,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,GACH,GAAG,CAAA;CACR,CAAA;AAED,MAAM,MAAM,iBAAiB,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,aAAa,CAAA;CAAE,CAAA;AAEvE,yCAAyC;AACzC,eAAO,MAAM,oBAAoB,OAE3B,WAAW,GAAG,IAAI,UAEd,mBAAmB;IAyEzB,+DAA+D;;IAE/D,mCAAmC;4BACX,mBAAmB;IAQ3C;;;OAGG;iCAC0B,MAAM;IAMnC;;;OAGG;uBACgB,mBAAmB;IAyEtC,uEAAuE;uBACpD,iBAAiB;IAapC,iCAAiC;qBAChB,iBAAiB;IAalC,8CAA8C;;;;;;;EAIjD,CAAA"}
@@ -1,5 +1,5 @@
1
- import { modalRouter as k } from "../router.js";
2
- import { useWorkspace as O } from "../store/workspace.js";
1
+ import { modalRouter as k } from "../../router.js";
2
+ import { useWorkspace as O } from "../../store/workspace.js";
3
3
  import { objectMerge as R } from "@scalar/oas-utils/helpers";
4
4
  import { getNestedValue as j } from "@scalar/object-utils/nested";
5
5
  import { createApp as C } from "vue";
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/layouts/Modal/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,cAAc,EAAE,MAAM,sBAAsB,CAAA;AAChE,cAAc,oBAAoB,CAAA"}
@@ -0,0 +1,14 @@
1
+ import type { CommandNames } from '../../components/CommandPalette/TheCommandPalette.vue.js';
2
+ export type CommandPaletteEvent = {
3
+ /** The command name which matches with the command palette */
4
+ commandName?: CommandNames;
5
+ /** Any extra metadata we want to pass to the command palettes */
6
+ metaData?: string;
7
+ };
8
+ /**
9
+ * Event bus for controlling the Command Palette
10
+ *
11
+ * @param commandName - the command name you wish to execute, leave empty for the full palette
12
+ */
13
+ export declare const commandPaletteBus: import("@vueuse/core").UseEventBusReturn<CommandPaletteEvent, any>;
14
+ //# sourceMappingURL=command-palette.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"command-palette.d.ts","sourceRoot":"","sources":["../../../src/libs/eventBusses/command-palette.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mDAAmD,CAAA;AAGrF,MAAM,MAAM,mBAAmB,GAAG;IAChC,8DAA8D;IAC9D,WAAW,CAAC,EAAE,YAAY,CAAA;IAC1B,iEAAiE;IACjE,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,CAAA;AAGD;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,oEAAiC,CAAA"}
@@ -0,0 +1,5 @@
1
+ import { useEventBus as t } from "@vueuse/core";
2
+ const e = Symbol(), m = t(e);
3
+ export {
4
+ m as commandPaletteBus
5
+ };
@@ -5,5 +5,5 @@ import type { useWorkspace } from '../store/workspace.js';
5
5
  *
6
6
  * Currently not working for workspace
7
7
  */
8
- export declare const loadAllResources: (mutators: ReturnType<typeof useWorkspace>, workspaceUid?: string) => void;
8
+ export declare const loadAllResources: (mutators: ReturnType<typeof useWorkspace>) => void;
9
9
  //# sourceMappingURL=local-storage.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"local-storage.d.ts","sourceRoot":"","sources":["../../src/libs/local-storage.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAcrD;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,aACjB,UAAU,CAAC,OAAO,YAAY,CAAC,gCAoE1C,CAAA"}
1
+ {"version":3,"file":"local-storage.d.ts","sourceRoot":"","sources":["../../src/libs/local-storage.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAcrD;;;;;GAKG;AACH,eAAO,MAAM,gBAAgB,aAAc,UAAU,CAAC,OAAO,YAAY,CAAC,SAkEzE,CAAA"}
@@ -1,36 +1,36 @@
1
1
  import { LS_KEYS as e } from "@scalar/object-utils/mutator-record";
2
- const h = (t, o = "default") => {
2
+ const N = (t) => {
3
3
  const {
4
- collectionMutators: s,
5
- cookieMutators: a,
6
- environmentMutators: r,
7
- folderMutators: c,
8
- requestExampleMutators: l,
9
- requestMutators: E,
10
- serverMutators: u,
4
+ collectionMutators: o,
5
+ cookieMutators: s,
6
+ environmentMutators: a,
7
+ folderMutators: r,
8
+ requestExampleMutators: c,
9
+ requestMutators: l,
10
+ serverMutators: E,
11
11
  securitySchemeMutators: S,
12
- workspaceMutators: O
12
+ workspaceMutators: u
13
13
  } = t;
14
14
  Object.values(
15
15
  JSON.parse(localStorage.getItem(e.COLLECTION) || "{}")
16
- ).forEach(s.rawAdd), Object.values(
16
+ ).forEach(o.rawAdd), Object.values(
17
17
  JSON.parse(localStorage.getItem(e.COOKIE) || "{}")
18
- ).forEach(a.add), Object.values(
18
+ ).forEach(s.add), Object.values(
19
19
  JSON.parse(localStorage.getItem(e.ENVIRONMENT) || "{}")
20
- ).forEach(r.add), Object.values(
20
+ ).forEach(a.add), Object.values(
21
21
  JSON.parse(localStorage.getItem(e.FOLDER) || "{}")
22
- ).forEach(c.rawAdd), Object.values(
22
+ ).forEach(r.rawAdd), Object.values(
23
23
  JSON.parse(localStorage.getItem(e.REQUEST_EXAMPLE) || "{}")
24
- ).forEach(l.rawAdd), Object.values(
24
+ ).forEach(c.rawAdd), Object.values(
25
25
  JSON.parse(localStorage.getItem(e.REQUEST) || "{}")
26
- ).forEach(E.rawAdd), Object.values(
26
+ ).forEach(l.rawAdd), Object.values(
27
27
  JSON.parse(localStorage.getItem(e.SERVER) || "{}")
28
- ).forEach(u.rawAdd), Object.values(
28
+ ).forEach(E.rawAdd), Object.values(
29
29
  JSON.parse(localStorage.getItem(e.SECURITY_SCHEME) || "{}")
30
30
  ).forEach(S.add), Object.values(
31
- JSON.parse(localStorage.getItem(e.WORKSPACE + o) || "{}")
32
- ).forEach(O.add);
31
+ JSON.parse(localStorage.getItem(e.WORKSPACE) || "{}")
32
+ ).forEach(u.rawAdd);
33
33
  };
34
34
  export {
35
- h as loadAllResources
35
+ N as loadAllResources
36
36
  };
package/dist/router.d.ts CHANGED
@@ -1,11 +1,11 @@
1
1
  export declare enum PathId {
2
2
  Request = "request",
3
- Example = "example",
3
+ Examples = "examples",
4
4
  Cookies = "cookies",
5
5
  Collection = "collection",
6
6
  Schema = "schema",
7
7
  Environment = "environment",
8
- Server = "server",
8
+ Servers = "servers",
9
9
  Workspace = "workspace"
10
10
  }
11
11
  /** Routes required by the client modal */
@@ -21,15 +21,10 @@ export declare const modalRoutes: ({
21
21
  name?: undefined;
22
22
  component?: undefined;
23
23
  } | {
24
- name: PathId;
24
+ name: string;
25
25
  path: string;
26
26
  component: () => Promise<typeof import("./views/Request/Request.vue.js")>;
27
27
  redirect?: undefined;
28
- } | {
29
- path: string;
30
- component: () => Promise<typeof import("./views/Request/Request.vue.js")>;
31
- redirect?: undefined;
32
- name?: undefined;
33
28
  })[];
34
29
  redirect?: undefined;
35
30
  })[];
@@ -43,10 +38,10 @@ export declare const activeRouterParams: import("vue").ComputedRef<{
43
38
  collection: string;
44
39
  environment: string;
45
40
  request: string;
46
- example: string;
41
+ examples: string;
47
42
  schema: string;
48
43
  cookies: string;
49
- server: string;
44
+ servers: string;
50
45
  workspace: string;
51
46
  }>;
52
47
  /** If we try to navigate to a entity UID that does not exist then we fallback to the default */
@@ -1 +1 @@
1
- {"version":3,"file":"router.d.ts","sourceRoot":"","sources":["../src/router.ts"],"names":[],"mappings":"AAQA,oBAAY,MAAM;IAChB,OAAO,YAAY;IACnB,OAAO,YAAY;IACnB,OAAO,YAAY;IACnB,UAAU,eAAe;IACzB,MAAM,WAAW;IACjB,WAAW,gBAAgB;IAC3B,MAAM,WAAW;IACjB,SAAS,cAAc;CACxB;AAuBD,0CAA0C;AAC1C,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;IAaI,CAAA;AAwE5B;;GAEG;AACH,eAAO,MAAM,MAAM,6BAGjB,CAAA;AAEF,sCAAsC;AACtC,eAAO,MAAM,WAAW,6BAGtB,CAAA;AAEF,eAAO,MAAM,kBAAkB;;;;;;;;;EA0B7B,CAAA;AAEF,gGAAgG;AAChG,wBAAgB,qBAAqB,CACnC,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,SAAS,QAmBtC"}
1
+ {"version":3,"file":"router.d.ts","sourceRoot":"","sources":["../src/router.ts"],"names":[],"mappings":"AAQA,oBAAY,MAAM;IAChB,OAAO,YAAY;IACnB,QAAQ,aAAa;IACrB,OAAO,YAAY;IACnB,UAAU,eAAe;IACzB,MAAM,WAAW;IACjB,WAAW,gBAAgB;IAC3B,OAAO,YAAY;IACnB,SAAS,cAAc;CACxB;AAwBD,0CAA0C;AAC1C,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;IAaI,CAAA;AA2E5B;;GAEG;AACH,eAAO,MAAM,MAAM,6BAGjB,CAAA;AAEF,sCAAsC;AACtC,eAAO,MAAM,WAAW,6BAGtB,CAAA;AAEF,eAAO,MAAM,kBAAkB;;;;;;;;;EA0B7B,CAAA;AAEF,gGAAgG;AAChG,wBAAgB,qBAAqB,CACnC,GAAG,EAAE,MAAM,EACX,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG,SAAS,QAmBtC"}
package/dist/router.js CHANGED
@@ -1,6 +1,6 @@
1
- import { computed as p } from "vue";
2
- import { createRouter as c, createWebHistory as n, createMemoryHistory as i } from "vue-router";
3
- var s = /* @__PURE__ */ ((e) => (e.Request = "request", e.Example = "example", e.Cookies = "cookies", e.Collection = "collection", e.Schema = "schema", e.Environment = "environment", e.Server = "server", e.Workspace = "workspace", e))(s || {});
1
+ import { computed as n } from "vue";
2
+ import { createRouter as u, createWebHistory as p, createMemoryHistory as m } from "vue-router";
3
+ var c = /* @__PURE__ */ ((e) => (e.Request = "request", e.Examples = "examples", e.Cookies = "cookies", e.Collection = "collection", e.Schema = "schema", e.Environment = "environment", e.Servers = "servers", e.Workspace = "workspace", e))(c || {});
4
4
  const l = [
5
5
  {
6
6
  path: "",
@@ -16,10 +16,11 @@ const l = [
16
16
  component: () => import("./views/Request/Request.vue.js")
17
17
  },
18
18
  {
19
- path: "request/:request/example/:example",
19
+ name: "requestExamples",
20
+ path: "request/:request/examples/:examples",
20
21
  component: () => import("./views/Request/Request.vue.js")
21
22
  }
22
- ], m = [
23
+ ], i = [
23
24
  {
24
25
  path: "/",
25
26
  redirect: "/workspace/default/request/default"
@@ -78,6 +79,7 @@ const l = [
78
79
  redirect: (e) => `${e.fullPath.replace(/\/$/, "")}/default`
79
80
  },
80
81
  {
82
+ name: "environment",
81
83
  path: "environment/:environment",
82
84
  component: () => import("./views/Environment/Environment.vue.js")
83
85
  },
@@ -86,6 +88,7 @@ const l = [
86
88
  redirect: (e) => `${e.fullPath.replace(/\/$/, "")}/default`
87
89
  },
88
90
  {
91
+ name: "cookies",
89
92
  path: "cookies/:cookies",
90
93
  component: () => import("./views/Cookies/Cookies.vue.js")
91
94
  },
@@ -94,29 +97,30 @@ const l = [
94
97
  redirect: (e) => `${e.fullPath.replace(/\/$/, "")}/default`
95
98
  },
96
99
  {
97
- path: "servers/:server",
100
+ name: "servers",
101
+ path: "servers/:servers",
98
102
  component: () => import("./views/Servers/Servers.vue.js")
99
103
  }
100
104
  ]
101
105
  }
102
- ], t = c({
103
- history: n(),
106
+ ], t = u({
107
+ history: p(),
104
108
  routes: f
105
- }), u = c({
106
- history: i(),
107
- routes: m
108
- }), v = p(() => {
109
+ }), s = u({
110
+ history: m(),
111
+ routes: i
112
+ }), v = n(() => {
109
113
  const e = {
110
114
  collection: "default",
111
115
  environment: "default",
112
116
  request: "default",
113
- example: "default",
117
+ examples: "default",
114
118
  schema: "default",
115
119
  cookies: "default",
116
- server: "default",
120
+ servers: "default",
117
121
  workspace: "default"
118
- }, a = u.currentRoute.value.matched.length ? u.currentRoute.value : t.currentRoute.value;
119
- return a && Object.values(s).forEach((r) => {
122
+ }, a = s.currentRoute.value.matched.length ? s.currentRoute.value : t.currentRoute.value;
123
+ return a && Object.values(c).forEach((r) => {
120
124
  a.params[r] && (e[r] = a.params[r]);
121
125
  }), e;
122
126
  });
@@ -132,10 +136,10 @@ function $(e, a) {
132
136
  });
133
137
  }
134
138
  export {
135
- s as PathId,
139
+ c as PathId,
136
140
  v as activeRouterParams,
137
141
  $ as fallbackMissingParams,
138
- u as modalRouter,
139
- m as modalRoutes,
142
+ s as modalRouter,
143
+ i as modalRoutes,
140
144
  t as router
141
145
  };