From bea19a263db88fef44b4356082b199fbfcc39a25 Mon Sep 17 00:00:00 2001
From: "Shishkevich D." <135337715+shishkevichd@users.noreply.github.com>
Date: Sun, 6 Apr 2025 16:40:33 +0700
Subject: Code refactoring (#2865)
* refactor: use vue inline styles in entire application
* refactor: setting row in dashboard page
* refactor: use blob for download file in text modal
* refactor: move all html templates in `web/html` folder
* refactor: `DeviceUtils` -> `MediaQueryMixin`
The transition to mixins has been made, as they can update themselves.
* chore: pretty right buttons in `outbounds` tab in xray settings
* refactor: add translations for system status
* refactor: adjust gutter spacing in setting list item
* refactor: use native `a-input-password` for password field
* chore: return old system status
with new translations
* chore: add missing translation
---
web/html/index.html | 752 ++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 752 insertions(+)
create mode 100644 web/html/index.html
(limited to 'web/html/index.html')
diff --git a/web/html/index.html b/web/html/index.html
new file mode 100644
index 00000000..1be7df13
--- /dev/null
+++ b/web/html/index.html
@@ -0,0 +1,752 @@
+
+
+{{template "head" .}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
{{ i18n "pages.index.cpu" }}: [[ CPUFormatter.cpuCoreFormat(status.cpuCores) ]]
+
+
+
+ {{ i18n "pages.index.logicalProcessors" }}: [[ (status.logicalPro) ]]
+ {{ i18n "pages.index.frequency" }}: [[ CPUFormatter.cpuSpeedFormat(status.cpuSpeedMhz) ]]
+
+
+
+
+
+
+
+ {{ i18n "pages.index.memory"}}: [[ SizeFormatter.sizeFormat(status.mem.current) ]] / [[ SizeFormatter.sizeFormat(status.mem.total) ]]
+
+
+
+
+
+
+
+
+
+ {{ i18n "pages.index.swap" }}: [[ SizeFormatter.sizeFormat(status.swap.current) ]] / [[ SizeFormatter.sizeFormat(status.swap.total) ]]
+
+
+
+
+
+ {{ i18n "pages.index.storage"}}: [[ SizeFormatter.sizeFormat(status.disk.current) ]] / [[ SizeFormatter.sizeFormat(status.disk.total) ]]
+
+
+
+
+
+
+
+
+
+
+
+ {{ i18n "pages.index.xrayStatus" }}
+
+ v[[ status.xray.version ]]
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ i18n "pages.index.xrayErrorPopoverTitle" }}
+
+
+
+
+
+
+
+ [[ line ]]
+
+
+
+
+
+
+
+
+ {{ i18n "pages.index.stopXray" }}
+
+
+
+ {{ i18n "pages.index.restartXray" }}
+
+
+
+
+ [[ status.xray.version != 'Unknown' ? `v${status.xray.version}` : '{{ i18n "pages.index.xraySwitch" }}' ]]
+
+
+
+
+
+
+
+
+
+
+ {{ i18n "pages.index.logs" }}
+
+
+
+ {{ i18n "pages.index.config" }}
+
+
+
+ {{ i18n "pages.index.backup" }}
+
+
+
+
+
+
+ v{{ .cur_ver }}
+ @XrayUI
+
+
+
+
+ Xray: [[ TimeFormatter.formatSecond(status.appStats.uptime) ]]
+ OS: [[ TimeFormatter.formatSecond(status.uptime) ]]
+
+
+
+
+
+
+ [[ status.loads[0] ]] | [[ status.loads[1] ]] | [[ status.loads[2] ]]
+
+ {{ i18n "pages.index.systemLoadDesc" }}
+
+
+
+
+
+
+
+ {{ i18n "pages.index.memory" }}: [[ SizeFormatter.sizeFormat(status.appStats.mem) ]]
+ {{ i18n "pages.index.threads" }}: [[ status.appStats.threads ]]
+
+
+
+
+
+
+
+
+
+
+
+ /s
+
+
+
+
+
+
+
+
+
+ /s
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ i18n "pages.index.toggleIpVisibility" }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ versionModal.visible = false" :class="themeSwitcher.currentTheme" footer="">
+
+
+
+ [[ version ]]
+
+
+
+
+ logModal.visible = false"
+ :class="themeSwitcher.currentTheme"
+ width="800px" footer="">
+
+ {{ i18n "pages.index.logs" }}
+
+
+
+
+
+
+
+ 10
+ 20
+ 50
+ 100
+ 500
+
+
+ Debug
+ Info
+ Notice
+ Warning
+ Error
+
+
+
+
+ SysLog
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ i18n "pages.index.exportDatabase" }}
+ {{ i18n "pages.index.exportDatabaseDesc" }}
+
+
+
+
+
+ {{ i18n "pages.index.importDatabase" }}
+ {{ i18n "pages.index.importDatabaseDesc" }}
+
+
+
+
+
+
+{{template "js" .}}
+{{template "component/aSidebar" .}}
+{{template "component/aThemeSwitch" .}}
+{{template "component/aCustomStatistic" .}}
+{{template "modals/textModal"}}
+
+
+
--
cgit v1.2.3