mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2025-12-10 05:27:03 +03:00
Merge branch 'master' into settings
This commit is contained in:
@@ -67,6 +67,7 @@ interface SBConfig {
|
||||
"preview-sponsor": PreviewBarOption,
|
||||
"selfpromo": PreviewBarOption,
|
||||
"preview-selfpromo": PreviewBarOption,
|
||||
"exclusive_access": PreviewBarOption,
|
||||
"interaction": PreviewBarOption,
|
||||
"preview-interaction": PreviewBarOption,
|
||||
"intro": PreviewBarOption,
|
||||
@@ -224,6 +225,9 @@ const Config: SBObject = {
|
||||
}, {
|
||||
name: "poi_highlight" as Category,
|
||||
option: CategorySkipOption.ManualSkip
|
||||
}, {
|
||||
name: "exclusive_access" as Category,
|
||||
option: CategorySkipOption.ShowOverlay
|
||||
}],
|
||||
|
||||
colorPalette: {
|
||||
@@ -254,6 +258,10 @@ const Config: SBObject = {
|
||||
color: "#bfbf35",
|
||||
opacity: "0.7"
|
||||
},
|
||||
"exclusive_access": {
|
||||
color: "#008a5c",
|
||||
opacity: "0.7"
|
||||
},
|
||||
"interaction": {
|
||||
color: "#cc00ff",
|
||||
opacity: "0.7"
|
||||
@@ -405,6 +413,17 @@ function fetchConfig(): Promise<void> {
|
||||
}
|
||||
|
||||
function migrateOldFormats(config: SBConfig) {
|
||||
if (!config["exclusive_accessCategoryAdded"] && !config.categorySelections.some((s) => s.name === "exclusive_access")) {
|
||||
config["exclusive_accessCategoryAdded"] = true;
|
||||
|
||||
config.categorySelections.push({
|
||||
name: "exclusive_access" as Category,
|
||||
option: CategorySkipOption.ShowOverlay
|
||||
});
|
||||
|
||||
config.categorySelections = config.categorySelections;
|
||||
}
|
||||
|
||||
if (config["fillerUpdate"] !== undefined) {
|
||||
chrome.storage.sync.remove("fillerUpdate");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user