Closed Bug 1604144 Opened 4 years ago Closed 4 years ago

_moz_resizing="true" disappeared from 64.0 onwards

Categories

(Core :: DOM: Editor, defect)

71 Branch
defect
Not set
normal

Tracking

()

RESOLVED WONTFIX

People

(Reporter: matteo.sindona, Unassigned)

References

(Regression)

Details

(Keywords: regression)

Attachments

(1 file)

Attached image December1.png

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:71.0) Gecko/20100101 Firefox/71.0

Steps to reproduce:

Go here: https://totallympics.com/index.php?/topic/16-test-thread/&do=editComment&comment=17781 and login with the following details:

Username: test
Password: test

Open one page with a Firefox version BEFORE 64.0 and one page with a Firefox version from 64.0 onwards (the latest Firefox version will be ok as well). Click on any cell of the table you see in the editor.

Actual results:

As you can see in the attached screenshot, with Firefox 63.0 I can see the symbols to add/remove rows/columns and to resize the table. These symbols were there since the very first versions of Firefox until version 63.0 included, but they are not there anymore from version 64.0 onwards.

Opening the inspector, I see that the "_moz_resizing="true"" is missing from version 64.0.

Expected results:

I want to see the resizer also in 64.0 (and onwards) versions, how can I do to do that? I have solved a similar problem on another website adding this in the editor.js file:
setTimeout(() => {
editdoc.execCommand("enableObjectResizing", false, true);
editdoc.execCommand("enableInlineTableEditing", false, true);
}, 0);

But I do not know where to add this on this website. Can you please help me?

Thank you very much!

Summary: _moz_resizing="true" disappeard from 64.0 onwards → _moz_resizing="true" disappeared from 64.0 onwards

Hi,
Thanks for submitting this bug to us!

I was unable to reproduce this issue on my end, I tried on Windows 10, with Firefox Nightly version 63.0 (64-bit) and 73
When trying your website, Version 63.0 only allows resizing table from the right column (and not from all around the table as shown in attached screenshot), and the symbols to add/remove rows/columns are not appearing either.
I've already chosen a component for this bug in hope that someone with more expertise may look at it. We'll await their answer.

Thanks in advance.
Best regards, Jero.

Flags: needinfo?(matteo.sindona)
Component: Untriaged → Layout: Tables
Product: Firefox → Core

Hello Jeronimo, thank you for your answer!

I have never tried using a Firefox Nightly version so I'm not sure the behaviour is the same.

Could you please try with an official release of Firefox and let me know if the behaviour is like how I described? I have tried from 2 different computers and the result is the same.

Thank you!

Matteo

Component: Layout: Tables → Untriaged
Flags: needinfo?(matteo.sindona)
Product: Core → Firefox
Component: Untriaged → DOM: Editor
Product: Firefox → Core

This was an intentional change, see bug 1449564. You can opt-into it using execCommand, see there for the details.

Status: UNCONFIRMED → RESOLVED
Closed: 4 years ago
Regressed by: 1449564
Resolution: --- → WONTFIX
Has Regression Range: --- → yes
Keywords: regression

Hello Emilio, thank you very much for the answer!
I'm not that good in these stuff, could you please explain me step by step how can I add the execCommand to all the pages so that I can see the resizer in all the pages ? I have access to the site's files so you can tell me which file I have to edit and what and where to add that.

I know this is not related to Mozilla anymore but I would be extremely grateful if you will help me with that.

Thank you and merry Chrismtas!

I think adding this to that page should work:

window.addEventListener("load", function() {
  document.execCommand("enableObjectResizing", false, true);
  document.execCommand("enableInlineTableEditing", false, true);
});

inside <script> tags, so:

<script>
window.addEventListener("load", function() {
  document.execCommand("enableObjectResizing", false, true);
  document.execCommand("enableInlineTableEditing", false, true);
});
</script>

Hello Emilio.

I would need to make it work in all the pages of the website, not only that one I sent as an example.

So in which file should I add this ? Could you locate the correct file ?

Thank you again!

I don't know how the website is structured internally, so cannot point you at a concrete file. I'd look at how the google analytics script is injected for example. All these sites have templates where you can drop common code for all pages. But if you're just a user you can't see them, you can just see the full thing.

Hello Emilio,

yes I can edit the "globalTemplate" file where I can drop common code for all pages. I wasn't sure where exactly to put what you suggested me so I put it just before the end of the "</head> tag.

Now this is something strange: the first time I have tried it worked, I had the resizers on the latest Firefox version! But after I updated the page they were not there anymore. How is that possible ? Maybe I have to use something similar to the "timeout" someone suggested for my other website ? https://bugzilla.mozilla.org/show_bug.cgi?id=1531435#c24

Anyway you can open the test link again now, do you see the script in the page?

Thank you!

(In reply to matteo.sindona from comment #9)

Hello Emilio,

yes I can edit the "globalTemplate" file where I can drop common code for all pages. I wasn't sure where exactly to put what you suggested me so I put it just before the end of the "</head> tag.

document.execCommand needs to be called after designMode or contenteditable is set. I guess that in most cases, it should work after load event. I meant that call it with setTimeout(() => { ... }, 0); if simply adding load event listener which emilio suggested does not work.

(In reply to matteo.sindona from comment #7)

I would need to make it work in all the pages of the website, not only that one I sent as an example.

You can do it only for you with setting editor.inline_table_editing.enabled_by_default to true and editor.resizing.enabled_by_default to true in about:config. However, all web apps which do not enable these features explicitly may have trouble with resizing <table> elements. So, I don't recommend to change these settings. And note that these prefs are added for enterprise users if it's difficult to change their apps by some reasons. Therefore, in the future, these prefs may be removed.

Hello Masayuki ! Thank you very much ! I have tried to change those two values from the about:config and it works!

Is there a way to make it work for everyone though ? Could you please explain me which file should I edit?

Thank you!

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: