mirror of
https://github.com/Karaka-Management/oms-Editor.git
synced 2026-02-12 08:28:39 +00:00
rector fixes
This commit is contained in:
parent
63bfe63176
commit
ef17aef12e
|
|
@ -293,9 +293,7 @@ final class ApiController extends Controller
|
||||||
*/
|
*/
|
||||||
private function createHistory(EditorDoc $doc) : EditorDocHistory
|
private function createHistory(EditorDoc $doc) : EditorDocHistory
|
||||||
{
|
{
|
||||||
$history = EditorDocHistory::createFromDoc($doc);
|
return EditorDocHistory::createFromDoc($doc);
|
||||||
|
|
||||||
return $history;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
<div id="<?= $this->renderId(); ?>" class="tabview tab-2 m-editor wf-100">
|
<div id="<?= $this->renderId(); ?>" class="tabview tab-2 m-editor wf-100">
|
||||||
<ul class="tab-links">
|
<ul class="tab-links">
|
||||||
<li><label tabindex="0" for="<?= $this->renderId(); ?>-c-tab-1"><?= $this->getHtml('Text', 'Editor'); ?></label>
|
<li><label tabindex="0" for="<?= $this->renderId(); ?>-c-tab-1"><?= $this->getHtml('Text', 'Editor'); ?></label>
|
||||||
<li<?= !empty($this->plain) ? ' class="active"' : ''; ?>><label tabindex="0" for="<?= $this->renderId(); ?>-c-tab-2"><?= $this->getHtml('Preview', 'Editor'); ?></label>
|
<li<?= empty($this->plain) ? '' : ' class="active"'; ?>><label tabindex="0" for="<?= $this->renderId(); ?>-c-tab-2"><?= $this->getHtml('Preview', 'Editor'); ?></label>
|
||||||
</ul>
|
</ul>
|
||||||
<div class="tab-content">
|
<div class="tab-content">
|
||||||
<input type="radio" id="<?= $this->renderId(); ?>-c-tab-1" name="tabular-1"<?= empty($this->plain) ? ' checked' : ''; ?>>
|
<input type="radio" id="<?= $this->renderId(); ?>-c-tab-1" name="tabular-1"<?= empty($this->plain) ? ' checked' : ''; ?>>
|
||||||
|
|
@ -17,7 +17,7 @@
|
||||||
<input type="hidden" id="<?= $this->renderId(); ?>-parsed">
|
<input type="hidden" id="<?= $this->renderId(); ?>-parsed">
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<input type="radio" id="<?= $this->renderId(); ?>-c-tab-2" name="tabular-1"<?= !empty($this->plain) ? ' checked' : ''; ?>>
|
<input type="radio" id="<?= $this->renderId(); ?>-c-tab-2" name="tabular-1"<?= empty($this->plain) ? '' : ' checked'; ?>>
|
||||||
<div class="tab">
|
<div class="tab">
|
||||||
<article data-tpl-text="<?= $this->renderTplText(); ?>" data-tpl-value="<?= $this->renderTplValue(); ?>"><?= $this->renderPreview(); ?></article>
|
<article data-tpl-text="<?= $this->renderTplText(); ?>" data-tpl-value="<?= $this->renderTplValue(); ?>"><?= $this->renderPreview(); ?></article>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,7 @@ echo $this->data['nav']->render(); ?>
|
||||||
<article><?= $doc->content; ?></article>
|
<article><?= $doc->content; ?></article>
|
||||||
<?php if (!empty($tags)) : ?>
|
<?php if (!empty($tags)) : ?>
|
||||||
<?php foreach ($tags as $tag) : ?>
|
<?php foreach ($tags as $tag) : ?>
|
||||||
<span class="tag" style="background: <?= $this->printHtml($tag->color); ?>"><?= !empty($tag->icon) ? '<i class="' . $this->printHtml($tag->icon) . '"></i>' : ''; ?><?= $this->printHtml($tag->getL11n()); ?></span>
|
<span class="tag" style="background: <?= $this->printHtml($tag->color); ?>"><?= empty($tag->icon) ? '' : '<i class="' . $this->printHtml($tag->icon) . '"></i>'; ?><?= $this->printHtml($tag->getL11n()); ?></span>
|
||||||
<?php endforeach; ?>
|
<?php endforeach; ?>
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
<?php if (!empty($files)) : ?>
|
<?php if (!empty($files)) : ?>
|
||||||
|
|
|
||||||
|
|
@ -381,7 +381,7 @@ function phpServe() : void
|
||||||
|
|
||||||
// Execute the command and store the process ID
|
// Execute the command and store the process ID
|
||||||
$output = [];
|
$output = [];
|
||||||
echo \sprintf('Starting server...') . \PHP_EOL;
|
echo 'Starting server...' . \PHP_EOL;
|
||||||
echo \sprintf(' Current directory: %s', \getcwd()) . \PHP_EOL;
|
echo \sprintf(' Current directory: %s', \getcwd()) . \PHP_EOL;
|
||||||
echo \sprintf(' %s', $command);
|
echo \sprintf(' %s', $command);
|
||||||
\exec($command, $output);
|
\exec($command, $output);
|
||||||
|
|
@ -406,7 +406,7 @@ function phpServe() : void
|
||||||
|
|
||||||
// Kill the web server when the process ends
|
// Kill the web server when the process ends
|
||||||
\register_shutdown_function(function() use ($killCommand, $pid) : void {
|
\register_shutdown_function(function() use ($killCommand, $pid) : void {
|
||||||
echo \PHP_EOL . \sprintf('Stopping server...') . \PHP_EOL;
|
echo \PHP_EOL . 'Stopping server...' . \PHP_EOL;
|
||||||
echo \sprintf(' %s - Killing process with ID %d', \date('r'), $pid) . \PHP_EOL;
|
echo \sprintf(' %s - Killing process with ID %d', \date('r'), $pid) . \PHP_EOL;
|
||||||
\exec($killCommand . $pid);
|
\exec($killCommand . $pid);
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user