striven-editor

Maintained and contributed to an open source WYSIWYG editor as an internship project that made it to production and was adopted by the company I was working at.
git clone https://unitehenry.com/git/striven-editor.git
Log | Files | Refs | README | LICENSE

commit c67eede5fc954ad38aab57023a1af83d5f728eb6
parent b0705c9a1c1d963e8f955254b922829173aad5fa
Author: unitehenry <unitehenry@gmail.com>
Date:   Tue, 12 Nov 2019 10:02:06 -0500

better responsive

Diffstat:
Mpackage.json | 2+-
Msrc/striveneditor.js | 4++--
2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/package.json b/package.json @@ -1,7 +1,7 @@ { "name": "@striven-erp/striven-editor", "private": false, - "version": "2.5.6", + "version": "2.5.7", "description": "The lightweight zero-dependency Striven WYSIWYG editor.", "main": "./dist", "scripts": { diff --git a/src/striveneditor.js b/src/striveneditor.js @@ -772,7 +772,7 @@ export default class StrivenEditor { e.preventDefault(); if (e.dataTransfer.types.includes('Files')) { - if(e.dataTransfer.files.length) { + if (e.dataTransfer.files.length) { [...e.dataTransfer.files].forEach(file => this.attachFile(file)); } } @@ -993,7 +993,7 @@ export default class StrivenEditor { hideOption('textAlign'); hideOption('removeFormat'); - if (this.editor.offsetWidth < 300) { + if ((this.toolbarTemplate.offsetWidth + this.toolbar.offsetWidth) > this.editor.offsetWidth) { responsiveMinimal(true); } else { responsiveMinimal(false);