diff --git a/test-vault/.obsidian/plugins/just-share-please/.gitignore b/test-vault/.obsidian/plugins/just-share-please/.gitignore new file mode 100644 index 0000000..d334fd2 --- /dev/null +++ b/test-vault/.obsidian/plugins/just-share-please/.gitignore @@ -0,0 +1,3 @@ +* +!.gitignore +!data.json diff --git a/test-vault/.obsidian/plugins/just-share-please/main b/test-vault/.obsidian/plugins/just-share-please/main deleted file mode 100644 index ade8b0c..0000000 --- a/test-vault/.obsidian/plugins/just-share-please/main +++ /dev/null @@ -1,162 +0,0 @@ -/* -THIS IS A GENERATED/BUNDLED FILE BY ESBUILD -if you want to view the source, please visit the github repository of this plugin -*/ -var __create = Object.create; -var __defProp = Object.defineProperty; -var __getOwnPropDesc = Object.getOwnPropertyDescriptor; -var __getOwnPropNames = Object.getOwnPropertyNames; -var __getProtoOf = Object.getPrototypeOf; -var __hasOwnProp = Object.prototype.hasOwnProperty; -var __markAsModule = (target) => __defProp(target, "__esModule", { value: true }); -var __export = (target, all) => { - __markAsModule(target); - for (var name in all) - __defProp(target, name, { get: all[name], enumerable: true }); -}; -var __reExport = (target, module2, desc) => { - if (module2 && typeof module2 === "object" || typeof module2 === "function") { - for (let key of __getOwnPropNames(module2)) - if (!__hasOwnProp.call(target, key) && key !== "default") - __defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable }); - } - return target; -}; -var __toModule = (module2) => { - return __reExport(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", module2 && module2.__esModule && "default" in module2 ? { get: () => module2.default, enumerable: true } : { value: module2, enumerable: true })), module2); -}; -var __async = (__this, __arguments, generator) => { - return new Promise((resolve, reject) => { - var fulfilled = (value) => { - try { - step(generator.next(value)); - } catch (e) { - reject(e); - } - }; - var rejected = (value) => { - try { - step(generator.throw(value)); - } catch (e) { - reject(e); - } - }; - var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected); - step((generator = generator.apply(__this, __arguments)).next()); - }); -}; - -// src/main.ts -__export(exports, { - default: () => JustSharePleasePlugin -}); -var import_obsidian2 = __toModule(require("obsidian")); - -// src/settings.ts -var defaultSettings = { - url: "http://localhost:8080", - shared: [] -}; - -// src/settings-tab.ts -var import_obsidian = __toModule(require("obsidian")); -var JSPSettingsTab = class extends import_obsidian.PluginSettingTab { - constructor(app, plugin) { - super(app, plugin); - this.plugin = plugin; - } - display() { - this.containerEl.empty(); - this.containerEl.createEl("h2", { text: "Just Share Please Settings" }); - this.containerEl.createEl("hr"); - this.containerEl.createEl("p", { text: "If you like this plugin and want to support its development, you can do so through my website by clicking this fancy image!" }); - this.containerEl.createEl("a", { href: "https://ellpeck.de/support" }).createEl("img", { - attr: { src: "https://ellpeck.de/res/generalsupport.png" }, - cls: "just-share-please-support" - }); - } -}; - -// src/main.ts -var JustSharePleasePlugin = class extends import_obsidian2.Plugin { - onload() { - return __async(this, null, function* () { - yield this.loadSettings(); - this.addSettingTab(new JSPSettingsTab(this.app, this)); - this.registerEvent(this.app.workspace.on("file-menu", (m, f) => __async(this, null, function* () { - if (f instanceof import_obsidian2.TFile) { - let shared = this.settings.shared.find((i) => i.path == f.path); - if (!shared) { - m.addItem((i) => { - i.setTitle("Share to JSP"); - i.setIcon("share"); - i.onClick(() => __async(this, null, function* () { - let response = yield (0, import_obsidian2.requestUrl)({ - url: `${this.settings.url}/share.php`, - method: "POST", - body: JSON.stringify({ content: yield this.app.vault.cachedRead(f) }), - throw: false - }); - console.log(response.status + " " + response.text); - if (response.status == 200) { - shared = response.json; - shared.path = f.path; - this.settings.shared.push(shared); - yield this.saveSettings(); - } - })); - }); - } else { - m.addItem((i) => { - i.setTitle("Copy JSP link"); - i.setIcon("link"); - i.onClick(() => navigator.clipboard.writeText(`${this.settings.url}#${shared.id}`)); - }); - m.addItem((i) => { - i.setTitle("Update in JSP"); - i.setIcon("share"); - i.onClick(() => __async(this, null, function* () { - let response = yield (0, import_obsidian2.requestUrl)({ - url: `${this.settings.url}/share.php?id=${shared.id}`, - method: "PATCH", - headers: { "Password": shared.password }, - body: JSON.stringify({ content: yield this.app.vault.cachedRead(f) }), - throw: false - }); - console.log(response.status + " " + response.text); - })); - }); - m.addItem((i) => { - i.setTitle("Delete from JSP"); - i.setIcon("trash"); - i.onClick(() => __async(this, null, function* () { - let response = yield (0, import_obsidian2.requestUrl)({ - url: `${this.settings.url}/share.php?id=${shared.id}`, - method: "DELETE", - headers: { "Password": shared.password }, - throw: false - }); - console.log(response.status); - if (response.status == 200) { - this.settings.shared.remove(shared); - yield this.saveSettings(); - } - })); - }); - } - } - }))); - }); - } - loadSettings() { - return __async(this, null, function* () { - this.settings = Object.assign({}, defaultSettings, yield this.loadData()); - }); - } - saveSettings() { - return __async(this, null, function* () { - yield this.saveData(this.settings); - }); - } -}; -//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsic3JjL21haW4udHMiLCAic3JjL3NldHRpbmdzLnRzIiwgInNyYy9zZXR0aW5ncy10YWIudHMiXSwKICAic291cmNlc0NvbnRlbnQiOiBbImltcG9ydCB7UGx1Z2luLCByZXF1ZXN0VXJsLCBURmlsZX0gZnJvbSBcIm9ic2lkaWFuXCI7XHJcbmltcG9ydCB7ZGVmYXVsdFNldHRpbmdzLCBKU1BTZXR0aW5ncywgU2hhcmVkSXRlbX0gZnJvbSBcIi4vc2V0dGluZ3NcIjtcclxuaW1wb3J0IHtKU1BTZXR0aW5nc1RhYn0gZnJvbSBcIi4vc2V0dGluZ3MtdGFiXCI7XHJcblxyXG5leHBvcnQgZGVmYXVsdCBjbGFzcyBKdXN0U2hhcmVQbGVhc2VQbHVnaW4gZXh0ZW5kcyBQbHVnaW4ge1xyXG5cclxuICAgIC8vIFRPRE8gYWxsb3cgZGVsZXRpbmcgdXBsb2FkcyB3aG9zZSBsb2NhbCBmaWxlcyBoYXZlIGJlZW4gZGVsZXRlZCAodGhyb3VnaCBjb21tYW5kPylcclxuICAgIC8vIFRPRE8gYWRkIGEgc2V0dGluZyBmb3IgYXV0by1yZWZyZXNoaW5nIHVwbG9hZHMgd2hlbiBzYXZpbmdcclxuICAgIC8vIFRPRE8gc3RyaXAgZnJvbnRtYXR0ZXIgYmVmb3JlIHVwbG9hZGluZz8gbWF5YmUgb3B0aW9uYWxseVxyXG4gICAgc2V0dGluZ3M6IEpTUFNldHRpbmdzO1xyXG5cclxuICAgIGFzeW5jIG9ubG9hZCgpOiBQcm9taXNlPHZvaWQ+IHtcclxuICAgICAgICBhd2FpdCB0aGlzLmxvYWRTZXR0aW5ncygpO1xyXG4gICAgICAgIHRoaXMuYWRkU2V0dGluZ1RhYihuZXcgSlNQU2V0dGluZ3NUYWIodGhpcy5hcHAsIHRoaXMpKTtcclxuXHJcbiAgICAgICAgdGhpcy5yZWdpc3RlckV2ZW50KHRoaXMuYXBwLndvcmtzcGFjZS5vbihcImZpbGUtbWVudVwiLCBhc3luYyAobSwgZikgPT4ge1xyXG4gICAgICAgICAgICBpZiAoZiBpbnN0YW5jZW9mIFRGaWxlKSB7XHJcbiAgICAgICAgICAgICAgICBsZXQgc2hhcmVkID0gdGhpcy5zZXR0aW5ncy5zaGFyZWQuZmluZChpID0+IGkucGF0aCA9PSBmLnBhdGgpO1xyXG4gICAgICAgICAgICAgICAgaWYgKCFzaGFyZWQpIHtcclxuICAgICAgICAgICAgICAgICAgICAvLyAobmV3bHkpIHNoYXJlIGEgbm90ZVxyXG4gICAgICAgICAgICAgICAgICAgIG0uYWRkSXRlbShpID0+IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5zZXRUaXRsZShcIlNoYXJlIHRvIEpTUFwiKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5zZXRJY29uKFwic2hhcmVcIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGkub25DbGljayhhc3luYyAoKSA9PiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBsZXQgcmVzcG9uc2UgPSBhd2FpdCByZXF1ZXN0VXJsKHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmw6IGAke3RoaXMuc2V0dGluZ3MudXJsfS9zaGFyZS5waHBgLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogXCJQT1NUXCIsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgYm9keTogSlNPTi5zdHJpbmdpZnkoe2NvbnRlbnQ6IGF3YWl0IHRoaXMuYXBwLnZhdWx0LmNhY2hlZFJlYWQoZil9KSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aHJvdzogZmFsc2VcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vIFRPRE8gZGlzcGxheSBtZXNzYWdlIGFib3V0IHN0YXR1cyBzdWNjZXNzL2ZhaWwgYW5kIGNvcHkgVVJMIHRvIGNsaXBib2FyZFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2cocmVzcG9uc2Uuc3RhdHVzICsgXCIgXCIgKyByZXNwb25zZS50ZXh0KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAocmVzcG9uc2Uuc3RhdHVzID09IDIwMCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNoYXJlZCA9IHJlc3BvbnNlLmpzb247XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2hhcmVkLnBhdGggPSBmLnBhdGg7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5zZXR0aW5ncy5zaGFyZWQucHVzaChzaGFyZWQpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMuc2F2ZVNldHRpbmdzKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgICAvLyBjb3B5IG5vdGUgbGlua1xyXG4gICAgICAgICAgICAgICAgICAgIG0uYWRkSXRlbShpID0+IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5zZXRUaXRsZShcIkNvcHkgSlNQIGxpbmtcIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGkuc2V0SWNvbihcImxpbmtcIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIC8vIFRPRE8gbGV0IHBlb3BsZSBrbm93IHRoaXMgaGFwcGVuZWRcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5vbkNsaWNrKCgpID0+IG5hdmlnYXRvci5jbGlwYm9hcmQud3JpdGVUZXh0KGAke3RoaXMuc2V0dGluZ3MudXJsfSMke3NoYXJlZC5pZH1gKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIC8vIHVwZGF0ZVxyXG4gICAgICAgICAgICAgICAgICAgIG0uYWRkSXRlbShpID0+IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5zZXRUaXRsZShcIlVwZGF0ZSBpbiBKU1BcIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGkuc2V0SWNvbihcInNoYXJlXCIpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBpLm9uQ2xpY2soYXN5bmMgKCkgPT4ge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbGV0IHJlc3BvbnNlID0gYXdhaXQgcmVxdWVzdFVybCh7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiBgJHt0aGlzLnNldHRpbmdzLnVybH0vc2hhcmUucGhwP2lkPSR7c2hhcmVkLmlkfWAsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiBcIlBBVENIXCIsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaGVhZGVyczoge1wiUGFzc3dvcmRcIjogc2hhcmVkLnBhc3N3b3JkfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBib2R5OiBKU09OLnN0cmluZ2lmeSh7Y29udGVudDogYXdhaXQgdGhpcy5hcHAudmF1bHQuY2FjaGVkUmVhZChmKX0pLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRocm93OiBmYWxzZVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgLy8gVE9ETyBkaXNwbGF5IG1lc3NhZ2UgYWJvdXQgc3RhdHVzIHN1Y2Nlc3MvZmFpbCBhZnRlciB1cGRhdGluZ1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2cocmVzcG9uc2Uuc3RhdHVzICsgXCIgXCIgKyByZXNwb25zZS50ZXh0KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIC8vIGRlbGV0ZVxyXG4gICAgICAgICAgICAgICAgICAgIG0uYWRkSXRlbShpID0+IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5zZXRUaXRsZShcIkRlbGV0ZSBmcm9tIEpTUFwiKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5zZXRJY29uKFwidHJhc2hcIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGkub25DbGljayhhc3luYyAoKSA9PiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBsZXQgcmVzcG9uc2UgPSBhd2FpdCByZXF1ZXN0VXJsKHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmw6IGAke3RoaXMuc2V0dGluZ3MudXJsfS9zaGFyZS5waHA/aWQ9JHtzaGFyZWQuaWR9YCxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtZXRob2Q6IFwiREVMRVRFXCIsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaGVhZGVyczoge1wiUGFzc3dvcmRcIjogc2hhcmVkLnBhc3N3b3JkfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aHJvdzogZmFsc2VcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vIFRPRE8gZGlzcGxheSBtZXNzYWdlIGFib3V0IHN0YXR1cyBzdWNjZXNzL2ZhaWwgd2hlbiBkZWxldGluZ1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2cocmVzcG9uc2Uuc3RhdHVzKTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAocmVzcG9uc2Uuc3RhdHVzID09IDIwMCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2V0dGluZ3Muc2hhcmVkLnJlbW92ZShzaGFyZWQpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMuc2F2ZVNldHRpbmdzKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgfSkpO1xyXG4gICAgfVxyXG5cclxuICAgIGFzeW5jIGxvYWRTZXR0aW5ncygpOiBQcm9taXNlPHZvaWQ+IHtcclxuICAgICAgICB0aGlzLnNldHRpbmdzID0gT2JqZWN0LmFzc2lnbih7fSwgZGVmYXVsdFNldHRpbmdzLCBhd2FpdCB0aGlzLmxvYWREYXRhKCkp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LFFBQVE7QUFDVixnQkFBRSxRQUFRLE1BQVk7QUFDbEIsb0JBQUksV0FBVyxNQUFNLGlDQUFXO0FBQUEsa0JBQzVCLEtBQUssR0FBRyxLQUFLLFNBQVMsb0JBQW9CLE9BQU87QUFBQSxrQkFDakQsUUFBUTtBQUFBLGtCQUNSLFNBQVMsRUFBQyxZQUFZLE9BQU87QUFBQSxrQkFDN0IsT0FBTztBQUFBO0FBSVgsd0JBQVEsSUFBSSxTQUFTO0FBRXJCLG9CQUFJLFNBQVMsVUFBVSxLQUFLO0FBQ3hCLHVCQUFLLFNBQVMsT0FBTyxPQUFPO0FBQzVCLHdCQUFNLEtBQUs7QUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFBO0FBQUE7QUFBQTtBQUFBO0FBQUEsRUFTakMsZUFBOEI7QUFBQTtBQUNoQyxXQUFLLFdBQVcsT0FBTyxPQUFPLElBQUksaUJBQWlCLE1BQU0sS0FBSztBQUFBO0FBQUE7QUFBQSxFQUc1RCxlQUE4QjtBQUFBO0FBQ2hDLFlBQU0sS0FBSyxTQUFTLEtBQUs7QUFBQTtBQUFBO0FBQUE7IiwKICAibmFtZXMiOiBbXQp9Cg== diff --git a/test-vault/.obsidian/plugins/just-share-please/main.js b/test-vault/.obsidian/plugins/just-share-please/main.js deleted file mode 100644 index ade8b0c..0000000 --- a/test-vault/.obsidian/plugins/just-share-please/main.js +++ /dev/null @@ -1,162 +0,0 @@ -/* -THIS IS A GENERATED/BUNDLED FILE BY ESBUILD -if you want to view the source, please visit the github repository of this plugin -*/ -var __create = Object.create; -var __defProp = Object.defineProperty; -var __getOwnPropDesc = Object.getOwnPropertyDescriptor; -var __getOwnPropNames = Object.getOwnPropertyNames; -var __getProtoOf = Object.getPrototypeOf; -var __hasOwnProp = Object.prototype.hasOwnProperty; -var __markAsModule = (target) => __defProp(target, "__esModule", { value: true }); -var __export = (target, all) => { - __markAsModule(target); - for (var name in all) - __defProp(target, name, { get: all[name], enumerable: true }); -}; -var __reExport = (target, module2, desc) => { - if (module2 && typeof module2 === "object" || typeof module2 === "function") { - for (let key of __getOwnPropNames(module2)) - if (!__hasOwnProp.call(target, key) && key !== "default") - __defProp(target, key, { get: () => module2[key], enumerable: !(desc = __getOwnPropDesc(module2, key)) || desc.enumerable }); - } - return target; -}; -var __toModule = (module2) => { - return __reExport(__markAsModule(__defProp(module2 != null ? __create(__getProtoOf(module2)) : {}, "default", module2 && module2.__esModule && "default" in module2 ? { get: () => module2.default, enumerable: true } : { value: module2, enumerable: true })), module2); -}; -var __async = (__this, __arguments, generator) => { - return new Promise((resolve, reject) => { - var fulfilled = (value) => { - try { - step(generator.next(value)); - } catch (e) { - reject(e); - } - }; - var rejected = (value) => { - try { - step(generator.throw(value)); - } catch (e) { - reject(e); - } - }; - var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected); - step((generator = generator.apply(__this, __arguments)).next()); - }); -}; - -// src/main.ts -__export(exports, { - default: () => JustSharePleasePlugin -}); -var import_obsidian2 = __toModule(require("obsidian")); - -// src/settings.ts -var defaultSettings = { - url: "http://localhost:8080", - shared: [] -}; - -// src/settings-tab.ts -var import_obsidian = __toModule(require("obsidian")); -var JSPSettingsTab = class extends import_obsidian.PluginSettingTab { - constructor(app, plugin) { - super(app, plugin); - this.plugin = plugin; - } - display() { - this.containerEl.empty(); - this.containerEl.createEl("h2", { text: "Just Share Please Settings" }); - this.containerEl.createEl("hr"); - this.containerEl.createEl("p", { text: "If you like this plugin and want to support its development, you can do so through my website by clicking this fancy image!" }); - this.containerEl.createEl("a", { href: "https://ellpeck.de/support" }).createEl("img", { - attr: { src: "https://ellpeck.de/res/generalsupport.png" }, - cls: "just-share-please-support" - }); - } -}; - -// src/main.ts -var JustSharePleasePlugin = class extends import_obsidian2.Plugin { - onload() { - return __async(this, null, function* () { - yield this.loadSettings(); - this.addSettingTab(new JSPSettingsTab(this.app, this)); - this.registerEvent(this.app.workspace.on("file-menu", (m, f) => __async(this, null, function* () { - if (f instanceof import_obsidian2.TFile) { - let shared = this.settings.shared.find((i) => i.path == f.path); - if (!shared) { - m.addItem((i) => { - i.setTitle("Share to JSP"); - i.setIcon("share"); - i.onClick(() => __async(this, null, function* () { - let response = yield (0, import_obsidian2.requestUrl)({ - url: `${this.settings.url}/share.php`, - method: "POST", - body: JSON.stringify({ content: yield this.app.vault.cachedRead(f) }), - throw: false - }); - console.log(response.status + " " + response.text); - if (response.status == 200) { - shared = response.json; - shared.path = f.path; - this.settings.shared.push(shared); - yield this.saveSettings(); - } - })); - }); - } else { - m.addItem((i) => { - i.setTitle("Copy JSP link"); - i.setIcon("link"); - i.onClick(() => navigator.clipboard.writeText(`${this.settings.url}#${shared.id}`)); - }); - m.addItem((i) => { - i.setTitle("Update in JSP"); - i.setIcon("share"); - i.onClick(() => __async(this, null, function* () { - let response = yield (0, import_obsidian2.requestUrl)({ - url: `${this.settings.url}/share.php?id=${shared.id}`, - method: "PATCH", - headers: { "Password": shared.password }, - body: JSON.stringify({ content: yield this.app.vault.cachedRead(f) }), - throw: false - }); - console.log(response.status + " " + response.text); - })); - }); - m.addItem((i) => { - i.setTitle("Delete from JSP"); - i.setIcon("trash"); - i.onClick(() => __async(this, null, function* () { - let response = yield (0, import_obsidian2.requestUrl)({ - url: `${this.settings.url}/share.php?id=${shared.id}`, - method: "DELETE", - headers: { "Password": shared.password }, - throw: false - }); - console.log(response.status); - if (response.status == 200) { - this.settings.shared.remove(shared); - yield this.saveSettings(); - } - })); - }); - } - } - }))); - }); - } - loadSettings() { - return __async(this, null, function* () { - this.settings = Object.assign({}, defaultSettings, yield this.loadData()); - }); - } - saveSettings() { - return __async(this, null, function* () { - yield this.saveData(this.settings); - }); - } -}; -//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsic3JjL21haW4udHMiLCAic3JjL3NldHRpbmdzLnRzIiwgInNyYy9zZXR0aW5ncy10YWIudHMiXSwKICAic291cmNlc0NvbnRlbnQiOiBb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gICBsZXQgc2hhcmVkID0gdGhpcy5zZXR0aW5ncy5zaGFyZWQuZmluZChpID0+IGkucGF0aCA9PSBmLnBhdGgpO1xyXG4gICAgICAgICAgICAgICAgaWYgKCFzaGFyZWQpIHtcclxuICAgICAgICAgICAgICAgICAgICAvLyAobmV3bHkpIHNoYXJlIGEgbm90ZVxyXG4gICAgICAgICAgICAgICAgICAgIG0uYWRkSXRlbShpID0+IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5zZXRUaXRsZShcIlNoYXJlIHRvIEpTUFwiKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5zZXRJY29uKFwic2hhcmVcIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGkub25DbGljayhhc3luYyAoKSA9PiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBsZXQgcmVzcG9uc2UgPSBhd2FpdCByZXF1ZXN0VXJsKHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmw6IGAke3RoaXMuc2V0dGluZ3MudXJsfS9zaGFyZS5waHBgLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIG1ldGhvZDogXCJQT1NUXCIsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgYm9keTogSlNPTi5zdHJpbmdpZnkoe2NvbnRlbnQ6IGF3YWl0IHRoaXMuYXBwLnZhdWx0LmNhY2hlZFJlYWQoZil9KSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aHJvdzogZmFsc2VcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vIFRPRE8gZGlzcGxheSBtZXNzYWdlIGFib3V0IHN0YXR1cyBzdWNjZXNzL2ZhaWwgYW5kIGNvcHkgVVJMIHRvIGNsaXBib2FyZFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2cocmVzcG9uc2Uuc3RhdHVzICsgXCIgXCIgKyByZXNwb25zZS50ZXh0KTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAocmVzcG9uc2Uuc3RhdHVzID09IDIwMCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNoYXJlZCA9IHJlc3BvbnNlLmpzb247XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2hhcmVkLnBhdGggPSBmLnBhdGg7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdGhpcy5zZXR0aW5ncy5zaGFyZWQucHVzaChzaGFyZWQpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMuc2F2ZVNldHRpbmdzKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgfSBlbHNlIHtcclxuICAgICAgICAgICAgICAgICAgICAvLyBjb3B5IG5vdGUgbGlua1xyXG4gICAgICAgICAgICAgICAgICAgIG0uYWRkSXRlbShpID0+IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5zZXRUaXRsZShcIkNvcHkgSlNQIGxpbmtcIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGkuc2V0SWNvbihcImxpbmtcIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIC8vIFRPRE8gbGV0IHBlb3BsZSBrbm93IHRoaXMgaGFwcGVuZWRcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5vbkNsaWNrKCgpID0+IG5hdmlnYXRvci5jbGlwYm9hcmQud3JpdGVUZXh0KGAke3RoaXMuc2V0dGluZ3MudXJsfSMke3NoYXJlZC5pZH1gKSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIC8vIHVwZGF0ZVxyXG4gICAgICAgICAgICAgICAgICAgIG0uYWRkSXRlbShpID0+IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5zZXRUaXRsZShcIlVwZGF0ZSBpbiBKU1BcIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGkuc2V0SWNvbihcInNoYXJlXCIpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICBpLm9uQ2xpY2soYXN5bmMgKCkgPT4ge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgbGV0IHJlc3BvbnNlID0gYXdhaXQgcmVxdWVzdFVybCh7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgdXJsOiBgJHt0aGlzLnNldHRpbmdzLnVybH0vc2hhcmUucGhwP2lkPSR7c2hhcmVkLmlkfWAsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgbWV0aG9kOiBcIlBBVENIXCIsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaGVhZGVyczoge1wiUGFzc3dvcmRcIjogc2hhcmVkLnBhc3N3b3JkfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBib2R5OiBKU09OLnN0cmluZ2lmeSh7Y29udGVudDogYXdhaXQgdGhpcy5hcHAudmF1bHQuY2FjaGVkUmVhZChmKX0pLFxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRocm93OiBmYWxzZVxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgLy8gVE9ETyBkaXNwbGF5IG1lc3NhZ2UgYWJvdXQgc3RhdHVzIHN1Y2Nlc3MvZmFpbCBhZnRlciB1cGRhdGluZ1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2cocmVzcG9uc2Uuc3RhdHVzICsgXCIgXCIgKyByZXNwb25zZS50ZXh0KTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XHJcbiAgICAgICAgICAgICAgICAgICAgfSk7XHJcblxyXG4gICAgICAgICAgICAgICAgICAgIC8vIGRlbGV0ZVxyXG4gICAgICAgICAgICAgICAgICAgIG0uYWRkSXRlbShpID0+IHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5zZXRUaXRsZShcIkRlbGV0ZSBmcm9tIEpTUFwiKTtcclxuICAgICAgICAgICAgICAgICAgICAgICAgaS5zZXRJY29uKFwidHJhc2hcIik7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIGkub25DbGljayhhc3luYyAoKSA9PiB7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBsZXQgcmVzcG9uc2UgPSBhd2FpdCByZXF1ZXN0VXJsKHtcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB1cmw6IGAke3RoaXMuc2V0dGluZ3MudXJsfS9zaGFyZS5waHA/aWQ9JHtzaGFyZWQuaWR9YCxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBtZXRob2Q6IFwiREVMRVRFXCIsXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgaGVhZGVyczoge1wiUGFzc3dvcmRcIjogc2hhcmVkLnBhc3N3b3JkfSxcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB0aHJvdzogZmFsc2VcclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG5cclxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIC8vIFRPRE8gZGlzcGxheSBtZXNzYWdlIGFib3V0IHN0YXR1cyBzdWNjZXNzL2ZhaWwgd2hlbiBkZWxldGluZ1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgY29uc29sZS5sb2cocmVzcG9uc2Uuc3RhdHVzKTtcclxuXHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAocmVzcG9uc2Uuc3RhdHVzID09IDIwMCkge1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMuc2V0dGluZ3Muc2hhcmVkLnJlbW92ZShzaGFyZWQpO1xyXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMuc2F2ZVNldHRpbmdzKCk7XHJcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XHJcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgICAgIH0pO1xyXG4gICAgICAgICAgICAgICAgfVxyXG4gICAgICAgICAgICB9XHJcbiAgICAgICAgfSkpO1xyXG4gICAgfVxyXG5cclxuICAgIGFzeW5jIGxvYWRTZXR0aW5ncygpOiBQcm9taXNlPHZvaWQ+IHtcclxuICAgICAgICB0aGlzLnNldHRpbmdzID0gT2JqZWN0LmFzc2lnbih7fSwgZGVmYXVsdFNldHRpbmdzLCBhd2FpdCB0aGlzLmxvYWREYXRhKCkpO1xyXG4gICAgfVxyXG5cclxuICAgIGFzeW5jIHNhdmVTZXR0aW5ncygpOiBQcm9taXNlPHZvaWQ+IHtcclxuICAgICAgICBhd2FpdCB0aGlzLnNhdmVEYXRhKHRoaXMuc2V0dGluZ3MpO1xyXG4gICAgfVxyXG59XHJcbiIsICJleHBvcnQgY29uc3QgZGVmYXVsdFNldHRpbmdzOiBKU1BTZXR0aW5ncyA9IHtcclxuICAgIHVybDogXCJodHRwOi8vbG9jYWxob3N0OjgwODBcIixcclxuICAgIHNoYXJlZDogW11cclxufTtcclxuXHJcbmV4cG9ydCBpbnRlcmZhY2UgSlNQU2V0dGluZ3Mge1xyXG5cclxuICAgIHVybDogc3RyaW5nO1xyXG4gICAgc2hhcmVkOiBTaGFyZWRJdGVtW107XHJcblxyXG59XHJcblxyXG5leHBvcnQgaW50ZXJmYWNlIFNoYXJlZEl0ZW0ge1xyXG5cclxuICAgIGlkOiBzdHJpbmc7XHJcbiAgICBwYXNzd29yZDogc3RyaW5nO1xyXG4gICAgcGF0aDogc3RyaW5nO1xyXG5cclxufVxyX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tBQUs7QUFBQTtBQUFBO0FBQUE7IiwKICAibmFtZXMiOiBbXQp9Cg== diff --git a/test-vault/.obsidian/plugins/just-share-please/manifest b/test-vault/.obsidian/plugins/just-share-please/manifest deleted file mode 100644 index b574edf..0000000 --- a/test-vault/.obsidian/plugins/just-share-please/manifest +++ /dev/null @@ -1,10 +0,0 @@ -{ - "id": "just-share-please", - "name": "Just Share Please", - "version": "0.1.0", - "minAppVersion": "1.3.0", - "description": "A simple plugin that allows sharing a note using a random link", - "author": "Ellpeck", - "authorUrl": "https://ellpeck.de", - "isDesktopOnly": false -} diff --git a/test-vault/.obsidian/plugins/just-share-please/manifest.json b/test-vault/.obsidian/plugins/just-share-please/manifest.json deleted file mode 100644 index b574edf..0000000 --- a/test-vault/.obsidian/plugins/just-share-please/manifest.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "id": "just-share-please", - "name": "Just Share Please", - "version": "0.1.0", - "minAppVersion": "1.3.0", - "description": "A simple plugin that allows sharing a note using a random link", - "author": "Ellpeck", - "authorUrl": "https://ellpeck.de", - "isDesktopOnly": false -} diff --git a/test-vault/.obsidian/plugins/just-share-please/styles b/test-vault/.obsidian/plugins/just-share-please/styles deleted file mode 100644 index af92d99..0000000 --- a/test-vault/.obsidian/plugins/just-share-please/styles +++ /dev/null @@ -1,5 +0,0 @@ -.just-share-please-support { - max-width: 50%; - width: 400px; - height: auto; -} diff --git a/test-vault/.obsidian/plugins/just-share-please/styles.css b/test-vault/.obsidian/plugins/just-share-please/styles.css deleted file mode 100644 index af92d99..0000000 --- a/test-vault/.obsidian/plugins/just-share-please/styles.css +++ /dev/null @@ -1,5 +0,0 @@ -.just-share-please-support { - max-width: 50%; - width: 400px; - height: auto; -}