Janne Savolainen and Mikko Aspiala
5c8ca2c038
Implement a lot of technical requirements for behavioural unit tests
...
Note: the crux of this was to make routing env-agnostic, and not based on URLs as magic strings, but instead something type-enforced.
Note: extension-based routes comply to same exact interface by "late-registering" their routes when installed. Routes are just injectables.
Note: another chunk of global shared state is no more.
Note: a lot of explicit side effects have been cornered to injectables.
Note: a lot of stuff has become reactive as part if this.
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com >
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
2022-03-31 15:13:26 +03:00
Janne Savolainen
125a47a56d
Replace WorkloadsOverviewDetailRegistry with reactive solution ( #4817 )
...
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
2022-03-04 10:04:38 +02:00
Janne Savolainen
54b87efd89
Replace KubeObjectStatusRegistry with reactive solution ( #4815 )
2022-03-03 07:55:57 -05:00
Sebastian Malton and Alex Andreev
8480b2a1e5
Fix StatusBar extension API ( #4838 )
...
Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com >
2022-02-10 09:08:59 -05:00
Janne Savolainen and Sebastian Malton
ac42a6565f
Replace kube object menu registry with reactive solution ( #4731 )
...
Co-authored-by: Sebastian Malton <sebastian@malton.name >
2022-01-31 10:16:29 -05:00
Janne Savolainen
09b33633f7
Replace StatusBarRegistry with reactive solution ( #4728 )
2022-01-28 08:40:58 -05:00
Sebastian Malton
53ffc62391
Add extension API for registering custom category views ( #4733 )
2022-01-21 16:44:57 -05:00
Sebastian Malton
411b9a9a88
Add support for custom columns on catalog categories ( #4708 )
2022-01-19 10:22:22 -05:00
Jim Ehrismann
d31ab690c2
Refactor app-preferences-registry to use di ( #4671 )
...
* converting app-preferences to use di
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* address review comments and fix lint
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
* use compact license header
Signed-off-by: Jim Ehrismann <jehrismann@mirantis.com >
2022-01-19 08:54:45 -05:00
Janne Savolainen
589472c2b5
Shorten license header to reduce amount of clutter in top of the files ( #4709 )
...
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
2022-01-18 10:18:10 +02:00
Sebastian Malton
abe90ad92a
Add CRDs to Command Palette and fix bugs
...
- Deprecate the "scope" on command registrations as it is buggy and
generally unfixable
- Switch to mounting CommandContainer in each new frame so that there is
no need to broadcast anything other than opening palette
- Add CRD entries to the command registry within each cluster
- Add navigate to CommandActionContext to simplify handling of root
frame scoped URLs
- Switch to using DI for some of the deps
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2022-01-05 11:48:51 -05:00
Janne Savolainen and Mikko Aspiala
6ca58570b0
Replace TopBarRegistry with reactive solution
...
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com >
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
2021-12-31 09:32:19 +02:00
Janne Savolainen and Mikko Aspiala
c5613a2e6a
Remove WelcomeBannerRegistry in favor of reactive solution
...
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com >
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
2021-12-28 13:55:55 +02:00
Janne Savolainen and Mikko Aspiala
04ac2ff3dd
Remove WelcomeMenuRegistry in favor of reactive solution
...
Co-authored-by: Mikko Aspiala <mikko.aspiala@gmail.com >
Signed-off-by: Janne Savolainen <janne.savolainen@live.fi >
2021-12-28 13:55:54 +02:00
Sebastian Malton
bde0a9ef91
Change isEnabledForCluster to use KubernetesCluster instead of Cluster ( #4584 )
2021-12-17 08:28:47 -05:00
chh and Sebastian Malton
4af796c532
Before hook for onRun of Catalog entities ( #3911 )
...
Co-authored-by: Sebastian Malton <sebastian@malton.name >
2021-10-05 15:36:44 -04:00
Panu Horsmalahti
936927af98
Add CatalogCategory filter to the extension API ( #3718 )
...
* Add CatalogCategory filter to the extension API.
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com >
* Fix test.
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com >
2021-09-13 15:46:28 +03:00
Sebastian Malton and Panu Horsmalahti
6fdb2f0b58
Support filtering catalog entities ( #3647 )
...
* Support filtering catalog entities
- This allows extensions and OpenLens to restrict which of the entities
the sources have provied are "visible" to the rest of Lens
Signed-off-by: Sebastian Malton <sebastian@malton.name >
* Fix lint
Signed-off-by: Sebastian Malton <sebastian@malton.name >
* switch to filtering only for catalog view
Signed-off-by: Sebastian Malton <sebastian@malton.name >
* Fix test
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com >
* Add test to iter reduce
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com >
Co-authored-by: Panu Horsmalahti <phorsmalahti@mirantis.com >
2021-08-31 16:00:56 +03:00
chh
d3ce43e73d
Add 'welcome banner' extension API ( #3656 )
...
* Add react-material-ui-carousel
Signed-off-by: Hung-Han (Henry) Chen <chenhungh@gmail.com >
* Add welcomeBanners extension api
Signed-off-by: Hung-Han (Henry) Chen <chenhungh@gmail.com >
2021-08-23 14:31:24 +03:00
Sebastian Malton
0a8cf96415
Add kube-version and distro on detail panel ( #3335 )
2021-07-14 08:30:57 -04:00
Sebastian Malton
c3c944cd30
Send LensMainExtension.nagivate calls to renderer before navigating ( #3082 )
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2021-06-17 12:59:27 +03:00
Alex Andreev
d14a3e4a6d
Adding Topbar extension registries ( #2997 )
...
* Move topbars to cluster manager
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Adding topBar extension registries
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* topbar test clean up
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Removing unused class
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Expanding CSS Module typings
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Fixing welcomeURL path
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Remove unused import
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Fix TopBarRegistry references
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Fixing topbar test
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Init missing registry
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
2021-06-14 07:40:14 +03:00
Jari Kolehmainen and Sebastian Malton
0fb927f96b
catalog details panel ( #2939 )
...
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
Co-authored-by: Sebastian Malton <sebastian@malton.name >
2021-06-07 10:09:00 +03:00
Lauri Nevala
9852e5cfd8
Implement extensions API for workloads overview details ( #2945 )
...
* Implement extensions API for workloads overview details
Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com >
* Prefix workloadsOverviewDetailItems
Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com >
* More renaming
Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com >
* Add missing registry
Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com >
2021-06-04 15:14:45 +03:00
Sebastian Malton
5ed4537979
Turn on noUnusedLocals, noImplicitReturns, importsNotUsedAsValues: error, and isolatedModules ( #2777 )
2021-05-19 12:11:54 -04:00
Jari Kolehmainen
2d0609ed24
Check source files for license header ( #2763 )
...
* check source files for license header
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* tweak
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* add license header to all relevant source files
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
2021-05-12 18:33:26 +03:00
Jari Kolehmainen
b1274cbb33
Extensible welcome page ( #2637 )
...
* welcome/landing page
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* fix integration tests
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
2021-04-27 11:24:39 +03:00
Jari Kolehmainen
8dde4a1ecb
Refactor cluster settings to catalog entity settings ( #2525 )
...
* fix cluster settings page layout
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* cleanup
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* refactor cluster settings to pluggable entity settings
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* fix
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* fix
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* fix gh actions network timeout on yarn install
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* review changes
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
2021-04-20 07:05:44 +03:00
Jari Kolehmainen
99a464c61d
Catalog & Hotbar - initial groundwork ( #2418 )
...
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
2021-04-09 09:11:58 +03:00
Sebastian Malton
1470103fd4
Add lens:// protocol handling with a routing mechanism ( #1949 )
...
- Add lens:// protocol handling with a routing mechanism
- document the methods in an extension guide
- remove handlers when an extension is deactivated or removed
- make sure that the found extension when routing a request is currently enabled (as a backup)
- added documentation about the above behaviour to the guide
- tweaked the naming convention so that it is clearer that the router uses extension names as not IDs (which currently are folder paths)
- Convert the extension API to use an array for registering handlers
- switch design to execute both main and renderer handlers simultaneously, without any overlap checking
- change open to be a dev dep
- improve docs, export types for extensions, skip integration tests
- switch to event emitting renderer being ready
- Add logging and fix renderer:loaded send to main
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2021-02-25 09:32:40 -05:00
Jari Kolehmainen
b5e7be7591
Initial command palette feature ( #1957 )
...
* wip: command palette
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* register shortcut to global menu
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* introduce openCommandDialog & closeCommandDialog
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* fix ipc broadcast to frames from renderer
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* tweak
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* add more commands
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* cleanup
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* ipc fix
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* add integration tests
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* ipc fix
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* implement workspace edit
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* workspace edit fixes
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* make tests green
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* fixes from code review
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* cleanup ipc
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* cleanup CommandRegistry
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* ipc fix
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* fix ClusterManager cluster auto-init
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* ensure cluster view is active before sending a command
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* switch to last active cluster when workspace change
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* tweak integration tests
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* run integration tests serially
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* cleanup
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* fixes based on code review
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* cleanup
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* cleanup more
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* cleanup
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* add workspace fixes
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
* cleanup
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
2021-02-02 12:34:13 +02:00
Roman
be4e1aa15c
Navigation refactoring, handling extension page params ( #1651 )
...
* decentralizing page url-params management -- PoC / tsc 4.1 random fixes
Signed-off-by: Roman <ixrock@gmail.com >
* fixes, tweak example-extension for demo
Signed-off-by: Roman <ixrock@gmail.com >
* lint fixes, revert tests
Signed-off-by: Roman <ixrock@gmail.com >
* removed occasional changes related to typescript 4.1
Signed-off-by: Roman <ixrock@gmail.com >
* updated example with 2 menu-items targeting same page with different params
Signed-off-by: Roman <ixrock@gmail.com >
* fix: merge page url chunks with native URL()-api, simplified default page-params registration
Signed-off-by: Roman <ixrock@gmail.com >
* fix: make lint happy
Signed-off-by: Roman <ixrock@gmail.com >
* fix: unit-tests
Signed-off-by: Roman <ixrock@gmail.com >
* renaming by jim's request: UrlParam => PageParam (type), createUrlParam => createPageParam (helper)
Signed-off-by: Roman <ixrock@gmail.com >
* fix: reverting NamespaceStore public-api breaking changes
Signed-off-by: Roman <ixrock@gmail.com >
* lint fix
Signed-off-by: Roman <ixrock@gmail.com >
* fine-tuning
Signed-off-by: Roman <ixrock@gmail.com >
* yes, lint always unhappy
Signed-off-by: Roman <ixrock@gmail.com >
* fix build
Signed-off-by: Roman <ixrock@gmail.com >
* small fixes
Signed-off-by: Roman <ixrock@gmail.com >
* fix merge-conflicts
Signed-off-by: Roman <ixrock@gmail.com >
* removed `isSystem` page-param's init field exposed to extensions-api
Signed-off-by: Roman <ixrock@gmail.com >
2020-12-22 15:29:25 +02:00
Panu Horsmalahti
dcf253e7d5
Add eslint rule padding-line-between-statements ( #1593 )
...
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com >
2020-12-02 09:55:52 +02:00
Sebastian Malton
7451869c25
add no-unused and react/recommended to eslint ( #1523 )
...
* add no-unused-vars and no-unused-imports
* added quotes: double, and remove ignore pattern
* move itif and describeif into utils
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2020-11-27 08:48:38 -05:00
Sebastian Malton
ca49fb98d9
remove @observable.shallow from Lens(M|R)Extension ( #1504 )
...
Signed-off-by: Sebastian Malton <sebastian@malton.name >
2020-11-24 12:41:57 -05:00
Jari Kolehmainen
1be86b34f4
Add LensRendererExtension.isEnabledForCluster ( #1502 )
...
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
2020-11-24 16:15:14 +02:00
Panu Horsmalahti
ff93760dc4
Enable object-shorthand rule ( #1500 )
...
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com >
2020-11-24 13:16:35 +02:00
Panu Horsmalahti
460dfe4d2b
Use @typescript-eslint/semi.
...
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com >
2020-11-19 18:12:52 +02:00
Panu Horsmalahti
1477bb8274
Enforce semicolons in eslint
...
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com >
2020-11-19 16:35:04 +02:00
Roman
13dbdac2f2
PageRegistration / PageMenuRegistration fixes & more simplification ( #1386 )
...
* PageRegistration & PageMenuRegistration fixes & more simplification, fix #1383
Signed-off-by: Roman <ixrock@gmail.com >
* clean up test, deprecate page.routePath
Signed-off-by: Roman <ixrock@gmail.com >
* fix: proper `isActive` state matching for page-menu-target to page considering current document location
Signed-off-by: Roman <ixrock@gmail.com >
2020-11-16 15:18:53 +02:00
Jari Kolehmainen and Roman
df0f080380
Simplify pages/menus/registry extension api internal implementation ( #1364 )
...
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
Co-authored-by: Roman <ixrock@gmail.com >
2020-11-13 17:04:39 +02:00
Roman and Jari Kolehmainen
faa1cef307
PageRegistration & BaseRegistry refactoring ( #1334 )
...
Signed-off-by: Roman <ixrock@gmail.com >
Co-authored-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
2020-11-12 16:29:02 +02:00
Jari Kolehmainen
4222359bd6
Add LensRendererExtension.navigate ( #1345 )
...
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
2020-11-12 10:30:57 +02:00
Lauri Nevala
85c4a10114
Implement KubeObjectStatusText extension API ( #1188 )
...
Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com >
2020-11-11 08:57:15 +02:00
Jari Kolehmainen
70a8982c9f
Add missing kubeObjectDetailItems observable to LensRendererExtension ( #1187 )
...
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
2020-10-30 21:49:16 +02:00
Roman
67754ffbb9
Get rid of this.disposers while registering stuff in extensions ( #1148 )
...
Signed-off-by: Roman <ixrock@gmail.com >
2020-10-27 17:07:21 +02:00
Alex Andreev
e9ebd06664
Allowing any item for StatusBarRegistration ( #1143 )
...
* Adding extension's label text next to Icon
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
* Removing unused registerStatusBarItem()
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com >
2020-10-26 17:29:54 +03:00
Roman
9b9bf47970
Refactor PageRegistration to separate registries/interfaces #1130 ( #1144 )
...
Signed-off-by: Roman <ixrock@gmail.com >
2020-10-26 15:40:34 +02:00
Jari Kolehmainen
62ae7771df
Allow extensions to define cluster features ( #1125 )
...
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com >
2020-10-26 08:21:22 +02:00
Roman and Jim Ehrismann
f3a0059355
Extension support page ( #1112 )
...
Signed-off-by: Roman <ixrock@gmail.com >
Co-authored-by: Jim Ehrismann <40840436+jim-docker@users.noreply.github.com >
2020-10-24 09:24:54 +03:00