zova-module-a-routerstack 5.1.28 → 5.1.30

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.
@@ -1,6 +1,6 @@
1
1
  import type { TypeControllerInnerProps } from 'zova';
2
- import type { ControllerRouterViewStackProps } from '../../component/routerViewStack/controller.jsx';
3
- import { ControllerRouterViewStack } from '../../component/routerViewStack/controller.jsx';
2
+ import type { ControllerRouterViewStackProps } from '../../component/routerViewStack/controller.tsx';
3
+ import { ControllerRouterViewStack } from '../../component/routerViewStack/controller.tsx';
4
4
  export type ZRouterViewStackProps = {
5
5
  controllerRef?: (ref: ControllerRouterViewStack) => void;
6
6
  } & ControllerRouterViewStackProps;
@@ -1,6 +1,6 @@
1
1
  /** model: begin */
2
- export * from '../model/stack.js';
3
- import { IModelOptionsStack } from '../model/stack.js';
2
+ export * from '../model/stack.ts';
3
+ import { IModelOptionsStack } from '../model/stack.ts';
4
4
  import 'zova-module-a-model';
5
5
  declare module 'zova-module-a-model' {
6
6
  interface IModelRecord {
@@ -18,7 +18,7 @@ declare module 'zova-module-a-routerstack' {
18
18
  }
19
19
  /** model: end */
20
20
  /** model: begin */
21
- import { ModelStack } from '../model/stack.js';
21
+ import type { ModelStack } from '../model/stack.ts';
22
22
  import 'zova';
23
23
  declare module 'zova' {
24
24
  interface IBeanRecordGeneral {
@@ -27,7 +27,7 @@ declare module 'zova' {
27
27
  }
28
28
  /** model: end */
29
29
  /** controller: begin */
30
- export * from '../component/routerViewStack/controller.jsx';
30
+ export * from '../component/routerViewStack/controller.tsx';
31
31
  import 'zova';
32
32
  declare module 'zova' {
33
33
  }
@@ -37,7 +37,7 @@ declare module 'zova-module-a-routerstack' {
37
37
  }
38
38
  /** controller: end */
39
39
  /** controller: begin */
40
- import { ControllerRouterViewStack } from '../component/routerViewStack/controller.jsx';
40
+ import type { ControllerRouterViewStack } from '../component/routerViewStack/controller.tsx';
41
41
  import 'zova';
42
42
  declare module 'zova' {
43
43
  interface IBeanRecordLocal {
@@ -46,8 +46,8 @@ declare module 'zova' {
46
46
  }
47
47
  /** controller: end */
48
48
  /** components: begin */
49
- export * from './component/routerViewStack.js';
50
- import { ZRouterViewStack } from './component/routerViewStack.js';
49
+ export * from './component/routerViewStack.ts';
50
+ import { ZRouterViewStack } from './component/routerViewStack.ts';
51
51
  export declare const components: {
52
52
  routerViewStack: import("vue").DefineSetupFnComponent<import("zova-module-a-routerstack").ZRouterViewStackProps, import("vue").EmitsOptions, import("vue").SlotsType<Record<string, any>>, {
53
53
  controllerRef?: (ref: ControllerRouterViewStack) => void;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/.metadata/index.ts"],"names":[],"mappings":"AACA,mBAAmB;AACnB,cAAc,mBAAmB,CAAC;AAClC,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AACvD,OAAO,qBAAqB,CAAC;AAC7B,OAAO,QAAQ,qBAAqB,CAAC;IAEjC,UAAiB,YAAY;QAC3B,qBAAqB,EAAE,kBAAkB,CAAC;KAC3C;CAGJ;AACD,OAAO,QAAQ,2BAA2B,CAAC;IAEnC,UAAiB,UAAU;KAG1B;IAED,UAAiB,UAAU;QACzB,IAAI,aAAa,IAAI,2BAA2B,CAAC;QACjD,IAAI,UAAU,IAAI,qBAAqB,CAAC;QACxC,IAAI,aAAa,IAAI,kBAAkB,CAAC;KACzC;CACR;AACD,iBAAiB;AACjB,mBAAmB;AACnB,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,MAAM,CAAC;AACd,OAAO,QAAQ,MAAM,CAAC;IACpB,UAAiB,kBAAkB;QACjC,2BAA2B,EAAE,UAAU,CAAC;KACzC;CACF;AACD,iBAAiB;AACjB,wBAAwB;AACxB,cAAc,6CAA6C,CAAC;AAE5D,OAAO,MAAM,CAAC;AACd,OAAO,QAAQ,MAAM,CAAC;CAGrB;AACD,OAAO,QAAQ,2BAA2B,CA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AAGzD,qBACa,uBAAwB,SAAQ,aAAa;CAAG;AAE7D,MAAM,WAAW,uBAAuB;IACtC,IAAI,EAAE,aAAa,CAAC;CACrB;AAED,OAAO,MAAM,CAAC;AACd,OAAO,QAAQ,MAAM,CAAC;IACpB,UAAiB,gBAAgB;QAC/B,eAAe,EAAE,uBAAuB,CAAC;KAC1C;CAOF;AAED,iBAAiB"}
@@ -1,3 +1,3 @@
1
1
  export declare const __ThisModule__ = "a-routerstack";
2
- export { ScopeModuleARouterstack as ScopeModule } from './index.js';
2
+ export { ScopeModuleARouterstack as ScopeModule } from './index.ts';
3
3
  //# sourceMappingURL=this.d.ts.map
@@ -1,6 +1,6 @@
1
1
  import { RouteLocationNormalizedLoadedGeneric } from '@cabloy/vue-router';
2
2
  import { BeanRouterViewBase, IRouterViewPropsBase, IRouteViewRouteMeta } from 'zova-module-a-router';
3
- import type { ModelStack } from '../../model/stack.js';
3
+ import type { ModelStack } from '../../model/stack.ts';
4
4
  export interface ControllerRouterViewStackProps extends IRouterViewPropsBase {
5
5
  pageHostProviders?: Record<string, unknown>;
6
6
  }
package/dist/index.d.ts CHANGED
@@ -1,3 +1,3 @@
1
- export * from './.metadata/index.js';
2
- export * from './types/index.js';
1
+ export * from './.metadata/index.ts';
2
+ export * from './types/index.ts';
3
3
  //# sourceMappingURL=index.d.ts.map
package/dist/index.js CHANGED
@@ -181,8 +181,6 @@ var ZRouterViewStack = defineComponent((_props) => {
181
181
  }, prepareComponentOptions());
182
182
  //#endregion
183
183
  //#region src/.metadata/index.ts
184
- /** components: end */
185
- /** scope: begin */
186
184
  var _dec;
187
185
  var _dec2;
188
186
  var _class;
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["Use","Controller","BeanRouterViewBase","ControllerRouterViewStack","_dec","_dec2","__z_BeanInfo","module","_dec3","injectionScope","_dec4","Reflect","metadata","ModelStack","Object","_class","_class2","_ControllerRouterViewStack","constructor","args","_initializerDefineProperty","_descriptor","backRoute","route","$$modelStack","forwardRoute","prepareRouteMeta","getKeepAliveInclude","keepAliveInclude","getPageHostProviders","$props","pageHostProviders","$propsDefault","_applyDecoratedDescriptor","prototype","configurable","enumerable","writable","initializer"],"sources":["../src/model/stack.ts","../src/component/routerViewStack/controller.tsx","../src/.metadata/component/routerViewStack.ts","../src/.metadata/index.ts"],"sourcesContent":["var _dec, _dec2, _class;\nimport { \"BeanInfo\" as __z_BeanInfo } from \"zova\";\nimport { mutate } from 'mutate-on-copy';\nimport { deepExtend } from 'zova';\nimport { BeanModelBase, Model } from 'zova-module-a-model';\nexport let ModelStack = (_dec = Model({\n enableSelector: true,\n max: -1\n}), _dec2 = __z_BeanInfo({\n module: \"a-routerstack\"\n}), _dec(_class = _dec2(_class = class ModelStack extends BeanModelBase {\n constructor(...args) {\n super(...args);\n this.stackOptions = void 0;\n this.tabs = void 0;\n this.keepAliveInclude = void 0;\n }\n async __init__(scene, options) {\n await super.__init__(scene);\n this.bean._setBean('$$modelStack', this);\n // options\n this.stackOptions = deepExtend({}, this.$onionOptions, options);\n // tabs: always []\n this.tabs = [];\n // computed\n this.keepAliveInclude = this.$computed(() => {\n return this._getKeepAliveInclude();\n });\n // first route\n if (this.$currentRoute) {\n this.forwardRoute(this.$currentRoute);\n }\n }\n addTab(tab) {\n return this._addTab(tab);\n }\n _addTab(tab) {\n const tabKey = tab.tabKey;\n if (!tabKey) return false;\n // tab\n const [index, tabOld] = this.findTab(tabKey);\n // tabs\n if (index === -1) {\n // new\n const tabNew = {\n tabKey,\n updatedAt: Date.now()\n };\n this.tabs = mutate(this.tabs, copyState => {\n copyState.push(tabNew);\n });\n this.pruneTabs();\n } else {\n // update\n if (!this._checkIfTabNeedUpdate(tabOld, tab)) {\n return false;\n }\n this.updateTab(tab);\n }\n return true;\n }\n findTab(tabKey) {\n if (!tabKey) return [-1, undefined];\n const index = this.tabs.findIndex(item => item.tabKey === tabKey);\n if (index === -1) return [index, undefined];\n return [index, this.tabs[index]];\n }\n deleteTab(tabKey) {\n if (!tabKey) return false;\n // tabs\n const [index] = this.findTab(tabKey);\n if (index === -1) return false;\n // tabs\n this.tabs = mutate(this.tabs, copyState => {\n copyState.splice(index, 1);\n });\n return true;\n }\n updateTab(tab) {\n const tabKey = tab.tabKey;\n const [index, tabOld] = this.findTab(tabKey);\n if (index === -1 || !tabOld) return;\n const tabNew = {\n ...tabOld,\n tabKey,\n updatedAt: Date.now()\n };\n this.tabs = mutate(this.tabs, copyState => {\n copyState.splice(index, 1, tabNew);\n });\n }\n async pruneTabs() {\n let max = this.stackOptions.max;\n if (max === undefined || max === -1) return;\n if (max < 1) max = 1;\n while (true) {\n if (this.tabs.length <= max) break;\n let tabKey;\n let updatedAt = Date.now();\n for (const tab of this.tabs) {\n if (tab.updatedAt < updatedAt) {\n tabKey = tab.tabKey;\n updatedAt = tab.updatedAt;\n }\n }\n if (!tabKey) break;\n this.deleteTab(tabKey);\n }\n }\n\n // special for _addTab\n _checkIfTabNeedUpdate(tabOld, _tabNew) {\n const recentTabIndex = this.tabs.findIndex(item => item.tabKey !== tabOld.tabKey && (item.updatedAt ?? 0) >= (tabOld.updatedAt ?? 0));\n if (recentTabIndex > -1) return true;\n return false;\n }\n _getKeepAliveInclude() {\n const include = [];\n for (const tab of this.tabs) {\n if (!include.includes(tab.tabKey)) {\n include.push(tab.tabKey);\n }\n }\n return include;\n }\n backRoute(route) {\n this.deleteTab(route.fullPath);\n }\n forwardRoute(route) {\n const componentMeta = this.prepareRouteMeta(route);\n this.addTab(componentMeta);\n }\n prepareRouteMeta(route) {\n // fullPath\n const fullPath = route.fullPath;\n // tab\n return {\n tabKey: fullPath,\n componentKey: fullPath,\n fullPath\n };\n }\n}) || _class) || _class);","import { RouteLocationNormalizedLoadedGeneric } from '@cabloy/vue-router';\nimport { Use } from 'zova';\nimport { Controller } from 'zova-module-a-bean';\nimport {\n BeanRouterViewBase,\n IRouterViewPropsBase,\n IRouteViewRouteMeta,\n} from 'zova-module-a-router';\n\nimport type { ModelStack } from '../../model/stack.js';\n\nexport interface ControllerRouterViewStackProps extends IRouterViewPropsBase {\n pageHostProviders?: Record<string, unknown>;\n}\n\n@Controller()\nexport class ControllerRouterViewStack extends BeanRouterViewBase {\n static $propsDefault = {};\n\n @Use({ injectionScope: 'skipSelf' })\n $$modelStack: ModelStack;\n\n public backRoute(route: RouteLocationNormalizedLoadedGeneric) {\n this.$$modelStack.backRoute(route);\n return true;\n }\n\n public forwardRoute(route: RouteLocationNormalizedLoadedGeneric) {\n this.$$modelStack.forwardRoute(route);\n return true;\n }\n\n protected prepareRouteMeta(route: RouteLocationNormalizedLoadedGeneric): IRouteViewRouteMeta {\n return this.$$modelStack.prepareRouteMeta(route);\n }\n\n protected getKeepAliveInclude(): string[] | undefined {\n return this.$$modelStack.keepAliveInclude;\n }\n\n protected getPageHostProviders(): Record<string, unknown> | undefined {\n return this.$props.pageHostProviders;\n }\n}\n","import { defineComponent } from 'vue';\nimport { prepareComponentOptions, useController } from 'zova';\nimport { ControllerRouterViewStack } from '../../component/routerViewStack/controller.jsx';\nexport const ZRouterViewStack = defineComponent(_props => {\n useController(ControllerRouterViewStack, undefined, undefined);\n return () => {};\n}, prepareComponentOptions());","var _dec, _dec2, _class;\nimport { \"BeanInfo\" as __z_BeanInfo } from \"zova\";\n// eslint-disable\n/** model: begin */\nexport * from '../model/stack.js';\nimport 'zova-module-a-model';\n/** model: end */\n/** model: begin */\nimport { ModelStack } from '../model/stack.js';\nimport 'zova';\n/** model: end */\n/** controller: begin */\nexport * from '../component/routerViewStack/controller.jsx';\nimport 'zova';\n/** controller: end */\n/** controller: begin */\nimport { ControllerRouterViewStack } from '../component/routerViewStack/controller.jsx';\nimport 'zova';\n/** controller: end */\n\n/** components: begin */\nexport * from './component/routerViewStack.js';\nimport { ZRouterViewStack } from './component/routerViewStack.js';\nexport const components = {\n 'routerViewStack': ZRouterViewStack\n};\nimport 'zova';\n/** components: end */\n/** scope: begin */\nimport { BeanScopeBase } from 'zova';\nimport { Scope } from 'zova-module-a-bean';\nexport let ScopeModuleARouterstack = (_dec = Scope(), _dec2 = __z_BeanInfo({\n module: \"a-routerstack\"\n}), _dec(_class = _dec2(_class = class ScopeModuleARouterstack extends BeanScopeBase {}) || _class) || _class);\nimport 'zova';\n\n/** scope: end */"],"mappings":";;;;;;;AAAA,IAAI;AAAM,IAAA;AAAO,IAAA;AAKjB,IAAW,gBAAc,SAAO,MAAM;CACpC,gBAAgB;CAChB,KAAK;AACP,CAAC,GAAG,UAAQ,SAAa,EACvB,QAAQ,gBACV,CAAC,GAAG,OAAK,WAAS,QAAM,WAAS,MAAM,mBAAmB,cAAc;CACtE,YAAY,GAAG,MAAM;EACnB,MAAM,GAAG,IAAI;EACb,KAAK,eAAe,KAAK;EACzB,KAAK,OAAO,KAAK;EACjB,KAAK,mBAAmB,KAAK;CAC/B;CACA,MAAM,SAAS,OAAO,SAAS;EAC7B,MAAM,MAAM,SAAS,KAAK;EAC1B,KAAK,KAAK,SAAS,gBAAgB,IAAI;EAEvC,KAAK,eAAe,WAAW,CAAC,GAAG,KAAK,eAAe,OAAO;EAE9D,KAAK,OAAO,CAAC;EAEb,KAAK,mBAAmB,KAAK,gBAAgB;GAC3C,OAAO,KAAK,qBAAqB;EACnC,CAAC;EAED,IAAI,KAAK,eACP,KAAK,aAAa,KAAK,aAAa;CAExC;CACA,OAAO,KAAK;EACV,OAAO,KAAK,QAAQ,GAAG;CACzB;CACA,QAAQ,KAAK;EACX,MAAM,SAAS,IAAI;EACnB,IAAI,CAAC,QAAQ,OAAO;EAEpB,MAAM,CAAC,OAAO,UAAU,KAAK,QAAQ,MAAM;EAE3C,IAAI,UAAU,IAAI;GAEhB,MAAM,SAAS;IACb;IACA,WAAW,KAAK,IAAI;GACtB;GACA,KAAK,OAAO,OAAO,KAAK,OAAM,cAAa;IACzC,UAAU,KAAK,MAAM;GACvB,CAAC;GACD,KAAK,UAAU;EACjB,OAAO;GAEL,IAAI,CAAC,KAAK,sBAAsB,QAAQ,GAAG,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D;EACpE,OAAO,KAAKC,OAAOC;CACrB;AACF,GAACd,2BA1BQe,gBAAgB,CAAC,GAACf,6BAAAI,cAAAY,0BAAAjB,QAAAkB,WAAA,gBAAA,CAAA1B,OAAAE,KAAA,GAAA;CAAAyB,cAAA;CAAAC,YAAA;CAAAC,UAAA;CAAAC,aAAA;AAAA,CAAA,GAAAtB,QAAA,KAAAD,QAAA,KAAAA;;;ACd3B,IAAa,mBAAmB,iBAAgB,WAAU;CACxD,cAAc,2BAA2B,KAAA,GAAW,KAAA,CAAS;CAC7D,aAAa,CAAC;AAChB,GAAG,wBAAwB,CAAC;;;;;ACN5B,IAAI;AAAM,IAAA;AAAO,IAAA;AAuBjB,IAAa,aAAa,EACxB,mBAAmB,iBACrB;AAMA,IAAW,2BAA2B,OAAO,MAAM,GAAG,QAAQ,SAAa,EACzE,QAAQ,gBACV,CAAC,GAAG,KAAK,SAAS,MAAM,SAAS,MAAM,gCAAgC,cAAc,CAAC,CAAC,KAAK,MAAM,KAAK"}
1
+ {"version":3,"file":"index.js","names":["_dec","_dec2","_class","ModelStack","__z_BeanInfo","Use","Controller","BeanRouterViewBase","ControllerRouterViewStack","_dec","_dec2","__z_BeanInfo","module","_dec3","injectionScope","_dec4","Reflect","metadata","ModelStack","Object","_class","_class2","_ControllerRouterViewStack","constructor","args","_initializerDefineProperty","_descriptor","backRoute","route","$$modelStack","forwardRoute","prepareRouteMeta","getKeepAliveInclude","keepAliveInclude","getPageHostProviders","$props","pageHostProviders","$propsDefault","_applyDecoratedDescriptor","prototype","configurable","enumerable","writable","initializer","_dec","_dec2","_class","__z_BeanInfo","__z_BeanInfo"],"sources":["../src/model/stack.ts","../src/component/routerViewStack/controller.tsx","../src/.metadata/component/routerViewStack.ts","../src/.metadata/index.ts"],"sourcesContent":["var _dec, _dec2, _class;\nimport { \"BeanInfo\" as __z_BeanInfo } from \"zova\";\nimport { mutate } from 'mutate-on-copy';\nimport { deepExtend } from 'zova';\nimport { BeanModelBase, Model } from 'zova-module-a-model';\nexport let ModelStack = (_dec = Model({\n enableSelector: true,\n max: -1\n}), _dec2 = __z_BeanInfo({\n module: \"a-routerstack\"\n}), _dec(_class = _dec2(_class = class ModelStack extends BeanModelBase {\n constructor(...args) {\n super(...args);\n this.stackOptions = void 0;\n this.tabs = void 0;\n this.keepAliveInclude = void 0;\n }\n async __init__(scene, options) {\n await super.__init__(scene);\n this.bean._setBean('$$modelStack', this);\n // options\n this.stackOptions = deepExtend({}, this.$onionOptions, options);\n // tabs: always []\n this.tabs = [];\n // computed\n this.keepAliveInclude = this.$computed(() => {\n return this._getKeepAliveInclude();\n });\n // first route\n if (this.$currentRoute) {\n this.forwardRoute(this.$currentRoute);\n }\n }\n addTab(tab) {\n return this._addTab(tab);\n }\n _addTab(tab) {\n const tabKey = tab.tabKey;\n if (!tabKey) return false;\n // tab\n const [index, tabOld] = this.findTab(tabKey);\n // tabs\n if (index === -1) {\n // new\n const tabNew = {\n tabKey,\n updatedAt: Date.now()\n };\n this.tabs = mutate(this.tabs, copyState => {\n copyState.push(tabNew);\n });\n this.pruneTabs();\n } else {\n // update\n if (!this._checkIfTabNeedUpdate(tabOld, tab)) {\n return false;\n }\n this.updateTab(tab);\n }\n return true;\n }\n findTab(tabKey) {\n if (!tabKey) return [-1, undefined];\n const index = this.tabs.findIndex(item => item.tabKey === tabKey);\n if (index === -1) return [index, undefined];\n return [index, this.tabs[index]];\n }\n deleteTab(tabKey) {\n if (!tabKey) return false;\n // tabs\n const [index] = this.findTab(tabKey);\n if (index === -1) return false;\n // tabs\n this.tabs = mutate(this.tabs, copyState => {\n copyState.splice(index, 1);\n });\n return true;\n }\n updateTab(tab) {\n const tabKey = tab.tabKey;\n const [index, tabOld] = this.findTab(tabKey);\n if (index === -1 || !tabOld) return;\n const tabNew = {\n ...tabOld,\n tabKey,\n updatedAt: Date.now()\n };\n this.tabs = mutate(this.tabs, copyState => {\n copyState.splice(index, 1, tabNew);\n });\n }\n async pruneTabs() {\n let max = this.stackOptions.max;\n if (max === undefined || max === -1) return;\n if (max < 1) max = 1;\n while (true) {\n if (this.tabs.length <= max) break;\n let tabKey;\n let updatedAt = Date.now();\n for (const tab of this.tabs) {\n if (tab.updatedAt < updatedAt) {\n tabKey = tab.tabKey;\n updatedAt = tab.updatedAt;\n }\n }\n if (!tabKey) break;\n this.deleteTab(tabKey);\n }\n }\n\n // special for _addTab\n _checkIfTabNeedUpdate(tabOld, _tabNew) {\n const recentTabIndex = this.tabs.findIndex(item => item.tabKey !== tabOld.tabKey && (item.updatedAt ?? 0) >= (tabOld.updatedAt ?? 0));\n if (recentTabIndex > -1) return true;\n return false;\n }\n _getKeepAliveInclude() {\n const include = [];\n for (const tab of this.tabs) {\n if (!include.includes(tab.tabKey)) {\n include.push(tab.tabKey);\n }\n }\n return include;\n }\n backRoute(route) {\n this.deleteTab(route.fullPath);\n }\n forwardRoute(route) {\n const componentMeta = this.prepareRouteMeta(route);\n this.addTab(componentMeta);\n }\n prepareRouteMeta(route) {\n // fullPath\n const fullPath = route.fullPath;\n // tab\n return {\n tabKey: fullPath,\n componentKey: fullPath,\n fullPath\n };\n }\n}) || _class) || _class);","import { RouteLocationNormalizedLoadedGeneric } from '@cabloy/vue-router';\nimport { Use } from 'zova';\nimport { Controller } from 'zova-module-a-bean';\nimport {\n BeanRouterViewBase,\n IRouterViewPropsBase,\n IRouteViewRouteMeta,\n} from 'zova-module-a-router';\n\nimport type { ModelStack } from '../../model/stack.ts';\n\nexport interface ControllerRouterViewStackProps extends IRouterViewPropsBase {\n pageHostProviders?: Record<string, unknown>;\n}\n\n@Controller()\nexport class ControllerRouterViewStack extends BeanRouterViewBase {\n static $propsDefault = {};\n\n @Use({ injectionScope: 'skipSelf' })\n $$modelStack: ModelStack;\n\n public backRoute(route: RouteLocationNormalizedLoadedGeneric) {\n this.$$modelStack.backRoute(route);\n return true;\n }\n\n public forwardRoute(route: RouteLocationNormalizedLoadedGeneric) {\n this.$$modelStack.forwardRoute(route);\n return true;\n }\n\n protected prepareRouteMeta(route: RouteLocationNormalizedLoadedGeneric): IRouteViewRouteMeta {\n return this.$$modelStack.prepareRouteMeta(route);\n }\n\n protected getKeepAliveInclude(): string[] | undefined {\n return this.$$modelStack.keepAliveInclude;\n }\n\n protected getPageHostProviders(): Record<string, unknown> | undefined {\n return this.$props.pageHostProviders;\n }\n}\n","import { defineComponent } from 'vue';\nimport { prepareComponentOptions, useController } from 'zova';\nimport { ControllerRouterViewStack } from '../../component/routerViewStack/controller.tsx';\nexport const ZRouterViewStack = defineComponent(_props => {\n useController(ControllerRouterViewStack, undefined, undefined);\n return () => {};\n}, prepareComponentOptions());","var _dec, _dec2, _class;\nimport { \"BeanInfo\" as __z_BeanInfo } from \"zova\";\n// eslint-disable\n/** model: begin */\nexport * from '../model/stack.ts';\nimport 'zova-module-a-model';\n/** model: end */\n/** model: begin */\n\nimport 'zova';\n/** model: end */\n/** controller: begin */\nexport * from '../component/routerViewStack/controller.tsx';\nimport 'zova';\n/** controller: end */\n/** controller: begin */\n\nimport 'zova';\n/** controller: end */\n\n/** components: begin */\nexport * from './component/routerViewStack.ts';\nimport { ZRouterViewStack } from './component/routerViewStack.ts';\nexport const components = {\n 'routerViewStack': ZRouterViewStack\n};\nimport 'zova';\n/** components: end */\n/** scope: begin */\nimport { BeanScopeBase } from 'zova';\nimport { Scope } from 'zova-module-a-bean';\nexport let ScopeModuleARouterstack = (_dec = Scope(), _dec2 = __z_BeanInfo({\n module: \"a-routerstack\"\n}), _dec(_class = _dec2(_class = class ScopeModuleARouterstack extends BeanScopeBase {}) || _class) || _class);\nimport 'zova';\n\n/** scope: end */"],"mappings":";;;;;;;AAAA,IAAIA;AAAMC,IAAAA;AAAOC,IAAAA;AAKjB,IAAWC,gBAAc,SAAO,MAAM;CACpC,gBAAgB;CAChB,KAAK;AACP,CAAC,GAAG,UAAQC,SAAa,EACvB,QAAQ,gBACV,CAAC,GAAGJ,OAAK,WAASC,QAAM,WAAS,MAAM,mBAAmB,cAAc;CACtE,YAAY,G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IAAA;AAAO,IAAA;AAuBjB,IAAa,aAAa,EACxB,mBAAmB,iBACrB;AAMA,IAAW,2BAA2B,OAAO,MAAM,GAAG,QAAQ4B,SAAa,EACzE,QAAQ,gBACV,CAAC,GAAG,KAAK,SAAS,MAAM,SAAS,MAAM,gCAAgC,cAAc,CAAC,CAAC,KAAK,MAAM,KAAK"}
@@ -2,7 +2,7 @@ import type { IDecoratorModelOptions } from 'zova-module-a-model';
2
2
  import { RouteLocationNormalizedLoadedGeneric } from '@cabloy/vue-router';
3
3
  import { BeanModelBase } from 'zova-module-a-model';
4
4
  import { IRouteViewRouteMeta } from 'zova-module-a-router';
5
- import { ModelStackOptions, ModelStackOptionsBase, RouteTab, RouteTabTransient } from '../types/stack.js';
5
+ import { ModelStackOptions, ModelStackOptionsBase, RouteTab, RouteTabTransient } from '../types/stack.ts';
6
6
  export interface IModelOptionsStack extends IDecoratorModelOptions, ModelStackOptionsBase {
7
7
  }
8
8
  export declare class ModelStack extends BeanModelBase {
@@ -1,2 +1,2 @@
1
- export * from './stack.js';
1
+ export * from './stack.ts';
2
2
  //# sourceMappingURL=index.d.ts.map
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "zova-module-a-routerstack",
3
- "version": "5.1.28",
4
- "gitHead": "bd7ffc467ab9d5e7e420e38d1c36a1162991f9fc",
3
+ "version": "5.1.30",
4
+ "gitHead": "c27fb3b5f3566b676b7d635e2e26545c6d389ad7",
5
5
  "description": "",
6
6
  "keywords": [
7
7
  "Zova Module"
@@ -3,9 +3,9 @@ import type { TypeControllerInnerProps } from 'zova';
3
3
  import { defineComponent } from 'vue';
4
4
  import { prepareComponentOptions, useController } from 'zova';
5
5
 
6
- import type { ControllerRouterViewStackProps } from '../../component/routerViewStack/controller.jsx';
6
+ import type { ControllerRouterViewStackProps } from '../../component/routerViewStack/controller.tsx';
7
7
 
8
- import { ControllerRouterViewStack } from '../../component/routerViewStack/controller.jsx';
8
+ import { ControllerRouterViewStack } from '../../component/routerViewStack/controller.tsx';
9
9
  export type ZRouterViewStackProps = {
10
10
  controllerRef?: (ref: ControllerRouterViewStack) => void;
11
11
  } & ControllerRouterViewStackProps;
@@ -1,7 +1,7 @@
1
1
  // eslint-disable
2
2
  /** model: begin */
3
- export * from '../model/stack.js';
4
- import { IModelOptionsStack } from '../model/stack.js';
3
+ export * from '../model/stack.ts';
4
+ import { IModelOptionsStack } from '../model/stack.ts';
5
5
  import 'zova-module-a-model';
6
6
  declare module 'zova-module-a-model' {
7
7
 
@@ -26,7 +26,7 @@ declare module 'zova-module-a-routerstack' {
26
26
  }
27
27
  /** model: end */
28
28
  /** model: begin */
29
- import { ModelStack } from '../model/stack.js';
29
+ import type { ModelStack } from '../model/stack.ts';
30
30
  import 'zova';
31
31
  declare module 'zova' {
32
32
  export interface IBeanRecordGeneral {
@@ -35,7 +35,7 @@ declare module 'zova' {
35
35
  }
36
36
  /** model: end */
37
37
  /** controller: begin */
38
- export * from '../component/routerViewStack/controller.jsx';
38
+ export * from '../component/routerViewStack/controller.tsx';
39
39
 
40
40
  import 'zova';
41
41
  declare module 'zova' {
@@ -51,7 +51,7 @@ declare module 'zova-module-a-routerstack' {
51
51
  }
52
52
  /** controller: end */
53
53
  /** controller: begin */
54
- import { ControllerRouterViewStack } from '../component/routerViewStack/controller.jsx';
54
+ import type { ControllerRouterViewStack } from '../component/routerViewStack/controller.tsx';
55
55
  import 'zova';
56
56
  declare module 'zova' {
57
57
  export interface IBeanRecordLocal {
@@ -61,8 +61,8 @@ declare module 'zova' {
61
61
  /** controller: end */
62
62
 
63
63
  /** components: begin */
64
- export * from './component/routerViewStack.js';
65
- import { ZRouterViewStack } from './component/routerViewStack.js';
64
+ export * from './component/routerViewStack.ts';
65
+ import { ZRouterViewStack } from './component/routerViewStack.ts';
66
66
  export const components = {
67
67
  'routerViewStack': ZRouterViewStack,
68
68
  };
@@ -1,2 +1,2 @@
1
1
  export const __ThisModule__ = 'a-routerstack';
2
- export { ScopeModuleARouterstack as ScopeModule } from './index.js';
2
+ export { ScopeModuleARouterstack as ScopeModule } from './index.ts';
@@ -7,7 +7,7 @@ import {
7
7
  IRouteViewRouteMeta,
8
8
  } from 'zova-module-a-router';
9
9
 
10
- import type { ModelStack } from '../../model/stack.js';
10
+ import type { ModelStack } from '../../model/stack.ts';
11
11
 
12
12
  export interface ControllerRouterViewStackProps extends IRouterViewPropsBase {
13
13
  pageHostProviders?: Record<string, unknown>;
package/src/index.ts CHANGED
@@ -1,2 +1,2 @@
1
- export * from './.metadata/index.js';
2
- export * from './types/index.js';
1
+ export * from './.metadata/index.ts';
2
+ export * from './types/index.ts';
@@ -11,7 +11,7 @@ import {
11
11
  ModelStackOptionsBase,
12
12
  RouteTab,
13
13
  RouteTabTransient,
14
- } from '../types/stack.js';
14
+ } from '../types/stack.ts';
15
15
 
16
16
  export interface IModelOptionsStack extends IDecoratorModelOptions, ModelStackOptionsBase {}
17
17
 
@@ -1 +1 @@
1
- export * from './stack.js';
1
+ export * from './stack.ts';