@scalar/nuxt 0.2.160 → 0.2.164
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.
package/dist/module.json
CHANGED
|
@@ -1,10 +1,7 @@
|
|
|
1
1
|
<script lang="ts" setup>
|
|
2
2
|
import { useHead, useRequestURL, useSeoMeta } from '#imports'
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
type ReferenceConfiguration,
|
|
6
|
-
parse,
|
|
7
|
-
} from '@scalar/api-reference'
|
|
3
|
+
import { ModernLayout, parse } from '@scalar/api-reference'
|
|
4
|
+
import type { ReferenceConfiguration } from '@scalar/types/legacy'
|
|
8
5
|
import { reactive, ref, toRaw } from 'vue'
|
|
9
6
|
import type { Configuration } from '~/src/types'
|
|
10
7
|
|
|
@@ -15,11 +12,14 @@ const props = defineProps<{
|
|
|
15
12
|
const isDark = ref(props.configuration.darkMode)
|
|
16
13
|
|
|
17
14
|
// Grab spec if we can
|
|
18
|
-
const content
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
15
|
+
const content =
|
|
16
|
+
typeof props.configuration.spec?.content === 'function'
|
|
17
|
+
? toRaw(props.configuration.spec.content())
|
|
18
|
+
: props.configuration.spec?.content
|
|
19
|
+
? toRaw(props.configuration.spec.content)
|
|
20
|
+
: props.configuration.spec?.url
|
|
21
|
+
? await $fetch<string>(props.configuration.spec?.url)
|
|
22
|
+
: await $fetch<string>('/_nitro/openapi.json')
|
|
23
23
|
|
|
24
24
|
// Check for empty spec
|
|
25
25
|
if (!content)
|
package/package.json
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
"bugs": "https://github.com/scalar/scalar/issues/new/choose",
|
|
8
8
|
"repository": {
|
|
9
9
|
"type": "git",
|
|
10
|
-
"url": "https://github.com/scalar/scalar.git",
|
|
10
|
+
"url": "git+https://github.com/scalar/scalar.git",
|
|
11
11
|
"directory": "packages/nuxt"
|
|
12
12
|
},
|
|
13
13
|
"keywords": [
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"testing",
|
|
21
21
|
"vue"
|
|
22
22
|
],
|
|
23
|
-
"version": "0.2.
|
|
23
|
+
"version": "0.2.164",
|
|
24
24
|
"engines": {
|
|
25
25
|
"node": ">=18"
|
|
26
26
|
},
|
|
@@ -39,8 +39,9 @@
|
|
|
39
39
|
],
|
|
40
40
|
"dependencies": {
|
|
41
41
|
"@nuxt/kit": "^3.12.3",
|
|
42
|
-
"@scalar/api-client": "2.2.
|
|
43
|
-
"@scalar/api-reference": "1.25.
|
|
42
|
+
"@scalar/api-client": "2.2.15",
|
|
43
|
+
"@scalar/api-reference": "1.25.86",
|
|
44
|
+
"@scalar/types": "0.0.25"
|
|
44
45
|
},
|
|
45
46
|
"devDependencies": {
|
|
46
47
|
"@nuxt/devtools": "^1.3.9",
|