@oinone/kunlun-theme 7.1.0 → 7.2.0

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oinone/kunlun-theme",
3
- "version": "7.1.0",
3
+ "version": "7.2.0",
4
4
  "type": "module",
5
5
  "main": "dist/oinone-kunlun-theme.esm.js",
6
6
  "scripts": {
@@ -15,7 +15,7 @@
15
15
  "postpublish": "node ../../../../scripts/postpublish.cjs"
16
16
  },
17
17
  "dependencies": {
18
- "@oinone/kunlun-config": "7.1.0"
18
+ "@oinone/kunlun-config": "7.2.0"
19
19
  },
20
20
  "gitHead": "2b4c0c7911626c105ca71c2d41e54af470e2e079",
21
21
  "module": "dist/oinone-kunlun-theme.esm.js",
@@ -27,7 +27,7 @@ export function genCSSVars(themes: ThemeName[], el?: string, prefix?: string) {
27
27
  ? (document.getElementsByClassName(el)[0] as HTMLElement)
28
28
  : (document.documentElement as HTMLElement);
29
29
  if (!element) {
30
- throw new Error('挂载dom匹配失败');
30
+ throw new Error('Mount DOM match failed');
31
31
  }
32
32
 
33
33
  const styleTags = Array.from(document.getElementsByTagName('style')) || [];
@@ -57,7 +57,7 @@ export class ColorHelper {
57
57
  public static getAlphaColor(color: string, alpha: number, backgroundColor = '#FFFFFF') {
58
58
  // 验证输入
59
59
  if (alpha < 0 || alpha > 1) {
60
- throw new Error('透明度必须是01之间的数值');
60
+ throw new Error('The opacity must be a value between 0 and 1.');
61
61
  }
62
62
 
63
63
  // 转换为RGB