UCF / WP-Shortcode-Interface

Creates a shortcode interface that provides a form for inserting and updating shortcodes.
0 stars 0 forks source link

Closing tags #7

Closed cjg89 closed 7 years ago

cjg89 commented 7 years ago

Updated the shortcode interface js logic to respect a shortcode class's content property and properly render a closing tag for the shortcode if necessary. Fixes #3.

To do this, I had to update how we store references to various elements in the shortcode interface so that they change based on the selected shortcode--previously, ShortcodeInterface.$fields stored all field elements for all shortcodes; this update changes the $fields reference (now $activeFields) whenever the selected shortcode changes. Coincidentally, this also fixes #6.