Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

Merge remote-tracking branch 'origin/dev' into dev

Vanessa611d47563f88
diff --cc app/src/config/bazaar.ts
index 1bdec2a091,21edb21116..89b46211dd
--- a/app/src/config/bazaar.ts
+++ b/app/src/config/bazaar.ts
@@@ -649,20 -649,16 +649,20 @@@ export const bazaar =
bazaar._onBazaar(response, bazaarType, ["themes", "icons"].includes(bazaarType));
bazaar._genMyHTML(bazaarType, app);
if (bazaarType === "plugins") {
- confirmDialog("💡 " + window.siyuan.languages.enablePlugin, window.siyuan.languages.enablePluginTip, () => {
- fetchPost("/api/petal/setPetalEnabled", {
- packageName: dataObj.name,
- enabled: true,
- frontend: getFrontend()
- }, (response) => {
- loadPlugin(app, response.data);
- bazaar._genMyHTML(bazaarType, app);
+ if (window.siyuan.config.bazaar.petalDisabled) {
+ confirmDialog(window.siyuan.languages.confirm, window.siyuan.languages.enablePluginTip2);
+ } else {
- confirmDialog(window.siyuan.languages.confirm, window.siyuan.languages.enablePluginTip, () => {
++ confirmDialog("💡 " + window.siyuan.languages.enablePlugin, window.siyuan.languages.enablePluginTip, () => {
+ fetchPost("/api/petal/setPetalEnabled", {
+ packageName: dataObj.name,
+ enabled: true,
+ frontend: getFrontend()
+ }, (response) => {
+ loadPlugin(app, response.data);
+ bazaar._genMyHTML(bazaarType, app);
+ });
});
- });
+ }
}
});
}