balm-core 4.27.0 → 4.27.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/README.md +15 -9
- package/lib/plugins/sass.js +8 -4
- package/lib/tasks/public/zip.js +2 -1
- package/package.json +2 -2
- package/tslib/plugins/sass.js +8 -3
- package/tslib/tasks/public/zip.js +2 -1
package/README.md
CHANGED
|
@@ -152,15 +152,17 @@ To download [example](https://balm.js.org/balm-example.zip) and try it, visit [b
|
|
|
152
152
|
|
|
153
153
|
## Ecosystem
|
|
154
154
|
|
|
155
|
-
| Project
|
|
156
|
-
|
|
|
157
|
-
| **[balm-core](https://github.com/balmjs/balm)**
|
|
158
|
-
| **[balm](https://github.com/balmjs/balm)**
|
|
159
|
-
| **[balm-cli](https://github.com/balmjs/balm-cli)**
|
|
160
|
-
| [balm-gui](https://github.com/balmjs/balm-gui)
|
|
161
|
-
| [balm-ui-lite](https://github.com/balmjs/ui-vue-lite)
|
|
162
|
-
| **[balm-ui](https://github.com/balmjs/ui-vue)**
|
|
163
|
-
| [balm-scroll](https://github.com/balmjs/balm-scroll)
|
|
155
|
+
| Project | Status | Description |
|
|
156
|
+
| ---------------------------------------------------------- | -------------------------------------------------------- | ------------------------------------------------------------------ |
|
|
157
|
+
| **[balm-core](https://github.com/balmjs/balm)** | [![NPM version][balm-core-image]][balm-core-url] | :black_joker: BalmJS compiler core (required for `balm 3.0+`) |
|
|
158
|
+
| **[balm](https://github.com/balmjs/balm)** | [![NPM version][balm-image]][balm-url] | :black_joker: BalmJS runtime core |
|
|
159
|
+
| **[balm-cli](https://github.com/balmjs/balm-cli)** | [![NPM version][balm-cli-image]][balm-cli-url] | :spades: BalmJS scaffolding tool |
|
|
160
|
+
| [balm-gui](https://github.com/balmjs/balm-gui) | N/A | :clubs: GUI for BalmJS |
|
|
161
|
+
| [balm-ui-lite](https://github.com/balmjs/ui-vue-lite) | [![NPM version][balm-ui-lite-image]][balm-ui-lite-url] | :hearts: Material Design Lite + Vue |
|
|
162
|
+
| **[balm-ui](https://github.com/balmjs/ui-vue)** | [![NPM version][balm-ui-image]][balm-ui-url] | :diamonds: Next Generation Material UI for Vue.js |
|
|
163
|
+
| [balm-scroll](https://github.com/balmjs/balm-scroll) | [![NPM version][balm-scroll-image]][balm-scroll-url] | :scroll: Smooth scrolling for Vue.js |
|
|
164
|
+
| **[balm-ui-pro](https://github.com/balmjs/balm-ui-pro)** | [![NPM version][balm-ui-pro-image]][balm-ui-pro-url] | More configuration definition, less code implementation for Vue.js |
|
|
165
|
+
| **[balm-git-flow](https://github.com/balmjs/balm-ui-pro)** | [![NPM version][balm-git-flow-image]][balm-git-flow-url] | The best practices for front-end git flow |
|
|
164
166
|
|
|
165
167
|
## Contributing
|
|
166
168
|
|
|
@@ -188,3 +190,7 @@ We'd love for you to contribute and make BalmJS even better than it is today! Pl
|
|
|
188
190
|
[balm-ui-url]: https://npmjs.org/package/balm-ui
|
|
189
191
|
[balm-scroll-image]: https://img.shields.io/npm/v/balm-scroll.svg
|
|
190
192
|
[balm-scroll-url]: https://npmjs.org/package/balm-scroll
|
|
193
|
+
[balm-ui-pro-image]: https://badge.fury.io/js/balm-ui-pro.svg
|
|
194
|
+
[balm-ui-pro-url]: https://npmjs.org/package/balm-ui-pro
|
|
195
|
+
[balm-git-flow-image]: https://badge.fury.io/js/balm-git-flow.svg
|
|
196
|
+
[balm-git-flow-url]: https://npmjs.org/package/balm-git-flow
|
package/lib/plugins/sass.js
CHANGED
|
@@ -3,15 +3,18 @@ import { pathToFileURL } from 'node:url';
|
|
|
3
3
|
// Reference `gulp-sass@5.1.0`
|
|
4
4
|
import { Transform } from 'node:stream';
|
|
5
5
|
import semver from 'semver';
|
|
6
|
-
import sass from 'sass';
|
|
6
|
+
import * as sass from 'sass';
|
|
7
7
|
import replaceExtension from 'replace-ext';
|
|
8
8
|
import stripAnsi from 'strip-ansi';
|
|
9
9
|
import applySourceMap from 'vinyl-sourcemaps-apply';
|
|
10
10
|
import ansiColors from 'ansi-colors';
|
|
11
11
|
process.env.BALM_CWD = process.env.INIT_CWD || process.cwd();
|
|
12
12
|
const localSassModule = node.path.join(process.env.BALM_CWD, 'node_modules', 'sass');
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
let isLegacy = false;
|
|
14
|
+
try {
|
|
15
|
+
const sassPkg = requireModule(node.path.join(localSassModule, 'package.json'));
|
|
16
|
+
isLegacy = semver.lt(sassPkg.version, '1.40.0');
|
|
17
|
+
} catch (_) {}
|
|
15
18
|
const nodeLocalSassModule = node.path.join(localSassModule, 'sass.node.js');
|
|
16
19
|
const defaultLocalSassModule = node.path.join(localSassModule, 'sass.default.js'); // For `npm i -D sass <= 1.62.1`
|
|
17
20
|
const dartLocalSassModule = node.path.join(localSassModule, 'sass.dart.js'); // For `npm i -D sass <= 1.39.2`
|
|
@@ -186,4 +189,5 @@ const gulpSass = options => transformObj((file, encoding, callback) => {
|
|
|
186
189
|
isLegacy ? legacyHandleError(error, file, callback) : handleError(error, file, callback);
|
|
187
190
|
}
|
|
188
191
|
});
|
|
189
|
-
export default gulpSass;
|
|
192
|
+
export default gulpSass;
|
|
193
|
+
export { isLegacy };
|
package/lib/tasks/public/zip.js
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import zip from 'gulp-zip';
|
|
1
2
|
class ZipTask extends BalmJS.BalmTask {
|
|
2
3
|
constructor() {
|
|
3
4
|
super('zip');
|
|
@@ -7,7 +8,7 @@ class ZipTask extends BalmJS.BalmTask {
|
|
|
7
8
|
recipe(input, output, filename = 'archive.zip') {
|
|
8
9
|
const balmZip = () => {
|
|
9
10
|
this.init(input, output);
|
|
10
|
-
return this.src.pipe(
|
|
11
|
+
return this.src.pipe(zip(filename)).pipe(gulp.dest(this.output));
|
|
11
12
|
};
|
|
12
13
|
return balmZip;
|
|
13
14
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "balm-core",
|
|
3
|
-
"version": "4.27.
|
|
3
|
+
"version": "4.27.2",
|
|
4
4
|
"description": "BalmJS compiler core",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"balm",
|
|
@@ -130,5 +130,5 @@
|
|
|
130
130
|
"engines": {
|
|
131
131
|
"node": ">=18.12.0"
|
|
132
132
|
},
|
|
133
|
-
"gitHead": "
|
|
133
|
+
"gitHead": "b9c211555deab271335142dd7e469a3b70a77481"
|
|
134
134
|
}
|
package/tslib/plugins/sass.js
CHANGED
|
@@ -2,15 +2,19 @@ import fs from 'node:fs';
|
|
|
2
2
|
import { pathToFileURL } from 'node:url';
|
|
3
3
|
import { Transform } from 'node:stream';
|
|
4
4
|
import semver from 'semver';
|
|
5
|
-
import sass from 'sass';
|
|
5
|
+
import * as sass from 'sass';
|
|
6
6
|
import replaceExtension from 'replace-ext';
|
|
7
7
|
import stripAnsi from 'strip-ansi';
|
|
8
8
|
import applySourceMap from 'vinyl-sourcemaps-apply';
|
|
9
9
|
import ansiColors from 'ansi-colors';
|
|
10
10
|
process.env.BALM_CWD = process.env.INIT_CWD || process.cwd();
|
|
11
11
|
const localSassModule = node.path.join(process.env.BALM_CWD, 'node_modules', 'sass');
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
let isLegacy = false;
|
|
13
|
+
try {
|
|
14
|
+
const sassPkg = requireModule(node.path.join(localSassModule, 'package.json'));
|
|
15
|
+
isLegacy = semver.lt(sassPkg.version, '1.40.0');
|
|
16
|
+
}
|
|
17
|
+
catch (_) { }
|
|
14
18
|
const nodeLocalSassModule = node.path.join(localSassModule, 'sass.node.js');
|
|
15
19
|
const defaultLocalSassModule = node.path.join(localSassModule, 'sass.default.js');
|
|
16
20
|
const dartLocalSassModule = node.path.join(localSassModule, 'sass.dart.js');
|
|
@@ -164,3 +168,4 @@ const gulpSass = (options) => transformObj((file, encoding, callback) => {
|
|
|
164
168
|
}
|
|
165
169
|
});
|
|
166
170
|
export default gulpSass;
|
|
171
|
+
export { isLegacy };
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import zip from 'gulp-zip';
|
|
1
2
|
class ZipTask extends BalmJS.BalmTask {
|
|
2
3
|
constructor() {
|
|
3
4
|
super('zip');
|
|
@@ -7,7 +8,7 @@ class ZipTask extends BalmJS.BalmTask {
|
|
|
7
8
|
recipe(input, output, filename = 'archive.zip') {
|
|
8
9
|
const balmZip = () => {
|
|
9
10
|
this.init(input, output);
|
|
10
|
-
return this.src.pipe(
|
|
11
|
+
return this.src.pipe(zip(filename)).pipe(gulp.dest(this.output));
|
|
11
12
|
};
|
|
12
13
|
return balmZip;
|
|
13
14
|
}
|