@scalar/api-client 2.14.0 → 2.15.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 (79) hide show
  1. package/CHANGELOG.md +54 -0
  2. package/dist/libs/string-template.d.ts +2 -0
  3. package/dist/libs/string-template.d.ts.map +1 -1
  4. package/dist/style.css +1 -1
  5. package/dist/v2/blocks/operation-block/OperationBlock.vue.d.ts.map +1 -1
  6. package/dist/v2/blocks/operation-block/OperationBlock.vue.js +28 -51
  7. package/dist/v2/blocks/operation-block/components/Header.vue.d.ts +0 -12
  8. package/dist/v2/blocks/operation-block/components/Header.vue.d.ts.map +1 -1
  9. package/dist/v2/blocks/operation-block/components/Header.vue.js +3 -3
  10. package/dist/v2/blocks/operation-block/components/Header.vue2.js +26 -28
  11. package/dist/v2/blocks/operation-block/helpers/build-request-parameters.d.ts +33 -0
  12. package/dist/v2/blocks/operation-block/helpers/build-request-parameters.d.ts.map +1 -0
  13. package/dist/v2/blocks/operation-block/helpers/build-request-security.d.ts +18 -0
  14. package/dist/v2/blocks/operation-block/helpers/build-request-security.d.ts.map +1 -0
  15. package/dist/v2/blocks/operation-block/helpers/decode-buffer.d.ts +7 -0
  16. package/dist/v2/blocks/operation-block/helpers/decode-buffer.d.ts.map +1 -0
  17. package/dist/v2/blocks/operation-block/helpers/get-delimiter.d.ts +8 -0
  18. package/dist/v2/blocks/operation-block/helpers/get-delimiter.d.ts.map +1 -0
  19. package/dist/v2/blocks/operation-block/helpers/get-example.d.ts +4 -0
  20. package/dist/v2/blocks/operation-block/helpers/get-example.d.ts.map +1 -0
  21. package/dist/v2/blocks/request-block/RequestBlock.vue.d.ts.map +1 -1
  22. package/dist/v2/blocks/request-block/RequestBlock.vue.js +1 -1
  23. package/dist/v2/blocks/request-block/RequestBlock.vue2.js +134 -125
  24. package/dist/v2/blocks/request-block/components/RequestBody.vue.d.ts +2 -0
  25. package/dist/v2/blocks/request-block/components/RequestBody.vue.d.ts.map +1 -1
  26. package/dist/v2/blocks/request-block/components/RequestBody.vue.js +2 -2
  27. package/dist/v2/blocks/request-block/components/RequestBody.vue2.js +11 -10
  28. package/dist/v2/blocks/request-block/components/RequestParams.vue.d.ts +2 -2
  29. package/dist/v2/blocks/request-block/components/RequestParams.vue.d.ts.map +1 -1
  30. package/dist/v2/blocks/request-block/components/RequestTable.vue.d.ts +2 -4
  31. package/dist/v2/blocks/request-block/components/RequestTable.vue.d.ts.map +1 -1
  32. package/dist/v2/blocks/request-block/components/RequestTable.vue.js +1 -1
  33. package/dist/v2/blocks/request-block/components/RequestTableRow.vue.d.ts +2 -2
  34. package/dist/v2/blocks/request-block/components/RequestTableRow.vue.d.ts.map +1 -1
  35. package/dist/v2/blocks/request-block/components/RequestTableRow.vue.js +10 -10
  36. package/dist/v2/blocks/request-block/helpers/create-parameter-handlers.d.ts +1 -1
  37. package/dist/v2/blocks/request-block/helpers/create-parameter-handlers.d.ts.map +1 -1
  38. package/dist/v2/blocks/request-block/helpers/create-parameter-handlers.js +21 -15
  39. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.d.ts +4 -13
  40. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.d.ts.map +1 -1
  41. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue.js +1 -1
  42. package/dist/v2/blocks/scalar-address-bar-block/components/AddressBar.vue2.js +106 -70
  43. package/dist/v2/components/code-input/CodeInput.vue.d.ts +10 -1
  44. package/dist/v2/components/code-input/CodeInput.vue.d.ts.map +1 -1
  45. package/dist/v2/components/code-input/CodeInput.vue.js +1 -1
  46. package/dist/v2/components/code-input/CodeInput.vue2.js +65 -51
  47. package/dist/v2/components/sidebar/Sidebar.vue.d.ts +4 -0
  48. package/dist/v2/components/sidebar/Sidebar.vue.d.ts.map +1 -1
  49. package/dist/v2/components/sidebar/Sidebar.vue.js +42 -39
  50. package/dist/v2/features/app/App.vue.d.ts.map +1 -1
  51. package/dist/v2/features/app/App.vue.js +64 -66
  52. package/dist/v2/features/app/components/AppSidebar.vue.d.ts.map +1 -1
  53. package/dist/v2/features/app/components/AppSidebar.vue.js +2 -2
  54. package/dist/v2/features/app/components/AppSidebar.vue2.js +193 -106
  55. package/dist/v2/features/app/components/ItemDecorator.vue.d.ts +22 -0
  56. package/dist/v2/features/app/components/ItemDecorator.vue.d.ts.map +1 -0
  57. package/dist/v2/features/app/components/ItemDecorator.vue.js +138 -0
  58. package/dist/v2/features/app/components/ItemDecorator.vue2.js +4 -0
  59. package/dist/v2/features/command-palette/components/CommandPaletteExample.vue.d.ts +8 -0
  60. package/dist/v2/features/command-palette/components/CommandPaletteExample.vue.d.ts.map +1 -1
  61. package/dist/v2/features/command-palette/components/CommandPaletteExample.vue.js +76 -68
  62. package/dist/v2/features/command-palette/components/CommandPaletteRequest.vue.d.ts +8 -0
  63. package/dist/v2/features/command-palette/components/CommandPaletteRequest.vue.d.ts.map +1 -1
  64. package/dist/v2/features/command-palette/components/CommandPaletteRequest.vue.js +83 -75
  65. package/dist/v2/features/command-palette/components/CommandPaletteTag.vue.d.ts +4 -0
  66. package/dist/v2/features/command-palette/components/CommandPaletteTag.vue.d.ts.map +1 -1
  67. package/dist/v2/features/command-palette/components/CommandPaletteTag.vue.js +32 -34
  68. package/dist/v2/features/command-palette/hooks/use-command-palette-state.d.ts +16 -0
  69. package/dist/v2/features/command-palette/hooks/use-command-palette-state.d.ts.map +1 -1
  70. package/dist/v2/features/command-palette/hooks/use-command-palette-state.js +24 -21
  71. package/dist/v2/features/operation/Operation.vue.js +1 -1
  72. package/dist/v2/features/settings/DocumentSettings.vue.js +2 -2
  73. package/dist/v2/features/settings/DocumentSettings.vue2.js +1 -1
  74. package/dist/v2/helpers/storage.d.ts.map +1 -1
  75. package/dist/v2/helpers/storage.js +5 -5
  76. package/dist/v2/hooks/use-workspace-client-events.d.ts.map +1 -1
  77. package/dist/v2/hooks/use-workspace-client-events.js +102 -61
  78. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
  79. package/package.json +21 -21
