Skip to main content

ion-list-header

shadow

列表标头是用于描述 list.txt 内容的块元素。与 物品分隔线 不同,列表标头只能在 items 列表的顶部使用一次。

¥List headers are block elements that are used to describe the contents of a list. Unlike item dividers, list headers should only be used once at the top of a list of items.

基本用法

¥Basic Usage

列表标题中的按钮

¥Buttons in List Headers

放置在列表标题中的 button 对于显示列表的一部分并使用按钮重定向到完整列表非常有用。

¥A button placed in a list header can be useful for showing part of a list and redirecting to the full list with the button.

列表标题行

¥List Header Lines

默认情况下,列表标题不显示底部边框。lines 属性可以修改为 "full""inset",它们将分别显示全宽边框或带有左内边距的插入边框。

¥List headers do not show a bottom border by default. The lines property can be modified to "full" or "inset" which will show a full width border or an inset border with left padding, respectively.

主题化

¥Theming

颜色

¥Colors

CSS 自定义属性

¥CSS Custom Properties

属性

¥Properties

color

DescriptionThe 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.
Attributecolor
Type"danger" | "dark" | "light" | "medium" | "primary" | "secondary" | "success" | "tertiary" | "warning" | string | undefined
Defaultundefined

lines

DescriptionHow the bottom border should be displayed on the list header.
Attributelines
Type"full" | "inset" | "none" | undefined
Defaultundefined

mode

DescriptionThe mode determines which platform styles to use.
Attributemode
Type"ios" | "md"
Defaultundefined

事件

¥Events

No events available for this component.

方法

¥Methods

No public methods available for this component.

CSS 阴影部分

¥CSS Shadow Parts

No CSS shadow parts available for this component.

CSS 自定义属性

¥CSS Custom Properties

NameDescription
--backgroundBackground of the list header
--border-colorColor of the list header border
--border-styleStyle of the list header border
--border-widthWidth of the list header border
--colorColor of the list header text
--inner-border-widthWidth of the inner list header border

插槽

¥Slots

No slots available for this component.