当前位置:网站首页>Wechat applet training notes 1
Wechat applet training notes 1
2022-07-03 10:44:00 【Fps-caigou】
video :p1-p7
wxml
<!--
view Block labels
hover-class Specify the style class to follow .
hover-start-time How long does the click state appear after pressing , Unit millisecond
hover-stay-time Click state retention time after finger release , Unit millisecond
hover-stop-propagation Specifies whether to prevent the click state of the ancestor node of this node
-->
<view class="box"
hover-class="boxHover"
hover-start-time="50"
hover-stay-time="50"> Wechat small program training 1
<view class="item" hover-class="itemHover" hover-stop-propagation>111111111</view>
</view>
<!--
text Row labels
selectable Is text optional ( Can I copy )
user-select
space Show continuous spaces
ensp Chinese character space half size
emsp Chinese character space size
nbsp According to the space size set by the font
decode Whether the decoding
-->
<view class="out">
<text> This is a line. </text>
<text> They are <text decode> </text> a line </text>
</view>
<text selectable space="ensp"> This is a large text, this is a large text, this is Big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text this is a big text Text this is a large text, this is a large text, this is a large text, this is a large text, this is a large text, this is a large text, this is a large text, this is a large text, this is a large text, this is a large text, this is a large text, this is a large text </text>
<!--
../ Go back to the previous Directory
./ At the same directory
/ Enter the next directory
Frontmost plus / root directory
image picture Network address can be introduced
mode Image clipping 、 Zoom mode
aspectFit Completely show , Keep the aspect ratio
aspectFill Keep the aspect ratio , Pictures are usually complete only horizontally or vertically , Intercept will occur in the other direction
widthFix The width does not change , Automatic height change , Keep the aspect ratio of the original image unchanged
heightFix The height remains the same , The width changes automatically , Keep the aspect ratio of the original image unchanged
show-menu-by-longpress Long press the picture to display the menu .
-->
<image class="img1" show-menu-by-longpress src="/images/2-1206131I104.jpg"></image>
<image class="img2" src="../../images/ba468fcb-8bb2-45d3-9db4-fb401e3b023f_s.jpg"/>
<image mode="widthFix" src="/images/cb1d1e9b-3b8e-403b-b46d-e39af3e56f24.jpg"></image>
<image mode="widthFix" src="https://img-s-msn-com.akamaized.net/tenant/amp/entityid/AATLy5I.img?h=630&w=874&m=6&q=60&o=f&l=f&x=775&y=267" ></image>
<!--
scroll-view Scrollable view area
scroll-x Allow horizontal scrolling
scroll-y Allow vertical scrolling
Initial sliding position
scroll-top
scroll-bottom
scroll-right
scroll-left
-->
<scroll-view scroll-x>
<view class="scrOut">
<view class="scrBox">111</view>
<view class="scrBox">222</view>
<view class="scrBox">333</view>
<view class="scrBox">444</view>
<view class="scrBox">555</view>
</view>
</scroll-view >
<scroll-view class="scroll1" scroll-y>
<view class="scrOut1">
<view class="scrBox1">111</view>
<view class="scrBox1">222</view>
<view class="scrBox1">333</view>
<view class="scrBox1">444</view>
<view class="scrBox1">555</view>
</view>
</scroll-view>
<!--
navigator Hyperlinks Block-level elements You can only jump to the page in the applet , No internet access
open-type Jump mode
redirect Destroy the previous page , You can only return to the home page , You cannot use menus in new windows
reLaunch ditto , But you can use menus , With parameters
-->
<view>
<navigator class="link" url="/pages/logs/logs"> Jump to log </navigator>
<navigator class="link" open-type="redirect" url="/pages/logs/logs"> Jump to log </navigator>
<navigator class="link" open-type="reLaunch" url="/pages/logs/logs"> Jump to log </navigator>
</view>
wxss
.box{
width: 200px;
height: 200px;
color: black;
background-color: lightblue;
}
.boxHover{
background-color: gray;
}
.item{
width: 100px;
height: 100px;
background-color: blueviolet;
}
.itemHover{
background-color: crimson;
}
.img1{
width: 200px;
height: 100px;
}
img2{
width: 100%;
height: 100%;
}
.link{
height: 40px;
}
.scrOut{
display: flex;
flex-wrap: nowrap;
}
/* flex attribute */
.scrBox{
width: 100px;
height: 100px;
background: gold;
margin-right: 2px;
flex: 0 0 100px;
}
.scroll1{
height: 250px;
}
.scrBox1{
width: 100%;
height: 100px;
background: pink;
margin-bottom: 2px;
}
边栏推荐
- Unity学习笔记:个人学习项目《疯狂天才埃德加》纠错文档
- Pytoch has been installed, but vs code still displays no module named 'torch‘
- Leetcode刷题---35
- Content type ‘application/x-www-form-urlencoded;charset=UTF-8‘ not supported
- Ut2014 learning notes
- 缓存路由组件
- Flink <-->Redis的使用介绍+with参数
- MySQL报错“Expression #1 of SELECT list is not in GROUP BY clause and contains nonaggre”解决方法
- 深度学习入门之自动求导(Pytorch)
- Leetcode skimming ---704
猜你喜欢
A complete mall system
Classification (data consolidation and grouping aggregation)
2021-09-22
Numpy realizes the classification of iris by perceptron
Jupiter notebook changing font style and font size
[combinatorial mathematics] pigeon nest principle (simple form examples of pigeon nest Principle 4 and 5)
How to hide cvxpy warnings: warn: a- > P (column pointers) not strictly increasing, column x empty?
神经网络入门之预备知识(PyTorch)
Ut2014 learning notes
神经网络入门之模型选择(PyTorch)
随机推荐
Leetcode skimming ---44
Jetson TX2 刷机
Leetcode skimming ---75
【SQL】一篇带你掌握SQL数据库的查询与修改相关操作
Ind kwf first week
Iterator iterator enhances for loop
神经网络入门之模型选择(PyTorch)
深度学习入门之线性代数(PyTorch)
一个30岁的测试员无比挣扎的故事,连躺平都是奢望
Binary search method
Leetcode刷题---374
Out of the box high color background system
Numpy quick start (III) -- array advanced operation
How to hide cvxpy warnings: warn: a- > P (column pointers) not strictly increasing, column x empty?
Leetcode skimming ---202
Leetcode刷题---10
神经网络入门之预备知识(PyTorch)
Leetcode刷题---75
Unity learning notes: online game pixel Adventure 1 learning process & error correction experience
[SQL] an article takes you to master the operations related to query and modification of SQL database