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

spec issue: limit the elements that can appear inside of a label of a labeled link #59

Closed
3 tasks done
Simon-Laux opened this issue Feb 12, 2024 · 1 comment · Fixed by #74
Closed
3 tasks done
Assignees
Labels
bug Something isn't working spec issue that involves the specification

Comments

@Simon-Laux
Copy link
Member

Simon-Laux commented Feb 12, 2024

Example:

[Account Sidebar: No window titlebar on MacOS
#3670](https://github.com/deltachat/deltachat-desktop/pull/3670#issuecomment-1935739509)

currently #3670 in the label is parsed as a clickable hashtag. I think it makes sense to limit the allowed elements inside of the label to pure text formatting (+ linebreaks and later emojis for #58).

A clickable hashtag inside of the link label is unexpected for users and in desktop it triggers a react warning/error: Warning: validateDOMNesting(...): <a> cannot appear as a descendant of <a>.

  • document the restriction inside of spec.md
  • add unit tests for it
  • implement the change
@Simon-Laux Simon-Laux added the bug Something isn't working label Feb 12, 2024
@Simon-Laux Simon-Laux added the spec issue that involves the specification label Apr 29, 2024
@Simon-Laux Simon-Laux self-assigned this May 18, 2024
@Simon-Laux
Copy link
Member Author

looks like there is also a bug in this where you can send markdown even in the desktop set like this:

[```
hello world
```](https://delta.chat)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working spec issue that involves the specification
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant