@scalar/api-client 2.17.7 → 2.18.0

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 (120) hide show
  1. package/CHANGELOG.md +74 -0
  2. package/dist/components/CommandPalette/CommandActionInput.vue.js +1 -1
  3. package/dist/components/Sidebar/Actions/DeleteSidebarListElement.vue.js +5 -5
  4. package/dist/components/Sidebar/Actions/EditSidebarListCollection.vue.js +18 -18
  5. package/dist/components/Sidebar/Actions/EditSidebarListElement.vue.js +7 -7
  6. package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.d.ts.map +1 -1
  7. package/dist/components/Sidebar/Actions/SidebarListElementForm.vue.js +44 -5
  8. package/dist/components/Sidebar/Actions/SidebarListElementForm.vue2.js +2 -44
  9. package/dist/style.css +1 -1
  10. package/dist/v2/blocks/operation-block/helpers/build-request.d.ts.map +1 -1
  11. package/dist/v2/blocks/operation-block/helpers/build-request.js +46 -51
  12. package/dist/v2/blocks/operation-block/helpers/get-environment-variables.d.ts +9 -0
  13. package/dist/v2/blocks/operation-block/helpers/get-environment-variables.d.ts.map +1 -0
  14. package/dist/v2/blocks/operation-block/helpers/get-environment-variables.js +7 -0
  15. package/dist/v2/blocks/operation-block/helpers/get-example.d.ts.map +1 -1
  16. package/dist/v2/blocks/operation-block/helpers/get-example.js +12 -10
  17. package/dist/v2/blocks/operation-block/helpers/get-server-url.d.ts +3 -0
  18. package/dist/v2/blocks/operation-block/helpers/get-server-url.d.ts.map +1 -0
  19. package/dist/v2/blocks/operation-block/helpers/get-server-url.js +12 -0
  20. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.d.ts.map +1 -1
  21. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.js +1 -1
  22. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue2.js +87 -65
  23. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.d.ts +18 -10
  24. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.d.ts.map +1 -1
  25. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuth2.vue.js +149 -126
  26. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesAddModal.vue.d.ts +20 -0
  27. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesAddModal.vue.d.ts.map +1 -0
  28. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesAddModal.vue.js +7 -0
  29. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesAddModal.vue2.js +76 -0
  30. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesInput.vue.d.ts +22 -5
  31. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesInput.vue.d.ts.map +1 -1
  32. package/dist/v2/blocks/scalar-auth-selector-block/components/OAuthScopesInput.vue.js +79 -64
  33. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.d.ts +16 -8
  34. package/dist/v2/blocks/scalar-auth-selector-block/components/RequestAuthTab.vue.d.ts.map +1 -1
  35. package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.d.ts +2 -2
  36. package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.d.ts.map +1 -1
  37. package/dist/v2/blocks/scalar-auth-selector-block/helpers/oauth.js +84 -82
  38. package/dist/v2/components/code-input/CodeInput.vue.d.ts +115 -144
  39. package/dist/v2/components/code-input/CodeInput.vue.d.ts.map +1 -1
  40. package/dist/v2/components/code-input/CodeInput.vue.js +2 -2
  41. package/dist/v2/components/code-input/CodeInput.vue2.js +120 -107
  42. package/dist/v2/components/data-table/DataTableInput.vue.d.ts +3 -3
  43. package/dist/v2/components/data-table/DataTableInput.vue.d.ts.map +1 -1
  44. package/dist/v2/components/data-table/DataTableInput.vue.js +2 -2
  45. package/dist/v2/components/data-table/DataTableInput.vue2.js +27 -27
  46. package/dist/v2/components/data-table/DataTableInputSelect.vue.d.ts +3 -2
  47. package/dist/v2/components/data-table/DataTableInputSelect.vue.d.ts.map +1 -1
  48. package/dist/v2/components/data-table/DataTableInputSelect.vue.js +42 -39
  49. package/dist/v2/components/forms/ConfirmationForm.vue.d.ts.map +1 -1
  50. package/dist/v2/components/forms/ConfirmationForm.vue.js +43 -5
  51. package/dist/v2/components/forms/ConfirmationForm.vue2.js +2 -43
  52. package/dist/v2/components/modals/DeleteModal.vue.js +11 -11
  53. package/dist/v2/components/sidebar/Sidebar.vue.d.ts +5 -3
  54. package/dist/v2/components/sidebar/Sidebar.vue.d.ts.map +1 -1
  55. package/dist/v2/components/sidebar/SidebarMenu.vue.d.ts +5 -3
  56. package/dist/v2/components/sidebar/SidebarMenu.vue.d.ts.map +1 -1
  57. package/dist/v2/components/sidebar/SidebarMenu.vue.js +25 -30
  58. package/dist/v2/features/app/App.vue.d.ts.map +1 -1
  59. package/dist/v2/features/app/App.vue.js +89 -141
  60. package/dist/v2/features/app/app-events.d.ts +22 -0
  61. package/dist/v2/features/app/app-events.d.ts.map +1 -0
  62. package/dist/v2/features/app/app-events.js +136 -0
  63. package/dist/v2/features/app/app-state.d.ts +135 -0
  64. package/dist/v2/features/app/app-state.d.ts.map +1 -0
  65. package/dist/v2/features/app/app-state.js +316 -0
  66. package/dist/v2/features/app/components/AppSidebar.vue.d.ts +6 -3
  67. package/dist/v2/features/app/components/AppSidebar.vue.d.ts.map +1 -1
  68. package/dist/v2/features/app/components/AppSidebar.vue.js +3 -3
  69. package/dist/v2/features/app/components/AppSidebar.vue2.js +4 -4
  70. package/dist/v2/features/app/components/DesktopTabs.vue.d.ts +4 -2
  71. package/dist/v2/features/app/components/DesktopTabs.vue.d.ts.map +1 -1
  72. package/dist/v2/features/app/components/DesktopTabs.vue.js +25 -22
  73. package/dist/v2/features/app/components/WebTopNav.vue.d.ts +9 -5
  74. package/dist/v2/features/app/components/WebTopNav.vue.d.ts.map +1 -1
  75. package/dist/v2/features/app/helpers/create-api-client-app.d.ts +62 -1
  76. package/dist/v2/features/app/helpers/create-api-client-app.d.ts.map +1 -1
  77. package/dist/v2/features/app/helpers/create-api-client-app.js +14 -10
  78. package/dist/v2/features/app/helpers/routes.d.ts +5 -2
  79. package/dist/v2/features/app/helpers/routes.d.ts.map +1 -1
  80. package/dist/v2/features/collection/WorkspaceCollection.vue.js +7 -7
  81. package/dist/v2/features/collection/components/Form.vue.d.ts +1 -1
  82. package/dist/v2/features/collection/components/Form.vue.d.ts.map +1 -1
  83. package/dist/v2/features/collection/components/Servers.vue.d.ts.map +1 -1
  84. package/dist/v2/features/modal/Modal.vue.d.ts.map +1 -1
  85. package/dist/v2/features/modal/Modal.vue.js +2 -2
  86. package/dist/v2/features/modal/Modal.vue2.js +40 -41
  87. package/dist/v2/features/operation/Operation.vue.d.ts.map +1 -1
  88. package/dist/v2/features/operation/Operation.vue.js +38 -28
  89. package/dist/v2/features/operation/helpers/combine-params.d.ts +4 -0
  90. package/dist/v2/features/operation/helpers/combine-params.d.ts.map +1 -0
  91. package/dist/v2/features/operation/helpers/combine-params.js +13 -0
  92. package/dist/v2/features/operation/index.d.ts +1 -0
  93. package/dist/v2/features/operation/index.d.ts.map +1 -1
  94. package/dist/v2/features/operation/index.js +10 -8
  95. package/dist/v2/features/settings/DocumentSettings.vue.d.ts.map +1 -1
  96. package/dist/v2/features/settings/DocumentSettings.vue.js +104 -5
  97. package/dist/v2/features/settings/DocumentSettings.vue2.js +2 -104
  98. package/dist/v2/helpers/get-tab-details.d.ts +2 -2
  99. package/dist/v2/helpers/get-tab-details.d.ts.map +1 -1
  100. package/dist/views/Collection/CollectionSettings.vue.d.ts.map +1 -1
  101. package/dist/views/Collection/CollectionSettings.vue.js +1 -4
  102. package/dist/views/Collection/CollectionSettings.vue2.js +5 -5
  103. package/dist/views/Environment/EnvironmentColorModal.vue.js +6 -6
  104. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
  105. package/package.json +17 -17
  106. package/dist/v2/features/app/hooks/use-app-sidebar.d.ts +0 -40
  107. package/dist/v2/features/app/hooks/use-app-sidebar.d.ts.map +0 -1
  108. package/dist/v2/features/app/hooks/use-app-sidebar.js +0 -134
  109. package/dist/v2/features/app/hooks/use-sync-path.d.ts +0 -11
  110. package/dist/v2/features/app/hooks/use-sync-path.d.ts.map +0 -1
  111. package/dist/v2/features/app/hooks/use-sync-path.js +0 -52
  112. package/dist/v2/features/app/hooks/use-tabs.d.ts +0 -31
  113. package/dist/v2/features/app/hooks/use-tabs.d.ts.map +0 -1
  114. package/dist/v2/features/app/hooks/use-tabs.js +0 -44
  115. package/dist/v2/features/app/hooks/use-workspace-client-app-events.d.ts +0 -18
  116. package/dist/v2/features/app/hooks/use-workspace-client-app-events.d.ts.map +0 -1
  117. package/dist/v2/features/app/hooks/use-workspace-client-app-events.js +0 -156
  118. package/dist/v2/features/app/hooks/use-workspace-selector.d.ts +0 -28
  119. package/dist/v2/features/app/hooks/use-workspace-selector.d.ts.map +0 -1
  120. package/dist/v2/features/app/hooks/use-workspace-selector.js +0 -81
@@ -4,7 +4,6 @@ import type { WorkspaceEventBus } from '@scalar/workspace-store/events';
4
4
  import type { XScalarEnvironment } from '@scalar/workspace-store/schemas/extensions/document/x-scalar-environments';
5
5
  import type { WorkspaceDocument } from '@scalar/workspace-store/schemas/workspace';
6
6
  import type { MergedSecuritySchemes } from '../../../../v2/blocks/scalar-auth-selector-block/helpers/merge-auth-config.js';
7
- import type { Workspace } from '../../../../v2/features/app/hooks/use-workspace-selector.js';
8
7
  import type { ClientPlugin } from '../../../../v2/helpers/plugins.js';
9
8
  import type { ClientLayout } from '../../../../v2/types/layout';
10
9
  /** These props are provided at the route level */
@@ -19,7 +18,10 @@ export type RouteProps = {
19
18
  environment: XScalarEnvironment;
20
19
  securitySchemes: MergedSecuritySchemes;
21
20
  workspaceStore: WorkspaceStore;
22
- activeWorkspace: Workspace;
21
+ activeWorkspace: {
22
+ id: string;
23
+ label: string;
24
+ };
23
25
  plugins: ClientPlugin[];
24
26
  };
25
27
  /** When in the collections pages */
@@ -30,6 +32,7 @@ export type CollectionProps = RouteProps & ({
30
32
  collectionType: 'workspace';
31
33
  document: null;
32
34
  });
35
+ export type ScalarClientAppRouteParams = 'workspaceSlug' | 'documentSlug' | 'pathEncoded' | 'method' | 'exampleName';
33
36
  /** Routes for the API client app and web, the same as modal + workspace routes */
34
37
  export declare const ROUTES: ({
35
38
  path: string;
@@ -1 +1 @@
1
- {"version":3,"file":"routes.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/app/helpers/routes.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mCAAmC,CAAA;AACnE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAA;AACpE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAA;AACvE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,2EAA2E,CAAA;AACnH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2CAA2C,CAAA;AAGlF,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,kEAAkE,CAAA;AAC7G,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gDAAgD,CAAA;AAU/E,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AAExD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAErD,kDAAkD;AAClD,MAAM,MAAM,UAAU,GAAG;IACvB,YAAY,EAAE,MAAM,CAAA;IACpB,QAAQ,EAAE,iBAAiB,GAAG,IAAI,CAAA;IAClC,QAAQ,EAAE,iBAAiB,CAAA;IAC3B,MAAM,EAAE,YAAY,CAAA;IACpB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,UAAU,CAAA;IACnB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,WAAW,EAAE,kBAAkB,CAAA;IAC/B,eAAe,EAAE,qBAAqB,CAAA;IACtC,cAAc,EAAE,cAAc,CAAA;IAC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EAAE,MAAM,CAAA;IACpB,QAAQ,EAAE,iBAAiB,GAAG,IAAI,CAAA;IAClC,QAAQ,EAAE,iBAAiB,CAAA;IAC3B,MAAM,EAAE,YAAY,CAAA;IACpB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,MAAM,CAAC,EAAE,UAAU,CAAA;IACnB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,WAAW,EAAE,kBAAkB,CAAA;IAC/B,eAAe,EAAE,qBAAqB,CAAA;IACtC,cAAc,EAAE,cAAc,CAAA;IAC9B,eAAe,EAAE;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAA;IAC9C,OAAO,EAAE,YAAY,EAAE,CAAA;CAGxB,CAAA;AAED,oCAAoC;AACpC,MAAM,MAAM,eAAe,GAAG,UAAU,GACtC,CACI;IACE,cAAc,EAAE,UAAU,CAAA;IAC1B,QAAQ,EAAE,iBAAiB,CAAA;CAC5B,GACD;IACE,cAAc,EAAE,WAAW,CAAA;IAC3B,QAAQ,EAAE,IAAI,CAAA;CACf,CACJ,CAAA;AAEH,MAAM,MAAM,0BAA0B,GAAG,eAAe,GAAG,cAAc,GAAG,aAAa,GAAG,QAAQ,GAAG,aAAa,CAAA;AAEpH,kFAAkF;AAClF,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;oCAZK,UAAU;8BAChB,iBAAiB;;oCAGX,WAAW;8BACjB,IAAI;;oCALE,UAAU;8BAChB,iBAAiB;;oCAGX,WAAW;8BACjB,IAAI;;;;;;;;;;;;;;;gCALE,UAAU;0BAChB,iBAAiB;;gCAGX,WAAW;0BACjB,IAAI;;gCALE,UAAU;0BAChB,iBAAiB;;gCAGX,WAAW;0BACjB,IAAI;;;;;;;;;IA0GM,CAAA"}
@@ -1,5 +1,5 @@
1
- import { defineComponent as l, createElementBlock as r, openBlock as n, createElementVNode as e, createVNode as t, unref as s, toDisplayString as i, mergeProps as m } from "vue";
2
- import { ScalarIconGlobe as p } from "@scalar/icons";
1
+ import { defineComponent as l, createElementBlock as r, openBlock as i, createElementVNode as e, createVNode as t, unref as s, toDisplayString as n, mergeProps as p } from "vue";
2
+ import { ScalarIconGlobe as m } from "@scalar/icons";
3
3
  import { RouterView as d } from "vue-router";
4
4
  import u from "./components/Tabs.vue.js";
5
5
  const _ = { class: "custom-scroll h-full" }, f = { class: "w-full md:mx-auto md:max-w-[720px]" }, x = ["aria-label"], h = { class: "group relative ml-1.25" }, v = { class: "text-c-1 flex h-8 items-center" }, k = { class: "px-1.5 py-8" }, w = {}, B = /* @__PURE__ */ l({
@@ -21,20 +21,20 @@ const _ = { class: "custom-scroll h-full" }, f = { class: "w-full md:mx-auto md:
21
21
  },
22
22
  setup(a) {
23
23
  const c = a;
24
- return (o, g) => (n(), r("div", _, [
24
+ return (o, b) => (i(), r("div", _, [
25
25
  e("div", f, [
26
26
  e("div", {
27
- "aria-label": `title: ${o.activeWorkspace.name}`,
27
+ "aria-label": `title: ${o.activeWorkspace.label}`,
28
28
  class: "mx-auto flex h-fit w-full flex-col gap-2 pt-6 pb-3 md:mx-auto md:max-w-[720px]"
29
29
  }, [
30
- t(s(p), { class: "text-c-2 size-6" }),
30
+ t(s(m), { class: "text-c-2 size-6" }),
31
31
  e("div", h, [
32
- e("span", v, i(o.activeWorkspace.name), 1)
32
+ e("span", v, n(o.activeWorkspace.label), 1)
33
33
  ])
34
34
  ], 8, x),
35
35
  t(u, { type: "workspace" }),
36
36
  e("div", k, [
37
- t(s(d), m(c, { collectionType: "workspace" }), null, 16)
37
+ t(s(d), p(c, { collectionType: "workspace" }), null, 16)
38
38
  ])
39
39
  ])
40
40
  ]));
@@ -7,7 +7,7 @@ type __VLS_Props = {
7
7
  placeholder: string;
8
8
  }[];
9
9
  data: Record<string, any>;
10
- onUpdate: (key: string, value: string) => void;
10
+ onUpdate: (key: string, value: string | number) => void;
11
11
  environment: XScalarEnvironment;
12
12
  };
13
13
  declare var __VLS_5: {};
@@ -1 +1 @@
1
- {"version":3,"file":"Form.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/collection/components/Form.vue"],"names":[],"mappings":"AA0EA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,2EAA2E,CAAA;AAQnH,KAAK,WAAW,GAAG;IACjB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,OAAO,EAAE;QACP,GAAG,EAAE,MAAM,CAAA;QACX,KAAK,EAAE,MAAM,CAAA;QACb,WAAW,EAAE,MAAM,CAAA;KACpB,EAAE,CAAA;IACH,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IACzB,QAAQ,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IAC9C,WAAW,EAAE,kBAAkB,CAAA;CAChC,CAAC;AA4IF,QAAA,IAAI,OAAO,IAAW,CAAE;AACxB,KAAK,WAAW,GAAG,EAAE,GACnB;IAAE,KAAK,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,OAAO,KAAK,GAAG,CAAA;CAAE,CAAC;AAyB7C,QAAA,MAAM,eAAe,kSAMnB,CAAC;wBACkB,eAAe,CAAC,OAAO,eAAe,EAAE,WAAW,CAAC;AAAzE,wBAA0E;AAQ1E,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"Form.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/collection/components/Form.vue"],"names":[],"mappings":"AA0EA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,2EAA2E,CAAA;AAQnH,KAAK,WAAW,GAAG;IACjB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,OAAO,EAAE;QACP,GAAG,EAAE,MAAM,CAAA;QACX,KAAK,EAAE,MAAM,CAAA;QACb,WAAW,EAAE,MAAM,CAAA;KACpB,EAAE,CAAA;IACH,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IACzB,QAAQ,EAAE,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,KAAK,IAAI,CAAA;IACvD,WAAW,EAAE,kBAAkB,CAAA;CAChC,CAAC;AA4IF,QAAA,IAAI,OAAO,IAAW,CAAE;AACxB,KAAK,WAAW,GAAG,EAAE,GACnB;IAAE,KAAK,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,OAAO,KAAK,GAAG,CAAA;CAAE,CAAC;AAyB7C,QAAA,MAAM,eAAe,kSAMnB,CAAC;wBACkB,eAAe,CAAC,OAAO,eAAe,EAAE,WAAW,CAAC;AAAzE,wBAA0E;AAQ1E,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"Servers.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/collection/components/Servers.vue"],"names":[],"mappings":";;;;;;;;;;;;;AAqjBA,wBAMG"}
1
+ {"version":3,"file":"Servers.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/collection/components/Servers.vue"],"names":[],"mappings":";;;;;;;;;;;;;AA6jBA,wBAMG"}
@@ -1 +1 @@
1
- {"version":3,"file":"Modal.vue.d.ts","sourceRoot":"","sources":["../../../../src/v2/features/modal/Modal.vue"],"names":[],"mappings":"AAyYA,OAAO,EAGL,KAAK,UAAU,EAChB,MAAM,oBAAoB,CAAA;AAC3B,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mCAAmC,CAAA;AACnE,OAAO,KAAK,EAAE,4BAA4B,EAAE,MAAM,6BAA6B,CAAA;AAE/E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAA;AACpE,OAAO,EAAE,KAAK,iBAA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/* @__PURE__ */ t(o, [["__scopeId", "data-v-f2ee8eaf"]]);
4
+ const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-433595c5"]]);
5
5
  export {
6
- r as default
6
+ p as default
7
7
  };
@@ -1,24 +1,23 @@
1
- import { defineComponent as I, ref as h, useId as N, watch as D, nextTick as E, onBeforeMount as F, onBeforeUnmount as U, computed as d, toValue as V, withDirectives as w, createElementBlock as u, openBlock as c, createElementVNode as i, unref as o, createVNode as l, withCtx as x, vShow as k } from "vue";
1
+ import { defineComponent as I, ref as h, useId as N, watch as D, nextTick as E, onBeforeMount as F, onBeforeUnmount as U, computed as u, toValue as V, withDirectives as w, createElementBlock as r, openBlock as c, createElementVNode as i, unref as o, createVNode as l, withCtx as x, vShow as k } from "vue";
2
2
  import { addScalarClassesToHeadless as A, ScalarTeleportRoot as $ } from "@scalar/components";
3
- import { ScalarToasts as M } from "@scalar/use-toasts";
4
- import { useFocusTrap as H } from "@vueuse/integrations/useFocusTrap";
5
- import { mergeAuthConfig as L } from "../../blocks/scalar-auth-selector-block/helpers/merge-auth-config.js";
3
+ import { ScalarToasts as H } from "@scalar/use-toasts";
4
+ import { useFocusTrap as L } from "@vueuse/integrations/useFocusTrap";
5
+ import { mergeAuthConfig as M } from "../../blocks/scalar-auth-selector-block/helpers/merge-auth-config.js";
6
6
  import z from "../operation/Operation.vue.js";
7
7
  import { getActiveEnvironment as O } from "../../helpers/get-active-environment.js";
8
- import { useColorMode as R } from "../../hooks/use-color-mode.js";
9
- import { useGlobalHotKeys as j } from "../../hooks/use-global-hot-keys.js";
10
- import { useScrollLock as q } from "../../hooks/use-scroll-lock.js";
11
- import { useWorkspaceClientModalEvents as G } from "./hooks/use-workspace-client-modal-events.js";
12
- import K from "../../components/sidebar/SidebarToggle.vue.js";
13
- import P from "../../components/sidebar/Sidebar.vue.js";
14
- const J = { class: "scalar scalar-app" }, Q = { class: "scalar-container" }, X = ["id"], Y = {
8
+ import { useGlobalHotKeys as R } from "../../hooks/use-global-hot-keys.js";
9
+ import { useScrollLock as j } from "../../hooks/use-scroll-lock.js";
10
+ import { useWorkspaceClientModalEvents as q } from "./hooks/use-workspace-client-modal-events.js";
11
+ import G from "../../components/sidebar/SidebarToggle.vue.js";
12
+ import K from "../../components/sidebar/Sidebar.vue.js";
13
+ const P = { class: "scalar scalar-app" }, J = { class: "scalar-container" }, Q = ["id"], X = {
15
14
  key: 0,
16
15
  class: "relative flex flex-1"
17
- }, Z = {
16
+ }, Y = {
18
17
  key: 1,
19
18
  class: "flex h-full w-full items-center justify-center"
20
- }, _ = {}, fe = /* @__PURE__ */ I({
21
- ..._,
19
+ }, Z = {}, ce = /* @__PURE__ */ I({
20
+ ...Z,
22
21
  __name: "Modal",
23
22
  props: {
24
23
  workspaceStore: {},
@@ -33,50 +32,50 @@ const J = { class: "scalar scalar-app" }, Q = { class: "scalar-container" }, X =
33
32
  options: {}
34
33
  },
35
34
  setup(t, { expose: b }) {
36
- typeof window < "u" && (window.dataDumpWorkspace = () => t.workspaceStore), R({ workspaceStore: t.workspaceStore });
35
+ typeof window < "u" && (window.dataDumpWorkspace = () => t.workspaceStore);
37
36
  const m = {
38
- name: "default",
37
+ label: "default",
39
38
  id: "default"
40
39
  }, s = h(!1);
41
- G({
40
+ q({
42
41
  eventBus: t.eventBus,
43
42
  document: t.document,
44
43
  workspaceStore: t.workspaceStore,
45
44
  isSidebarOpen: s,
46
45
  sidebarState: t.sidebarState,
47
46
  modalState: t.modalState
48
- }), j(t.eventBus, "modal");
49
- const f = h(null), v = N(), { activate: y, deactivate: B } = H(f, {
47
+ }), R(t.eventBus, "modal");
48
+ const v = h(null), f = N(), { activate: y, deactivate: B } = L(v, {
50
49
  allowOutsideClick: !0,
51
- fallbackFocus: `#${v}`
50
+ fallbackFocus: `#${f}`
52
51
  }), p = () => {
53
52
  B(), t.eventBus.emit("operation:cancel:request");
54
- }, g = q(() => typeof window < "u" ? window.document.body : null);
53
+ }, g = j(() => typeof window < "u" ? window.document.body : null);
55
54
  D(
56
55
  () => t.modalState.open,
57
56
  (e) => {
58
57
  g.value = e, e ? y({ checkCanFocusTrap: () => E() }) : p();
59
58
  }
60
59
  ), F(() => A()), U(() => p());
61
- const C = 288, r = d(
62
- () => t.workspaceStore?.workspace?.["x-scalar-sidebar-width"] ?? C
63
- ), T = (e) => t.workspaceStore?.update("x-scalar-sidebar-width", e), S = d(
60
+ const T = 288, d = u(
61
+ () => t.workspaceStore?.workspace?.["x-scalar-sidebar-width"] ?? T
62
+ ), C = (e) => t.workspaceStore?.update("x-scalar-sidebar-width", e), S = u(
64
63
  () => O(t.workspaceStore, t.document.value)
65
- ), W = d(
66
- () => L(
64
+ ), W = u(
65
+ () => M(
67
66
  t.document.value?.components?.securitySchemes,
68
67
  V(t.options)?.authentication?.securitySchemes
69
68
  )
70
69
  );
71
70
  return b({
72
- sidebarWidth: r,
71
+ sidebarWidth: d,
73
72
  environment: S
74
- }), (e, a) => w((c(), u("div", J, [
75
- i("div", Q, [
73
+ }), (e, a) => w((c(), r("div", P, [
74
+ i("div", J, [
76
75
  i("div", {
77
- id: o(v),
76
+ id: o(f),
78
77
  ref_key: "client",
79
- ref: f,
78
+ ref: v,
80
79
  "aria-label": "API Client",
81
80
  "aria-modal": "true",
82
81
  class: "scalar-app-layout scalar-client flex",
@@ -85,18 +84,18 @@ const J = { class: "scalar scalar-app" }, Q = { class: "scalar-container" }, X =
85
84
  }, [
86
85
  l(o($), null, {
87
86
  default: x(() => [
88
- l(o(M)),
89
- e.document.value && e.path?.value && e.method?.value ? (c(), u("main", Y, [
90
- l(o(K), {
87
+ l(o(H)),
88
+ e.document.value && e.path?.value && e.method?.value ? (c(), r("main", X, [
89
+ l(o(G), {
91
90
  modelValue: s.value,
92
91
  "onUpdate:modelValue": a[0] || (a[0] = (n) => s.value = n),
93
92
  class: "absolute top-2 left-3 z-[10001]"
94
93
  }, null, 8, ["modelValue"]),
95
- w(l(o(P), {
96
- sidebarWidth: r.value,
94
+ w(l(o(K), {
95
+ sidebarWidth: d.value,
97
96
  "onUpdate:sidebarWidth": [
98
- a[1] || (a[1] = (n) => r.value = n),
99
- T
97
+ a[1] || (a[1] = (n) => d.value = n),
98
+ C
100
99
  ],
101
100
  activeWorkspace: m,
102
101
  class: "z-[10000] h-full max-md:absolute! max-md:w-full!",
@@ -125,13 +124,13 @@ const J = { class: "scalar scalar-app" }, Q = { class: "scalar-container" }, X =
125
124
  securitySchemes: W.value,
126
125
  workspaceStore: e.workspaceStore
127
126
  }, null, 8, ["document", "documentSlug", "environment", "eventBus", "exampleName", "method", "path", "plugins", "securitySchemes", "workspaceStore"])
128
- ])) : (c(), u("div", Z, [...a[3] || (a[3] = [
127
+ ])) : (c(), r("div", Y, [...a[3] || (a[3] = [
129
128
  i("span", { class: "text-c-3" }, "No document selected", -1)
130
129
  ])]))
131
130
  ]),
132
131
  _: 1
133
132
  })
134
- ], 8, X),
133
+ ], 8, Q),
135
134
  i("div", {
136
135
  class: "scalar-app-exit",
137
136
  onClick: a[2] || (a[2] = (n) => e.modalState.hide())
@@ -143,5 +142,5 @@ const J = { class: "scalar scalar-app" }, Q = { class: "scalar-container" }, X =
143
142
  }
144
143
  });
145
144
  export {
146
- fe as default
145
+ ce as default
147
146
  };
@@ -1 +1 @@
1
- {"version":3,"file":"Operation.vue.d.ts","sourceRoot":"","sources":["../../../../src/v2/features/operation/Operation.vue"],"names":[],"mappings":"AA8JA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kCAAkC,CAAA;AAMlE;;;;;;;GAOG;;AACH,wBAwNC"}
1
+ {"version":3,"file":"Operation.vue.d.ts","sourceRoot":"","sources":["../../../../src/v2/features/operation/Operation.vue"],"names":[],"mappings":"AA6KA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kCAAkC,CAAA;AAMlE;;;;;;;GAOG;;AACH,wBAuOC"}
@@ -1,13 +1,14 @@
1
- import { defineComponent as i, computed as o, onMounted as d, watch as p, createBlock as h, createElementBlock as v, openBlock as n, unref as l, createElementVNode as y } from "vue";
2
- import { getResolvedRef as f } from "@scalar/workspace-store/helpers/get-resolved-ref";
3
- import { getOperationHeader as S } from "./helpers/get-operation-header.js";
4
- import { getSelectedServer as k } from "./helpers/get-selected-server.js";
5
- import g from "../../blocks/operation-block/OperationBlock.vue.js";
6
- const w = {
1
+ import { defineComponent as p, computed as r, onMounted as h, watch as v, createBlock as y, createElementBlock as f, openBlock as s, unref as u, createElementVNode as S } from "vue";
2
+ import { getResolvedRef as l } from "@scalar/workspace-store/helpers/get-resolved-ref";
3
+ import { combineParams as k } from "./helpers/combine-params.js";
4
+ import { getOperationHeader as g } from "./helpers/get-operation-header.js";
5
+ import { getSelectedServer as w } from "./helpers/get-selected-server.js";
6
+ import B from "../../blocks/operation-block/OperationBlock.vue.js";
7
+ const C = {
7
8
  key: 1,
8
9
  class: "flex h-full w-full items-center justify-center"
9
- }, B = {}, O = /* @__PURE__ */ i({
10
- ...B,
10
+ }, N = {}, R = /* @__PURE__ */ p({
11
+ ...N,
11
12
  __name: "Operation",
12
13
  props: {
13
14
  documentSlug: {},
@@ -24,18 +25,27 @@ const w = {
24
25
  plugins: {}
25
26
  },
26
27
  setup(t) {
27
- const r = o(
28
- () => t.path && t.method ? f(t.document?.paths?.[t.path]?.[t.method]) ?? null : null
29
- ), s = o(() => [
28
+ const o = r(() => {
29
+ if (!t.path || !t.method)
30
+ return null;
31
+ const e = l(t.document?.paths?.[t.path]?.[t.method]);
32
+ if (!e)
33
+ return null;
34
+ const a = l(t.document?.paths?.[t.path]);
35
+ if (!a)
36
+ return e;
37
+ const n = k(a.parameters, e.parameters);
38
+ return { ...e, parameters: n };
39
+ }), m = r(() => [
30
40
  ...t.workspaceStore.workspace?.["x-scalar-cookies"] ?? [],
31
41
  ...t.document?.["x-scalar-cookies"] ?? []
32
- ]), u = o(() => k(t.document));
33
- d(() => {
42
+ ]), i = r(() => w(t.document));
43
+ h(() => {
34
44
  typeof t.document?.["x-scalar-selected-server"] > "u" && t.document?.servers?.[0]?.url && t.eventBus.emit("server:update:selected", { url: t.document.servers[0].url });
35
- }), p(
36
- r,
45
+ }), v(
46
+ o,
37
47
  (e) => {
38
- e && t.path && t.method && !S({
48
+ e && t.path && t.method && !g({
39
49
  operation: e,
40
50
  name: "Accept",
41
51
  type: "header"
@@ -51,44 +61,44 @@ const w = {
51
61
  },
52
62
  { immediate: !0 }
53
63
  );
54
- const m = o(() => t.document?.["x-scalar-set-operation-security"] ? {
64
+ const c = r(() => t.document?.["x-scalar-set-operation-security"] ? {
55
65
  type: "operation",
56
66
  path: t.path ?? "",
57
67
  method: t.method ?? "get"
58
68
  } : {
59
69
  type: "document"
60
- }), c = "2.17.7";
61
- return (e, a) => e.path && e.method && e.exampleName && r.value ? (n(), h(l(g), {
70
+ }), d = "2.18.0";
71
+ return (e, a) => e.path && e.method && e.exampleName && o.value ? (s(), y(u(B), {
62
72
  key: 0,
63
- appVersion: l(c),
64
- authMeta: m.value,
73
+ appVersion: u(d),
74
+ authMeta: c.value,
65
75
  documentSecurity: e.document?.security ?? [],
66
76
  documentSelectedSecurity: e.document?.["x-scalar-selected-security"],
67
77
  documentUrl: e.document?.["x-scalar-original-source-url"],
68
78
  environment: e.environment,
69
79
  eventBus: e.eventBus,
70
80
  exampleKey: e.exampleName,
71
- globalCookies: s.value,
81
+ globalCookies: m.value,
72
82
  history: [],
73
83
  httpClients: e.workspaceStore.config["x-scalar-reference-config"]?.httpClients,
74
84
  layout: e.layout,
75
85
  method: e.method,
76
- operation: r.value,
86
+ operation: o.value,
77
87
  path: e.path,
78
88
  plugins: e.plugins,
79
89
  proxyUrl: e.workspaceStore.workspace["x-scalar-active-proxy"] ?? "",
80
90
  securitySchemes: e.securitySchemes,
81
91
  selectedClient: e.workspaceStore.workspace["x-scalar-default-client"],
82
- server: u.value,
92
+ server: i.value,
83
93
  servers: e.document?.servers ?? [],
84
94
  setOperationSecurity: e.document?.["x-scalar-set-operation-security"] ?? !1,
85
95
  totalPerformedRequests: 0,
86
- "onUpdate:servers": a[0] || (a[0] = (C) => e.eventBus.emit("ui:route:page", { name: "document.servers" }))
87
- }, null, 8, ["appVersion", "authMeta", "documentSecurity", "documentSelectedSecurity", "documentUrl", "environment", "eventBus", "exampleKey", "globalCookies", "httpClients", "layout", "method", "operation", "path", "plugins", "proxyUrl", "securitySchemes", "selectedClient", "server", "servers", "setOperationSecurity"])) : (n(), v("div", w, [...a[1] || (a[1] = [
88
- y("span", { class: "text-c-3" }, "Select an operation to view details", -1)
96
+ "onUpdate:servers": a[0] || (a[0] = (n) => e.eventBus.emit("ui:route:page", { name: "document.servers" }))
97
+ }, null, 8, ["appVersion", "authMeta", "documentSecurity", "documentSelectedSecurity", "documentUrl", "environment", "eventBus", "exampleKey", "globalCookies", "httpClients", "layout", "method", "operation", "path", "plugins", "proxyUrl", "securitySchemes", "selectedClient", "server", "servers", "setOperationSecurity"])) : (s(), f("div", C, [...a[1] || (a[1] = [
98
+ S("span", { class: "text-c-3" }, "Select an operation to view details", -1)
89
99
  ])]));
90
100
  }
91
101
  });
92
102
  export {
93
- O as default
103
+ R as default
94
104
  };
@@ -0,0 +1,4 @@
1
+ import type { OperationObject, ParameterObject, PathItemObject } from '@scalar/workspace-store/schemas/v3.1/strict/openapi-document';
2
+ /** Combine pathItem and operation parameters into a single, dereferenced parameter array */
3
+ export declare const combineParams: (pathParams?: PathItemObject["parameters"], operationParams?: OperationObject["parameters"]) => ParameterObject[];
4
+ //# sourceMappingURL=combine-params.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"combine-params.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/operation/helpers/combine-params.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,eAAe,EACf,eAAe,EACf,cAAc,EACf,MAAM,8DAA8D,CAAA;AAErE,4FAA4F;AAC5F,eAAO,MAAM,aAAa,GACxB,aAAY,cAAc,CAAC,YAAY,CAAM,EAC7C,kBAAiB,eAAe,CAAC,YAAY,CAAM,KAClD,eAAe,EAgBjB,CAAA"}
@@ -0,0 +1,13 @@
1
+ import { isDefined as s } from "@scalar/helpers/array/is-defined";
2
+ import { getResolvedRef as t } from "@scalar/workspace-store/helpers/get-resolved-ref";
3
+ const c = (a = [], o = []) => {
4
+ const m = [...a, ...o].map((e) => t(e)).filter((e) => s(e) && e.name), r = /* @__PURE__ */ new Map();
5
+ for (const e of m) {
6
+ const n = `${e.in}:${e.name}`;
7
+ r.set(n, e);
8
+ }
9
+ return Array.from(r.values());
10
+ };
11
+ export {
12
+ c as combineParams
13
+ };
@@ -1,3 +1,4 @@
1
+ export { combineParams } from './helpers/combine-params.js';
1
2
  export { getSecurityRequirements } from './helpers/get-security-requirements.js';
2
3
  export { getSelectedSecurity } from './helpers/get-selected-security.js';
3
4
  export { getSelectedServer } from './helpers/get-selected-server.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/v2/features/operation/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAAE,MAAM,qCAAqC,CAAA;AAC7E,OAAO,EAAE,mBAAmB,EAAE,MAAM,iCAAiC,CAAA;AACrE,OAAO,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAA;AACjE,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,iBAAiB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/v2/features/operation/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAA;AACxD,OAAO,EAAE,uBAAuB,EAAE,MAAM,qCAAqC,CAAA;AAC7E,OAAO,EAAE,mBAAmB,EAAE,MAAM,iCAAiC,CAAA;AACrE,OAAO,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAA;AACjE,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,iBAAiB,CAAA"}
@@ -1,10 +1,12 @@
1
- import { getSecurityRequirements as t } from "./helpers/get-security-requirements.js";
2
- import { getSelectedSecurity as f } from "./helpers/get-selected-security.js";
3
- import { getSelectedServer as p } from "./helpers/get-selected-server.js";
4
- import { default as c } from "./Operation.vue.js";
1
+ import { combineParams as t } from "./helpers/combine-params.js";
2
+ import { getSecurityRequirements as m } from "./helpers/get-security-requirements.js";
3
+ import { getSelectedSecurity as p } from "./helpers/get-selected-security.js";
4
+ import { getSelectedServer as c } from "./helpers/get-selected-server.js";
5
+ import { default as x } from "./Operation.vue.js";
5
6
  export {
6
- c as Operation,
7
- t as getSecurityRequirements,
8
- f as getSelectedSecurity,
9
- p as getSelectedServer
7
+ x as Operation,
8
+ t as combineParams,
9
+ m as getSecurityRequirements,
10
+ p as getSelectedSecurity,
11
+ c as getSelectedServer
10
12
  };
@@ -1 +1 @@
1
- {"version":3,"file":"DocumentSettings.vue.d.ts","sourceRoot":"","sources":["../../../../src/v2/features/settings/DocumentSettings.vue"],"names":[],"mappings":"AAmKA,KAAK,WAAW,GAAG;IACjB,uCAAuC;IACvC,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,yDAAyD;IACzD,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,qBAAqB;IACrB,KAAK,EAAE,MAAM,CAAA;IACb,+CAA+C;IAC/C,eAAe,CAAC,EAAE,OAAO,CAAA;CAC1B,CAAC;;;;;;;;AAgUF,wBAOG"}
1
+ {"version":3,"file":"DocumentSettings.vue.d.ts","sourceRoot":"","sources":["../../../../src/v2/features/settings/DocumentSettings.vue"],"names":[],"mappings":"AAyJA,KAAK,WAAW,GAAG;IACjB,uCAAuC;IACvC,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,yDAAyD;IACzD,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,qBAAqB;IACrB,KAAK,EAAE,MAAM,CAAA;IACb,+CAA+C;IAC/C,eAAe,CAAC,EAAE,OAAO,CAAA;CAC1B,CAAC;;;;;;;;AAkTF,wBAOG"}
@@ -1,7 +1,106 @@
1
- import t from "./DocumentSettings.vue2.js";
2
- /* empty css */
3
- import o from "../../../_virtual/_plugin-vue_export-helper.js";
4
- const c = /* @__PURE__ */ o(t, [["__scopeId", "data-v-cda64f02"]]);
1
+ import { defineComponent as v, createElementBlock as d, openBlock as a, Fragment as i, createElementVNode as e, createVNode as n, unref as o, createTextVNode as u, toDisplayString as w, withCtx as m } from "vue";
2
+ import { useModal as x, ScalarToggle as D, ScalarIcon as f, ScalarButton as y, ScalarModal as k } from "@scalar/components";
3
+ import M from "../../../components/Sidebar/Actions/DeleteSidebarListElement.vue.js";
4
+ const U = { class: "flex flex-col gap-12" }, C = { class: "flex flex-col gap-2" }, N = { class: "bg-b-2 rounded-lg border text-sm" }, S = { class: "bg-b-1 flex items-center justify-between gap-4 rounded-t-lg p-3" }, B = { class: "text-c-1 flex items-center overflow-x-auto border-t py-1.5 whitespace-nowrap" }, V = { class: "flex items-center" }, T = ["href"], z = { class: "flex flex-col gap-4" }, A = { class: "flex items-center justify-between rounded-lg border p-3 text-sm" }, O = /* @__PURE__ */ v({
5
+ __name: "DocumentSettings",
6
+ props: {
7
+ documentUrl: {},
8
+ watchMode: { type: Boolean },
9
+ title: {},
10
+ isDraftDocument: { type: Boolean, default: !1 }
11
+ },
12
+ emits: ["delete:document", "update:watchMode"],
13
+ setup(p, { emit: g }) {
14
+ const r = g, s = x(), b = () => {
15
+ p.isDraftDocument || s.show();
16
+ }, h = () => {
17
+ r("delete:document"), s.hide();
18
+ };
19
+ return (l, t) => (a(), d(i, null, [
20
+ e("div", U, [
21
+ e("div", C, [
22
+ t[5] || (t[5] = e("div", { class: "flex h-8 items-center" }, [
23
+ e("h3", { class: "font-bold" }, "Features")
24
+ ], -1)),
25
+ e("div", N, [
26
+ e("div", S, [
27
+ t[2] || (t[2] = e("div", null, [
28
+ e("h4", null, "Watch Mode"),
29
+ e("p", { class: "text-c-2 mt-1" }, " When enabled, the OpenAPI document will be polled for changes. The collection will be updated automatically. ")
30
+ ], -1)),
31
+ n(o(D), {
32
+ class: "w-4",
33
+ disabled: !l.documentUrl,
34
+ modelValue: l.watchMode ?? !1,
35
+ "onUpdate:modelValue": t[0] || (t[0] = (c) => r("update:watchMode", c))
36
+ }, null, 8, ["disabled", "modelValue"])
37
+ ]),
38
+ e("div", B, [
39
+ e("div", V, [
40
+ l.documentUrl ? (a(), d(i, { key: 0 }, [
41
+ t[3] || (t[3] = e("span", { class: "bg-b-2 sticky left-0 pr-2 pl-3" }, "Source", -1)),
42
+ e("a", {
43
+ class: "text-c-2 group rounded pr-3 no-underline hover:underline",
44
+ href: l.documentUrl,
45
+ target: "_blank"
46
+ }, [
47
+ u(w(l.documentUrl) + " ", 1),
48
+ n(o(f), {
49
+ class: "ml-1 hidden w-2.5 group-hover:inline",
50
+ icon: "ExternalLink"
51
+ })
52
+ ], 8, T)
53
+ ], 64)) : (a(), d(i, { key: 1 }, [
54
+ n(o(f), {
55
+ class: "text-c-2 mr-2 ml-3 w-4",
56
+ icon: "NotAllowed",
57
+ size: "sm"
58
+ }),
59
+ t[4] || (t[4] = e("span", { class: "text-c-2 pr-3" }, " No URL configured. Try importing an OpenAPI document from an URL. ", -1))
60
+ ], 64))
61
+ ])
62
+ ])
63
+ ])
64
+ ]),
65
+ e("div", z, [
66
+ t[8] || (t[8] = e("h3", { class: "font-bold" }, "Danger Zone", -1)),
67
+ e("div", A, [
68
+ t[7] || (t[7] = e("div", null, [
69
+ e("h4", null, "Delete Collection"),
70
+ e("p", { class: "text-c-2 mt-1" }, " Be careful, my friend. Once deleted, there is no way to recover the collection. ")
71
+ ], -1)),
72
+ n(o(y), {
73
+ disabled: l.isDraftDocument,
74
+ size: "sm",
75
+ variant: "danger",
76
+ onClick: b
77
+ }, {
78
+ default: m(() => [...t[6] || (t[6] = [
79
+ u(" Delete Collection ", -1)
80
+ ])]),
81
+ _: 1
82
+ }, 8, ["disabled"])
83
+ ])
84
+ ])
85
+ ]),
86
+ n(o(k), {
87
+ size: "xxs",
88
+ state: o(s),
89
+ title: `Delete ${l.title}`
90
+ }, {
91
+ default: m(() => [
92
+ n(M, {
93
+ variableName: l.title ?? "",
94
+ warningMessage: "This action cannot be undone.",
95
+ onClose: t[1] || (t[1] = (c) => o(s).hide()),
96
+ onDelete: h
97
+ }, null, 8, ["variableName"])
98
+ ]),
99
+ _: 1
100
+ }, 8, ["state", "title"])
101
+ ], 64));
102
+ }
103
+ });
5
104
  export {
6
- c as default
105
+ O as default
7
106
  };