mermaid-js / mermaid

Generation of diagrams like flowcharts or sequence diagrams from text in a similar manner as markdown
https://mermaid.js.org
MIT License
69.17k stars 6.12k forks source link

Support for 5-digit Unicode code points #5347

Open chris-braidwell opened 4 months ago

chris-braidwell commented 4 months ago

Description

When I label an object with a 4-digit unicode value: like entry[#9829;], the resulting label is , great.

When I try to use a 5-digit unicode value like entry[#1FBC5;], the resulting label is #1FBC5;.

When I try to represent that code point as a surrogate pair like entry[#D83E;#DFC5;], the label is #D83E;#DFC5;.

Is there a way to represent code points with >4 digits?

Steps to reproduce

See examples above

Screenshots

No response

Code Sample

No response

Setup

Suggested Solutions

No response

Additional Context

No response

Yash-Singh1 commented 3 months ago

When I try to use a 5-digit unicode value like entry[#1FBC5;], the resulting label is #1FBC5;.

Mermaid.js doesn't support hexadecimal HTML entities, but you can use the decimal equivalent as #129989;

https://mermaid.live/edit#pako:eNoNyrEOgjAQBuBXIb8ri062rLyBo-dwaQ8h0tac1xBCeHe7fcN3IJQo8JjWsoWZ1ShLNt2fl-vNubsbXuiRRBMvsbWDctcRbJYkBN8YWT8Eymd7XK089hzgTav0qN_IJuPCb-UEP_H6k_MPnsYmxQ