Add ipsBlocked to Freedom

Expose an ipsBlocked array on Outbound.FreedomSettings and wire it into the outbound form. The constructor now defaults fragment to {} and noises/ipsBlocked to arrays for robustness; fromJson/toJson handle ipsBlocked and omit it when empty. The outbound HTML adds a tag-style <a-select> bound to outbound.settings.ipsBlocked (with comma tokenization and placeholder) so users can enter IP/CIDR/geoip entries.
This commit is contained in:
MHSanaei
2026-04-20 18:02:39 +02:00
parent aef0503f8f
commit eb16cca551
2 changed files with 20 additions and 5 deletions

View File

@@ -51,6 +51,17 @@
<a-form-item label="Redirect">
<a-input v-model="outbound.settings.redirect"></a-input>
</a-form-item>
<a-form-item label="IPs Blocked">
<a-select
mode="tags"
v-model="outbound.settings.ipsBlocked"
:style="{ width: '100%' }"
:dropdown-class-name="themeSwitcher.currentTheme"
:token-separators="[',']"
placeholder="IP/CIDR/geoip:*/ext:*"
>
</a-select>
</a-form-item>
<a-form-item label="Fragment">
<a-switch
:checked="Object.keys(outbound.settings.fragment).length >0"