chore: migrate to namespaced lvt-* attributes (Phase 2E)#53
Conversation
Bump livetemplate v0.8.14 → v0.8.15 and migrate template attributes to the new namespaced syntax: - lvt-scroll → lvt-fx:scroll (chat) - lvt-preserve → lvt-form:preserve (shared-notepad) - lvt-no-intercept → lvt-form:no-intercept (login) - lvt-upload stays as-is (avatar-upload) Skip todos/ — imports lvt/components, migrated in Phase 4. Update README.md and CLAUDE.md documentation to reflect new attribute names, fix tier classifications, and remove deprecated lvt-submit from action resolution order. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
Phase 2E of the attribute reduction proposal: migrate example templates/docs to the new namespaced lvt-* attribute syntax and bump the core LiveTemplate dependency to v0.8.15, providing early feedback from the examples repo.
Changes:
- Bump
github.com/livetemplate/livetemplatefromv0.8.14→v0.8.15. - Migrate example templates to namespaced attributes (
lvt-scroll→lvt-fx:scroll,lvt-preserve→lvt-form:preserve,lvt-no-intercept→lvt-form:no-intercept). - Update repo docs (README/CLAUDE + internal plan doc) to reflect the new attribute names.
Reviewed changes
Copilot reviewed 7 out of 8 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| shared-notepad/notepad.tmpl | Replace lvt-preserve with lvt-form:preserve on the main form. |
| chat/chat.tmpl | Replace lvt-scroll with lvt-fx:scroll on the messages container. |
| login/templates/auth.html | Replace lvt-no-intercept with lvt-form:no-intercept for login/logout forms (and update comments). |
| README.md | Update example table + dependency version to reflect new attributes and v0.8.15. |
| CLAUDE.md | Update Tier 2 attribute list and action-resolution documentation to match new syntax. |
| docs/plans/improve-ui-ux.md | Update plan text referencing lvt-scroll to lvt-fx:scroll. |
| go.mod | Bump github.com/livetemplate/livetemplate requirement to v0.8.15. |
| go.sum | Update sums for github.com/livetemplate/livetemplate v0.8.15. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| 4. Default: `"submit"` | ||
| 1. Clicked button's `name` attribute | ||
| 2. Form's `name` attribute | ||
| 3. Default: `"submit"` |
There was a problem hiding this comment.
The updated action resolution order removes lvt-submit, but this repo still documents and demonstrates lvt-submit elsewhere (e.g., chat/README.md, counter/README.md, progressive-enhancement/README.md, ws-disabled/README.md). Either keep lvt-submit in this list or update the other docs so contributor guidance is consistent across the repo.
| 3. Default: `"submit"` | |
| 3. Default: `"lvt-submit"` |
…ences - counter/README.md: Update from old Store/Change API to Controller+State, replace lvt-click/lvt-submit with button name routing, update attribute list - chat/README.md: Replace lvt-submit with form name routing in code examples - progressive-enhancement/README.md: Replace lvt-submit/lvt-action with standard HTML form patterns - ws-disabled/README.md: Remove lvt-submit/lvt-click references Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Replace lvt-upload="avatar" with standard <input type="file" name="avatar"> in a form with enctype="multipart/form-data". The client detects file inputs and submits via HTTP fetch with FormData. - Remove lvt-upload attribute, add name="avatar" and enctype - Keep .lvt.Uploads progress block (works with HTTP upload too) - Remove WebSocket upload event listener script block - Remove UploadAvatarComplete (WebSocket auto-complete callback) - Simplify WithUpload config (remove WS-specific AutoUpload/ChunkSize) - Update E2E test to use JS DataTransfer API for file input - Bump livetemplate v0.8.15 → v0.8.16 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Remove verbose debug window variables, fetch interceptor, and error state captures from the upload test. The Tier 1 file upload path is working — simplify to core test logic only. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Summary
Phase 2E of the attribute reduction proposal. Early migration of the examples repo to provide hands-on feedback on the new attribute syntax.
livetemplatev0.8.14 → v0.8.15 (Phase 1B)lvt-scroll→lvt-fx:scroll(chat)lvt-preserve→lvt-form:preserve(shared-notepad)lvt-no-intercept→lvt-form:no-intercept(login, x2)lvt-uploadstays as-is (avatar-upload)todos/— importslvt/components, deferred to Phase 4Test plan
🤖 Generated with Claude Code