Skip to content

Commit 22ce17c

Browse files
fix(module:card): remove nzBorderless input (#8741)
1 parent 2c63c87 commit 22ce17c

File tree

4 files changed

+25
-27
lines changed

4 files changed

+25
-27
lines changed

components/card/card.component.ts

+1-2
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ const NZ_CONFIG_MODULE_NAME: NzConfigKey = 'card';
8585
host: {
8686
class: 'ant-card',
8787
'[class.ant-card-loading]': 'nzLoading',
88-
'[class.ant-card-bordered]': 'nzBorderless === false && nzBordered',
88+
'[class.ant-card-bordered]': 'nzBordered',
8989
'[class.ant-card-hoverable]': 'nzHoverable',
9090
'[class.ant-card-small]': 'nzSize === "small"',
9191
'[class.ant-card-contain-grid]': 'listOfNzCardGridDirective && listOfNzCardGridDirective.length',
@@ -100,7 +100,6 @@ export class NzCardComponent implements OnDestroy, OnInit {
100100
readonly _nzModuleName: NzConfigKey = NZ_CONFIG_MODULE_NAME;
101101

102102
@Input({ transform: booleanAttribute }) @WithConfig() nzBordered: boolean = true;
103-
@Input({ transform: booleanAttribute }) @WithConfig() nzBorderless: boolean = false;
104103
@Input({ transform: booleanAttribute }) nzLoading = false;
105104
@Input({ transform: booleanAttribute }) @WithConfig() nzHoverable: boolean = false;
106105
@Input() nzBodyStyle: NgStyleInterface | null = null;

components/card/doc/index.en-US.md

+12-12
Original file line numberDiff line numberDiff line change
@@ -24,18 +24,18 @@ import { NzCardModule } from 'ng-zorro-antd/card';
2424

2525
### nz-card:standalone
2626

27-
| Property | Description | Type | Default | Global Config |
28-
| ---------------- | -------------------------------------------------------------------------- | --------------------------- | ----------- | ------------- |
29-
| `[nzActions]` | The action list, shows at the bottom of the Card. | `Array<TemplateRef<void>>` | - |
30-
| `[nzBodyStyle]` | Inline style to apply to the card content | `{ [key: string]: string }` | - |
31-
| `[nzBorderless]` | Remove border around the card | `boolean` | `false` ||
32-
| `[nzCover]` | Card cover | `TemplateRef<void>` | - |
33-
| `[nzExtra]` | Content to render in the top-right corner of the card | `string\|TemplateRef<void>` | - |
34-
| `[nzHoverable]` | Lift up when hovering card | `boolean` | `false` ||
35-
| `[nzLoading]` | Shows a loading indicator while the contents of the card are being fetched | `boolean` | `false` |
36-
| `[nzTitle]` | Card title | `string\|TemplateRef<void>` | - |
37-
| `[nzType]` | Card style type, can be set to `inner` or not set | `'inner'` | - |
38-
| `[nzSize]` | Size of card | `'default'\|'small'` | `'default'` ||
27+
| Property | Description | Type | Default | Global Config |
28+
| --------------- | -------------------------------------------------------------------------- | --------------------------- | ----------- | ------------- |
29+
| `[nzActions]` | The action list, shows at the bottom of the Card. | `Array<TemplateRef<void>>` | - |
30+
| `[nzBodyStyle]` | Inline style to apply to the card content | `{ [key: string]: string }` | - |
31+
| `[nzBordered]` | Toggles rendering of the border around the card | `boolean` | `true` | |
32+
| `[nzCover]` | Card cover | `TemplateRef<void>` | - |
33+
| `[nzExtra]` | Content to render in the top-right corner of the card | `string\|TemplateRef<void>` | - |
34+
| `[nzHoverable]` | Lift up when hovering card | `boolean` | `false` | |
35+
| `[nzLoading]` | Shows a loading indicator while the contents of the card are being fetched | `boolean` | `false` |
36+
| `[nzTitle]` | Card title | `string\|TemplateRef<void>` | - |
37+
| `[nzType]` | Card style type, can be set to `inner` or not set | `'inner'` | - |
38+
| `[nzSize]` | Size of card | `'default'\|'small'` | `'default'` | |
3939

4040
### nz-card-meta:standalone
4141

components/card/doc/index.zh-CN.md

+12-12
Original file line numberDiff line numberDiff line change
@@ -25,18 +25,18 @@ import { NzCardModule } from 'ng-zorro-antd/card';
2525

2626
### nz-card:standalone
2727

28-
| 参数 | 说明 | 类型 | 默认值 | 支持全局配置 |
29-
| ---------------- | --------------------------------------------------- | --------------------------- | ----------- | ------------ |
30-
| `[nzActions]` | 卡片操作组,位置在卡片底部 | `Array<TemplateRef<void>>` | - |
31-
| `[nzBodyStyle]` | 内容区域自定义样式 | `{ [key: string]: string }` | - |
32-
| `[nzBorderless]` | 是否移除边框 | `boolean` | `false` ||
33-
| `[nzCover]` | 卡片封面 | `TemplateRef<void>` | - |
34-
| `[nzExtra]` | 卡片右上角的操作区域 | `string\|TemplateRef<void>` | - |
35-
| `[nzHoverable]` | 鼠标移过时可浮起 | `boolean` | `false` ||
36-
| `[nzLoading]` | 当卡片内容还在加载中时,可以用 loading 展示一个占位 | `boolean` | `false` |
37-
| `[nzTitle]` | 卡片标题 | `string\|TemplateRef<void>` | - |
38-
| `[nzType]` | 卡片类型,可设置为 `inner` 或 不设置 | `'inner'` | - |
39-
| `[nzSize]` | 卡片的尺寸 | `'default'\|'small'` | `'default'` ||
28+
| 参数 | 说明 | 类型 | 默认值 | 支持全局配置 |
29+
| --------------- | --------------------------------------------------- | --------------------------- | ----------- | ------------ |
30+
| `[nzActions]` | 卡片操作组,位置在卡片底部 | `Array<TemplateRef<void>>` | - |
31+
| `[nzBodyStyle]` | 内容区域自定义样式 | `{ [key: string]: string }` | - |
32+
| `[nzBordered]` | 是否有边框 | `boolean` | `true` | |
33+
| `[nzCover]` | 卡片封面 | `TemplateRef<void>` | - |
34+
| `[nzExtra]` | 卡片右上角的操作区域 | `string\|TemplateRef<void>` | - |
35+
| `[nzHoverable]` | 鼠标移过时可浮起 | `boolean` | `false` | |
36+
| `[nzLoading]` | 当卡片内容还在加载中时,可以用 loading 展示一个占位 | `boolean` | `false` |
37+
| `[nzTitle]` | 卡片标题 | `string\|TemplateRef<void>` | - |
38+
| `[nzType]` | 卡片类型,可设置为 `inner` 或 不设置 | `'inner'` | - |
39+
| `[nzSize]` | 卡片的尺寸 | `'default'\|'small'` | `'default'` | |
4040

4141
### nz-card-meta:standalone
4242

components/core/config/config.ts

-1
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,6 @@ export interface CardConfig {
151151
nzSize?: NzSizeDSType;
152152
nzHoverable?: boolean;
153153
nzBordered?: boolean;
154-
nzBorderless?: boolean;
155154
}
156155

157156
export interface CarouselConfig {

0 commit comments

Comments
 (0)