整理前后端与测试构建目录并完善配置和安全引导
Security Checks / security (push) Waiting to run

统一 frontend、backend、test、test-log 和 out 目录,更新构建、部署及测试入口;纳入配置管理兼容与首次安全引导修复;排除本机配置、密钥和测试产物。
This commit is contained in:
xuans committed 2026-09-05 19:19:52 +08:00
1 parent 28cd9d3406
commit f60d3b0880
603 files changed
+2351 -660

No files matched your search

@@ -0,0 +1,55 @@
<html>
<header>
<script>
function saveSettings() {
const form = document.getElementById("form");
window.parent.postMessage({
type: "smail-plugin-settings-save",
plugin: "SpamBlock",
payload: {
url: form.url.value,
timeout: form.timeout.value,
threshold: form.threshold.value
}
}, "*");
}
window.addEventListener("message", function (event) {
if (event.source === window.parent && event.data && event.data.type === "smail-plugin-settings-result" && event.data.plugin === "SpamBlock") {
alert(event.data.ok ? "保存成功" : "保存失败");
}
});
</script>
</header>
<body>
<div>
<form id="form" action="#" method="post">
<div>
<label for="url"> 模型API接口地址: </label>
<input id="url" style="width: 600px;" name="url" value="%s"
placeholder="https://model.example.com/v1/predict">
</div>
<div>
<label for="timeout"> 超时时间: </label>
<input id="timeout" style="width: 600px;" name="timeout" value="%d" placeholder="单位毫秒">
</div>
<div>
<label for="threshold"> 识别阈值: </label>
<input id="threshold" name="threshold" type="number" value="%f" style="width: 600px;"
step=".01" max="100" min="0" placeholder="识别阈值,值越低过滤越严格,越容易误判">
</div>
<input id="submit" type="button" value="保存" onclick="saveSettings()"/>
</form>
</div>
</body>
</html>