urkit-ui 0.1.5 → 0.2.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/README.md +51 -3
- package/dist/module.json +1 -1
- package/dist/runtime/assets/css/global.css +1 -1
- package/dist/runtime/components/Alert.d.vue.ts +56 -0
- package/dist/runtime/components/Alert.vue +107 -0
- package/dist/runtime/components/Alert.vue.d.ts +56 -0
- package/dist/runtime/components/Badge.d.vue.ts +28 -0
- package/dist/runtime/components/Badge.vue +24 -0
- package/dist/runtime/components/Badge.vue.d.ts +28 -0
- package/dist/runtime/components/Button.d.vue.ts +1 -1
- package/dist/runtime/components/Button.vue.d.ts +1 -1
- package/dist/runtime/components/Input.d.vue.ts +6 -6
- package/dist/runtime/components/Input.vue +83 -22
- package/dist/runtime/components/Input.vue.d.ts +6 -6
- package/dist/runtime/public/assets/icons/alert-error.svg +3 -0
- package/dist/runtime/public/assets/icons/alert-feature.svg +3 -0
- package/dist/runtime/public/assets/icons/alert-info.svg +3 -0
- package/dist/runtime/public/assets/icons/alert-success.svg +3 -0
- package/dist/runtime/public/assets/icons/alert-warning.svg +3 -0
- package/dist/runtime/public/assets/icons/close.svg +4 -0
- package/dist/runtime/public/assets/icons/hide.svg +12 -6
- package/dist/runtime/public/assets/icons/search.svg +7 -1
- package/dist/runtime/public/assets/icons/show.svg +6 -2
- package/package.json +13 -12
- package/src/runtime/public/assets/icons/alert-error.svg +3 -0
- package/src/runtime/public/assets/icons/alert-feature.svg +3 -0
- package/src/runtime/public/assets/icons/alert-info.svg +3 -0
- package/src/runtime/public/assets/icons/alert-success.svg +3 -0
- package/src/runtime/public/assets/icons/alert-warning.svg +3 -0
- package/src/runtime/public/assets/icons/close.svg +4 -0
- package/src/runtime/public/assets/icons/hide.svg +12 -6
- package/src/runtime/public/assets/icons/search.svg +7 -1
- package/src/runtime/public/assets/icons/show.svg +6 -2
- package/dist/runtime/public/assets/icons/arrow-down.svg +0 -10
- package/dist/runtime/public/assets/icons/collapse.svg +0 -6
- package/dist/runtime/public/assets/icons/color.svg +0 -1
- package/dist/runtime/public/assets/icons/copied.svg +0 -3
- package/dist/runtime/public/assets/icons/copy.svg +0 -10
- package/dist/runtime/public/assets/icons/figma.svg +0 -1
- package/dist/runtime/public/assets/icons/heart.svg +0 -3
- package/dist/runtime/public/assets/icons/icons-icon.svg +0 -10
- package/dist/runtime/public/assets/icons/installation.svg +0 -1
- package/dist/runtime/public/assets/icons/introduction.svg +0 -1
- package/dist/runtime/public/assets/icons/loader-icon.svg +0 -6
- package/dist/runtime/public/assets/icons/profile.svg +0 -1
- package/dist/runtime/public/assets/icons/radiuss.svg +0 -4
- package/dist/runtime/public/assets/icons/star.svg +0 -3
- package/dist/runtime/public/assets/icons/toast-close.svg +0 -3
- package/dist/runtime/public/assets/icons/toast-error.svg +0 -4
- package/dist/runtime/public/assets/icons/toast-info.svg +0 -5
- package/dist/runtime/public/assets/icons/toast-success.svg +0 -4
- package/dist/runtime/public/assets/icons/toast-warning.svg +0 -5
- package/dist/runtime/public/assets/icons/typo.svg +0 -1
- package/src/runtime/public/assets/icons/arrow-down.svg +0 -10
- package/src/runtime/public/assets/icons/collapse.svg +0 -6
- package/src/runtime/public/assets/icons/color.svg +0 -1
- package/src/runtime/public/assets/icons/copied.svg +0 -3
- package/src/runtime/public/assets/icons/copy.svg +0 -10
- package/src/runtime/public/assets/icons/figma.svg +0 -1
- package/src/runtime/public/assets/icons/heart.svg +0 -3
- package/src/runtime/public/assets/icons/icons-icon.svg +0 -10
- package/src/runtime/public/assets/icons/installation.svg +0 -1
- package/src/runtime/public/assets/icons/introduction.svg +0 -1
- package/src/runtime/public/assets/icons/loader-icon.svg +0 -6
- package/src/runtime/public/assets/icons/profile.svg +0 -1
- package/src/runtime/public/assets/icons/radiuss.svg +0 -4
- package/src/runtime/public/assets/icons/star.svg +0 -3
- package/src/runtime/public/assets/icons/toast-close.svg +0 -3
- package/src/runtime/public/assets/icons/toast-error.svg +0 -4
- package/src/runtime/public/assets/icons/toast-info.svg +0 -5
- package/src/runtime/public/assets/icons/toast-success.svg +0 -4
- package/src/runtime/public/assets/icons/toast-warning.svg +0 -5
- package/src/runtime/public/assets/icons/typo.svg +0 -1
package/README.md
CHANGED
|
@@ -25,6 +25,8 @@ Currently available components in v0.1.5:
|
|
|
25
25
|
| **UrButton** | Full-featured button with variants, sizes, loading states, and icons | ✅ Stable |
|
|
26
26
|
| **UrInput** | Comprehensive input component with validation, password toggle, icons, and select | ✅ Stable |
|
|
27
27
|
| **UrIcon** | Flexible icon system with namespace support | ✅ Stable |
|
|
28
|
+
| **UrAlert** | Alert component for messages and notifications with multiple variants and statuses | ✅ Stable |
|
|
29
|
+
| **UrBadge** | Badge component for labels and status indicators with colors and variants | ✅ Stable |
|
|
28
30
|
|
|
29
31
|
### Coming Soon
|
|
30
32
|
|
|
@@ -129,13 +131,58 @@ Comprehensive input component with validation, icons, and advanced features.
|
|
|
129
131
|
- Select dropdown
|
|
130
132
|
- Disabled and error states
|
|
131
133
|
|
|
134
|
+
### Alert
|
|
135
|
+
|
|
136
|
+
Alert component for displaying important messages and notifications.
|
|
137
|
+
|
|
138
|
+
```vue
|
|
139
|
+
<UrAlert
|
|
140
|
+
status="success"
|
|
141
|
+
title="Success!"
|
|
142
|
+
description="Your changes have been saved."
|
|
143
|
+
:dismissable="true"
|
|
144
|
+
@dismiss="handleDismiss"
|
|
145
|
+
/>
|
|
146
|
+
```
|
|
147
|
+
|
|
148
|
+
**Variants**: `filled`, `light`, `lighter`, `stroke`
|
|
149
|
+
**Sizes**: `xsmall`, `small`, `large`
|
|
150
|
+
**Statuses**: `error`, `warning`, `success`, `information`, `feature`
|
|
151
|
+
|
|
152
|
+
**Features**:
|
|
153
|
+
- Multiple variants and sizes
|
|
154
|
+
- 5 status types with unique icons
|
|
155
|
+
- Optional description and action buttons
|
|
156
|
+
- Dismissable with close button
|
|
157
|
+
- Slots for custom content
|
|
158
|
+
|
|
159
|
+
### Badge
|
|
160
|
+
|
|
161
|
+
Badge component for labels and status indicators.
|
|
162
|
+
|
|
163
|
+
```vue
|
|
164
|
+
<UrBadge
|
|
165
|
+
variant="filled"
|
|
166
|
+
size="medium"
|
|
167
|
+
color="blue"
|
|
168
|
+
>
|
|
169
|
+
New
|
|
170
|
+
</UrBadge>
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
**Variants**: `filled`, `light`, `lighter`, `stroke`
|
|
174
|
+
**Sizes**: `small`, `medium`, `large`
|
|
175
|
+
**Colors**: `gray`, `blue`, `orange`, `red`, `green`, `yellow`, `purple`, `sky`, `pink`, `teal`
|
|
176
|
+
|
|
132
177
|
## 🎨 Icon System
|
|
133
178
|
|
|
134
|
-
Urkit includes a flexible icon system with
|
|
179
|
+
Urkit includes a flexible icon system with namespace support and automatic caching.
|
|
180
|
+
|
|
181
|
+
**📘 [Complete Icon Documentation](./ICONS.md)** - Usage, custom icons, and advanced configuration
|
|
135
182
|
|
|
136
|
-
### Included Icons
|
|
183
|
+
### Included Icons
|
|
137
184
|
|
|
138
|
-
The module includes
|
|
185
|
+
The module includes essential icons to get you started:
|
|
139
186
|
|
|
140
187
|
| Icon | Name | Usage |
|
|
141
188
|
|------|------|-------|
|
|
@@ -254,6 +301,7 @@ export default defineNuxtConfig({
|
|
|
254
301
|
## 📖 Documentation
|
|
255
302
|
|
|
256
303
|
- **[Complete Usage Guide](./USAGE.md)** - Detailed component documentation and examples
|
|
304
|
+
- **[Icon System Guide](./ICONS.md)** - Icon usage, custom icons, and namespaces
|
|
257
305
|
- **[Color Customization](./COLORS.md)** - Brand color customization guide
|
|
258
306
|
- **[Architecture](./ARCHITECTURE.md)** - Technical architecture and asset management
|
|
259
307
|
|
package/dist/module.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@font-face{font-display:swap;font-family:InterFull;font-weight:100 900;src:url(/fonts/Inter-VariableFont_opsz,wght.ttf) format("truetype")}@font-face{font-display:swap;font-family:Instrument;font-style:normal;font-weight:400;src:url(/fonts/Instrument_Serif/InstrumentSerif-Regular.ttf) format("truetype")}@font-face{font-display:swap;font-family:Instrument Italic;font-style:italic;font-weight:400;src:url(/fonts/Instrument_Serif/InstrumentSerif-Italic.ttf) format("truetype")}body{background-color:var(--white);color:var(--white);font-family:InterFull,sans-serif;font-feature-settings:"salt" on,"ss01" on,"ss03" on,"ss07" on,"ss08" on,"tnum" on,"cv01" 1,"cv02" 1,"cv03" 1,"cv04" 1,"cv05" 1,"cv06" 1,"cv08" 1,"cv09" 1,"cv10" 1,"cv12" 1,"cv11" 1,"cv13" 1,"calt" 1,"liga" 1;font-optical-sizing:auto;font-style:normal}body.no-scroll{overflow:hidden!important}*{border-style:solid;border-width:0;box-sizing:border-box}#__nuxt{min-height:inherit}.heading{display:inline-block;font-size:24px;font-weight:600;margin-bottom:32px}.trading-heading{color:var(--white);font-size:14px;font-weight:700}.b-r{border:1px solid red}.b-l{border:1px solid lime}.b-y{border:1px solid #ff0}.b-g{border:1px solid green}.b-b{border:1px solid blue}.section-divider{background:var(--neutral-3);border:none;height:1px;margin:56px 0}.page-enter-active,.page-leave-active{transition:all .4s cubic-bezier(.4,0,.2,1)}.page-enter-from,.page-leave-to{filter:blur(10px);opacity:0}.page-enter-to,.page-leave-from{filter:blur(0);opacity:1}::selection{background-color:var(--neutral-3);text-shadow:none}::-moz-selection{background-color:var(--neutral-3);text-shadow:none}::-webkit-scrollbar{height:6px;width:6px}::-webkit-scrollbar-track{background:transparent}::-webkit-scrollbar-thumb{background-color:transparent;border-radius:6px;-webkit-transition:background-color .3s ease;transition:background-color .3s ease}::-webkit-scrollbar-corner{background:transparent}body:hover::-webkit-scrollbar-thumb{background-color:var(--neutral-4)}body:hover::-webkit-scrollbar-thumb:hover{background-color:var(--neutral-6)}html{scrollbar-color:transparent transparent;scrollbar-width:thin}html:hover{scrollbar-color:var(--neutral-4) transparent}
|
|
1
|
+
@font-face{font-display:swap;font-family:InterFull;font-weight:100 900;src:url(/fonts/Inter-VariableFont_opsz,wght.ttf) format("truetype")}@font-face{font-display:swap;font-family:Instrument;font-style:normal;font-weight:400;src:url(/fonts/Instrument_Serif/InstrumentSerif-Regular.ttf) format("truetype")}@font-face{font-display:swap;font-family:Instrument Italic;font-style:italic;font-weight:400;src:url(/fonts/Instrument_Serif/InstrumentSerif-Italic.ttf) format("truetype")}body{background-color:var(--white);color:var(--white);font-family:InterFull,sans-serif;font-feature-settings:"salt" on,"ss01" on,"ss03" on,"ss07" on,"ss08" on,"tnum" on,"cv01" 1,"cv02" 1,"cv03" 1,"cv04" 1,"cv05" 1,"cv06" 1,"cv08" 1,"cv09" 1,"cv10" 1,"cv12" 1,"cv11" 1,"cv13" 1,"calt" 1,"liga" 1;font-optical-sizing:auto;font-style:normal}body.no-scroll{overflow:hidden!important}*{border-style:solid;border-width:0;box-sizing:border-box}#__nuxt{min-height:inherit}.heading{display:inline-block;font-size:24px;font-weight:600;margin-bottom:32px}.trading-heading{color:var(--white);font-size:14px;font-weight:700}.b-r{border:1px solid red}.b-l{border:1px solid lime}.b-y{border:1px solid #ff0}.b-g{border:1px solid green}.b-b{border:1px solid blue}.section-divider{background:var(--neutral-3);border:none;height:1px;margin:56px 0}.page-enter-active,.page-leave-active{transition:all .4s cubic-bezier(.4,0,.2,1)}.page-enter-from,.page-leave-to{filter:blur(10px);opacity:0}.page-enter-to,.page-leave-from{filter:blur(0);opacity:1}::selection{background-color:var(--neutral-3);text-shadow:none}::-moz-selection{background-color:var(--neutral-3);text-shadow:none}::-webkit-scrollbar{height:6px;width:6px}::-webkit-scrollbar-track{background:transparent}::-webkit-scrollbar-thumb{background-color:transparent;border-radius:6px;-webkit-transition:background-color .3s ease;transition:background-color .3s ease}::-webkit-scrollbar-corner{background:transparent}body:hover::-webkit-scrollbar-thumb{background-color:var(--neutral-4)}body:hover::-webkit-scrollbar-thumb:hover{background-color:var(--neutral-6)}html{scrollbar-color:transparent transparent;scrollbar-width:thin}html:hover{scrollbar-color:var(--neutral-4) transparent}:root{--alert-error-bg:#fb3748;--alert-error-light:#fecaca;--alert-error-lighter:#fef2f2;--alert-warning-bg:#fa731a;--alert-warning-light:#fff2e4;--alert-warning-lighter:#fff7ed;--alert-success-bg:#21c16b;--alert-success-light:#bbf7d0;--alert-success-lighter:#f0fdf4;--alert-info-bg:#335cff;--alert-info-light:#dbeafe;--alert-info-lighter:#eff6ff;--alert-feature-bg:#7d52f4;--alert-feature-light:#e9d5ff;--alert-feature-lighter:#faf5ff}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Alert component for displaying important messages and notifications
|
|
3
|
+
* @component UrAlert
|
|
4
|
+
*/
|
|
5
|
+
interface Props {
|
|
6
|
+
/** Alert visual style */
|
|
7
|
+
variant?: 'filled' | 'light' | 'lighter' | 'stroke';
|
|
8
|
+
/** Alert size */
|
|
9
|
+
size?: 'xsmall' | 'small' | 'large';
|
|
10
|
+
/** Alert status type */
|
|
11
|
+
status?: 'error' | 'warning' | 'success' | 'information' | 'feature';
|
|
12
|
+
/** Additional CSS classes for wrapper */
|
|
13
|
+
wrapperClassName?: string;
|
|
14
|
+
/** Alert title text */
|
|
15
|
+
title?: string;
|
|
16
|
+
/** Alert description text */
|
|
17
|
+
description?: string;
|
|
18
|
+
/** Show "Learn More" action button */
|
|
19
|
+
showLearnMore?: boolean;
|
|
20
|
+
/** Show "Upgrade" action button */
|
|
21
|
+
showUpgrade?: boolean;
|
|
22
|
+
/** Enable dismiss button */
|
|
23
|
+
dismissable?: boolean;
|
|
24
|
+
}
|
|
25
|
+
declare var __VLS_5: {}, __VLS_7: {}, __VLS_9: {}, __VLS_15: {};
|
|
26
|
+
type __VLS_Slots = {} & {
|
|
27
|
+
title?: (props: typeof __VLS_5) => any;
|
|
28
|
+
} & {
|
|
29
|
+
description?: (props: typeof __VLS_7) => any;
|
|
30
|
+
} & {
|
|
31
|
+
actions?: (props: typeof __VLS_9) => any;
|
|
32
|
+
} & {
|
|
33
|
+
'footer-actions'?: (props: typeof __VLS_15) => any;
|
|
34
|
+
};
|
|
35
|
+
declare const __VLS_component: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
36
|
+
dismiss: () => any;
|
|
37
|
+
}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{
|
|
38
|
+
onDismiss?: (() => any) | undefined;
|
|
39
|
+
}>, {
|
|
40
|
+
variant: "filled" | "light" | "lighter" | "stroke";
|
|
41
|
+
size: "xsmall" | "small" | "large";
|
|
42
|
+
status: "error" | "warning" | "success" | "information" | "feature";
|
|
43
|
+
wrapperClassName: string;
|
|
44
|
+
title: string;
|
|
45
|
+
description: string;
|
|
46
|
+
showLearnMore: boolean;
|
|
47
|
+
showUpgrade: boolean;
|
|
48
|
+
dismissable: boolean;
|
|
49
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
50
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
51
|
+
export default _default;
|
|
52
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
53
|
+
new (): {
|
|
54
|
+
$slots: S;
|
|
55
|
+
};
|
|
56
|
+
};
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div
|
|
3
|
+
:class="[
|
|
4
|
+
'alert',
|
|
5
|
+
`alert--${variant}`,
|
|
6
|
+
`alert--${size}`,
|
|
7
|
+
`alert--${status}`,
|
|
8
|
+
wrapperClassName,
|
|
9
|
+
{ 'alert--has-description': description || $slots.description }
|
|
10
|
+
]"
|
|
11
|
+
>
|
|
12
|
+
<div class="alert__main">
|
|
13
|
+
<div class="alert__content">
|
|
14
|
+
<div class="alert__icon">
|
|
15
|
+
<UrIcon :name="iconName" :size="iconSize" />
|
|
16
|
+
</div>
|
|
17
|
+
<div class="alert__text">
|
|
18
|
+
<div class="alert__title">
|
|
19
|
+
<slot name="title">
|
|
20
|
+
{{ title }}
|
|
21
|
+
</slot>
|
|
22
|
+
</div>
|
|
23
|
+
<div v-if="description || $slots.description" class="alert__description">
|
|
24
|
+
<slot name="description">
|
|
25
|
+
{{ description }}
|
|
26
|
+
</slot>
|
|
27
|
+
</div>
|
|
28
|
+
</div>
|
|
29
|
+
</div>
|
|
30
|
+
<div class="alert__actions">
|
|
31
|
+
<div
|
|
32
|
+
v-if="(showLearnMore || showUpgrade || $slots.actions) && !(description || $slots.description)"
|
|
33
|
+
class="alert__ctas"
|
|
34
|
+
>
|
|
35
|
+
<slot name="actions">
|
|
36
|
+
<button v-if="showLearnMore" class="alert__learn-more">Learn More</button>
|
|
37
|
+
<span v-if="showLearnMore && showUpgrade" class="alert__separator">·</span>
|
|
38
|
+
<button v-if="showUpgrade" class="alert__upgrade">Upgrade</button>
|
|
39
|
+
</slot>
|
|
40
|
+
</div>
|
|
41
|
+
<button v-if="dismissable" class="alert__close" @click="$emit('dismiss')">
|
|
42
|
+
<UrIcon name="icons:close" :size="16" />
|
|
43
|
+
</button>
|
|
44
|
+
</div>
|
|
45
|
+
</div>
|
|
46
|
+
<div
|
|
47
|
+
v-if="(showLearnMore || showUpgrade || $slots.actions) && (description || $slots.description)"
|
|
48
|
+
class="alert__footer"
|
|
49
|
+
>
|
|
50
|
+
<div class="alert__links">
|
|
51
|
+
<slot name="footer-actions">
|
|
52
|
+
<button v-if="showLearnMore" class="alert__learn-more">Learn More</button>
|
|
53
|
+
<span v-if="showLearnMore && showUpgrade" class="alert__separator">·</span>
|
|
54
|
+
<button v-if="showUpgrade" class="alert__upgrade">Upgrade</button>
|
|
55
|
+
</slot>
|
|
56
|
+
</div>
|
|
57
|
+
</div>
|
|
58
|
+
</div>
|
|
59
|
+
</template>
|
|
60
|
+
|
|
61
|
+
<script setup>
|
|
62
|
+
import { computed } from "vue";
|
|
63
|
+
const props = defineProps({
|
|
64
|
+
variant: { type: String, required: false, default: "filled" },
|
|
65
|
+
size: { type: String, required: false, default: "small" },
|
|
66
|
+
status: { type: String, required: false, default: "information" },
|
|
67
|
+
wrapperClassName: { type: String, required: false, default: "" },
|
|
68
|
+
title: { type: String, required: false, default: "Insert your alert title here!" },
|
|
69
|
+
description: { type: String, required: false, default: "" },
|
|
70
|
+
showLearnMore: { type: Boolean, required: false, default: false },
|
|
71
|
+
showUpgrade: { type: Boolean, required: false, default: true },
|
|
72
|
+
dismissable: { type: Boolean, required: false, default: true }
|
|
73
|
+
});
|
|
74
|
+
const emit = defineEmits(["dismiss"]);
|
|
75
|
+
const iconName = computed(() => {
|
|
76
|
+
switch (props.status) {
|
|
77
|
+
case "error":
|
|
78
|
+
return "icons:alert-error";
|
|
79
|
+
case "warning":
|
|
80
|
+
return "icons:alert-warning";
|
|
81
|
+
case "success":
|
|
82
|
+
return "icons:alert-success";
|
|
83
|
+
case "information":
|
|
84
|
+
return "icons:alert-info";
|
|
85
|
+
case "feature":
|
|
86
|
+
return "icons:alert-feature";
|
|
87
|
+
default:
|
|
88
|
+
return "icons:alert-info";
|
|
89
|
+
}
|
|
90
|
+
});
|
|
91
|
+
const iconSize = computed(() => {
|
|
92
|
+
switch (props.size) {
|
|
93
|
+
case "xsmall":
|
|
94
|
+
return 16;
|
|
95
|
+
case "small":
|
|
96
|
+
return 20;
|
|
97
|
+
case "large":
|
|
98
|
+
return 24;
|
|
99
|
+
default:
|
|
100
|
+
return 16;
|
|
101
|
+
}
|
|
102
|
+
});
|
|
103
|
+
</script>
|
|
104
|
+
|
|
105
|
+
<style scoped>
|
|
106
|
+
.alert{border-radius:12px;display:flex;flex-direction:column;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif;font-weight:500;letter-spacing:-.015px;min-width:400px;transition:all .2s ease}.alert:not(.alert--has-description){align-items:center;flex-direction:row;justify-content:space-between}.alert:not(.alert--has-description) .alert__main{align-items:center;flex:1}.alert:not(.alert--has-description) .alert__actions{align-items:center;margin-top:0}.alert__main{gap:12px;justify-content:space-between}.alert__content,.alert__main{align-items:flex-start;display:flex}.alert__content{flex:1;gap:8px}.alert__icon{align-items:center;display:flex;flex-shrink:0;justify-content:center;margin-top:2px}.alert__icon :deep(svg){fill:currentColor}.alert__text{display:flex;flex:1;flex-direction:column;gap:4px}.alert__description{font-weight:350;line-height:1.5}.alert__title{font-weight:500}.alert__actions{align-items:flex-start;display:flex;gap:12px;margin-top:2px}.alert__ctas{align-items:center;display:flex;gap:8px}.alert__footer{margin-top:12px}.alert__links{align-items:center;display:flex;gap:8px}.alert__separator{color:inherit;font-weight:400;opacity:.6}.alert__upgrade{background:none;border:none;color:inherit;cursor:pointer;font-size:inherit;font-weight:500;text-decoration:underline;transition:opacity .2s ease}.alert__upgrade:hover{opacity:.8}.alert__learn-more{background:none;border:none;color:inherit;cursor:pointer;font-size:inherit;font-weight:400;opacity:.8;transition:opacity .2s ease}.alert__learn-more:hover{opacity:1}.alert__close{align-items:center;background:none;border:none;color:inherit;cursor:pointer;display:flex;justify-content:center;padding:4px;transition:all .2s ease}.alert__close:hover{background:rgba(0,0,0,.1)}.alert--xsmall{border-radius:8px;font-size:12px;font-weight:400;padding:8px}.alert--xsmall .alert__content,.alert--xsmall .alert__main{align-items:center}.alert--xsmall .alert__actions,.alert--xsmall .alert__icon{margin-top:0}.alert--small{border-radius:10px;font-size:14px;padding:8px}.alert--small .alert__content,.alert--small .alert__main{align-items:center}.alert--small .alert__actions,.alert--small .alert__icon{margin-top:0}.alert--large{border-radius:12px;font-size:16px;padding:16px}.alert--large .alert__description{font-size:15px;margin-top:2px}.alert--xsmall .alert__footer{padding-left:24px}.alert--small .alert__footer{padding-left:28px}.alert--large .alert__footer{padding-left:32px}.alert--filled.alert--error{background-color:var(--alert-error-bg);color:#fff}.alert--filled.alert--warning{background-color:var(--alert-warning-bg);color:#fff}.alert--filled.alert--success{background-color:var(--alert-success-bg);color:#fff}.alert--filled.alert--information{background-color:var(--alert-info-bg);color:#fff}.alert--filled.alert--feature{background-color:var(--alert-feature-bg);color:#fff}.alert--light.alert--error{background-color:var(--alert-error-light);color:var(--neutral-10)}.alert--light.alert--warning{background-color:var(--alert-warning-light);color:var(--neutral-10)}.alert--light.alert--success{background-color:var(--alert-success-light);color:var(--neutral-10)}.alert--light.alert--information{background-color:var(--alert-info-light);color:var(--neutral-10)}.alert--light.alert--feature{background-color:var(--alert-feature-light);color:var(--neutral-10)}.alert--lighter.alert--error{background-color:var(--alert-error-lighter);color:var(--neutral-10)}.alert--lighter.alert--warning{background-color:var(--alert-warning-lighter);color:var(--neutral-10)}.alert--lighter.alert--success{background-color:var(--alert-success-lighter);color:var(--neutral-10)}.alert--lighter.alert--information{background-color:var(--alert-info-lighter);color:var(--neutral-10)}.alert--lighter.alert--feature{background-color:var(--alert-feature-lighter);color:var(--neutral-10)}.alert--stroke{box-shadow:0 4px 8px rgba(41,41,41,.06),0 2px 4px rgba(41,41,41,.04),0 1px 2px rgba(41,41,41,.04),0 0 0 1px rgba(41,41,41,.04),inset 0 -.5px .5px rgba(41,41,41,.08)}.alert--stroke.alert--error,.alert--stroke.alert--feature,.alert--stroke.alert--information,.alert--stroke.alert--success,.alert--stroke.alert--warning{background-color:transparent;color:var(--neutral-10)}.alert--filled.alert--error .alert__icon,.alert--filled.alert--feature .alert__icon,.alert--filled.alert--information .alert__icon,.alert--filled.alert--success .alert__icon,.alert--filled.alert--warning .alert__icon{color:#fff}.alert--light.alert--error .alert__icon{color:var(--alert-error-bg)}.alert--light.alert--warning .alert__icon{color:var(--alert-warning-bg)}.alert--light.alert--success .alert__icon{color:var(--alert-success-bg)}.alert--light.alert--information .alert__icon{color:var(--alert-info-bg)}.alert--light.alert--feature .alert__icon{color:var(--alert-feature-bg)}.alert--lighter.alert--error .alert__icon{color:var(--alert-error-bg)}.alert--lighter.alert--warning .alert__icon{color:var(--alert-warning-bg)}.alert--lighter.alert--success .alert__icon{color:var(--alert-success-bg)}.alert--lighter.alert--information .alert__icon{color:var(--alert-info-bg)}.alert--lighter.alert--feature .alert__icon{color:var(--alert-feature-bg)}.alert--stroke.alert--error .alert__icon{color:var(--alert-error-bg)}.alert--stroke.alert--warning .alert__icon{color:var(--alert-warning-bg)}.alert--stroke.alert--success .alert__icon{color:var(--alert-success-bg)}.alert--stroke.alert--information .alert__icon{color:var(--alert-info-bg)}.alert--stroke.alert--feature .alert__icon{color:var(--alert-feature-bg)}.alert--filled .alert__close:hover{background:hsla(0,0%,100%,.2);border-radius:9999px;transition:all .2s ease}.alert--light .alert__close:hover,.alert--lighter .alert__close:hover,.alert--stroke .alert__close:hover{background:rgba(0,0,0,.1);border-radius:9999px;transition:all .2s ease}
|
|
107
|
+
</style>
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Alert component for displaying important messages and notifications
|
|
3
|
+
* @component UrAlert
|
|
4
|
+
*/
|
|
5
|
+
interface Props {
|
|
6
|
+
/** Alert visual style */
|
|
7
|
+
variant?: 'filled' | 'light' | 'lighter' | 'stroke';
|
|
8
|
+
/** Alert size */
|
|
9
|
+
size?: 'xsmall' | 'small' | 'large';
|
|
10
|
+
/** Alert status type */
|
|
11
|
+
status?: 'error' | 'warning' | 'success' | 'information' | 'feature';
|
|
12
|
+
/** Additional CSS classes for wrapper */
|
|
13
|
+
wrapperClassName?: string;
|
|
14
|
+
/** Alert title text */
|
|
15
|
+
title?: string;
|
|
16
|
+
/** Alert description text */
|
|
17
|
+
description?: string;
|
|
18
|
+
/** Show "Learn More" action button */
|
|
19
|
+
showLearnMore?: boolean;
|
|
20
|
+
/** Show "Upgrade" action button */
|
|
21
|
+
showUpgrade?: boolean;
|
|
22
|
+
/** Enable dismiss button */
|
|
23
|
+
dismissable?: boolean;
|
|
24
|
+
}
|
|
25
|
+
declare var __VLS_5: {}, __VLS_7: {}, __VLS_9: {}, __VLS_15: {};
|
|
26
|
+
type __VLS_Slots = {} & {
|
|
27
|
+
title?: (props: typeof __VLS_5) => any;
|
|
28
|
+
} & {
|
|
29
|
+
description?: (props: typeof __VLS_7) => any;
|
|
30
|
+
} & {
|
|
31
|
+
actions?: (props: typeof __VLS_9) => any;
|
|
32
|
+
} & {
|
|
33
|
+
'footer-actions'?: (props: typeof __VLS_15) => any;
|
|
34
|
+
};
|
|
35
|
+
declare const __VLS_component: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
36
|
+
dismiss: () => any;
|
|
37
|
+
}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{
|
|
38
|
+
onDismiss?: (() => any) | undefined;
|
|
39
|
+
}>, {
|
|
40
|
+
variant: "filled" | "light" | "lighter" | "stroke";
|
|
41
|
+
size: "xsmall" | "small" | "large";
|
|
42
|
+
status: "error" | "warning" | "success" | "information" | "feature";
|
|
43
|
+
wrapperClassName: string;
|
|
44
|
+
title: string;
|
|
45
|
+
description: string;
|
|
46
|
+
showLearnMore: boolean;
|
|
47
|
+
showUpgrade: boolean;
|
|
48
|
+
dismissable: boolean;
|
|
49
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
50
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
51
|
+
export default _default;
|
|
52
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
53
|
+
new (): {
|
|
54
|
+
$slots: S;
|
|
55
|
+
};
|
|
56
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Badge component for labels and status indicators
|
|
3
|
+
* @component UrBadge
|
|
4
|
+
*/
|
|
5
|
+
interface BadgeProps {
|
|
6
|
+
/** Badge visual style */
|
|
7
|
+
variant?: 'filled' | 'light' | 'lighter' | 'stroke';
|
|
8
|
+
/** Badge size */
|
|
9
|
+
size?: 'small' | 'medium' | 'large';
|
|
10
|
+
/** Badge color scheme */
|
|
11
|
+
color?: 'gray' | 'blue' | 'orange' | 'red' | 'green' | 'yellow' | 'purple' | 'sky' | 'pink' | 'teal';
|
|
12
|
+
}
|
|
13
|
+
declare var __VLS_1: {};
|
|
14
|
+
type __VLS_Slots = {} & {
|
|
15
|
+
default?: (props: typeof __VLS_1) => any;
|
|
16
|
+
};
|
|
17
|
+
declare const __VLS_component: import("vue").DefineComponent<BadgeProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<BadgeProps> & Readonly<{}>, {
|
|
18
|
+
variant: "filled" | "light" | "lighter" | "stroke";
|
|
19
|
+
size: "small" | "medium" | "large";
|
|
20
|
+
color: "gray" | "blue" | "orange" | "red" | "green" | "yellow" | "purple" | "sky" | "pink" | "teal";
|
|
21
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
22
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
23
|
+
export default _default;
|
|
24
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
25
|
+
new (): {
|
|
26
|
+
$slots: S;
|
|
27
|
+
};
|
|
28
|
+
};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<span :class="badgeClasses" class="badge">
|
|
3
|
+
<slot />
|
|
4
|
+
</span>
|
|
5
|
+
</template>
|
|
6
|
+
|
|
7
|
+
<script setup>
|
|
8
|
+
const props = defineProps({
|
|
9
|
+
variant: { type: String, required: false, default: "filled" },
|
|
10
|
+
size: { type: String, required: false, default: "small" },
|
|
11
|
+
color: { type: String, required: false, default: "gray" }
|
|
12
|
+
});
|
|
13
|
+
const badgeClasses = computed(() => {
|
|
14
|
+
const baseClasses = "badge";
|
|
15
|
+
const variantClass = `badge--${props.variant}`;
|
|
16
|
+
const sizeClass = `badge--${props.size}`;
|
|
17
|
+
const colorClass = `badge--${props.color}`;
|
|
18
|
+
return [baseClasses, variantClass, sizeClass, colorClass];
|
|
19
|
+
});
|
|
20
|
+
</script>
|
|
21
|
+
|
|
22
|
+
<style scoped>
|
|
23
|
+
.badge{align-items:center;border:1px solid transparent;border-radius:999px;display:inline-flex;font-weight:600;letter-spacing:.025em;letter-spacing:-.015px;text-align:center;text-transform:uppercase;transition:all .2s ease;white-space:nowrap}.badge--small{font-size:10px;padding:2px 6px}.badge--medium{font-size:11px;padding:4px 10px}.badge--large{font-size:12px;padding:6px 14px}.badge--filled.badge--gray{background:#7b7b7b;color:#fff}.badge--light.badge--gray{background:#f3f4f6;color:var(--neutral-7)}.badge--lighter.badge--gray{background:#f9fafb;color:#6b7280}.badge--stroke.badge--gray{background:transparent;border-color:#d1d5db;color:#6b7280}.badge--filled.badge--blue{background:#335cff;color:#fff}.badge--light.badge--blue{background:#dbeafe;color:#1d4ed8}.badge--lighter.badge--blue{background:#eff6ff;color:#1e40af}.badge--stroke.badge--blue{background:transparent;border-color:#93c5fd;color:#3b82f6}.badge--filled.badge--orange{background:#fa731a;color:#fff}.badge--light.badge--orange{background:#fff2e4;color:#ea580c}.badge--lighter.badge--orange{background:#fff7ed;color:#c2410c}.badge--stroke.badge--orange{background:transparent;border-color:#fdba74;color:#f97316}.badge--filled.badge--red{background:#fb3748;color:#fff}.badge--light.badge--red{background:#fecaca;color:#dc2626}.badge--lighter.badge--red{background:#fef2f2;color:#b91c1c}.badge--stroke.badge--red{background:transparent;border-color:#fca5a5;color:#ef4444}.badge--filled.badge--green{background:#21c16b;color:#fff}.badge--light.badge--green{background:#bbf7d0;color:#16a34a}.badge--lighter.badge--green{background:#f0fdf4;color:#15803d}.badge--stroke.badge--green{background:transparent;border-color:#86efac;color:#22c55e}.badge--filled.badge--yellow{background:#f6b51e;color:#fff}.badge--light.badge--yellow{background:#fef3c7;color:#d97706}.badge--lighter.badge--yellow{background:#fffbeb;color:#b45309}.badge--stroke.badge--yellow{background:transparent;border-color:#fde047;color:#eab308}.badge--filled.badge--purple{background:#7d52f4;color:#fff}.badge--light.badge--purple{background:#e9d5ff;color:#9333ea}.badge--lighter.badge--purple{background:#faf5ff;color:#7c3aed}.badge--stroke.badge--purple{background:transparent;border-color:#c084fc;color:#a855f7}.badge--filled.badge--sky{background:#47c2ff;color:#fff}.badge--light.badge--sky{background:#bae6fd;color:#0284c7}.badge--lighter.badge--sky{background:#f0f9ff;color:#0369a1}.badge--stroke.badge--sky{background:transparent;border-color:#7dd3fc;color:#0ea5e9}.badge--filled.badge--pink{background:#fb4ba3;color:#fff}.badge--light.badge--pink{background:#fbcfe8;color:#db2777}.badge--lighter.badge--pink{background:#fdf2f8;color:#be185d}.badge--stroke.badge--pink{background:transparent;border-color:#f9a8d4;color:#ec4899}.badge--filled.badge--teal{background:#24d3ba;color:#fff}.badge--light.badge--teal{background:#99f6e4;color:#0d9488}.badge--lighter.badge--teal{background:#f0fdfa;color:#0f766e}.badge--stroke.badge--teal{background:transparent;border-color:#5eead4;color:#14b8a6}.badge:hover{opacity:.9;transform:translateY(-1px)}
|
|
24
|
+
</style>
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Badge component for labels and status indicators
|
|
3
|
+
* @component UrBadge
|
|
4
|
+
*/
|
|
5
|
+
interface BadgeProps {
|
|
6
|
+
/** Badge visual style */
|
|
7
|
+
variant?: 'filled' | 'light' | 'lighter' | 'stroke';
|
|
8
|
+
/** Badge size */
|
|
9
|
+
size?: 'small' | 'medium' | 'large';
|
|
10
|
+
/** Badge color scheme */
|
|
11
|
+
color?: 'gray' | 'blue' | 'orange' | 'red' | 'green' | 'yellow' | 'purple' | 'sky' | 'pink' | 'teal';
|
|
12
|
+
}
|
|
13
|
+
declare var __VLS_1: {};
|
|
14
|
+
type __VLS_Slots = {} & {
|
|
15
|
+
default?: (props: typeof __VLS_1) => any;
|
|
16
|
+
};
|
|
17
|
+
declare const __VLS_component: import("vue").DefineComponent<BadgeProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<BadgeProps> & Readonly<{}>, {
|
|
18
|
+
variant: "filled" | "light" | "lighter" | "stroke";
|
|
19
|
+
size: "small" | "medium" | "large";
|
|
20
|
+
color: "gray" | "blue" | "orange" | "red" | "green" | "yellow" | "purple" | "sky" | "pink" | "teal";
|
|
21
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
22
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
23
|
+
export default _default;
|
|
24
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
25
|
+
new (): {
|
|
26
|
+
$slots: S;
|
|
27
|
+
};
|
|
28
|
+
};
|
|
@@ -67,9 +67,9 @@ declare const __VLS_component: import("vue").DefineComponent<ButtonProps, {}, {}
|
|
|
67
67
|
}, string, import("vue").PublicProps, Readonly<ButtonProps> & Readonly<{
|
|
68
68
|
onClick?: ((event: MouseEvent) => any) | undefined;
|
|
69
69
|
}>, {
|
|
70
|
+
variant: ButtonVariant;
|
|
70
71
|
size: ButtonSize;
|
|
71
72
|
type: "button" | "submit" | "reset";
|
|
72
|
-
variant: ButtonVariant;
|
|
73
73
|
iconPosition: IconPosition;
|
|
74
74
|
iconCollection: IconCollection;
|
|
75
75
|
rounded: boolean;
|
|
@@ -67,9 +67,9 @@ declare const __VLS_component: import("vue").DefineComponent<ButtonProps, {}, {}
|
|
|
67
67
|
}, string, import("vue").PublicProps, Readonly<ButtonProps> & Readonly<{
|
|
68
68
|
onClick?: ((event: MouseEvent) => any) | undefined;
|
|
69
69
|
}>, {
|
|
70
|
+
variant: ButtonVariant;
|
|
70
71
|
size: ButtonSize;
|
|
71
72
|
type: "button" | "submit" | "reset";
|
|
72
|
-
variant: ButtonVariant;
|
|
73
73
|
iconPosition: IconPosition;
|
|
74
74
|
iconCollection: IconCollection;
|
|
75
75
|
rounded: boolean;
|
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Input size types
|
|
3
3
|
*/
|
|
4
|
-
type InputSize =
|
|
4
|
+
type InputSize = "sm" | "md" | "lg";
|
|
5
5
|
/**
|
|
6
6
|
* Icon position types
|
|
7
7
|
*/
|
|
8
|
-
type IconPosition =
|
|
8
|
+
type IconPosition = "left" | "right";
|
|
9
9
|
/**
|
|
10
10
|
* Affix position types
|
|
11
11
|
*/
|
|
12
|
-
type AffixPosition =
|
|
12
|
+
type AffixPosition = "left" | "right";
|
|
13
13
|
/**
|
|
14
14
|
* Button variant types
|
|
15
15
|
*/
|
|
16
|
-
type ButtonVariant =
|
|
16
|
+
type ButtonVariant = "primary" | "error" | "success" | "neutral";
|
|
17
17
|
/**
|
|
18
18
|
* Button size types
|
|
19
19
|
*/
|
|
20
|
-
type ButtonSize =
|
|
20
|
+
type ButtonSize = "sm" | "md" | "lg" | "xlg";
|
|
21
21
|
/**
|
|
22
22
|
* Select option interface
|
|
23
23
|
*/
|
|
@@ -88,7 +88,7 @@ interface InputProps {
|
|
|
88
88
|
/** Select placeholder */
|
|
89
89
|
selectPlaceholder?: string;
|
|
90
90
|
/** Radius type with standard values */
|
|
91
|
-
radiusType?:
|
|
91
|
+
radiusType?: "none" | "soft" | "medium" | "pill";
|
|
92
92
|
}
|
|
93
93
|
declare const _default: import("vue").DefineComponent<InputProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
94
94
|
"update:modelValue": (value: string | number) => any;
|