Skip to content

Commit

Permalink
release(16.3.0): release 16.3.0 (#1645)
Browse files Browse the repository at this point in the history
  • Loading branch information
cipchk authored Sep 1, 2023
1 parent 1f8def7 commit 5dc859e
Show file tree
Hide file tree
Showing 9 changed files with 115 additions and 27 deletions.
4 changes: 4 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,10 @@ module.exports = {
rules: {
'prettier/prettier': ['error', { parser: 'angular' }]
}
},
{
files: ['*.js'],
parserOptions: { sourceType: 'module' }
}
]
};
22 changes: 22 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,25 @@
# [16.3.0](https://github.com/ng-alain/delon/compare/16.2.1...16.3.0) (2023-09-01)


### Bug Fixes

* **abc:pdf:** fix ignore dependency `pdfjs-dist` ([#1641](https://github.com/ng-alain/delon/issues/1641)) ([b987bab](https://github.com/ng-alain/delon/commit/b987baba6035eb60872c4ee48198568df140869c))
* **form:select:** fix ignore reset option data when set `onSearch` ([#1644](https://github.com/ng-alain/delon/issues/1644)) ([1f8def7](https://github.com/ng-alain/delon/commit/1f8def70856c091ed677cbd47aed7ca230a2aa79))
* **theme:http:** fix missing `content` of `HttpOptions` ([#1640](https://github.com/ng-alain/delon/issues/1640)) ([28eeceb](https://github.com/ng-alain/delon/commit/28eecebd7ab71a1b9a8345c0af1ebe22fd3bc1a6))


### Features

* **abc:cell:** add `cell` component ([#1530](https://github.com/ng-alain/delon/issues/1530)) ([26023ca](https://github.com/ng-alain/delon/commit/26023cac7a91cae5383cfffd26d44fba6a95fb9f))
* **abc:page-header:** add `titleSub` property ([#1643](https://github.com/ng-alain/delon/issues/1643)) ([79e229f](https://github.com/ng-alain/delon/commit/79e229f5c1b509dd463c48e4a82b361e5d923920))
* **abc:st:** add `tooltip` in tag or badge ([#1634](https://github.com/ng-alain/delon/issues/1634)) ([0e9006e](https://github.com/ng-alain/delon/commit/0e9006e5b9fd30092b5a808f9b3d8012fd3a060c))
* **abc:sv:** add `bordered` property ([#1628](https://github.com/ng-alain/delon/issues/1628)) ([ccfa5e1](https://github.com/ng-alain/delon/commit/ccfa5e1d6f5cf1d3f9bc5360bc2e373604ae22a2))
* **cli:** add `bindToComponentInputs` of `ng add` ([#1630](https://github.com/ng-alain/delon/issues/1630)) ([9717d9d](https://github.com/ng-alain/delon/commit/9717d9dd4ee1d5ab1526616a99da7b70e8664bd2))
* **theme:drawer:** add `closeAll`, `openDrawers` method ([#1627](https://github.com/ng-alain/delon/issues/1627)) ([bab3d0c](https://github.com/ng-alain/delon/commit/bab3d0c3c648d933784c4623b2714ac227219c5c))
* **theme:modal:** add size support percentage ([#1626](https://github.com/ng-alain/delon/issues/1626)) ([8b52a08](https://github.com/ng-alain/delon/commit/8b52a08d82378a42e06c316757e19e5434e109dc))



## [16.2.1](https://github.com/ng-alain/delon/compare/16.2.0...16.2.1) (2023-08-06)


Expand Down
23 changes: 23 additions & 0 deletions docs/changelog.en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,29 @@ NG-ALAIN strictly follows [Semantic Versioning 2.0.0](http://semver.org/lang/zh-

---

# [16.3.0](https://github.com/ng-alain/delon/compare/16.2.1...16.3.0) (2023-09-01)

### SCAFFOLDING

* enabled `bindToComponentInputs` [#2409](https://github.com/ng-alain/ng-alain/pull/2409/files).

### Bug Fixes

* **abc:pdf:** fix ignore dependency `pdfjs-dist` (If you [use local path](https://ng-alain.com/components/pdf) to load the libary, you need to install the dependency yourself. `pdfjs-dist` depends on `canvas`, which may be slow to install dependencies due to environmental factors) ([#1641](https://github.com/ng-alain/delon/issues/1641)) ([#1641](https://github.com/ng-alain/delon/issues/1641)) ([b987bab](https://github.com/ng-alain/delon/commit/b987baba6035eb60872c4ee48198568df140869c))
* **form:select:** fix ignore reset option data when set `onSearch` ([#1644](https://github.com/ng-alain/delon/issues/1644)) ([1f8def7](https://github.com/ng-alain/delon/commit/1f8def70856c091ed677cbd47aed7ca230a2aa79))
* **theme:http:** fix missing `content` of `HttpOptions` ([#1640](https://github.com/ng-alain/delon/issues/1640)) ([28eeceb](https://github.com/ng-alain/delon/commit/28eecebd7ab71a1b9a8345c0af1ebe22fd3bc1a6))

### Features

* **abc:cell:** add `cell` component ([#1530](https://github.com/ng-alain/delon/issues/1530)) ([26023ca](https://github.com/ng-alain/delon/commit/26023cac7a91cae5383cfffd26d44fba6a95fb9f))
* **abc:page-header:** add `titleSub` property ([#1643](https://github.com/ng-alain/delon/issues/1643)) ([79e229f](https://github.com/ng-alain/delon/commit/79e229f5c1b509dd463c48e4a82b361e5d923920))
* **abc:st:** add `tooltip` in tag or badge ([#1634](https://github.com/ng-alain/delon/issues/1634)) ([0e9006e](https://github.com/ng-alain/delon/commit/0e9006e5b9fd30092b5a808f9b3d8012fd3a060c))
* **abc:sv:** add `bordered` property ([#1628](https://github.com/ng-alain/delon/issues/1628)) ([ccfa5e1](https://github.com/ng-alain/delon/commit/ccfa5e1d6f5cf1d3f9bc5360bc2e373604ae22a2))
* **cli:** add `bindToComponentInputs` of `ng add` ([#1630](https://github.com/ng-alain/delon/issues/1630)) ([9717d9d](https://github.com/ng-alain/delon/commit/9717d9dd4ee1d5ab1526616a99da7b70e8664bd2))
* **theme:drawer:** add `closeAll`, `openDrawers` method ([#1627](https://github.com/ng-alain/delon/issues/1627)) ([bab3d0c](https://github.com/ng-alain/delon/commit/bab3d0c3c648d933784c4623b2714ac227219c5c))
* **theme:modal:** add size support percentage ([#1626](https://github.com/ng-alain/delon/issues/1626)) ([8b52a08](https://github.com/ng-alain/delon/commit/8b52a08d82378a42e06c316757e19e5434e109dc))


## [16.2.1](https://github.com/ng-alain/delon/compare/16.2.0...16.2.1) (2023-08-06)

### Bug Fixes
Expand Down
23 changes: 23 additions & 0 deletions docs/changelog.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,29 @@ NG-ALAIN 严格遵循 [Semantic Versioning 2.0.0](http://semver.org/lang/zh-CN/)

---

# [16.3.0](https://github.com/ng-alain/delon/compare/16.2.1...16.3.0) (2023-09-01)

### SCAFFOLDING

* 启用 `bindToComponentInputs` [#2409](https://github.com/ng-alain/ng-alain/pull/2409/files).

### Bug Fixes

* **abc:pdf:** 忽略依赖 `pdfjs-dist`(若使用[本地](https://ng-alain.com/components/pdf)加载模式,需要自行安装该依赖,`pdfjs-dist` 依赖了 `canvas` 可能会因为环境因素安装依赖很慢) ([#1641](https://github.com/ng-alain/delon/issues/1641)) ([b987bab](https://github.com/ng-alain/delon/commit/b987baba6035eb60872c4ee48198568df140869c))
* **form:select:** 当设置 `onSearch` 时重置数据时会忽略更新预选数据 ([#1644](https://github.com/ng-alain/delon/issues/1644)) ([1f8def7](https://github.com/ng-alain/delon/commit/1f8def70856c091ed677cbd47aed7ca230a2aa79))
* **theme:http:** 纠正 `HttpOptions` 缺少 `content` ([#1640](https://github.com/ng-alain/delon/issues/1640)) ([28eeceb](https://github.com/ng-alain/delon/commit/28eecebd7ab71a1b9a8345c0af1ebe22fd3bc1a6))

### Features

* **abc:cell:** 新增 `cell` 单元格数据组件 ([#1530](https://github.com/ng-alain/delon/issues/1530)) ([26023ca](https://github.com/ng-alain/delon/commit/26023cac7a91cae5383cfffd26d44fba6a95fb9f))
* **abc:page-header:** 新增 `titleSub` 子标题属性 ([#1643](https://github.com/ng-alain/delon/issues/1643)) ([79e229f](https://github.com/ng-alain/delon/commit/79e229f5c1b509dd463c48e4a82b361e5d923920))
* **abc:st:** 标签或徽标支持 `tooltip` ([#1634](https://github.com/ng-alain/delon/issues/1634)) ([0e9006e](https://github.com/ng-alain/delon/commit/0e9006e5b9fd30092b5a808f9b3d8012fd3a060c))
* **abc:sv:** 新增 `bordered` 是否显示边框 ([#1628](https://github.com/ng-alain/delon/issues/1628)) ([ccfa5e1](https://github.com/ng-alain/delon/commit/ccfa5e1d6f5cf1d3f9bc5360bc2e373604ae22a2))
* **cli:** `ng add` 开启 `bindToComponentInputs` ([#1630](https://github.com/ng-alain/delon/issues/1630)) ([9717d9d](https://github.com/ng-alain/delon/commit/9717d9dd4ee1d5ab1526616a99da7b70e8664bd2))
* **theme:drawer:** 新增 `closeAll`, `openDrawers` 方法 ([#1627](https://github.com/ng-alain/delon/issues/1627)) ([bab3d0c](https://github.com/ng-alain/delon/commit/bab3d0c3c648d933784c4623b2714ac227219c5c))
* **theme:modal:** 支持百分比大小 ([#1626](https://github.com/ng-alain/delon/issues/1626)) ([8b52a08](https://github.com/ng-alain/delon/commit/8b52a08d82378a42e06c316757e19e5434e109dc))


## [16.2.1](https://github.com/ng-alain/delon/compare/16.2.0...16.2.1) (2023-08-06)

### Bug Fixes
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "delon",
"version": "16.2.1",
"version": "16.3.0",
"description": "Delon is a set of essential modules for NG-ALAIN.",
"keywords": [
"delon",
Expand Down
3 changes: 3 additions & 0 deletions scripts/publish/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"type": "module"
}
16 changes: 10 additions & 6 deletions scripts/publish/publish-scaffold.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
const chalk = require('chalk');
const fs = require('fs-extra');
const path = require('path');
import chalk from 'chalk';
import { readJSONSync } from 'fs-extra/esm';
import { join, resolve, dirname } from 'path';
import { fileURLToPath } from 'url';

const nextVersion = fs.readJSONSync(path.join(__dirname, '../../package.json'))
const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);

const nextVersion = readJSONSync(join(__dirname, '../../package.json'))
.version;
const root = path.resolve(__dirname, `../../../ng-alain`);
const root = resolve(__dirname, `../../../ng-alain`);

/* Shortcut methods */
const execSync = require('child_process').execSync;
import { execSync } from 'child_process';
const execSyncOptions = {
cwd: root,
};
Expand Down
30 changes: 17 additions & 13 deletions scripts/publish/publish.js
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
const chalk = require('chalk');
const fs = require('fs-extra');
const path = require('path');
const read = require('readline-sync');
import { writeFileSync, readFileSync } from 'fs';
import { readJSONSync } from 'fs-extra/esm';
import { resolve, join, dirname } from 'path';
import { question } from 'readline-sync';
import chalk from 'chalk';
import { execSync } from 'child_process';
import { fileURLToPath } from 'url';

const root = path.resolve(__dirname, `../..`);
const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);
const root = resolve(__dirname, `../..`);

/* Shortcut methods */
const execSync = require('child_process').execSync;
const print = console.log;
const log = {
info: msg => {
Expand All @@ -26,7 +30,7 @@ const log = {
/* The whole process */
log.info('Starting publishing process...');

const nextVersion = fs.readJSONSync(path.join(root, 'package.json')).version;
const nextVersion = readJSONSync(join(root, 'package.json')).version;

fetchOlderVersions();
generatingPublishNote();
Expand All @@ -49,7 +53,7 @@ function generatingPublishNote() {
let completeEditing = false;

while (!completeEditing) {
const result = read.question(
const result = question(
chalk.bgYellow.black(
'Please manually update docs/changelog. Press [Y] if you are done:',
) + ' ',
Expand All @@ -64,16 +68,16 @@ function generatingPublishNote() {

function fixDependenciePath() {
log.info('Fix dependencie paths...');
const packageData = fs.readJSONSync(path.join(root, 'package.json'));
const packageData = readJSONSync(join(root, 'package.json'));
const versionData = {
...packageData.dependencies,
...packageData.devDependencies
};
log.info('>> fix ajv version path in code service');
const codeServicePath = path.join(root, 'src/app/core/code.service.ts');
fs.writeFileSync(codeServicePath,
fs.readFileSync(codeServicePath, 'utf-8')
.replace(/\/ajv\/[^\/]+\//g, `/ajv/${versionData['ajv'].replace(/\^/g, '').replace(/\~/g, '')}/`)
const codeServicePath = join(root, 'src/app/core/code.service.ts');
writeFileSync(codeServicePath,
readFileSync(codeServicePath, 'utf-8')
.replace(/\/ajv\/[^\/]+\//g, `/ajv/${versionData['ajv'].replace(/\^/g, '').replace(/\~/g, '')}/`)
);
}

Expand Down
19 changes: 12 additions & 7 deletions scripts/publish/sync-scaffold-version.js
Original file line number Diff line number Diff line change
@@ -1,22 +1,27 @@
// node scripts/publish/sync-scaffold-version.js
// node scripts/publish/sync-scaffold-version.js theme
const fs = require('fs-extra');
const path = require('path');
import { existsSync } from 'fs';
import { readJSONSync, writeJSONSync } from 'fs-extra/esm';
import { join, resolve, dirname } from 'path';
import { fileURLToPath } from 'url';

const nextJson = fs.readJSONSync(path.join(__dirname, '../../package.json'));
const __filename = fileURLToPath(import.meta.url);
const __dirname = dirname(__filename);

const nextJson = readJSONSync(join(__dirname, '../../package.json'));
const nextVersion = nextJson.version;
const nextVersions = {
...nextJson.dependencies,
...nextJson.devDependencies,
};
const name = (process.argv.length >= 2 ? process.argv[2] : '') || 'ng-alain';
const packagePath = path.resolve(__dirname, name.startsWith('../') ? name : `../../../${name}/package.json`);
const packagePath = resolve(__dirname, name.startsWith('../') ? name : `../../../${name}/package.json`);
console.log(`Use packagePath: ` + packagePath);
if (!fs.existsSync(packagePath)) {
if (!existsSync(packagePath)) {
throw Error(`所选的文件不存在, ${packagePath}`)
}

const json = fs.readJSONSync(packagePath);
const json = readJSONSync(packagePath);
// Update third party
['dependencies', 'devDependencies'].forEach(type => {
Object.keys(json[type])
Expand All @@ -36,6 +41,6 @@ json.devDependencies[`@delon/testing`] = `^${nextVersion}`;
json.devDependencies[`ng-alain`] = `^${nextVersion}`;

// Save
fs.writeJSONSync(packagePath, json, {
writeJSONSync(packagePath, json, {
spaces: 2,
});

0 comments on commit 5dc859e

Please sign in to comment.