Skip to content

Commit

Permalink
luci-app-adblock: sync with adblock-4.2.0
Browse files Browse the repository at this point in the history
* add hagezi support

Signed-off-by: Dirk Brenken <[email protected]>
  • Loading branch information
dibdot committed Aug 9, 2024
1 parent 0d4d477 commit 257cfac
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -593,6 +593,22 @@ return view.extend({
o.optional = true;
o.rmempty = true;

o = s.taboption('sources', form.DummyValue, '_sub');
o.rawhtml = true;
o.default = '<em><b>Hagezi List Selection</b></em>';

o = s.taboption('sources', form.DynamicList, 'adb_hag_sources', _('Variants'));
for (var i = 0; i < categories.length; i++) {
code = categories[i].match(/^(\w+);/)[1].trim();
if (code === 'hag') {
list = categories[i].match(/^\w+;(.*);/)[1].trim();
path = categories[i].match(/^.*;(.*$)/)[1].trim();
o.value(path, list);
}
}
o.optional = true;
o.rmempty = true;

return m.render();
},
handleReset: null
Expand Down
1 change: 1 addition & 0 deletions applications/luci-app-adblock/po/templates/adblock.pot
Original file line number Diff line number Diff line change
Expand Up @@ -726,6 +726,7 @@ msgid "Unable to save changes: %s"
msgstr ""

#: applications/luci-app-adblock/htdocs/luci-static/resources/view/adblock/overview.js:584
#: applications/luci-app-adblock/htdocs/luci-static/resources/view/adblock/overview.js:600
msgid "Variants"
msgstr ""

Expand Down

0 comments on commit 257cfac

Please sign in to comment.