@@ -1 +1 @@
1
- {"version":3,"file":"Sidebar.vue.d.ts","sourceRoot":"","sources":["../../../../src/v2/components/sidebar/Sidebar.vue"],"names":[],"mappings":"AA6IA,OAAO,EAEL,KAAK,YAAY,EACjB,KAAK,WAAW,EAChB,KAAK,YAAY,EAClB,MAAM,iBAAiB,CAAA;AACxB,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAA;AACvE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,iCAAiC,CAAA;AACxE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,4CAA4C,CAAA;AAKhF,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mCAAmC,CAAA;AAClE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAKrD,KAAK,WAAW,GAAG;IACjB,iDAAiD;IACjD,YAAY,EAAE,YAAY,CAAC,cAAc,CAAC,CAAA;IAC1C,4BAA4B;IAC5B,MAAM,EAAE,YAAY,CAAA;IACpB,qCAAqC;IACrC,eAAe,EAAE,SAAS,CAAA;IAC1B,2CAA2C;IAC3C,UAAU,EAAE,SAAS,EAAE,CAAA;IACvB,kEAAkE;IAClE,QAAQ,EAAE,iBAAiB,CAAA;IAC3B,+CAA+C;IAC/C,SAAS,EAAE,iBAAiB,EAAE,CAAA;IAC9B;;;;OAIG;IACH,WAAW,CAAC,EACR,OAAO,GACP,CAAC,CAAC,YAAY,EAAE,YAAY,EAAE,WAAW,EAAE,WAAW,KAAK,OAAO,CAAC,CAAA;CACxE,CAAC;AAeF,KAAK,WAAW,GAAG;IACjB,uCAAuC;IACvC,eAAe,CAAC,IAAI,OAAO,CAAA;IAC3B,mDAAmD;IACnD,MAAM,CAAC,IAAI,OAAO,CAAA;CACnB,CAAC;AAsBF,KAAK,iBAAiB,GAAG,WAAW,GAAG;IACvC,6CAA6C;IAC7C,eAAe,EAAE,OAAO,CAAC;IACzB,wCAAwC;IACxC,cAAc,EAAE,MAAM,CAAC;CACtB,CAAC;AA4MF,QAAA,MAAM,eAAe;;;;;;;;;;;;;;;kFAOnB,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":"Sidebar.vue.d.ts","sourceRoot":"","sources":["../../../../src/v2/components/sidebar/Sidebar.vue"],"names":[],"mappings":"AAqJA,OAAO,EAEL,KAAK,YAAY,EACjB,KAAK,WAAW,EAChB,KAAK,YAAY,EAClB,MAAM,iBAAiB,CAAA;AACxB,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAA;AACvE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,iCAAiC,CAAA;AACxE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,4CAA4C,CAAA;AAKhF,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mCAAmC,CAAA;AAClE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAKrD,KAAK,WAAW,GAAG;IACjB,iDAAiD;IACjD,YAAY,EAAE,YAAY,CAAC,cAAc,CAAC,CAAA;IAC1C,4BAA4B;IAC5B,MAAM,EAAE,YAAY,CAAA;IACpB,qCAAqC;IACrC,eAAe,EAAE,SAAS,CAAA;IAC1B,2CAA2C;IAC3C,UAAU,EAAE,SAAS,EAAE,CAAA;IACvB,kEAAkE;IAClE,QAAQ,EAAE,iBAAiB,CAAA;IAC3B,+CAA+C;IAC/C,SAAS,EAAE,iBAAiB,EAAE,CAAA;IAC9B;;;;OAIG;IACH,WAAW,CAAC,EACR,OAAO,GACP,CAAC,CAAC,YAAY,EAAE,YAAY,EAAE,WAAW,EAAE,WAAW,KAAK,OAAO,CAAC,CAAA;CACxE,CAAC;AAeF,KAAK,WAAW,GAAG;IACjB,uCAAuC;IACvC,eAAe,CAAC,IAAI,OAAO,CAAA;IAC3B,sDAAsD;IACtD,SAAS,CAAC,CAAC,KAAK,EAAE;QAAE,IAAI,EAAE,cAAc,CAAA;KAAE,GAAG,OAAO,CAAA;IACpD,mDAAmD;IACnD,MAAM,CAAC,IAAI,OAAO,CAAA;CACnB,CAAC;AAsBF,KAAK,iBAAiB,GAAG,WAAW,GAAG;IACvC,6CAA6C;IAC7C,eAAe,EAAE,OAAO,CAAC;IACzB,wCAAwC;IACxC,cAAc,EAAE,MAAM,CAAC;CACtB,CAAC;AAmNF,QAAA,MAAM,eAAe;;;;;;;;;;;;;;;kFAOnB,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,12 +1,12 @@
1
- import { defineComponent as w, mergeModels as f, useModel as c, ref as y, createBlock as s, openBlock as r, unref as a, withCtx as l, createVNode as B, renderSlot as b, createElementVNode as k, createCommentVNode as n } from "vue";
2
- import { ScalarIconButton as W } from "@scalar/components";
3
- import { ScalarIconMagnifyingGlass as V } from "@scalar/icons";
4
- import { ScalarSidebar as $ } from "@scalar/sidebar";
5
- import g from "./SidebarMenu.vue.js";
6
- import C from "./SidebarToggle.vue.js";
7
- import I from "../resize/Resize.vue.js";
8
- import M from "../../features/search/components/SearchButton.vue.js";
9
- const O = { class: "bg-sidebar-b-1 z-1 flex flex-col gap-1.5 px-3 pb-1.5" }, D = { class: "flex items-center justify-between" }, F = /* @__PURE__ */ w({
1
+ import { defineComponent as w, mergeModels as f, useModel as b, ref as y, createBlock as r, openBlock as s, unref as a, withCtx as i, createVNode as B, renderSlot as n, normalizeProps as W, guardReactiveProps as $, createElementVNode as k, createCommentVNode as p } from "vue";
2
+ import { ScalarIconButton as V } from "@scalar/components";
3
+ import { ScalarIconMagnifyingGlass as g } from "@scalar/icons";
4
+ import { ScalarSidebar as C } from "@scalar/sidebar";
5
+ import I from "./SidebarMenu.vue.js";
6
+ import M from "./SidebarToggle.vue.js";
7
+ import O from "../resize/Resize.vue.js";
8
+ import D from "../../features/search/components/SearchButton.vue.js";
9
+ const E = { class: "bg-sidebar-b-1 z-1 flex flex-col gap-1.5 px-3 pb-1.5" }, z = { class: "flex items-center justify-between" }, G = /* @__PURE__ */ w({
10
10
  __name: "Sidebar",
11
11
  props: /* @__PURE__ */ f({
12
12
  sidebarState: {},
@@ -26,15 +26,15 @@ const O = { class: "bg-sidebar-b-1 z-1 flex flex-col gap-1.5 px-3 pb-1.5" }, D =
26
26
  sidebarWidthModifiers: {}
27
27
  }),
28
28
  emits: /* @__PURE__ */ f(["selectItem", "select:workspace", "create:workspace", "reorder"], ["update:isSidebarOpen", "update:sidebarWidth"]),
29
- setup(p, { emit: S }) {
30
- const i = S, u = c(p, "isSidebarOpen"), d = y(!1), m = c(p, "sidebarWidth");
31
- return (e, t) => (r(), s(a(I), {
32
- width: m.value,
33
- "onUpdate:width": t[6] || (t[6] = (o) => m.value = o),
29
+ setup(u, { emit: S }) {
30
+ const l = S, m = b(u, "isSidebarOpen"), d = y(!1), c = b(u, "sidebarWidth");
31
+ return (e, o) => (s(), r(a(O), {
32
+ width: c.value,
33
+ "onUpdate:width": o[6] || (o[6] = (t) => c.value = t),
34
34
  class: "flex flex-col"
35
35
  }, {
36
- default: l(() => [
37
- B(a($), {
36
+ default: i(() => [
37
+ B(a(C), {
38
38
  class: "flex w-auto flex-1 pt-2",
39
39
  indent: 15,
40
40
  isDroppable: e.isDroppable,
@@ -42,42 +42,45 @@ const O = { class: "bg-sidebar-b-1 z-1 flex flex-col gap-1.5 px-3 pb-1.5" }, D =
42
42
  isSelected: e.sidebarState.isSelected,
43
43
  items: e.sidebarState.items.value,
44
44
  layout: "client",
45
- onReorder: t[4] || (t[4] = (o, v) => i("reorder", o, v)),
46
- onSelectItem: t[5] || (t[5] = (o) => i("selectItem", o))
45
+ onReorder: o[4] || (o[4] = (t, v) => l("reorder", t, v)),
46
+ onSelectItem: o[5] || (o[5] = (t) => l("selectItem", t))
47
47
  }, {
48
- header: l(() => [
49
- k("div", O, [
50
- k("div", D, [
51
- e.layout === "desktop" ? (r(), s(g, {
48
+ header: i(() => [
49
+ k("div", E, [
50
+ k("div", z, [
51
+ e.layout === "desktop" ? (s(), r(I, {
52
52
  key: 0,
53
53
  activeWorkspace: e.activeWorkspace,
54
54
  workspaces: e.workspaces,
55
- "onCreate:workspace": t[0] || (t[0] = (o) => i("create:workspace")),
56
- "onSelect:workspace": t[1] || (t[1] = (o) => i("select:workspace", o))
57
- }, null, 8, ["activeWorkspace", "workspaces"])) : e.layout === "modal" ? (r(), s(C, {
55
+ "onCreate:workspace": o[0] || (o[0] = (t) => l("create:workspace")),
56
+ "onSelect:workspace": o[1] || (o[1] = (t) => l("select:workspace", t))
57
+ }, null, 8, ["activeWorkspace", "workspaces"])) : e.layout === "modal" ? (s(), r(M, {
58
58
  key: 1,
59
- modelValue: u.value,
60
- "onUpdate:modelValue": t[2] || (t[2] = (o) => u.value = o)
61
- }, null, 8, ["modelValue"])) : n("", !0),
62
- e.layout !== "web" ? (r(), s(a(W), {
59
+ modelValue: m.value,
60
+ "onUpdate:modelValue": o[2] || (o[2] = (t) => m.value = t)
61
+ }, null, 8, ["modelValue"])) : p("", !0),
62
+ e.layout !== "web" ? (s(), r(a(V), {
63
63
  key: 2,
64
- icon: a(V),
64
+ icon: a(g),
65
65
  label: "Search",
66
- onClick: t[3] || (t[3] = (o) => d.value = !d.value)
67
- }, null, 8, ["icon"])) : n("", !0)
66
+ onClick: o[3] || (o[3] = (t) => d.value = !d.value)
67
+ }, null, 8, ["icon"])) : p("", !0)
68
68
  ]),
69
- d.value || e.layout === "web" ? (r(), s(a(M), {
69
+ d.value || e.layout === "web" ? (s(), r(a(D), {
70
70
  key: 0,
71
71
  documents: e.documents,
72
72
  eventBus: e.eventBus
73
- }, null, 8, ["documents", "eventBus"])) : n("", !0)
73
+ }, null, 8, ["documents", "eventBus"])) : p("", !0)
74
74
  ])
75
75
  ]),
76
- before: l(() => [
77
- b(e.$slots, "workspaceButton")
76
+ decorator: i((t) => [
77
+ n(e.$slots, "decorator", W($(t)))
78
78
  ]),
79
- footer: l(() => [
80
- b(e.$slots, "footer")
79
+ before: i(() => [
80
+ n(e.$slots, "workspaceButton")
81
+ ]),
82
+ footer: i(() => [
83
+ n(e.$slots, "footer")
81
84
  ]),
82
85
  _: 3
83
86
  }, 8, ["isDroppable", "isExpanded", "isSelected", "items"])
@@ -87,5 +90,5 @@ const O = { class: "bg-sidebar-b-1 z-1 flex flex-col gap-1.5 px-3 pb-1.5" }, D =
87
90
  }
88
91
  });
89
92
  export {
90
- F as default
93
+ G as default
91
94
  };
@@ -1 +1 @@
1
- {"version":3,"file":"App.vue.d.ts","sourceRoot":"","sources":["../../../../src/v2/features/app/App.vue"],"names":[],"mappings":"AA2WA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAQrD;;;;GAIG;;YAGO,OAAO,CAAC,YAAY,EAAE,OAAO,CAAC;;YAA9B,OAAO,CAAC,YAAY,EAAE,OAAO,CAAC;;AAFxC,wBA+bC"}
1
+ {"version":3,"file":"App.vue.d.ts","sourceRoot":"","sources":["../../../../src/v2/features/app/App.vue"],"names":[],"mappings":"AA2WA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAQrD;;;;GAIG;;YAGO,OAAO,CAAC,YAAY,EAAE,OAAO,CAAC;;YAA9B,OAAO,CAAC,YAAY,EAAE,OAAO,CAAC;;AAFxC,wBA8bC"}
@@ -1,37 +1,37 @@
1
- import { defineComponent as F, ref as z, computed as r, createElementBlock as G, createBlock as h, unref as t, openBlock as d, Fragment as K, createElementVNode as b, createVNode as u, withCtx as j, withDirectives as q, vShow as J, normalizeProps as Q, guardReactiveProps as X } from "vue";
2
- import { useModal as Y, ScalarTeleportRoot as Z } from "@scalar/components";
3
- import { isHttpMethod as ee } from "@scalar/helpers/http/is-http-method";
4
- import { getThemeStyles as te } from "@scalar/themes";
5
- import { createWorkspaceEventBus as oe } from "@scalar/workspace-store/events";
1
+ import { defineComponent as F, ref as z, computed as r, createElementBlock as G, createBlock as h, unref as t, openBlock as m, Fragment as K, createElementVNode as b, createVNode as u, withCtx as j, normalizeProps as q, guardReactiveProps as J } from "vue";
2
+ import { useModal as Q, ScalarTeleportRoot as X } from "@scalar/components";
3
+ import { isHttpMethod as Y } from "@scalar/helpers/http/is-http-method";
4
+ import { getThemeStyles as Z } from "@scalar/themes";
5
+ import { createWorkspaceEventBus as ee } from "@scalar/workspace-store/events";
6
6
  import { xScalarEnvironmentSchema as W } from "@scalar/workspace-store/schemas/extensions/document/x-scalar-environments";
7
7
  import { coerceValue as y } from "@scalar/workspace-store/schemas/typebox-coerce";
8
- import { useRoute as ae, useRouter as re, RouterView as se } from "vue-router";
9
- import ne from "./components/CreateWorkspaceModal.vue.js";
10
- import le from "./components/SplashScreen.vue.js";
11
- import ce from "../command-palette/components/TheCommandPalette.vue.js";
12
- import { useCommandPaletteState as ue } from "../command-palette/hooks/use-command-palette-state.js";
13
- import { useColorMode as ie } from "../../hooks/use-color-mode.js";
14
- import { useDocumentWatcher as pe } from "../../hooks/use-document-watcher.js";
15
- import { useGlobalHotKeys as me } from "../../hooks/use-global-hot-keys.js";
16
- import { useSidebarState as de } from "../../hooks/use-sidebar-state.js";
17
- import { useSyncPath as ve } from "../../hooks/use-sync-path.js";
18
- import { useWorkspaceClientEvents as ke } from "../../hooks/use-workspace-client-events.js";
19
- import { useWorkspaceSelector as Se } from "../../hooks/use-workspace-selector.js";
20
- import { useTabs as fe } from "../../hooks/use-tabs.js";
21
- import we from "./components/AppSidebar.vue.js";
22
- import he from "./components/DesktopTabs.vue.js";
23
- import be from "./components/WebTopNav.vue.js";
24
- const We = ["innerHTML"], ye = { class: "flex min-h-0 flex-1" }, Ee = { class: "bg-b-1 flex-1" }, Te = {}, Je = /* @__PURE__ */ F({
25
- ...Te,
8
+ import { useRoute as te, useRouter as oe, RouterView as ae } from "vue-router";
9
+ import re from "./components/CreateWorkspaceModal.vue.js";
10
+ import se from "./components/SplashScreen.vue.js";
11
+ import ne from "../command-palette/components/TheCommandPalette.vue.js";
12
+ import { useCommandPaletteState as le } from "../command-palette/hooks/use-command-palette-state.js";
13
+ import { useColorMode as ce } from "../../hooks/use-color-mode.js";
14
+ import { useDocumentWatcher as ue } from "../../hooks/use-document-watcher.js";
15
+ import { useGlobalHotKeys as ie } from "../../hooks/use-global-hot-keys.js";
16
+ import { useSidebarState as pe } from "../../hooks/use-sidebar-state.js";
17
+ import { useSyncPath as me } from "../../hooks/use-sync-path.js";
18
+ import { useWorkspaceClientEvents as de } from "../../hooks/use-workspace-client-events.js";
19
+ import { useWorkspaceSelector as ve } from "../../hooks/use-workspace-selector.js";
20
+ import { useTabs as ke } from "../../hooks/use-tabs.js";
21
+ import Se from "./components/AppSidebar.vue.js";
22
+ import fe from "./components/DesktopTabs.vue.js";
23
+ import we from "./components/WebTopNav.vue.js";
24
+ const he = ["innerHTML"], be = { class: "flex min-h-0 flex-1" }, We = { class: "bg-b-1 flex-1" }, ye = {}, je = /* @__PURE__ */ F({
25
+ ...ye,
26
26
  __name: "App",
27
27
  props: {
28
28
  layout: {}
29
29
  },
30
30
  setup(E) {
31
31
  typeof window < "u" && (window.dataDumpWorkspace = () => o.value);
32
- const n = oe({
32
+ const n = ee({
33
33
  debug: !1
34
- }), i = z(!0), O = ae(), U = re(), c = (e) => {
34
+ }), d = z(!0), O = te(), U = oe(), c = (e) => {
35
35
  const a = O.params[e];
36
36
  return typeof a == "string" ? a : void 0;
37
37
  }, v = r(() => c("workspaceSlug")), l = r(() => c("documentSlug")), k = r(() => !l.value || o.value === null ? null : o.value.workspace.documents[l.value] ?? null), S = r(() => {
@@ -39,40 +39,40 @@ const We = ["innerHTML"], ye = { class: "flex min-h-0 flex-1" }, Ee = { class: "
39
39
  return e ? decodeURIComponent(e) : void 0;
40
40
  }), f = r(() => {
41
41
  const e = c("method");
42
- return e && ee(e) ? e : void 0;
43
- }), T = r(() => c("exampleName")), _ = Se(), { store: o, workspaces: g, activeWorkspace: p, setWorkspaceId: D, createWorkspace: I } = _;
44
- ie({ workspaceStore: o });
45
- const m = de({
42
+ return e && Y(e) ? e : void 0;
43
+ }), T = r(() => c("exampleName")), _ = ve(), { store: o, workspaces: g, activeWorkspace: i, setWorkspaceId: I, createWorkspace: M } = _;
44
+ ce({ workspaceStore: o });
45
+ const p = pe({
46
46
  workspaceStore: o,
47
47
  documentSlug: l,
48
48
  path: S,
49
49
  method: f,
50
50
  exampleName: T
51
- }), C = fe({
51
+ }), C = ke({
52
52
  workspaceStore: o,
53
- getEntryByLocation: m.getEntryByLocation,
53
+ getEntryByLocation: p.getEntryByLocation,
54
54
  workspaceSlug: v,
55
55
  documentSlug: l,
56
56
  path: S,
57
57
  method: f
58
- }), { isLoading: M } = ve({
58
+ }), { isLoading: P } = me({
59
59
  workspaceSelectorState: _,
60
60
  tabsState: C,
61
61
  eventBus: n
62
- }), B = ue();
63
- ke({
62
+ }), B = le();
63
+ de({
64
64
  eventBus: n,
65
65
  document: k,
66
66
  workspaceStore: o,
67
- isSidebarOpen: i,
67
+ isSidebarOpen: d,
68
68
  commandPaletteState: B,
69
- sidebarState: m
70
- }), me(n, E.layout), pe({
69
+ sidebarState: p
70
+ }), ie(n, E.layout), ue({
71
71
  documentName: l,
72
72
  store: o,
73
73
  initialTimeout: 5e3
74
74
  });
75
- const P = r(() => {
75
+ const D = r(() => {
76
76
  if (o.value === null)
77
77
  return y(W, {});
78
78
  const e = o.value.workspace["x-scalar-active-environment"];
@@ -92,7 +92,7 @@ const We = ["innerHTML"], ye = { class: "flex min-h-0 flex-1" }, Ee = { class: "
92
92
  if (o.value === null)
93
93
  return "";
94
94
  const e = o.value.workspace["x-scalar-theme"];
95
- return e ? `<style>${te(e)}</style>` : "";
95
+ return e ? `<style>${Z(e)}</style>` : "";
96
96
  }), A = 288, N = r(
97
97
  () => o.value?.workspace?.["x-scalar-sidebar-width"] ?? A
98
98
  ), R = r(
@@ -101,75 +101,73 @@ const We = ["innerHTML"], ye = { class: "flex min-h-0 flex-1" }, Ee = { class: "
101
101
  name: "workspace.environment",
102
102
  params: { workspaceSlug: v.value }
103
103
  }), x = (e) => {
104
- e && D(e);
104
+ e && I(e);
105
105
  }, V = r(
106
106
  () => ({
107
107
  documentSlug: l.value ?? "",
108
108
  document: k.value,
109
- environment: P.value,
109
+ environment: D.value,
110
110
  eventBus: n,
111
111
  exampleName: T.value,
112
112
  layout: E.layout,
113
113
  method: f.value,
114
114
  path: S.value,
115
115
  workspaceStore: o.value,
116
- activeWorkspace: p.value
116
+ activeWorkspace: i.value
117
117
  })
118
- ), w = Y();
119
- return (e, a) => t(o) !== null && t(p) !== null && !t(M) ? (d(), G(K, { key: 0 }, [
120
- b("div", { innerHTML: L.value }, null, 8, We),
121
- u(t(Z), null, {
118
+ ), w = Q();
119
+ return (e, a) => t(o) !== null && t(i) !== null && !t(P) ? (m(), G(K, { key: 0 }, [
120
+ b("div", { innerHTML: L.value }, null, 8, he),
121
+ u(t(X), null, {
122
122
  default: j(() => [
123
- e.layout === "desktop" ? (d(), h(he, {
123
+ e.layout === "desktop" ? (m(), h(fe, {
124
124
  key: 0,
125
125
  eventBus: t(n),
126
126
  tabsState: t(C)
127
- }, null, 8, ["eventBus", "tabsState"])) : (d(), h(be, {
127
+ }, null, 8, ["eventBus", "tabsState"])) : (m(), h(we, {
128
128
  key: 1,
129
- activeWorkspace: t(p),
129
+ activeWorkspace: t(i),
130
130
  workspaces: t(g),
131
131
  "onCreate:workspace": a[0] || (a[0] = (s) => t(w).show()),
132
132
  "onSelect:workspace": x
133
133
  }, null, 8, ["activeWorkspace", "workspaces"])),
134
- b("main", ye, [
135
- q(u(we, {
136
- isSidebarOpen: i.value,
137
- "onUpdate:isSidebarOpen": a[1] || (a[1] = (s) => i.value = s),
138
- activeWorkspace: t(p),
134
+ b("main", be, [
135
+ u(Se, {
136
+ isSidebarOpen: d.value,
137
+ "onUpdate:isSidebarOpen": a[1] || (a[1] = (s) => d.value = s),
138
+ activeWorkspace: t(i),
139
139
  eventBus: t(n),
140
140
  isWorkspaceOpen: R.value,
141
141
  layout: e.layout,
142
- sidebarState: t(m).state,
142
+ sidebarState: t(p).state,
143
143
  sidebarWidth: N.value,
144
144
  store: t(o),
145
145
  workspaces: t(g),
146
146
  "onClick:workspace": $,
147
147
  "onCreate:workspace": a[2] || (a[2] = (s) => t(w).show()),
148
148
  "onSelect:workspace": x,
149
- onSelectItem: t(m).handleSelectItem,
149
+ onSelectItem: t(p).handleSelectItem,
150
150
  "onUpdate:sidebarWidth": H
151
- }, null, 8, ["isSidebarOpen", "activeWorkspace", "eventBus", "isWorkspaceOpen", "layout", "sidebarState", "sidebarWidth", "store", "workspaces", "onSelectItem"]), [
152
- [J, i.value]
153
- ]),
154
- u(ne, {
151
+ }, null, 8, ["isSidebarOpen", "activeWorkspace", "eventBus", "isWorkspaceOpen", "layout", "sidebarState", "sidebarWidth", "store", "workspaces", "onSelectItem"]),
152
+ u(re, {
155
153
  state: t(w),
156
- "onCreate:workspace": a[3] || (a[3] = (s) => t(I)(s))
154
+ "onCreate:workspace": a[3] || (a[3] = (s) => t(M)(s))
157
155
  }, null, 8, ["state"]),
158
- u(ce, {
156
+ u(ne, {
159
157
  eventBus: t(n),
160
158
  paletteState: t(B),
161
159
  workspaceStore: t(o)
162
160
  }, null, 8, ["eventBus", "paletteState", "workspaceStore"]),
163
- b("div", Ee, [
164
- u(t(se), Q(X(V.value)), null, 16)
161
+ b("div", We, [
162
+ u(t(ae), q(J(V.value)), null, 16)
165
163
  ])
166
164
  ])
167
165
  ]),
168
166
  _: 1
169
167
  })
170
- ], 64)) : (d(), h(le, { key: 1 }));
168
+ ], 64)) : (m(), h(se, { key: 1 }));
171
169
  }
172
170
  });
173
171
  export {
174
- Je as default
172
+ je as default
175
173
  };
@@ -1 +1 @@
1
- {"version":3,"file":"AppSidebar.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/app/components/AppSidebar.vue"],"names":[],"mappings":"AAoQA,OAAO,KAAK,EAA6B,YAAY,EAAE,MAAM,iBAAiB,CAAA;AAC9E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAA;AACpE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAA;AACvE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,4CAA4C,CAAA;AAQhF,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mCAAmC,CAAA;AAClE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAErD,KAAK,WAAW,GAAG;IACjB;;OAEG;IACH,MAAM,EAAE,YAAY,CAAA;IAEpB;;OAEG;IACH,YAAY,EAAE,YAAY,CAAC,cAAc,CAAC,CAAA;IAE1C;;OAEG;IACH,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB;;;OAGG;IACH,eAAe,EAAE,SAAS,CAAA;IAC1B;;;OAGG;IACH,UAAU,EAAE,SAAS,EAAE,CAAA;IACvB;;;OAGG;IACH,QAAQ,EAAE,iBAAiB,CAAA;IAC3B;;;OAGG;IACH,KAAK,EAAE,cAAc,CAAA;CACtB,CAAC;AAkEF,KAAK,iBAAiB,GAAG,WAAW,GAAG;IACvC,6CAA6C;IAC7C,eAAe,EAAE,OAAO,CAAC;IACzB,wCAAwC;IACxC,cAAc,EAAE,MAAM,CAAC;CACtB,CAAC;;;;;;;;;;;;;;;;;AAoRF,wBAOG"}
1
+ {"version":3,"file":"AppSidebar.vue.d.ts","sourceRoot":"","sources":["../../../../../src/v2/features/app/components/AppSidebar.vue"],"names":[],"mappings":"AA8YA,OAAO,KAAK,EAA6B,YAAY,EAAE,MAAM,iBAAiB,CAAA;AAC9E,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAA;AACpE,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAA;AAEvE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,4CAA4C,CAAA;AAUhF,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mCAAmC,CAAA;AAClE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAA;AAErD,KAAK,WAAW,GAAG;IACjB;;OAEG;IACH,MAAM,EAAE,YAAY,CAAA;IAEpB;;OAEG;IACH,YAAY,EAAE,YAAY,CAAC,cAAc,CAAC,CAAA;IAE1C;;OAEG;IACH,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB;;;OAGG;IACH,eAAe,EAAE,SAAS,CAAA;IAC1B;;;OAGG;IACH,UAAU,EAAE,SAAS,EAAE,CAAA;IACvB;;;OAGG;IACH,QAAQ,EAAE,iBAAiB,CAAA;IAC3B;;;OAGG;IACH,KAAK,EAAE,cAAc,CAAA;CACtB,CAAC;AA4JF,KAAK,iBAAiB,GAAG,WAAW,GAAG;IACvC,6CAA6C;IAC7C,eAAe,EAAE,OAAO,CAAC;IACzB,wCAAwC;IACxC,cAAc,EAAE,MAAM,CAAC;CACtB,CAAC;;;;;;;;;;;;;;;;;AAsYF,wBAOG"}
@@ -1,7 +1,7 @@
1
1
  import o from "./AppSidebar.vue2.js";
2
2
  /* empty css */
3
3
  import p from "../../../../_virtual/_plugin-vue_export-helper.js";
4
- const m = /* @__PURE__ */ p(o, [["__scopeId", "data-v-a9d2880c"]]);
4
+ const f = /* @__PURE__ */ p(o, [["__scopeId", "data-v-7ac2f137"]]);
5
5
  export {
6
- m as default
6
+ f as default
7
7
  };