跳到主要内容
版本:v7

ion-backdrop

shadow

背景遮罩(Backdrop)是覆盖在其他组件之上的全屏组件。它们适用于在其他内容之上过渡进入的组件背后,并可用于关闭该组件。

基本用法​

背景遮罩防止点击或触摸其背后的内容。默认情况下它是透明的,因此下面的演示包含了使其可见的 CSS。

样式​

可以通过直接为背景遮罩元素分配 CSS 属性来自定义背景遮罩。常见属性包括 background-color、background 和 opacity。

可以通过在内容上设置高于背景遮罩(默认为 2)的 z-index 来在背景遮罩上方显示内容。

属性​

stopPropagation​

说明If true, the backdrop will stop propagation on tap.
属性stop-propagation
类型boolean
默认值true

tappable​

说明If true, the backdrop will can be clicked and will emit the ionBackdropTap event.
属性tappable
类型boolean
默认值true

visible​

说明If true, the backdrop will be visible.
属性visible
类型boolean
默认值true

事件​

Name说明冒泡
ionBackdropTapEmitted when the backdrop is tapped.true

方法​

该组件没有可用的公共方法。

CSS 阴影部分​

该组件没有可用的 CSS 阴影部分。

CSS 自定义属性​

该组件没有可用的 CSS 自定义属性。

插槽​

该组件没有可用的插槽。