Config filed for custom socks proxy for trackers

This commit is contained in:
shortcutme 2018-07-16 01:54:07 +02:00
parent 7c0541034a
commit f1f0332d22
No known key found for this signature in database
GPG key ID: 5B63BAE6CB9613AE

View file

@ -59,7 +59,6 @@ class ConfigStorage extends Class
{title: "Enable", value: "enable"} {title: "Enable", value: "enable"}
{title: "Always", value: "always"} {title: "Always", value: "always"}
] ]
value: "Enable"
description: [ description: [
"Disable: Don't connect to peers on Tor network", h("br"), "Disable: Don't connect to peers on Tor network", h("br"),
"Enable: Only use Tor for Tor network peers", h("br"), "Enable: Only use Tor for Tor network peers", h("br"),
@ -91,10 +90,21 @@ class ConfigStorage extends Class
key: "trackers_proxy" key: "trackers_proxy"
type: "select" type: "select"
options: [ options: [
{title: "Disable", value: "disable"} {title: "Custom", value: ""}
{title: "Tor", value: "tor"} {title: "Tor", value: "tor"}
{title: "Disable", value: "disable"}
] ]
section.items.push
title: "Custom socks proxy address for trackers"
key: "trackers_proxy"
type: "text"
placeholder: "Eg.: 127.0.0.1:1080"
value_pos: "fullwidth"
valid_pattern: /.+:[0-9]+/
isHidden: =>
Page.values["trackers_proxy"] in ["tor", "disable"]
createSection: (title) => createSection: (title) =>
section = {} section = {}
section.title = title section.title = title