v1.0.0 Release Notes
Released
v0.6.22 -> v1.0.0
Summary
Reworks the rendering core from whole-tree diffing into keyed, block-level partial updates, and stabilizes the public surface for a 1.0 release. Built-in visual effects and source obfuscation are dropped, and locale selection becomes explicit.
翻譯
將渲染核心由整棵樹比對改為以 key 識別的區塊級局部更新,並為 1.0 定版整理對外介面。內建視覺效果與原始碼混淆一併移除,語系選擇改為明確指定。
⚠️ Breaking Changes
Rendering switched from DOM diffing to keyed partial rendering
Before:
- <!-- loops matched by position; container children contain only rendered items -->
- <li :for="item in items">{{ item.name }}</li>
After:
- <!-- optional :key matches outer-loop items by identity; each top-level :for / :if block is delimited by comment nodes -->
- <li :for="item in items" :key="item.id">{{ item.name }}</li>
:modelbinds only top-level keys; a nested path such asform.nameis no longer bound and logs[Invalid]fragment()copies the root's child nodes excluding comment anchors- Top-level
:for/:ifblocks add comment nodes to the container'schildNodes
Migration:
- // Old
- <input :model="form.name" />
- // New: bind a top-level key
- <input :model="formName" />
- // Old: code assuming childNodes holds only rendered items
- container.firstChild
- // New: skip comment anchors
- [...container.childNodes].filter((n) => n.nodeType !== 8)[0]
Built-in render effects and loading masks removed
Before:
- <img :lazyload="cover" :effect="circle" />
- <div :mask="true" effect="fade-in"></div>
After:
- <img :lazyload="cover" />
Migration:
- /* Old: QuickUI added fade-in / expand / loading-block classes automatically */
- /* New: provide the visuals with your own CSS */
- .card {
- animation: fade 0.3s;
- }
i18nLang removed; locale must be selected explicitly
Before:
- const app = new QUI({ id: "app", i18n: { zh: {...}, en: {...} }, i18nLang: "zh" });
After:
- const app = new QUI({ id: "app", i18n: { zh: {...}, en: {...} } });
- app.lang("zh");
- No default locale: nothing is translated until
lang()selects one - Missing translations render the raw
i18n.xxxstring instead of the bare key lang()called before initialization is queued, and no longer logs a conflict
Migration:
- // Old
- new QUI({ id: "app", i18n, i18nLang: "zh" });
- // New (lang() returns nothing; keep the instance in a variable first)
- const app = new QUI({ id: "app", i18n });
- app.lang("zh");
QUI.body accessor removed
Before:
- app.body.classList.add("ready");
After:
- app.element.classList.add("ready");
Migration:
- // Old
- app.body;
- // New
- app.element;
翻譯
- 渲染由 DOM diff 改為以 key 識別的局部渲染:
:model僅支援頂層 key,巢狀路徑不再綁定;頂層:for/:if區塊會在容器childNodes加入註解節點;fragment()不含註解錨點。 - 移除內建渲染效果與載入遮罩(
:effect、:animation、:mask),需自行以 CSS 實作。 - 移除
i18nLang,改以lang()明確選擇語系;未選擇或缺少翻譯時顯示原始i18n.xxx字串。 - 移除
QUI.body,改用QUI.element。
Changes
BREAKING
- Replace DOM diffing with keyed partial rendering and add
:keyfor outer-loop item identity (@pardnchiu) [3290140, ce2eadd]- Track binding blocks and a dependency index so only affected blocks recompute
- Restrict
:modelto top-level keys - Delimit top-level
:for/:ifblocks with comment nodes
- Remove built-in render effects and loading masks, and unminify internal source (@pardnchiu) [52edcd3]
- Drop
:effect,:animationand:maskpresets - Use native API names in
src/whiledist/stays minified
- Drop
- Require explicit locale selection through
lang()and removei18nLang(@pardnchiu) [30a9e76]- Queue
lang()calls made before initialization - Show the raw
i18n.xxxstring when a translation is missing
- Queue
- Remove the
QUI.bodyaccessor in favor ofQUI.element(@pardnchiu) [fdb03b1]
翻譯
- 以 key 識別的局部渲染取代 DOM diff,並新增
:key - 移除內建渲染效果與載入遮罩,並還原內部原始碼的可讀性
- 改為透過
lang()明確選擇語系,移除i18nLang - 移除
QUI.body,改用QUI.element
FIX
- Fix weekday formatting in
dateFormat, HTML attribute bindings and template traversal (@pardnchiu) [ce2eadd]
翻譯
- 修正
dateFormat星期格式、HTML 屬性綁定與模板走訪問題
Scope
src/model/,src/function/,src/listener/,src/interface.ts— BREAKING, FIXsrc/QuickUI.debug.js,dist/— BREAKING, FIXpackage.json— UPDATEREADME.md,doc/— DOC.gitattributes,wiki-worker/— CHORE
Generated by SKILL