Closed yin1999 closed 3 months ago
Reference doc: https://discuss.streamlit.io/t/st-code-on-multiple-lines/50511
Add CSS style to allow the code to be wrapped, this enables directly previewing the entire token and makes it easier to copy because the copy button will not be mixed with the token string.
Used CSS properties:
white-space
streamlit
hyphens
overflow-wrap
The token is randomly generated (the length of it is the same as the token generated by aliyundrive API)
Reference doc: https://discuss.streamlit.io/t/st-code-on-multiple-lines/50511
Add CSS style to allow the code to be wrapped, this enables directly previewing the entire token and makes it easier to copy because the copy button will not be mixed with the token string.
Used CSS properties:
white-space
: used for override the settings ofstreamlit
, see https://discuss.streamlit.io/t/st-code-on-multiple-lines/50511hyphens
: remove the auto inserted hyphen between non-space-breaking characters.overflow-wrap
: always break the line if the line is going to be overflowed.Tests
The token is randomly generated (the length of it is the same as the token generated by aliyundrive API)
Before
After