@revojs/ui 0.3.4 → 0.3.6
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/components/badge.d.ts +1 -1
- package/dist/components/link.d.ts +1 -1
- package/dist/module/index.d.ts +4 -0
- package/dist/module/index.js +8 -0
- package/dist/style.css +4 -0
- package/dist/vue/components/badge.vue +2 -0
- package/dist/vue/components/link.vue +4 -0
- package/dist/vue/components/markdown.vue +2 -2
- package/dist/vue/components/notification.vue +1 -1
- package/package.json +4 -4
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { IconComponent } from "./icon";
|
|
2
|
-
export type BadgeVariant = "outline" | "secondary" | "primary" | "attention" | "success" | "destructive";
|
|
2
|
+
export type BadgeVariant = "outline" | "secondary" | "primary" | "attention" | "success" | "info" | "destructive";
|
|
3
3
|
export interface BadgeProps {
|
|
4
4
|
label?: string;
|
|
5
5
|
href?: string;
|
package/dist/module/index.d.ts
CHANGED
|
@@ -38,6 +38,10 @@ export interface UiTheme {
|
|
|
38
38
|
successHover: TailwindColor;
|
|
39
39
|
successActive: TailwindColor;
|
|
40
40
|
successForeground: TailwindColor;
|
|
41
|
+
info: TailwindColor;
|
|
42
|
+
infoHover: TailwindColor;
|
|
43
|
+
infoActive: TailwindColor;
|
|
44
|
+
infoForeground: TailwindColor;
|
|
41
45
|
border: TailwindColor;
|
|
42
46
|
input: TailwindColor;
|
|
43
47
|
ring: TailwindColor;
|
package/dist/module/index.js
CHANGED
|
@@ -62,6 +62,10 @@ var module_default = defineModule({
|
|
|
62
62
|
successHover: "green-800",
|
|
63
63
|
successActive: "green-900",
|
|
64
64
|
successForeground: "white",
|
|
65
|
+
info: "blue-700",
|
|
66
|
+
infoHover: "blue-800",
|
|
67
|
+
infoActive: "blue-900",
|
|
68
|
+
infoForeground: "white",
|
|
65
69
|
border: "zinc-200",
|
|
66
70
|
input: "zinc-200",
|
|
67
71
|
ring: "zinc-400"
|
|
@@ -99,6 +103,10 @@ var module_default = defineModule({
|
|
|
99
103
|
successHover: "green-500",
|
|
100
104
|
successActive: "green-600",
|
|
101
105
|
successForeground: "zinc-950",
|
|
106
|
+
info: "blue-400",
|
|
107
|
+
infoHover: "blue-500",
|
|
108
|
+
infoActive: "blue-600",
|
|
109
|
+
infoForeground: "zinc-950",
|
|
102
110
|
border: "zinc-700",
|
|
103
111
|
input: "zinc-700",
|
|
104
112
|
ring: "zinc-700"
|
package/dist/style.css
CHANGED
|
@@ -35,6 +35,10 @@
|
|
|
35
35
|
--color-success-hover: var(--ui-success-hover);
|
|
36
36
|
--color-success-active: var(--ui-success-active);
|
|
37
37
|
--color-success-foreground: var(--ui-success-foreground);
|
|
38
|
+
--color-info: var(--ui-info);
|
|
39
|
+
--color-info-hover: var(--ui-info-hover);
|
|
40
|
+
--color-info-active: var(--ui-info-active);
|
|
41
|
+
--color-info-foreground: var(--ui-info-foreground);
|
|
38
42
|
--color-border: var(--ui-border);
|
|
39
43
|
--color-input: var(--ui-input);
|
|
40
44
|
--color-ring: var(--ui-ring);
|
|
@@ -43,6 +43,7 @@ const variants: Record<BadgeVariant, string> = {
|
|
|
43
43
|
primary: "bg-primary text-primary-foreground",
|
|
44
44
|
attention: "text-attention ring-1 ring-attention/30 ring-inset",
|
|
45
45
|
success: "text-success ring-1 ring-success/30 ring-inset",
|
|
46
|
+
info: "text-info ring-1 ring-info/30 ring-inset",
|
|
46
47
|
destructive: "text-destructive ring-1 ring-destructive/30 ring-inset",
|
|
47
48
|
};
|
|
48
49
|
|
|
@@ -52,6 +53,7 @@ const hovers: Record<BadgeVariant, string> = {
|
|
|
52
53
|
primary: "hover:bg-primary-hover active:bg-primary-active",
|
|
53
54
|
attention: "hover:bg-ghost-hover active:bg-ghost-active",
|
|
54
55
|
success: "hover:bg-ghost-hover active:bg-ghost-active",
|
|
56
|
+
info: "hover:bg-ghost-hover active:bg-ghost-active",
|
|
55
57
|
destructive: "hover:bg-ghost-hover active:bg-ghost-active",
|
|
56
58
|
};
|
|
57
59
|
</script>
|
|
@@ -27,5 +27,9 @@ const {
|
|
|
27
27
|
const variants: Record<LinkVariant, string> = {
|
|
28
28
|
primary: "text-foreground",
|
|
29
29
|
muted: "text-muted-foreground",
|
|
30
|
+
attention: "text-attention",
|
|
31
|
+
success: "text-success",
|
|
32
|
+
info: "text-info",
|
|
33
|
+
destructive: "text-destructive",
|
|
30
34
|
};
|
|
31
35
|
</script>
|
|
@@ -110,7 +110,7 @@ const elements = computed(() => ({
|
|
|
110
110
|
a: ((_, { attrs, slots }) =>
|
|
111
111
|
h(
|
|
112
112
|
"a",
|
|
113
|
-
{ ...attrs, ...external(attrs.href), class: "
|
|
113
|
+
{ ...attrs, ...external(attrs.href), class: "text-info underline-offset-3 hover:underline" },
|
|
114
114
|
slots.default?.(),
|
|
115
115
|
)) satisfies FunctionalComponent,
|
|
116
116
|
img: ((_, { attrs }) =>
|
|
@@ -118,7 +118,7 @@ const elements = computed(() => ({
|
|
|
118
118
|
? h("img", { ...attrs, loading: "lazy", class: "inline max-w-full rounded-ui" })
|
|
119
119
|
: h(
|
|
120
120
|
"a",
|
|
121
|
-
{ href: attrs.src, ...external(attrs.src), class: "
|
|
121
|
+
{ href: attrs.src, ...external(attrs.src), class: "text-info underline-offset-3 hover:underline" },
|
|
122
122
|
String(attrs.alt || attrs.src),
|
|
123
123
|
)) satisfies FunctionalComponent,
|
|
124
124
|
...components,
|
|
@@ -59,6 +59,6 @@ const variants: Record<NotificationVariant, string> = {
|
|
|
59
59
|
error: "border-destructive/30 bg-destructive/5 text-destructive",
|
|
60
60
|
attention: "border-attention/30 bg-attention/5 text-attention",
|
|
61
61
|
success: "border-success/30 bg-success/5 text-success",
|
|
62
|
-
info: "border-
|
|
62
|
+
info: "border-info/30 bg-info/5 text-info",
|
|
63
63
|
};
|
|
64
64
|
</script>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@revojs/ui",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.6",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -35,14 +35,14 @@
|
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"@iconify-json/hugeicons": "^1.2.35",
|
|
38
|
-
"@revojs/client": "0.3.
|
|
38
|
+
"@revojs/client": "0.3.6",
|
|
39
39
|
"@tailwindcss/vite": "^4.3.3",
|
|
40
|
-
"revojs": "0.3.
|
|
40
|
+
"revojs": "0.3.6",
|
|
41
41
|
"tailwindcss": "^4.3.3",
|
|
42
42
|
"unplugin-icons": "^24.0.0"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
|
-
"@revojs/tsconfig": "0.3.
|
|
45
|
+
"@revojs/tsconfig": "0.3.6",
|
|
46
46
|
"@vitejs/plugin-vue": "^6.0.9"
|
|
47
47
|
},
|
|
48
48
|
"optionalDependencies": {
|