This commit is contained in:
fyears
2024-06-22 21:03:43 +08:00
parent 690f56945a
commit cc0a286471
37 changed files with 1165 additions and 140 deletions
+26 -1
View File
@@ -257,7 +257,9 @@ export const generateProSettingsPart = (
yandexDiskAllowedToUsedDiv: HTMLDivElement,
yandexDiskNotShowUpHintSetting: Setting,
koofrAllowedToUsedDiv: HTMLDivElement,
koofrNotShowUpHintSetting: Setting
koofrNotShowUpHintSetting: Setting,
azureBlobStorageAllowedToUsedDiv: HTMLDivElement,
azureBlobStorageNotShowUpHintSetting: Setting
) => {
proDiv
.createEl("h2", { text: t("settings_pro") })
@@ -389,6 +391,29 @@ export const generateProSettingsPart = (
);
}
const allowAzureBlobStorage =
plugin.settings.pro?.enabledProFeatures.filter(
(x) => x.featureName === "feature-azure_blob_storage"
).length === 1;
console.debug(
`allow to show up AzureBlobStorage settings? ${allowAzureBlobStorage}`
);
if (allowAzureBlobStorage) {
azureBlobStorageAllowedToUsedDiv.removeClass(
"azureblobstorage-allow-to-use-hide"
);
azureBlobStorageNotShowUpHintSetting.settingEl.addClass(
"azureBlobStorage-allow-to-use-hide"
);
} else {
azureBlobStorageAllowedToUsedDiv.addClass(
"azureblobstorage-allow-to-use-hide"
);
azureBlobStorageNotShowUpHintSetting.settingEl.removeClass(
"azureblobstorage-allow-to-use-hide"
);
}
new Notice(t("settings_pro_features_refresh_succ"));
});
});