ion-list-header
列表标题是用于描述列表内容的块级元素。与项目分隔线不同,列表标题应仅在列表的顶部使用一次(在项目列表的上方)。
基本用法
列表标题中的按钮
放置在列表标题中的按钮可用于显示列表的一部分,并通过按钮重定向到完整列表。
列表标题边框线
列表标题默认不显示底部边框。lines 属性可以修改为 "full" 或 "inset",分别显示全宽边框或带左内边距的内嵌边框。
主题
颜色
CSS 自定义属性
属性
color
| 说明 | The color to use from your application's color palette. Default options are: "primary", "secondary", "tertiary", "success", "warning", "danger", "light", "medium", and "dark". For more information on colors, see theming. |
| 属性 | color |
| 类型 | "danger" | "dark" | "light" | "medium" | "primary" | "secondary" | "success" | "tertiary" | "warning" | string | undefined |
| 默认值 | undefined |
lines
| 说明 | How the bottom border should be displayed on the list header. |
| 属性 | lines |
| 类型 | "full" | "inset" | "none" | undefined |
| 默认值 | undefined |
mode
| 说明 | The mode determines which platform styles to use. 这是一个虚拟属性,在初始化时设置一次,之后更改其值不会更新组件。 |
| 属性 | mode |
| 类型 | "ios" | "md" |
| 默认值 | undefined |
事件
该组件没有可用的事件。
方法
该组件没有可用的公共方法。
CSS Shadow Parts
| Name | 说明 |
|---|---|
inner | The inner wrapper element that arranges the list header content. |
CSS 自定义属性
- iOS
- MD
| Name | 说明 |
|---|---|
--background | Background of the list header |
--border-color | Color of the list header border |
--border-style | Style of the list header border |
--border-width | Width of the list header border |
--color | Color of the list header text |
--inner-border-width | Width of the inner list header border |
| Name | 说明 |
|---|---|
--background | Background of the list header |
--border-color | Color of the list header border |
--border-style | Style of the list header border |
--border-width | Width of the list header border |
--color | Color of the list header text |
--inner-border-width | Width of the inner list header border |
插槽
该组件没有可用的插槽。