Skip to content

Commit

Permalink
chore: 无法运行。重构
Browse files Browse the repository at this point in the history
  • Loading branch information
terwer committed Jun 15, 2023
1 parent e1dedf6 commit b9fabc6
Show file tree
Hide file tree
Showing 12 changed files with 47 additions and 17 deletions.
6 changes: 0 additions & 6 deletions .changeset/hungry-radios-sparkle.md

This file was deleted.

6 changes: 6 additions & 0 deletions apps/zhi-cli/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# zhi-cli

## 1.5.10

### Patch Changes

- zhi-log@1.14.10

## 1.5.9

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion apps/zhi-cli/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "zhi-cli",
"version": "1.5.9",
"version": "1.5.10",
"description": "a tool for generating zhi framework related projects",
"type": "module",
"bin": {
Expand Down
6 changes: 6 additions & 0 deletions libs/zhi-device/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# zhi-device

## 2.3.0

### Minor Changes

- add custom time for reload

## 2.2.0

### Minor Changes
Expand Down
2 changes: 1 addition & 1 deletion libs/zhi-device/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "zhi-device",
"version": "2.2.0",
"version": "2.3.0",
"type": "module",
"main": "./dist/index.js",
"typings": "./dist/index.d.ts",
Expand Down
15 changes: 9 additions & 6 deletions libs/zhi-device/src/lib/browserUtil.ts
Original file line number Diff line number Diff line change
Expand Up @@ -189,33 +189,36 @@ class BrowserUtil {
* @param tabname - tabname
* @param t - 延迟时间
*/
public static reloadTabPage = (tabname: string, t = 200): void => {
public static reloadTabPage = (tabname: string, t?: number): void => {
setTimeout(function () {
if (BrowserUtil.isInBrowser) {
const url = window.location.href
window.location.href = BrowserUtil.setUrlParameter(url, "tab", tabname)
}
}, t)
}, t ?? 200)
}

/**
* 刷新当前tab页面
*
* @param t - 延迟时间
*/
public static reloadPage = (): void => {
public static reloadPage = (t?: number): void => {
setTimeout(function () {
if (BrowserUtil.isInBrowser) {
window.location.reload()
}
}, 200)
}, t ?? 200)
}

/**
* 刷新当前tab页面
*
* @param msg - 消息提示
* @param cb - 回调
* @param t - 延迟时间
*/
public static reloadPageWithMessageCallback = (msg: string, cb: any): void => {
public static reloadPageWithMessageCallback = (msg: string, cb?: any, t?: number): void => {
if (cb) {
cb(msg)
}
Expand All @@ -224,7 +227,7 @@ class BrowserUtil {
if (BrowserUtil.isInBrowser) {
window.location.reload()
}
}, 200)
}, t ?? 200)
}
}

Expand Down
7 changes: 7 additions & 0 deletions libs/zhi-fetch-middleware/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# zhi-fetch-middleware

## 0.1.14

### Patch Changes

- Updated dependencies
- zhi-device@2.3.0

## 0.1.13

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion libs/zhi-fetch-middleware/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "zhi-fetch-middleware",
"version": "0.1.13",
"version": "0.1.14",
"type": "module",
"description": "an intermediate tier prepared for fetch requests",
"main": "./dist/index.js",
Expand Down
7 changes: 7 additions & 0 deletions libs/zhi-log/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# zhi-log

## 1.14.10

### Patch Changes

- Updated dependencies
- zhi-device@2.3.0

## 1.14.9

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion libs/zhi-log/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "zhi-log",
"version": "1.14.9",
"version": "1.14.10",
"type": "module",
"main": "./dist/index.js",
"typings": "./dist/index.d.ts",
Expand Down
7 changes: 7 additions & 0 deletions libs/zhi-xmlrpc-middleware/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# zhi-xmlrpc-middleware

## 0.2.14

### Patch Changes

- Updated dependencies
- zhi-device@2.3.0

## 0.2.13

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion libs/zhi-xmlrpc-middleware/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "zhi-xmlrpc-middleware",
"version": "0.2.13",
"version": "0.2.14",
"type": "module",
"description": "abstract xmlrpc middle layer",
"main": "./dist/index.js",
Expand Down

0 comments on commit b9fabc6

Please sign in to comment.