@atooyu/uxto-fronted 1.0.3 → 1.0.5

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.
@@ -2,6 +2,9 @@ import { createSSRApp } from 'vue'
2
2
  import { createPinia } from 'pinia'
3
3
  import App from './App.vue'
4
4
 
5
+ // 引入 UXTO UI 组件库样式
6
+ import '@atooyu/uxto-ui/style'
7
+
5
8
  export function createApp() {
6
9
  const app = createSSRApp(App)
7
10
  const pinia = createPinia()
@@ -22,7 +22,7 @@
22
22
  "easycom": {
23
23
  "autoscan": true,
24
24
  "custom": {
25
- "^u-(.*)": "uxto-ui/u-$1/u-$1.vue"
25
+ "^u-(.*)": "@atooyu/uxto-ui/src/components/u-$1/u-$1.vue"
26
26
  }
27
27
  }
28
28
  }
@@ -2,8 +2,8 @@ const { defineConfig } = require('vite')
2
2
  const uni = require('@dcloudio/vite-plugin-uni').default
3
3
  const path = require('path')
4
4
 
5
- const uxtoUiComponentsPath = path.resolve(__dirname, '../../uxto-ui/src/components').replace(/\\/g, '/')
6
- const variablesPath = path.resolve(__dirname, '../../uxto-ui/src/styles/variables.scss').replace(/\\/g, '/')
5
+ const uxtoUiPath = path.resolve(__dirname, '../../uxto-ui').replace(/\\/g, '/')
6
+ const variablesPath = path.join(uxtoUiPath, 'src/styles/variables.scss').replace(/\\/g, '/')
7
7
 
8
8
  module.exports = defineConfig({
9
9
  plugins: [uni()],
@@ -13,8 +13,9 @@ module.exports = defineConfig({
13
13
  },
14
14
  resolve: {
15
15
  alias: {
16
- '@': path.resolve(__dirname, 'src').replace(/\\/g, '/'),
17
- 'uxto-ui': uxtoUiComponentsPath
16
+ '@': path.resolve(__dirname, 'src').replace(/\\/g, '/')
17
+ // 注意: 不要将 uxto-ui 别名到 components,否则会破坏样式导入
18
+ // easycom 已经配置了组件自动导入
18
19
  },
19
20
  extensions: ['.mjs', '.js', '.ts', '.jsx', '.tsx', '.json', '.vue']
20
21
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atooyu/uxto-fronted",
3
- "version": "1.0.3",
3
+ "version": "1.0.5",
4
4
  "description": "UXTO UniApp 前端脚手架模板 - 支持 iOS、Android、鸿蒙",
5
5
  "keywords": [
6
6
  "uxto",
@@ -14,7 +14,7 @@
14
14
  "build:harmony": "uni build -p app-harmony"
15
15
  },
16
16
  "dependencies": {
17
- "@atooyu/uxto-ui": "^1.0.2",
17
+ "@atooyu/uxto-ui": "^1.0.3",
18
18
  "@dcloudio/uni-app": "3.0.0-4060620250520001",
19
19
  "@dcloudio/uni-app-harmony": "3.0.0-4060620250520001",
20
20
  "@dcloudio/uni-components": "3.0.0-4060620250520001",
@@ -2,6 +2,9 @@ import { createSSRApp } from 'vue'
2
2
  import { createPinia } from 'pinia'
3
3
  import App from './App.vue'
4
4
 
5
+ // 引入 UXTO UI 组件库样式
6
+ import '@atooyu/uxto-ui/style'
7
+
5
8
  export function createApp() {
6
9
  const app = createSSRApp(App)
7
10
  const pinia = createPinia()
@@ -13,8 +13,9 @@ module.exports = defineConfig({
13
13
  resolve: {
14
14
  alias: {
15
15
  '@': path.resolve(__dirname, 'src').replace(/\\/g, '/'),
16
- 'uxto-ui': uxtoUiComponentsPath,
17
- '@atooyu/uxto-ui': uxtoUiComponentsPath
16
+ // 注意: 不要将 @atooyu/uxto-ui 整体别名到 components,
17
+ // 否则会破坏样式导入 (@atooyu/uxto-ui/style) 的解析
18
+ // easycom 已经配置了组件自动导入
18
19
  },
19
20
  extensions: ['.mjs', '.js', '.ts', '.jsx', '.tsx', '.json', '.vue']
20
21
  },