mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 02:35:49 +00:00
fix(route) showKeysPanel
This commit is contained in:
parent
99e022728d
commit
868c424f52
1 changed files with 5 additions and 3 deletions
|
|
@ -53,7 +53,8 @@ module.exports = (req, res, next) => {
|
|||
* additional processing of index file
|
||||
*/
|
||||
function indexProcessing(options) {
|
||||
const keysPanel = '<div id="js-keyspanel" class="{{ className }}';
|
||||
const keysPanel = '<div id="js-keyspanel" class="{{ className }}"';
|
||||
const keysPanelRegExp = '<div id="?js-keyspanel"? class="?{{ className }}"?';
|
||||
const isOnePanel = config('onePanelMode');
|
||||
const noConfig = !config('configDialog');
|
||||
const noConsole = !config('console');
|
||||
|
|
@ -64,8 +65,9 @@ function indexProcessing(options) {
|
|||
|
||||
let from;
|
||||
let to;
|
||||
|
||||
if (!config('showKeysPanel')) {
|
||||
from = rendy(keysPanel, {
|
||||
from = rendy(keysPanelRegExp, {
|
||||
className: 'keyspanel'
|
||||
});
|
||||
|
||||
|
|
@ -73,7 +75,7 @@ function indexProcessing(options) {
|
|||
className: 'keyspanel hidden'
|
||||
});
|
||||
|
||||
data = data.replace(from, to);
|
||||
data = data.replace(RegExp(from), to);
|
||||
}
|
||||
|
||||
if (isOnePanel)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue