ロングノーツ中点・終点にwidthオプション追加 - #60
Open
mtsgi wants to merge 3 commits into
Open
Conversation
There was a problem hiding this comment.
Pull request overview
This PR extends the chart editor’s note model and rendering to support variable widths for type 1/89 nodes (normal / long-note midpoint & endpoint), adds UI controls to edit that width, and updates SVG hold-path generation to support different start/end widths.
Changes:
- Added a new
widthoption to type 1/89 option definitions and documented it inCHART_TYPES.md. - Updated option validation (
getValidatedOptions) and unit tests to include and trim the new width option appropriately. - Updated Long Note / shadow rendering to compute node/segment geometry using per-node widths, and updated editing forms/layout to expose the width field.
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| src/composables/useNoteTypes.ts | Adds width option metadata and updates hold SVG path generation to support different start/end widths. |
| src/composables/useNoteCheck.ts | Extends option normalization for type 1/89 to include the new width option. |
| src/composables/tests/useNoteTypes.test.ts | Updates expectations for new option list and verifies SVG path generation with differing widths. |
| src/composables/tests/useNoteCheck.test.ts | Adds test coverage for width retention and trimming behavior in validated options. |
| src/components/NoteShadow.vue | Updates shadow rendering geometry and hold segment generation to reflect variable widths. |
| src/components/LongNote.vue | Updates long note rendering + editing UI to handle width-aware layout and improved form UX. |
| src/components/EndForm.vue | Adds UI + reactive wiring for editing end-node width option. |
| CHART_TYPES.md | Documents the new width option for type 1/89. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
…-editor into feature/long-width
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request adds support for specifying and visualizing the width of type 1/89 notes, updates the UI to allow editing this new property, and ensures that the rendering logic and tests handle variable note widths correctly. It also refines the layout and user experience for note editing forms.
Support for variable note widths:
width(Float) option to type 1/89 notes, documented inCHART_TYPES.md, and updated the description and option list accordingly.widthproperty, including validation and default value trimming ingetValidatedOptionsandnoteOptions. [1] [2]UI changes for editing note width:
EndForm.vueandLongNote.vueto add a field for editing thewidthproperty of note ends, and adjusted the responsive layout of note editing forms. [1] [2] [3] [4] [5] [6] [7]Rendering and visualization updates:
LongNote.vueandNoteShadow.vueto use thewidthproperty when calculating note positions and widths, ensuring correct visual representation of variable-width notes. [1] [2] [3] [4] [5] [6]SVG path generation and related tests:
Miscellaneous improvements:
These changes collectively enable users to specify, edit, and visualize the width of certain note types, improving the flexibility and expressiveness of the chart editor.