@coffic/cosy-ui 0.9.7 → 0.9.9

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
@@ -2,14 +2,14 @@
2
2
 
3
3
  [![English](https://img.shields.io/badge/English-violet)](README.md)
4
4
  [![简体中文](https://img.shields.io/badge/中文文档-gray)](docs/README-zh.md)
5
- [![Release](https://img.shields.io/github/v/release/cofficlab/cosy-ui?style=flat-square&logo=github&color=blue)](https://github.com/yuaotian/go-cursor-help/releases/latest)
5
+ [![Release](https://img.shields.io/github/v/release/cosyzone/cosy-ui?style=flat-square&logo=github&color=blue)](https://github.com/yuaotian/go-cursor-help/releases/latest)
6
6
  [![DEV](https://img.shields.io/badge/DEV-gray)](README-dev.md)
7
7
  [![NPM](https://img.shields.io/badge/NPM-orange)](https://www.npmjs.com/package/@coffic/cosy-ui)
8
8
  ![NPM Downloads](https://img.shields.io/npm/dm/%40coffic%2Fcosy-ui)
9
9
  ![NPM Version](https://img.shields.io/npm/v/%40coffic%2Fcosy-ui)
10
10
  [![Coffic](https://img.shields.io/badge/Coffic-green)](https://coffic.cn)
11
11
  [![Maintainer](https://img.shields.io/badge/Maintainer-blue)](https://github.com/nookery)
12
- ![GitHub License](https://img.shields.io/github/license/cofficlab/cosy-ui)
12
+ ![GitHub License](https://img.shields.io/github/license/cosyzone/cosy-ui)
13
13
 
14
14
  This is an Astro component library that provides a unified UI style for multiple projects under the same organization.
15
15
 
@@ -28,4 +28,4 @@ Usage in Astro components:
28
28
  import { Button } from "@coffic/cosy-ui";
29
29
  ---
30
30
  <Button>Hi</Button>
31
- ```
31
+ ```
@@ -93,8 +93,12 @@ export class LanguageUtil {
93
93
  private static getLanguageFromBrowser(): string | undefined {
94
94
  if (typeof navigator === 'undefined') return undefined;
95
95
 
96
- // 获取浏览器语言
97
- const browserLang = navigator.language.toLowerCase();
98
- return browserLang;
96
+ const browserLang = navigator.language;
97
+
98
+ if (browserLang) {
99
+ return browserLang.toLowerCase();
100
+ }
101
+
102
+ return undefined;
99
103
  }
100
104
  }
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "@coffic/cosy-ui",
3
- "version": "0.9.7",
3
+ "version": "0.9.9",
4
4
  "description": "An astro component library",
5
5
  "author": {
6
6
  "name": "nookery",
7
7
  "url": "https://github.com/nookery"
8
8
  },
9
9
  "repository": {
10
- "url": "https://github.com/CofficLab/cosy-ui"
10
+ "url": "https://github.com/CosyZone/cosy-ui"
11
11
  },
12
12
  "license": "MIT",
13
13
  "keywords": [
@@ -17,7 +17,7 @@
17
17
  "astro",
18
18
  "cosy-ui"
19
19
  ],
20
- "homepage": "https://cofficlab.github.io/cosy-ui/en/",
20
+ "homepage": "https://cosyzone.github.io/cosy-ui/en/",
21
21
  "publishConfig": {
22
22
  "access": "public"
23
23
  },