Skip to content

feat(components): add dedicated "copy value" context menu option to document card COMPASS-10041#7919

Closed
gribnoysup wants to merge 2 commits intomainfrom
COMPASS-10041-copy-value
Closed

feat(components): add dedicated "copy value" context menu option to document card COMPASS-10041#7919
gribnoysup wants to merge 2 commits intomainfrom
COMPASS-10041-copy-value

Conversation

@gribnoysup
Copy link
Copy Markdown
Collaborator

@gribnoysup gribnoysup commented Mar 27, 2026

Quick one we stumbled upon when going through the backlog. Copying just the value is helpful sometimes, especially for strings that we truncate

@gribnoysup gribnoysup requested a review from a team as a code owner March 27, 2026 15:22
@gribnoysup gribnoysup requested a review from tculig March 27, 2026 15:22
@github-actions github-actions Bot added the feat label Mar 27, 2026
@gribnoysup gribnoysup changed the title feat(components): add dedicated copy value context menu option COMPASS-10041 feat(components): add dedicated "copy value" context menu option COMPASS-10041 Mar 27, 2026
@gribnoysup gribnoysup changed the title feat(components): add dedicated "copy value" context menu option COMPASS-10041 feat(components): add dedicated "copy value" context menu option to document card COMPASS-10041 Mar 27, 2026
{
label: 'Copy value',
onAction: () => {
void navigator.clipboard.writeText(element.toEJSON());
Copy link
Copy Markdown
Member

@Anemy Anemy Mar 27, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we make the value shell syntax? We'd want to update the copy field and value to be shell syntax as well then. These changes look good if we want to go with EJSON here.
*Looking at it more, we'd also want to change the Copy Document to be shell syntax instead of EJSON for consistency then.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Element doesn't have methods for this, so we will need to extend it first, add tests, etc. This was supposed to be 2 story points that we just do during triage and I don't really have time to do this change too, I'll move this back to backlog

@gribnoysup gribnoysup closed this Apr 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants