Skip to content

Commit e8edcda

Browse files
authored
Merge pull request #646 from jschoiRR/mold-main#2025
[Mold UI] 시스템테마 설정에 맞도록 다크모드 변경/ 가상머신 nic 탭 ui 수정
2 parents c1db152 + 718ffb4 commit e8edcda

21 files changed

Lines changed: 237 additions & 135 deletions

scripts/util/update-mold-theme-from-license.sh

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,8 @@ if [ "ablestack" == "$type" ]; then
1212
# 로고 파일 변경
1313
sed -i "/\"logo\"/ c\ \"logo\": \"assets/logo-ablestack.png\"," $config_path
1414
sed -i "/\"banner\"/ c\ \"banner\": \"assets/login-logo-ablestack.png\"," $config_path
15-
sed -i "/\"minilogo\"/ c\ \"minilogo\": \"assets/mini-logo-ablestack.png\"," $config_path
15+
sed -i "/\"miniLogo\"/ c\ \"miniLogo\": \"assets/mini-logo-ablestack.png\"," $config_path
16+
sed -i "/\"whiteLogo\"/ c\ \"whiteLogo\": \"assets/white-logo-ablestack.png\"," $config_path
1617

1718
# 저작권 표시 변경
1819
sed -i "/\"footer\"/ c\ \"footer\": \"ⓒ 2021-2025 ABLECLOUD Inc. All Rights Reserved.\"," $config_path
@@ -42,7 +43,8 @@ elif [ "clostack" == "$type" ]; then
4243
# 로고 파일 변경
4344
sed -i "/\"logo\"/ c\ \"logo\": \"assets/logo-clostack.png\"," $config_path
4445
sed -i "/\"banner\"/ c\ \"banner\": \"assets/login-logo-clostack.png\"," $config_path
45-
sed -i "/\"minilogo\"/ c\ \"minilogo\": \"assets/mini-logo-ablestack.png\"," $config_path
46+
sed -i "/\"miniLogo\"/ c\ \"miniLogo\": \"assets/mini-logo-ablestack.png\"," $config_path
47+
sed -i "/\"whiteLogo\"/ c\ \"whiteLogo\": \"assets/white-logo-clostack.png\"," $config_path
4648

4749
# 저작권 표시 변경
4850
sed -i "/\"footer\"/ c\ \"footer\": \"ⓒ 2025 ITCEN CLOIT. All Rights Reserved.\"," $config_path
@@ -71,7 +73,8 @@ elif [ "hv" == "$type" ]; then
7173
# 로고 파일 변경
7274
sed -i "/\"logo\"/ c\ \"logo\": \"assets/logo-hv.png\"," $config_path
7375
sed -i "/\"banner\"/ c\ \"banner\": \"assets/login-logo-hv.png\"," $config_path
74-
sed -i "/\"minilogo\"/ c\ \"minilogo\": \"assets/mini-logo-hv.png\"," $config_path
76+
sed -i "/\"miniLogo\"/ c\ \"miniLogo\": \"assets/mini-logo-hv.png\"," $config_path
77+
sed -i "/\"whiteLogo\"/ c\ \"whiteLogo\": \"assets/white-logo-hv.png\"," $config_path
7578

7679
# 저작권 표시 변경
7780
sed -i "/\"footer\"/ c\ \"footer\": \"© HS HYOSUNG INFORMATION SYSTEMS\"," $config_path
14.4 KB
Loading
17.6 KB
Loading

ui/public/assets/white-logo-hv.png

10.8 KB
Loading

ui/public/config.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,8 @@
1313
"buildVersion": "V4.0-4.0.15",
1414
"loginFooter": "",
1515
"logo": "assets/logo-ablestack.png",
16-
"minilogo": "assets/mini-logo-ablestack.png",
16+
"whiteLogo": "assets/white-logo-ablestack.png",
17+
"miniLogo": "assets/mini-logo-ablestack.png",
1718
"banner": "assets/login-logo-ablestack.png",
1819
"loginTitle": "ABLESTACK",
1920
"loginFavicon": "assets/ablestack-favicon.png",

