Skip to content

Add selection and selectionHtml variables #495

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

chasemccoy
Copy link

This PR adds new, separate variables containing only the content selected by the user (if any) in both markdown and HTML format. Currently, the content variable contains the selection if there is one, and otherwise the page contents or highlights.

I wanted my clipper template to capture selected text, but not default to clipping the entire page contents if there isn't a selection, so thought adding a separate variable for just the selection would be the way to go.

@chasemccoy chasemccoy marked this pull request as ready for review May 25, 2025 19:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant