uview-ultra-plus 1.10.1 → 1.10.3
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/package.json +2 -2
- package/dist/scripts/build.js +22 -15
- package/dist/scripts/patch-imports.js +9 -1
- package/dist/uview-ultra/components/up-calendar/month.uvue +1 -1
- package/dist/uview-ultra/components/up-calendar/up-calendar.uvue +1 -1
- package/dist/uview-ultra/components/up-calendar/util.uts +1 -1
- package/dist/uview-ultra/components/up-datetime-picker/up-datetime-picker.uvue +1 -1
- package/dist/uview-ultra/package-lock.json +2 -2
- package/dist/uview-ultra/package.json +1 -1
- package/package.json +2 -2
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "uview-ultra-plus",
|
|
3
|
-
"version": "1.10.
|
|
3
|
+
"version": "1.10.3",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"registry": "https://registry.npmjs.org/"
|
|
6
6
|
},
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
"uview-ultra-plus": "dist/scripts/install.js"
|
|
13
13
|
},
|
|
14
14
|
"scripts": {
|
|
15
|
-
"release": "
|
|
15
|
+
"release": "release-it",
|
|
16
16
|
"build": "node scripts/build.js",
|
|
17
17
|
"rollup": "rollup -c rollup.config.mjs",
|
|
18
18
|
"test": "echo \"No test specified\""
|
package/dist/scripts/build.js
CHANGED
|
@@ -23,22 +23,29 @@ function clean() {
|
|
|
23
23
|
|
|
24
24
|
function copySource() {
|
|
25
25
|
console.log('[Build] Copying source to dist (excluding node_modules)...');
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
26
|
+
|
|
27
|
+
// Main components
|
|
28
|
+
const uviewSrc = path.join(projectRoot, 'src/uview-ultra');
|
|
29
|
+
const uviewDest = path.join(distPath, 'uview-ultra');
|
|
30
|
+
|
|
31
|
+
if (fs.existsSync(uviewSrc)) {
|
|
32
|
+
execSync(`rsync -aq --exclude='node_modules' --exclude='uts-libs' "${uviewSrc}/" "${uviewDest}/"`);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
// lime-dayuts (moved to src/uview-ultra/uts-libs/lime-dayuts)
|
|
36
|
+
const limeSrc = path.join(projectRoot, 'src/uview-ultra/uts-libs/lime-dayuts');
|
|
37
|
+
const limeDest = path.join(distPath, 'lime-dayuts');
|
|
38
|
+
if (fs.existsSync(limeSrc)) {
|
|
39
|
+
if (!fs.existsSync(limeDest)) fs.mkdirSync(limeDest, { recursive: true });
|
|
40
|
+
execSync(`rsync -aq --exclude='node_modules' "${limeSrc}/" "${limeDest}/"`);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
// Other core files
|
|
44
|
+
const otherFiles = ['scripts', 'index.js', 'index.d.ts', 'theme.scss', 'package.json'];
|
|
45
|
+
otherFiles.forEach(file => {
|
|
46
|
+
const srcPath = path.join(projectRoot, file);
|
|
30
47
|
if (fs.existsSync(srcPath)) {
|
|
31
|
-
|
|
32
|
-
try {
|
|
33
|
-
execSync(`rsync -aq --exclude='node_modules' "${srcPath}" "${distPath}/"`);
|
|
34
|
-
} catch (e) {
|
|
35
|
-
// Fallback for environments without rsync (though unlikely on Mac)
|
|
36
|
-
if (fs.lstatSync(srcPath).isDirectory()) {
|
|
37
|
-
copyRecursiveSync(srcPath, destPath);
|
|
38
|
-
} else {
|
|
39
|
-
fs.copyFileSync(srcPath, destPath);
|
|
40
|
-
}
|
|
41
|
-
}
|
|
48
|
+
execSync(`rsync -aq --exclude='node_modules' "${srcPath}" "${distPath}/"`);
|
|
42
49
|
}
|
|
43
50
|
});
|
|
44
51
|
}
|
|
@@ -31,11 +31,19 @@ const replacements = [
|
|
|
31
31
|
const relPath = path.relative(path.dirname(filePath), path.join(distUViewPath, 'vendor/clipboard.min.js'));
|
|
32
32
|
return `import Clipboard from './${relPath}'`;
|
|
33
33
|
}
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
pattern: /@\/uni_modules\/lime-dayuts/g,
|
|
37
|
+
replacement: (filePath) => {
|
|
38
|
+
const relToDist = path.relative(path.dirname(filePath), path.dirname(distUViewPath));
|
|
39
|
+
// In dist, lime-dayuts is a peer of uview-ultra
|
|
40
|
+
return `./${relToDist}/lime-dayuts`;
|
|
41
|
+
}
|
|
34
42
|
}
|
|
35
43
|
];
|
|
36
44
|
|
|
37
45
|
function patchFile(filePath) {
|
|
38
|
-
if (!['.js', '.vue', '.uvue'].some(ext => filePath.endsWith(ext))) return;
|
|
46
|
+
if (!['.js', '.vue', '.uvue', '.uts'].some(ext => filePath.endsWith(ext))) return;
|
|
39
47
|
|
|
40
48
|
let content = fs.readFileSync(filePath, 'utf8');
|
|
41
49
|
let changed = false;
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
import { array as testArray } from '../../libs/function/test';
|
|
39
39
|
import defProps from './calendar.uts';
|
|
40
40
|
let calendarProp = defProps['calendar'] as UTSJSONObject;
|
|
41
|
-
import {dayuts} from '
|
|
41
|
+
import {dayuts} from './../../../lime-dayuts';
|
|
42
42
|
export type monthsItemDate = {
|
|
43
43
|
date: Date
|
|
44
44
|
selected: boolean | null
|
|
@@ -66,7 +66,7 @@ import uHeader from './header.uvue'
|
|
|
66
66
|
import uMonth, { monthsItem, monthsItemDate } from './month.uvue'
|
|
67
67
|
import { propsCalendar } from './props'
|
|
68
68
|
import util from './util'
|
|
69
|
-
import {dayuts} from '
|
|
69
|
+
import {dayuts} from './../../../lime-dayuts';
|
|
70
70
|
// import Calendar from '../../libs/util/calendar'
|
|
71
71
|
import { mpMixin } from '../../libs/mixin/mpMixin'
|
|
72
72
|
import { mixin } from '../../libs/mixin/mixin'
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
// 导入ref
|
|
48
48
|
import type { PropType } from 'vue'
|
|
49
49
|
import { ref } from 'vue';
|
|
50
|
-
import {dayuts} from '
|
|
50
|
+
import {dayuts} from './../../../lime-dayuts';
|
|
51
51
|
import { range, error, padZero } from '../../libs/function/index.uts';
|
|
52
52
|
import { date as testDate } from '../../libs/function/test.uts';
|
|
53
53
|
import defProps from './datetimePicker.uts';
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "uview-ultra",
|
|
3
|
-
"version": "1.10.
|
|
3
|
+
"version": "1.10.3",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "uview-ultra",
|
|
9
|
-
"version": "1.10.
|
|
9
|
+
"version": "1.10.3",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"clipboard": "^2.0.11",
|
|
12
12
|
"dayjs": "^1.11.3"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "uview-ultra-plus",
|
|
3
|
-
"version": "1.10.
|
|
3
|
+
"version": "1.10.3",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"registry": "https://registry.npmjs.org/"
|
|
6
6
|
},
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
"uview-ultra-plus": "dist/scripts/install.js"
|
|
13
13
|
},
|
|
14
14
|
"scripts": {
|
|
15
|
-
"release": "
|
|
15
|
+
"release": "release-it",
|
|
16
16
|
"build": "node scripts/build.js",
|
|
17
17
|
"rollup": "rollup -c rollup.config.mjs",
|
|
18
18
|
"test": "echo \"No test specified\""
|