Improved: List of domains line by line (#236)
This commit is contained in:
parent
09f52fe081
commit
480722e1f6
|
@ -121,8 +121,8 @@ const WebRequestType = {
|
|||
};
|
||||
|
||||
const Allowlist = {
|
||||
'TRIM_EXPRESSION': /^;+|;+$/g,
|
||||
'VALUE_SEPARATOR': ';'
|
||||
'TRIM_EXPRESSION': /^\n+|\n+$/g,
|
||||
'VALUE_SEPARATOR': '\n'
|
||||
};
|
||||
|
||||
const BrowserType = {
|
||||
|
|
|
@ -87,7 +87,7 @@
|
|||
<div class="option-group">
|
||||
<section class="option">
|
||||
<div class="title-option without-checkbox" data-i18n-content="allowlistedDomainsTitle">Deactivate LocalCDN for these domains:</div>
|
||||
<input id="tf-domains-allowlist" class="input-text without-checkbox" data-option="allowlistedDomains" type="text">
|
||||
<textarea rows="7" id="tf-domains-allowlist" class="input-text without-checkbox" data-option="allowlistedDomains" type="text"></textarea>
|
||||
<div class="description-option without-checkbox">
|
||||
<span data-i18n-content="allowlistedDomainsDescription">Enter domains to disable LocalCDN there. One domain per line.</span><br><br>
|
||||
<span class="monoblock">domain.com;<br>sub.domain.com;<br>*.wildcard-domain.com;</span>
|
||||
|
@ -132,7 +132,7 @@
|
|||
</div>
|
||||
<div class="description-option" data-i18n-content="blockGoogleFontsDescription">If you use the rules of the rule generator, requests to "fonts.googleapis.com" are allowed to substitute "Google Material Icons" automatically. If you want to block the other requests, enable this option.</div>
|
||||
<div id="div-domains-allowlist-google-fonts">
|
||||
<div class="description-option"><input id="tf-domains-allowlist-google-fonts" class="input-text without-checkbox" data-option="allowedDomainsGoogleFonts" type="text"></div>
|
||||
<div class="description-option"><textarea rows="7" id="tf-domains-allowlist-google-fonts" class="input-text without-checkbox" data-option="allowedDomainsGoogleFonts" type="text"></textarea></div>
|
||||
<div class="description-option" data-i18n-content="labelDomainsAllowlistGoogleFonts">These domains are allowed to load Google Fonts. One domain per line.</div>
|
||||
</div>
|
||||
</section>
|
||||
|
@ -151,7 +151,7 @@
|
|||
<section class="option">
|
||||
<div id="html-filter-domains-title-exclude" class="title-option without-checkbox" data-i18n-content="htmlFilterDomainsTitleExclude">Do not apply HTML filter to these domains:</div>
|
||||
<div id="html-filter-domains-title-include" class="title-option without-checkbox" data-i18n-content="htmlFilterDomainsTitleInclude">Apply HTML filter to these domains:</div>
|
||||
<input id="tf-domains-manipulate-dom" class="input-text without-checkbox" data-option="domainsManipulateDOM" type="text">
|
||||
<textarea rows="7" id="tf-domains-manipulate-dom" class="input-text without-checkbox" data-option="domainsManipulateDOM" type="text"></textarea>
|
||||
<div class="description-option without-checkbox" data-i18n-content="htmlFilterDomainsDescription">Enter the domains to be handled or ignored by the HTML filter. One domain per line.</div>
|
||||
</section>
|
||||
<section class="option">
|
||||
|
@ -194,7 +194,7 @@
|
|||
<div class="b-input"></div>
|
||||
</label>
|
||||
</div>
|
||||
<textarea rows="12" cols="15" id="generated-rules" readonly></textarea>
|
||||
<textarea rows="12" id="generated-rules" readonly></textarea>
|
||||
<button id="button-copy-rule-set" value="Copy" class="btns"><span data-i18n-content="copyRuleSet">Copy</span><span id="button-copy-rule-set-icon"></span></button>
|
||||
</section>
|
||||
</div>
|
||||
|
|
|
@ -279,7 +279,7 @@ options._serializeAllowlistedDomains = function (allowlistedDomains) {
|
|||
domainAllowlist = '';
|
||||
|
||||
allowlistedDomainKeys.forEach(function (domain) {
|
||||
domainAllowlist = `${domainAllowlist}${domain};`;
|
||||
domainAllowlist = `${domainAllowlist}${domain}\n`;
|
||||
});
|
||||
|
||||
domainAllowlist = domainAllowlist.slice(0, -1);
|
||||
|
|
|
@ -40,6 +40,7 @@
|
|||
<li>Implemented: Wildcard support for allowlist (<a href="https://codeberg.org/nobody/LocalCDN/issues/233">#233</a>)</li>
|
||||
<li>Fixed: Invert HTML Filter option breaks sourcecode view (<a href="https://codeberg.org/nobody/LocalCDN/issues/234">#234</a>)</li>
|
||||
<li>Updated: element-ui v2.14.1 -> v2.15.0 (<a href="https://codeberg.org/nobody/LocalCDN/issues/235">#235</a>)</li>
|
||||
<li>Improved: List of domains line by line (<a href="https://codeberg.org/nobody/LocalCDN/issues/236">#236</a>)</li>
|
||||
</ul>
|
||||
<div id="generator-section">
|
||||
<div class="topic-label">
|
||||
|
|
Loading…
Reference in New Issue