Skip to content

Commit 966dc8f

Browse files
authored
feat(module:select): add string array support for nzDropdownClassName (#7643)
1 parent aec94c9 commit 966dc8f

3 files changed

Lines changed: 3 additions & 5 deletions

File tree

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

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ import { NzSelectModule } from 'ng-zorro-antd/select';
3838
| `[nzOpen]` | dropdown expand state, double binding | `boolean` | `false` |
3939
| `[nzAutoFocus]` | Get focus by default | `boolean` | `false` |
4040
| `[nzDisabled]` | Whether disabled select | `boolean` | `false` |
41-
| `[nzDropdownClassName]` | className of dropdown menu | `string` | - |
41+
| `[nzDropdownClassName]` | className of dropdown menu | `string \| string[]` | - |
4242
| `[nzDropdownMatchSelectWidth]` | Whether dropdown's width is same width than select. | `boolean` | `true` |
4343
| `[nzDropdownStyle]` | style of dropdown menu | `object` | - |
4444
| `[nzCustomTemplate]` | The custom template of select | `TemplateRef<{ $implicit: NzOptionComponent }>` | - |
@@ -48,7 +48,6 @@ import { NzSelectModule } from 'ng-zorro-antd/select';
4848
| `[nzMode]` | Set mode of Select | `'multiple' \| 'tags' \| 'default'` | `'default'` |
4949
| `[nzNotFoundContent]` | Specify content to show when no result matches.. | `string \| TemplateRef<void>` | `'Not Found'` |
5050
| `[nzPlaceHolder]` | Placeholder of select | `string` | - |
51-
| `[nzPlacement]` | The position where the selection box pops up | `'bottomLeft' \| 'bottomRight' \| 'topLeft' \| 'topRight'` | `'bottomLeft'` |
5251
| `[nzShowArrow]` | Whether to show the drop-down arrow | `boolean` | `true`(for single select), `false`(for multiple select) |
5352
| `[nzShowSearch]` | Whether show search input in single mode. | `boolean` | `false` |
5453
| `[nzSize]` | Size of Select input | `'large' \| 'small' \| 'default'` | `'default'` |

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

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ import { NzSelectModule } from 'ng-zorro-antd/select';
3939
| `[nzOpen]` | 下拉菜单是否打开,可双向绑定 | `boolean` | `false` |
4040
| `[nzAutoFocus]` | 默认获取焦点 | `boolean` | `false` |
4141
| `[nzDisabled]` | 是否禁用 | `boolean` | `false` |
42-
| `[nzDropdownClassName]` | 下拉菜单的 className 属性 | `string` | - |
42+
| `[nzDropdownClassName]` | 下拉菜单的 className 属性 | `string \| string[]` | - |
4343
| `[nzDropdownMatchSelectWidth]` | 下拉菜单和选择器同宽 | `boolean` | `true` |
4444
| `[nzDropdownStyle]` | 下拉菜单的 style 属性 | `object` | - |
4545
| `[nzCustomTemplate]` | 自定义选择框的 Template 内容 | `TemplateRef<{ $implicit: NzOptionComponent }>` | - |
@@ -49,7 +49,6 @@ import { NzSelectModule } from 'ng-zorro-antd/select';
4949
| `[nzMode]` | 设置 nz-select 的模式 | `'multiple' \| 'tags' \| 'default'` | `'default'` |
5050
| `[nzNotFoundContent]` | 当下拉列表为空时显示的内容 | `string \| TemplateRef<void>` | - |
5151
| `[nzPlaceHolder]` | 选择框默认文字 | `string` | - |
52-
| `[nzPlacement]` | 选择框弹出的位置 | `'bottomLeft' \| 'bottomRight' \| 'topLeft' \| 'topRight'` | `'bottomLeft'` |
5352
| `[nzShowArrow]` | 是否显示下拉小箭头 | `boolean` | 单选为 `true`,多选为 `false` |
5453
| `[nzShowSearch]` | 使单选模式可搜索 | `boolean` | `false` |
5554
| `[nzSize]` | 选择框大小 | `'large' \| 'small' \| 'default'` | `'default'` |

components/select/select.component.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ export class NzSelectComponent implements ControlValueAccessor, OnInit, AfterCon
215215
@Input() nzStatus: NzStatus = '';
216216
@Input() nzOptionHeightPx = 32;
217217
@Input() nzOptionOverflowSize = 8;
218-
@Input() nzDropdownClassName: string | null = null;
218+
@Input() nzDropdownClassName: string[] | string | null = null;
219219
@Input() nzDropdownMatchSelectWidth = true;
220220
@Input() nzDropdownStyle: { [key: string]: string } | null = null;
221221
@Input() nzNotFoundContent: string | TemplateRef<NzSafeAny> | undefined = undefined;

0 commit comments

Comments
 (0)