Skip to:
Content

bbPress.org

Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#1917 closed defect (fixed)

tabindex issue on new topic form

Reported by: jaredatch Owned by: ethitter
Milestone: 2.3 Priority: low
Severity: normal Version: 2.1
Component: Appearance - Theme Compatibility Keywords: has-patch
Cc: stephen@…, wordpress@…, erick@…

Description

Thought there was a ticket open for this already, but I can't find it.

When on the new topic form, tabbing will jump from the title to the tags, skipping over the body. It's not a show stopper but definitely annoying.

I've done some investigating but haven't figured out why this is happening. Everything works fine in the admin and tinymce on the front end is loading the same TinyMCE plugins (including the one for tabindex support) as the backend - so it *should* be working. But it isn't.

Attachments (3)

1917.patch (2.8 KB) - added by ethitter 8 years ago.
1917.2.patch (4.4 KB) - added by johnjamesjacoby 8 years ago.
Removes extra theme compat helper JS
1917.3.patch (1.8 KB) - added by ethitter 8 years ago.
Handling tabbing out of the Visual Editor

Download all attachments as: .zip

Change History (25)

#1 @johnjamesjacoby
8 years ago

Oddly enough, this works if the HTML tab is selected, but not Visual. More than likely it's due to the iframe, but WordPress core pulls it off in wp-admin, presumably with some additional JS somewhere.

Possibly related: #WP20834

#2 @johnjamesjacoby
8 years ago

  • Milestone changed from Awaiting Review to 2.2

#3 @netweb
8 years ago

  • Cc stephen@… added

I think this is the ticket your referring to:

http://bbpress.trac.wordpress.org/ticket/1407 'Tabindex attribute causing issues'

#4 @MZAWeb
8 years ago

  • Cc wordpress@… added

#5 @johnjamesjacoby
8 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [4513]) TinyMCE:

  • Fix tabbing from topic title.
  • Hat-tip MZAWeb.
  • Fixes #1917.

#6 @MZAWeb
8 years ago

  • Keywords needs-patch added
  • Resolution fixed deleted
  • Status changed from closed to reopened

We need to make sure jQuery is enqueued where this script is included.

#7 @johnjamesjacoby
8 years ago

  • Owner set to johnjamesjacoby
  • Status changed from reopened to new

#8 @jaredatch
8 years ago

The other part of the conversation was talking about loading order, which possibly could be an issue (jQuery in the footer and the script output in the header).

@ethitter
8 years ago

#9 follow-up: @ethitter
8 years ago

  • Cc erick@… added
  • Keywords has-patch added; needs-patch removed

When the full TinyMCE editor is used, wp_editor() enables the tab focus plugin. The same is not done for the teeny editor, which bbPress uses by default.

1917.patch turns on the tab focus plugin when bbp_get_the_content() calls wp_editor().

bbp_get_the_content() will also accept TinyMCE's tabfocus_elements argument now, passing it to the editor instance so one can be explicit about the tab order if needed.

@johnjamesjacoby
8 years ago

Removes extra theme compat helper JS

#11 in reply to: ↑ 9 ; follow-up: @johnjamesjacoby
8 years ago

Replying to ethitter:

Oddly enough, it still doesn't work without the additional theme-compat JS. Attached patch even tries to use explicit class names for the previous and next items, with no success. Thoughts?

#12 follow-up: @MZAWeb
8 years ago

After last dev chat, I'm doing a little patch to move the in-line JS to a .js file and enqueuing with jQuery as a dep.

Still needed, right?

#13 in reply to: ↑ 12 @johnjamesjacoby
8 years ago

Replying to MZAWeb:

After last dev chat, I'm doing a little patch to move the in-line JS to a .js file and enqueuing with jQuery as a dep.

Still needed, right?

Should not be, if I understand the purpose of tabfocus correctly. It's just that it's still not working. :)

#14 @johnjamesjacoby
8 years ago

(In [4576]) Iterate on #1917.

  • Remove fullscreen editor from teeny editor buttons.
  • Introduce tabfocus plugin, with some approximate values.
  • Props ethitter.
  • Note: theme-side tinymce tabfocus still not working as intended.

#15 follow-up: @MZAWeb
8 years ago

Does it not work when you get jQuery enqueued _before_ the inline script? Works for me...

#16 @johnjamesjacoby
8 years ago

(In [4577]) Do not use hashes in tabfocus_elements array values. See #1917.

#17 in reply to: ↑ 15 @johnjamesjacoby
8 years ago

Replying to MZAWeb:

Does it not work when you get jQuery enqueued _before_ the inline script? Works for me...

The above tabfocus_elements fixes tabbing out-of TinyMCE, but not tabbing into it. If you wanted to write up the JS to enqueue a small JS file if we're using the fancy editor, that includes part of what was reverted in r4576, plus the same for reverse tabbing from the topic-tags input area, should fix this completely.

#18 in reply to: ↑ 11 ; follow-up: @ethitter
8 years ago

Replying to johnjamesjacoby:

Replying to ethitter:

Oddly enough, it still doesn't work without the additional theme-compat JS. Attached patch even tries to use explicit class names for the previous and next items, with no success. Thoughts?

Interesting. I honestly didn't try it without the additional JS.

I can take another look this weekend if MZAWeb doesn't beat me to it.

#19 in reply to: ↑ 18 @johnjamesjacoby
8 years ago

  • Owner changed from johnjamesjacoby to ethitter

Replying to ethitter:

I can take another look this weekend if MZAWeb doesn't beat me to it.

MZAWeb is out until after holiday, so it's all yours.

#20 @johnjamesjacoby
8 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [4632]) Allow tabbing into and out of TinyMCE. Fixes #1917.

@ethitter
8 years ago

Handling tabbing out of the Visual Editor

#21 follow-up: @ethitter
8 years ago

1917.3.patch uses TinyMCE's method for catching keypresses to handle tabbing out of the editor. Even with the changes from r4632, tabbing wasn't consistently working for me.

Trying to shift+tab from the Topic Tags back to the editor still doesn't work properly though. Rather than return to the editor, I end up back in the Topic Title field. But we're getting closer.

#22 in reply to: ↑ 21 @ethitter
8 years ago

Replying to ethitter:

Trying to shift+tab from the Topic Tags back to the editor still doesn't work properly though. Rather than return to the editor, I end up back in the Topic Title field. But we're getting closer.

Ignore me. I was testing with a checkout from the plugin repo, not the bbPress repo.

Note: See TracTickets for help on using tickets.