Jump to content

msg textarea formating for Firefox


No one
 Share

Recommended Posts

The chat box looks and behaves weird to say the least. Comparing Chrome to Firefox:

 


 

Spoiler

This is how it looks in Firefox when opening the page:2021-08-25-Firefox-after-load.PNG.e18dac834883b02758b29675edd06fad.PNG

This is how it looks in Firefox when witing in it :2021-08-25-Firefox-when-writing.PNG.835229796868ba5ebc20e46c0b4e8d46.PNG

This is how it looks in Chrome when opening the page: 2021-08-25-Chrome-after-load.PNG.497c29397bb9bd523b78e8c006131c22.PNG

This is how it looks when witing in Chrome in it 2021-08-25-Chrome-when-writing.PNG.6906fca621406a89ddf4b7fcbe7f681f.PNG


 

It is ugly as s**t, here is a proposal:

Instead of :

<textarea rows="1" cols="30" autocomplete="off" name="msg" class="frm-input-msg" id="msg" style="width:82%; word-break: break-all; resize: none; overflow:" maxlength="200" placeholder="Type your spells or message here..." wrap="hard"></textarea>

use this:

<textarea oninput="this.style.height = '5px'; this.style.height=(this.scrollHeight + 2)+'px'" rows="4" cols="30" autocomplete="off" name="msg" class="frm-input-msg" id="msg" style="width: 82%; word-break: break-all; resize: none; overflow: hidden; height: 19px;" maxlength="200" placeholder="Type your spells or message here..." onload="this.style.height = '5px'; this.style.height=(this.scrollHeight)+'px'" wrap="hard"></textarea>


And the outcome would be :


 

Spoiler

In Firefox with proposed code at load time (hopefully as it can't be 100% at load), already looking smoother:

2021-08-25-Firefox-with_proposal_after-load_hopefully.PNG.ef3ded80e018a86341be4e8817836d3c.PNG

In Chrome with proposed code at load time (hopefully as it can't be 100% at load), it looks identical:
2021-08-25-Chrome-with_proposal_after-load_hopefully.PNG.f54a8e4db842eb40e4b06b9275d81516.PNG

And when writing in it in Firefox :
2021-08-25-Firefox-with_proposal_when-writing.PNG.51f75e6fdbf594a5aba2fea88427ca6d.PNG

And in Chrome :
2021-08-25-Chrome-with_proposal_when-writing.PNG.b1b092f42d44354857a9b5d2faff491e.PNG

 

I hope you can test it in Safari as well, but at least it would improve on these 2 browsers

 

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Forum Statistics

    17k
    Total Topics
    180.3k
    Total Posts
  • Recently Browsing

    • No registered users viewing this page.
  • Upcoming Events

    No upcoming events found
  • Recent Event Reviews

×
×
  • Create New...