@vc-shell/vc-app-skill 2.0.0-alpha.34 → 2.0.0-pr221.637b802
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/CHANGELOG.md +89 -136
- package/hooks/vc-app-check-update.js +14 -7
- package/package.json +1 -1
- package/runtime/VERSION +1 -1
- package/runtime/knowledge/docs/_BUILD_HASH.md +1 -1
- package/runtime/knowledge/migration-prompts/blade-form-migration.md +10 -7
- package/runtime/knowledge/migration-prompts/manual-migration-audit.md +40 -2
- package/runtime/knowledge/migration-prompts/notifications-migration.md +75 -27
- package/runtime/knowledge/migration-prompts/use-blade-migration.md +153 -0
- package/runtime/vc-app.md +13 -13
- package/runtime/knowledge/docs/core/composables/usePlatformLocaleSync/usePlatformLocaleSync.docs.md +0 -28
package/CHANGELOG.md
CHANGED
|
@@ -1,162 +1,115 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Changelog
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
### Bug Fixes
|
|
5
|
-
|
|
6
|
-
* **datatable:** normalise date-range filter values to YYYY-MM-DD ([d89864a](https://github.com/VirtoCommerce/vc-shell/commit/d89864aa635e7479137fb0ad501197adf335f99e))
|
|
7
|
-
* **migrate:** datatable prompt forbids 'removed filters for green build' shortcut ([af5ae8e](https://github.com/VirtoCommerce/vc-shell/commit/af5ae8e4259b435729e6cea9e4c61d74b41d3952))
|
|
8
|
-
* **migrate:** use-data-table-pagination prompt — per-file scope skip ([8949f01](https://github.com/VirtoCommerce/vc-shell/commit/8949f01da97b69c15fc6e3a2fca951608731979c))
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
### chore
|
|
12
|
-
|
|
13
|
-
* **scripts:** normalize yarn scripts per industry standards ([1cdd0cb](https://github.com/VirtoCommerce/vc-shell/commit/1cdd0cb517d2436ef2a509c6b6c358f6a48630d1))
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
### Features
|
|
17
|
-
|
|
18
|
-
* **migrate:** add use-data-table-pagination-audit + AI migration prompt ([0c2e7b6](https://github.com/VirtoCommerce/vc-shell/commit/0c2e7b6efba387d9fafe04e5bdcd21ea20500259))
|
|
19
|
-
* **migrate:** expand v2 migration tooling — icon/asset/audit prompts and blade-event cleanup ([f4788d4](https://github.com/VirtoCommerce/vc-shell/commit/f4788d4d9c588157ca5c11facfe558a69c254c2e)), closes [#41](https://github.com/VirtoCommerce/vc-shell/issues/41)
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
### BREAKING CHANGES
|
|
23
|
-
|
|
24
|
-
* **scripts:** for external consumers: old script names
|
|
25
|
-
(storybook-serve, build-framework, check-locales etc) are removed.
|
|
26
|
-
Legacy aliases are deliberately not provided — they would perpetuate
|
|
27
|
-
the non-standard naming this commit eliminates.
|
|
28
|
-
# [2.0.0-alpha.33](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.32...v2.0.0-alpha.33) (2026-04-14)
|
|
29
|
-
|
|
30
|
-
### Bug Fixes
|
|
31
|
-
|
|
32
|
-
- **vc-app-skill:** add VC_SHELL_MIGRATE_CLI env override for local testing ([010d2f2](https://github.com/VirtoCommerce/vc-shell/commit/010d2f2ecb29d31d9134406bcd18e46e5883208b))
|
|
33
|
-
- **vc-app-skill:** resolve migrate CLI from project node_modules before npx fallback ([82a8156](https://github.com/VirtoCommerce/vc-shell/commit/82a81563f7fdb94a94a7b8a80796ecffc671a39c))
|
|
34
|
-
- **vc-app-skill:** resolve migrate CLI locally in dev mode, fallback to npx ([89888a0](https://github.com/VirtoCommerce/vc-shell/commit/89888a06cc0b4a1519f46f070ee06ebb0d82fd09))
|
|
35
|
-
|
|
36
|
-
### Features
|
|
37
|
-
|
|
38
|
-
- **vc-app-skill:** add /vc-app migrate command with full migration pipeline ([35a8b11](https://github.com/VirtoCommerce/vc-shell/commit/35a8b119457b14f6f4626caf133476222afd6663))
|
|
39
|
-
- **vc-app-skill:** add migration prompt knowledge base (nswag, widgets, form, blade-props, notifications) ([a0b0eb2](https://github.com/VirtoCommerce/vc-shell/commit/a0b0eb2a96521916a72bdbf787961c1c96f96f6d))
|
|
40
|
-
- **vc-app-skill:** add migration-agent subagent prompt ([29ac155](https://github.com/VirtoCommerce/vc-shell/commit/29ac1550c8e3c9b71d5dbc2ade7ea86b4d40213f))
|
|
41
|
-
|
|
42
|
-
# [2.0.0-alpha.32](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.31...v2.0.0-alpha.32) (2026-04-02)
|
|
43
|
-
|
|
44
|
-
**Note:** Version bump only for package @vc-shell/vc-app-skill
|
|
45
|
-
|
|
46
|
-
# [2.0.0-alpha.31](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.30...v2.0.0-alpha.31) (2026-04-01)
|
|
47
|
-
|
|
48
|
-
**Note:** Version bump only for package @vc-shell/vc-app-skill
|
|
49
|
-
|
|
50
|
-
# [2.0.0-alpha.30](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.29...v2.0.0-alpha.30) (2026-03-30)
|
|
3
|
+
# [2.0.0](https://github.com/VirtoCommerce/vc-shell/compare/v1.2.3...v2.0.0) (2026-04-22)
|
|
51
4
|
|
|
52
5
|
### Features
|
|
53
6
|
|
|
54
7
|
- **docs:** add documentation for usePopup and useResponsive composables ([342a50a](https://github.com/VirtoCommerce/vc-shell/commit/342a50ada1545637782e01f5452a60839aa90fd2))
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
**Note:** Version bump only for package @vc-shell/vc-app-skill
|
|
59
|
-
|
|
60
|
-
# [2.0.0-alpha.28](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.27...v2.0.0-alpha.28) (2026-03-26)
|
|
61
|
-
|
|
62
|
-
**Note:** Version bump only for package @vc-shell/vc-app-skill
|
|
63
|
-
|
|
64
|
-
# [2.0.0-alpha.27](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.26...v2.0.0-alpha.27) (2026-03-25)
|
|
65
|
-
|
|
66
|
-
**Note:** Version bump only for package @vc-shell/vc-app-skill
|
|
67
|
-
|
|
68
|
-
# [2.0.0-alpha.26](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.25...v2.0.0-alpha.26) (2026-03-25)
|
|
69
|
-
|
|
70
|
-
**Note:** Version bump only for package @vc-shell/vc-app-skill
|
|
71
|
-
|
|
72
|
-
# [2.0.0-alpha.25](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.24...v2.0.0-alpha.25) (2026-03-25)
|
|
73
|
-
|
|
74
|
-
**Note:** Version bump only for package @vc-shell/vc-app-skill
|
|
75
|
-
|
|
76
|
-
# [2.0.0-alpha.24](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.23...v2.0.0-alpha.24) (2026-03-25)
|
|
77
|
-
|
|
78
|
-
### Features
|
|
79
|
-
|
|
80
|
-
- **vc-app-skill:** add knowledge-stats script for knowledge base audit ([7a568fc](https://github.com/VirtoCommerce/vc-shell/commit/7a568fc57335d51349a644721c904586efd49273))
|
|
81
|
-
- **vc-app-skill:** enrich knowledge base with When to Use sections, patterns, and sync-docs script ([c82ed63](https://github.com/VirtoCommerce/vc-shell/commit/c82ed639d748bdc8fd2d9c39435ee37baedd0563))
|
|
82
|
-
- **vc-app:** add sidebar search bar for menu filtering ([72f17fc](https://github.com/VirtoCommerce/vc-shell/commit/72f17fc5b0e77e4e87457c5a29262345da50317d)), closes [#menu](https://github.com/VirtoCommerce/vc-shell/issues/menu) [#menu](https://github.com/VirtoCommerce/vc-shell/issues/menu)
|
|
83
|
-
|
|
84
|
-
# [2.0.0-alpha.23](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.22...v2.0.0-alpha.23) (2026-03-23)
|
|
85
|
-
|
|
86
|
-
### Bug Fixes
|
|
87
|
-
|
|
88
|
-
- **vc-app-skill:** add menuItem to standalone details blades (isWorkspace entry point) ([6be54ad](https://github.com/VirtoCommerce/vc-shell/commit/6be54ad38613ea0de865ab1348236417da8a572d))
|
|
89
|
-
- **vc-app-skill:** auto-run yarn install after project scaffold ([cb9ada3](https://github.com/VirtoCommerce/vc-shell/commit/cb9ada34579f89121de5648eee65b346bcd4d924))
|
|
90
|
-
|
|
91
|
-
### Features
|
|
92
|
-
|
|
93
|
-
- **vc-app-skill:** add platform URL prompt and update design plan structure ([7855830](https://github.com/VirtoCommerce/vc-shell/commit/78558303247107ff55d5b0aeb3f5fdf50cad16f8))
|
|
94
|
-
|
|
95
|
-
# [2.0.0-alpha.22](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.21...v2.0.0-alpha.22) (2026-03-23)
|
|
96
|
-
|
|
97
|
-
### Bug Fixes
|
|
98
|
-
|
|
99
|
-
- **vc-app-skill:** clarify app.use ordering — after framework, before router ([97439e4](https://github.com/VirtoCommerce/vc-shell/commit/97439e4cfedcae81a6fc26721b91d79187e95f1a))
|
|
100
|
-
- **vc-app-skill:** register generated modules in main.ts (import + app.use) ([e88d75e](https://github.com/VirtoCommerce/vc-shell/commit/e88d75e86ed0d4f69d3261d3d04e3b68bfb3baa5))
|
|
101
|
-
|
|
102
|
-
# [2.0.0-alpha.21](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.20...v2.0.0-alpha.21) (2026-03-23)
|
|
103
|
-
|
|
104
|
-
### Bug Fixes
|
|
105
|
-
|
|
106
|
-
- **vc-app-skill:** use [@alpha](https://github.com/alpha) dist-tag for create-vc-app commands ([09b4a27](https://github.com/VirtoCommerce/vc-shell/commit/09b4a273116d9b04c00ff1c6ad19af2d869bd394))
|
|
107
|
-
|
|
108
|
-
# [2.0.0-alpha.20](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.18...v2.0.0-alpha.20) (2026-03-23)
|
|
109
|
-
|
|
110
|
-
### Bug Fixes
|
|
111
|
-
|
|
112
|
-
- **vc-app-skill:** use [@alpha](https://github.com/alpha) dist-tag for update command and version check hook ([cceaab9](https://github.com/VirtoCommerce/vc-shell/commit/cceaab926a3a51160d8994891bc88445bfb9a9aa))
|
|
113
|
-
|
|
114
|
-
# [2.0.0-alpha.19](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.18...v2.0.0-alpha.19) (2026-03-23)
|
|
115
|
-
|
|
116
|
-
**Note:** Version bump only for package @vc-shell/vc-app-skill
|
|
117
|
-
|
|
118
|
-
# [2.0.0-alpha.18](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.17...v2.0.0-alpha.18) (2026-03-23)
|
|
119
|
-
|
|
120
|
-
**Note:** Version bump only for package @vc-shell/vc-app-skill
|
|
121
|
-
|
|
122
|
-
# [2.0.0-alpha.17](https://github.com/VirtoCommerce/vc-shell/compare/v2.0.0-alpha.16...v2.0.0-alpha.17) (2026-03-23)
|
|
123
|
-
|
|
124
|
-
### Bug Fixes
|
|
125
|
-
|
|
126
|
-
- **vc-app-skill:** correct mock template in details-blade-generator ([04b7d43](https://github.com/VirtoCommerce/vc-shell/commit/04b7d43dc12cb66ad786f91017e48c4c30e889e9))
|
|
127
|
-
- **vc-app-skill:** validate runtime arg and fix command listing ([f7169af](https://github.com/VirtoCommerce/vc-shell/commit/f7169afa56092be2e223a61c0edd5b73cd653d77))
|
|
128
|
-
|
|
129
|
-
### Features
|
|
130
|
-
|
|
8
|
+
- **migrate:** add use-data-table-pagination-audit + AI migration prompt ([0c2e7b6](https://github.com/VirtoCommerce/vc-shell/commit/0c2e7b6efba387d9fafe04e5bdcd21ea20500259))
|
|
9
|
+
- **migrate:** expand v2 migration tooling — icon/asset/audit prompts and blade-event cleanup ([f4788d4](https://github.com/VirtoCommerce/vc-shell/commit/f4788d4d9c588157ca5c11facfe558a69c254c2e)), closes [#41](https://github.com/VirtoCommerce/vc-shell/issues/41)
|
|
131
10
|
- **vc-app-skill:** add /vc-app design command documentation ([3cc59b2](https://github.com/VirtoCommerce/vc-shell/commit/3cc59b29831da7f2f78900c7f61354165583813e))
|
|
132
11
|
- **vc-app-skill:** add /vc-app design phases 1-6 (prompt → plan → execute → summary) ([b0bb44f](https://github.com/VirtoCommerce/vc-shell/commit/b0bb44f47e28fe9df147c5941a15e76b5ae3d2f8))
|
|
133
12
|
- **vc-app-skill:** add /vc-app design to routing table and help ([8b2f53e](https://github.com/VirtoCommerce/vc-shell/commit/8b2f53e7d8643f8ab87f3fab82dc4dd8c8bd44da))
|
|
13
|
+
- **vc-app-skill:** add /vc-app migrate command with full migration pipeline ([35a8b11](https://github.com/VirtoCommerce/vc-shell/commit/35a8b119457b14f6f4626caf133476222afd6663))
|
|
134
14
|
- **vc-app-skill:** add /vc-app promote command with 5-phase flow ([a3b6da6](https://github.com/VirtoCommerce/vc-shell/commit/a3b6da658322a1e39ffb9808d0e80bf732f52ae8))
|
|
135
15
|
- **vc-app-skill:** add blade-enhancer agent for surgical module modifications ([bc83681](https://github.com/VirtoCommerce/vc-shell/commit/bc83681c99accd3a25b48a5da1916810a6393aa0))
|
|
136
16
|
- **vc-app-skill:** add design-specific error handling scenarios ([5381685](https://github.com/VirtoCommerce/vc-shell/commit/5381685b75a7eac82add64314cab8269518ba53f))
|
|
137
17
|
- **vc-app-skill:** add enhance flow to /vc-app generate for existing modules ([2936bd6](https://github.com/VirtoCommerce/vc-shell/commit/2936bd60946d4c63207682908a8edbb8f137e448))
|
|
138
18
|
- **vc-app-skill:** add entry-point and update commands ([ab9075f](https://github.com/VirtoCommerce/vc-shell/commit/ab9075f49b1bb2d93f56613758d038ef1ca09d09))
|
|
139
19
|
- **vc-app-skill:** add existingModule context and append mode to generators ([3978c66](https://github.com/VirtoCommerce/vc-shell/commit/3978c66aff3b2526f51227c560371be425018ad2))
|
|
20
|
+
- **vc-app-skill:** add knowledge-stats script for knowledge base audit ([7a568fc](https://github.com/VirtoCommerce/vc-shell/commit/7a568fc57335d51349a644721c904586efd49273))
|
|
21
|
+
- **vc-app-skill:** add migration prompt knowledge base (nswag, widgets, form, blade-props, notifications) ([a0b0eb2](https://github.com/VirtoCommerce/vc-shell/commit/a0b0eb2a96521916a72bdbf787961c1c96f96f6d))
|
|
22
|
+
- **vc-app-skill:** add migration-agent subagent prompt ([29ac155](https://github.com/VirtoCommerce/vc-shell/commit/29ac1550c8e3c9b71d5dbc2ade7ea86b4d40213f))
|
|
140
23
|
- **vc-app-skill:** add module-analyzer agent for existing module introspection ([9eaff6b](https://github.com/VirtoCommerce/vc-shell/commit/9eaff6b3ca829ce41298c739f26ba6bdf93a2adb))
|
|
141
24
|
- **vc-app-skill:** add multi-runtime installer ([00e656e](https://github.com/VirtoCommerce/vc-shell/commit/00e656e65bef05ebe8e7cb29cbf2efe64b991f5a))
|
|
25
|
+
- **vc-app-skill:** add platform URL prompt and update design plan structure ([7855830](https://github.com/VirtoCommerce/vc-shell/commit/78558303247107ff55d5b0aeb3f5fdf50cad16f8))
|
|
142
26
|
- **vc-app-skill:** add promote-agent subagent for mock-to-API transformation ([27484e3](https://github.com/VirtoCommerce/vc-shell/commit/27484e39c72e7b738e8db5846063e6388f7e06db))
|
|
143
27
|
- **vc-app-skill:** add SessionStart update check hook ([72c5bcf](https://github.com/VirtoCommerce/vc-shell/commit/72c5bcf33d4f8ae826e7ed76d9228c42cfa846d4))
|
|
144
28
|
- **vc-app-skill:** add uninstaller ([6a0507c](https://github.com/VirtoCommerce/vc-shell/commit/6a0507c9a5c755c0b4487c5625898c5c50c38986))
|
|
145
29
|
- **vc-app-skill:** create package scaffold with README ([a2bbced](https://github.com/VirtoCommerce/vc-shell/commit/a2bbced57b2fbb62bb56ca38c679b0c42e7aee88))
|
|
30
|
+
- **vc-app-skill:** enrich knowledge base with When to Use sections, patterns, and sync-docs script ([c82ed63](https://github.com/VirtoCommerce/vc-shell/commit/c82ed639d748bdc8fd2d9c39435ee37baedd0563))
|
|
146
31
|
- **vc-app-skill:** migrate skill content from create-vc-app to standalone package ([1ac8945](https://github.com/VirtoCommerce/vc-shell/commit/1ac894510ca32cad22efb226117127f76085f85a))
|
|
147
32
|
- **vc-app-skill:** update scaffold to skip --module-name for standalone ([c82066e](https://github.com/VirtoCommerce/vc-shell/commit/c82066e3c910676ada13f0cd8f1d7db72d81982a))
|
|
33
|
+
- **vc-app:** add sidebar search bar for menu filtering ([72f17fc](https://github.com/VirtoCommerce/vc-shell/commit/72f17fc5b0e77e4e87457c5a29262345da50317d))
|
|
148
34
|
|
|
149
|
-
|
|
35
|
+
### Bug Fixes
|
|
150
36
|
|
|
151
|
-
|
|
37
|
+
- **datatable:** normalise date-range filter values to YYYY-MM-DD ([d89864a](https://github.com/VirtoCommerce/vc-shell/commit/d89864aa635e7479137fb0ad501197adf335f99e))
|
|
38
|
+
- **migrate:** datatable prompt forbids 'removed filters for green build' shortcut ([af5ae8e](https://github.com/VirtoCommerce/vc-shell/commit/af5ae8e4259b435729e6cea9e4c61d74b41d3952))
|
|
39
|
+
- **migrate:** use-data-table-pagination prompt — per-file scope skip ([8949f01](https://github.com/VirtoCommerce/vc-shell/commit/8949f01da97b69c15fc6e3a2fca951608731979c))
|
|
40
|
+
- **release:** update changelog and release-it configuration ([767c312](https://github.com/VirtoCommerce/vc-shell/commit/767c3123773a02a4badc3bcf89661e535d5f26c8))
|
|
41
|
+
- **vc-app-skill:** add menuItem to standalone details blades (isWorkspace entry point) ([6be54ad](https://github.com/VirtoCommerce/vc-shell/commit/6be54ad38613ea0de865ab1348236417da8a572d))
|
|
42
|
+
- **vc-app-skill:** add VC_SHELL_MIGRATE_CLI env override for local testing ([010d2f2](https://github.com/VirtoCommerce/vc-shell/commit/010d2f2ecb29d31d9134406bcd18e46e5883208b))
|
|
43
|
+
- **vc-app-skill:** auto-run yarn install after project scaffold ([cb9ada3](https://github.com/VirtoCommerce/vc-shell/commit/cb9ada34579f89121de5648eee65b346bcd4d924))
|
|
44
|
+
- **vc-app-skill:** clarify app.use ordering — after framework, before router ([97439e4](https://github.com/VirtoCommerce/vc-shell/commit/97439e4cfedcae81a6fc26721b91d79187e95f1a))
|
|
45
|
+
- **vc-app-skill:** correct mock template in details-blade-generator ([04b7d43](https://github.com/VirtoCommerce/vc-shell/commit/04b7d43dc12cb66ad786f91017e48c4c30e889e9))
|
|
46
|
+
- **vc-app-skill:** register generated modules in main.ts (import + app.use) ([e88d75e](https://github.com/VirtoCommerce/vc-shell/commit/e88d75e86ed0d4f69d3261d3d04e3b68bfb3baa5))
|
|
47
|
+
- **vc-app-skill:** resolve migrate CLI from project node_modules before npx fallback ([82a8156](https://github.com/VirtoCommerce/vc-shell/commit/82a81563f7fdb94a94a7b8a80796ecffc671a39c))
|
|
48
|
+
- **vc-app-skill:** resolve migrate CLI locally in dev mode, fallback to npx ([89888a0](https://github.com/VirtoCommerce/vc-shell/commit/89888a06cc0b4a1519f46f070ee06ebb0d82fd09))
|
|
49
|
+
- **vc-app-skill:** use @alpha dist-tag for create-vc-app commands ([09b4a27](https://github.com/VirtoCommerce/vc-shell/commit/09b4a273116d9b04c00ff1c6ad19af2d869bd394))
|
|
50
|
+
- **vc-app-skill:** use @alpha dist-tag for update command and version check hook ([cceaab9](https://github.com/VirtoCommerce/vc-shell/commit/cceaab926a3a51160d8994891bc88445bfb9a9aa))
|
|
51
|
+
- **vc-app-skill:** validate runtime arg and fix command listing ([f7169af](https://github.com/VirtoCommerce/vc-shell/commit/f7169afa56092be2e223a61c0edd5b73cd653d77))
|
|
152
52
|
|
|
153
|
-
###
|
|
53
|
+
### Code Refactoring
|
|
54
|
+
|
|
55
|
+
- clean up code formatting and improve readability across multiple files ([9f710b5](https://github.com/VirtoCommerce/vc-shell/commit/9f710b5ceba270475709735c139e061c66c96b18))
|
|
56
|
+
- **core:** make user composables a true singleton ([72391b6](https://github.com/VirtoCommerce/vc-shell/commit/72391b610e0bd520b0814641eedfc5163058236a))
|
|
57
|
+
- rename App Switcher to App Hub ([1646b22](https://github.com/VirtoCommerce/vc-shell/commit/1646b2276791f2448e0e69e77ca25c96857a3975))
|
|
58
|
+
- rename vc-table to vc-data-table, extract usePopup to core composables ([15cc93d](https://github.com/VirtoCommerce/vc-shell/commit/15cc93dc871d6d23344aa8d0fff7074528fea001))
|
|
59
|
+
|
|
60
|
+
### Documentation
|
|
61
|
+
|
|
62
|
+
- add comprehensive documentation for useDataTablePagination composable ([a783cd9](https://github.com/VirtoCommerce/vc-shell/commit/a783cd9a7a5837267d4c11cc3279f2b70d0e6734))
|
|
63
|
+
- document peer-versions.json and --update-deps peer alignment ([4de1dfd](https://github.com/VirtoCommerce/vc-shell/commit/4de1dfd032194a6e2797055abfcd94f61f117cf6))
|
|
64
|
+
- update references from IBladeInstance to BladeDescriptor ([ef380d8](https://github.com/VirtoCommerce/vc-shell/commit/ef380d80df9247fdc70e42aed411a48239a294fa))
|
|
65
|
+
- **vc-app-skill:** document /vc-app migrate command and migration-agent ([5ded9f1](https://github.com/VirtoCommerce/vc-shell/commit/5ded9f1a98028a07327d06254e88ac8635c4fd66))
|
|
66
|
+
- **vc-app-skill:** update README and simplify create command ([1edd79d](https://github.com/VirtoCommerce/vc-shell/commit/1edd79d746b57cc77fc9c5dd9278c81f6c575bbe))
|
|
67
|
+
- **vc-app-skill:** update README to remove release section and ensure proper formatting ([0e24e48](https://github.com/VirtoCommerce/vc-shell/commit/0e24e481ec03583b41b29ce47f8dc623020a1079))
|
|
68
|
+
- **vc-app-skill:** use @alpha tag in install commands until stable release ([d82529c](https://github.com/VirtoCommerce/vc-shell/commit/d82529c32386770945b6aff35b1d0bf01a414b79))
|
|
69
|
+
|
|
70
|
+
### Styles
|
|
71
|
+
|
|
72
|
+
- **lint:** one-time cleanup of pre-existing violations and tech debt ([a7113c5](https://github.com/VirtoCommerce/vc-shell/commit/a7113c5d25b5b4dc9da20f6bc40c54b57fe46422))
|
|
73
|
+
|
|
74
|
+
### Chores
|
|
75
|
+
|
|
76
|
+
- auto-sync vc-app-skill VERSION and docs during release ([140897d](https://github.com/VirtoCommerce/vc-shell/commit/140897d2f31b98eef88f17309baa76fbdaae821f))
|
|
77
|
+
- **docs:** generalize private references in migration tooling and skill ([4719e51](https://github.com/VirtoCommerce/vc-shell/commit/4719e51586ff4dae9693c33d195072408111f3c0))
|
|
78
|
+
- **release-it:** add before:stage hook to stage runtime files before release ([a8f0b8c](https://github.com/VirtoCommerce/vc-shell/commit/a8f0b8cd7c4cb6c0cd9a789003d75f81ac2fb2d0))
|
|
79
|
+
- **scripts:** normalize yarn scripts per industry standards ([1cdd0cb](https://github.com/VirtoCommerce/vc-shell/commit/1cdd0cb517d2436ef2a509c6b6c358f6a48630d1))
|
|
80
|
+
- track vc-app-skill knowledge docs in repository ([9189f08](https://github.com/VirtoCommerce/vc-shell/commit/9189f0842a01e7c46d06c28243236ccdfb8bf04f))
|
|
81
|
+
- update package.json to include publishConfig for npm registry ([cf5f3ed](https://github.com/VirtoCommerce/vc-shell/commit/cf5f3edd1a048a9bb16e5ac11d4aa5f717a717c5))
|
|
82
|
+
- **vc-app-skill:** add to release pipeline and bump to 2.0.0-alpha.16 ([f703552](https://github.com/VirtoCommerce/vc-shell/commit/f7035529020bb330a5f50840c50ad0843828ebf1))
|
|
83
|
+
|
|
84
|
+
### Other Changes
|
|
85
|
+
|
|
86
|
+
- Merge remote-tracking branch 'origin/main' ([bb2c2da](https://github.com/VirtoCommerce/vc-shell/commit/bb2c2da88fd9ac8d58eb0a84451d80bfba3f2547))
|
|
87
|
+
|
|
88
|
+
### release
|
|
89
|
+
|
|
90
|
+
- v2.0.0-alpha.17 ([408e4af](https://github.com/VirtoCommerce/vc-shell/commit/408e4af487f37b8aff790398d5a992820c8f05a2))
|
|
91
|
+
- v2.0.0-alpha.18 ([2466e35](https://github.com/VirtoCommerce/vc-shell/commit/2466e359313c9d78893d2473474ec5ce46ad49ca))
|
|
92
|
+
- v2.0.0-alpha.19 ([9d5a075](https://github.com/VirtoCommerce/vc-shell/commit/9d5a075e0a722c6c7371706f582b59bbf570ef37))
|
|
93
|
+
- v2.0.0-alpha.20 ([98bd4a6](https://github.com/VirtoCommerce/vc-shell/commit/98bd4a62ffa933bbfdae16ef7e46777084f15190))
|
|
94
|
+
- v2.0.0-alpha.21 ([bbd0d70](https://github.com/VirtoCommerce/vc-shell/commit/bbd0d70464ff5c0dafbc67ed3bf8ea36f65b0a7a))
|
|
95
|
+
- v2.0.0-alpha.22 ([ec455eb](https://github.com/VirtoCommerce/vc-shell/commit/ec455eba6bb91ae5fdbea64817ce1650116b9d50))
|
|
96
|
+
- v2.0.0-alpha.23 ([65b2144](https://github.com/VirtoCommerce/vc-shell/commit/65b214434ef1630069aecd6f2eaf916531bf37ef))
|
|
97
|
+
- v2.0.0-alpha.24 ([05ff510](https://github.com/VirtoCommerce/vc-shell/commit/05ff5107b81e0280447872ea52771fc47cb3cd67))
|
|
98
|
+
- v2.0.0-alpha.25 ([19d09b9](https://github.com/VirtoCommerce/vc-shell/commit/19d09b998861836b288aba36a6d18d7b26cff0b7))
|
|
99
|
+
- v2.0.0-alpha.26 ([ee6818c](https://github.com/VirtoCommerce/vc-shell/commit/ee6818ceb60b24d26b7011f2584c8d23f6b4fd3e))
|
|
100
|
+
- v2.0.0-alpha.27 ([f43652d](https://github.com/VirtoCommerce/vc-shell/commit/f43652d1aae8af36d5d2f00312492ea9de57f2f1))
|
|
101
|
+
- v2.0.0-alpha.28 ([7954dfd](https://github.com/VirtoCommerce/vc-shell/commit/7954dfddf1126d00038b8f66a6fe3efc5c19cfe8))
|
|
102
|
+
- v2.0.0-alpha.29 ([ffa72cf](https://github.com/VirtoCommerce/vc-shell/commit/ffa72cf458eed77c78955c88d211a82ead152b0f))
|
|
103
|
+
- v2.0.0-alpha.30 ([2db7f17](https://github.com/VirtoCommerce/vc-shell/commit/2db7f17d74afe97e3c6dfef2de436a797f0c32f4))
|
|
104
|
+
- v2.0.0-alpha.31 ([8d92fba](https://github.com/VirtoCommerce/vc-shell/commit/8d92fbad5954c71164e7815193b3496e569a5703))
|
|
105
|
+
- v2.0.0-alpha.32 ([1ed5533](https://github.com/VirtoCommerce/vc-shell/commit/1ed5533a6a20081e655f2e628bf824de40472f5d))
|
|
106
|
+
- v2.0.0-alpha.33 ([49cad36](https://github.com/VirtoCommerce/vc-shell/commit/49cad36a454534136b52576e6a0d97dfe48ae895))
|
|
107
|
+
- v2.0.0-alpha.34 ([78bed5a](https://github.com/VirtoCommerce/vc-shell/commit/78bed5af3aeb7ace2eb9f58ddde3235fced47b37))
|
|
108
|
+
- v2.0.0-alpha.35 ([05d6f25](https://github.com/VirtoCommerce/vc-shell/commit/05d6f2562c939dd4a2e7e4e7a3d80948beccbef1))
|
|
109
|
+
|
|
110
|
+
### BREAKING CHANGES
|
|
154
111
|
|
|
155
|
-
- **
|
|
156
|
-
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
- **vc-app-skill:** enhance existing modules with surgical modifications — add columns, fields, toolbar actions, logic, blade links (`/vc-app generate` enhance flow)
|
|
160
|
-
- **vc-app-skill:** promote prototype modules from mock data to real API clients (`/vc-app promote`)
|
|
161
|
-
- **vc-app-skill:** 9 specialized subagents for code generation and transformation
|
|
162
|
-
- **vc-app-skill:** framework knowledge base with component docs, patterns, and examples
|
|
112
|
+
- **scripts:** for external consumers: old script names
|
|
113
|
+
(storybook-serve, build-framework, check-locales etc) are removed.
|
|
114
|
+
Legacy aliases are deliberately not provided — they would perpetuate
|
|
115
|
+
the non-standard naming this commit eliminates.
|
|
@@ -35,7 +35,11 @@ if (!fs.existsSync(cacheDir)) {
|
|
|
35
35
|
fs.mkdirSync(cacheDir, { recursive: true });
|
|
36
36
|
}
|
|
37
37
|
|
|
38
|
-
const child = spawn(
|
|
38
|
+
const child = spawn(
|
|
39
|
+
process.execPath,
|
|
40
|
+
[
|
|
41
|
+
"-e",
|
|
42
|
+
`
|
|
39
43
|
const fs = require("fs");
|
|
40
44
|
const { execSync } = require("child_process");
|
|
41
45
|
|
|
@@ -54,7 +58,7 @@ const child = spawn(process.execPath, ["-e", `
|
|
|
54
58
|
|
|
55
59
|
let latest = null;
|
|
56
60
|
try {
|
|
57
|
-
latest = execSync("npm view @vc-shell/vc-app-skill@
|
|
61
|
+
latest = execSync("npm view @vc-shell/vc-app-skill@latest version", { encoding: "utf8", timeout: 10000, windowsHide: true }).trim();
|
|
58
62
|
} catch (e) {}
|
|
59
63
|
|
|
60
64
|
const result = {
|
|
@@ -65,10 +69,13 @@ const child = spawn(process.execPath, ["-e", `
|
|
|
65
69
|
};
|
|
66
70
|
|
|
67
71
|
fs.writeFileSync(cacheFile, JSON.stringify(result));
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
72
|
+
`,
|
|
73
|
+
],
|
|
74
|
+
{
|
|
75
|
+
stdio: "ignore",
|
|
76
|
+
windowsHide: true,
|
|
77
|
+
detached: true,
|
|
78
|
+
},
|
|
79
|
+
);
|
|
73
80
|
|
|
74
81
|
child.unref();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vc-shell/vc-app-skill",
|
|
3
|
-
"version": "2.0.0-
|
|
3
|
+
"version": "2.0.0-pr221.637b802",
|
|
4
4
|
"description": "AI coding skill for scaffolding and generating VirtoCommerce Shell applications. Works with Claude Code, OpenCode, Gemini, Codex, Cursor.",
|
|
5
5
|
"bin": "./bin/install.cjs",
|
|
6
6
|
"files": [
|
package/runtime/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
2.0.0
|
|
1
|
+
2.0.0
|
|
@@ -1 +1 @@
|
|
|
1
|
-
Synced from framework at commit
|
|
1
|
+
Synced from framework at commit be4d05add on 2026-04-22T12:54:33.589Z
|
|
@@ -63,13 +63,14 @@ const { canSave, isModified, setBaseline, revert, setFieldError, errorBag } = us
|
|
|
63
63
|
closeConfirmMessage: () => t("MY_MODULE.ALERTS.CLOSE_CONFIRMATION"),
|
|
64
64
|
});
|
|
65
65
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
);
|
|
66
|
+
// Call setBaseline() AFTER data is loaded in onMounted.
|
|
67
|
+
// Do NOT use watch(item, ..., { once: true }) — it only detects ref
|
|
68
|
+
// replacement (item.value = newData), not in-place mutations
|
|
69
|
+
// (Object.assign(item.value, newData)).
|
|
70
|
+
onMounted(async () => {
|
|
71
|
+
await load(param.value);
|
|
72
|
+
setBaseline();
|
|
73
|
+
});
|
|
73
74
|
|
|
74
75
|
async function handleSave() {
|
|
75
76
|
await save(item.value);
|
|
@@ -77,6 +78,8 @@ async function handleSave() {
|
|
|
77
78
|
}
|
|
78
79
|
```
|
|
79
80
|
|
|
81
|
+
**IMPORTANT — `setBaseline()` placement:** Always call `setBaseline()` AFTER the async load completes, inside `onMounted` or after the load function returns. A `watch(data, ..., { once: true })` watcher fails when the composable mutates data in-place via `Object.assign(data.value, loadedData)` instead of replacing the ref — the watcher never fires because the `.value` reference doesn't change.
|
|
82
|
+
|
|
80
83
|
## RULE 2: Remove onBeforeClose Entirely
|
|
81
84
|
|
|
82
85
|
`useBladeForm` handles the unsaved-changes guard automatically via `autoBeforeClose` (defaults to `true`).
|
|
@@ -90,7 +90,45 @@ await closeSelf();
|
|
|
90
90
|
|
|
91
91
|
If `closeBlade(index)` was used to close by index, refactor to close current blade only (or use explicit navigation logic) — do not keep index-based close calls.
|
|
92
92
|
|
|
93
|
-
## RULE 5:
|
|
93
|
+
## RULE 5: Remove `resolveBladeByName` — pass name directly to `openBlade`
|
|
94
|
+
|
|
95
|
+
**BEFORE:**
|
|
96
|
+
|
|
97
|
+
```typescript
|
|
98
|
+
const { openBlade, resolveBladeByName } = useBlade();
|
|
99
|
+
openBlade({ blade: resolveBladeByName("OrderDetails")!, param: orderId });
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
**AFTER:**
|
|
103
|
+
|
|
104
|
+
```typescript
|
|
105
|
+
const { openBlade } = useBlade();
|
|
106
|
+
openBlade({ name: "OrderDetails", param: orderId });
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
Remove `resolveBladeByName` from the destructuring. The `blade` property in the openBlade argument is replaced by `name` (string).
|
|
110
|
+
|
|
111
|
+
## RULE 6: Replace `onParentCall` with `callParent`
|
|
112
|
+
|
|
113
|
+
**BEFORE:**
|
|
114
|
+
|
|
115
|
+
```typescript
|
|
116
|
+
const { onParentCall } = useBladeNavigation();
|
|
117
|
+
onParentCall({ method: "reload" });
|
|
118
|
+
onParentCall({ method: "updateItem", args: newItem });
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
**AFTER:**
|
|
122
|
+
|
|
123
|
+
```typescript
|
|
124
|
+
const { callParent } = useBlade();
|
|
125
|
+
await callParent("reload");
|
|
126
|
+
await callParent("updateItem", newItem);
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
Note: `callParent` is async and returns a Promise. Add `await` if the result matters.
|
|
130
|
+
|
|
131
|
+
## RULE 7: Consolidate multiple `useBlade()` calls per file
|
|
94
132
|
|
|
95
133
|
Use one `useBlade()` destructuring per component/composable unless there is a strong technical reason.
|
|
96
134
|
|
|
@@ -111,7 +149,7 @@ const { openBlade, closeSelf, callParent, param } = useBlade();
|
|
|
111
149
|
|
|
112
150
|
After migration:
|
|
113
151
|
|
|
114
|
-
1. Search and remove stale APIs: `useExternalWidgets`, `import moment`, `useFunctions(`, `closeBlade(`.
|
|
152
|
+
1. Search and remove stale APIs: `useExternalWidgets`, `import moment`, `useFunctions(`, `closeBlade(`, `resolveBladeByName`, `onParentCall`.
|
|
115
153
|
2. Search for duplicate `useBlade()` calls in the same file and consolidate.
|
|
116
154
|
3. Run `npx vue-tsc --noEmit`.
|
|
117
155
|
4. Run `yarn build`.
|
|
@@ -152,17 +152,28 @@ Toast options:
|
|
|
152
152
|
|
|
153
153
|
## RULE 4: Replace useNotifications in Blades
|
|
154
154
|
|
|
155
|
-
Replace `useNotifications()` with `useBladeNotifications()`. Remove `setNotificationHandler`, `moduleNotifications`
|
|
155
|
+
Replace `useNotifications()` with `useBladeNotifications()`. Remove `setNotificationHandler`, the entire `watch(moduleNotifications, ...)` block, manual toast management, and `notifyType` from `defineOptions`.
|
|
156
|
+
|
|
157
|
+
### What to DELETE (toast management is now automatic via module config):
|
|
158
|
+
|
|
159
|
+
- The entire `watch(moduleNotifications/messages, ..., { deep: true })` block
|
|
160
|
+
- All `notification()` / `notification.update()` calls related to notification messages
|
|
161
|
+
- The `notificationId` ref used for toast tracking
|
|
162
|
+
- `setNotificationHandler(...)` calls
|
|
163
|
+
- `markAsRead()` calls inside toast `onClose` handlers
|
|
164
|
+
- `notifyType` from `defineOptions`/`defineBlade`
|
|
165
|
+
|
|
166
|
+
### What to EXTRACT into `onMessage`:
|
|
167
|
+
|
|
168
|
+
- Only **data-reload logic** from the watch callback (e.g., `getTasks()`, `refreshData()`, `reload()`)
|
|
169
|
+
- Add `filter` if the callback had blade-specific conditions (e.g., `message.profileId === param.value`)
|
|
170
|
+
|
|
171
|
+
### Simple case: `setNotificationHandler`
|
|
156
172
|
|
|
157
173
|
**BEFORE:**
|
|
158
174
|
|
|
159
175
|
```typescript
|
|
160
|
-
|
|
161
|
-
name: "MyBlade",
|
|
162
|
-
notifyType: "MyDomainEvent",
|
|
163
|
-
});
|
|
164
|
-
|
|
165
|
-
const { markAsRead, setNotificationHandler, moduleNotifications } = useNotifications("MyDomainEvent");
|
|
176
|
+
const { markAsRead, setNotificationHandler } = useNotifications("MyDomainEvent");
|
|
166
177
|
|
|
167
178
|
setNotificationHandler((message) => {
|
|
168
179
|
if (message.title) {
|
|
@@ -173,12 +184,54 @@ setNotificationHandler((message) => {
|
|
|
173
184
|
});
|
|
174
185
|
}
|
|
175
186
|
});
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
**AFTER:**
|
|
190
|
+
|
|
191
|
+
```typescript
|
|
192
|
+
useBladeNotifications({
|
|
193
|
+
types: ["MyDomainEvent"],
|
|
194
|
+
});
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
### Complex case: `watch` with toast management + data reload
|
|
198
|
+
|
|
199
|
+
**BEFORE:**
|
|
200
|
+
|
|
201
|
+
```typescript
|
|
202
|
+
const { moduleNotifications, markAsRead } = useNotifications("ImportPushNotification");
|
|
203
|
+
const notificationId = ref();
|
|
176
204
|
|
|
177
|
-
// or watch pattern:
|
|
178
205
|
watch(
|
|
179
206
|
moduleNotifications,
|
|
180
207
|
(newVal) => {
|
|
181
|
-
|
|
208
|
+
(newVal as ImportPushNotification[]).forEach((message) => {
|
|
209
|
+
const messageContent = message.profileName ? `${message.profileName}: ${message.title}` : message.title;
|
|
210
|
+
|
|
211
|
+
// DATA RELOAD — extract this into onMessage
|
|
212
|
+
if (!importStarted.value && message.profileId === param.value) {
|
|
213
|
+
getTasks({ profileId: message.profileId, importJobId: message.jobId });
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
// TOAST MANAGEMENT — delete all of this (handled by module config)
|
|
217
|
+
if (!message.finished) {
|
|
218
|
+
if (!notificationId.value && messageContent) {
|
|
219
|
+
notificationId.value = notification(messageContent, { timeout: false });
|
|
220
|
+
} else {
|
|
221
|
+
notification.update(notificationId.value, { content: messageContent });
|
|
222
|
+
}
|
|
223
|
+
} else {
|
|
224
|
+
notification.update(notificationId.value, {
|
|
225
|
+
timeout: 5000,
|
|
226
|
+
content: messageContent,
|
|
227
|
+
type: message.title === "Import failed" ? "error" : "success",
|
|
228
|
+
onClose() {
|
|
229
|
+
markAsRead(message);
|
|
230
|
+
notificationId.value = undefined;
|
|
231
|
+
},
|
|
232
|
+
});
|
|
233
|
+
}
|
|
234
|
+
});
|
|
182
235
|
},
|
|
183
236
|
{ deep: true },
|
|
184
237
|
);
|
|
@@ -187,28 +240,23 @@ watch(
|
|
|
187
240
|
**AFTER:**
|
|
188
241
|
|
|
189
242
|
```typescript
|
|
190
|
-
defineOptions({
|
|
191
|
-
name: "MyBlade",
|
|
192
|
-
// notifyType removed
|
|
193
|
-
});
|
|
194
|
-
|
|
195
|
-
const { messages } = useBladeNotifications({
|
|
196
|
-
types: ["MyDomainEvent"],
|
|
197
|
-
onMessage: () => reloadData(),
|
|
198
|
-
});
|
|
199
|
-
```
|
|
200
|
-
|
|
201
|
-
For progress notifications:
|
|
202
|
-
|
|
203
|
-
```typescript
|
|
204
|
-
// Module config: notifications: { MyProgressEvent: { toast: { mode: "progress" } } }
|
|
205
243
|
useBladeNotifications({
|
|
206
|
-
types: ["
|
|
207
|
-
filter: (msg) => msg.
|
|
208
|
-
onMessage: (msg) =>
|
|
244
|
+
types: ["ImportPushNotification"],
|
|
245
|
+
filter: (msg) => (msg as ImportPushNotification).profileId === param.value,
|
|
246
|
+
onMessage: (msg) => {
|
|
247
|
+
if (!importStarted.value) {
|
|
248
|
+
getTasks({
|
|
249
|
+
profileId: (msg as ImportPushNotification).profileId,
|
|
250
|
+
importJobId: (msg as ImportPushNotification).jobId,
|
|
251
|
+
});
|
|
252
|
+
}
|
|
253
|
+
},
|
|
209
254
|
});
|
|
255
|
+
// DELETE: notificationId ref, watch block, notification()/notification.update() calls
|
|
210
256
|
```
|
|
211
257
|
|
|
258
|
+
Toast appearance is configured in `defineAppModule({ notifications: { ImportPushNotification: { toast: { mode: "progress" } } } })`. The `markAsRead` is handled automatically.
|
|
259
|
+
|
|
212
260
|
## Verification
|
|
213
261
|
|
|
214
262
|
After migration:
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: use-blade-migration
|
|
3
|
+
description: AI transformation rules for useBladeNavigation → useBlade, resolveBladeByName removal, onParentCall → callParent.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Blade Navigation Migration: useBladeNavigation → useBlade
|
|
7
|
+
|
|
8
|
+
Replace `useBladeNavigation()`, `useBladeContext()`, `resolveBladeByName()`, and `onParentCall()` with the unified `useBlade()` composable.
|
|
9
|
+
|
|
10
|
+
## RULE 1: Replace useBladeNavigation / useBladeContext with useBlade
|
|
11
|
+
|
|
12
|
+
Rename the import and call site. Merge destructured properties from both into a single `useBlade()` call.
|
|
13
|
+
|
|
14
|
+
**BEFORE:**
|
|
15
|
+
|
|
16
|
+
```typescript
|
|
17
|
+
import { useBladeNavigation } from "@vc-shell/framework";
|
|
18
|
+
const { openBlade, resolveBladeByName, onBeforeClose } = useBladeNavigation();
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
**AFTER:**
|
|
22
|
+
|
|
23
|
+
```typescript
|
|
24
|
+
import { useBlade } from "@vc-shell/framework";
|
|
25
|
+
const { openBlade, onBeforeClose } = useBlade();
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
If both `useBladeNavigation()` and `useBladeContext()` are used, merge into one `useBlade()`:
|
|
29
|
+
|
|
30
|
+
**BEFORE:**
|
|
31
|
+
|
|
32
|
+
```typescript
|
|
33
|
+
const blade = useBlade();
|
|
34
|
+
const { openBlade, onBeforeClose } = useBladeNavigation();
|
|
35
|
+
registerWidget(myWidget, blade?.value.id ?? "");
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
**AFTER:**
|
|
39
|
+
|
|
40
|
+
```typescript
|
|
41
|
+
const { id: bladeId, openBlade, onBeforeClose } = useBlade();
|
|
42
|
+
registerWidget(myWidget, bladeId.value);
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
## RULE 2: Remove resolveBladeByName
|
|
46
|
+
|
|
47
|
+
`resolveBladeByName` is no longer needed — pass the blade name directly to `openBlade`.
|
|
48
|
+
|
|
49
|
+
**BEFORE:**
|
|
50
|
+
|
|
51
|
+
```typescript
|
|
52
|
+
openBlade({ blade: resolveBladeByName("OrderDetails")!, param: orderId });
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
**AFTER:**
|
|
56
|
+
|
|
57
|
+
```typescript
|
|
58
|
+
openBlade({ name: "OrderDetails", param: orderId });
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
Also handle the pattern with options:
|
|
62
|
+
|
|
63
|
+
**BEFORE:**
|
|
64
|
+
|
|
65
|
+
```typescript
|
|
66
|
+
openBlade({
|
|
67
|
+
blade: resolveBladeByName("ImportProcess")!,
|
|
68
|
+
param: profileId,
|
|
69
|
+
options: { title: profile.name, importJobId: jobId },
|
|
70
|
+
});
|
|
71
|
+
```
|
|
72
|
+
|
|
73
|
+
**AFTER:**
|
|
74
|
+
|
|
75
|
+
```typescript
|
|
76
|
+
openBlade({
|
|
77
|
+
name: "ImportProcess",
|
|
78
|
+
param: profileId,
|
|
79
|
+
options: { title: profile.name, importJobId: jobId },
|
|
80
|
+
});
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
Remove the `resolveBladeByName` destructure from `useBlade()` since it's no longer used.
|
|
84
|
+
|
|
85
|
+
## RULE 3: Replace onParentCall with callParent
|
|
86
|
+
|
|
87
|
+
**BEFORE:**
|
|
88
|
+
|
|
89
|
+
```typescript
|
|
90
|
+
const { onParentCall } = useBladeNavigation();
|
|
91
|
+
onParentCall({ method: "reload" });
|
|
92
|
+
onParentCall({ method: "updateItem", args: newItem });
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
**AFTER:**
|
|
96
|
+
|
|
97
|
+
```typescript
|
|
98
|
+
const { callParent } = useBlade();
|
|
99
|
+
await callParent("reload");
|
|
100
|
+
await callParent("updateItem", newItem);
|
|
101
|
+
```
|
|
102
|
+
|
|
103
|
+
Note: `callParent` is async and returns a Promise.
|
|
104
|
+
|
|
105
|
+
## RULE 4: Invert onBeforeClose Boolean
|
|
106
|
+
|
|
107
|
+
The guard semantics are **inverted** in the new API:
|
|
108
|
+
|
|
109
|
+
| Legacy | New |
|
|
110
|
+
| ------------------------------ | ----------------------------- |
|
|
111
|
+
| `return false` → prevent close | `return true` → prevent close |
|
|
112
|
+
| `return true` → allow close | `return false` → allow close |
|
|
113
|
+
|
|
114
|
+
**BEFORE:**
|
|
115
|
+
|
|
116
|
+
```typescript
|
|
117
|
+
onBeforeClose(async () => {
|
|
118
|
+
if (isModified.value) {
|
|
119
|
+
return await showConfirmation(msg); // true = allow, false = prevent
|
|
120
|
+
}
|
|
121
|
+
});
|
|
122
|
+
```
|
|
123
|
+
|
|
124
|
+
**AFTER:**
|
|
125
|
+
|
|
126
|
+
```typescript
|
|
127
|
+
onBeforeClose(async () => {
|
|
128
|
+
if (isModified.value) {
|
|
129
|
+
return !(await showConfirmation(msg)); // true = prevent, false = allow
|
|
130
|
+
}
|
|
131
|
+
});
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
If `useBladeForm()` is used, `onBeforeClose` can be removed entirely — `useBladeForm` handles it automatically.
|
|
135
|
+
|
|
136
|
+
## RULE 5: Clean Up Unused Imports
|
|
137
|
+
|
|
138
|
+
After applying all rules, remove:
|
|
139
|
+
|
|
140
|
+
- `useBladeNavigation` import
|
|
141
|
+
- `useBladeContext` import
|
|
142
|
+
- `resolveBladeByName` import (if it was imported separately)
|
|
143
|
+
- Any unused destructured variables
|
|
144
|
+
|
|
145
|
+
## Verification
|
|
146
|
+
|
|
147
|
+
After migration:
|
|
148
|
+
|
|
149
|
+
1. Run `npx vue-tsc --noEmit` to verify no TypeScript errors
|
|
150
|
+
2. Confirm `openBlade` calls navigate correctly
|
|
151
|
+
3. Confirm blade close confirmation dialogs still appear when data is modified
|
|
152
|
+
4. Confirm no remaining imports of `useBladeNavigation`, `useBladeContext`, or `resolveBladeByName`
|
|
153
|
+
5. Confirm no remaining `onParentCall` calls
|
package/runtime/vc-app.md
CHANGED
|
@@ -1600,19 +1600,19 @@ Parse the "Manual Migration Required" section. Extract each topic heading and th
|
|
|
1600
1600
|
|
|
1601
1601
|
Map topic headings to migration prompt files and pattern files:
|
|
1602
1602
|
|
|
1603
|
-
| Report Heading contains (or equals transform name)
|
|
1604
|
-
|
|
|
1605
|
-
| Widget / widgets-migration
|
|
1606
|
-
| Form Management / useBladeForm / use-blade-form
|
|
1607
|
-
| Injection Key / remove-deprecated-aliases
|
|
1608
|
-
| NSwag / DTO / Clone-then-mutate / nswag-class-to-interface
|
|
1609
|
-
| Reusable Blade Components / blade-props-simplification
|
|
1610
|
-
| Notification / notification-migration
|
|
1611
|
-
| VcTable / DataTable / vctable-audit
|
|
1612
|
-
| Icon / material- / bi- / fa- / icon-audit
|
|
1613
|
-
| Assets API / useAssets / useAssetsManager / use-assets-migration
|
|
1614
|
-
| Manual Migration Audit / useExternalWidgets / moment / useFunctions / manual-migration-audit | `manual-migration-audit` | `{KNOWLEDGE_BASE}/migration-prompts/manual-migration-audit.md` | — |
|
|
1615
|
-
| Pagination / useDataTablePagination / use-data-table-pagination-audit
|
|
1603
|
+
| Report Heading contains (or equals transform name) | Canonical topic name | Migration Prompt | Pattern |
|
|
1604
|
+
| -------------------------------------------------------------------------------------------------------------------------------- | --------------------------------- | --------------------------------------------------------------------------- | ---------------------------------------------------- |
|
|
1605
|
+
| Widget / widgets-migration | `widgets-migration` | `{KNOWLEDGE_BASE}/migration-prompts/widgets-migration.md` | `{KNOWLEDGE_BASE}/patterns/blade-widget.md` |
|
|
1606
|
+
| Form Management / useBladeForm / use-blade-form | `use-blade-form` | `{KNOWLEDGE_BASE}/migration-prompts/blade-form-migration.md` | `{KNOWLEDGE_BASE}/patterns/form-validation.md` |
|
|
1607
|
+
| Injection Key / remove-deprecated-aliases | `remove-deprecated-aliases` | `{KNOWLEDGE_BASE}/migration-prompts/blade-props-migration.md` | `{KNOWLEDGE_BASE}/patterns/blade-navigation.md` |
|
|
1608
|
+
| NSwag / DTO / Clone-then-mutate / nswag-class-to-interface | `nswag-class-to-interface` | `{KNOWLEDGE_BASE}/migration-prompts/nswag-migration.md` | — |
|
|
1609
|
+
| Reusable Blade Components / blade-props-simplification | `blade-props-simplification` | `{KNOWLEDGE_BASE}/migration-prompts/blade-props-migration.md` | `{KNOWLEDGE_BASE}/patterns/child-blade-flow.md` |
|
|
1610
|
+
| Notification / notification-migration | `notification-migration` | `{KNOWLEDGE_BASE}/migration-prompts/notifications-migration.md` | `{KNOWLEDGE_BASE}/patterns/signalr-notifications.md` |
|
|
1611
|
+
| VcTable / DataTable / vctable-audit | `vctable-audit` | `{KNOWLEDGE_BASE}/migration-prompts/datatable-migration.md` | `{KNOWLEDGE_BASE}/patterns/datatable-pattern.md` |
|
|
1612
|
+
| Icon / material- / bi- / fa- / icon-audit | `icon-audit` | `{KNOWLEDGE_BASE}/migration-prompts/icon-migration.md` | — |
|
|
1613
|
+
| Assets API / useAssets / useAssetsManager / use-assets-migration | `use-assets-migration` | `{KNOWLEDGE_BASE}/migration-prompts/use-assets-migration.md` | `{KNOWLEDGE_BASE}/patterns/assets-management.md` |
|
|
1614
|
+
| Manual Migration Audit / useExternalWidgets / moment / useFunctions / resolveBladeByName / onParentCall / manual-migration-audit | `manual-migration-audit` | `{KNOWLEDGE_BASE}/migration-prompts/manual-migration-audit.md` | — |
|
|
1615
|
+
| Pagination / useDataTablePagination / use-data-table-pagination-audit | `use-data-table-pagination-audit` | `{KNOWLEDGE_BASE}/migration-prompts/use-data-table-pagination-migration.md` | — |
|
|
1616
1616
|
|
|
1617
1617
|
Build the `topics` array for the migration-agent using the canonical topic names above.
|
|
1618
1618
|
|
package/runtime/knowledge/docs/core/composables/usePlatformLocaleSync/usePlatformLocaleSync.docs.md
DELETED
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
# usePlatformLocaleSync
|
|
2
|
-
|
|
3
|
-
One-way reactive bridge from the VirtoCommerce platform's locale storage key (`NG_TRANSLATE_LANG_KEY`, set by AngularJS + angular-translate) to the shell's language service.
|
|
4
|
-
|
|
5
|
-
Call this composable only when the shell runs embedded inside the platform — `useShellBootstrap` invokes it automatically when `options.isEmbedded === true`. In standalone mode the shell owns its own locale via `VC_LANGUAGE_SETTINGS`, and this composable should not be used.
|
|
6
|
-
|
|
7
|
-
## When to Use
|
|
8
|
-
|
|
9
|
-
- Never call directly from feature code. This is a framework-internal sync primitive.
|
|
10
|
-
- It is invoked once per `VcApp` mount from `useShellBootstrap`.
|
|
11
|
-
|
|
12
|
-
## Behaviour
|
|
13
|
-
|
|
14
|
-
- Reads `localStorage["NG_TRANSLATE_LANG_KEY"]` via VueUse's `useLocalStorage`, which subscribes to `storage` events for cross-tab reactivity.
|
|
15
|
-
- On setup, if the value is non-empty, calls `LanguageService.setLocale(value)`. `setLocale` normalises the value (e.g. `en-US` → `en-us`), falls back to `en` for unsupported locales, updates `vue-i18n`, reconfigures `vee-validate`, and persists to `VC_LANGUAGE_SETTINGS`.
|
|
16
|
-
- On subsequent changes of the platform key, re-applies the value.
|
|
17
|
-
- Skips empty strings (platform clearing the key does not blank the shell locale).
|
|
18
|
-
- Skips values equal to `currentLocale` to avoid redundant re-configuration.
|
|
19
|
-
|
|
20
|
-
## How It Works
|
|
21
|
-
|
|
22
|
-
`useLocalStorage("NG_TRANSLATE_LANG_KEY", "")` returns a `Ref<string>` that VueUse keeps in sync with `localStorage` and the DOM `storage` event (which fires in tabs other than the writer). The composable applies the current ref value once synchronously and then registers a `watch` on it; any cross-tab mutation flows through the ref into `setLocale`.
|
|
23
|
-
|
|
24
|
-
The watcher is bound to the active effect scope (typically `VcApp`'s setup). When `VcApp` unmounts, the watcher stops; `useLocalStorage` cleans up its own `storage` listener.
|
|
25
|
-
|
|
26
|
-
## Relationship to `VC_LANGUAGE_SETTINGS`
|
|
27
|
-
|
|
28
|
-
The sync is strictly one-directional. `setLocale` writes to `VC_LANGUAGE_SETTINGS` as a side effect, but this composable never writes to `NG_TRANSLATE_LANG_KEY`. In embedded mode the in-shell `LanguageSelector` is unreachable (it lives inside `UserDropdownButton`, which is hidden when `isEmbedded` is `true`), so there is no competing writer from the shell side.
|