diff --git a/package.json b/package.json index 15cb43c..6c24e82 100755 --- a/package.json +++ b/package.json @@ -4,7 +4,7 @@ "description": "A file explorer (primarily a learning experience for me)", "main": "main.js", "scripts": { - "start": "electron-forge start", + "start": "electron .", "nv": "node newversion.js", "package": "electron-forge package", "make": "electron-forge make" @@ -30,7 +30,7 @@ { "name": "@electron-forge/maker-squirrel", "config": { - "name": "filekade" + "name": "FileKade" } }, { diff --git a/scripts/startup/changelog.js b/scripts/startup/changelog.js index 1d7c92e..22f9b7e 100755 --- a/scripts/startup/changelog.js +++ b/scripts/startup/changelog.js @@ -20,9 +20,13 @@ module.exports = () => { title.innerHTML = 'FileKade - Changelog'; modal.appendChild(title); + let clww = document.createElement('div'); + clww.className = 'changelog-anchor'; + modal.appendChild(clww); + let clw = document.createElement('div'); clw.className = 'changelog-wrapper'; - modal.appendChild(clw); + clww.appendChild(clw); changelogs.reverse().forEach(changelog => { changelog = require(`../../json/changelogs/${changelog}`); @@ -54,6 +58,11 @@ module.exports = () => { }); }); + clww.style = `height: ${modalOut.clientHeight - 6};`; // TODO cry enough tears that they magically make this line work + console.log(clww.style.height); + console.log(modalOut.clientHeight - 6); + console.log(typeof clww.style); + let msm = new Mousetrap(modal); msm.bind('esc', () => { modalOut.remove(); diff --git a/styles/modal.css b/styles/modal.css index b7bc2ab..0bdb6c6 100755 --- a/styles/modal.css +++ b/styles/modal.css @@ -74,6 +74,8 @@ margin: 0 0; padding: 0 0; position: relative; + max-height: inherit; + height: inherit; } .close-button-wrapper { @@ -118,11 +120,19 @@ align-items: stretch; align-content: stretch; justify-content: flex-start; - overflow: auto; flex-direction: column; row-gap: 8px; margin-top: 6px; margin-left: 6px; + position: static; + max-height: inherit; + overflow-y: scroll; +} + +.changelog-anchor { + position: static; + max-height: 62vh; + overflow: hidden; } #changelog-modal {max-height: 70vh;} \ No newline at end of file