@fastkit/vui 0.10.0 → 0.10.2
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/tool/{index.js → index.mjs} +18 -20
- package/package.json +12 -9
- package/src/tool/vite-plugin.ts +7 -7
- package/dist/vui.cjs.js +0 -5556
- package/dist/vui.cjs.prod.js +0 -5556
- package/dist/vui.min.css +0 -5
- package/dist/vui.min.css.map +0 -1
- package/index.js +0 -6
|
@@ -1,28 +1,26 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
var eta = require('eta');
|
|
8
|
-
var tinyLogger = require('@fastkit/tiny-logger');
|
|
1
|
+
import { dynamicSrcVitePlugin } from '@fastkit/vite-kit';
|
|
2
|
+
import path from 'path';
|
|
3
|
+
import fs from 'fs-extra';
|
|
4
|
+
import { getDirname, findPackageDirSync } from '@fastkit/node-util';
|
|
5
|
+
import { render } from 'eta';
|
|
6
|
+
import { TinyLogger, createTinyError } from '@fastkit/tiny-logger';
|
|
9
7
|
|
|
10
8
|
const name = 'vui';
|
|
11
|
-
new
|
|
12
|
-
const VuiError =
|
|
9
|
+
new TinyLogger(name);
|
|
10
|
+
const VuiError = createTinyError(name);
|
|
13
11
|
|
|
14
|
-
const VUI_PACKAGE_DIR = path.resolve(
|
|
12
|
+
const VUI_PACKAGE_DIR = path.resolve(getDirname(import.meta.url), '../..');
|
|
15
13
|
const STYLE_AFTER_EFFECTS_PATH = path.join(VUI_PACKAGE_DIR, 'src/styles/after-effects.scss');
|
|
16
14
|
const COLOR_DUMP_STYLE = `@include dump-color-scheme(true);`;
|
|
17
15
|
const TEMPLATE = `
|
|
18
16
|
/* eslint-disable */
|
|
19
17
|
// @ts-nocheck
|
|
20
18
|
<% if (!it.__dev) { %>
|
|
21
|
-
import '@fastkit/vue-stack/
|
|
22
|
-
import '@fastkit/vue-app-layout/
|
|
23
|
-
import '@fastkit/vue-loading/
|
|
24
|
-
import '@fastkit/vue-scroller/
|
|
25
|
-
import '@fastkit/vui/
|
|
19
|
+
import '@fastkit/vue-stack/vue-stack.css';
|
|
20
|
+
import '@fastkit/vue-app-layout/vue-app-layout.css';
|
|
21
|
+
import '@fastkit/vue-loading/vue-loading.css';
|
|
22
|
+
import '@fastkit/vue-scroller/vue-scroller.css';
|
|
23
|
+
import '@fastkit/vui/vui.css';
|
|
26
24
|
<% } %>
|
|
27
25
|
import './setup.scss';
|
|
28
26
|
import type { App } from 'vue';
|
|
@@ -48,7 +46,7 @@ export function installVui(settings: { app: App, router: Router }, options?: Raw
|
|
|
48
46
|
export default installVui;
|
|
49
47
|
`.trim();
|
|
50
48
|
async function renderTemplate({ colorScheme, mediaMatch, uiSettings, icons, __dev, }) {
|
|
51
|
-
const result = await
|
|
49
|
+
const result = await render(TEMPLATE, {
|
|
52
50
|
colorScheme,
|
|
53
51
|
mediaMatch,
|
|
54
52
|
uiSettings: JSON.stringify(uiSettings),
|
|
@@ -64,7 +62,7 @@ function defaultDynamicDest() {
|
|
|
64
62
|
return path.resolve('.vui');
|
|
65
63
|
}
|
|
66
64
|
function getBuiltinsDir() {
|
|
67
|
-
const pkgDir =
|
|
65
|
+
const pkgDir = findPackageDirSync(undefined, true);
|
|
68
66
|
if (!pkgDir) {
|
|
69
67
|
throw new Error(`missing package directory`);
|
|
70
68
|
}
|
|
@@ -149,7 +147,7 @@ export {};
|
|
|
149
147
|
};
|
|
150
148
|
});
|
|
151
149
|
}
|
|
152
|
-
plugins.push(
|
|
150
|
+
plugins.push(dynamicSrcVitePlugin({
|
|
153
151
|
colorScheme: {
|
|
154
152
|
src: colorSchemeSrc,
|
|
155
153
|
dest: colorSchemeDest,
|
|
@@ -192,4 +190,4 @@ export {};
|
|
|
192
190
|
};
|
|
193
191
|
}
|
|
194
192
|
|
|
195
|
-
|
|
193
|
+
export { viteVuiPlugin };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fastkit/vui",
|
|
3
|
-
"version": "0.10.
|
|
3
|
+
"version": "0.10.2",
|
|
4
4
|
"description": "A simple, extensible UI kit for Vue applications.",
|
|
5
5
|
"buildOptions": {
|
|
6
6
|
"name": "Vui",
|
|
@@ -14,10 +14,13 @@
|
|
|
14
14
|
"ja": "Vueアプリケーション用のシンプルで拡張可能なUIキット。"
|
|
15
15
|
}
|
|
16
16
|
},
|
|
17
|
-
"main": "
|
|
18
|
-
"
|
|
17
|
+
"main": "./dist/vui.mjs",
|
|
18
|
+
"exports": {
|
|
19
|
+
"./vui.css": "./dist/vui.css",
|
|
20
|
+
"./tool": "./dist/tool/index.mjs",
|
|
21
|
+
".": "./dist/vui.mjs"
|
|
22
|
+
},
|
|
19
23
|
"files": [
|
|
20
|
-
"index.js",
|
|
21
24
|
"dist",
|
|
22
25
|
"src"
|
|
23
26
|
],
|
|
@@ -43,11 +46,11 @@
|
|
|
43
46
|
"vue": "^3.2.45"
|
|
44
47
|
},
|
|
45
48
|
"dependencies": {
|
|
46
|
-
"@fastkit/color-scheme": "0.10.
|
|
47
|
-
"@fastkit/icon-font": "0.10.
|
|
48
|
-
"@fastkit/tiny-logger": "0.10.
|
|
49
|
-
"@fastkit/vite-kit": "0.10.
|
|
50
|
-
"@fastkit/vue-kit": "0.10.
|
|
49
|
+
"@fastkit/color-scheme": "0.10.2",
|
|
50
|
+
"@fastkit/icon-font": "0.10.2",
|
|
51
|
+
"@fastkit/tiny-logger": "0.10.2",
|
|
52
|
+
"@fastkit/vite-kit": "0.10.2",
|
|
53
|
+
"@fastkit/vue-kit": "0.10.2",
|
|
51
54
|
"@tiptap/extension-link": "^2.0.0-beta.209",
|
|
52
55
|
"@tiptap/extension-text-style": "^2.0.0-beta.209",
|
|
53
56
|
"@tiptap/extension-underline": "^2.0.0-beta.209",
|
package/src/tool/vite-plugin.ts
CHANGED
|
@@ -2,13 +2,13 @@ import { Plugin } from 'vite';
|
|
|
2
2
|
import { dynamicSrcVitePlugin } from '@fastkit/vite-kit';
|
|
3
3
|
import path from 'path';
|
|
4
4
|
import fs from 'fs-extra';
|
|
5
|
-
import { findPackageDirSync } from '@fastkit/node-util';
|
|
5
|
+
import { findPackageDirSync, getDirname } from '@fastkit/node-util';
|
|
6
6
|
import { RawIconFontEntry, IconFontSettings } from '@fastkit/icon-font-gen';
|
|
7
7
|
import { VuiServiceOptions } from '../service';
|
|
8
8
|
import { render } from 'eta';
|
|
9
9
|
import { VuiError } from '../logger';
|
|
10
10
|
|
|
11
|
-
const VUI_PACKAGE_DIR = path.resolve(
|
|
11
|
+
const VUI_PACKAGE_DIR = path.resolve(getDirname(import.meta.url), '../..');
|
|
12
12
|
const STYLE_AFTER_EFFECTS_PATH = path.join(
|
|
13
13
|
VUI_PACKAGE_DIR,
|
|
14
14
|
'src/styles/after-effects.scss',
|
|
@@ -20,11 +20,11 @@ const TEMPLATE = `
|
|
|
20
20
|
/* eslint-disable */
|
|
21
21
|
// @ts-nocheck
|
|
22
22
|
<% if (!it.__dev) { %>
|
|
23
|
-
import '@fastkit/vue-stack/
|
|
24
|
-
import '@fastkit/vue-app-layout/
|
|
25
|
-
import '@fastkit/vue-loading/
|
|
26
|
-
import '@fastkit/vue-scroller/
|
|
27
|
-
import '@fastkit/vui/
|
|
23
|
+
import '@fastkit/vue-stack/vue-stack.css';
|
|
24
|
+
import '@fastkit/vue-app-layout/vue-app-layout.css';
|
|
25
|
+
import '@fastkit/vue-loading/vue-loading.css';
|
|
26
|
+
import '@fastkit/vue-scroller/vue-scroller.css';
|
|
27
|
+
import '@fastkit/vui/vui.css';
|
|
28
28
|
<% } %>
|
|
29
29
|
import './setup.scss';
|
|
30
30
|
import type { App } from 'vue';
|