Workaround for empty unique variable editing blockgrid / blocklist#214
Merged
rickbutterfield merged 2 commits intorickbutterfield:v5/mainfrom Jan 8, 2026
Merged
Workaround for empty unique variable editing blockgrid / blocklist#214rickbutterfield merged 2 commits intorickbutterfield:v5/mainfrom
rickbutterfield merged 2 commits intorickbutterfield:v5/mainfrom
Conversation
…st from a deeper level
Contributor
There was a problem hiding this comment.
Pull request overview
This pull request addresses issue #213 by implementing a workaround for empty unique variable values when editing blockgrid and blocklist elements. The fix introduces a fallback mechanism to extract the document unique identifier from the workspace edit path when it's not available from the context.
Key changes:
- Adds a new
#extractUniqueFromWorkspacePathmethod that uses regex to extract UUIDs from workspace paths - Implements fallback logic in multiple locations to populate the unique value when it's empty
- Includes minor formatting and whitespace adjustments in block-grid-preview
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 6 comments.
| File | Description |
|---|---|
| rich-text-preview.custom-view.element.ts | Adds fallback logic to extract unique from workspace path and implements the extraction method |
| block-list-preview.custom-view.element.ts | Adds identical fallback logic and extraction method for block list previews |
| block-grid-preview.custom-view.element.ts | Adds fallback logic, extraction method, and includes formatting/whitespace cleanup |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
4 tasks
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 seems to fix the issue #213