ui/public/locales/ko_KR.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1837,7 +1837,7 @@
18371837
"label.publickey": "\uacf5\uac1c \ud0a4",
18381838
"label.publicnetwork": "\uc11c\ube44\uc2a4\uc6a9 \ub124\ud2b8\uc6cc\ud06c",
18391839
"label.publicport": "Public \ud3ec\ud2b8",
1840-
"label.purgeresources": "Purge Resources",
1840+
"label.purgeresources": "VM \ud30c\uae30\uc2dc \ub9ac\uc18c\uc2a4 \uc815\ub9ac",
18411841
"label.purge.usage.records.success": "\uc0ac\uc6a9 \uae30\ub85d\uc744 \uc131\uacf5\uc801\uc73c\ub85c \uc0ad\uc81c\ud588\uc2b5\ub2c8\ub2e4",
18421842
"label.purge.usage.records.error": "\uc0ac\uc6a9 \uae30\ub85d\uc744 \uc0ad\uc81c\ub97c \uc2e4\ud328\ud588\uc2b5\ub2c8\ub2e4",
18431843
"label.purpose": "\ubaa9\uc801",
@@ -2055,10 +2055,10 @@
20552055
"label.scaleup.policy": "\uc2a4\ucf00\uc77c\uc5c5 \uc815\ucc45",
20562056
"label.scaling": "\uc2a4\ucf00\uc77c\ub9c1",
20572057
"label.schedule": "\uc2a4\ucf00\uc904",
2058-
"label.schedule.add": "Add schedule",
2058+
"label.schedule.add": "\uc2a4\ucf00\uc904 \ucd94\uac00",
20592059
"label.scheduled.backups": "\uc608\uc57d\ub41c \ubc31\uc5c5",
20602060
"label.scheduled.snapshots": "\uc608\uc57d\ub41c \uc2a4\ub0c5\uc0f7",
2061-
"label.schedules": "Schedules",
2061+
"label.schedules": "\uc2a4\ucf00\uc904",
20622062
"label.scope": "\ubc94\uc704",
20632063
"label.scope.tooltip": "\uae30\ubcf8 \uc800\uc7a5\uc18c \ud480 \ubc94\uc704",
20642064
"label.search": "\uac80\uc0c9",
@@ -3429,7 +3429,7 @@
34293429
"message.network.offering.mac.learning": "VMware Distributed Virtual Switches \ubc84\uc804 6.6.0 \uc774\uc0c1 \ubc0f vSphere \ubc84\uc804 6.7 \uc774\uc0c1\uc5d0\uc11c\ub9cc VMware \ud558\uc774\ud37c\ubc14\uc774\uc800\uc758 \uac8c\uc2a4\ud2b8 \ub124\ud2b8\uc6cc\ud06c\uc5d0 \uc801\uc6a9\ud560 \uc218 \uc788\uc2b5\ub2c8\ub2e4.\nMAC \ud559\uc2b5\uc740 \ub2e8\uc77c vNIC \ub4a4\uc5d0 \uc788\ub294 \uc5ec\ub7ec MAC \uc8fc\uc18c\uc5d0 \ub300\ud55c \ub124\ud2b8\uc6cc\ud06c \uc5f0\uacb0\uc744 \ud65c\uc131\ud654\ud569\ub2c8\ub2e4.\n\uc5c6\uc74c - \uae00\ub85c\ubc8c \uc124\uc815\uc758 \uae30\ubcf8\uac12 .",
34303430
"message.network.offering.mac.learning.warning": "\uacbd\uace0: MAC \ud559\uc2b5\uc744 \uc0ac\uc6a9\ud558\ub824\uba74 \ud558\uc774\ud37c\ubc14\uc774\uc800 \ud638\uc2a4\ud2b8\uac00 ESXi 6.7 \uc774\uc0c1\uc744 \uc2e4\ud589 \uc911\uc774\uace0 \ub124\ud2b8\uc6cc\ud06c\uac00 \ubd84\uc0b0 vSwitch 6.6.0 \uc774\uc0c1\uc744 \uc0ac\uc6a9\ud558\ub294\uc9c0 \ud655\uc778\ud574\uc57c \ud569\ub2c8\ub2e4.",
34313431
"message.network.offering.promiscuous.mode": "VMware \ud558\uc774\ud37c\ubc14\uc774\uc800\uc758 \uac8c\uc2a4\ud2b8 \ub124\ud2b8\uc6cc\ud06c\uc5d0\ub9cc \uc801\uc6a9\ud560 \uc218 \uc788\uc2b5\ub2c8\ub2e4.\n\uac70\ubd80 - \uc2a4\uc704\uce58\uac00 .vmx \uad6c\uc131 \ud30c\uc77c\uc5d0 \uc788\ub294 \uac83\uacfc \ub2e4\ub978 \uc18c\uc2a4 MAC \uc8fc\uc18c\ub97c \uac00\uc9c4 \uac00\uc0c1 \uba38\uc2e0 \uc5b4\ub311\ud130\uc5d0\uc11c \uc544\uc6c3\ubc14\uc6b4\ub4dc \ud504\ub808\uc784\uc744 \uc0ad\uc81c\ud569\ub2c8\ub2e4.\n\uc218\ub77d - \uc2a4\uc704\uce58\uac00 \ud544\ud130\ub9c1\uc744 \uc218\ud589\ud558\uc9c0 \uc54a\uc2b5\ub2c8\ub2e4. , \ubaa8\ub4e0 \uc544\uc6c3\ubc14\uc6b4\ub4dc \ud504\ub808\uc784\uc744 \ud5c8\uc6a9\ud569\ub2c8\ub2e4.\n\uc5c6\uc74c - \uae00\ub85c\ubc8c \uc124\uc815\uc758 \uae30\ubcf8\uac12\uc785\ub2c8\ub2e4.",
3432-
"message.network.removenic": "\uc774 NIC\ub97c \uc81c\uac70 \ud560 \uac83\uc778\uc9c0 \ud655\uc778\ud558\uc2ed\uc2dc\uc624. \uadf8\ub7ec\uba74 VM\uc5d0\uc11c \uc5f0\uacb0\ub41c \ub124\ud2b8\uc6cc\ud06c\ub3c4 \uc81c\uac70\ub429\ub2c8\ub2e4.",
3432+
"message.network.removenic": "\ud574\ub2f9 NIC\ub97c \uc81c\uac70\ud558\uc2dc\uaca0\uc2b5\ub2c8\uae4c? \uadf8\ub7ec\uba74 VM\uc5d0\uc11c \uc5f0\uacb0\ub41c \ub124\ud2b8\uc6cc\ud06c\ub3c4 \uc81c\uac70\ub429\ub2c8\ub2e4.",
34333433
"message.network.restart.required": "\ub124\ud2b8\uc6cc\ud06c\uc5d0 \ub300\ud55c \uc7ac\uc2dc\uc791\uc774 \ud544\uc694\ud569\ub2c8\ub2e4. \uc7ac\uc2dc\uc791\uc774 \ud544\uc694\ud55c \ub124\ud2b8\uc6cc\ud06c\ub97c \ubcf4\ub824\uba74 \uc5ec\uae30\ub97c \ud074\ub9ad\ud558\uc138\uc694.",
34343434
"message.network.secondaryip": "\uc774 NIC\uc5d0 \ub300\ud55c \uc0c8 \ubcf4\uc870 IP\ub97c \ud68d\ub4dd \ud560 \uac83\uc778\uc9c0 \ud655\uc778\ud558\uc2ed\uc2dc\uc624. \n \ucc38\uace0: \uac00\uc0c1\uba38\uc2e0 \ub0b4\uc5d0\uc11c \uc0c8\ub85c \ud68d\ub4dd\ud55c \ubcf4\uc870 IP\ub97c \uc218\ub3d9\uc73c\ub85c \uad6c\uc131\ud574\uc57c\ud569\ub2c8\ub2e4.",
34353435
"message.network.selection": "\uc778\uc2a4\ud134\uc2a4\ub97c \uc5f0\uacb0\ud560 \ub124\ud2b8\uc6cc\ud06c\ub97c \ud558\ub098 \uc774\uc0c1 \uc120\ud0dd\ud558\uc138\uc694. \uc5ec\uae30\uc5d0\uc11c \uc0c8 \ub124\ud2b8\uc6cc\ud06c\ub97c \ub9cc\ub4e4 \uc218\ub3c4 \uc788\uc2b5\ub2c8\ub2e4.",
@@ -3550,7 +3550,7 @@
35503550
"message.select.zone.hint": "\uc0ac\uc6a9\ud558\ub824\ub294 Zone \ubc30\ud3ec \uc720\ud615\uc785\ub2c8\ub2e4. \uae30\ubcf8 Zone : \uac01 VM \uac00\uc0c1\uba38\uc2e0\uc5d0 \ub124\ud2b8\uc6cc\ud06c\uc5d0\uc11c \uc9c1\uc811 IP\uac00 \ud560\ub2f9\ub418\ub294 \ub2e8\uc77c \ub124\ud2b8\uc6cc\ud06c\ub97c \uc81c\uacf5\ud569\ub2c8\ub2e4. \uac8c\uc2a4\ud2b8 \uaca9\ub9ac\ub294 \ubcf4\uc548\uadf8\ub8f9(IP \uc8fc\uc18c \uc18c\uc2a4 \ud544\ud130\ub9c1)\uacfc \uac19\uc740 \uacc4\uce35 3 \uc218\ub2e8\uc744 \ud1b5\ud574 \uc81c\uacf5 \ub420 \uc218 \uc788\uc2b5\ub2c8\ub2e4. \uace0\uae09 \uc601\uc5ed :\ubcf4\ub2e4 \uc815\uad50\ud55c \ub124\ud2b8\uc6cc\ud06c \ud1a0\ud3f4\ub85c\uc9c0 \uc6a9. \uc774 \ub124\ud2b8\uc6cc\ud06c \ubaa8\ub378\uc740 \uac00\uc0c1\uba38\uc2e0\uc6a9 \ub124\ud2b8\uc6cc\ud06c\ub97c \uc815\uc758\ud558\uace0 \ubc29\ud654\ubcbd, VPN \ub610\ub294 \ub85c\ub4dc \ubc38\ub7f0\uc11c \uc9c0\uc6d0\uacfc \uac19\uc740 \uc0ac\uc6a9\uc790 \uc9c0\uc815 \ub124\ud2b8\uc6cc\ud06c \uc81c\ud488\uc744 \uc81c\uacf5\ud558\ub294 \ub370 \uac00\uc7a5 \ud070 \uc720\uc5f0\uc131\uc744 \uc81c\uacf5\ud569\ub2c8\ub2e4.",
35513551
"message.server": "\uc11c\ubc84 : ",
35523552
"message.server.description": "NFS, iSCSI \ub610\ub294 PreSetup : \uc2a4\ud1a0\ub9ac\uc9c0 \uc7a5\uce58\uc758 IP \uc8fc\uc18c \ub610\ub294 DNS \uc774\ub984. VMWare PreSetup : vCenter \uc11c\ubc84\uc758 IP \uc8fc\uc18c \ub610\ub294 DNS \uc774\ub984\uc785\ub2c8\ub2e4.",
3553-
"message.set.default.nic": "\uc774 NIC\ub97c \uc774 VM\uc758 \uae30\ubcf8\uac12\uc73c\ub85c \uc124\uc815\ud560 \uac83\uc778\uc9c0 \ud655\uc778\ud558\uc2ed\uc2dc\uc624.",
3553+
"message.set.default.nic": "\ud574\ub2f9 NIC\ub97c VM\uc758 \uae30\ubcf8 NIC\ub85c \uc124\uc815\ud558\uc2dc\uaca0\uc2b5\ub2c8\uae4c?",
35543554
"message.set.default.nic.manual": "\uc9c0\uae08 VM\uc5d0\uc11c \uae30\ubcf8 NIC\ub97c \uc218\ub3d9\uc73c\ub85c \uc5c5\ub370\uc774\ud2b8\ud558\uc2ed\uc2dc\uc624.",
35553555
"message.setting.updated": "\uc5c5\ub370\uc774\ud2b8 \ub41c \uc124\uc815: ",
35563556
"message.setting.update.delay": "\uc0c8\ub85c\uc6b4 \uac12\uc740 30\ucd08 \uc774\ub0b4\uc5d0 \uc801\uc6a9\ub429\ub2c8\ub2e4.",

