Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
OpenHarmony
Docs
提交
e3f34c48
D
Docs
项目概览
OpenHarmony
/
Docs
1 年多 前同步成功
通知
159
Star
292
Fork
28
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
Docs
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
e3f34c48
编写于
1月 04, 2023
作者:
O
openharmony_ci
提交者:
Gitee
1月 04, 2023
浏览文件
操作
浏览文件
下载
差异文件
!13109 翻译完成 9962
Merge pull request !13109 from ester.zhou/TR-9962
上级
2a6e26f0
def364da
变更
9
隐藏空白更改
内联
并排
Showing
9 changed file
with
30 addition
and
24 deletion
+30
-24
en/application-dev/ui/figures/en-us_image_00000011.gif
en/application-dev/ui/figures/en-us_image_00000011.gif
+0
-0
en/application-dev/ui/figures/en-us_image_0000001176075554.gif
...plication-dev/ui/figures/en-us_image_0000001176075554.gif
+0
-0
en/application-dev/ui/figures/en-us_image_0000001227701867.gif
...plication-dev/ui/figures/en-us_image_0000001227701867.gif
+0
-0
en/application-dev/ui/figures/en-us_image_0000001276003541.gif
...plication-dev/ui/figures/en-us_image_0000001276003541.gif
+0
-0
en/application-dev/ui/figures/en-us_image_0000001276162773.gif
...plication-dev/ui/figures/en-us_image_0000001276162773.gif
+0
-0
en/application-dev/ui/ui-js-building-ui-event.md
en/application-dev/ui/ui-js-building-ui-event.md
+8
-4
en/application-dev/ui/ui-js-components-canvas.md
en/application-dev/ui/ui-js-components-canvas.md
+2
-4
en/application-dev/ui/ui-js-components-marquee.md
en/application-dev/ui/ui-js-components-marquee.md
+7
-5
en/application-dev/ui/ui-js-components-search.md
en/application-dev/ui/ui-js-components-search.md
+13
-11
未找到文件。
en/application-dev/ui/figures/en-us_image_00000011.gif
0 → 100644
浏览文件 @
e3f34c48
16.2 KB
en/application-dev/ui/figures/en-us_image_0000001176075554.gif
0 → 100644
浏览文件 @
e3f34c48
644.0 KB
en/application-dev/ui/figures/en-us_image_0000001227701867.gif
0 → 100644
浏览文件 @
e3f34c48
392.6 KB
en/application-dev/ui/figures/en-us_image_0000001276003541.gif
已删除
100644 → 0
浏览文件 @
2a6e26f0
235.3 KB
en/application-dev/ui/figures/en-us_image_0000001276162773.gif
已删除
100644 → 0
浏览文件 @
2a6e26f0
529.2 KB
en/application-dev/ui/ui-js-building-ui-event.md
浏览文件 @
e3f34c48
...
...
@@ -49,16 +49,18 @@ The following is an example:
```
css
/* xxx.css */
.container
{
width
:
100%
;
height
:
100%
;
flex-direction
:
column
;
justify-content
:
center
;
align-items
:
center
;
}
.text-container
{
margin-top
:
1
0px
;
margin-top
:
3
0px
;
flex-direction
:
column
;
width
:
75
0px
;
height
:
5
0px
;
background-color
:
#0
9ba07
;
width
:
60
0px
;
height
:
7
0px
;
background-color
:
#0
000FF
;
}
.text-style
{
width
:
100%
;
...
...
@@ -100,3 +102,5 @@ export default {
},
}
```
![
en-us_image_00000011
](
figures/en-us_image_00000011.gif
)
\ No newline at end of file
en/application-dev/ui/ui-js-components-canvas.md
浏览文件 @
e3f34c48
...
...
@@ -115,12 +115,10 @@ Add the long press event to the **<canvas>** component. When the event is
```
js
// xxx.js
import
prompt
from
'
@system.prompt
'
;
import
prompt
Action
from
'
@ohos.promptAction
'
;
export
default
{
data
:{
dataURL
:
null
,
antialia
:
false
,
porc
:
'
open
'
,
},
onShow
(){
let
el
=
this
.
$refs
.
canvas1
;
...
...
@@ -131,7 +129,7 @@ export default {
let
el
=
this
.
$refs
.
canvas1
let
dataUrl
=
el
.
toDataURL
()
this
.
dataURL
=
dataUrl
;
prompt
.
showToast
({
duration
:
2000
,
message
:
"
long press,get dataURL
"
})
prompt
Action
.
showToast
({
duration
:
2000
,
message
:
"
long press,get dataURL
"
})
}
}
```
...
...
en/application-dev/ui/ui-js-components-marquee.md
浏览文件 @
e3f34c48
...
...
@@ -79,7 +79,7 @@ Set the **scrollamount**, **loop**, and **direction** attributes to define the m
<div
class=
"tutorial-page"
>
<div
class=
"mymarquee"
>
<marquee
loop=
"{{loopval}}"
scrollamount=
"{{scroll}}"
direction=
"{{isleft}}"
class=
"marqueetext"
id=
"testmarquee"
onclick=
"makestart"
>
It's a racing lamp
Life is a journey, not the destination.
</marquee>
</div>
<div
style=
"width: 600px;height: 150px;flex-direction: row;justify-content: space-around;"
>
...
...
@@ -128,7 +128,9 @@ button{
// xxx.js
export
default
{
private
:
{
loopval
:
-
1
,
scroll
:
10
,
isleft
:
"
left
"
,
loopval
:
-
1
,
scroll
:
10
,
isleft
:
"
left
"
,
},
onInit
(){
},
...
...
@@ -148,7 +150,7 @@ export default {
>
> When the value of **loop** is less than or equal to 0, the marquee scrolls continuously. If **loop** is not set, the default value **-1** is used.
![
en-us_image_00000012
76162773
](
figures/en-us_image_0000001276162773
.gif
)
![
en-us_image_00000012
27701867
](
figures/en-us_image_0000001227701867
.gif
)
## Example Scenario
...
...
@@ -164,7 +166,7 @@ Set **loop** to **1**. When scrolling ends, trigger a **finish** event to increa
<div
class=
"mymarquee"
>
<marquee
style=
"color: {{color1}}"
loop=
"{{loopval}}"
scrollamount=
"{{scroll}}"
direction=
"{{isleft}}"
class=
"marqueetext"
id=
"testmarquee"
onfinish=
"setfinish"
>
It's a racing lamp
Life is a journey, not the destination.
</marquee>
</div>
<div
style=
"width: 600px;height: 150px;flex-direction: row;justify-content: space-around;"
>
...
...
@@ -233,4 +235,4 @@ export default {
}
```
![
en-us_image_0000001
276003541
](
figures/en-us_image_0000001276003541
.gif
)
![
en-us_image_0000001
176075554
](
figures/en-us_image_0000001176075554
.gif
)
en/application-dev/ui/ui-js-components-search.md
浏览文件 @
e3f34c48
...
...
@@ -62,7 +62,7 @@ Set the **hint**, **icon**, and **searchbutton** to define the hint text, icon,
## Adding Styles
Set
**color**
,
**placeholder**
, and
**caret-color**
to set the text color, hint text color, and cursor color of the search box.
Set
**color**
,
**placeholder
-color
**
, and
**caret-color**
to set the text color, hint text color, and cursor color of the search box.
```
html
...
...
@@ -84,7 +84,9 @@ Set **color**, **placeholder**, and **caret-color** to set the text color, hint
background-color
:
#F1F3F5
;
}
search
{
color
:
black
;
placeholder-color
:
black
;
caret-color
:
red
;
color
:
black
;
placeholder-color
:
black
;
caret-color
:
red
;
}
```
...
...
@@ -130,34 +132,34 @@ text{
```
js
// index.js
import
prompt
from
'
@system.prompt
'
import
prompt
Action
from
'
@ohos.promptAction
'
export
default
{
search
(
e
){
prompt
.
showToast
({
prompt
Action
.
showToast
({
message
:
e
.
value
,
duration
:
3000
,
});
},
translate
(
e
){
prompt
.
showToast
({
prompt
Action
.
showToast
({
message
:
e
.
value
,
duration
:
3000
,
});
},
share
(
e
){
prompt
.
showToast
({
prompt
Action
.
showToast
({
message
:
e
.
value
,
duration
:
3000
,
});
},
change
(
e
){
prompt
.
showToast
({
prompt
Action
.
showToast
({
message
:
e
.
value
,
duration
:
3000
,
});
},
submit
(
e
){
prompt
.
showToast
({
prompt
Action
.
showToast
({
message
:
'
submit
'
,
duration
:
3000
,
});
...
...
@@ -216,7 +218,7 @@ In this example, you can select the **<search>**, **<textarea>**, or
```
js
// index.js
import
prompt
from
'
@system.prompt
'
;
import
prompt
Action
from
'
@ohos.promptAction
'
;
export
default
{
data
:
{
showsearch
:
true
,
...
...
@@ -241,13 +243,13 @@ export default {
}
},
submit
(
e
)
{
prompt
.
showToast
({
prompt
Action
.
showToast
({
message
:
'
Search!
'
,
duration
:
2000
})
},
change
(
e
)
{
prompt
.
showToast
({
prompt
Action
.
showToast
({
message
:
'
Content:
'
+
e
.
text
,
duration
:
2000
})
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录