Make WordPress Core

Opened 12 years ago

Closed 12 years ago

Last modified 11 years ago

#31163 closed defect (bug) (fixed)

Cannot disable the text editor without auto expand breaking

Reported by: iseulde Owned by: azaozz
Priority: normal Milestone: 4.2
Component: Editor Version: 4.0
Severity: normal Keywords: has-patch
Cc: Focuses: javascript

Description

Test:

add_filter( 'wp_editor_settings', function( $settings, $id ) {
	if ( $id === 'content' ) {
		$settings['quicktags'] = false;
	}

	return $settings;
}, 10, 2 );

We're assuming both editors will be there, but plugins can disable one.
Additionally, the DFW button disappears.

Attachments (1)

31163.patch​ (831 bytes ) - added by iseulde 12 years ago.

Download all attachments as: .zip

Change History (6)

#1 follow-up: @DrewAPicture
12 years ago

  • Keywords reporter-feedback added

I can't confirm that auto-expand breaks –– I tried it before and after and it worked fine both times. I can however confirm that the DFW button disappears. This is latest Firefox if you think that makes a difference.

#2 in reply to: ↑ 1 @SergeyBiryukov
12 years ago

Replying to DrewAPicture:

I can't confirm that auto-expand breaks –– I tried it before and after and it worked fine both times.

Auto-expand seems to work for me as well, but I see a JS error in Debug Bar, in both Firefox and Chrome:

TypeError: $top.parent(...).offset(...) is undefined
http://trunk.wordpress/wp-admin/js/editor-expand.js?ver=4.2-alpha-31308 line 353

#3 @iseulde
12 years ago

  • Keywords has-patch added; reporter-feedback removed
  • Milestone Awaiting Review → 4.2

#4 @azaozz
12 years ago

  • Owner set to azaozz
  • Resolution → fixed
  • Status new → closed

In 31361:

Editor: prevent errors in editor-expand when the Text editor is not used. Props iseulde, fixes #31163.

#5 @iseulde
11 years ago

#31716 was marked as a duplicate.

Note: See TracTickets for help on using tickets.