HJ_Client/extensions/update_res/dist/main.js
DESKTOP-15R5JU0\legu 62fef0360c init
2023-11-17 14:13:11 +08:00

52 lines
1.5 KiB
JavaScript

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.unload = exports.load = exports.methods = void 0;
const submitTrans_1 = require("./submitTrans");
const updateResources_1 = require("./updateResources");
/**
* @en Registration method for the main process of Extension
* @zh 为扩展的主进程的注册方法
*/
exports.methods = {
updates: async (...args) => {
if (args.includes('json'))
await (0, updateResources_1.updateJson)();
if (args.includes('shared'))
await (0, updateResources_1.updateShared)();
return '更新资源完毕';
},
update_ui: () => {
(0, updateResources_1.updateUi)();
},
update_json: () => {
(0, updateResources_1.updateJson)();
},
update_jsonType: () => {
(0, updateResources_1.updateJsonType)();
},
update_sound: () => {
(0, updateResources_1.updateSound)();
},
update_spine: () => {
(0, updateResources_1.updateSpine)();
},
update_shared() {
(0, updateResources_1.updateShared)();
},
submitTanslation() {
(0, submitTrans_1.SubmitTranslation)();
}
};
/**
* @en Hooks triggered after extension loading is complete
* @zh 扩展加载完成后触发的钩子
*/
function load() { }
exports.load = load;
/**
* @en Hooks triggered after extension uninstallation is complete
* @zh 扩展卸载完成后触发的钩子
*/
function unload() { }
exports.unload = unload;