Repository navigation
v1.0.0-preview.8
Pre-release
Pre-release
·
23 commits
to main
since this release
Jazor 1.0.0-preview.8
中文 | English
新增功能
- Element Plus Select、Table、Dropdown 新增泛型组件,选项值、行事件、单元格 scoped slot 与 command 保留业务类型;新增强类型消息、通知、确认和 Prompt 服务。by @devhxj
- 官方 Razor SG 组件新增身份与 Vue 参数名冲突诊断;外部 wrapper 的常量默认 props 支持继承、调用处显式覆盖和 attribute splat 覆盖,错误指向作者源码。by @devhxj
- ASP.NET Core 前端宿主新增
IServiceCollection.AddJazorFrontend、IApplicationBuilder.UseJazorPathBase和IApplicationBuilder.UseJazorFrontend,Startup、IStartupFilter与第三方框架可复用 HTTP、WebSocket、PathBase 和 Release 资源管线。by @devhxj - Emit 按目标 RID 与 SDK runtime graph 选择兼容程序集,显式子路径导入复用唯一 npm/JSR 包身份;Release SSR 生成可独立运行的
ssr/ssr-entry.js与本地 chunks,无需恢复node_modules。by @devhxj - 浏览器绑定补齐 live
DOMTokenList、IWindow.LiveLocation(WindowProxy同样可用)和Number到long/ulong的显式转换。超出 Number 安全整数范围的标识应保留字符串或 BigInt;结构化 JSON 通过调用方 replacer 将 BigInt 转为十进制字符串。by @devhxj - 既有 C# DOM 事件通过 CLR 映射与 extension 访问原生浏览器属性,覆盖 12 种事件的精确
NativeEvent、input/dropFiles以及DataTransfer、DataTransferItem、TouchPoint、ElementReference投影。原生接口仍由 WebIDL 生成;CurrentTarget与临时剪贴板/拖放数据应在 callback 中、首次 await 前读取。CLRDataTransfer.Files/Items使用独立的NativeFiles/NativeItems入口。by @devhxj
破坏性变更
Element.ClassList、Part、RelList等 token 属性从集合投影改为原生 liveDOMTokenList。迁移:把Count改为Length,通过GetItem(index)读取原生item(index),集合操作改用Add、Remove、Toggle等 DOM 方法。by @devhxjElTableColumn.ChildContent改为RenderFragment<ElTableSlotContext>scoped slot;新增ElTypedTableColumn<TRow>使用ElTableSlotContext<TRow>保留行类型。迁移:Razor 自定义单元格通过Context="cell"访问cell.Row、cell.Column、cell.Index;手工赋值ChildContent时改为接收该 context 的 fragment 工厂。by @devhxj- Folder Publish 默认只复制
dist/**和启用 SSR 时的ssr/**,不再复制源码、根项目文件、lock 或node_modules,source map 默认不发布。迁移:部署脚本托管dist/,SSR 执行ssr/ssr-entry.js;需要部署 source map 时设置JazorPublishSourceMaps=true。by @devhxj
问题修复
- 修复 inline getter 的空条件属性和方法访问丢失整链短路的问题;接收者保持单次求值。by @devhxj
- 修复
ProgressEventArgs.Loaded/Total混用 Number 与 CLR BigInt carrier,原生NativeEvent继续使用 WebIDL Number。by @devhxj - 修复外部组件显式参数仍被已覆盖的动态默认 initializer 拒绝的问题。by @devhxj
- RazorVue 保留 code-behind 产生的 Vue lifecycle helper import,条件分支使用稳定 Fragment 锚点;重复挂载、卸载及 loading/empty/data 切换保持资源清理与 DOM 范围正确。by @devhxj
- Development SSR 优先当前源码图,避免误用历史 Release bundle。by @devhxj
- npm/JSR 子路径包身份精确比较 Base64 完整性摘要,大小写差异在写出前报告冲突。by @devhxj
- MSBuild
JazorMode默认值改在 targets 阶段应用,项目条件属性可以覆盖;自定义或相对JazorDir只排除生成根,不吞掉Jazor/*.cs、.razor和其他作者输入。by @devhxj
其他变更
- 开发者反馈回归纳入完整主线与覆盖率门禁;Release 包消费者验证运行闭包、PathBase、真实 Chrome 交互、Deno SSR 与 hydration,发布和 Wiki 验收同步新的目录与默认 source map 契约。by @devhxj
- 更新公共 API 基线并通过 Release 程序集比较、绑定生成与 inventory、XML 文档检查及 23 个 lockstep 包验证;当前指标与复现入口见反馈验收。by @devhxj
New Features
- Add generic Element Plus Select, Table, and Dropdown components that retain business types for option values, row events, scoped cell slots, and commands; add typed message, notification, confirmation, and Prompt services. by @devhxj
- Add component-identity and Vue parameter-name collision diagnostics to official Razor SG authoring. External wrapper constant defaults support inheritance, explicit parameters, and attribute splats, with errors located in authored source. by @devhxj
- Add
IServiceCollection.AddJazorFrontend,IApplicationBuilder.UseJazorPathBase, andIApplicationBuilder.UseJazorFrontendso Startup,IStartupFilter, and framework integrations can reuse the HTTP, WebSocket, PathBase, and Release artifact pipeline. by @devhxj - Select compatible assemblies by target RID and SDK runtime graph, and reuse one npm/JSR package identity for declared subpath imports. Release SSR produces an independently runnable
ssr/ssr-entry.jswith local chunks, without restoringnode_modules. by @devhxj - Add live
DOMTokenList,IWindow.LiveLocation(also available onWindowProxy), and explicitNumbertolong/ulongconversions. Keep identifiers outside the safe Number integer range as strings or BigInt; serialize structural JSON with a caller-owned replacer that converts BigInt to decimal strings. by @devhxj - Existing C# DOM events gain native browser properties through CLR mappings and extensions, covering precisely typed
NativeEventfor 12 event families, input/dropFiles, andDataTransfer,DataTransferItem,TouchPoint, andElementReferenceprojections. WebIDL still generates native interfaces. ReadCurrentTargetand transient clipboard/drop data in the callback before the first await; use distinctNativeFiles/NativeItemsentries for CLRDataTransfer.Files/Items. by @devhxj
Breaking Changes
- Change token properties such as
Element.ClassList,Part, andRelListfrom collection projections to native liveDOMTokenListvalues. Migration: replaceCountwithLength, useGetItem(index)for nativeitem(index), and use DOM methods such asAdd,Remove, andTogglefor mutation. by @devhxj - Change
ElTableColumn.ChildContentto aRenderFragment<ElTableSlotContext>scoped slot; the newElTypedTableColumn<TRow>keeps the row type throughElTableSlotContext<TRow>. Migration: useContext="cell"withcell.Row,cell.Column, andcell.Indexin Razor cell templates; manualChildContentassignments must accept that context and return a fragment. by @devhxj - Folder Publish copies only
dist/**and optional SSRssr/**, excluding source, root project files, locks, andnode_modules; source maps are excluded by default. Migration: servedist/and runssr/ssr-entry.jsfor SSR. SetJazorPublishSourceMaps=truewhen deployed maps are needed. by @devhxj
Bug Fixes
- Preserve null short-circuiting through entire inline getter property and method chains, with single evaluation of the receiver. by @devhxj
- Fix Number/CLR BigInt carrier mixing in
ProgressEventArgs.Loaded/Total; nativeNativeEventretains WebIDL Number values. by @devhxj - Stop rejecting explicit external-component parameters because of an overridden dynamic default initializer. by @devhxj
- Preserve Vue lifecycle helper imports from code-behind and use stable Fragment anchors for conditional branches, keeping resource cleanup and DOM ranges correct across repeated mounting, unmounting, and loading/empty/data transitions. by @devhxj
- Prefer current source graphs for Development SSR instead of stale Release bundles. by @devhxj
- Compare npm/JSR subpath Base64 integrity digests exactly and report case-sensitive conflicts before writing output. by @devhxj
- Apply the
JazorModedefault in targets so project conditions can override it; custom or relativeJazorDirvalues exclude only their generated root and keep authoredJazor/*.cs,.razor, and other inputs. by @devhxj
Chores
- Include developer-feedback regressions in the complete mainline and coverage gates. Release consumers verify runnable closures, PathBase, real Chrome interaction, Deno SSR, and hydration; release and Wiki checks follow the current layout and default source-map contract. by @devhxj
- Update the public API baseline and pass Release assembly comparison, binding generation/inventory, XML documentation, and 23 lockstep package checks. Current metrics and reproduction commands are in the feedback validation. by @devhxj