Compare commits

...

5 Commits

Author SHA1 Message Date
chorblack
2a87eca8e4 模块化准备 2025-04-26 23:01:14 +08:00
chorblack
a18a07be71 ... 2025-04-26 22:59:40 +08:00
chorblack
36e25fa8a9 模块化准备 2025-04-26 22:58:47 +08:00
chorblack
4e80d6236c Merge branch 'main' of git.chorblack.top:admin/keypan 2025-04-26 22:53:01 +08:00
chorblack
515ea8665c 修改显示bug 2025-04-26 22:52:58 +08:00
2 changed files with 6 additions and 53 deletions

View File

@@ -1,36 +0,0 @@
# 手表示例模版
## 文件结构
```
├── sign # 存储 rpk 包签名模块(须自行生成);
│ ├── certificate.pem # 证书文件
│ └── private.pem # 私钥文件
└── src
│ ├── assets # 公用的资源(images/styles/字体...)
│ │ ├──images # 存储 png/jpg/svg 等公共图片资源
│ │ └──styles # 存放 less/css/sass 等公共样式资源
│ ├── pages # 统一存放项目页面级代码
│ ├── app.ux # 应用程序代码的入口文件
│ ├── manifest.json # 配置蓝河应用基本信息
│ └── components # 存放蓝河应用组件
└── package.json # 定义项目需要的各种模块及配置信息
```
### 模版说明
- `Demo` 页面:示例页面;
- `DemoDetail`页面:详情页面;
## 如何使用
- **内置样式处理方案**;「蓝河应用」支持 `sass` 的预编译;这里采取 [dart sass](https://sass-lang.com/documentation) 方案,并内置了部分变量,以及常用混合方法,使得可以轻松开启样式编写、复用、修改等;
- **添加新增页面命令脚本**;如果需要新建页面,只需运行:`yarn gen YourPageName` ,当然,也可以根据需要,自行定定制模板:*/command/gen/template.ux*
- **集成 [Prettier](https://prettier.io/)**;在检测代码中潜在问题的同时,统一团队代码规范、风格(`js``less``scss`等),从而促使写出高质量代码,以提升工作效率(尤其针对团队开发)
## 内置命令
| 命令 | 描述 | 备注 |
|---|---|---|
| `yarn gen ` | 新增「蓝河应用」页面 | 助你高效生成页面,模版可自定义,推荐 ✓|
| `yarn prettier` | 一键美化代码(js/css/less/ux) | 实在是团队开发好帮手,推荐 ✓ |

View File

@@ -1,32 +1,20 @@
<template>
<div class="container">
<swiper class="container-swiper" index="{{ sindex }} " vertical="true" loop="false" onchange="changeSwiper">
<div class="container-col">
<div class="text-container">
<text>输入法demo</text>
<text class="text-content">{{inputWords}}_</text>
</div>
<div class="container-row">
<input type="button" value="返回" class="func-button" onclick="cancelInput"></input>
<input type="button" value="确定" class="func-button" onclick="finishInput"></input>
<input type="button" value="退格" class="func-button" onclick="wordsBackspace"></input>
</div>
<text>上滑输入文字</text>
</div>
<div class="container-col">
<text class="letters-display">{{ letters }}</text>
<text class="words-preview">{{ words }}</text>
<div class="container-row-candidate">
<input type="button" value="<" class="candidate-word-button" onclick="wordsPageBack"></input>
<input type="button" value="{{ currentWords[0] }}" class="candidate-word-button"
<input type="button" value="{{ currentWords[0]||'' }}" class="candidate-word-button"
onclick="selectInput(currentWords[0])"></input>
<input type="button" value="{{ currentWords[1] }}" class="candidate-word-button"
<input type="button" value="{{ currentWords[1]||'' }}" class="candidate-word-button"
onclick="selectInput(currentWords[1])"></input>
<input type="button" value="{{ currentWords[2] }}" class="candidate-word-button"
<input type="button" value="{{ currentWords[2]||'' }}" class="candidate-word-button"
onclick="selectInput(currentWords[2])"></input>
<input type="button" value="{{ currentWords[3] }}" class="candidate-word-button"
<input type="button" value="{{ currentWords[3] ||''}}" class="candidate-word-button"
onclick="selectInput(currentWords[3])"></input>
<input type="button" value="{{ currentWords[4] }}" class="candidate-word-button"
<input type="button" value="{{ currentWords[4] ||''}}" class="candidate-word-button"
onclick="selectInput(currentWords[4])"></input>
<input type="button" value=">" class="candidate-word-button" onclick="wordsPageForward"></input>
</div>
@@ -353,6 +341,7 @@ export default {
height: 60px;
color: #f0f8ff;
background-color: #9f83fb;
border-radius: 25px; /* 新增圆角 */
}
.active-mode {
background-color: #2196F3;