* Reorganize stuff to prevent circular dependencies
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Install injectable extension to allow injecting reactively many implementations
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Switch to using computedInjectMany over filtering injectMany based on enabled extensions for simplicity
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Remove await for not being needed
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Sort dependencies alphabetically
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* electron v15.5.7
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
* change pipelines to use node 16
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
* bump @types/node
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
* update yarn.lock
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
* use fs.ObjectEncodingOptions
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
Fixes#5132#5133
- bundled 7 new monospaced fonts for terminal
- fix: refresh terminal font after changing in the preferences / keep cluster iframe accessible in DOM while not active/focused
- display terminal's custom font preview with font-name in the select-box + live-preload for current `fontSize`, fix lint
* Fixes for <Input/>:
- remove duplicated error messages for sync validators
- don't propagate invalid values on change (uncontrolled components only)
- more informative error message for numeric input with min/max info
* Extract product name as injectable
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make tray items comply with Open Closed Principle
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Replace duplicated overrides with global
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Add behaviour for navigating to preferences using tray
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Introduce a tray item for updating application
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Tweak naming
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Tweak more naming
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Remove redundant indirection
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Tweak more naming
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Introduce injectable for package.json being side-effect
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Relocate file to directory containing feature
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Switch to using injectable for limiting side effect
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Add missing injection token for implementation of tray item
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Remove resetting state for update is ready to be installed for being unclear
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Kill dead code
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make label of tray item reactive
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Extract updating is enabled to separate injectable
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Introduce competition for tray
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Expand scope of behaviour for updating using tray also contain checking for updates
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Remove dead code
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Kill dead code
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Implement checking of updates from multiple update channels
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Start installing updates automatically when quitting application
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Show application window when checking of updates has happened
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Show notifications and dialog for downloading update
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Implement naive notifications for version updates
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Implement checking of Electron specific updates as responsibility
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Implement downloading of Electron specific updates as responsibility
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Introduce competition for channel abstraction
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Remove redundant global override
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Fix typing after enabling strict mode
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Introduce abstraction for a state that is shared between environments
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Extract states of application update to be usable from all environments
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Handle failing download of update
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make code for window visibility actually work
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Consolidate code for sending messages between processes to a window
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Split bloated dependency in smaller pieces
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make state of download progress accessible from all environments
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Rename files for accuracy
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Move channel abstraction to more global directory
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Enhance typing of channels and sync-box
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Consolidate channel abstraction types
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Update asyncFn to support strict mode
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Fix snapshot after rebase
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Add missing global override
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Introduce injection token for channels to allow injecting all of them at once
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Add notifications about change in update status
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Rename property for accuracy
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Tweak code style
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make notifications unit testable in behaviours
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Add implementation for asking boolean over processes
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Reorganize responsibilities for checking updates
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Reorganize tests for installing update under separate scenarios
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make stuff happening when root frame is rendered unit testable
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Introduce periodical check for updates
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Allow downgrading app versions
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Switch to using competition for checking of updates in application menu
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Kill dead code
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make test less prone to fail for wrong reason
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Remove redundant boilerplate
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make tests for specific migrations less prone to failing for wrong reason
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Move shared stuff under common
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Switch to using single source of truth for selected update channel
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Extract tests for installing update from different update channels to separate scenario
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Add missing global override
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Switch to using release channel of installed application version as default value for selected update channel
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Consolidate usage of channel abstraction to same implementation
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make Channel abstraction support return values
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Fix direct calling of runnables
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Synchronize initial values of sync boxes when window starts
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Add missing global override
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Tweak message of question from user
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Consolidate names of directories
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Add TODO
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Remove unimplemented scenario from test
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Simplify test
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Improve name of test
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Remove redundant overrides
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Fix code style
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make Animate deterministic in unit tests
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Simplify naming
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Simplify more naming
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Simplify even more naming
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Simplify more and more naming
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Add todo for cleaning unacceptable code encountered
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Improve name of behaviour
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Make unit test more strict
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Enhance name of behaviour
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Introduce dependency to get random IDs
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Make asking of boolean value from user not require explicit ID for question
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Simplify code for asking of boolean value from user
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Make setting of initial state for sync boxes not trigger irrelevant messaging to main
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Make a channel have default type for sent and returned message
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Introduce higher order function to log errors in decorated functions
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Export type for error logging
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Tweak test name
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Introduce higher order function for suppressing errors
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Relocate some explicit error handlings to proper level of abstraction
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make higher order function for logging errors support asynchronous rejecting with non error instance
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make overridden version of application exactly the one required by unit test
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Mark injectable causing side effects
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Revert not required changes
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make code for asserting a promise more strict
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Make dependencies readonly
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Remove duplication for disposers
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Implement initial values for sync-boxes
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Separate concept of message and request channels
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Introduce tests for requesting from channel in renderer
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Implement requesting from renderer in main
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Revert "Implement requesting from renderer in main"
This reverts commit d3e7899d7900516f3dbfacdb317a453202318305.
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Tweak typing of request channel listeners to get rid of unexpected undefined
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Remove unused variable
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Tweak timing of sentry setup
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Require messages for MessageChannels be JsonValues for serialization
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Require requests and responses for RequestChannels be JsonValues for serialization
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Make different MessageChannels not require explicit "extends JsonObject"
Note: Non-escaped lint breaks type here for forcing interface over type. Reasonable effort brought no understanding for what is the relevant difference between the two.
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Make a primitive argument an object for readability
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Make typing of higher order function for error suppression not lie
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Serialize messages in channels to make IPC not blow up
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Introduce a way to make intentional orphan promises uniform, controllable and deliberate
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Make downloading of update and what follows more deliberate as orphan promise
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
* Move utility function under directory
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Move another utility function under directory
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Fix incorrect name of file
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Remove redundant code
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Kill dead code
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Round percentage of update download progress in tray
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Fix rebase conflicts
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
* Fix CheckForUpdate type errors
Signed-off-by: Sebastian Malton <sebastian@malton.name>
Co-authored-by: Iku-turso <mikko.aspiala@gmail.com>
Co-authored-by: Sebastian Malton <sebastian@malton.name>