From 741064371002d15019033c6eae970f578e86f58b Mon Sep 17 00:00:00 2001 From: andrewmcgivery Date: Fri, 8 Mar 2024 00:00:19 -0500 Subject: [PATCH] Quick test to see if we can infact have dividers on phones --- main.ts | 24 ++++++++++++------------ manifest.json | 2 +- package.json | 2 +- versions.json | 3 ++- 4 files changed, 16 insertions(+), 15 deletions(-) diff --git a/main.ts b/main.ts index f011ced..563a3fb 100644 --- a/main.ts +++ b/main.ts @@ -42,16 +42,16 @@ export default class DividerPlugin extends Plugin { // Render the dividers based on what is already in settings // Don't try to render them on phones since it ends up being a context menu - if ( + /*if ( // @ts-ignore !(this.app.isMobile && document.body.classList.contains("is-phone")) - ) { - Object.keys(this.settings.dividers).forEach((dividerId) => { - const divider = this.settings.dividers[dividerId]; + ) {*/ + Object.keys(this.settings.dividers).forEach((dividerId) => { + const divider = this.settings.dividers[dividerId]; - this.renderDivider(divider); - }); - } + this.renderDivider(divider); + }); + //} // This adds a settings tab so the user can configure various aspects of the plugin this.addSettingTab(new DividerSettingTab(this.app, this)); @@ -137,7 +137,7 @@ export default class DividerPlugin extends Plugin { async renderDivider(divider: Divider) { const dividerIconEl = this.addRibbonIcon( "", - `Divider: ${divider.id}`, + `-`, (evt: MouseEvent) => {} ); dividerIconEl.addClass("ribbon-divider"); @@ -150,12 +150,12 @@ export default class DividerPlugin extends Plugin { * @param divider */ async addDivider(divider: Divider) { - if ( + /*if ( // @ts-ignore !(this.app.isMobile && document.body.classList.contains("is-phone")) - ) { - this.renderDivider(divider); - } + ) {*/ + this.renderDivider(divider); + //} this.settings.dividers[divider.id] = divider; diff --git a/manifest.json b/manifest.json index 539bc5d..46f6b7a 100644 --- a/manifest.json +++ b/manifest.json @@ -1,7 +1,7 @@ { "id": "ribbon-divider", "name": "Ribbon Divider", - "version": "1.1.0-beta.5", + "version": "1.1.0-beta.6", "minAppVersion": "0.15.0", "description": "Allows you to add dividers to the ribbon to space out your icons.", "author": "Andrew McGivery", diff --git a/package.json b/package.json index 03efbc0..f1bb434 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "obsidian-ribbon-divider", - "version": "1.1.0-beta.5", + "version": "1.1.0-beta.6", "description": "A plugin for Obsidian.MD that allows you to add dividers to the ribbon to space out your icons.", "main": "dist/main.js", "scripts": { diff --git a/versions.json b/versions.json index cda0cd3..998f980 100644 --- a/versions.json +++ b/versions.json @@ -4,5 +4,6 @@ "1.1.0-beta.2": "0.15.0", "1.1.0-beta.3": "0.15.0", "1.1.0-beta.4": "0.15.0", - "1.1.0-beta.5": "0.15.0" + "1.1.0-beta.5": "0.15.0", + "1.1.0-beta.6": "0.15.0" } \ No newline at end of file