1
0
mirror of https://github.com/lensapp/lens.git synced 2024-09-20 22:07:31 +03:00
Commit Graph

57 Commits

Author SHA1 Message Date
Jari Kolehmainen
fa94773bf3
Electron 9.4.0 (#1799)
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
2020-12-29 17:42:01 +02:00
Jari Kolehmainen
a03da3c572
Remove lingui (#1874)
* remove lingui

Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>

* babelless

Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>

* tweak ts-loader options

Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>

* tweak renderer webpack config

Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
2020-12-29 14:53:34 +02:00
Alex Andreev
5d746cdff5
Dock tabs context menu (#1863)
* Adding context menu to dock tabs

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

* Allowing to open menu by contextmenu event

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

* Adding DockTab tests with fine-tuning jest config

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

* Adding disable state to menu items

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

* Removing empty lines

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

* Moving jest-canvas-mock to dev dependencies

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2020-12-28 15:18:03 +03:00
Jari Kolehmainen
24b5d2dff9
Optimise Cluster.getAllowedResources() (#1830)
* optimise Cluster.getAllowedResources()

Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>

* make it faster (max 5 concurrent requests)

Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
2020-12-22 16:09:52 +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
Roman
d281ff4a21
Fix: missing dependent types for Select and Slider components (#1828)
* Types for Select and Slider components are not fully exported, fix #1824

Signed-off-by: Roman <ixrock@gmail.com>

* remove unused @types/material-ui package

Signed-off-by: Roman <ixrock@gmail.com>
2020-12-22 14:38:06 +02:00
Sebastian Malton
320bd05d5a
bump eslint-plugin-unused-imports to 1.0.1 (#1577)
Signed-off-by: Sebastian Malton <sebastian@malton.name>
2020-11-30 13:00:13 -05:00
Jari Kolehmainen
245eab0120
Electron 9.3.5 (#1562)
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
2020-11-30 09:14:05 +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
Panu Horsmalahti
263d56b3c1
Disable Uninstall and Enable/Disable buttons while uninstalling. Add Notification for uninstall. (#1539)
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com>
2020-11-27 10:23:12 +02:00
Panu Horsmalahti
4e02e086a9
Remove extension when folder is removed during runtime (#1518)
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com>
2020-11-26 09:40:37 +02:00
Roman
7243dfdce4
Installing extensions UI improvements (#1522)
Signed-off-by: Roman <ixrock@gmail.com>
2020-11-25 16:42:19 +02:00
Roman
77ae31550a
Allow to install packed extensions from URL or local file (#1456)
* Option to install an extension from filesystem/url #1227 -- part 1 (UI)

Signed-off-by: Roman <ixrock@gmail.com>

* DropFileInput: common component to handle droped files (replaced also in add-cluster-page)

Signed-off-by: Roman <ixrock@gmail.com>

* fix: install via url-string on input.submit

Signed-off-by: Roman <ixrock@gmail.com>

* ui tweaks & minor fixes

Signed-off-by: Roman <ixrock@gmail.com>

* more ui/ux tweaks & fixes

Signed-off-by: Roman <ixrock@gmail.com>

* layout fixes

Signed-off-by: Roman <ixrock@gmail.com>

* component renaming: `copy-to-click` => `copy-to-clipboard` => `clipboard`

Signed-off-by: Roman <ixrock@gmail.com>

* reworks -- part 1

Signed-off-by: Roman <ixrock@gmail.com>

* fix downloading file, added common/utils/downloadFile

Signed-off-by: Roman <ixrock@gmail.com>

* confirm before install, unpack tar first steps

Signed-off-by: Roman <ixrock@gmail.com>

* installation flow, extracting .tgz

Signed-off-by: Roman <ixrock@gmail.com>

* clean up, fix lint issues

Signed-off-by: Roman <ixrock@gmail.com>

* update .azure-pipelines.yml

Signed-off-by: Roman <ixrock@gmail.com>

* fixes & refactoring

Signed-off-by: Roman <ixrock@gmail.com>

* fix lint harder :/

Signed-off-by: Roman <ixrock@gmail.com>

* fix validation

Signed-off-by: Roman <ixrock@gmail.com>

* fix validation harder

Signed-off-by: Roman <ixrock@gmail.com>

* responding to comments, fixed package validation

Signed-off-by: Roman <ixrock@gmail.com>

* common/utils/tar.ts: reject with Error-type

Signed-off-by: Roman <ixrock@gmail.com>

* fix: unit-tests

Signed-off-by: Roman <ixrock@gmail.com>
2020-11-25 09:55:28 +02:00
Panu Horsmalahti
2a8cfe5e67
Add React Developers Tools (#1410)
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com>
2020-11-24 12:45:12 +02:00
Panu Horsmalahti
c79cee0311
Watch for added/removed local extensions (#1482)
Signed-off-by: Panu Horsmalahti <phorsmalahti@mirantis.com>
2020-11-24 10:48:40 +02:00
Jari Kolehmainen
596e60a6f3
Generate extension-api .d.ts and .js files using tsc (#1387)
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
2020-11-16 15:09:16 +02:00
Jari Kolehmainen
469b723469
Generate extension api reference docs using library mode (#1307)
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
2020-11-11 09:02:26 +02:00
chh
3eeb395a78
Remove hard-source-webpack-plugin (#1305)
Signed-off-by: Hung-Han (Henry) Chen <1474479+chenhunghan@users.noreply.github.com>
2020-11-10 12:13:01 +02:00
Alex Andreev
b2f3cdd0d2
Keeping Icon focus state only for keyboard (#1234)
* Passing toolbar prop into action menus

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

* Toggling .mouse-intent

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

* Icon focus restyling

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

* Adding what-input dependency

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2020-11-10 12:36:06 +03:00
Mario Sarcher
de85229512 Generate API Reference documentation using typedocs and gh-actions
Signed-off-by: Mario Sarcher <msarcher@mirantis.com>
2020-11-10 09:36:28 +01:00
chh
85f0ef8c2e
Add webpack hot-reload/cache plugins to improve Lens DX (#1250)
* Add webpack-dev-server (for hot module replacement) to serve statics, add HardSourceWebpackPlugin to improve re-compiling speed

* Serve statics using webpack-dev-server instead of lens-proxy, redirect request of Lens.html/Lens.js to webpack-dev-server

* Add react-refresh-webpack-plugin and its dep for hot-reload

* Add hot-reload plugin, and make proxy redirects requests to webpackdevserver

* Add hard-source webpack plugin to main process

* Remove parameter 'path' of handleStaticFile

* Upgarde webpack to v4 latest stable

* Fix build error: plugins shouldnt be null

Signed-off-by: Hung-Han (Henry) Chen <1474479+chenhunghan@users.noreply.github.com>
2020-11-09 21:04:41 +08:00
chh
484de2ec21
Add +/- buttons in scale deployment popup screen (#1191)
* Add @testing-library/jest-dom and @testing-library/react for writing test cases

* Make eslint check __mocks__/*.ts files

* Mock electron.ipcRenderer.on to prevent errors in React compoment test cases

* Mock <Trans /> from @lingui/macro as a component simplely returns children components

* Use optional chaining operator (?.) to avoid TypeError: Cannot read property 'replicas' of undefined

* Add jest-fetch-mock for mocking global.fetch, activate for all test cases in jest.setup.ts

* Add basic tests for <DeploymentScaleDialog /> to ensure it initialises/renders without errors

* Add +/- button for changing desired replicas, and its test cases

* Adjust the styles of +/- buttons container to make sure it aligns with the slider

* Refactor after rebase from master

* Use var defined in vars.scss

* Add flex align-center to slider-container and remove margin-top: -4px

* Use <Icon /> to replace <i/>

* Add flex gaps to plus-minus-container

Signed-off-by: Hung-Han (Henry) Chen <1474479+chenhunghan@users.noreply.github.com>
2020-11-03 20:30:36 +08:00
Roman
334815f71a
Tray icon (#1005)
* Tray icon #833 -- part 1

Signed-off-by: Roman <ixrock@gmail.com>

* Tray icon #833 -- part 2

Signed-off-by: Roman <ixrock@gmail.com>

* Tray icon #833 -- part 3

Signed-off-by: Roman <ixrock@gmail.com>

* Tray icon #833 -- part 4

Signed-off-by: Roman <ixrock@gmail.com>

* fix: lint / linux build failed

Signed-off-by: Roman <ixrock@gmail.com>

* allow to disable tray from preferences

Signed-off-by: Roman <ixrock@gmail.com>

* allow to tweak svg-icon before applying as tray-icon

Signed-off-by: Roman <ixrock@gmail.com>

* add checkbox indication, setActive workspace on cluster select

Signed-off-by: Roman <ixrock@gmail.com>

* fix build version (cannon find module 'react')

Signed-off-by: Roman <ixrock@gmail.com>

* - switching dark/light icon depending on os-x theme settings
- optimization: don't re-create tray icon on menu udpates (avoid blinking)

Signed-off-by: Roman <ixrock@gmail.com>

* fix: refresh icon after turning on/off + switching dark-mode

Signed-off-by: Roman <ixrock@gmail.com>

* allow to close main window and re-open from dock or tray icon

Signed-off-by: Roman <ixrock@gmail.com>

* small fix

Signed-off-by: Roman <ixrock@gmail.com>

* fix: ensure main-window from global menu

Signed-off-by: Roman <ixrock@gmail.com>

* chore

Signed-off-by: Roman <ixrock@gmail.com>

* fix: hide traffic-light buttons for tray window

Signed-off-by: Roman <ixrock@gmail.com>

* removed redundant tray window

Signed-off-by: Roman <ixrock@gmail.com>

* removed delay from base-store

Signed-off-by: Roman <ixrock@gmail.com>

* adding cluster fix (reverted changes from master)

Signed-off-by: Roman <ixrock@gmail.com>

* - hide icon in dock when main-window closed (mac-os only)
- added preferences checkbox to open app at system start-up

Signed-off-by: Roman <ixrock@gmail.com>

* handle quit app action from tray menu

Signed-off-by: Roman <ixrock@gmail.com>

* moved generating tray icons to build step

Signed-off-by: Roman <ixrock@gmail.com>

* Fix integration tests (#1080)

* Fix integration tests

Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com>

* Update integration/helpers/utils.ts

Co-authored-by: Sebastian Malton <sebastian@malton.name>
Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com>

Co-authored-by: Sebastian Malton <sebastian@malton.name>

* fix-build: invisible app icon when there are more files within "build/icons/*.png"

Signed-off-by: Roman <ixrock@gmail.com>

* chore

Signed-off-by: Roman <ixrock@gmail.com>

* yarn i18n.extract

Signed-off-by: Roman <ixrock@gmail.com>

* clean-up

Signed-off-by: Roman <ixrock@gmail.com>

* navigation refactoring, move out `buildUrl` to common/utils so `react` and `react-router` not required as package.json dependecies in runtime (main)

Signed-off-by: Roman <ixrock@gmail.com>

* Ignore namespace query param on integration tests (#1109)

Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com>

* merge-conflicts fixes

Signed-off-by: Roman <ixrock@gmail.com>

* support page fixes

Signed-off-by: Roman <ixrock@gmail.com>

* make eslint happy again

Signed-off-by: Roman <ixrock@gmail.com>

Co-authored-by: Lauri Nevala <lauri.nevala@gmail.com>
Co-authored-by: Sebastian Malton <sebastian@malton.name>
2020-10-27 15:25:29 +02:00
Roman
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
Jari Kolehmainen
c566c85351
Move tracker to telemetry extension (#1092)
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
2020-10-19 11:56:08 +03:00
Jari Kolehmainen
a00d26149c Merge branch 'master' into extensions-api
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
2020-10-16 07:58:47 +03:00
Lauri Nevala
3a6b499fe3 Merge branch 'extensions-api' of github.com:lensapp/lens into extensions-api 2020-10-14 09:15:46 +03:00
steve richards
4fcac6b0d0
Added additional checks on the command used in the Exec plugin in a kubeconfig (#1013)
- Added check to see if the program being referenced in the command field of the
exec object in the User construct exists. If it doesn't an error will be raised.
If more than 1 context is selected when adding a kubeconfig then valid contexts
will be added and any with an error will not be.

Signed-off-by: Steve Richards <srichards@mirantis.com>

Co-authored-by: Steve Richards <srichards@mirantis.com>
2020-10-12 10:20:08 +03:00
Sebastian Malton
0960259279
Add some basic unit tests for the following files: (#1050)
* Add some basic unit tests for cluster, kube-auth-proxy, and kubeconfig-manager

- src/main/cluster.ts
- src/main/kube-auth-proxy.ts
- src/main/kubeconfig-manager.ts

Signed-off-by: Sebastian Malton <sebastian@malton.name>
2020-10-09 11:25:20 -04:00
Jari Kolehmainen
4f98a01a8b
Improve how extension-api is exposed/loaded (#1055)
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
2020-10-09 14:12:40 +03:00
Lauri Nevala
0f57ea91b1 Merge branch 'master' into extensions-api 2020-10-06 14:52:27 +03:00
Jari Kolehmainen
2b6f283e1b
Allow extensions to have external dependencies (#1018)
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
2020-10-05 16:39:58 +03:00
Sebastian Malton
9ecfeb316c
cleanup Draggable into ResizingAnchor (#989)
* Rename `Draggable` as `ResizingAnchor` since that is what it is used for and shouldn't be mistaken as a general draggable item

* Refactor `ResizingAnchor` to be much more smart about how it handles mouse movements. Allow it to know which direction the resizing should be in allowing it to produce exact resized values.

* Add event handlers for the min and max extents so that actions can be triggered when those extents are passed (in either direction)

* Add double click support

Signed-off-by: Sebastian Malton <sebastian@malton.name>
2020-10-01 11:37:27 -04:00
Roman
5ec6751ab4
Extensions api types (#985)
Signed-off-by: Roman <ixrock@gmail.com>
2020-09-29 07:37:25 +03:00
Roman
91b4823ec6 Merge branch 'master' into extensions-api
# Conflicts:
#	src/renderer/components/app.tsx
#	src/renderer/components/cluster-manager/clusters-menu.scss
#	src/renderer/components/cluster-manager/clusters-menu.tsx
#	src/renderer/components/layout/main-layout.tsx
#	src/renderer/components/layout/sidebar.tsx
2020-09-23 11:49:16 +03:00
Jari Kolehmainen
c2afd026cc
Inject Host header to k8s client requests (#887)
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
2020-09-16 20:54:36 +03:00
Roman
a3dc928430 Merge branch 'master' into extensions-api
# Conflicts:
#	package.json
#	src/common/cluster-store.ts
#	src/renderer/bootstrap.tsx
#	src/renderer/components/cluster-manager/clusters-menu.tsx
#	static/RELEASE_NOTES.md
#	webpack.dll.ts
2020-09-11 12:29:38 +03:00
Sebastian Malton
8d1f0efe80
remove make-syncronous and file-type calls from migration (#844)
* remove make-syncronous and file-type calls from migration

Signed-off-by: Sebastian Malton <smalton@mirantis.com>

Co-authored-by: Sebastian Malton <smalton@mirantis.com>
2020-09-09 16:41:25 -04:00
Roman
f1b03990ea
Extensions loading (#795)
Signed-off-by: Roman <ixrock@gmail.com>

Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com>
Co-authored-by: Lauri Nevala <lauri.nevala@gmail.com>
2020-09-09 13:00:25 +03:00
Sebastian Malton
295333d055
add progress bar for webpack compilation (#794)
Signed-off-by: Sebastian Malton <smalton@mirantis.com>

Co-authored-by: Sebastian Malton <smalton@mirantis.com>
2020-09-08 08:44:34 -04:00
Alex Andreev
06b4bfe363
Removing DEBUG env from package.json commands (#810)
* Removing DEBUG env from dev processes

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

* Removing cross-env dependency

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

* Updating lock file

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
2020-09-07 12:10:35 +03:00
Sebastian Malton
8f94f4a3da
add drag and drop capabilities for the order of cluster icons on the side bar (#623)
* add drag and drop capabilities for the order of cluster icons on the side bar

* add type annotations for better clarity

* fix clusters staying in previously icon reordered workspaces

* add some tests to cluster-store

Signed-off-by: Sebastian Malton <smalton@mirantis.com>

Co-authored-by: Sebastian Malton <smalton@mirantis.com>
2020-09-04 13:32:27 -04:00
Sebastian Malton
8c0ee5dc37
upgrade eslint typescript parser (#773)
Signed-off-by: Sebastian Malton <smalton@mirantis.com>

Co-authored-by: Sebastian Malton <smalton@mirantis.com>
2020-09-01 09:27:39 -04:00
Sebastian Malton
a12aa8a04f
add cluster icon migration code (#673)
Signed-off-by: Sebastian Malton <smalton@mirantis.com>
2020-08-25 16:42:30 +03:00
Lauri Nevala
b75cac4546
Fix windows dev env (#722)
Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com>

Co-authored-by: Trevor Nichols <trevor@ml.net.au>
2020-08-25 11:08:46 +03:00
Roman
5163ede4f1
package.json: upgrade typescript to 4.x (#725)
Signed-off-by: Roman <ixrock@gmail.com>
2020-08-20 21:01:33 +03:00
Roman
5670312c47
Migrating Vue components to React and stores refactoring (#585)
Signed-off-by: Roman <ixrock@gmail.com>

Co-authored-by: Sebastian Malton <sebastian@malton.name>
Co-authored-by: Sebastian Malton <smalton@mirantis.com>
Co-authored-by: Lauri Nevala <lauri.nevala@gmail.com>
Co-authored-by: Alex Andreev <alex.andreev.email@gmail.com>
2020-08-20 08:53:07 +03:00
Roman
b7974827d2
Lens restructure (#540)
Signed-off-by: Roman <ixrock@gmail.com>
2020-06-30 14:35:16 +03:00
Lauri Nevala
78eeef2805
Close proxy server on app quit (#413)
Signed-off-by: Lauri Nevala <lauri.nevala@gmail.com>
2020-06-10 17:00:17 +03:00
dependabot[bot]
a36a279bce
Bump websocket-extensions from 0.1.3 to 0.1.4 (#409)
Bumps [websocket-extensions](https://github.com/faye/websocket-extensions-node) from 0.1.3 to 0.1.4.
- [Release notes](https://github.com/faye/websocket-extensions-node/releases)
- [Changelog](https://github.com/faye/websocket-extensions-node/blob/master/CHANGELOG.md)
- [Commits](https://github.com/faye/websocket-extensions-node/compare/0.1.3...0.1.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-06-09 14:35:03 +03:00