From 672288135e560036422995ebd428b1b1c5f86746 Mon Sep 17 00:00:00 2001 From: Ellpeck Date: Tue, 22 Mar 2022 12:03:48 +0100 Subject: [PATCH] initial rename --- README.md | 10 +++------- main.ts | 26 +++++++++++++------------- manifest.json | 6 +++--- package-lock.json | 2 +- package.json | 4 ++-- 5 files changed, 22 insertions(+), 26 deletions(-) diff --git a/README.md b/README.md index 8901be3..38b09d7 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,6 @@ -# Obsidian Keep -An Obsidian plugin that displays Google Keep in the app. +# Obsidian Custom Frames +An Obsidian plugin that allows adding iframes with custom styling as editor tabs -![A screenshot of the Obsidian Keep plugin in action](screenshot.png) - -If you accidentally close the Google Keep view, or it doesn't open when you first install the plugin, you can open it again with the `Obsidian Keep: Open Keep` command. - -By default, the plugin also ships with a set of custom CSS that is applied to Google Keep to make it work better as a narrow side view rather than a full page. +![A screenshot of the Obsidian Custom Frames plugin in action](screenshot.png) Note that this plugin only works on Desktop right now. \ No newline at end of file diff --git a/main.ts b/main.ts index 71ff6fc..3ecc6ac 100644 --- a/main.ts +++ b/main.ts @@ -2,7 +2,7 @@ import { App, ItemView, Plugin, PluginSettingTab, Setting, WorkspaceLeaf } from import { remote, webContents } from 'electron'; const viewName: string = "keep"; -const defaultSettings: KeepSettings = { +const defaultSettings: CustomFramesSettings = { minimumWidth: 370, padding: 5, css: `/* hide the menu bar and the "Keep" logo and text */ @@ -11,20 +11,20 @@ const defaultSettings: KeepSettings = { }` }; -interface KeepSettings { +interface CustomFramesSettings { minimumWidth: number; padding: number; css: string; } -export default class KeepPlugin extends Plugin { +export default class CustomFramesPlugin extends Plugin { - settings: KeepSettings; + settings: CustomFramesSettings; async onload(): Promise { await this.loadSettings(); - this.registerView(viewName, l => new KeepView(l, this.settings)); + this.registerView(viewName, l => new CustomFrameView(l, this.settings)); this.addCommand({ id: "open-keep", name: "Open Keep", @@ -34,7 +34,7 @@ export default class KeepPlugin extends Plugin { this.openKeep(); }, }); - this.addSettingTab(new KeepSettingTab(this.app, this)); + this.addSettingTab(new CustomFramesSettingTab(this.app, this)); this.app.workspace.onLayoutReady(() => this.openKeep()); } @@ -53,11 +53,11 @@ export default class KeepPlugin extends Plugin { } } -class KeepView extends ItemView { +class CustomFrameView extends ItemView { - private settings: KeepSettings; + private settings: CustomFramesSettings; - constructor(leaf: WorkspaceLeaf, settings: KeepSettings) { + constructor(leaf: WorkspaceLeaf, settings: CustomFramesSettings) { super(leaf); this.settings = settings; } @@ -105,18 +105,18 @@ class KeepView extends ItemView { } } -class KeepSettingTab extends PluginSettingTab { +class CustomFramesSettingTab extends PluginSettingTab { - plugin: KeepPlugin; + plugin: CustomFramesPlugin; - constructor(app: App, plugin: KeepPlugin) { + constructor(app: App, plugin: CustomFramesPlugin) { super(app, plugin); this.plugin = plugin; } display(): void { this.containerEl.empty(); - this.containerEl.createEl('h2', { text: 'Obsidian Keep Settings' }); + this.containerEl.createEl('h2', { text: 'Obsidian Custom Frames Settings' }); new Setting(this.containerEl) .setName("Minimum View Width") diff --git a/manifest.json b/manifest.json index 6f62be5..0de3897 100644 --- a/manifest.json +++ b/manifest.json @@ -1,9 +1,9 @@ { - "id": "obsidian-keep", - "name": "Obsidian Keep", + "id": "obsidian-custom-frames", + "name": "Obsidian Custom Frames", "version": "1.1.1", "minAppVersion": "0.13.33", - "description": "An Obsidian plugin that displays Google Keep in the app", + "description": "An Obsidian plugin that allows adding iframes with custom styling as editor tabs", "author": "Ellpeck", "authorUrl": "https://ellpeck.de", "isDesktopOnly": true diff --git a/package-lock.json b/package-lock.json index 87b2b86..0f7fb6b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,5 +1,5 @@ { - "name": "obsidian-keep", + "name": "obsidian-custom-frames", "version": "1.1.1", "lockfileVersion": 1, "requires": true, diff --git a/package.json b/package.json index 1f27137..8ea1992 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { - "name": "obsidian-keep", + "name": "obsidian-custom-frames", "version": "1.1.1", - "description": "An Obsidian plugin that displays Google Keep in the app", + "description": "An Obsidian plugin that allows adding iframes with custom styling as editor tabs", "main": "main.js", "scripts": { "dev": "node esbuild.config.mjs",