adjust style properties on installing
* reason = 'install' * updateUrl += '?' when configurable
This commit is contained in:
parent
f120ae9753
commit
baab837be4
|
@ -406,6 +406,11 @@ window.addEventListener('showStyles:done', function _() {
|
||||||
// Fetch .JSON style
|
// Fetch .JSON style
|
||||||
searchAPI.fetchStyleJson(result)
|
searchAPI.fetchStyleJson(result)
|
||||||
.then(userstyleJson => {
|
.then(userstyleJson => {
|
||||||
|
userstyleJson.reason = 'install';
|
||||||
|
if (result.style_settings.length) {
|
||||||
|
// this will make the popup show a config-on-homepage icon
|
||||||
|
userstyleJson.updateUrl += '?';
|
||||||
|
}
|
||||||
// Install style
|
// Install style
|
||||||
saveStyleSafe(userstyleJson)
|
saveStyleSafe(userstyleJson)
|
||||||
.then(savedStyle => {
|
.then(savedStyle => {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user