| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
|
|
| |
Make sure that files have a default import with the same name as the
file whenever possible to reduce surprise.
Also shuffles around some file names for better legibility.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
| |
Makes sure that the renderer always sees a consistent state.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
|
| |
Makes the synchronization of references across the main/renderer process
boundary more robust.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
|
|
|
|
|
| |
Now the runtime state lives inside the model (instead of being
associated to the static settings via a map), which simplifies state
management. Static settings are now located inside the runtime models,
so we must create tests to make sure that the settings are being
persisted correctly. The contents of the config file are now generated
as a view of store (instead of a snapshot), which adds flexibility.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
| |
Lets the main process see which service is currently selected.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
|
|
| |
Makes it clear that we are talking about wrappers for nodejs and
electron functionality, and not the services being displayed by the
application.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
|
| |
Stores transient state for services shared between the main and renderer
processes.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
loglevel wants to persist the current log level in localStorage, which
apparently crashes the network service. We'll need to find another way
to log in service preload scripts. The main window preload scripts seems
unaffected, even though we use loglevel (and hence localStorage) in both
the preload and the renderer script.
Maybe related: https://github.com/electron/electron/issues/31689
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
| |
Currently, they do nothing.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
|
| |
Non-integer coordinates make electron throw the error and the reaction
to synchronize the BrowserView position fail.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
| |
We have to cheat again and use require() to lazy load a dev dependency.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
|
| |
If we generate a new ID or a new profile, it should be added to the
config file immediately.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
|
|
|
|
| |
In the main process, it is optional to specify the ID of a Profile or a
Service. The missing ID will be filled in with a randomly generated one.
Moreover, services without a profile will get a profile generated with
the same name.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Signed-off-by: Vijay A <vraravam@users.noreply.github.com>
|
| |
|
|
|
|
|
|
| |
This would run as part of gitlab SAST (if it didn't time out).
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
| |
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
| |
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
| |
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
|
| |
eslint will also enforce prettier rules, so there is no need to call
prettier separately in CI.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
|
|
|
| |
See https://github.com/typescript-eslint/typescript-eslint/issues/3851
Also upgrades dependencies and simplifies eslint config (used during
debugging this issue to eliminate other possible sources of errors.)
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
| |
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
| |
Signed-off-by: Vijay A <vraravam@users.noreply.github.com>
|
|
|
|
| |
Signed-off-by: Vijay A <vraravam@users.noreply.github.com>
|
|
|
|
| |
Signed-off-by: Vijay A <vraravam@users.noreply.github.com>
|
| |
|
|
|
|
| |
Signed-off-by: Vijay A <vraravam@users.noreply.github.com>
|
|
|
|
| |
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
| |
Signed-off-by: Vijay A <vraravam@users.noreply.github.com>
|
|
|
|
|
|
|
|
| |
- Remove unnecessary plugins array in esbuild config.
- Use vite linked deps for shared packages:
https://github.com/vitejs/vite/issues/195#issuecomment-637725505
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
| |
Test devDependencies in the main package were incorrect.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
On the first startup in dev mode, Electron must be able to download the
devtools extensions and wait for them to be installed.
Loosens the UI process request filter a bit, but the behavior should
match production mode in all cases except chrome webstore URLs.
Nevertheless, only production mode should be considered secure.
Fixes #6
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
| |
Fixes #5
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
|
|
|
|
|
| |
Also changes the default browserview contents to the gitlab repo.
Signed-off-by: Kristóf Marussy <kristof@marussy.com>
|
| |
|
|
|
|
| |
yarn typecheck still throw an unstable feature warning.
|
| |
|
|
|
|
|
| |
The renderer package still has to use node module resolution to be able
to find MUI packages.
|
| |
|
|
|
|
| |
Requires some workarounds for ts-jest to find the vendored dependencies.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Changed jest to run from the root package and reference the packages
as projects. This required moving the base jest config file away from
the project root.
- Module isolation seems to prevent ts-jest from loading the shared
package, so we disabled it for now.
- To better facilitate mocking, services should be split into interfaces
and implementation
- Had to downgrade to chald 4.1.2 as per
https://github.com/chalk/chalk/releases/tag/v5.0.0 at least until
https://github.com/microsoft/TypeScript/issues/46452 is resolved.
|
|
|
|
|
|
| |
This doesn't seem to cause any race conditions (except for the warnings
that appear even if we install the extensions before initializing the
main window and are ignored by yarn watch).
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Now we can run with ESM at build and test time and transpile into
commonjs for electron. This greatly simplifies testing, since we treat
everything as ESM during build with esbuild anyways. Now the test
environment and the build scripts match the apparent (but not the actual
for the main, preload, and inject modules) runtime environment.
Caveats:
- We may use top-level async expressions in tests and script, but not in
code that gets transpiled into commonjs or scripts that get imported
by vite. The limitation w.r.t. commonjs seems fundamental.
- Jest only experimentally supports ESM and there are some limitations
with mocking. Most limitations (except the lack of automatic mocks)
can be worked around by async importing code that uses mocks.
- There are packages marked as modules (so that node reads any scripts
in them as ESM) that nevertheless get transpiled into commonjs
modules. However, these should be clearly marked by using a .cjs
extension as their bundle. The worst offender is the root package,
which has a .cjs as its main entry point that gets read by electron,
but is in fact marked as a module. This doesn't seem to bother electron
at all. The service-inject package is an IIFE with a .js extension,
but it outputs a fully self-contained bundle, so the choice of module
format should be irrelevant.
|
|
|
|
|
| |
The rest of the packages aren't buld with vite, so we shouldn't use its
typings.
|
|
|
|
|
|
|
|
|
|
| |
By running the build for the shared packages only once, errors in them
are reported only once in watch mode.
We still have to point jest to the original source files (and rebuild
the shared source files as part of the test), because it won't load the
"module" entry of the shared packages. However, as a benefit, jest can
now run even if the shared packages haven't been built yet.
|