From c6a24eb7f203bcc82c7d6f54a2a3f15264f751e3 Mon Sep 17 00:00:00 2001 From: aijunhao Date: Fri, 9 Jun 2023 17:22:55 +0800 Subject: [PATCH] feat(module: all): support Angular 16 --- README-zh_CN.md | 2 +- README.md | 2 +- components/core/util/position.ts | 2 +- components/package.json | 34 ++++++------ docs/introduce.en-US.md | 2 +- docs/introduce.zh-CN.md | 2 +- package.json | 52 +++++++++---------- scripts/site/_site/src/app/app.component.ts | 7 +-- .../share/nz-codebox/nz-codebox.component.ts | 24 ++++----- 9 files changed, 64 insertions(+), 63 deletions(-) diff --git a/README-zh_CN.md b/README-zh_CN.md index 36f9466b..048c966b 100644 --- a/README-zh_CN.md +++ b/README-zh_CN.md @@ -38,7 +38,7 @@ ## Angular 支持 -现在支持 Angular `^15.0.0`. +现在支持 Angular `^16.0.0`. ## 安装 diff --git a/README.md b/README.md index 52a84969..82551021 100644 --- a/README.md +++ b/README.md @@ -38,7 +38,7 @@ This is the **Angular** implementation of **Ant Design Mobile** specification, s ## Angular Support -Now Supports Angular `^15.0.0`. +Now Supports Angular `^16.0.0`. ## Installation diff --git a/components/core/util/position.ts b/components/core/util/position.ts index b001823f..3c5634e5 100644 --- a/components/core/util/position.ts +++ b/components/core/util/position.ts @@ -37,7 +37,7 @@ export function getPosition(element) { let elPosition; let parentOffset = { width: 0, height: 0, top: 0, bottom: 0, left: 0, right: 0 }; if (getStyle(element, 'position') === 'fixed') { - elPosition = element.getBoundingClientRect(); + elPosition = { ...element.getBoundingClientRect() }; } else { let offsetParentEl = getOffsetParent(element); elPosition = getOffset(element); diff --git a/components/package.json b/components/package.json index 8c602eba..022f4f1c 100644 --- a/components/package.json +++ b/components/package.json @@ -1,6 +1,6 @@ { "name": "ng-zorro-antd-mobile", - "version": "8.0.0", + "version": "9.0.0", "description": "An enterprise-class mobile UI components based on Ant Design and Angular", "schematics": "./schematics/collection.json", "keywords": [ @@ -22,26 +22,26 @@ "url": "https://github.com/NG-ZORRO/ng-zorro-antd-mobile/issues" }, "dependencies": { - "@angular/animations": "^15.0.3", - "@angular/cdk": "^15.0.2", - "@angular/common": "^15.0.3", - "@angular/compiler": "^15.0.3", - "@angular/core": "^15.0.3", - "@angular/forms": "^15.0.3", - "@angular/platform-browser": "^15.0.3", - "@angular/platform-browser-dynamic": "^15.0.3", - "@angular/router": "^15.0.3", - "@ant-design/icons-angular": "^15.0.0" + "@angular/animations": "^16.0.0", + "@angular/cdk": "^16.0.0", + "@angular/common": "^16.0.0", + "@angular/compiler": "^16.0.0", + "@angular/core": "^16.0.0", + "@angular/forms": "^16.0.0", + "@angular/platform-browser": "^16.0.0", + "@angular/platform-browser-dynamic": "^16.0.0", + "@angular/router": "^16.0.0", + "@ant-design/icons-angular": "^16.0.0" }, "devDependencies": { - "@angular/upgrade": "^15.0.3", - "@angular-devkit/build-angular": "^15.0.3", - "@angular/cli": "^15.0.3", - "@angular/compiler-cli": "^15.0.3", - "@angular/platform-server": "^15.0.3", + "@angular/upgrade": "^16.0.0", + "@angular-devkit/build-angular": "^16.0.0", + "@angular/cli": "^16.0.0", + "@angular/compiler-cli": "^16.0.0", + "@angular/platform-server": "^16.0.0", "tslib": "^2.4.1", "tslint": "~6.1.3", - "typescript": "~4.8.4" + "typescript": "~5.0.4" }, "lint-staged": { "{src,docs}/**/*.{scss}": [ diff --git a/docs/introduce.en-US.md b/docs/introduce.en-US.md index fcf4b9b1..152d8255 100755 --- a/docs/introduce.en-US.md +++ b/docs/introduce.en-US.md @@ -133,7 +133,7 @@ This is the **Angular** implementation of **Ant Design Mobile** specification, s ## Angular Support -Now Supports Angular `^15.0.0`. +Now Supports Angular `^16.0.0`. ## Installation diff --git a/docs/introduce.zh-CN.md b/docs/introduce.zh-CN.md index e0e704a8..f4420587 100755 --- a/docs/introduce.zh-CN.md +++ b/docs/introduce.zh-CN.md @@ -133,7 +133,7 @@ title: Ant Design Mobile of Angular
=18.10.0" }, "husky": { "hooks": { diff --git a/scripts/site/_site/src/app/app.component.ts b/scripts/site/_site/src/app/app.component.ts index ea8a5b80..908ce7f3 100644 --- a/scripts/site/_site/src/app/app.component.ts +++ b/scripts/site/_site/src/app/app.component.ts @@ -22,7 +22,7 @@ export class AppComponent implements OnInit, AfterViewInit { docsearch = null; kitchenUrl = window.location.origin + '/#/kitchen-sink?lang=zh-CN'; language = 'zh'; - versionList = ['0.12.x', '1.0.6', '2.0.7', '3.0.3', '4.0.0', '5.0.3', '6.0.2', '7.0.1', '8.0.0']; + versionList = ['0.12.x', '1.0.6', '2.0.7', '3.0.3', '4.0.0', '5.0.3', '6.0.2', '7.0.1', '8.0.0', '9.0.0']; versionMap = { '0.12.x': '0.12.5', '1.0.6': '2001.0.6', @@ -32,9 +32,10 @@ export class AppComponent implements OnInit, AfterViewInit { '5.0.3': '2015.0.3', '6.0.2': '2016.0.2', '7.0.1': '2017.0.1', - '8.0.0': '2018.0.11' + '8.0.0': '2018.0.11', + '9.0.0': '2019.0.0' }; - currentVersion = '8.0.0'; + currentVersion = '9.0.0'; isHomeURL = true; isKitchenURL = false; demoTitle = ''; diff --git a/scripts/site/_site/src/app/share/nz-codebox/nz-codebox.component.ts b/scripts/site/_site/src/app/share/nz-codebox/nz-codebox.component.ts index 4a36eadf..a0f136a2 100644 --- a/scripts/site/_site/src/app/share/nz-codebox/nz-codebox.component.ts +++ b/scripts/site/_site/src/app/share/nz-codebox/nz-codebox.component.ts @@ -340,19 +340,19 @@ export class AppModule { } description: 'Created with <3 by the StackBlitz SDK!', template: 'angular-cli', dependencies: { - '@angular/animations': '^15.0.3', - '@angular/cdk': '^15.0.2', - '@angular/common': '^15.0.3', - '@angular/compiler': '^15.0.3', - '@angular/core': '^15.0.3', - '@angular/forms': '^15.0.3', - '@angular/platform-browser': '^15.0.3', - '@angular/platform-browser-dynamic': '^15.0.3', - '@angular/router': '^15.0.3', - '@ant-design/icons-angular': '^15.0.0', + '@angular/animations': '^16.0.0', + '@angular/cdk': '^16.0.0', + '@angular/common': '^16.0.0', + '@angular/compiler': '^16.0.0', + '@angular/core': '^16.0.0', + '@angular/forms': '^16.0.0', + '@angular/platform-browser': '^16.0.0', + '@angular/platform-browser-dynamic': '^16.0.0', + '@angular/router': '^16.0.0', + '@ant-design/icons-angular': '^16.0.0', rxjs: '~7.6.0', - 'zone.js': '~0.12.0', - 'ng-zorro-antd-mobile': '8.0.0' + 'zone.js': '~0.13.0', + 'ng-zorro-antd-mobile': '9.0.0' }, tags: ['stackblitz', 'sdk'] });