Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
# Changelog

## 1.0.0-beta.8 - UNRELEASED
## 1.0.0-beta.8
### Fixed
- The space key can now be used for keyboard shortcuts
- An issue where items in the rundown couldn't rapidly be selected and de-selected
- An issue where context menus were cut off in the rundown
- An issue with the palette not setting proper keys
- An issue with the palette not removing event listeners
- The escape key causes weird behaviour when editing a shortcut
- Closing shortcuts with the escape key prevents context menus in the edit mode
- Closing shortcuts with the escape key prevents context menus in the edit mode
- An issue that crashed the app in windows when opened with an invalid file path as runtime argument
### Added
- Support for selecting multiple items at once with the shift key
- An API for managing context menus
Expand Down
2 changes: 1 addition & 1 deletion app/components/Header/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ export function Header ({ title = DEFAULT_TITLE, features }) {
{ featureShown('title') && title }
{
shared?._hasUnsavedChanges &&
<div className='Header-unsavedDot' />
<span className='Header-edited'> — edited</span>
}
</div>
<div className='Header-center'></div>
Expand Down
11 changes: 3 additions & 8 deletions app/components/Header/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,9 @@ for the traffic light
align-items: center;
}

.Header-unsavedDot {
display: inline-block;
width: 6px;
height: 6px;
margin-left: 5px;

border-radius: 10px;
background: var(--base-color);
.Header-edited {
white-space: pre-wrap;
opacity: 0.4;
}

.Header-center {
Expand Down
15 changes: 11 additions & 4 deletions lib/electron/electron.js
Original file line number Diff line number Diff line change
Expand Up @@ -146,10 +146,12 @@ as workspace if it was opened with one

/* FOR WINDOWS */
if (process.platform === 'win32' && process.argv.length >= 2) {
_wasOpenedByFile = true

const filePath = process.argv[1]
openWithFile(filePath)

if (await paths.pathIsFile(filePath)) {
_wasOpenedByFile = true
openWithFile(filePath)
}
}

/* FOR MACOS */
Expand Down Expand Up @@ -235,7 +237,12 @@ async function initWorkspaceMainWindow (workspace, opts = {}) {
minWidth: 560,
minHeight: 500,
titleBarStyle: 'hiddenInset',
transparent: true,

/*
Only enable transparency on macOS as
it will disable window resizing on Windows
*/
transparent: process.platform === 'darwin',
vibrancy: 'fullscreen-ui',
backgroundMaterial: 'acrylic',
webPreferences: {
Expand Down
23 changes: 20 additions & 3 deletions lib/paths.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,12 @@
//
// SPDX-License-Identifier: MIT

const path = require('path')
const assert = require('assert')

const electron = require('electron')

const fs = require('node:fs')
const path = require('node:path')
const assert = require('node:assert')

const platform = require('./platform')

;(function () {
Expand Down Expand Up @@ -63,3 +64,19 @@ exports.temp = temp
*/
const userDefaults = path.join(appData, '/UserDefaults.json')
exports.userDefaults = userDefaults

/**
* Check whether or not
* a path is a file
* @param { string } filePath
* @returns { boolean }
*/
async function pathIsFile (filePath) {
try {
const stat = await fs.promises.stat(filePath)
return stat.isFile()
} catch {
return false
}
}
exports.pathIsFile = pathIsFile
Loading