mirror of
https://github.com/HugoAura/Seewo-HugoAura.git
synced 2026-06-25 18:54:29 +08:00
[Feat] Bump version to 0.1.0-beta && 1st rel
This commit is contained in:
@@ -0,0 +1,409 @@
|
||||
/* General */
|
||||
|
||||
#aura-container-Aura-UI-Assistant-Config {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
z-index: 1000;
|
||||
}
|
||||
|
||||
.aura-config-page-root {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
background: url("../../../../app.asar/public/ae247697b4639c92bd008d0ea7d13b53.png");
|
||||
/* 这里不用 background-size: cover; 的效果反而更舒服一些... */
|
||||
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
|
||||
opacity: 1;
|
||||
transform: scale(1);
|
||||
|
||||
transition: all 0.5s;
|
||||
}
|
||||
|
||||
.aura-config-page-root-inactive {
|
||||
opacity: 0;
|
||||
transform: scale(1.5);
|
||||
}
|
||||
|
||||
/* Header */
|
||||
|
||||
.aura-config-page-header-area {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: flex-start;
|
||||
width: 100%;
|
||||
padding-left: 8px;
|
||||
padding-right: 8px;
|
||||
color: white;
|
||||
|
||||
opacity: 1;
|
||||
transform: translateY(0);
|
||||
|
||||
transition: all 0.5s;
|
||||
}
|
||||
|
||||
.aura-config-page-header-area .iconfont {
|
||||
font-size: 24px;
|
||||
|
||||
transition: all 0.25s;
|
||||
}
|
||||
|
||||
.aura-config-page-header-area .iconfont:hover {
|
||||
opacity: 0.75;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.aura-config-page-header-area .iconfont:active {
|
||||
opacity: 0.375;
|
||||
}
|
||||
|
||||
.aura-config-page-header-area p {
|
||||
margin-top: -2px;
|
||||
}
|
||||
|
||||
.aura-config-page-header-area.header-collapsed {
|
||||
transform: translateY(-1rem);
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
.aura-config-page-app-bar {
|
||||
height: 40px;
|
||||
display: flex;
|
||||
justify-content: flex-start;
|
||||
align-items: center;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
/* Status */
|
||||
|
||||
.aura-config-page-status-container {
|
||||
flex: 1;
|
||||
width: 100%;
|
||||
align-self: center;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
|
||||
opacity: 1;
|
||||
|
||||
transition: all 0.5s;
|
||||
}
|
||||
|
||||
.aura-config-page-status-container-hidden {
|
||||
position: absolute;
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
.aura-config-page-status-main,
|
||||
.aura-config-page-status-description {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.aura-config-page-status-description {
|
||||
margin-top: 0.5rem;
|
||||
transform: translateY(0);
|
||||
opacity: 1;
|
||||
|
||||
transition: all 0.5s;
|
||||
}
|
||||
|
||||
.aura-config-page-status-description.status-description-hidden {
|
||||
transform: translateY(-2rem);
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
.aura-config-page-status-description p {
|
||||
font-size: 18px;
|
||||
margin-left: 15px;
|
||||
margin-top: -2px;
|
||||
color: white;
|
||||
font-family: "Consolas", "Microsoft YaHei", sans-serif;
|
||||
}
|
||||
|
||||
.aura-config-page-status-description i {
|
||||
color: white;
|
||||
}
|
||||
|
||||
.aura-config-page-central-aura-logo {
|
||||
margin: 0.5rem 3rem;
|
||||
width: 17.5%;
|
||||
}
|
||||
|
||||
.aura-config-hr-vertical {
|
||||
height: 3.75rem;
|
||||
width: 1px;
|
||||
background-color: rgba(255, 255, 255, 0.3);
|
||||
margin-left: 30px;
|
||||
margin-right: 30px;
|
||||
border: none;
|
||||
}
|
||||
|
||||
.aura-config-page-status-el {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
font-family: "Consolas", monospace;
|
||||
color: white;
|
||||
|
||||
/*
|
||||
.version-type {
|
||||
content: "I want to use scss plz 😇"
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
.aura-config-page-status-side {
|
||||
height: 30%;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
flex: 1;
|
||||
|
||||
transform: translateX(0);
|
||||
opacity: 1;
|
||||
|
||||
transition: transform 0.5s, opacity 0.5s;
|
||||
}
|
||||
|
||||
.aura-config-page-status-side.left-side {
|
||||
justify-content: flex-end;
|
||||
}
|
||||
|
||||
.aura-config-page-status-side.left-side.status-side-hidden {
|
||||
transform: translateX(5rem);
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
.aura-config-page-status-side.right-side {
|
||||
justify-content: flex-start;
|
||||
}
|
||||
|
||||
.aura-config-page-status-side.right-side.status-side-hidden {
|
||||
transform: translateX(-5rem);
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
.aura-config-page-status-el .version-type {
|
||||
font-size: 20px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.aura-config-page-status-el .version-content {
|
||||
font-size: 16px;
|
||||
margin-top: 5px;
|
||||
opacity: 0.625;
|
||||
}
|
||||
|
||||
/* Operation */
|
||||
|
||||
.aura-config-page-operation-area {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: flex-end;
|
||||
flex: 1;
|
||||
width: 100%;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-area::-webkit-scrollbar {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-area.subpage-expanded {
|
||||
flex: 15;
|
||||
}
|
||||
|
||||
.aura-config-page-subpage-container {
|
||||
width: 100%;
|
||||
height: 0;
|
||||
background-color: rgba(255, 255, 255, 0.825);
|
||||
z-index: 6000;
|
||||
overflow-y: scroll;
|
||||
|
||||
opacity: 0;
|
||||
|
||||
transition: all 0.5s;
|
||||
}
|
||||
|
||||
.aura-config-page-subpage-container::-webkit-scrollbar {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-area.subpage-expanded
|
||||
.aura-config-page-subpage-container {
|
||||
height: calc(100% - 40px - 4rem);
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-container {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 100%;
|
||||
background-color: rgba(255, 255, 255, 0.1);
|
||||
padding-left: 1rem;
|
||||
padding-right: 1rem;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-container.hide-other-operations
|
||||
.aura-config-page-operation-el:not(.preserve-operation) {
|
||||
max-width: 0;
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-container.hide-other-operations
|
||||
.aura-config-page-operation-el.preserve-operation {
|
||||
flex: 0.25;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
flex: 1;
|
||||
padding-top: 2rem;
|
||||
padding-bottom: 2rem;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
|
||||
max-width: 25%;
|
||||
opacity: 1;
|
||||
transform: translateY(0);
|
||||
|
||||
transition: opacity 0.5s, transform 0.5s,
|
||||
max-width cubic-bezier(0, 0.42, 0.18, 1) 0.5s;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el.operation-el-show:hover {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el.operation-el-show[aura-disabled="true"]:hover {
|
||||
cursor: not-allowed;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el.operation-el-hidden {
|
||||
transform: translateY(2rem);
|
||||
opacity: 0;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el.operation-el-show
|
||||
.aura-config-page-operation-body {
|
||||
opacity: 1;
|
||||
transition: opacity 0.25s;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el.operation-el-show[aura-disabled="true"]
|
||||
.aura-config-page-operation-body {
|
||||
transition: opacity 0.5s;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el.operation-el-show:not(.preserve-operation):hover
|
||||
.aura-config-page-operation-body {
|
||||
opacity: 0.625;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el.operation-el-show[aura-disabled="true"]:hover
|
||||
.aura-config-page-operation-body {
|
||||
opacity: 0.25;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el.operation-el-show:not(.preserve-operation):active
|
||||
.aura-config-page-operation-body {
|
||||
opacity: 0.25;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el.operation-el-show[aura-disabled="true"]::after {
|
||||
content: "别急嘛, 还在开发呢...";
|
||||
font-size: 16px;
|
||||
opacity: 0;
|
||||
color: white;
|
||||
position: absolute;
|
||||
|
||||
transition: all 0.5s;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el.operation-el-show[aura-disabled="true"]:hover::after,
|
||||
.aura-config-page-operation-el.operation-el-show[aura-disabled="true"]:active::after {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-body {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el img {
|
||||
max-width: 40px;
|
||||
margin-right: 20px;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el .config-operation-title {
|
||||
color: white;
|
||||
font-size: large;
|
||||
}
|
||||
|
||||
.aura-config-page-operation-el .config-operation-description {
|
||||
color: white;
|
||||
opacity: 0.75;
|
||||
font-size: small;
|
||||
}
|
||||
|
||||
/* Toast */
|
||||
|
||||
.aura-config-page-toast-area {
|
||||
z-index: 9000;
|
||||
}
|
||||
|
||||
.aura-config-page-toast-area .toast {
|
||||
--bs-toast-border-width: 0 !important;
|
||||
--bs-toast-bg: #fff !important;
|
||||
}
|
||||
|
||||
.aura-config-page-toast-area .toast-header {
|
||||
background-color: rgb(255, 234, 202);
|
||||
|
||||
border-top-left-radius: var(--bs-toast-border-radius);
|
||||
border-top-right-radius: var(--bs-toast-border-radius);
|
||||
}
|
||||
|
||||
.aura-config-page-toast-area .toast.acp-toast-emerg .toast-header {
|
||||
background-color: rgb(255, 202, 202);
|
||||
}
|
||||
|
||||
.aura-config-page-toast-area .toast-header * {
|
||||
color: rgba(234, 126, 14, 0.85);
|
||||
}
|
||||
|
||||
.aura-config-page-toast-area .toast.acp-toast-emerg .toast-header * {
|
||||
color: rgba(234, 65, 14, 0.85);
|
||||
}
|
||||
|
||||
.aura-config-page-toast-area .toast-body p {
|
||||
margin-bottom: var(--bs-toast-padding-x);
|
||||
}
|
||||
|
||||
.aura-config-page-toast-area .toast-header .layui-icon {
|
||||
font-weight: bolder;
|
||||
margin-right: 0.5rem;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,166 @@
|
||||
<div class="aura-config-page-root-inactive aura-config-page-root">
|
||||
<div class="header-collapsed aura-config-page-header-area">
|
||||
<div class="aura-config-page-app-bar" style="-webkit-app-region: drag">
|
||||
<div
|
||||
onclick="global.__HUGO_AURA_UI_FUNCTIONS__.config.handleNavBack()"
|
||||
style="-webkit-app-region: no-drag; z-index: 2000"
|
||||
>
|
||||
<i class="iconfont"></i>
|
||||
</div>
|
||||
<p>雨光之环</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="aura-config-page-status-container">
|
||||
<div class="aura-config-page-status-main">
|
||||
<div
|
||||
class="aura-config-page-status-side left-side status-side-hidden"
|
||||
id="leftStatusContainer"
|
||||
>
|
||||
<div class="aura-config-page-status-el">
|
||||
<p class="version-type">Node</p>
|
||||
<p class="version-content" id="nodeVersion">
|
||||
v{{ versionInfo.node }}
|
||||
</p>
|
||||
<!-- I want to use Vue plz 😭😭😭 -->
|
||||
</div>
|
||||
<hr class="aura-config-hr-vertical" />
|
||||
<div class="aura-config-page-status-el">
|
||||
<p class="version-type">Electron</p>
|
||||
<p class="version-content" id="electronVersion">
|
||||
v{{ versionInfo.electron }}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<img
|
||||
src="../../aura/ui/static/aura.svg"
|
||||
class="aura-config-page-central-aura-logo"
|
||||
/>
|
||||
|
||||
<div
|
||||
class="aura-config-page-status-side right-side status-side-hidden"
|
||||
id="rightStatusContainer"
|
||||
>
|
||||
<div class="aura-config-page-status-el">
|
||||
<p class="version-type">Hugo</p>
|
||||
<p class="version-content" id="hugoVersion">
|
||||
v{{ versionInfo.hugo }}
|
||||
</p>
|
||||
</div>
|
||||
<hr class="aura-config-hr-vertical" />
|
||||
<div class="aura-config-page-status-el">
|
||||
<p class="version-type">Aura</p>
|
||||
<p class="version-content" id="auraVersion">
|
||||
v{{ versionInfo.aura }}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="status-description-hidden aura-config-page-status-description">
|
||||
<i class="layui-icon layui-icon-ok" style="font-size: 24px"></i>
|
||||
<p>HugoAura 正常运行中</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="aura-config-page-operation-area">
|
||||
<div class="aura-config-page-subpage-container"></div>
|
||||
<div class="aura-config-page-operation-container">
|
||||
<div
|
||||
class="operation-el-hidden aura-config-page-operation-el"
|
||||
onclick="window.__HUGO_AURA_UI_FUNCTIONS__.config.toggleSubConfig('disableLimitations', true)"
|
||||
>
|
||||
<div class="aura-config-page-operation-body">
|
||||
<img src="../../aura/ui/static/config/no_limitations.svg" />
|
||||
<div>
|
||||
<p class="config-operation-title">限制解除</p>
|
||||
<p class="config-operation-description">禁用密码、关闭冰点</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="operation-el-hidden aura-config-page-operation-el"
|
||||
aura-disabled="true"
|
||||
>
|
||||
<div class="aura-config-page-operation-body">
|
||||
<img src="../../aura/ui/static/config/behaviour_mon.svg" />
|
||||
<div>
|
||||
<p class="config-operation-title">行为管控</p>
|
||||
<p class="config-operation-description">窥屏提醒、数据欺骗</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div
|
||||
class="operation-el-hidden aura-config-page-operation-el"
|
||||
aura-disabled="true"
|
||||
>
|
||||
<div class="aura-config-page-operation-body">
|
||||
<img src="../../aura/ui/static/config/plugin.svg" />
|
||||
<div>
|
||||
<p class="config-operation-title">插件管理</p>
|
||||
<p class="config-operation-description">插件列表、安装插件</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="operation-el-hidden aura-config-page-operation-el">
|
||||
<div class="aura-config-page-operation-body">
|
||||
<img src="../../aura/ui/static/config/about.svg" />
|
||||
<div>
|
||||
<p class="config-operation-title">关于项目</p>
|
||||
<p class="config-operation-description">使用文档、获取帮助</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="aura-config-page-toast-area">
|
||||
<div class="toast-container position-fixed bottom-0 end-0 p-3">
|
||||
<div
|
||||
id="reloadNotifyToast"
|
||||
class="toast"
|
||||
aria-atomic="true"
|
||||
data-bs-autohide="false"
|
||||
>
|
||||
<div class="toast-header">
|
||||
<i class="layui-icon layui-icon-tips"></i>
|
||||
<strong class="me-auto">重载页面以应用设置</strong>
|
||||
</div>
|
||||
<div class="toast-body">
|
||||
<p>请重载当前窗口以应用修改的设置</p>
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-primary btn-sm"
|
||||
onclick="window.location.reload()"
|
||||
>
|
||||
重载页面
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="toast-container position-fixed bottom-0 end-0 p-3">
|
||||
<div
|
||||
id="relaunchNotifyToast"
|
||||
class="toast acp-toast-emerg"
|
||||
aria-atomic="true"
|
||||
data-bs-autohide="false"
|
||||
>
|
||||
<div class="toast-header">
|
||||
<i class="layui-icon layui-icon-tips"></i>
|
||||
<strong class="me-auto">重启进程以应用设置</strong>
|
||||
</div>
|
||||
<div class="toast-body">
|
||||
<p>请重启 Electron 进程以应用修改的设置</p>
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-primary btn-sm"
|
||||
onclick="ipcRenderer.invoke('$aura.base.restartApplication')"
|
||||
>
|
||||
重启进程
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -0,0 +1,180 @@
|
||||
global.__HUGO_AURA_UI_REACTIVES__.config = {
|
||||
isInSubPage: false,
|
||||
currentActiveSubPage: "",
|
||||
};
|
||||
|
||||
global.__HUGO_AURA_UI_FUNCTIONS__.config = {
|
||||
handleNavBack: () => {
|
||||
if (global.__HUGO_AURA_UI_REACTIVES__.config.isInSubPage) {
|
||||
global.__HUGO_AURA_UI_FUNCTIONS__.config.toggleSubConfig(
|
||||
global.__HUGO_AURA_UI_REACTIVES__.config.currentActiveSubPage,
|
||||
false
|
||||
);
|
||||
} else {
|
||||
global.__HUGO_AURA_UI_FUNCTIONS__.config.hideConfigPage();
|
||||
}
|
||||
},
|
||||
|
||||
hideConfigPage: async () => {
|
||||
const defaultHeader = document.getElementsByClassName(
|
||||
"index__header__16DmR2a5"
|
||||
)[0];
|
||||
defaultHeader.style = "-webkit-app-region: drag;";
|
||||
|
||||
const auraConfigPageRoot = document.getElementsByClassName(
|
||||
"aura-config-page-root"
|
||||
)[0];
|
||||
auraConfigPageRoot.className =
|
||||
"aura-config-page-root-inactive aura-config-page-root";
|
||||
|
||||
await window.__HUGO_AURA_GLOBAL__.utils.sleep(500);
|
||||
|
||||
window.__HUGO_AURA_LOADER__["Aura.UI.Assistant.Config"].active = false;
|
||||
},
|
||||
|
||||
toggleSubConfig: (subPage, side) => {
|
||||
if (side === global.__HUGO_AURA_UI_REACTIVES__.config.isInSubPage) return;
|
||||
if (!side) {
|
||||
side = !global.__HUGO_AURA_UI_REACTIVES__.config.isInSubPage;
|
||||
}
|
||||
|
||||
const operationContainerEl = document.getElementsByClassName(
|
||||
"aura-config-page-operation-container"
|
||||
)[0];
|
||||
side
|
||||
? operationContainerEl.classList.add("hide-other-operations")
|
||||
: operationContainerEl.classList.remove("hide-other-operations");
|
||||
|
||||
const operationElArr = document.getElementsByClassName(
|
||||
"aura-config-page-operation-el"
|
||||
);
|
||||
let pendingSubPageId = "";
|
||||
switch (subPage) {
|
||||
case "disableLimitations":
|
||||
side
|
||||
? operationElArr[0].classList.add("preserve-operation")
|
||||
: operationElArr[0].classList.remove("preserve-operation");
|
||||
pendingSubPageId = "Aura.UI.Assistant.Config.DisableLimitations";
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
const operationAreaEl = document.getElementsByClassName(
|
||||
"aura-config-page-operation-area"
|
||||
)[0];
|
||||
if (side) {
|
||||
operationAreaEl.classList.add("subpage-expanded");
|
||||
} else {
|
||||
operationAreaEl.style = "flex: 15;";
|
||||
operationAreaEl.classList.remove("subpage-expanded");
|
||||
setTimeout(() => {
|
||||
operationAreaEl.style = "";
|
||||
}, 500);
|
||||
}
|
||||
|
||||
const statusContainerEl = document.getElementsByClassName(
|
||||
"aura-config-page-status-container"
|
||||
)[0];
|
||||
if (side) {
|
||||
statusContainerEl.classList.add(
|
||||
"aura-config-page-status-container-hidden"
|
||||
);
|
||||
} else {
|
||||
setTimeout(() => {
|
||||
statusContainerEl.classList.remove(
|
||||
"aura-config-page-status-container-hidden"
|
||||
);
|
||||
}, 500);
|
||||
}
|
||||
|
||||
setTimeout(
|
||||
() => {
|
||||
window.__HUGO_AURA_LOADER__[pendingSubPageId].active = side;
|
||||
},
|
||||
side ? 0 : 500
|
||||
);
|
||||
|
||||
global.__HUGO_AURA_UI_REACTIVES__.config.currentActiveSubPage = side
|
||||
? subPage
|
||||
: "";
|
||||
|
||||
global.__HUGO_AURA_UI_REACTIVES__.config.isInSubPage = side;
|
||||
},
|
||||
};
|
||||
|
||||
(() => {
|
||||
const applyVersionInfo = () => {
|
||||
const nodeVersionEl = document.getElementById("nodeVersion");
|
||||
const electronVersionEl = document.getElementById("electronVersion");
|
||||
const hugoVersionEl = document.getElementById("hugoVersion");
|
||||
const auraVersionEl = document.getElementById("auraVersion");
|
||||
|
||||
nodeVersionEl.textContent = window.process.versions.node;
|
||||
electronVersionEl.textContent = window.process.versions.electron;
|
||||
hugoVersionEl.textContent = window.CUSTOM_CONFIG.root
|
||||
.replace(/\\/g, "/")
|
||||
.split("SeewoService_")[1]
|
||||
.split("/")[0];
|
||||
auraVersionEl.textContent = window.__HUGO_AURA__.version;
|
||||
};
|
||||
|
||||
const showVersionContainerAnimation = () => {
|
||||
const leftSidePane = document.getElementById("leftStatusContainer");
|
||||
const rightSidePane = document.getElementById("rightStatusContainer");
|
||||
leftSidePane.className = "aura-config-page-status-side left-side";
|
||||
rightSidePane.className = "aura-config-page-status-side right-side";
|
||||
|
||||
const descriptionEl = document.getElementsByClassName(
|
||||
"aura-config-page-status-description"
|
||||
)[0];
|
||||
descriptionEl.className = "aura-config-page-status-description";
|
||||
};
|
||||
|
||||
const showHeaderAnimation = () => {
|
||||
const headerEl = document.getElementsByClassName(
|
||||
"aura-config-page-header-area"
|
||||
)[0];
|
||||
headerEl.className = "aura-config-page-header-area";
|
||||
};
|
||||
|
||||
const showOperationsAnimation = () => {
|
||||
const operationElArr = document.getElementsByClassName(
|
||||
"aura-config-page-operation-el"
|
||||
);
|
||||
let timeout = 0;
|
||||
Array.from(operationElArr).forEach((el) => {
|
||||
setTimeout(() => {
|
||||
el.className = "operation-el-show aura-config-page-operation-el";
|
||||
}, timeout);
|
||||
timeout += 150;
|
||||
});
|
||||
};
|
||||
|
||||
const showAnimation = async () => {
|
||||
const defaultHeader = document.getElementsByClassName(
|
||||
"index__header__16DmR2a5"
|
||||
)[0];
|
||||
|
||||
const auraConfigPageRoot = document.getElementsByClassName(
|
||||
"aura-config-page-root"
|
||||
)[0];
|
||||
await window.__HUGO_AURA_GLOBAL__.utils.sleep(200);
|
||||
auraConfigPageRoot.className = "aura-config-page-root";
|
||||
|
||||
await window.__HUGO_AURA_GLOBAL__.utils.sleep(500);
|
||||
defaultHeader.style = "display: none;";
|
||||
showVersionContainerAnimation();
|
||||
showHeaderAnimation();
|
||||
await window.__HUGO_AURA_GLOBAL__.utils.sleep(500);
|
||||
showOperationsAnimation();
|
||||
};
|
||||
|
||||
const onMounted = () => {
|
||||
applyVersionInfo();
|
||||
|
||||
showAnimation();
|
||||
};
|
||||
|
||||
onMounted();
|
||||
})();
|
||||
|
||||
Reference in New Issue
Block a user