navigator
Page link.
Attribute name | Type | Default value | Description |
url | String | In-app jump link | |
redirect | Boolean | false | Whether to close the current page |
hover-class | String | navigator- hover |
Specify the style class when clicked, When hover-class="none", there is no click state effect |
Note: The default value of navigator-hover is {background-color: rgba(0, 0, 0, 0.1); opacity: 0.7;}, and the background color of the child node should be transparent
Example Code:
/** wxss **//** 修改默认的navigator点击态 **/.navigator-hover { color:blue;}/** 自定义其他点击态样式类 **/.other-navigator-hover { color:red;}
<!-- sample.wxml --> <view> <navigator url="navigate?title=navigate" hover-class="navigator-hover">跳转到新页面</navigator> <navigator url="redirect?title=redirect" redirect hover-class="other-navigator-hover">在当前页打开</navigator> </view>
<!-- navigator.wxml --> <view style="text-align:center"> {{title}} </view> <view> 点击左上角返回回到之前页面 </view> <!-- redirect.wxml --> <view style="text-align:center"> {{title}} </view> <view> 点击左上角返回回到上级页面 </view> // redirect.js navigator.js Page({ onLoad: function(options) { this.setData({ title: options.title }) } })
The above is the content of the WeChat applet development component-navigation. For more related content, please pay attention to the PHP Chinese website (www.php.cn)!

Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

SublimeText3 Linux new version
SublimeText3 Linux latest version

Dreamweaver Mac version
Visual web development tools

WebStorm Mac version
Useful JavaScript development tools

PhpStorm Mac version
The latest (2018.2.1) professional PHP integrated development tool

DVWA
Damn Vulnerable Web App (DVWA) is a PHP/MySQL web application that is very vulnerable. Its main goals are to be an aid for security professionals to test their skills and tools in a legal environment, to help web developers better understand the process of securing web applications, and to help teachers/students teach/learn in a classroom environment Web application security. The goal of DVWA is to practice some of the most common web vulnerabilities through a simple and straightforward interface, with varying degrees of difficulty. Please note that this software
