diff --git a/serendipity_event_template_editor/serendipity_event_template_editor.css b/serendipity_event_template_editor/serendipity_event_template_editor.css index af9dc7eb..3161a441 100644 --- a/serendipity_event_template_editor/serendipity_event_template_editor.css +++ b/serendipity_event_template_editor/serendipity_event_template_editor.css @@ -1,36 +1,37 @@ -.templateEditorList li { - padding-top: 0.5em; - list-style-type: none; +.templateEditorListItem { + display: inline-block; + padding: .5em; +} + +.templateEditorForm { + margin: .75em 0; } #template_editor { - width: 100%; font-size: 1em; + width: 100%; } .CodeMirror-line-numbers { font-size: 1em; } -img { - border: 0; -} - .templateEditorHighlight { - background: rgba(72,122,202,0.2); + background: rgba(72, 122, 202, .2); border: 1px solid grey; } -#templateEditorUpload { - float: right; - margin-right: 5em; - margin-top: 0.5em; -} +@media only screen and (min-width: 768px) { + .templateEditorForm { + box-sizing: border-box; + float: left; + margin: 0; + padding: 0 1em 0 0; + width: 50%; + } -#templateEditorUploadButton { - border: 1px solid grey; -} - -#templateEditorPath { - margin-top: 0.5em; + #startEditorUpload { + position: relative; + top: 2.25em; + } } \ No newline at end of file diff --git a/serendipity_event_template_editor/serendipity_event_template_editor.php b/serendipity_event_template_editor/serendipity_event_template_editor.php index 18f940d2..add93dad 100644 --- a/serendipity_event_template_editor/serendipity_event_template_editor.php +++ b/serendipity_event_template_editor/serendipity_event_template_editor.php @@ -177,11 +177,7 @@ class serendipity_event_template_editor extends serendipity_event { if (! (serendipity_checkPermission('siteConfiguration'))) { return; } - echo '

- - '. PLUGIN_EVENT_TEMPLATE_EDITOR_START .' - -

'; + echo ''. PLUGIN_EVENT_TEMPLATE_EDITOR_START .''; return true; break; case 'backend_sidebar_entries_event_display_template_editor': @@ -190,17 +186,15 @@ class serendipity_event_template_editor extends serendipity_event { } if (isset($serendipity['GET']['message'])) { - echo '

'.(function_exists('serendipity_specialchars') ? serendipity_specialchars($serendipity['GET']['message']) : htmlspecialchars($serendipity['GET']['message'], ENT_COMPAT, LANG_CHARSET)).'

'; + echo '' . (function_exists('serendipity_specialchars') ? serendipity_specialchars($serendipity['GET']['message']) : htmlspecialchars($serendipity['GET']['message'], ENT_COMPAT, LANG_CHARSET)) . ''; } if (isset($serendipity['GET']['success'])) { - echo '

'.(function_exists('serendipity_specialchars') ? serendipity_specialchars($serendipity['GET']['success']) : htmlspecialchars($serendipity['GET']['success'], ENT_COMPAT, LANG_CHARSET)).'

'; + echo ' ' . (function_exists('serendipity_specialchars') ? serendipity_specialchars($serendipity['GET']['success']) : htmlspecialchars($serendipity['GET']['success'], ENT_COMPAT, LANG_CHARSET)) . ''; } if (isset($serendipity['GET']['error'])) { - echo '

'.(function_exists('serendipity_specialchars') ? serendipity_specialchars($serendipity['GET']['error']) : htmlspecialchars($serendipity['GET']['error'], ENT_COMPAT, LANG_CHARSET)).'

'; + echo ' ' . (function_exists('serendipity_specialchars') ? serendipity_specialchars($serendipity['GET']['error']) : htmlspecialchars($serendipity['GET']['error'], ENT_COMPAT, LANG_CHARSET)) . ''; } - - #only necessary for delivering the javascript and css $pluginPath = $this->pluginPath = $this->get_config('path', ''); if (empty($pluginPath) || $pluginPath == 'default' || $pluginPath == 'none' || $pluginPath == 'empty') { @@ -223,13 +217,13 @@ class serendipity_event_template_editor extends serendipity_event { $path = $serendipity['GET']['template_editor_path']; } if ($this->forkTemplate()) { + $this->showFiles($path); + $this->showDirectories($path); if (isset($serendipity['GET']['template_editor_upload'])) { $this->showUploader($path, true); } else { $this->showUploader($path, false); } - $this->showFiles($path); - $this->showDirectories($path); $this->showCreator($path); } @@ -260,21 +254,22 @@ class serendipity_event_template_editor extends serendipity_event { $path = $template_path . $cur_template . '/'; } if ($form) { - echo '

'.PLUGIN_EVENT_TEMPLATE_EDITOR_UPLOAD.'

-
- - - -
'; + echo '
+ +
+ + + +
+
'; } else { - echo '
-
- - - - - -
'; + echo '
+ + + + + +
'; } } @@ -286,12 +281,14 @@ class serendipity_event_template_editor extends serendipity_event { if (!$path) { $path = $template_path . $cur_template . '/'; } - echo '

'.CREATE.'

-
- - - -
'; + echo '
+ +
+ + + +
+
'; } function showEditor($path , $temp=false) { @@ -313,11 +310,13 @@ class serendipity_event_template_editor extends serendipity_event { $heading = $this->linkify("?&serendipity[adminModule]=event_display&serendipity[adminAction]=template_editor&serendipity[template_editor_path]=", $path, $serendipity['template']); - echo '

'.$heading.'

+ echo '

' . $heading . '

- - - + + +
+ +
'; } @@ -334,31 +333,31 @@ class serendipity_event_template_editor extends serendipity_event { $heading = $this->linkify("?&serendipity[adminModule]=event_display&serendipity[adminAction]=template_editor&serendipity[template_editor_path]=", $path, $cur_template); - echo '

'. $heading.'

'; + echo '

' . $heading . '

'; if (empty($files)) { return; } - echo '