Skip to content

Commit

Permalink
Revert "add logout feature (#1301)"
Browse files Browse the repository at this point in the history
This reverts commit abef25c.
  • Loading branch information
jeessy2 authored Oct 31, 2024
1 parent abef25c commit 2ad48c1
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 63 deletions.
1 change: 0 additions & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,6 @@ func runWebServer() error {
http.HandleFunc("/logs", web.Auth(web.Logs))
http.HandleFunc("/clearLog", web.Auth(web.ClearLog))
http.HandleFunc("/webhookTest", web.Auth(web.WebhookTest))
http.HandleFunc("/logout", web.Auth(web.Logout))

util.Log("监听 %s", *listen)

Expand Down
29 changes: 1 addition & 28 deletions static/common.css
Original file line number Diff line number Diff line change
Expand Up @@ -227,31 +227,4 @@ main {
line-height: 0;
text-align: center;
font-size: 16px;
}

.badge {
margin-right: 20px; /* 给版本号添加右侧间距 */
}

.action-button {
display: inline-block;
padding: 6px 12px;
font-size: 14px;
color: white;
border: 1px solid white;
border-radius: 8px;
background-color: transparent;
text-align: center;
text-decoration: none;
}

.action-button:hover,
.action-button:visited,
.action-button:active,
.action-button:focus {
color: white;
border-color: white;
background-color: transparent;
text-decoration: none;
outline: none;
}
}
2 changes: 0 additions & 2 deletions static/constant.js
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,6 @@ const I18N_MAP = {
"NetInterfaceEmptyHelp": '<span style="color: red">No available network card found</span>',
"Login": 'Login',
"LoginInit": 'Login and configure as an administrator account',
"Logout": 'Logout',
},
'zh-cn': {
'Logs': '日志',
Expand Down Expand Up @@ -299,6 +298,5 @@ const I18N_MAP = {
"NetInterfaceEmptyHelp": '<span style="color: red">没有找到可用的网卡</span>',
"Login": '登录',
"LoginInit": '登录并配置为管理员账号',
"Logout": '注销',
}
};
23 changes: 0 additions & 23 deletions web/logout.go

This file was deleted.

19 changes: 10 additions & 9 deletions web/writing.html
Original file line number Diff line number Diff line change
Expand Up @@ -30,17 +30,18 @@
>
<strong>DDNS-GO</strong>
</a>
<button data-i18n="Logs" class="action-button logout-button" id="logsBtn">
<button
data-i18n="Logs"
class="btn btn-info btn-sm"
id="logsBtn"
>
Logs
</button>
<span
class="theme-button gg-dark-mode"
id="themeButton"
></span>
<span class="badge badge-secondary">{{.Version}}</span>
<a href="./logout" class="action-button logout-button" data-i18n="Logout">
Logout
</a>
</div>
</div>
</header>
Expand Down Expand Up @@ -101,7 +102,7 @@

<form id="formDnsConf">
<div class="portlet">
<h5
<h5
data-i18n="DNS Provider"
class="portlet__head"
id="dnsProvider"
Expand Down Expand Up @@ -479,7 +480,7 @@ <h5 class="portlet__head">IPv6</h5>
id="Ipv6Reg"
aria-describedby="Ipv6RegHelp"
/>
<small
<small
data-i18n_html="regHelp"
id="Ipv6RegHelp"
class="form-text text-muted"
Expand Down Expand Up @@ -512,7 +513,7 @@ <h5 class="portlet__head">IPv6</h5>

<form id="formGlobal">
<div class="portlet">
<h5
<h5
data-i18n="Others"
class="portlet__head"
>Others</h5>
Expand Down Expand Up @@ -560,7 +561,7 @@ <h5 class="portlet__head">IPv6</h5>
/>
<small
data-i18n_html="accountHelp"
id="UsernameHelp"
id="UsernameHelp"
class="form-text text-muted"
></small>
</div>
Expand Down Expand Up @@ -749,7 +750,7 @@ <h5 class="portlet__head">Webhook</h5>
TTL: "",
};
</script>

<!-- 表单相关 -->
<script>
// 生成DNS选择项
Expand Down

0 comments on commit 2ad48c1

Please sign in to comment.