zova-ui-empty 5.1.52 → 5.1.54

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/env/.env CHANGED
@@ -58,7 +58,7 @@ SSR_API_BASE_URL = $API_BASE_URL
58
58
  SSR_PROD_PORT = 3000
59
59
  SSR_PROD_PROTOCOL = http
60
60
  SSR_PROD_HOST = localhost:3000
61
- SSR_HMR = false
61
+ SSR_WITH_VONA = false
62
62
  SSR_TRANSFERCACHE = false
63
63
  SSR_TRANSFERCACHE_EXPIRES = 0
64
64
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "zova-ui-empty",
3
- "version": "5.1.52",
4
- "gitHead": "2a37020557c59191fdaae0def6cb2a69fa0b2c21",
3
+ "version": "5.1.54",
4
+ "gitHead": "105e4dce1e85740f1f8a7ba9add2029beeaf9316",
5
5
  "description": "A vue3 empty framework with ioc",
6
6
  "keywords": [
7
7
  "ioc",
@@ -74,8 +74,8 @@
74
74
  "vue": "^3.5.6",
75
75
  "vue-router": "^4.4.5",
76
76
  "zod": "^4.3.6",
77
- "zova": "^5.1.35",
78
- "zova-jsx": "^1.1.18",
77
+ "zova": "^5.1.37",
78
+ "zova-jsx": "^1.1.20",
79
79
  "zova-module-a-action": "^5.1.11",
80
80
  "zova-module-a-actions": "^5.1.9",
81
81
  "zova-module-a-api": "^5.1.8",
@@ -89,22 +89,22 @@
89
89
  "zova-module-a-fetch": "^5.1.8",
90
90
  "zova-module-a-form": "^5.1.9",
91
91
  "zova-module-a-icon": "^5.1.11",
92
- "zova-module-a-interceptor": "^5.1.13",
92
+ "zova-module-a-interceptor": "^5.1.14",
93
93
  "zova-module-a-logger": "^5.1.9",
94
94
  "zova-module-a-meta": "^5.1.8",
95
95
  "zova-module-a-model": "^5.1.11",
96
- "zova-module-a-openapi": "^5.1.9",
96
+ "zova-module-a-openapi": "^5.1.10",
97
97
  "zova-module-a-pinia": "^5.1.8",
98
98
  "zova-module-a-router": "^5.1.11",
99
99
  "zova-module-a-routerstack": "^5.1.9",
100
- "zova-module-a-routertabs": "^5.1.12",
100
+ "zova-module-a-routertabs": "^5.1.13",
101
101
  "zova-module-a-ssr": "^5.1.10",
102
- "zova-module-a-ssrhmr": "^5.1.8",
102
+ "zova-module-a-ssrhmr": "^5.1.9",
103
103
  "zova-module-a-ssrserver": "^5.1.8",
104
- "zova-module-a-style": "^5.1.11",
104
+ "zova-module-a-style": "^5.1.12",
105
105
  "zova-module-a-table": "^5.1.9",
106
106
  "zova-module-a-zod": "^5.1.11",
107
- "zova-module-a-zova": "^5.1.22",
107
+ "zova-module-a-zova": "^5.1.24",
108
108
  "zova-module-demo-basic": "workspace:^",
109
109
  "zova-module-home-api": "workspace:^",
110
110
  "zova-module-home-base": "workspace:^",
@@ -33,7 +33,10 @@ export default function (sys: ZovaSys) {
33
33
 
34
34
  // ssr
35
35
  config.ssr = {
36
- cookie: sys.env.SSR_COOKIE === 'true',
36
+ cookie: env.SSR_COOKIE === 'true',
37
+ withVona: env.SSR_WITH_VONA === 'true',
38
+ ignoreCookieOnServer: process.env.SERVER && env.SSR_COOKIE === 'false',
39
+ hmr: env.SSR_WITH_VONA === 'true' && env.META_MODE === 'development',
37
40
  };
38
41
 
39
42
  // ws
@@ -8,7 +8,7 @@ import { BeanRouterGuardsBase } from 'zova-module-a-router';
8
8
  export class ServiceRouterGuards extends BeanRouterGuardsBase {
9
9
  protected onRouterGuards(router: BeanRouter) {
10
10
  router.beforeEach(async to => {
11
- if (!this.sys.util.ignoreCookieOnServer() && to.meta.requiresAuth !== false && !this.$passport.isAuthenticated) {
11
+ if (!this.sys.config.ssr.ignoreCookieOnServer && to.meta.requiresAuth !== false && !this.$passport.isAuthenticated) {
12
12
  const [_res, err] = await catchError(() => {
13
13
  return this.$passport.ensurePassport();
14
14
  });
@@ -22,7 +22,7 @@ export class ModelMenu extends BeanModelBase {
22
22
  return this._prepareMenuTree(queryMenus.data);
23
23
  });
24
24
  // event
25
- if (process.env.CLIENT && this.sys.env.SSR_HMR === 'true') {
25
+ if (process.env.CLIENT && this.sys.config.ssr.hmr) {
26
26
  this._eventSsrHmrReload = this.sys.meta.event.on('a-ssrhmr:reload', async (_data, next) => {
27
27
  await this.$refetchQueries({ queryKey: ['retrieveMenus'] });
28
28
  return next();
@@ -30,7 +30,7 @@ export class ModelPassport extends BeanModelBase {
30
30
  this.passport = process.env.CLIENT ? this.$useStateLocal({ queryKey: ['passport'] }) : this.$useStateMem({ queryKey: ['passport'] });
31
31
  this.jwt = this.$useStateLocal({ queryKey: ['jwt'] });
32
32
  this.expireTime = this.$useStateLocal({ queryKey: ['expireTime'] });
33
- this.accessToken = this.sys.util.ignoreCookieOnServer() ? undefined : this.$useStateCookie({ queryKey: ['token'] });
33
+ this.accessToken = this.sys.config.ssr.ignoreCookieOnServer ? undefined : this.$useStateCookie({ queryKey: ['token'] });
34
34
  if (process.env.CLIENT) {
35
35
  this._setLocaleTz();
36
36
  }