1917 Commits

Author SHA1 Message Date
金毛88 c5c8eb2515 chore(deps): 更新项目依赖版本
- 将 cspell 从 10.0.1 更新到 10.1.0
- 将 eslint 从 10.8.1 更新到 10.9.0
- 将 happy-dom 从 20.11.2 更新到 20.11.6
- 将 oxlint 从 1.78.0 更新到 1.79.0
- 将 turbo 从 2.10.10 更新到 2.10.11
- 将 vite 从 8.2.1 更新到 8.2.2
- 将 vitest 从 4.1.10 更新到 4.1.11
- 将 vue-tsc 从 3.3.9 更新到 3.3.11
2026-08-23 15:13:49 +08:00
徐蒙恩 53b1529298 feat(locales): support runtime dynamic language list (#8279)
* feat(locales): support runtime dynamic language list

- 将 SupportedLanguagesType 从硬编码的 'en-US' | 'zh-CN' 联合类型放宽为 string,支持应用在运行时注册自定义语言

- @vben/constants 新增 setSupportLanguages / onSupportLanguagesChange / getSupportLanguages,以发布订阅方式动态管理语言列表(订阅时立即回调当前值)

- language-toggle 与 user-dropdown 组件改为订阅动态列表,不再直接引入静态 SUPPORT_LANGUAGES

- use-simple-locale 对未知语言回退到 en-US

- vxe-table 集成对未打包的自定义语言回退到 en-US 语言包

向后兼容:不调用 setSupportLanguages 时,行为与之前完全一致。

* fix(constants): 语言列表注册表返回独立快照

getSupportLanguages 与监听器回调改为返回克隆快照,存储时也做克隆,避免外部直接修改数组或元素对象污染注册表内部状态、绕过 setSupportLanguages 导致其他订阅者不同步。

* fix(constants): 偏好设置面板语言列表改为订阅动态注册表

- general.vue 不再直接引入静态 SUPPORT_LANGUAGES,改为通过 onSupportLanguagesChange 订阅,运行时替换语言列表后设置面板同步刷新

- setSupportLanguages 通知时迭代监听器快照,避免监听器在回调中取消订阅导致跳过后续监听器

* fix(constants): 固化本次更新快照后再通知监听器

监听器回调中嵌套调用 setSupportLanguages 时,后续监听器仍收到本次更新的列表,而不是嵌套调用的新列表。
2026-08-23 14:45:09 +08:00
Liu e3369bd635 docs: 补充工具、状态管理、缓存模块文档 (#8266)
* docs: 补充工具、状态管理、缓存模块文档

- 新增 essentials/utils、stores、cache 三篇中英文档
- 基础导航下新增工具、状态管理、缓存入口
- utils 文档为每个方法配独立示例,第三方再导出补官方文档链接
- 缓存模块独立成篇,utils 移除缓存与底层时区函数说明

* docs: 修正 review 反馈

- cache: 补全 driver 省略时回退说明、空前缀 clear/keys 警告、setItem 移除不支持的泛型
- stores: getTimezoneOptions 示例补 await
- utils: mergeWithArrayOverride 改名、triggerDownload 位置签名、downloadFileFromUrl 校验说明、formatDateTime 固定日期、createMerge 回调契约

* docs: 修正工具与状态管理文档并补全导航配置

- 工具文档:移除 createMerge 章节,修正 mergeWithArrayOverride 示例结果为 { a: [1] }(defu 回调保留首个参数数组)
- 状态管理文档:澄清 useTimezoneStore.$reset 不会同步 dayjs 默认时区,补充 VITE_APP_STORE_SECURE_KEY 加密配置说明
- 工具/状态管理/缓存文档:添加 outline: deep 以显示 H2/H3 二级方法导航

* docs: 移除文档中多余的对象合并章节内容

整理了中英文版的状态管理和工具函数文档,删除了过时的对象合并相关文档内容,优化文档结构。
2026-08-19 12:30:27 +08:00
dream-weave 4e0208c93e Merge branch 'main' into fix/layout-css-scroll-background 2026-08-18 13:31:17 +08:00
Dream 522a83b2fb fix(@vben-core/layout-ui): add overlay viewport height fallback 2026-08-18 11:56:15 +08:00
金毛88 154b727491 chore: 更新项目依赖包版本
- 更新 @tsdown/css 从 0.22.13 到 0.22.14
- 更新 eslint 从 10.7.0 到 10.8.1
- 更新 happy-dom 从 20.11.1 到 20.11.2
- 更新 oxlint 从 1.75.0 到 1.78.0
- 更新 playwright 从 1.61.1 到 1.62.1
- 更新 tsdown 从 0.22.13 到 0.22.14
- 更新 turbo 从 2.10.6 到 2.10.10
- 更新 vite 从 8.1.5 到 8.2.1
- 更新 vue-tsc 从 3.3.8 到 3.3.9
2026-08-15 13:12:21 +08:00
金毛88 f83252d443 Merge branch 'fork/HaroldZhangCode91/feature/fix_modal_defects' 2026-08-14 22:50:36 +08:00
OctoBored c6e196f1d2 docs: fix broken star history chart (#8254)
The star history chart in the README is broken because the upstream endpoint is no longer able to read GitHub stargazer data reliably. Switch the chart image and its link to the alternative star-history domain so the chart renders correctly again.

Co-authored-by: OctoBored <212877535+OctoBored@users.noreply.github.com>
2026-08-14 19:29:12 +08:00
Harold Zhang de78a87f38 fix(@vben/vite-config): 修复生产构建下组件库 css 层顺序错误导致样式被覆盖
viteCssLayerPlugin 把组件库 css 包进 @layer 依赖 theme.css 中的层顺序声明
先被注册。生产构建下 css 按 chunk 注入,若组件库 css chunk 先于 theme.css
加载,层名会被注册为最低优先级,Tailwind base/utilities 覆盖组件样式。

由于 rolldown-vite 的 css 合并会剥离「层顺序声明 + @layer 规则」模块的层
(规则被脱层),压缩阶段也会丢弃 transform 输出的声明,改为在
generateBundle 阶段向含组件库层的 css 产物顶部统一注入层顺序声明,无论
chunk 加载顺序如何层优先级都正确(theme.css 先加载时声明为幂等 no-op)。
properties(Tailwind --tw-* 回退变量层)排在首位保持最低优先级,theme.css
中的声明同步更新以保持一致。
2026-08-14 16:55:51 +08:00
Harold Zhang fbd8ffac75 fix(@vben-core/shadcn-ui): 修复弹窗关闭动画被取消时 closed 事件丢失导致弹窗无法关闭
closed/opened 事件仅由内容元素自身的 animationend 确认,当退出动画被跳过或
取消(reduced motion、动画中断、关闭中 class 变化)时事件永远不会触发,
弹窗保持可见、destroy-on-close 重挂载和 onClosed 监听器挂起。

提取共享 useDialogStateEvents 组合式函数(dialog/alert-dialog/sheet 三处
重复实现统一),同时监听 animationend/animationcancel(对齐 reka-ui Presence
语义),并在动画窗口后增加 300ms 兜底触发,配合 exactly-once 守卫保证关闭
链路恰好完成一次;onScopeDispose 清理定时器。补充 popup-ui 单测覆盖兜底
与恰好一次两条路径。
2026-08-14 16:15:09 +08:00
Dream aa36114181 fix(@vben-core/layout-ui): address layout review findings 2026-08-13 11:09:26 +08:00
Dream 63667e46ee fix(@vben-core/layout-ui): avoid nested sidebar ternary 2026-08-13 10:30:14 +08:00
dream-weave 3b9cc44bc5 Merge branch 'main' into fix/layout-css-scroll-background 2026-08-13 10:20:15 +08:00
Dream 8f60e8063a test(@vben/playground): cover layout behavior and performance 2026-08-12 11:34:28 +08:00
Dream fa2b1ec243 refactor(@vben/common-ui): simplify page content sizing 2026-08-12 10:42:23 +08:00
Dream 89c05f8274 refactor(@vben-core/layout-ui): move layout sizing and scrolling to CSS 2026-08-12 10:41:29 +08:00
Zehui Chan 51ce0ecdd6 feat(@vben-core/form-ui): support labelWidth auto alignment (#8245)
* feat(@vben-core/form-ui): support labelWidth auto alignment

Measure horizontal labels and align them to the widest one when
labelWidth is set to auto, allow string widths, and expose a single
form-render context that also carries the label-width registry.

Co-authored-by: Cursor <cursoragent@cursor.com>

* feat(@vben/playground): add form labelWidth auto demo

Provide an interactive example under Examples -> Form -> Label Auto
Width, with locales and route wiring, to showcase auto alignment.

Co-authored-by: Cursor <cursoragent@cursor.com>

---------

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-12 08:37:30 +08:00
MistyMoon 0b9ecbb6c9 fix(@vben-core/menu-ui): menu badge overflow, font-size & default color (#8244)
* fix(@vben-core/menu-ui): menu badge ping ring clipped by overflow

The .vben-menu-item__content span rule applied the menu-title mixin
(overflow:hidden, for text ellipsis) to ALL descendant spans, including
the badge dot spans. This clipped the animate-ping expanding ring, so
the leaf-menu badge dot only pulsed (opacity fade) instead of pinging,
while the sub-menu (directory) badge pinged correctly because it lives
under .vben-sub-menu-content which has no such rule.

Fix: scope the menu-title mixin to the title span (.vben-menu__name)
and wrap the menu-item title slot accordingly.

* fix(@vben-core/menu-ui): allow custom font-size on sub-menu-content descendants

* fix(@vben-core/menu-ui): correct default badge variant color
2026-08-12 08:27:29 +08:00
JyQAQ e8d35a7471 fix(@vben/styles): 修复弹窗内 tooltip 层级被遮挡问题 (#8240)
将 antd-tooltip 的 z-index 提升至 2001,避免在 Modal/弹窗等高 z-index 容器内的 tooltip 被遮挡
2026-08-07 06:08:20 +08:00
yshbyy f038166681 chore: 更新.gitattributes文件配置 (#8178)
git 不支持 Shell 的花括号展开语法
2026-08-07 05:16:35 +08:00
dependabot[bot] 88cc837f6a build(deps): bump actions/stale from 10 to 11 (#8227)
Bumps [actions/stale](https://github.com/actions/stale) from 10 to 11.
- [Release notes](https://github.com/actions/stale/releases)
- [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/stale/compare/v10...v11)

---
updated-dependencies:
- dependency-name: actions/stale
  dependency-version: '11'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-08-07 05:15:36 +08:00
金毛88 82d790a6ab Merge branch 'fork/dream-weave/fix/popup-route-reentry' 2026-08-07 05:14:52 +08:00
金毛88 9c3ba53990 Merge branch 'fork/ming4762/fix-transition-20260805' 2026-08-07 05:11:42 +08:00
金毛88 cb707c8c78 Merge branch 'fork/LayHuts/fix/lint-format' 2026-08-07 05:09:58 +08:00
Dream 98761dce98 fix(@vben-core/popup-ui): stabilize content popups across routes
Mount in-content drawers and modals to the persistent main content element.

Initialize drawer open state when mounted after the API opens.

Fixes vbenjs/vue-vben-admin#8210
2026-08-06 10:17:14 +08:00
zhongming4762 d3dc081b5d perf: 优化路由动画切换 1、切换出现双页面问题 2、切换出现横向和纵向滚动条问题 2026-08-05 19:14:12 +08:00
layhuts 2c1e643ab9 fix: 调整lint执行顺序
使用核心 no-nested-ternary 规则替代 Unicorn 自动修复,避免嵌套三元表达式被错误加括号
调整 oxlint、oxfmt、eslint 和 stylelint 的执行顺序,保证commit与format流程一致
2026-08-05 11:10:21 +08:00
Dream 0a47dc8a3d fix(@vben/playground): reset popup form state 2026-08-05 10:24:28 +08:00
Dream d0c8c887fd docs: document typed popup data contracts 2026-08-05 09:54:01 +08:00
Dream f16c780c2b refactor(@vben/web-naive): type modal shared data 2026-08-05 09:52:28 +08:00
Dream ebe0eadee4 feat(@vben/playground): add typed popup data examples 2026-08-05 09:50:55 +08:00
Dream 3cbb1e8411 refactor(@vben/playground): type popup data consumers 2026-08-05 09:48:27 +08:00
Dream 21d9132703 feat(@vben-core/popup-ui)!: add typed popup data contracts
Bind shared data to modal and drawer APIs and infer it from exposed connected components.

BREAKING CHANGE: getData<T>() is replaced by getData().
Shared data defaults to unknown, and an unset payload returns undefined instead
of an empty object.
2026-08-05 09:46:37 +08:00
dream-weave 9f5b1cd9fb fix(@vben-core/form-ui)!: group field slot component props (#8215)
* refactor(@vben-core/form-ui)!: group field slot component props

* fix(@vben-core/form-ui): stabilize grouped field slot bindings

Resolve function-based common component props with field context.

Preserve internal model and event bindings when custom field slots spread componentProps.

Add regression coverage for array contexts, disabled precedence, and stale binding isolation.

* feat(@vben/vite-config): warn about field slot migration

Print the temporary field-slot migration warning when the development server starts.

Inject the same message into the browser console and keep the plugin serve-only.

* docs(@vben/docs): document field slot migration

Place the breaking field-slot notice at the start of both form documents.

Explain old and new bindings, development warnings, and planned notice removal.

* feat(@vben/playground): extend custom form example

Add a switchable input and select field to demonstrate schema component updates.

Update the composite phone field to emit new tuple values so validation observes changes.
2026-07-31 18:13:49 +08:00
dream-weave 32495e40b2 fix(@vben-core/popup-ui): rebind popup api after HMR (#8217)
* fix(@vben-core/popup-ui): rebind popup api after hmr

* fix(@vben-core/popup-ui): preserve options after remount
2026-07-31 06:13:10 +08:00
dream-weave cb52807b27 fix(@vben-core/form-ui): correct field slot props (#8216) 2026-07-31 06:07:52 +08:00
MistyMoon 418c16e093 fix(@vben/locales): 修复锁屏弹窗按钮文案歧义 (#8211)
锁屏设置弹窗(lock-screen-modal)的确认按钮作用是输入密码后锁定屏幕,
但按钮文案 i18n key `ui.widgets.lockScreen.screenButton` 原值为「解锁」/「Unlock」,
与弹窗标题「锁定屏幕」及实际动作矛盾,存在歧义。

- zh-CN: 「解锁」->「锁定」
- en-US: 「Unlock」->「Lock」

(同段另有 `unlock` key 值「点击解锁」,用于已锁定后的全屏解锁界面,语义正确,保持不变)
2026-07-30 07:12:08 +08:00
JyQAQ b04d728249 fix(@vben-core/form-ui): 兼容 zod v4 的 ZodArray,避免误用 unwrap() 丢失数组外壳导致数组校验失败 (#8207) 2026-07-28 15:50:15 +08:00
JyQAQ 44483db9af fix(project): 修复弹窗中表单上传组件预览图片层级问题 (#8205)
将 PreviewGroupComponent 的 hidden class 替换为通过 classes.popup.root
设置更高 z-index,避免在弹窗内被遮挡
2026-07-27 22:37:33 +08:00
layhuts fbf0cebf4b style: 优化 vxe-table 类型组织结构,将 viewed-row 功能域相关类型进行模块化拆分,由全局类型声明调整为功能目录内聚管理,避免公共 types 文件持续膨胀。 (#8204) 2026-07-27 22:36:04 +08:00
金毛88 98344dfcec Merge branch 'fork/dream-weave/fix-layout-scroll-container' 2026-07-25 20:37:20 +08:00
Dream 6d5ccc7ac8 fix(@vben/layouts): scope hash targets to layout 2026-07-24 17:32:51 +08:00
Dream b9c6d56f74 fix(@vben/layouts): restore internal scroll navigation 2026-07-24 16:58:39 +08:00
Dream aaf0da582c fix(@vben-core/layout-ui): stabilize internal layout scrolling 2026-07-24 16:57:32 +08:00
Dream 9a5d052fa5 fix(@vben-core/composables): lock layout scroll container 2026-07-24 16:56:35 +08:00
Dream baea741432 feat(@vben-core/shared): add layout scroll helpers 2026-07-24 16:55:36 +08:00
xingyu4j 33f4522bff fix: 补充 i18n 缺失的英文 2026-07-24 15:26:08 +08:00
xingyu4j cb6b0a8872 fix: constrain popper content to available viewport width 2026-07-24 15:21:07 +08:00
xingyu4j 57e2a54219 fix: add missing Symbol descriptions 2026-07-24 15:17:55 +08:00
xingyu4j 4db254cd21 fix: Tailwindcss v4 new variable shorthand syntax 2026-07-24 15:07:17 +08:00