@liujitcn/kratos-taro-app-ui 0.1.4 → 0.1.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -15,3 +15,9 @@
15
15
  ```
16
16
 
17
17
  业务代码只从本包公开入口引用图标。不要直接依赖 NutUI 的内部路径;按需加载细节由本包统一维护。
18
+
19
+ ## 统一圆角
20
+
21
+ 主题提供 `--kratos-page-radius: 12px`(Taro 设计稿单位),按 750 设计宽度转换,与 uni-app 的 `12rpx` 对齐,在 375 逻辑宽度下约为 6px。普通卡片、按钮、输入框、消息气泡和弹窗统一使用 `var(--kratos-page-radius)`;底部面板使用 `var(--kratos-page-radius) var(--kratos-page-radius) 0 0`。NutUI 按钮圆角也映射到此变量。
22
+
23
+ 圆形元素使用 `50%`,直角使用 `0`;CSS 绘制的图标和 AI 头像保留造型所需圆角。宿主可以在全局主题引入后,通过 `page`、`.theme-light` 和 `.theme-dark` 覆盖统一圆角,业务页面继续消费变量。
package/package.json CHANGED
@@ -7,7 +7,7 @@
7
7
  "type": "git",
8
8
  "url": "git@github.com:liujitcn/kratos-admin.git"
9
9
  },
10
- "version": "0.1.4",
10
+ "version": "0.1.11",
11
11
  "type": "module",
12
12
  "files": [
13
13
  "src",
@@ -29,7 +29,7 @@
29
29
  "react": "18.3.1"
30
30
  },
31
31
  "peerDependencies": {
32
- "@liujitcn/kratos-taro-app-core": "^0.1.4"
32
+ "@liujitcn/kratos-taro-app-core": "^0.1.11"
33
33
  },
34
34
  "scripts": {
35
35
  "build": "pnpm pack --pack-destination ../../dist/npm",
@@ -4,6 +4,14 @@
4
4
  * 页面根节点绑定 .theme-light 或 .theme-dark 后变量随主题生效。
5
5
  * ============================================================ */
6
6
 
7
+ /* 普通矩形控件共用圆角,375 逻辑宽度下约为 6px。 */
8
+ :root,
9
+ page,
10
+ .theme-light,
11
+ .theme-dark {
12
+ --kratos-page-radius: 12px;
13
+ }
14
+
7
15
  :root,
8
16
  page,
9
17
  .theme-light {
@@ -53,7 +61,7 @@ page,
53
61
  --nutui-color-background: #eef3f8;
54
62
  --nutui-color-title: #102232;
55
63
  --nutui-color-text-help: #5a7083;
56
- --nutui-button-border-radius: 6px;
64
+ --nutui-button-border-radius: var(--kratos-page-radius);
57
65
  }
58
66
 
59
67
  /* 暗黑主题:深色数据驾驶舱 */