ui/src/components/header/Logo.vue

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,15 @@
1616
// under the License.
1717

1818
<template>
19-
<div v-if="collapsed && $config.minilogo">
19+
<div v-if="collapsed && $config.miniLogo">
2020
<img
2121
:style="{
2222
width: $config.theme['@mini-logo-width'],
2323
height: $config.theme['@mini-logo-height'],
2424
marginTop: $config.theme['@mini-logo-magin-top'],
2525
marginBottom: $config.theme['@mini-logo-magin-bottom']
2626
}"
27-
:src="$config.minilogo" />
27+
:src="$config.miniLogo" />
2828
</div>
2929
<div v-else-if="$config.logo">
3030
<img
@@ -36,12 +36,11 @@
3636
marginTop: $config.theme['@logo-magin-top'],
3737
marginBottom: $config.theme['@logo-magin-bottom']
3838
}"
39-
:src="$config.logo" />
39+
:src="logoPath" />
4040
</div>
4141
</template>
4242

4343
<script>
44-
4544
export default {
4645
name: 'Logo',
4746
components: {
@@ -62,6 +61,16 @@ export default {
6261
default: false,
6362
required: false
6463
}
64+
},
65+
data () {
66+
return {
67+
logoPath: this.$store.getters.darkMode ? this.$config.whiteLogo : this.$config.logo
68+
}
69+
},
70+
watch: {
71+
'$store.getters.darkMode' (darkMode) {
72+
this.logoPath = darkMode ? this.$config.whiteLogo : this.$config.logo
73+
}
6574
}
6675
}
6776
</script>

