# cover-view
Start from base library version 1.4.0. Please remaining backward compatible.
The text view that overrides the native component.
at presentNative component is already supported for same layer rendering, and it is recommended to use view Substitute. Native components that can be overridden include map、video、canvas、camera、live-player、live-pusher
Nesting only cover-view、cover-image, available in the cover-view Used in button。 The unit of length of the component attribute defaults to px, Support incoming units from 2.4.0(rpx/px)。
attribute | type | Default value | Required | Introductions | Minimum version |
---|---|---|---|---|---|
scroll-top | number/string | no | Set the top scroll offset, only when the overflow-y: scroll Becomes a scrolling element. | 2.1.0 |
# Bug & Tip
tip
: [cover-view]((cover-view) and[cover-image]((cover-image)aria-role
Can only be set tobutton
Click on the on in the screen reading mode, and read out the "on"Can focus when empty, but cannot clicktip
: Base library 2.2.4 Rise support touch Related events, or you can use the hover-class Set Click Modetip
: Base library 2.1.0 Start Support Settingsscale
rotate
of css Styles, including transition animationtip
: Base library 1.9.90 risecover-view
Supportoverflow: scroll
But does not support dynamic updatesoverflow
tip
: Base library 1.9.90 Outermost layercover-view
Supportposition: fixed
tip
: Base library 1.9.0 Up support plug inview
Wait for the label. Prior to this, only native components can be nestedmap
、video
、canvas
、camera
Avoid nesting within other components.tip
: Base library 1.6.0 Start supporting css Transition animation,transition-property
Only supporttransform (translateX, translateY)
andopacity
。tip
: Base library 1.6.0 Start supporting css opacity。tip
: The event model follows the bubbling model but does not bubble to native components.tip
: All text suggestions are tagged with cover-view tags to avoid typographical errors.tip
: Only basic positioning, layout, and text styles are supported. Do not support settingsUnilateral border
、background-image
、shadow
、overflow: visible
Wait.tip
: Advise child nodes not to overflow parent nodestip
: Support use z-index Control leveltip
: The default styles are:white-space: nowrap
line-height: 1.2
display: block
bug
: Custom component nestingcover-view
To customize the component s slot And its parent node temporarily supports passing wx:if Control explicit or causecover-view
Do not show