Skip to content

Commit 4a160bd

Browse files
committed
fix(ui): label node Outbounds button as Outbounds / ACL
1 parent 36931f3 commit 4a160bd

4 files changed

Lines changed: 17 additions & 7 deletions

File tree

src/locales/en.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -581,6 +581,8 @@
581581
"aclGeoUpdateInterval": "Geo database update interval",
582582
"aclRulesEditorHint": "Inline ACL rules are edited on the",
583583
"aclRulesEditorLink": "Outbounds / ACL page",
584+
"outboundsAclButton": "Outbounds / ACL",
585+
"outboundsAclButtonHint": "ACL rules and outbound proxies",
584586
"domainHintHysteria": "If set — TLS certificate will be issued automatically (ACME). Also used in subscription URLs instead of IP.",
585587
"sniHintHysteria": "Custom SNI for clients. Works ONLY without domain (self-signed cert). If domain is set — this field is ignored.",
586588
"outboundsAclLockedDisabled": "Outbounds ACL editor is unavailable because ACL is disabled for this node.",

src/locales/ru.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -581,6 +581,8 @@
581581
"aclGeoUpdateInterval": "Интервал обновления Geo-баз",
582582
"aclRulesEditorHint": "Inline-правила ACL редактируются на странице",
583583
"aclRulesEditorLink": "Outbounds / ACL",
584+
"outboundsAclButton": "Outbounds / ACL",
585+
"outboundsAclButtonHint": "Правила ACL и исходящие прокси",
584586
"domainHintHysteria": "Если указан — TLS-сертификат выпустится автоматически (ACME). Также используется в ссылках подписки вместо IP.",
585587
"sniHintHysteria": "Кастомный SNI для клиентов. Работает ТОЛЬКО без домена (self-signed сертификат). Если указан домен — это поле игнорируется.",
586588
"outboundsAclLockedDisabled": "Редактор ACL в Outbounds недоступен: ACL выключен в настройках ноды.",

src/locales/zh-CN.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -581,6 +581,8 @@
581581
"aclGeoUpdateInterval": "Geo 数据库更新间隔",
582582
"aclRulesEditorHint": "内联 ACL 规则在",
583583
"aclRulesEditorLink": "出站 / ACL 页面",
584+
"outboundsAclButton": "出站 / ACL",
585+
"outboundsAclButtonHint": "ACL 规则和出站代理",
584586
"domainHintHysteria": "如果设置,将自动签发 TLS 证书(ACME)。订阅 URL 也会使用它而不是 IP。",
585587
"sniHintHysteria": "客户端使用的自定义 SNI。仅在无域名(自签名证书)时有效。如果设置了域名,此字段会被忽略。",
586588
"outboundsAclLockedDisabled": "由于此节点已禁用 ACL,出站 ACL 编辑器不可用。",

views/partials/node-form/management.ejs

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -284,17 +284,21 @@
284284
<% } %>
285285
<% if (outboundsAclLocked) { %>
286286
<span class="action-btn is-disabled" style="text-decoration:none;text-align:center;" title="<%= t('nodes.outboundsAclLockedDisabled') %>" aria-disabled="true">
287-
<span class="action-icon"><i class="ti ti-arrow-up-right"></i></span>
288-
<span>Outbounds</span>
289-
<% if (node.outbounds && node.outbounds.length > 0) { %>
287+
<span class="action-icon"><i class="ti ti-filter"></i></span>
288+
<span><%= t('nodes.outboundsAclButton') %></span>
289+
<% if (node.aclRules && node.aclRules.length > 0) { %>
290+
<span class="badge" style="font-size:10px;background:var(--accent);color:#fff;border-radius:10px;padding:1px 6px;margin-left:4px;"><%= node.aclRules.length %></span>
291+
<% } else if (node.outbounds && node.outbounds.length > 0) { %>
290292
<span class="badge" style="font-size:10px;background:var(--accent);color:#fff;border-radius:10px;padding:1px 6px;margin-left:4px;"><%= node.outbounds.length %></span>
291293
<% } %>
292294
</span>
293295
<% } else { %>
294-
<a href="/panel/nodes/<%= node._id %>/outbounds" class="action-btn" style="text-decoration:none;text-align:center;">
295-
<span class="action-icon"><i class="ti ti-arrow-up-right"></i></span>
296-
<span>Outbounds</span>
297-
<% if (node.outbounds && node.outbounds.length > 0) { %>
296+
<a href="/panel/nodes/<%= node._id %>/outbounds" class="action-btn" style="text-decoration:none;text-align:center;" title="<%= t('nodes.outboundsAclButtonHint') %>">
297+
<span class="action-icon"><i class="ti ti-filter"></i></span>
298+
<span><%= t('nodes.outboundsAclButton') %></span>
299+
<% if (node.aclRules && node.aclRules.length > 0) { %>
300+
<span class="badge" style="font-size:10px;background:var(--accent);color:#fff;border-radius:10px;padding:1px 6px;margin-left:4px;"><%= node.aclRules.length %></span>
301+
<% } else if (node.outbounds && node.outbounds.length > 0) { %>
298302
<span class="badge" style="font-size:10px;background:var(--accent);color:#fff;border-radius:10px;padding:1px 6px;margin-left:4px;"><%= node.outbounds.length %></span>
299303
<% } %>
300304
</a>

0 commit comments

Comments
 (0)