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

fix(spoolman): break long comments & support multiline comments #1781

Merged

Conversation

mdziekon
Copy link
Contributor

Description

Spoolman allows putting newline characters in the "Comment" field, allowing users to somewhat organize any notes relevant to certain spools (for example, I put the selling vendor name & what was the condition of the spool on arrival).

Currently, Mainsail does not preserve these newline characters, just renders the received comment "as-is" in a plain HTML fashion. This leads to everything being presented in one line, easily overflowing the table & dialog when a lot of notes are added. There's also no line break behavior defined, so even one-liner, long comments cause dialog overflow (see attached screenshot).

However, \n character is nothing special when proper CSS is applied, so this can be easily fixed, which is what this PR does. It should also takes care of long, unbreakable words, which are another case of potential unwanted horizontal overflow.

Related Tickets & Documents

N/A

Mobile & Desktop Screenshots/Recordings

Before:

obraz

After:

obraz

@mdziekon mdziekon changed the title Fix/spoolman preserve newlines fix: Spool long & multiline comments overflow dialog Feb 15, 2024
Signed-off-by: Michał Dziekoński <[email protected]>
@meteyou meteyou changed the title fix: Spool long & multiline comments overflow dialog fix(spoolman): break long comments & support multiline comments Feb 17, 2024
@meteyou meteyou merged commit eaaa19b into mainsail-crew:develop Feb 17, 2024
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.

2 participants