@mureka-fe/ui 2.0.0 → 3.0.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/llms.txt +30 -1
- package/dist/src/components/badge/Badge.vue.d.ts +13 -0
- package/dist/src/components/badge/Badge.vue.d.ts.map +1 -0
- package/dist/src/components/badge/__docs__/demos/content.demo.vue.d.ts +3 -0
- package/dist/src/components/badge/__docs__/demos/content.demo.vue.d.ts.map +1 -0
- package/dist/src/components/badge/__docs__/demos/preset.demo.vue.d.ts +3 -0
- package/dist/src/components/badge/__docs__/demos/preset.demo.vue.d.ts.map +1 -0
- package/dist/src/components/badge/__docs__/demos/variant.demo.vue.d.ts +3 -0
- package/dist/src/components/badge/__docs__/demos/variant.demo.vue.d.ts.map +1 -0
- package/dist/src/components/badge/__docs__/meta.d.ts +4 -0
- package/dist/src/components/badge/__docs__/meta.d.ts.map +1 -0
- package/dist/src/components/badge/badge.spec.d.ts +2 -0
- package/dist/src/components/badge/badge.spec.d.ts.map +1 -0
- package/dist/src/components/badge/badge.types.d.ts +24 -0
- package/dist/src/components/badge/badge.types.d.ts.map +1 -0
- package/dist/src/components/badge/index.d.ts +3 -0
- package/dist/src/components/badge/index.d.ts.map +1 -0
- package/dist/src/components/modal/Modal.vue.d.ts +2 -2
- package/dist/src/index.d.ts +2 -0
- package/dist/src/index.d.ts.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/ui.js +616 -471
- package/dist/ui.umd.cjs +1 -1
- package/package.json +1 -1
package/dist/llms.txt
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# @mureka-fe/ui
|
|
1
|
+
# @mureka-fe/ui v3.0.0
|
|
2
2
|
|
|
3
3
|
> AI/LLM-readable reference for the @mureka-fe/ui Vue 3 component library.
|
|
4
4
|
> Read this file before writing UI in a project that depends on this package.
|
|
@@ -19,6 +19,7 @@ import { MuButton, MuModal } from '@mureka-fe/ui';
|
|
|
19
19
|
| --- | --- | --- |
|
|
20
20
|
| Button 按钮 | `button` | 用于触发即时操作,支持主次层级、反色外观、危险状态、胶囊形状与图标模式。 |
|
|
21
21
|
| Message 消息提示 | `message` | 全局展示操作反馈信息,不打断用户操作。 |
|
|
22
|
+
| Badge 徽标 | `badge` | 用于展示状态、权益、版本和轻量元信息的纯展示徽标。 |
|
|
22
23
|
| Dialog 弹窗 | `modal` | 用于承载需要中断当前流程的确认、编辑、危险操作以及结果反馈对话框。提供 form 与 feedback 两种排版形态。 |
|
|
23
24
|
| Tag 标签 | `tag` | 用于筛选、分类、模式切换等轻量选择场景;新版 MuTag 是交互式 button。 |
|
|
24
25
|
| Switch 开关 | `switch` | 用于切换开/关状态,支持受控与非受控、自定义值、异步切换拦截、自定义文案和图标。 |
|
|
@@ -30,6 +31,8 @@ import { MuButton, MuModal } from '@mureka-fe/ui';
|
|
|
30
31
|
```ts
|
|
31
32
|
import './styles/index.css';
|
|
32
33
|
|
|
34
|
+
export { MuBadge } from './components/badge';
|
|
35
|
+
export type { BadgePreset, BadgeProps, BadgeVariant } from './components/badge';
|
|
33
36
|
export { MuButton } from './components/button';
|
|
34
37
|
export { MessageList, message } from './components/message';
|
|
35
38
|
export { MuModal, muModal, openMuModal } from './components/modal';
|
|
@@ -131,6 +134,32 @@ Status: stable · Since 1.0.0 · Category: 反馈
|
|
|
131
134
|
| message.error | (text: string \| { title: string; description?: string; duration?: number; closable?: boolean; resetOnHover?: boolean; icon?: string \| Component }) => { close: () => void } | 展示业务错误提示,可恢复。 |
|
|
132
135
|
| message.danger | (text: string \| { title: string; description?: string; duration?: number; closable?: boolean; resetOnHover?: boolean; icon?: string \| Component }) => { close: () => void } | 展示系统级危险错误提示,不可恢复。 |
|
|
133
136
|
|
|
137
|
+
### Badge 徽标 `badge`
|
|
138
|
+
|
|
139
|
+
Status: stable · Since 2.0.0 · Category: 通用
|
|
140
|
+
|
|
141
|
+
用于展示状态、权益、版本和轻量元信息的纯展示徽标。
|
|
142
|
+
|
|
143
|
+
#### Usage notes
|
|
144
|
+
|
|
145
|
+
- **Preset 总览** — 内置 12 个命名徽标,覆盖 NEW 字标、权益、发布状态和元信息展示。
|
|
146
|
+
- **Variant** — 内容驱动模式支持 outline、solid 和 soft 三种视觉形态。
|
|
147
|
+
- **内容驱动** — 不传 preset 时内容完全来自默认插槽,paid 控制免费灰色与付费主题色。
|
|
148
|
+
|
|
149
|
+
#### Props
|
|
150
|
+
|
|
151
|
+
| name | type | default | description |
|
|
152
|
+
| --- | --- | --- | --- |
|
|
153
|
+
| variant | 'outline' \| 'solid' \| 'soft' | 'outline' | 内容驱动模式的视觉形态。传入 preset 时不可同时使用。 |
|
|
154
|
+
| paid | boolean | false | 内容驱动模式的付费状态。false 使用免费灰色,true 使用主题色。 |
|
|
155
|
+
| preset | BadgePreset | -- | 命名徽标。支持 new、new-mini、premier、pro、beta、free、studio、upload、publish、published、details、bpm。 |
|
|
156
|
+
|
|
157
|
+
#### Slots
|
|
158
|
+
|
|
159
|
+
| name | type | default | description |
|
|
160
|
+
| --- | --- | --- | --- |
|
|
161
|
+
| default | VNode | -- | 徽标内容。文字 preset 提供默认内容并允许覆盖;new 与 new-mini 固定渲染 SVG 字标并忽略插槽。 |
|
|
162
|
+
|
|
134
163
|
### Dialog 弹窗 `modal`
|
|
135
164
|
|
|
136
165
|
Status: stable · Since 1.0.0 · Category: 反馈
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
declare var __VLS_1: {};
|
|
2
|
+
type __VLS_Slots = {} & {
|
|
3
|
+
default?: (props: typeof __VLS_1) => any;
|
|
4
|
+
};
|
|
5
|
+
declare const __VLS_component: import("vue").DefineComponent<import("./badge.types").BadgeBaseProps | import("./badge.types").BadgePresetProps, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("./badge.types").BadgeBaseProps | import("./badge.types").BadgePresetProps> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
|
|
6
|
+
declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
|
|
7
|
+
export default _default;
|
|
8
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
9
|
+
new (): {
|
|
10
|
+
$slots: S;
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=Badge.vue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Badge.vue.d.ts","sourceRoot":"","sources":["../../../../src/components/badge/Badge.vue"],"names":[],"mappings":"AAgcA,QAAA,IAAI,OAAO,IAAW,CAAE;AACxB,KAAK,WAAW,GAAG,EAAE,GACnB;IAAE,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,OAAO,KAAK,GAAG,CAAA;CAAE,CAAC;AAwB/C,QAAA,MAAM,eAAe,8aAMnB,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"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
export default _default;
|
|
3
|
+
//# sourceMappingURL=content.demo.vue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"content.demo.vue.d.ts","sourceRoot":"","sources":["../../../../../../src/components/badge/__docs__/demos/content.demo.vue"],"names":[],"mappings":";AA6HA,wBAKG"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
export default _default;
|
|
3
|
+
//# sourceMappingURL=preset.demo.vue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"preset.demo.vue.d.ts","sourceRoot":"","sources":["../../../../../../src/components/badge/__docs__/demos/preset.demo.vue"],"names":[],"mappings":";AAgHA,wBAKG"}
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
+
export default _default;
|
|
3
|
+
//# sourceMappingURL=variant.demo.vue.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"variant.demo.vue.d.ts","sourceRoot":"","sources":["../../../../../../src/components/badge/__docs__/demos/variant.demo.vue"],"names":[],"mappings":";AAyIA,wBAKG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"meta.d.ts","sourceRoot":"","sources":["../../../../../src/components/badge/__docs__/meta.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,kCAAkC,CAAC;AAEzE,QAAA,MAAM,IAAI,EAAE,gBA+DX,CAAC;AAEF,eAAe,IAAI,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"badge.spec.d.ts","sourceRoot":"","sources":["../../../../src/components/badge/badge.spec.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export type BadgeVariant = 'outline' | 'solid' | 'soft';
|
|
2
|
+
export type BadgePreset = 'new' | 'new-mini' | 'premier' | 'pro' | 'beta' | 'free' | 'studio' | 'upload' | 'publish' | 'published' | 'details' | 'bpm';
|
|
3
|
+
export interface BadgeBaseProps {
|
|
4
|
+
variant?: BadgeVariant;
|
|
5
|
+
paid?: boolean;
|
|
6
|
+
preset?: never;
|
|
7
|
+
}
|
|
8
|
+
export interface BadgePresetProps {
|
|
9
|
+
preset: BadgePreset;
|
|
10
|
+
variant?: never;
|
|
11
|
+
paid?: never;
|
|
12
|
+
}
|
|
13
|
+
export type BadgeProps = BadgeBaseProps | BadgePresetProps;
|
|
14
|
+
export interface ResolvedBadgeProps {
|
|
15
|
+
preset?: BadgePreset;
|
|
16
|
+
variant?: BadgeVariant;
|
|
17
|
+
paid?: boolean;
|
|
18
|
+
defaultContent?: string;
|
|
19
|
+
isSvgPreset: boolean;
|
|
20
|
+
}
|
|
21
|
+
export declare const badgePresets: readonly ["new", "new-mini", "premier", "pro", "beta", "free", "studio", "upload", "publish", "published", "details", "bpm"];
|
|
22
|
+
export declare function resolveBadgeProps(props?: BadgeProps): ResolvedBadgeProps;
|
|
23
|
+
export declare function getBadgeClassNames(props?: BadgeProps): string[];
|
|
24
|
+
//# sourceMappingURL=badge.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"badge.types.d.ts","sourceRoot":"","sources":["../../../../src/components/badge/badge.types.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,OAAO,GAAG,MAAM,CAAC;AACxD,MAAM,MAAM,WAAW,GACnB,KAAK,GACL,UAAU,GACV,SAAS,GACT,KAAK,GACL,MAAM,GACN,MAAM,GACN,QAAQ,GACR,QAAQ,GACR,SAAS,GACT,WAAW,GACX,SAAS,GACT,KAAK,CAAC;AAEV,MAAM,WAAW,cAAc;IAC7B,OAAO,CAAC,EAAE,YAAY,CAAC;IACvB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,MAAM,CAAC,EAAE,KAAK,CAAC;CAChB;AAED,MAAM,WAAW,gBAAgB;IAC/B,MAAM,EAAE,WAAW,CAAC;IACpB,OAAO,CAAC,EAAE,KAAK,CAAC;IAChB,IAAI,CAAC,EAAE,KAAK,CAAC;CACd;AAED,MAAM,MAAM,UAAU,GAAG,cAAc,GAAG,gBAAgB,CAAC;AAE3D,MAAM,WAAW,kBAAkB;IACjC,MAAM,CAAC,EAAE,WAAW,CAAC;IAErB,OAAO,CAAC,EAAE,YAAY,CAAC;IACvB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,WAAW,EAAE,OAAO,CAAC;CACtB;AAOD,eAAO,MAAM,YAAY,8HAakB,CAAC;AA+B5C,wBAAgB,iBAAiB,CAAC,KAAK,GAAE,UAAe,GAAG,kBAAkB,CAgB5E;AAED,wBAAgB,kBAAkB,CAAC,KAAK,GAAE,UAAe,GAAG,MAAM,EAAE,CAqBnE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/badge/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,OAAO,EAAE,MAAM,aAAa,CAAC;AACjD,YAAY,EAAE,WAAW,EAAE,UAAU,EAAE,YAAY,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC"}
|
|
@@ -18,11 +18,11 @@ declare const __VLS_component: import("vue").DefineComponent<ModalProps, {}, {},
|
|
|
18
18
|
"onUpdate:visible"?: ((value: boolean) => any) | undefined;
|
|
19
19
|
onOk?: ((event: MouseEvent) => any) | undefined;
|
|
20
20
|
}>, {
|
|
21
|
+
variant: import("./modal.types").ModalVariant;
|
|
22
|
+
title: string;
|
|
21
23
|
status: import("./modal.types").ModalStatus;
|
|
22
24
|
size: import("./modal.types").ModalSize;
|
|
23
|
-
title: string;
|
|
24
25
|
closable: boolean;
|
|
25
|
-
variant: import("./modal.types").ModalVariant;
|
|
26
26
|
visible: boolean;
|
|
27
27
|
maskClosable: boolean;
|
|
28
28
|
escToClose: boolean;
|
package/dist/src/index.d.ts
CHANGED
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import './styles/index.css';
|
|
2
|
+
export { MuBadge } from './components/badge';
|
|
3
|
+
export type { BadgePreset, BadgeProps, BadgeVariant } from './components/badge';
|
|
2
4
|
export { MuButton } from './components/button';
|
|
3
5
|
export { MessageList, message } from './components/message';
|
|
4
6
|
export { MuModal, muModal, openMuModal } from './components/modal';
|
package/dist/src/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,oBAAoB,CAAC;AAE5B,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAC5D,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACnE,YAAY,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAC/D,OAAO,EAAE,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAC3D,YAAY,EACV,mBAAmB,EACnB,eAAe,EACf,UAAU,EACV,UAAU,GACX,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAC/C,YAAY,EACV,kBAAkB,EAClB,WAAW,EACX,UAAU,EACV,UAAU,EACV,WAAW,GACZ,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAClD,YAAY,EACV,QAAQ,EACR,QAAQ,EACR,cAAc,EACd,UAAU,EACV,SAAS,EACT,QAAQ,EACR,WAAW,GACZ,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,KAAK,EAAE,MAAM,kBAAkB,CAAC;AACzC,Y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