getgrav / getgrav/grav-plugin-admin

Editor field in fieldset field makes codemirrror css breaks

Open
#1,673 0 comments 0 reactions 0 assignees View on GitHub
ui
Dominant language
PHP
Stars
377
Forks
225
Avg merge
11h 51m
Merged PRs (30d)
4

Description

This `editor` field is not wrapped inside `fieldset`, no issue at all
![t](https://i.ibb.co/H7TdrSP/Capture-d-e-cran-2019-05-07-a-11-57-07.png)

This one is inside `fieldset` field, on first load, the editor is black and when you click inside the `code`appears but with css issues (`linenumbers`)
![](https://i.ibb.co/H41S2C9/Capture-d-e-cran-2019-05-07-a-11-57-14.png)

you can test with :
````
form:
fields:
general:
type: section
title: 'Image'
underline: true
fields:
header.test_editor:
type: editor
label: 'HTML'
autofocus: true
codemirror:
mode: 'text/html'
theme: 'monokai'
indentUnit: 4
autofocus: true
indentWithTabs: false
lineNumbers: true
styleActiveLine: true
gutters: ['CodeMirror-lint-markers']
lint: false
header.el_media_options:
type: fieldset
title: 'Image'
icon: tv
collapsed: true
collapsible: true
fields:
header.el_image_basic_svg_overlay_editor:
type: editor
label: 'HTML'
autofocus: true
codemirror:
mode: 'text/html'
theme: 'monokai'
indentUnit: 4
autofocus: true
indentWithTabs: false
lineNumbers: true
styleActiveLine: true
lint: false
````

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.