mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-07-18 00:47:01 +00:00
feature: client: modules: help: migrate to ESM
This commit is contained in:
parent
dc34ee8714
commit
327ac9dee6
4 changed files with 30 additions and 30 deletions
|
|
@ -126,7 +126,7 @@ export default {
|
|||
[`${modules}/edit-names-vim`]: `${dirModules}/edit-names-vim.mjs`,
|
||||
[`${modules}/menu`]: `${dirModules}/menu/index.mjs`,
|
||||
[`${modules}/view`]: `${dirModules}/view/index.mjs`,
|
||||
[`${modules}/help`]: `${dirModules}/help.js`,
|
||||
[`${modules}/help`]: `${dirModules}/help.mjs`,
|
||||
[`${modules}/markdown`]: `${dirModules}/markdown.js`,
|
||||
[`${modules}/config`]: `${dirModules}/config/index.mjs`,
|
||||
[`${modules}/contact`]: `${dirModules}/contact.js`,
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
import Events from '#dom/events';
|
||||
import * as Events from '#dom/events';
|
||||
|
||||
const {CloudCmd} = globalThis;
|
||||
|
||||
|
|
@ -42,4 +42,3 @@ function listener(event) {
|
|||
hide();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,27 +0,0 @@
|
|||
'use strict';
|
||||
|
||||
/* global CloudCmd */
|
||||
CloudCmd.Help = exports;
|
||||
|
||||
const Images = require('#dom/images');
|
||||
|
||||
module.exports.init = () => {
|
||||
Images.show.load('top');
|
||||
};
|
||||
|
||||
module.exports.show = show;
|
||||
module.exports.hide = hide;
|
||||
|
||||
function show() {
|
||||
const positionLoad = 'top';
|
||||
const relative = true;
|
||||
|
||||
CloudCmd.Markdown.show('/HELP.md', {
|
||||
positionLoad,
|
||||
relative,
|
||||
});
|
||||
}
|
||||
|
||||
function hide() {
|
||||
CloudCmd.View.hide();
|
||||
}
|
||||
28
client/modules/help.mjs
Normal file
28
client/modules/help.mjs
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
import * as Images from '#dom/images';
|
||||
|
||||
const {CloudCmd} = globalThis;
|
||||
|
||||
CloudCmd.Help = {
|
||||
init,
|
||||
show,
|
||||
hide,
|
||||
};
|
||||
|
||||
export function init() {
|
||||
Images.show.load('top');
|
||||
}
|
||||
|
||||
export function show() {
|
||||
const positionLoad = 'top';
|
||||
const relative = true;
|
||||
|
||||
CloudCmd.Markdown.show('/HELP.md', {
|
||||
positionLoad,
|
||||
relative,
|
||||
});
|
||||
}
|
||||
|
||||
export function hide() {
|
||||
CloudCmd.View.hide();
|
||||
}
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue