diff --git a/openwrt/files/luci/model/cbi/ua3f/fields.lua b/openwrt/files/luci/model/cbi/ua3f/fields.lua index de7ed70..68cfc8c 100644 --- a/openwrt/files/luci/model/cbi/ua3f/fields.lua +++ b/openwrt/files/luci/model/cbi/ua3f/fields.lua @@ -65,7 +65,7 @@ function M.add_general_fields(section) rewrite_mode:value("RULES", translate("Rule Based")) rewrite_mode.default = "GLOBAL" rewrite_mode.description = translate( - "Direct Forward: No rewriting. Global Rewrite: Rewrite all User-Agents to the specified value. Rule Based: Use rewrite rules to determine behavior.") + "Direct Forward: No rewriting. Global Rewrite: Rewrite all User-Agents. Rule Based: Use rewrite rules to determine behavior.") -- User-Agent (for Global Rewrite) local ua = section:taboption("general", Value, "ua", translate("User-Agent")) diff --git a/openwrt/files/luci/view/ua3f/rules.htm b/openwrt/files/luci/view/ua3f/rules.htm index ed48ebf..0e61011 100644 --- a/openwrt/files/luci/view/ua3f/rules.htm +++ b/openwrt/files/luci/view/ua3f/rules.htm @@ -57,11 +57,11 @@ local rules_data = uci:get("ua3f", "main", "rewrite_rules") or "[]" <%:Enabled%> <%:Index%> - <%:Rule Type%> + <%:Type%> <%:Rewrite Header%> <%:Match Value%> - <%:Rewrite Action%> - <%:Rewrite Value%> + <%:Action%> + <%:Value%> <%:Actions%> @@ -253,7 +253,7 @@ local rules_data = uci:get("ua3f", "main", "rewrite_rules") or "[]" var upBtn = document.createElement('button'); upBtn.type = 'button'; upBtn.className = 'cbi-button cbi-button-neutral'; - upBtn.textContent = '<%:Move Up%>'; + upBtn.textContent = '<%:Up%>'; upBtn.disabled = index === 0; upBtn.onclick = function() { rewriteRules.moveRuleUp(index); }; td8.appendChild(upBtn); @@ -263,7 +263,7 @@ local rules_data = uci:get("ua3f", "main", "rewrite_rules") or "[]" var downBtn = document.createElement('button'); downBtn.type = 'button'; downBtn.className = 'cbi-button cbi-button-neutral'; - downBtn.textContent = '<%:Move Down%>'; + downBtn.textContent = '<%:Down%>'; // Can't move down if it's the second-to-last (because last is FINAL) downBtn.disabled = index >= this.rules.length - 2; downBtn.onclick = function() { rewriteRules.moveRuleDown(index); }; @@ -348,7 +348,7 @@ local rules_data = uci:get("ua3f", "main", "rewrite_rules") or "[]" typeValue.className = 'cbi-value'; var typeLabel = document.createElement('label'); typeLabel.className = 'cbi-value-title'; - typeLabel.textContent = '<%:Rule Type%>'; + typeLabel.textContent = '<%:Type%>'; typeValue.appendChild(typeLabel); var typeField = document.createElement('div'); typeField.className = 'cbi-value-field'; @@ -421,7 +421,7 @@ local rules_data = uci:get("ua3f", "main", "rewrite_rules") or "[]" actionValue.className = 'cbi-value'; var actionLabel = document.createElement('label'); actionLabel.className = 'cbi-value-title'; - actionLabel.textContent = '<%:Rewrite Action%>'; + actionLabel.textContent = '<%:Action%>'; actionValue.appendChild(actionLabel); var actionField = document.createElement('div'); actionField.className = 'cbi-value-field'; diff --git a/openwrt/files/luci/view/ua3f/statistics.htm b/openwrt/files/luci/view/ua3f/statistics.htm index 8c89590..04776ad 100644 --- a/openwrt/files/luci/view/ua3f/statistics.htm +++ b/openwrt/files/luci/view/ua3f/statistics.htm @@ -14,7 +14,7 @@ local rowstyle = data.rowstyle - + @@ -22,7 +22,7 @@ local rowstyle = data.rowstyle <% for i, item in ipairs(rewrite_stats) do %> - + @@ -34,7 +34,7 @@ local rowstyle = data.rowstyle
<%:Host%><%:Rewrite Count%><%:Count%> <%:Original Header%> <%:Modified Header%>
<%= item.host %><%= item.count %><%= item.count %> <%= item.origin_ua %> <%= item.mocked_ua %>
- + @@ -42,7 +42,7 @@ local rowstyle = data.rowstyle <% for i, item in ipairs(pass_stats) do %> - + diff --git a/openwrt/po/zh_cn/ua3f.po b/openwrt/po/zh_cn/ua3f.po index bdeb5ac..373839b 100644 --- a/openwrt/po/zh_cn/ua3f.po +++ b/openwrt/po/zh_cn/ua3f.po @@ -56,7 +56,7 @@ msgstr "全局重写" msgid "Rule Based" msgstr "规则判定" -msgid "Direct Forward: No rewriting. Global Rewrite: Rewrite all User-Agents to the specified value. Rule Based: Use rewrite rules to determine behavior." +msgid "Direct Forward: No rewriting. Global Rewrite: Rewrite all User-Agents. Rule Based: Use rewrite rules to determine behavior." msgstr "直接转发:不进行任何重写。全局重写:将所有 User-Agent 重写为指定值。规则判定:根据重写规则判定行为。" msgid "User-Agent" @@ -89,8 +89,8 @@ msgstr "重写次数实时统计" msgid "Host" msgstr "地址" -msgid "Rewrite Count" -msgstr "重写次数" +msgid "Count" +msgstr "次数" msgid "Original Header" msgstr "原始 Header" @@ -101,9 +101,6 @@ msgstr "重写后 Header" msgid "Pass-Through Statistics" msgstr "放行次数实时统计" -msgid "Pass-Through Count" -msgstr "放行次数" - msgid "Last Source Address" msgstr "最近访问源地址" @@ -155,13 +152,13 @@ msgstr "添加规则" msgid "Index" msgstr "序号" -msgid "Rule Type" -msgstr "规则类型" +msgid "Type" +msgstr "类型" msgid "Match Value" msgstr "匹配值" -msgid "Rewrite Action" +msgid "Action" msgstr "重写策略" msgid "Rewrite Value" @@ -209,10 +206,10 @@ msgstr "保存" msgid "Edit" msgstr "编辑" -msgid "Move Up" +msgid "Up" msgstr "上移" -msgid "Move Down" +msgid "Down" msgstr "下移" msgid "Delete"
<%:Header%><%:Pass-Through Count%><%:Count%> <%:Last Source Address%> <%:Last Destination Address%>
<%= item.ua %><%= item.count %><%= item.count %> <%= item.srcAddr %> <%= item.destAddr %>