@nuxt/devtools-ui-kit 0.3.1 → 0.4.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.
- package/dist/assets/styles.css +0 -1
- package/dist/components/NButton.vue +1 -1
- package/dist/components/NCheckbox.vue +4 -4
- package/dist/components/NCodeBlock.vue +1 -2
- package/dist/components/NDialog.vue +2 -2
- package/dist/components/NDropdown.vue +1 -1
- package/dist/components/NIconTitle.vue +1 -1
- package/dist/components/NLink.vue +1 -1
- package/dist/components/NLoading.vue +3 -3
- package/dist/components/NPanelGrids.vue +5 -0
- package/dist/components/NRadio.vue +4 -4
- package/dist/components/NSectionBlock.vue +24 -10
- package/dist/components/NSelect.vue +4 -3
- package/dist/components/NSwitch.vue +4 -4
- package/dist/components/NTextInput.vue +3 -3
- package/dist/module.json +1 -1
- package/dist/module.mjs +4 -1
- package/dist/runtime/client.d.ts +1 -1
- package/dist/unocss.d.ts +1 -1
- package/dist/unocss.mjs +117 -99
- package/package.json +14 -13
package/dist/assets/styles.css
CHANGED
|
@@ -14,7 +14,7 @@ defineProps<{
|
|
|
14
14
|
:is="to ? NuxtLink : 'button'"
|
|
15
15
|
:to="to"
|
|
16
16
|
v-bind="$attrs"
|
|
17
|
-
class="n-
|
|
17
|
+
class="n-button n-button-base active:n-button-active focus-visible:n-focus-base n-transition hover:n-button-hover n-disabled:n-disabled"
|
|
18
18
|
>
|
|
19
19
|
<slot name="icon">
|
|
20
20
|
<NIcon v-if="icon" :icon="icon" class="n-button-icon" />
|
|
@@ -16,19 +16,19 @@ const checked = useVModel(props, 'modelValue', emit, { passive: true })
|
|
|
16
16
|
|
|
17
17
|
<template>
|
|
18
18
|
<label
|
|
19
|
-
class="
|
|
19
|
+
class="hover:n-checkbox-hover n-checkbox select-none items-center n-disabled:n-disabled"
|
|
20
20
|
:checked="checked || null"
|
|
21
21
|
:disabled="disabled || null"
|
|
22
22
|
>
|
|
23
23
|
<input
|
|
24
24
|
v-model="checked"
|
|
25
25
|
type="checkbox"
|
|
26
|
-
class="absolute op0
|
|
26
|
+
class="peer absolute op0"
|
|
27
27
|
:disabled="disabled"
|
|
28
28
|
@keypress.enter="checked = !checked"
|
|
29
29
|
>
|
|
30
|
-
<span class="n-
|
|
31
|
-
<NIcon class="n-
|
|
30
|
+
<span class="n-checkbox-box n-checked:n-checkbox-box-checked peer-active:n-active-base peer-focus-visible:n-focus-base n-transition">
|
|
31
|
+
<NIcon class="n-checkbox-icon scale-0 transform op0 n-transition n-checked:scale-100 n-checked:op100" />
|
|
32
32
|
</span>
|
|
33
33
|
<span :class="checked ? '' : 'op50'" class="n-transition"><slot /></span>
|
|
34
34
|
</label>
|
|
@@ -27,8 +27,7 @@ const rendered = computed(() => devToolsClient.value?.devtools.renderCodeHighlig
|
|
|
27
27
|
<pre
|
|
28
28
|
class="n-code-block"
|
|
29
29
|
:class="lines ? 'n-code-block-lines' : ''"
|
|
30
|
-
|
|
31
|
-
/>
|
|
30
|
+
><pre class="shiki"><code><template v-for="line, _idx in code.split('\n')" :key="_idx"><span class="line" v-text="line" /><br></template></code></pre></pre>
|
|
32
31
|
</template>
|
|
33
32
|
</template>
|
|
34
33
|
|
|
@@ -47,13 +47,13 @@ export default {
|
|
|
47
47
|
<template>
|
|
48
48
|
<Teleport v-if="show" to="body">
|
|
49
49
|
<div
|
|
50
|
-
class="n-
|
|
50
|
+
class="n-dialog fixed inset-0 z-100 flex items-center justify-center n-transition"
|
|
51
51
|
:class="[
|
|
52
52
|
show ? '' : 'op0 pointer-events-none visibility-none',
|
|
53
53
|
]"
|
|
54
54
|
>
|
|
55
55
|
<div
|
|
56
|
-
class="inset-0
|
|
56
|
+
class="absolute inset-0 -z-1"
|
|
57
57
|
:class="[
|
|
58
58
|
dim ? 'bg-black/50' : '',
|
|
59
59
|
]"
|
|
@@ -22,7 +22,7 @@ onClickOutside(el, () => {
|
|
|
22
22
|
</slot>
|
|
23
23
|
|
|
24
24
|
<div
|
|
25
|
-
class="absolute
|
|
25
|
+
class="absolute z-10 border n-border-base rounded shadow n-transition n-bg-base"
|
|
26
26
|
:class="[enabled ? 'op-100' : 'op0 pointer-events-none -translate-y-1']"
|
|
27
27
|
>
|
|
28
28
|
<slot />
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div class="n-loading">
|
|
3
|
-
<div class="flex flex-col items-center text-lg
|
|
4
|
-
<div class="
|
|
2
|
+
<div class="n-loading n-panel-grids">
|
|
3
|
+
<div class="flex flex-col animate-pulse items-center text-lg">
|
|
4
|
+
<div class="i-carbon-circle-dash animate-spin text-4xl op50" />
|
|
5
5
|
<slot>
|
|
6
6
|
Loading...
|
|
7
7
|
</slot>
|
|
@@ -19,21 +19,21 @@ const model = useVModel(props, 'modelValue', emit, { passive: true })
|
|
|
19
19
|
|
|
20
20
|
<template>
|
|
21
21
|
<label
|
|
22
|
-
class="n-
|
|
22
|
+
class="n-radio hover:n-radio-hover inline-flex select-none items-center n-disabled:n-disabled"
|
|
23
23
|
:checked="model === value || null"
|
|
24
24
|
:disabled="disabled || null"
|
|
25
25
|
>
|
|
26
26
|
<input
|
|
27
27
|
v-model="model"
|
|
28
28
|
type="radio"
|
|
29
|
-
class="absolute op0
|
|
29
|
+
class="peer absolute op0"
|
|
30
30
|
:disabled="disabled"
|
|
31
31
|
:name="name"
|
|
32
32
|
:value="value"
|
|
33
33
|
@keypress.enter="model = value!"
|
|
34
34
|
>
|
|
35
|
-
<span class="n-
|
|
36
|
-
<div class="n-
|
|
35
|
+
<span class="n-radio-box n-checked:n-radio-box-checked peer-active:n-active-base peer-focus-visible:n-focus-base n-transition">
|
|
36
|
+
<div class="n-radio-inner n-checked:n-radio-inner-checked n-transition" />
|
|
37
37
|
</span>
|
|
38
38
|
<span><slot /></span>
|
|
39
39
|
</label>
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
|
-
|
|
2
|
+
import { useVModel } from '@vueuse/core'
|
|
3
|
+
|
|
4
|
+
const props = withDefaults(
|
|
3
5
|
defineProps<{
|
|
4
6
|
icon?: string
|
|
5
7
|
text: string
|
|
@@ -15,17 +17,24 @@ withDefaults(
|
|
|
15
17
|
collapse: true,
|
|
16
18
|
},
|
|
17
19
|
)
|
|
20
|
+
|
|
21
|
+
const open = useVModel(props, 'open', undefined, { passive: true })
|
|
22
|
+
function onToggle(e: any) {
|
|
23
|
+
open.value = e.target.open
|
|
24
|
+
}
|
|
18
25
|
</script>
|
|
19
26
|
|
|
20
27
|
<template>
|
|
21
|
-
<details :open="open">
|
|
22
|
-
<summary class="
|
|
23
|
-
<NIconTitle :icon="icon" :text="text"
|
|
28
|
+
<details :open="open" @toggle="onToggle">
|
|
29
|
+
<summary class="cursor-pointer select-none hover:bg-active p4" :class="collapse ? '' : 'pointer-events-none'">
|
|
30
|
+
<NIconTitle :icon="icon" :text="text" text-xl transition :class="open ? 'op100' : 'op60'">
|
|
24
31
|
<div>
|
|
25
|
-
<
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
32
|
+
<div text-base>
|
|
33
|
+
<slot name="text">
|
|
34
|
+
{{ text }}
|
|
35
|
+
</slot>
|
|
36
|
+
</div>
|
|
37
|
+
<div v-if="description || $slots.description" text-sm op50>
|
|
29
38
|
<slot name="description">
|
|
30
39
|
{{ description }}
|
|
31
40
|
</slot>
|
|
@@ -36,11 +45,16 @@ withDefaults(
|
|
|
36
45
|
<NIcon
|
|
37
46
|
v-if="collapse"
|
|
38
47
|
icon="carbon-chevron-down"
|
|
39
|
-
class="
|
|
48
|
+
class="chevron"
|
|
49
|
+
cursor-pointer place-self-start text-base op75 transition duration-500
|
|
40
50
|
/>
|
|
41
51
|
</NIconTitle>
|
|
42
52
|
</summary>
|
|
43
|
-
<div
|
|
53
|
+
<div
|
|
54
|
+
v-lazy-show="open"
|
|
55
|
+
class="flex flex-col flex-gap2 pb6 pt2"
|
|
56
|
+
:class="typeof padding === 'string' ? padding : padding ? 'px4' : ''"
|
|
57
|
+
>
|
|
44
58
|
<slot name="details" />
|
|
45
59
|
<div :class="containerClass" class="mt1">
|
|
46
60
|
<slot />
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
2
|
import { useVModel } from '@vueuse/core'
|
|
3
|
+
|
|
3
4
|
const props = withDefaults(
|
|
4
5
|
defineProps<{
|
|
5
6
|
modelValue?: any
|
|
@@ -20,12 +21,12 @@ const input = useVModel(props, 'modelValue', emit, { passive: true })
|
|
|
20
21
|
|
|
21
22
|
<template>
|
|
22
23
|
<div
|
|
23
|
-
class="
|
|
24
|
+
class="n-text-input flex flex items-center border n-border-base rounded px-2 py-1 focus-within:n-focus-base focus-within:border-context n-bg-base"
|
|
24
25
|
>
|
|
25
26
|
<slot name="icon">
|
|
26
|
-
<NIcon v-if="icon" :icon="icon" class="
|
|
27
|
+
<NIcon v-if="icon" :icon="icon" class="mr-0.4em text-1.1em op50" />
|
|
27
28
|
</slot>
|
|
28
|
-
<select v-model="input" :disabled="disabled" class="
|
|
29
|
+
<select v-model="input" :disabled="disabled" class="w-full flex-auto n-bg-base !outline-none">
|
|
29
30
|
<option v-if="placeholder" value="" disabled hidden>
|
|
30
31
|
{{ placeholder }}
|
|
31
32
|
</option>
|
|
@@ -16,19 +16,19 @@ const checked = useVModel(props, 'modelValue', emit, { passive: true })
|
|
|
16
16
|
|
|
17
17
|
<template>
|
|
18
18
|
<label
|
|
19
|
-
class="n-
|
|
19
|
+
class="n-switch n-switch-base n-disabled:n-disabled"
|
|
20
20
|
:checked="checked || null"
|
|
21
21
|
:disabled="disabled || null"
|
|
22
22
|
>
|
|
23
23
|
<input
|
|
24
24
|
v-model="checked"
|
|
25
25
|
type="checkbox"
|
|
26
|
-
class="absolute op0
|
|
26
|
+
class="peer absolute op0"
|
|
27
27
|
:disabled="disabled"
|
|
28
28
|
@keypress.enter="checked = !checked"
|
|
29
29
|
>
|
|
30
|
-
<div class="n-
|
|
31
|
-
<div class="n-
|
|
30
|
+
<div class="n-switch-slider n-checked:n-switch-slider-checked peer-active:n-active-base peer-focus-visible:n-focus-base n-transition">
|
|
31
|
+
<div class="n-checked:n-switch-thumb-checked n-switch-thumb n-transition" />
|
|
32
32
|
</div>
|
|
33
33
|
<slot />
|
|
34
34
|
</label>
|
|
@@ -20,13 +20,13 @@ const input = useVModel(props, 'modelValue', emit, { passive: true })
|
|
|
20
20
|
</script>
|
|
21
21
|
|
|
22
22
|
<template>
|
|
23
|
-
<div class="n-
|
|
23
|
+
<div class="n-text-input flex flex items-center border n-border-base rounded py-1 pl-1 pr-2 focus-within:n-focus-base focus-within:border-context n-bg-base">
|
|
24
24
|
<slot name="icon">
|
|
25
|
-
<NIcon v-if="icon" :icon="icon" class="
|
|
25
|
+
<NIcon v-if="icon" :icon="icon" class="ml-0.3em mr-0.1em text-1.1em op50" />
|
|
26
26
|
</slot>
|
|
27
27
|
<input
|
|
28
28
|
v-model="input"
|
|
29
|
-
class="flex-auto n-bg-base
|
|
29
|
+
class="ml-0.4em w-full flex-auto n-bg-base !outline-none"
|
|
30
30
|
:type="type"
|
|
31
31
|
:disabled="disabled"
|
|
32
32
|
:placeholder="placeholder"
|
package/dist/module.json
CHANGED
package/dist/module.mjs
CHANGED
|
@@ -8,7 +8,9 @@ import '@unocss/preset-mini';
|
|
|
8
8
|
import '@unocss/preset-mini/rules';
|
|
9
9
|
import 'unocss';
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
function rPath(p) {
|
|
12
|
+
return fileURLToPath(new URL(p, import.meta.url).toString());
|
|
13
|
+
}
|
|
12
14
|
const module = defineNuxtModule({
|
|
13
15
|
meta: {
|
|
14
16
|
name: "devtools-ui-kit",
|
|
@@ -29,6 +31,7 @@ const module = defineNuxtModule({
|
|
|
29
31
|
await installModule(await resolver.resolvePath("@unocss/nuxt"));
|
|
30
32
|
await installModule(await resolver.resolvePath("@vueuse/nuxt"));
|
|
31
33
|
await installModule(await resolver.resolvePath("@nuxtjs/color-mode"));
|
|
34
|
+
await installModule(await resolver.resolvePath("v-lazy-show/nuxt"));
|
|
32
35
|
}
|
|
33
36
|
});
|
|
34
37
|
|
package/dist/runtime/client.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const devToolsClient: import("vue").Ref<import("@nuxt/devtools-kit/dist/client-api-
|
|
1
|
+
export declare const devToolsClient: import("vue").Ref<import("@nuxt/devtools-kit/dist/client-api-a2b0aa8f").c | undefined>;
|
package/dist/unocss.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Preset } from '@unocss/core';
|
|
2
2
|
import { UnocssNuxtOptions } from '@unocss/nuxt';
|
|
3
3
|
|
|
4
|
-
declare
|
|
4
|
+
declare function unocssPreset(): Preset;
|
|
5
5
|
declare function extendUnocssOptions(user?: UnocssNuxtOptions): UnocssNuxtOptions;
|
|
6
6
|
|
|
7
7
|
export { extendUnocssOptions, unocssPreset };
|
package/dist/unocss.mjs
CHANGED
|
@@ -3,108 +3,126 @@ import { theme } from '@unocss/preset-mini';
|
|
|
3
3
|
import { fonts } from '@unocss/preset-mini/rules';
|
|
4
4
|
import { mergeDeep, presetUno, presetAttributify, presetTypography, presetIcons, transformerDirectives, transformerVariantGroup } from 'unocss';
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}),
|
|
16
|
-
rules: [
|
|
17
|
-
[/^n-(.*)$/, ([, body], { theme }) => {
|
|
18
|
-
const color = parseColor(body, theme);
|
|
19
|
-
if (color?.cssColor?.type === "rgb" && color.cssColor.components) {
|
|
20
|
-
return {
|
|
21
|
-
"--nui-c-context": `${color.cssColor.components.join(",")}`
|
|
22
|
-
};
|
|
23
|
-
}
|
|
24
|
-
}],
|
|
25
|
-
[/^n-(.*)$/, fonts[1][1]],
|
|
26
|
-
["n-dashed", { "border-style": "dashed" }],
|
|
27
|
-
["n-solid", {
|
|
28
|
-
"background-color": "rgba(var(--nui-c-context), 1) !important",
|
|
29
|
-
"border-color": "rgba(var(--nui-c-context), 1)",
|
|
30
|
-
"color": "white !important"
|
|
31
|
-
}],
|
|
32
|
-
["n-disabled", {
|
|
33
|
-
"opacity": 0.4,
|
|
34
|
-
"pointer-events": "none",
|
|
35
|
-
"filter": "saturate(0)"
|
|
36
|
-
}]
|
|
37
|
-
],
|
|
38
|
-
variants: [
|
|
39
|
-
(input) => {
|
|
40
|
-
const prefix = "n-disabled:";
|
|
41
|
-
if (input.startsWith(prefix)) {
|
|
42
|
-
return {
|
|
43
|
-
matcher: input.slice(prefix.length),
|
|
44
|
-
selector: (input2) => `[disabled] ${input2}, ${input2}[disabled]`
|
|
45
|
-
};
|
|
6
|
+
function unocssPreset() {
|
|
7
|
+
return {
|
|
8
|
+
name: "@nuxt/devtools-ui-kit",
|
|
9
|
+
theme: mergeDeep(theme, {
|
|
10
|
+
colors: {
|
|
11
|
+
context: "rgba(var(--nui-c-context),%alpha)"
|
|
12
|
+
},
|
|
13
|
+
fontFamily: {
|
|
14
|
+
sans: "Avenir, Helvetica, Arial, sans-serif"
|
|
46
15
|
}
|
|
47
|
-
},
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
16
|
+
}),
|
|
17
|
+
rules: [
|
|
18
|
+
[/^n-(.*)$/, ([, body], { theme }) => {
|
|
19
|
+
const color = parseColor(body, theme);
|
|
20
|
+
if (color?.cssColor?.type === "rgb" && color.cssColor.components) {
|
|
21
|
+
return {
|
|
22
|
+
"--nui-c-context": `${color.cssColor.components.join(",")}`
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
}],
|
|
26
|
+
[/^n-(.*)$/, fonts[1][1]],
|
|
27
|
+
["n-dashed", { "border-style": "dashed" }],
|
|
28
|
+
["n-solid", {
|
|
29
|
+
"background-color": "rgba(var(--nui-c-context), 1) !important",
|
|
30
|
+
"border-color": "rgba(var(--nui-c-context), 1)",
|
|
31
|
+
"color": "white !important"
|
|
32
|
+
}],
|
|
33
|
+
["n-disabled", {
|
|
34
|
+
"opacity": 0.4,
|
|
35
|
+
"pointer-events": "none",
|
|
36
|
+
"filter": "saturate(0)"
|
|
37
|
+
}],
|
|
38
|
+
/**
|
|
39
|
+
* Credit to Nanda Syahrasyad (https://github.com/narendrasss)
|
|
40
|
+
*
|
|
41
|
+
* - https://github.com/narendrasss/NotANumber
|
|
42
|
+
* - https://www.nan.fyi/grid.svg
|
|
43
|
+
* - https://www.nan.fyi/grid-dark.svg
|
|
44
|
+
*/
|
|
45
|
+
["n-panel-grids-light", {
|
|
46
|
+
"background-image": `url("data:image/svg+xml,%0A%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' transform='scale(3)'%3E%3Crect x='0' y='0' width='100%25' height='100%25' fill='white'/%3E%3Cpath d='M 10,-2.55e-7 V 20 Z M -1.1677362e-8,10 H 20 Z' stroke-width='0.2' stroke='hsla(0, 0%25, 98%25, 1)' fill='none'/%3E%3C/svg%3E")`,
|
|
47
|
+
"background-size": "40px 40px"
|
|
48
|
+
}],
|
|
49
|
+
["n-panel-grids-dark", {
|
|
50
|
+
"background-image": `url("data:image/svg+xml,%0A%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' transform='scale(3)'%3E%3Crect x='0' y='0' width='100%25' height='100%25' fill='hsl(0, 0%25, 8.5%25)'/%3E%3Cpath d='M 10,-2.55e-7 V 20 Z M -1.1677362e-8,10 H 20 Z' stroke-width='0.2' stroke='hsl(0, 0%25, 11.0%25)' fill='none'/%3E%3C/svg%3E");`,
|
|
51
|
+
"background-size": "40px 40px"
|
|
52
|
+
}]
|
|
53
|
+
],
|
|
54
|
+
variants: [
|
|
55
|
+
(input) => {
|
|
56
|
+
const prefix = "n-disabled:";
|
|
57
|
+
if (input.startsWith(prefix)) {
|
|
58
|
+
return {
|
|
59
|
+
matcher: input.slice(prefix.length),
|
|
60
|
+
selector: (input2) => `[disabled] ${input2}, ${input2}[disabled]`
|
|
61
|
+
};
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
(input) => {
|
|
65
|
+
const prefix = "n-checked:";
|
|
66
|
+
if (input.startsWith(prefix)) {
|
|
67
|
+
return {
|
|
68
|
+
matcher: input.slice(prefix.length),
|
|
69
|
+
selector: (input2) => `[checked] ${input2}, ${input2}[checked]`
|
|
70
|
+
};
|
|
71
|
+
}
|
|
55
72
|
}
|
|
73
|
+
],
|
|
74
|
+
shortcuts: {
|
|
75
|
+
// general
|
|
76
|
+
"n-bg-base": "bg-white dark:bg-[#151515]",
|
|
77
|
+
"n-bg-active": "bg-gray:5",
|
|
78
|
+
"n-bg-hover": "bg-gray:3",
|
|
79
|
+
"n-border-base": "border-gray/20",
|
|
80
|
+
"n-transition": "transition-all duration-200",
|
|
81
|
+
"n-focus-base": "ring-2 ring-context/50",
|
|
82
|
+
"n-active-base": "ring-3 ring-context/10",
|
|
83
|
+
"n-borderless": "!border-none !shadow-none",
|
|
84
|
+
// link
|
|
85
|
+
"n-link-base": "underline underline-offset-2 underline-black/20 dark:underline-white/40",
|
|
86
|
+
"n-link-hover": "decoration-dotted text-context underline-context",
|
|
87
|
+
// card
|
|
88
|
+
"n-card-base": "border n-border-base rounded n-bg-base shadow-sm",
|
|
89
|
+
// header
|
|
90
|
+
"n-header-upper": "text-sm uppercase mb-2 leading-1.2em tracking-wide op50",
|
|
91
|
+
// button
|
|
92
|
+
"n-button-base": "border n-border-base rounded shadow-sm px-1em py-0.25em inline-flex items-center gap-1 op80 !outline-none touch-manipulation",
|
|
93
|
+
"n-button-hover": "op100 !border-context text-context",
|
|
94
|
+
"n-button-active": "n-active-base bg-context/5",
|
|
95
|
+
"n-button-icon": "-ml-0.2em mr-0.2em text-1.1em",
|
|
96
|
+
// checkbox
|
|
97
|
+
"n-checkbox": "inline-flex gap-1 items-center",
|
|
98
|
+
"n-checkbox-box": "border n-border-base w-1.1em h-1.1em mr-1 text-white flex flex-none items-center rounded-sm overflow-visible",
|
|
99
|
+
"n-checkbox-box-checked": "bg-context border-context",
|
|
100
|
+
"n-checkbox-icon": "carbon-checkmark w-1em h-1em m-auto",
|
|
101
|
+
// radio
|
|
102
|
+
"n-radio-box": "border n-border-base w-1.2em h-1.2em mr-1 text-white flex flex-none rounded-full overflow-visible",
|
|
103
|
+
"n-radio-box-checked": "border-context",
|
|
104
|
+
"n-radio-inner": "bg-context rounded-1/2 w-0 h-0 m-auto",
|
|
105
|
+
"n-radio-inner-checked": "w-0.8em h-0.8em",
|
|
106
|
+
// switch
|
|
107
|
+
"n-switch-base": "inline-flex items-center select-none",
|
|
108
|
+
"n-switch-slider": "mr-1 rounded-full border n-border-base relative p-2px",
|
|
109
|
+
"n-switch-slider-checked": "border-context/20 bg-context/10",
|
|
110
|
+
"n-switch-thumb": "h-1em w-1em rounded-1/2 border n-border-base ml-0 mr-0.8em",
|
|
111
|
+
"n-switch-thumb-checked": "bg-context border-context ml-0.8em mr-0",
|
|
112
|
+
// tip
|
|
113
|
+
"n-tip-base": "bg-context/4 text-context px-1em py-0.4em rounded flex gap-2 items-center dark:bg-context/12",
|
|
114
|
+
// icon
|
|
115
|
+
"n-icon": "flex-none",
|
|
116
|
+
// code
|
|
117
|
+
"n-code-block": "dark:bg-[#121212] bg-white",
|
|
118
|
+
// icon-button
|
|
119
|
+
"n-icon-button": "aspect-1/1 w-1.6em h-1.6em flex items-center justify-center rounded op50 hover:op100 hover:n-bg-active",
|
|
120
|
+
// loading
|
|
121
|
+
"n-loading": "flex h-full w-full justify-center items-center",
|
|
122
|
+
"n-panel-grids": "n-panel-grids-light dark:n-panel-grids-dark flex flex-col h-full gap-2 items-center justify-center"
|
|
56
123
|
}
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
// general
|
|
60
|
-
"n-bg-base": "bg-white dark:bg-[#151515]",
|
|
61
|
-
"n-bg-active": "bg-gray:5",
|
|
62
|
-
"n-bg-hover": "bg-gray:3",
|
|
63
|
-
"n-border-base": "border-gray/20",
|
|
64
|
-
"n-transition": "transition-all duration-200",
|
|
65
|
-
"n-focus-base": "ring-2 ring-context/50",
|
|
66
|
-
"n-active-base": "ring-3 ring-context/10",
|
|
67
|
-
"n-borderless": "!border-none !shadow-none",
|
|
68
|
-
// link
|
|
69
|
-
"n-link-base": "underline underline-offset-2 underline-black/20 dark:underline-white/40",
|
|
70
|
-
"n-link-hover": "decoration-dotted text-context underline-context",
|
|
71
|
-
// card
|
|
72
|
-
"n-card-base": "border n-border-base rounded n-bg-base shadow-sm",
|
|
73
|
-
// header
|
|
74
|
-
"n-header-upper": "text-sm uppercase mb-2 leading-1.2em tracking-wide op50",
|
|
75
|
-
// button
|
|
76
|
-
"n-button-base": "border n-border-base rounded shadow-sm px-1em py-0.25em inline-flex items-center gap-1 op80 !outline-none touch-manipulation",
|
|
77
|
-
"n-button-hover": "op100 !border-context text-context",
|
|
78
|
-
"n-button-active": "n-active-base bg-context/5",
|
|
79
|
-
"n-button-icon": "-ml-0.2em mr-0.2em text-1.1em",
|
|
80
|
-
// checkbox
|
|
81
|
-
"n-checkbox": "inline-flex gap-1 items-center",
|
|
82
|
-
"n-checkbox-box": "border n-border-base w-1.1em h-1.1em mr-1 text-white flex flex-none items-center rounded-sm overflow-visible",
|
|
83
|
-
"n-checkbox-box-checked": "bg-context border-context",
|
|
84
|
-
"n-checkbox-icon": "carbon-checkmark w-1em h-1em m-auto",
|
|
85
|
-
// radio
|
|
86
|
-
"n-radio-box": "border n-border-base w-1.2em h-1.2em mr-1 text-white flex flex-none rounded-full overflow-visible",
|
|
87
|
-
"n-radio-box-checked": "border-context",
|
|
88
|
-
"n-radio-inner": "bg-context rounded-1/2 w-0 h-0 m-auto",
|
|
89
|
-
"n-radio-inner-checked": "w-0.8em h-0.8em",
|
|
90
|
-
// switch
|
|
91
|
-
"n-switch-base": "inline-flex items-center select-none",
|
|
92
|
-
"n-switch-slider": "mr-1 rounded-full border n-border-base relative p-2px",
|
|
93
|
-
"n-switch-slider-checked": "border-context/20 bg-context/10",
|
|
94
|
-
"n-switch-thumb": "h-1em w-1em rounded-1/2 border n-border-base ml-0 mr-0.8em",
|
|
95
|
-
"n-switch-thumb-checked": "bg-context border-context ml-0.8em mr-0",
|
|
96
|
-
// tip
|
|
97
|
-
"n-tip-base": "bg-context/4 text-context px-1em py-0.4em rounded flex gap-2 items-center dark:bg-context/12",
|
|
98
|
-
// icon
|
|
99
|
-
"n-icon": "flex-none",
|
|
100
|
-
// code
|
|
101
|
-
"n-code-block": "dark:bg-[#121212] bg-white",
|
|
102
|
-
// icon-button
|
|
103
|
-
"n-icon-button": "aspect-1/1 w-1.6em h-1.6em flex items-center justify-center rounded op50 hover:op100 hover:n-bg-active",
|
|
104
|
-
// loading
|
|
105
|
-
"n-loading": "flex h-full w-full justify-center items-center"
|
|
106
|
-
}
|
|
107
|
-
});
|
|
124
|
+
};
|
|
125
|
+
}
|
|
108
126
|
function extendUnocssOptions(user = {}) {
|
|
109
127
|
return {
|
|
110
128
|
...user,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nuxt/devtools-ui-kit",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.4.0",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": "nuxt/devtools",
|
|
7
7
|
"exports": {
|
|
@@ -23,29 +23,30 @@
|
|
|
23
23
|
"*.cjs"
|
|
24
24
|
],
|
|
25
25
|
"peerDependencies": {
|
|
26
|
-
"@nuxt/devtools": "0.
|
|
26
|
+
"@nuxt/devtools": "0.4.0"
|
|
27
27
|
},
|
|
28
28
|
"dependencies": {
|
|
29
29
|
"@iconify-json/carbon": "^1.1.16",
|
|
30
|
-
"@nuxt/kit": "^3.3.
|
|
30
|
+
"@nuxt/kit": "^3.3.3",
|
|
31
31
|
"@nuxtjs/color-mode": "^3.2.0",
|
|
32
|
-
"@unocss/core": "^0.
|
|
33
|
-
"@unocss/nuxt": "^0.
|
|
34
|
-
"@unocss/preset-attributify": "^0.
|
|
35
|
-
"@unocss/preset-icons": "^0.
|
|
36
|
-
"@unocss/preset-mini": "^0.
|
|
37
|
-
"@unocss/reset": "^0.
|
|
32
|
+
"@unocss/core": "^0.51.4",
|
|
33
|
+
"@unocss/nuxt": "^0.51.4",
|
|
34
|
+
"@unocss/preset-attributify": "^0.51.4",
|
|
35
|
+
"@unocss/preset-icons": "^0.51.4",
|
|
36
|
+
"@unocss/preset-mini": "^0.51.4",
|
|
37
|
+
"@unocss/reset": "^0.51.4",
|
|
38
38
|
"@vueuse/core": "^9.13.0",
|
|
39
39
|
"@vueuse/integrations": "^9.13.0",
|
|
40
40
|
"@vueuse/nuxt": "^9.13.0",
|
|
41
41
|
"defu": "^6.1.2",
|
|
42
42
|
"focus-trap": "^7.4.0",
|
|
43
|
-
"unocss": "^0.
|
|
44
|
-
"
|
|
45
|
-
"@nuxt/devtools
|
|
43
|
+
"unocss": "^0.51.4",
|
|
44
|
+
"v-lazy-show": "^0.2.2",
|
|
45
|
+
"@nuxt/devtools": "0.4.0",
|
|
46
|
+
"@nuxt/devtools-kit": "0.4.0"
|
|
46
47
|
},
|
|
47
48
|
"devDependencies": {
|
|
48
|
-
"nuxt": "^3.3.
|
|
49
|
+
"nuxt": "^3.3.3"
|
|
49
50
|
},
|
|
50
51
|
"publishConfig": {
|
|
51
52
|
"access": "public"
|