@emoo-ai/brand 0.1.15 → 0.1.17
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 +1 -1
- package/dist/file-icons.d.ts +2 -2
- package/dist/file-icons.js +4 -1
- package/dist/manifest.json +5 -5
- package/dist/tokens.css +2 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
- `@emoo-ai/brand` / `@emoo-ai/brand/tokens.css`:预编译纯 CSS,只有 `:where(:root)` / `:where(:root.dark)` token 声明。
|
|
8
8
|
- `@emoo-ai/brand/colors`:混色、RGB、主色 20 项变量派生与头像 tint 的纯函数运行时(附类型声明)。
|
|
9
|
-
- `@emoo-ai/brand/file-icons`:名词图标家族(文件 / 文件夹 / emoo 对象,
|
|
9
|
+
- `@emoo-ai/brand/file-icons`:名词图标家族(文件 / 文件夹 / emoo 对象,19 枚)的 SVG 字形真源 `FILE_ICON_GLYPHS` 与按文件名判定 `fileIconType(fileName)` / 取字形 `fileIconGlyph(type)`;色板 token `--emoo-file-*` / `--emoo-{doc|table|meeting|folder|folder-open}` 在 tokens.css 亮暗各一套。`ui-vue` 的 `EmooFileTypeIcon` 与 `ui-react` 的 `FileTypeIcon` 都只是它的 `<svg>` 薄壳。
|
|
10
10
|
- `@emoo-ai/brand/manifest.json`:精确版本与源码/制品 SHA-256,用于核对产物一致性。
|
|
11
11
|
|
|
12
12
|
没有 Vue/React/Element Plus 的运行依赖或 peer;安装 CSS 产物不需要 Sass。
|
package/dist/file-icons.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export type FileIconType = 'pdf' | 'word' | 'excel' | 'csv' | 'ppt' | 'text' | 'markdown' | 'zip' | 'video' | 'audio' | 'image' | 'code' | 'unknown' | 'folder' | 'folder-open' | 'doc' | 'table' | 'meeting';
|
|
2
|
-
export declare const FILE_ICON_TYPES: ["pdf", "word", "excel", "csv", "ppt", "text", "markdown", "zip", "video", "audio", "image", "code", "unknown", "folder", "folder-open", "doc", "table", "meeting"];
|
|
1
|
+
export type FileIconType = 'pdf' | 'word' | 'excel' | 'csv' | 'ppt' | 'text' | 'markdown' | 'zip' | 'video' | 'audio' | 'image' | 'code' | 'cad' | 'unknown' | 'folder' | 'folder-open' | 'doc' | 'table' | 'meeting';
|
|
2
|
+
export declare const FILE_ICON_TYPES: ["pdf", "word", "excel", "csv", "ppt", "text", "markdown", "zip", "video", "audio", "image", "code", "cad", "unknown", "folder", "folder-open", "doc", "table", "meeting"];
|
|
3
3
|
export declare const FILE_ICON_GLYPHS: Readonly<Record<FileIconType, string>>;
|
|
4
4
|
export declare const FILE_ICON_VIEWBOX: Readonly<Record<FileIconType, string>>;
|
|
5
5
|
export declare function fileIconType(fileName: string | null | undefined): FileIconType;
|
package/dist/file-icons.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export const FILE_ICON_TYPES = [
|
|
2
|
-
'pdf', 'word', 'excel', 'csv', 'ppt', 'text', 'markdown', 'zip', 'video', 'audio', 'image', 'code', 'unknown',
|
|
2
|
+
'pdf', 'word', 'excel', 'csv', 'ppt', 'text', 'markdown', 'zip', 'video', 'audio', 'image', 'code', 'cad', 'unknown',
|
|
3
3
|
'folder', 'folder-open', 'doc', 'table', 'meeting',
|
|
4
4
|
];
|
|
5
5
|
export const FILE_ICON_GLYPHS = {
|
|
@@ -15,6 +15,7 @@ export const FILE_ICON_GLYPHS = {
|
|
|
15
15
|
audio: "<path fill=\"var(--emoo-file-audio, #06b6d4)\" d=\"M7 4h10a3 3 0 0 1 3 3v10a3 3 0 0 1-3 3H7a3 3 0 0 1-3-3V7a3 3 0 0 1 3-3Z\"/><g stroke=\"#fff\" stroke-width=\"1.7\" stroke-linecap=\"round\"><path d=\"M8.5 10.5v3\"/><path d=\"M11 8.5v7\"/><path d=\"M13.5 10v4\"/><path d=\"M16 11v2\"/></g>",
|
|
16
16
|
image: "<path fill=\"var(--emoo-file-image, #22c55e)\" d=\"M7 4h10a3 3 0 0 1 3 3v10a3 3 0 0 1-3 3H7a3 3 0 0 1-3-3V7a3 3 0 0 1 3-3Z\"/><circle cx=\"14.3\" cy=\"9.3\" r=\"1.3\" fill=\"#fff\"/><path d=\"M8 15.8 L11 11.5 L13 14 L14.5 12 L16.5 15.8 Z\" fill=\"#fff\"/>",
|
|
17
17
|
code: "<path fill=\"var(--emoo-file-code, #64748b)\" d=\"M7 4h10a3 3 0 0 1 3 3v10a3 3 0 0 1-3 3H7a3 3 0 0 1-3-3V7a3 3 0 0 1 3-3Z\"/><g fill=\"none\" stroke=\"#fff\" stroke-width=\"1.7\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><path d=\"M9.5 9 L7 12 L9.5 15\"/><path d=\"M14.5 9 L17 12 L14.5 15\"/><path d=\"M12.8 8.2 L11.2 15.8\"/></g>",
|
|
18
|
+
cad: "<path fill=\"var(--emoo-file-cad, #f59e0b)\" d=\"M7 4h10a3 3 0 0 1 3 3v10a3 3 0 0 1-3 3H7a3 3 0 0 1-3-3V7a3 3 0 0 1 3-3Z\"/><g fill=\"none\" stroke=\"#fff\" stroke-width=\"1.55\" stroke-linecap=\"round\" stroke-linejoin=\"round\"><circle cx=\"12\" cy=\"8.3\" r=\"1.3\"/><path d=\"m10.9 9.3-3.1 6.9M13.1 9.3l3.1 6.9M9.7 12.6h4.6\"/></g>",
|
|
18
19
|
unknown: "<path fill=\"var(--emoo-file-unknown, #94a3b8)\" d=\"M7 4h10a3 3 0 0 1 3 3v10a3 3 0 0 1-3 3H7a3 3 0 0 1-3-3V7a3 3 0 0 1 3-3Z\"/><g fill=\"#fff\"><circle cx=\"8.5\" cy=\"12\" r=\"1.3\"/><circle cx=\"12\" cy=\"12\" r=\"1.3\"/><circle cx=\"15.5\" cy=\"12\" r=\"1.3\"/></g>",
|
|
19
20
|
folder: "<path fill=\"var(--emoo-folder-back, #7885c9)\" d=\"M4 8.25A2.25 2.25 0 0 1 6.25 6h3.05a2.25 2.25 0 0 1 1.65.71L12.1 8h5.65A2.25 2.25 0 0 1 20 10.25v7.5A2.25 2.25 0 0 1 17.75 20H6.25A2.25 2.25 0 0 1 4 17.75Z\"/><path fill=\"var(--emoo-folder-front, #a0abeb)\" d=\"M4 10.25h16v7.5A2.25 2.25 0 0 1 17.75 20H6.25A2.25 2.25 0 0 1 4 17.75Z\"/>",
|
|
20
21
|
'folder-open': "<path fill=\"var(--emoo-folder-back, #7885c9)\" d=\"M4 8.25A2.25 2.25 0 0 1 6.25 6h3.05a2.25 2.25 0 0 1 1.65.71L12.1 8h5.65A2.25 2.25 0 0 1 20 10.25V12H4Z\"/><path fill=\"var(--emoo-folder-back, #7885c9)\" d=\"m4 13 16-1.8v3L4 16Z\"/><path fill=\"#252c53\" fill-opacity=\".24\" d=\"m4 13 16-1.8v2L4 15Z\"/><path fill=\"var(--emoo-folder-front, #a0abeb)\" d=\"m4 15 16-1.8v4.55A2.25 2.25 0 0 1 17.75 20H6.25A2.25 2.25 0 0 1 4 17.75Z\"/>",
|
|
@@ -35,6 +36,7 @@ export const FILE_ICON_VIEWBOX = {
|
|
|
35
36
|
audio: '4 4 16 16',
|
|
36
37
|
image: '4 4 16 16',
|
|
37
38
|
code: '4 4 16 16',
|
|
39
|
+
cad: '4 4 16 16',
|
|
38
40
|
unknown: '4 4 16 16',
|
|
39
41
|
folder: '4 5 16 15',
|
|
40
42
|
'folder-open': '4 5 16 15',
|
|
@@ -57,6 +59,7 @@ const EXT_TYPE = {
|
|
|
57
59
|
js: 'code', jsx: 'code', ts: 'code', tsx: 'code', vue: 'code', py: 'code', java: 'code', go: 'code', rs: 'code',
|
|
58
60
|
c: 'code', cpp: 'code', h: 'code', css: 'code', scss: 'code', sh: 'code', bash: 'code', sql: 'code',
|
|
59
61
|
html: 'code', htm: 'code', xml: 'code', json: 'code', yml: 'code', yaml: 'code',
|
|
62
|
+
dwg: 'cad', dxf: 'cad',
|
|
60
63
|
};
|
|
61
64
|
const has = (record, key) => Object.prototype.hasOwnProperty.call(record, key);
|
|
62
65
|
export function fileIconType(fileName) {
|
package/dist/manifest.json
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 3,
|
|
3
3
|
"package": "@emoo-ai/brand",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.17",
|
|
5
5
|
"source": {
|
|
6
|
-
"sha256": "
|
|
6
|
+
"sha256": "090a42d31167444dba4940f3a60c3e9fbd6889fe44c0712652ecf1ff744312e3"
|
|
7
7
|
},
|
|
8
8
|
"files": {
|
|
9
9
|
"tokens.css": {
|
|
10
|
-
"sha256": "
|
|
10
|
+
"sha256": "b7b399d3c83d54c658889df0f641a578858c233a0722558b779c467af9ca3850"
|
|
11
11
|
},
|
|
12
12
|
"colors.js": {
|
|
13
13
|
"sha256": "a2d8ce386855074667695cced5e1d97ab2e4f4b9afc467b23e60d39b517bade4"
|
|
@@ -16,10 +16,10 @@
|
|
|
16
16
|
"sha256": "6591f2d23bcb488bb7f545b15e401a71f031086351f91b411bb645c332487a94"
|
|
17
17
|
},
|
|
18
18
|
"file-icons.js": {
|
|
19
|
-
"sha256": "
|
|
19
|
+
"sha256": "a6f3bcfd48dc041c67d28152d0deac10e75496f47a67c2f04a664b3c56c8347d"
|
|
20
20
|
},
|
|
21
21
|
"file-icons.d.ts": {
|
|
22
|
-
"sha256": "
|
|
22
|
+
"sha256": "d4b0d61f3a9ef197456e92a303049e933eb1c79a433000611dceb9ae50ca424d"
|
|
23
23
|
}
|
|
24
24
|
}
|
|
25
25
|
}
|
package/dist/tokens.css
CHANGED
|
@@ -97,6 +97,7 @@
|
|
|
97
97
|
--emoo-file-audio: #06b6d4;
|
|
98
98
|
--emoo-file-image: #22c55e;
|
|
99
99
|
--emoo-file-code: #64748b;
|
|
100
|
+
--emoo-file-cad: #f59e0b;
|
|
100
101
|
--emoo-file-unknown: #94a3b8;
|
|
101
102
|
--emoo-folder-back: #7885c9;
|
|
102
103
|
--emoo-folder-front: #a0abeb;
|
|
@@ -173,6 +174,7 @@
|
|
|
173
174
|
--emoo-file-audio: #22d3ee;
|
|
174
175
|
--emoo-file-image: #4ade80;
|
|
175
176
|
--emoo-file-code: #8593b0;
|
|
177
|
+
--emoo-file-cad: #fbbf24;
|
|
176
178
|
--emoo-file-unknown: #a5aebd;
|
|
177
179
|
--emoo-folder-back: #8997da;
|
|
178
180
|
--emoo-folder-front: #b0baf1;
|