SMF icon indicating copy to clipboard operation
SMF copied to clipboard

quick reply gaining focus on topic view

Open illori opened this issue 12 years ago • 18 comments

when you go to a topic from the message index the quick reply gains focus and you can not go to the newest post or the top of the page without clicking out of the quick reply first.

illori avatar Oct 20 '14 15:10 illori

Confirmed.

NanoSector avatar Oct 21 '14 11:10 NanoSector

I thought I fixed this before.

live627 avatar Oct 21 '14 21:10 live627

a5353cb83ba4a684ddea73d3e9afed655d1a3e25

live627 avatar Oct 21 '14 21:10 live627

well it is still happening with the most recent checkout as of midnight EST today.

illori avatar Oct 21 '14 21:10 illori

Same, site was updated midnight GMT+2.

NanoSector avatar Oct 21 '14 21:10 NanoSector

that commit fixed a different issue. it was not putting focus to the quick reply that i could see at that time and not everyone could duplicate that issue. for example i asked antes to test it on my test install and he could not duplicate that issue.

illori avatar Oct 21 '14 21:10 illori

We enabled autoFocus, https://github.com/SimpleMachines/SMF2.1/blob/release-2.1/Themes/default/scripts/jquery.sceditor.js#L5988 can you disable that and try again?

XinYenFon avatar Oct 21 '14 22:10 XinYenFon

does not fully fix it. the issue that live fixed seems to have returned.

need to also remove the base.blur on 2087 of the same file.

illori avatar Oct 21 '14 22:10 illori

Adding autofocus : false, to the editor instance seems to fix the issue

Why do we need to modify the sceditor.js directly? I would rather prefer not doing that if we can avoid it.

Can't replicate the "other issue" and I have no idea about it, a better description of all the issues may be handy...

MissAllSunday avatar Oct 22 '14 14:10 MissAllSunday

i could always duplicate it on opera or firefox, i would go to a topic new or old and not be at the new reply or top of the topic view.

illori avatar Oct 22 '14 14:10 illori

you could always duplicate what exactly?

Again, I need way more details.

if I click on the "new" link I get redirected to the first new message. Even when using the full editor on quick reply.

MissAllSunday avatar Oct 22 '14 14:10 MissAllSunday

I can reproduce it on my test install which was just updated last night. Firefox 31.1 in openSUSE 31.1 (haven't tested it with Windows or other browsers).

Oldiesmann avatar Oct 22 '14 14:10 Oldiesmann

But exactly WHAT you can reproduce? the "remove blur()" thing or the auto focus one?

MissAllSunday avatar Oct 22 '14 15:10 MissAllSunday

This happens to me as well. Clicking on a topic sends you to quick reply instead of to the first post. If clicking to see the last post in a thread it does the same thing. (Using Firefox)

smfbigguy avatar Oct 22 '14 16:10 smfbigguy

i dont know which version of sceditor we are using but their latest version has autofocus false yet we have it as true.

https://github.com/samclarke/SCEditor/blob/master/src/jquery.sceditor.js#L5987

illori avatar Oct 22 '14 16:10 illori

Doesn't really matter, like I said, it can be solved pretty easily by adding

autofocus : false,

When the editor is initialized.

The "blur();" thing is the one I have no idea about.... no one seems to care to actually EXPLAIN what that issue is or why it is a different issue from the autofocus one...

MissAllSunday avatar Oct 22 '14 16:10 MissAllSunday

the blur issue is when you load the topic and it does not go to the top of the page or to the new message.

https://github.com/SimpleMachines/SMF2.1/issues/2171 explains it somewhat. it seems to not occur for everyone as i had antes test it and he could not duplicate it on my install where 2 of my users could.

illori avatar Oct 22 '14 16:10 illori

The reason for changing autofocus was to auto-focus the editor box on the main reply page (kind of annoying to click reply then have to click inside the box before you can start typing). This seems to be a side-effect of that, so we'll need to find another way to handle that situation.

Oldiesmann avatar Oct 22 '14 18:10 Oldiesmann