Skip to content
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

Hashtag: Ignore tags within HTML attributes (like hex colors) #1037

Merged
merged 1 commit into from
Dec 3, 2024

Conversation

obenland
Copy link
Member

@obenland obenland commented Dec 3, 2024

Fixes #955.

Proposed changes:

  • Strips tags before searching for hashtags to convert to tags.
  • Adds unit test for various scenarios where hashtags should and shouldn't be converted.

Other information:

  • Have you written new tests for your changes, if applicable?

Testing instructions:

  • Create a new Post, use the code editor.
  • Enter an HTML tag with a css hex color code in its style. e.g.: <span style="color: #ffffff"> (Important: preceding whitespace)
  • Save the post
  • Make sure the post doesn't have a tag called ffffff.

@obenland obenland requested a review from a team December 3, 2024 16:04
@obenland obenland self-assigned this Dec 3, 2024
Copy link
Member

@pfefferle pfefferle left a comment

Choose a reason for hiding this comment

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

this is so simple and smart!

@obenland obenland merged commit df1c645 into trunk Dec 3, 2024
25 of 26 checks passed
@obenland obenland deleted the fix/hex-tagging branch December 3, 2024 16:21
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.

css hex colors turned into tags
2 participants