Skip to content

Commit

Permalink
feat(abc:qr): will be removed in 18.0.0 (#1667)
Browse files Browse the repository at this point in the history
  • Loading branch information
cipchk authored Oct 26, 2023
1 parent e2c17f7 commit 5a7bdd4
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 2 deletions.
3 changes: 3 additions & 0 deletions packages/abc/qr/index.en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,11 @@ title: qr
subtitle: QR
cols: 1
module: import { QRModule } from '@delon/abc/qr';
deprecated: 18.0.0
---

# Will be removed in 18.0.0, please use [nz-qrcode](https://ng.ant.design/components/qr-code) instead.

Generate a QR code based on [qrious](https://github.com/neocotic/qrious).


Expand Down
3 changes: 3 additions & 0 deletions packages/abc/qr/index.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,11 @@ title: qr
subtitle: 二维码
cols: 1
module: import { QRModule } from '@delon/abc/qr';
deprecated: 18.0.0
---

# 将在 18.0.0 中移除,请使用 [nz-qrcode](https://ng.ant.design/components/qr-code) 替代

基于 [qrious](https://github.com/neocotic/qrious) 生成二维码。

默认二维码的操作并不是刚需的原因,因此采用一种延迟加载脚本的形式,可以通过[全局配置](/docs/global-config)配置来改变默认 CDN 路径,默认情况下使用 `https://cdn.jsdelivr.net/npm/qrious/dist/qrious.min.js`。或安装 `npm i --save qrious` 依赖包并在 `angular.json``scripts` 引用 `"node_modules/qrious/dist/qrious.min.js"`
Expand Down
3 changes: 3 additions & 0 deletions packages/abc/qr/qr.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ import type { NzSafeAny } from 'ng-zorro-antd/core/types';
import { QR_DEFULAT_CONFIG } from './qr.config';
import { QROptions } from './qr.types';

/**
* @deprecated Will be removed in 18.0.0, please use [nz-qrcode](https://ng.ant.design/components/qr-code) instead.
*/
@Component({
selector: 'qr',
exportAs: 'qr',
Expand Down
3 changes: 3 additions & 0 deletions packages/abc/qr/qr.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ import { QRComponent } from './qr.component';

const COMPONENTS = [QRComponent];

/**
* @deprecated Will be removed in 18.0.0, please use [nz-qrcode](https://ng.ant.design/components/qr-code) instead.
*/
@NgModule({
imports: [CommonModule],
declarations: COMPONENTS,
Expand Down
4 changes: 2 additions & 2 deletions src/styles/_custom.less
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@
}

.menu-deprecated {
opacity: 0.5;

.ant-badge {
color: @error-color;
text-decoration: line-through;
opacity: 0.5;
}
}

0 comments on commit 5a7bdd4

Please sign in to comment.