1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00
Commit Graph

1728 Commits

Author SHA1 Message Date
Alex Andreev
17ddee2bde
Remove Tabs hover line width transition (#6020)
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-08-11 15:39:23 +03:00
Sebastian Malton
bd3f123aef
Fix Badges being too small when scrollable and not expandable (#5987)
Signed-off-by: Sebastian Malton <sebastian@malton.name>
2022-08-10 05:46:41 -07:00
Sebastian Malton
09f2919946
Remove usage of deprecated xtermjs's registerLinkMatcher API (#5996)
* Make openBrowser->openLinkInBrowser injectable

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Remove use of deprecated link matcher API from XtermJS

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Fix type errors

Signed-off-by: Sebastian Malton <sebastian@malton.name>
2022-08-09 19:25:11 -07:00
Sebastian Malton
5c11d7f7fe
Fix completely overriding PATH in shellSync (#5451) 2022-08-09 10:08:56 -04:00
Sebastian Malton
592600c1bb
Fix focus not switching to new cluster frame (#5995) 2022-08-08 21:49:21 +03:00
Janne Savolainen
688ef40e92
Fix incorrect links in workload overview page (#6002)
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-08-08 12:26:48 -04:00
Alex Andreev
f759cf6230 Introduce VirtualTable component
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-08-08 09:39:05 +03:00
Alex Andreev
3df4c306e5 Move TableHeader to its own component
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-08-08 09:38:35 +03:00
Alex Andreev
bd965c93f4 Using one-line layout for the <td>s
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-08-08 09:38:07 +03:00
Alex Andreev
a2e6d6e313 Remove unused import
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-08-08 09:37:27 +03:00
Sebastian Malton
d9785ad4dc
Fix ResourceQuotaDetails quotas display bugs (#5909) 2022-08-05 14:02:35 -04:00
Janne Savolainen
06d780479c
Tweak timing of starting and stopping periodical checking for updates (#5981) 2022-08-04 14:21:16 -04:00
Sebastian Malton
8dea3ad8bc
Correctly handle HorizontalPodAutoscaler metrics with 0 usage (#5986) 2022-08-04 14:21:01 -04:00
Janne Savolainen
04652b4f90
Tweak timing of starting and stopping kubeconfig sync (#5982) 2022-08-04 14:12:33 -04:00
Sebastian Malton
249927dc80
Fix HorizontalPodAutoscaler metrics not displaying current values (#5956) 2022-08-04 12:34:52 -04:00
Alex Andreev
8ab1faafb6 Introduce TableList generic component
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-08-04 15:59:30 +03:00
Alex Andreev
355c965d74 Remove checkboxes column from the Pods column object
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-08-04 15:59:08 +03:00
Alex Andreev
69ad3974a8 Move useReactTable hook from Table to outer components
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-08-04 15:58:35 +03:00
Alex Andreev
cd2215097a Using new columns format in Pods list
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-08-04 11:56:15 +03:00
Alex Andreev
c3c81529f6 Initial sketch of new react table component
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-08-04 10:52:21 +03:00
Sebastian Malton
2b24a42883
Fix Pod Container sorting not correlating to visuals (#5175) 2022-08-02 12:44:32 -04:00
Sebastian Malton
95ed0dda1b
Fix CPU spike when opening PodDetails from MonacoEditor (#5642) 2022-08-02 12:41:23 -04:00
Janne Savolainen
83232440dc
Replace individual mocks for withTooltip with global mock (#5962) 2022-08-02 10:06:37 -04:00
Sebastian Malton
57e4e29a16
Fix not being able to switch metrics if none are available (#5430)
Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-08-02 10:05:15 -04:00
Alex Andreev
3d62d1c029
Fix ingress list line heights (#5949)
* Split ingress rules by multiple lines

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>

* Force updating virtual list when rowHeights changed

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>

* Replacing simple div selectors with more specific

.ingressRule classnames

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-08-02 15:24:53 +03:00
Sebastian Malton
07568839f6
Fix KubeObjectDetails drawer not working for Cluster scoped resources (#5954)
- Fix not displaying spinner while object is not defined

- Fix not displaying loading error if object is not defined

Signed-off-by: Sebastian Malton <sebastian@malton.name>
2022-08-01 13:25:29 +03:00
Sebastian Malton
485f213461
Remove duplicate 'Controlled by' section on Jobs' details (#5943)
Signed-off-by: Sebastian Malton <sebastian@malton.name>
2022-08-01 13:22:49 +03:00
Janne Savolainen
af4b74d9bd
Open application only if new update is available when using tray to check for updates (#5948)
* Prevent opening of application if no new updates were downloaded when checking for updates using tray when application window is closed

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Fix getting initial value of sync box

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Tweak naming of variable

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-07-29 15:55:16 +03:00
Alex Andreev
5ddd8e8846
Fine-tune styles of Extensions page (#5921) 2022-07-28 16:34:06 -04:00
Sebastian Malton
feb2859b5d
Fix Badge.props.expandable's default being switched to false (#5911)
Signed-off-by: Sebastian Malton <sebastian@malton.name>
2022-07-28 13:11:32 -07:00
Janne Savolainen
e682c7de45
Fix editing of kube resource (#5906) 2022-07-27 11:44:11 -04:00
Alex Andreev
e334a6aeda
Adding more control over extension preferences page title (#5901)
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-07-27 14:05:55 +03:00
stewoe
392d548bf0
Set focus on port field when port-forward-dialog opens (#5908)
Signed-off-by: Stefan Woehrer <stefan.woehrer@lean-coders.at>

Co-authored-by: Stefan Woehrer <stefan.woehrer@lean-coders.at>
2022-07-27 14:03:58 +03:00
Janne Savolainen
a12b94405a
Resolve kube object status texts again on re-render to make it look like it's reactive (#5875)
* Make tests for kube object status icon more realistic

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Start resolving kube object status texts on each re-render to mimic reactivity

Note: This is done due the current implementation exposed in Extension API expects it to work so. However, this is bad.

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Switch to using existing implementation for isDefined

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-07-27 09:21:38 +03:00
Sebastian Malton
f61330611e
Remove global shared state to fix unit tests (#5889) 2022-07-26 08:55:13 -04:00
Janne Savolainen
bedc440d42
Fix opening of release details (#5850)
* Make sure release details are updates when opening details

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Relax filtering of resources to prevent crashing when release has installed resources in another namespace

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Add Open Closed Principle compliant way to introduce global overrides without modification in getDiForUnitTesting

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Rework helm release details to fix multiple bugs

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Remove redundant optional chaining

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Simplify code

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-07-26 14:57:46 +03:00
Sebastian Malton
e7e8d1688c
Fix trying to connect to cluster whose entity doesn't exist (#5881)
* Fix trying to connect to cluster whose entity doesn't exist

- If a Cluster is trying to be connected to but there is no associated
  entity then don't try and connect

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Revert cleanup

Signed-off-by: Sebastian Malton <sebastian@malton.name>
2022-07-25 13:12:46 -04:00
Alex Andreev
811d96eb74
Fix styles for topbar window buttons on linux (#5874)
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-07-25 08:55:41 +03:00
Sebastian Malton
f7f41cab79
Fix terminal freezing self and whole app when internet is disconnected (#5870)
- Remove uses to navigator.onLine as not needed and because that value
  cannot be trusted (see several bug reports on chromium)

- Fix infinite loop when socket is not connected in flush

- Add some simple tests

Signed-off-by: Sebastian Malton <sebastian@malton.name>
2022-07-25 08:34:54 +03:00
Sebastian Malton
4e4690f15f
Fix edit kube resource tab not respecting changes to current draft (#5878) 2022-07-22 12:14:48 -04:00
Janne Savolainen
f281df1693
Fix installation of helm charts (#5841)
* Relax validator for installing charts

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Tweak spacing between words in confirmation dialog

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Add mocks for monaco editor and virtualized auto sizer to allow components to be rendered in unit tests

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Improve typing for a function

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Remove usage of shared global state from a component

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Provide a way to unit test usages of storages

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Add way to get current value from select in behavioural unit tests

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Rework installation of helm charts to get rid of the majority of bugs

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Update snapshots

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Remove technical test for being covered in behaviours

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Split behaviour to smaller pieces

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Add tests accidentally removed back

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Mark functions causing side effects

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Remove behaviour covered by other behaviours

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Tweak naming

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Remove unused dependency

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-07-20 08:15:27 +03:00
Sebastian Malton
81c18a6cad
Add guards to prevent activation errors slipping through (#5845)
* Add guards to prevent activation errors slipping through

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Make sure all logging has a message, output less errors when prometheus fails

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Improve logging from getPortFromStream

Signed-off-by: Sebastian Malton <sebastian@malton.name>
2022-07-19 09:05:41 +03:00
Jim Ehrismann
0d2aea0101
removed no longer necessary workaround in resolveAuthProxyUrl() (#5833)
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com>
2022-07-19 08:48:27 +03:00
Piotr Roszatycki
f4b7fea54a
feat: New view for PriorityClasses under Config menu (#5816)
* feat: new view for PriorityClass under Config menu

Signed-off-by: Piotr Roszatycki <piotr.roszatycki@gmail.com>

* Added priorityClassDetailItemInjectable

Signed-off-by: Piotr Roszatycki <piotr.roszatycki@gmail.com>

* Removed uneccessary defensive code

Signed-off-by: Piotr Roszatycki <piotr.roszatycki@gmail.com>
2022-07-19 08:41:07 +03:00
Mario Sarcher
94091e93f8
Do not show Version on welcome screen (#5840)
Co-authored-by: k8slens-bot <info@k8slens.dev>
2022-07-18 12:18:37 -04:00
Sebastian Malton
5f746760c8
Fix terminal fit errors (#5811) 2022-07-18 09:53:15 -04:00
Sebastian Malton
ede8a2e91f
Fix open CommandDialog (#5818)
Signed-off-by: Sebastian Malton <sebastian@malton.name>
2022-07-15 08:17:44 +03:00
Janne Savolainen
d66e6c23c5
Expose reactive ways to hide items in cluster frame using Extension API - PART 7 (#5824)
* Kludge "isEnabledForCluster" work again for cluster pages

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Kludge "isEnabledForCluster" work again for kube object details

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Expose reactive way to hide kube object detail items in Extension API

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Expose reactive way to hide kube object menu items in Extension API

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Expose reactive way to hide kube object status items in Extension API

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Expose reactive way to hide workload overview detail items in Extension API

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Expose reactive way to disable pages in Extension API

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Expose a way to access active cluster from Extension API

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Deprecate "isEnabledForCluster" in favor of individual enabled or visible properties for each registration

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-07-13 13:47:03 -04:00
Janne Savolainen
ca40c51117
Introduce kludge to make "isEnabledForCluster" work again for cluster pages PART 1 (#5800)
* Kludge "isEnabledForCluster" work again for cluster pages

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Introduce kludge to make "isEnabledForCluster" work again for cluster page menus  PART 2 (#5801)

* Kludge "isEnabledForCluster" work again for cluster page menus (sidebar items)

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Introduce kludge to make "isEnabledForCluster" work again for kube object status texts PART 3 (#5802)

* Kludge "isEnabledForCluster" work again for kube object status texts

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Kludge "isEnabledForCluster" work again for kube object menu items (#5803)

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Introduce kludge to make "isEnabledForCluster" work again for workload overview details PART 5 (#5804)

* Kludge "isEnabledForCluster" work again for cluster page menus (sidebar items)

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Kludge "isEnabledForCluster" work again for kube object status texts

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Kludge "isEnabledForCluster" work again for kube object menu items

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Kludge "isEnabledForCluster" work again for workload overview details

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Kludge "isEnabledForCluster" work again for kube object details (#5805)

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-07-13 08:36:51 +03:00
Janne Savolainen
63bd783803
Add global override for component observing current time for causing … (#5814) 2022-07-08 12:54:23 -04:00
dependabot[bot]
ec92aa779b
Bump @async-fn/jest from 1.6.1 to 1.6.2 (#5808)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Sebastian Malton <sebastian@malton.name>
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
2022-07-08 08:43:02 -04:00
Janne Savolainen
c53aa77775
Update snapshots after merging something (#5815)
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-07-08 15:20:10 +03:00
Sebastian Malton
f935454875
Fix check on NamespaceSelectFilter not updating (#5691) 2022-07-07 11:59:33 -04:00
Janne Savolainen
b16a419287
Fix menu actions not opening in multiple places (#5799) 2022-07-07 09:23:24 -04:00
Sebastian Malton
07c5de6e8e
Use extension's app preference tab name when available (#5798)
Signed-off-by: Sebastian Malton <sebastian@malton.name>
2022-07-07 08:34:58 +03:00
Sebastian Malton
d44599af00
Fix breaking changes in extension API types (#5797) 2022-07-06 15:00:31 -04:00
Sebastian Malton
2a37d6bfac
Remove reference to window in ExtensionLoader (#5796) 2022-07-06 12:27:01 -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]
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
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
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
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
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
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
Janne Savolainen
2b9c2ad69e
Re-export types for notifications store to revert accidental breaking… (#5715)
* Re-export types for notifications store to revert accidental breaking change

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Tweak exports for notifications to provide same API contract

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-06-27 09:06:02 +03:00
Janne Savolainen
fc770b4b44
Revert accidental breaking change (#5703) 2022-06-22 09:48:09 -04:00
Iku-turso
71427da02d
Helper to resolve proxy from URL in any environment, or using extension-API (#5690)
* Permit modular directory structures for behaviours in spirit of "Screaming Architecture"

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Implement env-agnostic helper to resolve proxy from URL

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Implement way to resolve a proxy, that is not reliant on existing windows

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Restore reliancy on existing windows for resolving proxy for fears of Electron events misbehaving because of a temp-window used in case no windows are open

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Make resolving a proxy throw if no browser window is available

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Extract minimal abstraction for specifically logging error instead of also warn, info, etc.

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Make decorator for error logging not create orphan promise for easier controllability

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Add error logging to resolving of proxy

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Expose resolving of proxy in extension-API

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Add missing general override

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Add test to add documentation

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Disperse implementation of resolve-proxy back to conventional directory structure instead of an experimental one

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Revert "Permit modular directory structures for behaviours in spirit of "Screaming Architecture""

This reverts commit 75e1231b0e61b74d030d12365352226e7f1ce500.

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Rename a helper for less ambiguity

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>

* Add tsdoc for "resolveSystemProxy" exposed in Extension-API

Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>

Signed-off-by: Iku-turso <mikko.aspiala@gmail.com>
2022-06-22 16:09:24 +03:00
Janne Savolainen
fa23b5cd3f
Fix download percentages not updating in tray (#5697)
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-06-22 15:37:13 +03:00
Lauri Nevala
666d90dd3c
Do not crash if ingress is missing status.loadbalancer.ingress property (#5665) 2022-06-21 11:24:02 -04:00
Alex Andreev
0784085bf4
Show extension preferences in separate page (#5284)
Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com>
Co-authored-by: Janne Savolainen <janne.savolainen@live.fi>
2022-06-21 11:11:31 -04:00
Sebastian Malton
de43df1cca
Fix cluster frame display issue (#5518)
* Fix cluster frame display issue

- Add some defensive code to prevent this sort of infinite loop

- Add some unit tests

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* fix unit tests

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Fix build

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Fix lint

Signed-off-by: Sebastian Malton <sebastian@malton.name>

* Factor out injectable for getting of cluster config data

Signed-off-by: Sebastian Malton <sebastian@malton.name>
2022-06-20 22:23:15 -04:00
Janne Savolainen
f8b008612f
Trivial tweaks accidentally left from other PR (#5679)
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com>
2022-06-20 11:49:59 -04:00
Janne Savolainen
f87f5f245c
Simplify logic for injecting many instances which can reactively change e.g. based on extension being enabled or disabled (#5662)
* 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>
2022-06-20 10:19:20 +03:00
Janne Savolainen
d0ed4e46b1
Fix tray bugs (#5666)
* Make unit tests for tray behave correctly when item is disabled

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>

* Make multiple separators in tray originating from same extension not throw up

Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-06-17 16:21:18 +03:00
Janne Savolainen
10ba9ef853
Add behaviour for tray menu items originating from extensions (#5609) 2022-06-17 08:07:26 -04:00
Janne Savolainen
2a5b4af344
Fix issue where releases are not reloaded when new release is added externally (e.g. from terminal) (#5603)
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-06-17 10:26:07 +03:00
Janne Savolainen
d1f5f1cdef
Fix flaky unit test (#5661)
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-06-17 10:25:01 +03:00
Alex Andreev
96ed99a06b
Fix table row heights (#5652) 2022-06-16 10:01:27 -04:00
Janne Savolainen
9c420d6f1e
Try solving flaky unit test by switch to use different implementation of setImmediate (#5655)
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-06-16 09:57:32 -04:00
Janne Savolainen
5c049ecca0
Improved metrics for updating application (#5607) 2022-06-16 09:05:00 -04:00
Janne Savolainen
7b0521f3b2 Rename injection token for clarity (#5636)
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-06-16 08:44:38 -04:00
Janne Savolainen
287c814565 Move phenomenon of renderer out from common by introducing different implementations for environments
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi>
2022-06-16 08:44:38 -04:00
Alex Andreev
8349d6aa4a
Fix html font size and adjust usage of rem units (#5641)
* Leave default browser font-size for the html

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>

* Fix preferences helm repos layout

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>

* Adjust usage of rem units

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>

* Adjust namespace select filter option sizes

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>

* Fixing ToBottom btn sizing

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>

* Fixing Remove Cluster dialog sizing

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>

* Fixing catalog sidebar title font-size

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>

* Fix Notice sizing

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>

* Update snapshots

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>

* Update more snapshots

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2022-06-15 19:38:10 -04:00