ui/src/components/page/GlobalLayout.vue

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -227,11 +227,16 @@ export default {
227227
}
228228
},
229229
mounted () {
230-
const layoutMode = this.$config.theme['@layout-mode'] || 'light'
231-
this.$store.dispatch('SetDarkMode', (layoutMode === 'dark'))
232-
if (layoutMode === 'dark') {
233-
document.body.classList.add('dark-mode')
234-
}
230+
// 시스템 테마 변경되었을때 감지 후 테마 변경
231+
window.matchMedia('(prefers-color-scheme: dark)').addEventListener('change', (event) => {
232+
this.$localStorage.set('DARK_MODE', event.matches)
233+
this.$store.dispatch('SetDarkMode', event.matches)
234+
document.body.classList.toggle('dark-mode', event.matches)
235+
})
236+
// 로컬스토리지 다크 모드 확인 후 변경
237+
const isDark = !!this.$localStorage.get('DARK_MODE')
238+
this.$store.dispatch('SetDarkMode', isDark)
239+
document.body.classList.toggle('dark-mode', isDark)
235240
const userAgent = navigator.userAgent
236241
if (userAgent.indexOf('Edge') > -1) {
237242
this.$nextTick(() => {

ui/src/components/view/DateTimeFilter.vue

Lines changed: 4 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
<a-form-item :label="$t('label.only.start.date.and.time')" ref="allData" name="allData">
3535
<a-switch v-model:checked="onlyStartDateIsChecked" @change="onToggleStartDate"/>
3636
</a-form-item>
37-
<a-form-item :label="$t('label.start.date.and.time')" ref="startDate" name="startDate" :rules="[{ required: showStartDate, message: `${this.$t('message.error.start.date.and.time')}` }]">
37+
<a-form-item :label="$t('label.start.date.and.time')" ref="startDate" name="startDate">
3838
<a-date-picker
3939
v-model:value="form.startDate"
4040
show-time
@@ -45,7 +45,7 @@
4545
<a-form-item :label="$t('label.only.end.date.and.time')">
4646
<a-switch v-model:checked="onlyEndDateIsChecked" @change="onToggleEndDate"/>
4747
</a-form-item>
48-
<a-form-item :label="$t('label.end.date.and.time')" ref="endDate" name="endDate" :rules="[{ required: showEndDate, message: `${this.$t('message.error.end.date.and.time')}` }]">
48+
<a-form-item :label="$t('label.end.date.and.time')" ref="endDate" name="endDate">
4949
<a-date-picker
5050
v-model:value="form.endDate"
5151
show-time
@@ -61,7 +61,7 @@
6161

6262
<script>
6363
import { ref, reactive, toRaw } from 'vue'
64-
import moment from 'moment'
64+
// import moment from 'moment'
6565
6666
export default {
6767
name: 'DateTimeFilter',
@@ -84,20 +84,7 @@ export default {
8484
value: ''
8585
}
8686
},
87-
computed: {
88-
startDate () {
89-
if (this.startDateProp) {
90-
return moment(this.startDateProp)
91-
}
92-
return null
93-
},
94-
endDate () {
95-
if (this.endDateProp) {
96-
return moment(this.endDateProp)
97-
}
98-
return null
99-
}
100-
},
87+
computed: {},
10188
data () {
10289
return {
10390
allDataIsChecked: false,

ui/src/components/view/Setting.vue

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ export default {
143143
},
144144
data () {
145145
return {
146-
layoutMode: this.$config.theme['@layout-mode'] || 'light',
146+
layoutMode: this.$localStorage.get('DARK_MODE') ? 'dark' : 'light',
147147
colorPick: this.$config.theme['@primary-color'],
148148
navBgColorPick: this.$config.theme['@navigation-background-color'],
149149
navTextColorPick: this.$config.theme['@navigation-text-color'],
@@ -229,7 +229,6 @@ export default {
229229
methods: {
230230
fetchData () {
231231
this.originalSetting = Object.assign({}, this.$config.theme)
232-
this.layoutMode = this.$config.theme['@layout-mode'] || 'light'
233232
this.uiSettings = this.$config.theme
234233
},
235234
switchLayoutMode () {

0 commit comments

Comments
 (0)