Sebastian Malton
323b91e004
Fix tests
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 15:55:06 -04:00
Sebastian Malton
1b700491f9
Add more injectables
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:44:48 -04:00
Sebastian Malton
a733641f62
Make shell sessions even more injectable
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:44:48 -04:00
Sebastian Malton
28227c923d
make more injectable for testing
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:44:40 -04:00
Sebastian Malton
62af94bb2d
Remove unnecessary any cast
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
66addb8595
Fix type issue when generating extension types
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
3d39cab82d
Another attempt to fix type errors
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
e22a309c33
Revert 'fix type error'
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
321913ee57
Fix tests
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
17d384f503
Fix type error
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
91d336518a
Add unit testing requirement to have data serializable
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
2c48be3ec0
Verify messages are serializable within tests
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
78674e636f
Fix tests
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
138f488e17
Move proxy server to injectable
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
4d9a7f9b1b
Switch to Writable from Mutable
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
7767b3727d
Fix main's navigate to route
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
a3fedd3810
Fix type error
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
a98b3e5705
Cleaning up some IPC types
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
99b1f20d17
Simply implementation of sendToChannelInLensWindow
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
42af68d763
Remove side-effect in override
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
2012602e6e
Respond to PR comments
...
- Add helper function to improve types with MessageChannelListeners
- Remove some debug printing
- Improve some typing about application update status
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
299bc475a2
Fix request bases tests as serialization is now down via electron, add general override in applicationBuilder for randomBytes
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
ea8c262d3c
Convert shell authentication IPC to injectable RequestChannel
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
78ead4f2b9
Make IPC usage injectable
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:46 -04:00
Sebastian Malton
ac42d7e365
Remove console.log
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:45 -04:00
Sebastian Malton
c3f956675a
Cleanup shell sessions
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 11:42:45 -04:00
Sebastian Malton
fb4dca8e58
Export TrayMenuRegistration type ( #5793 )
2022-07-06 09:57:52 -04:00
Janne Savolainen
6e5c8e0427
Force update after thirty days since update was downloaded ( #5776 )
2022-07-06 09:48:00 -04:00
Janne Savolainen
eb6cc70143
Expose a way to reactively control visibility of preference tabs and tray menu items through Extension API ( #5789 )
2022-07-06 08:51:59 -04:00
dependabot[bot] and Sebastian Malton
03d8f2b677
Bump @kubernetes/client-node from 0.16.3 to 0.17.0 ( #5751 )
...
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Sebastian Malton <sebastian@malton.name >
2022-07-06 08:07:23 -04:00
Janne Savolainen
5ac33a6070
Prevent re-downloading update that is already downloaded ( #5781 )
2022-07-06 08:06:59 -04:00
Janne Savolainen
4d99a46dfe
Make application window appear even when its hidden underneath other apps ( #5782 )
...
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
2022-07-06 09:44:56 +03:00
Janne Savolainen and Sebastian Malton
667053cdf5
Replace status bar item application update with different tray icon based on status of the update ( #5769 )
...
* Remove the auto-update status bar item for not being needed anymore
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Make adding of new tray icons easier by complying to Open Closed Principle
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Start showing different tray icon when checking for updates
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Include placeholder icon for checking for updates
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Simplify code
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Add first keyframe for downloading spinner
Signed-off-by: Sebastian Malton <sebastian@malton.name >
Co-authored-by: Sebastian Malton <sebastian@malton.name >
2022-07-05 15:44:03 -07:00
Sebastian Malton
26127fe906
Remove unused ask-boolean injectable ( #5788 )
2022-07-05 14:58:52 -04:00
Sebastian Malton
eddefb2074
Fix type errors using raw InputValidator ( #5704 )
...
- Introduce LegacyInputValidator type
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-05 14:56:41 -04:00
Sebastian Malton and Alex Andreev
32b84d1658
Fix crash in HelmChartDetails ( #5667 )
...
* Fix crash in HelmChartDetails
Signed-off-by: Sebastian Malton <sebastian@malton.name >
* Fix bug in helm chart icon fallback
Signed-off-by: Sebastian Malton <sebastian@malton.name >
* Update snapshots
Signed-off-by: Sebastian Malton <sebastian@malton.name >
* Factor out HelmChartIcon for better reusability
Signed-off-by: Sebastian Malton <sebastian@malton.name >
* Fix compile error
Signed-off-by: Sebastian Malton <sebastian@malton.name >
* Fix remaining type errors
Signed-off-by: Sebastian Malton <sebastian@malton.name >
* Remove HelmChart list figure background
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Removing dangerouslySetInnerHTML usage
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Snapshots update
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Using currentColor from cascade instead of specific one
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com >
2022-07-04 16:17:44 -04:00
Janne Savolainen and Mikko Aspiala
14d5a1c3cc
Split root and cluster frames in smaller pieces ( #5737 )
...
* Make root frame child components comply with open closed principle and include it in the behavioural unit tests
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Make cluster frame child components comply with open closed principle and include it in behavioural unit tests
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Remove duplication
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Simplify test
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Make a component more determistic in unit tests
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Mock uninterested, non-deterministic third party library in unit tests
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com >
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Optimize registration of injectables in unit tests to make tests faster
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Update snapshots
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Remove import time side-effect causing memory leak
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
2022-07-04 09:38:29 -07:00
Sebastian Malton
a4f70c3d53
Fix broken 'Add Cluster' docs link ( #5725 )
...
* Fix broken 'Add Cluster' docs link
Signed-off-by: Sebastian Malton <sebastian@malton.name >
* fix tests
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-07-01 10:06:27 -07:00
Janne Savolainen
5f57213179
Fix stuff happening based on timers not being run correctly in unit tests ( #5764 )
...
* Introduce helper for advancing fake time
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Introduce reactive now to kludge around global shared state in library
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Replace all usages of "now" from mobx-utils with our own kludge to get rid of shared global state between unit tests
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Consolidate all usages of advanceTimersByTime to make sure things happening based on timers are run correctly
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Fix incorrect expect in test
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Enable skipped unit test since prerequisites are done
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
2022-07-01 19:40:34 +03:00
Jim Ehrismann and Janne Savolainen
3480b517c1
auto-update notifications on the status bar ( #5361 )
...
* auto-update notifications on the status bar
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* integrated with new and improved autoupdate code
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* lint
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* refactored to include AutoUpdateComponent in the statusBarItemsInjectable
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* refactor to use a registrator
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* fix lint, remove unused code
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* refactored for the simplified logic for injecting many instances PR
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* using the update syncBox injectables directly for status bar notifications
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* removed update broadcasting/listening, updated snapshots
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* fixing tests
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* fixed tests
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* cleanup after rebase to master
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* address review comments
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* fixed incorrect injectable id
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* address review comments
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* Tweak code-style
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi >
2022-07-01 14:09:00 +03:00
Sebastian Malton
165bf57380
Fix triple click breaking inputs ( #5588 )
2022-06-30 08:26:08 -04:00
Sebastian Malton
27adab8d1c
Fix parsing memory metrics expecting wrong unit suffix ( #5585 )
2022-06-30 08:25:56 -04:00
Jari Kolehmainen
71473af796
more padding between status bar items ( #5760 )
...
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
2022-06-30 10:11:04 +03:00
Sebastian Malton
0f43779727
Add react-select as a dependency for @k8slens/extensions ( #5705 )
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-06-29 19:33:31 -07:00
Alex Andreev
014ec6a03b
Align HotbarSelector elements with status bar items ( #5755 )
...
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
2022-06-29 15:44:36 +03:00
Janne Savolainen
5d76dd4fc2
Stop trying to restart catalog sync and updating of application when reloading window ( #5735 )
2022-06-29 08:22:08 -04:00
Sebastian Malton
7ab3d419b3
Fix selecting items always scrolling to top ( #5728 )
2022-06-29 08:21:57 -04:00
Sebastian Malton
a1f79092a5
Remove 'Update Now' notification ( #5750 )
2022-06-28 12:01:01 -04:00
Alex Andreev and Janne Savolainen
3084b7b8d9
Change update warning level over time ( #5445 )
...
* Give an UpdateButton injectables
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* AppUpdateWarning class and injectable
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Rename folder to app-update-warning
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Add appPublishDateInjectable
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Inject ipcRenderer into app-update-warning
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Add setter for downloadedUpdateDate
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Add tests for AppUpdateWarning
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* appPublishDate initial test
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Parsing app release date from the package version
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Introduce appUpdateWarningLevelInjectable
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Fix withInjectables props
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Determine warning from days passed after update available
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Save update available date in session storage
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Move quitAndInstall() to separate function
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Register quit-and-install ipc channel
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Make update function injectable for button
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Update tests
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Set proper timeframes
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Setting global UTC timezone for tests
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Refresh tests
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Testing warning level changes over time
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Remove unused app-publish-date files
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Make linter happy
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Pass quitAndInstallUpdateInjectable to UpdateButton
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Remove updateAppInjectable
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Initial tests for installing update using topbar button
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Refactor AppUpdateWarning class using injectables
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Permit side effects in injectable
periodicalCheckForUpdateWarningInjectable
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Temporarily set noop for UpdateButton update()
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Remove previous implementation files
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Unoverriding topbar injectables
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Render TopBar inside ApplicationBuilder
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Move updateWarningLevelInjectable
to /common subfolders from /main
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Make UpdateButton warning prop observable
by using computed() structure
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Updating snapshots
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Add sync box files allowing to restart & install
update from renderer process
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Add Update button dropdown tests
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Fix jest.advanceTimersByTime usage
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Check for severe warning level
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Linter fixes
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Remove usage of legacy global causing trouble in unit tests
Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com >
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Make update warning level completely reactive and responsibility of a renderer
Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com >
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Remove dead code
Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com >
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Remove tests that are covered by behaviour
Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com >
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Fix restarting and installing update when pressing update button
Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com >
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Update snapshots
Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com >
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Remove dead code
Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com >
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Update more snapshots
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Remove duplication from behavioural unit test
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
* Reducing too large MenuItems height
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Reduce too large UpdateButton paddings
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Add jest globalSetup into package.json
to fix timezone test
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Do not triggering computed value every time it is being used
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi >
2022-06-28 16:27:19 +03:00
Alex Andreev
0e1c507ce1
Do not affect history while navigating ( #5741 )
...
to Preferences extensions tabs
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
2022-06-28 13:47:55 +03:00