@@ -94,12 +94,12 @@ discard block |
||
| 94 | 94 | |
| 95 | 95 | if (is_a($form, \dokuwiki\Form\Form::class)) { |
| 96 | 96 | $form->addElement($this->buildToggleButton(), 0); |
| 97 | - $form->setHiddenField('prosemirror_json',$prosemirrorJSON); |
|
| 97 | + $form->setHiddenField('prosemirror_json', $prosemirrorJSON); |
|
| 98 | 98 | $form->addHTML('<div class="prosemirror_wrapper" id="prosemirror__editor"></div>', 1); |
| 99 | 99 | } else { |
| 100 | 100 | // todo remove when old stable is no longer supported |
| 101 | 101 | $form->insertElement(0, $this->buildOldToggleButton()); |
| 102 | - $form->addHidden('prosemirror_json',$prosemirrorJSON); |
|
| 102 | + $form->addHidden('prosemirror_json', $prosemirrorJSON); |
|
| 103 | 103 | $form->insertElement(1, '<div class="prosemirror_wrapper" id="prosemirror__editor"></div>'); |
| 104 | 104 | } |
| 105 | 105 | } |
@@ -180,7 +180,7 @@ discard block |
||
| 180 | 180 | 'id' => 'prosemirror-linkform', |
| 181 | 181 | 'style' => 'display: none;', |
| 182 | 182 | ]); |
| 183 | - $linkForm->addFieldsetOpen('Links')->addClass('js-link-fieldset');; |
|
| 183 | + $linkForm->addFieldsetOpen('Links')->addClass('js-link-fieldset'); ; |
|
| 184 | 184 | $iwOptions = array_keys(getInterwiki()); |
| 185 | 185 | $linkForm->addDropdown('iwshortcut', $iwOptions, 'InterWiki')->attr('required', 'required'); |
| 186 | 186 | |
@@ -67,7 +67,9 @@ |
||
| 67 | 67 | $form = $event->data; |
| 68 | 68 | |
| 69 | 69 | // return early if content is not editable |
| 70 | - if ($this->isReadOnly($form)) return; |
|
| 70 | + if ($this->isReadOnly($form)) { |
|
| 71 | + return; |
|
| 72 | + } |
|
| 71 | 73 | |
| 72 | 74 | |
| 73 | 75 | $useWYSIWYG = get_doku_pref('plugin_prosemirror_useWYSIWYG', false); |