Commit Graph

169 Commits

Author SHA1 Message Date
Neil MacDougall bb02892585
Add support for Individual banner settings (#11200)
* Add support for individual banners

* Fixes

* Add tags to e2e tests

* Update e2e tests

* Revert changed

* Fix lint issues with trailing spaces

* Update e2e tests for login consent banner

* Update test for re-factor

* Fix lint

* Fix e2e banner tests

* Don't run individual banner tests for the standard user

* Ensure after hook runs after the standard tests, not the individual banner tests

* Fix updating existing ui-banners setting
2024-06-12 15:05:11 +01:00
Richard Cox a5661c575f
Remove usages of findAll for types supported by server-side pagination (#10795)
* Changes for new design
- New visuals
- Pagination controls --> load more
- finished testing of label select with pagination off

# Conflicts:
#	shell/edit/provisioning.cattle.io.cluster/__tests__/Basics.tests.ts

* Changes following review

* Update Node list to support server-side pagination
- Setup pagination headers for the node type
- Define a pattern for fetching custom list secondary resources
- Major improvements to the way pagination settings are defined and created
- Lots of docs improvements
- Handle calling fetch again once fetch is in progress (nuxt caches running request)
- Validate filter fields (not all are supported by the vai cache
- General pagination fixes

* Lint / test / fixes

* Improvements to configmap e2e test & Improve pagination disabled

* Beef up validation

* Fix missing name column in non-server-side paginated node list

* Fix PR automation actions
- fix syntax
- catch scenario where a pr has no fixed issue

> There's duplication between files, see https://github.com/rancher/dashboard/pull/10534

* CI bump

* Fixes post merge

* Wire in 2.9.0 settings for server-side pagination
- Everything is gated on `on-disk-steve-cache` feature flag
  - There's a backend in progress item to resolve a `revision` issue, until then disable watching a resource given it
- Global Settings - Performance
  - Added new setting to enable server side pagination
  - this is incompatible with two other performance settings

* Integrate pagination with configmaps in cis clusterscanbenchmark edit form
Also
- improved labeled select pagination
- gate label select pagination functinality on steve cache being enabled

* - harvester machine-config
- project monitoring (and bug fixes)

* Disable workload screen if vai cache is on
- temp step until we get new overview

* TODOs and TEST

* Conditionally remove fetch of all secrets from SelectOrCreateAuthSecret

* TODOs and TEST

* Update SimpleSecretSelector
- only used in monitoring.coreos.com.alertmanagerconfig context

* View and Edit ingress - secrets

* node detail page - pods list

* Backup/Restore: Secrets (WIP)

* Backup/Restore: Secrets, and other usages of SimpleSecretSelector / SelectOrCreateAuthSecret

* Edit: Service account

* Add comments for remaining items

* Paginate Secret selection for logging providers
- Allow `None` option in Paginationed LabelSelect
- Optionally classify pagination response

* WIP

* fixes arfter merge

* Don't suggest container names, not practical
- previously all pods were fetched... and we scrapped all container names from them
- this is a scaling nightmare, user now must just enter the name/s to match

* Avoid findAll secrets in SimpleSecretSelector

* tidying up

* Move LabeledSelect/index.vue back to LabeledSelect.vue to not break extensions

* changes after self review... 1

* changes after self review... 2

* ooof

* changes after self review... 3

* fix formatting

* Link new paginated label select with pagination setting

* Work around failing kubewarden unit tests in check-plugins gate

* Fix backup.spec e2e test

* fix formatting, paginationUtils.isSteveCacheEnabled --> paginationUtils.isEnabled

* Don't fetch all secrets on cloud creds page

* Fix backup.spec e2e test

* TODO tidying / tracking

* don't getch ALL workloads for hacky way to get a link to a service's workload

* Fix bad merge

* Create a convienence wrapper called ResourceLabelSelector that hides most of the complexity

* fix unit test

* Updates following review

* changes following self review

* Fix bottom bar of edit backup, edit restore pages

* revert temp change

* changes following self review

* Workaround for kubewarden unit tests in check plugin gate

* bump

* Fix e2e
2024-06-05 09:15:43 +01:00
Neil MacDougall 826f68fb8a
Remove version number from side nav and update app bar to show it instead (#11143)
* Tweaks

* Add automated tests

* Fix merge issue

* Fix lint issues
2024-06-03 09:51:03 +01:00
Alexandre Alves 3bbf0cafbc
Local cluster does not appear at the top of the app bar (#11058)
* Update shell/components/nav/TopLevelMenu.vue

Co-authored-by: Phillip Rak <rak.phillip@gmail.com>

* fix lint error with Trailing spaces not allowed in TopLevelMenu + add sneaky fix for cluster and project members side nav item not being highlighted

* make sure local cluster appears always on top of pinned and unpinned cluster lists in main nav menu + add unit tests

---------

Co-authored-by: Phillip Rak <rak.phillip@gmail.com>
2024-05-22 10:12:35 +01:00
Izaac Zavaleta be1bad5445
Merge pull request #11057 from izaac/cluster_actions
[Automation] - Cluster Actions Header
2024-05-21 11:40:43 -07:00
Alexandre Alves 7af0c0b473
The highlighted cluster in the App Bar retains its highlighting even when clicking on an item from the bottom category of the App Bar (#11055)
* fix issue with double active main menu items in app bar + add e2e test to prevent regression

* Update shell/components/nav/TopLevelMenu.vue

Co-authored-by: Phillip Rak <rak.phillip@gmail.com>

* fix lint error with Trailing spaces not allowed in TopLevelMenu + add sneaky fix for cluster and project members side nav item not being highlighted

---------

Co-authored-by: Phillip Rak <rak.phillip@gmail.com>
2024-05-21 18:01:08 +01:00
Izaac Zavaleta 8e3317951b Cluster Actions Header 2024-05-20 10:55:16 -07:00
Neil MacDougall da47da7ab1
Add e2e test for resource search and namespace filter issue (#10932)
* Add e2e test for resource search and namespace filter issue

* Fix lint issues
2024-05-07 09:07:25 +01:00
Sorin 08f11a5d81
fixes i18n, new Cluster Appearance UX (#10677)
* fixes i18n and small UX
* new layout design for the modal
* enables edit badge from cluster explorer

---------

Signed-off-by: scures <scurescu@suse.com>
2024-04-29 17:12:16 +02:00
Alexandre Alves 7be2f2e81a
add mgmt cluster description to prov cluster description as fallback in home cluster list and main side nav clusters (#10782)
* add mgmt cluster description to prov cluster description as fallbacks in home cluster list and main side nav clusters

* address pr comments

* add e2e to test description for rke1 cluster in home page

* address pr comments
2024-04-20 10:03:18 +01:00
Cody Jackson e205b568ee Updating <router-link> to no longer use the deprecated :tag property 2024-04-18 04:23:04 -07:00
Alexandre Alves e6c4d0194e
Don't show state column on import yaml dialog (#10730)
* remove state col and subrows from import YAML action success screen + add tests

* fix e2e test issue

* address pr comments

* address pr comments
2024-04-09 09:04:30 +01:00
Alexandre Alves 7cc94dcf44
fix visual bug with cluster description on main side nav (#10767) 2024-04-08 16:22:05 +01:00
Richard Cox 7108e56e66
Merge pull request #10349 from richard-cox/pagination
Server-side pagination - First, limited change, disabled in code
2024-04-05 10:03:37 +01:00
Alexandre Alves c7ffa7477c
10153: add e2e test (#10731)
* add e2e test

* fix e2e test issue

* fix e2e test issue
2024-04-04 09:50:40 +01:00
Richard Cox 09614b0136 Server-side pagination
Polish and fixes from alpha
2024-04-02 13:34:36 +01:00
Richard Cox ae7eb102ad Pagination Alpha 2024-04-02 13:34:36 +01:00
Alexandre Alves bf435d691d
add missing translation to hardcoded string and adjust of copy + change key shortcut to ALT key only + remove lodash usage (#10707) 2024-04-01 17:00:59 +01:00
Phillip Rak 6206f9763c
Merge pull request #10716 from rak-phillip/chore/remove-nuxt-link
Replace `nuxt-link` with `router-link`
2024-04-01 08:00:12 -07:00
Neil MacDougall f6c80b295f
Add root product to improve performance of nav change within inExplorer products (#10447)
* Fix race condition in loadCluster

* Revert new error and comments

* Improve navigation performance for products within the explorer product

* Remove unused getter

* Fix issue with not loading nwe cluster when changing clusters

* Fix bug where sidenav take a short time to update (was using queueUpdate)

* Fix lint issues

* Address PR feedback
2024-03-28 09:28:23 +00:00
Phillip Rak 7e703b4c74 Replace `nuxt-link` & `n-link` with `router-link`
Signed-off-by: Phillip Rak <rak.phillip@gmail.com>
2024-03-27 14:04:17 -07:00
Francesco Torchia 294e7bc741
Merge pull request #10596 from torchiaf/10561-navlinks
Remove Vue `getMatchedComponents`
2024-03-27 11:13:23 +01:00
Richard Cox 513ba0c219
Merge pull request #10601 from richard-cox/fix-legacy-project-menu-item
Fix Legacy / Project group
2024-03-26 15:33:00 +00:00
Evgeniya Vashkevich 4503cda47d
[FIX] Fixed clicking on a group header outside of text not working (#10670)
* [FIX] Fixed clicking on a group header outside of text
2024-03-22 14:46:28 -07:00
Richard Cox f12a13afcb changes following review 2024-03-22 16:15:23 +00:00
Richard Cox 286cbe3c72 Fix Legacy / Project group
- fixed scenario exposed by the project virtual type where call to allTypes ruled out all virt / spoofed types if basic mode has an inavalid entry (!groupForBasicType)
- however also removed the project virtual type. the nav item comes from `Project` group specified in `basicTypes` call)
- fixed a few things around the project group
  - add label for project group
  - explicitely set project group root of app
- fixed display of namespace icon for a menu item if there are no counts
2024-03-22 10:48:56 +00:00
Alexandre Alves 05d4cea23a
Allow switching between down stream clusters with a dropdown menu (#10535)
* add logic to handle key combos + add route change on key combo press

* fix issue with tooltip position + add correct icon for when key combo pressed + added all logic to make key combo capture and route change work

* final adjustments + bug fix with width of text in side nav which caused horizontal scroll

* add e2e test

* finish key combo logic + finish e2e tests

* fix icon in dark mode

---------

Co-authored-by: Alexandre Alves <aalves@Alexandres-MacBook-Pro.local>
2024-03-21 14:00:44 +00:00
Phillip Rak 4a9ce08614
Merge pull request #10591 from rak-phillip/feature/8207-modal-replace
Replace `vue-js-modal` with `app-modal`
2024-03-13 09:58:02 -07:00
Phillip Rak bc36082391 Replace instances of `<modal>`
Signed-off-by: Phillip Rak <rak.phillip@gmail.com>
2024-03-12 15:37:44 -07:00
Francesco Torchia 8f62c2e930
Remove getMatchedComponents as deprecated
Signed-off-by: Francesco Torchia <francesco.torchia@suse.com>
2024-03-11 18:38:58 +01:00
codyrancher b0d2dcbeb4
Vue 3 Nuxtism Removal (#10533)
* Removing everything related to scrollTrigger.

The latest vue router seems to behave exactly as it does with the modified scrollBehavior so it can all be removed.

* Removing unused $nuxt.{suffixes} that I found
- routeChanged  (didn't find any watches of this event)
- nbFetching (The only place reading this was a computed property which wasn't used anywhere)

* Replace the use of Vue[installKey]

* Removing some ssr rehydration code since we're not doing ssr

* Remove the remaining $nuxt.$on,$off,$emit and replace with the use of our primary store which already had related code

* Replacing usages of the .$nuxt on vue instances with globalApp references

* Removing SSR dead code

* Fixing an issue where extensions could still be referencing window.$nuxt. This now provides a deprecation warning.

* Migrating another $nuxt over to the window.$globalApp

* Removed the usage of Vue.config.$nux

* Removed the usage of Vue.util.defineReactive

- Saw that the Nuxt component wasn't needed any longer so I removed it instead of trying to work around Vue.util.defineReactive

* Re-run missing check

---------

Co-authored-by: cnotv <giuseppe.leo@suse.com>
2024-03-11 18:38:25 +01:00
Alexandre Alves cd4882c683
Improve logout message for SSO (#10537)
* add logic to change copy of logout screen when logging out with an auth provider different than local

* fex e2e test

---------

Co-authored-by: Alexandre Alves <aalves@Alexandres-MacBook-Pro.local>
2024-03-01 17:09:54 +00:00
Alexandre Alves 319a0a0af6
Add cluster description to cluster side menu and main menu (#10487)
* add cluster description to home page cluster list and side menu clusters

* working on tooltip for long descriptions

* add tooltip to description on side menu

* remove console logs

* add tooltip to description on side menu + fine tune tooltip position

* finish tests

* fix e2e

* address test flakiness of repeated use of toggling main nav menu and not waiting for transitions

* address failing e2e tests + add missing array brackets to tests that only had tag as string (were not running)

* fix bug where clicking on home link wouldn't close the main nav + fix e2e

* update home link e2e getter with correct structure

* address #8854

* break long strings to next line

---------

Co-authored-by: Alexandre Alves <aalves@Alexandres-MacBook-Pro.local>
2024-03-01 16:39:59 +00:00
Richard Cox b464d15ee0
Integrate new schemaDefinitions endpoint (#10141)
* resource edit AS yaml

* fix cruresource (yaml from form)
- lazy load the schemaDefinitions when needed, avoids sync all to createYaml before we have an async chance to fetch schemaDefinitions

* Fix questions
- there are only four places we use questions, none of which use schema, this is just to be safe

* cluster scan, plugins/fieldsForDriver, defaultFor, validationErrors

* pathExistsInSchema
- used to optionally show conditions tab/list in resource detail view
- logs of things in ingress list/edit

* createPopulated / defaultFor
defaultFor requires resourceFields, it's only used by createPopulated in one place to support machine configs without components

* wip

* WIP MONITORING.SPOOFED
- these aren't spoofed types, but secondary schemas
- testing fix blocked, primary schema's have resourceFields

* Move steve specific (resourceField) code to steve models
- create models for steve schemas and apply to cluster and management stores
- move resoureField based validationto steve model
- move pathExistsInSchema to steve store getter
- don't fetch schemaDefinitions on start up when saving prefs (not needed and blocking)

* comments / improvements

* (untested) refactoring

* Fix alertmanager definitions, add retry definition fetch

* Fix pathExistsInSchema for path length > 2

* Fix questions that accept schemas
- tested by adding Questions to random page and the node schema

* Fix to saving configmap part 1
- the save works but doesn't show data. the yaml is the same as before. debug info added

* Validation by resourceFields is a norman specific thing, so make it such

* small refactor

* Tidying up

* Remove rebase junk

* fix linting and unit tests

* fix unit tests

* fix linting from fix for test....

* Tidying up, fix alertmanagerconfig

* Remove unit test todos

* add unit tests for resource fields

* sdssdf

* Add unit tests for pathExistsInSchema

* JS --> TS

* Store schemas in local singleton cache to avoid hitting store

* fix minor changes from review

* cruresource changes following review
- improvement - remove spurious canDiff
- createResourceYaml - pass in resource to use instead of calc in code

* WIP changes to parseType

* Fix generic cloud credential and node driver forms

* handle missing reactivity given schema definitions not in store

* fix and add unit tests for `parseType`

* Fix create-yaml test

* Changes following review
- improved comments
- SchemaDefinitionCache is now per store (and is reset as such)
- typeRef now uses parseType

* Fix dep loop by moving route based helps in auth out to utils file

* fix unit tests

* Changes following review
2024-02-28 17:08:35 +00:00
Cody Jackson 36a31a397e More informative page titles 2024-02-12 20:11:45 -07:00
Richard Cox 47333bd19d Changes following review
- fix / update comments
- allNavLinksKey --> allNavLinksIds
- remove horrible `typeof this.type.count !== 'undefined'`
2024-02-09 15:47:33 +00:00
Richard Cox b489361fbe Fix unit test 2024-02-09 15:47:33 +00:00
Richard Cox 48d5695359 Improve getGroups performances
- Improve performance of allTypes fn
  - This consumed the majority of time within getGroups
  - Reduced execution time by a half
  - Change from running allTypes products * modes times, run it once per product
- Reduce the amount of times getGroups is called
2024-02-09 15:47:33 +00:00
Sorin 8052619f61
APP Bar fixes (#10074)
* feat: app-bar fixes
2024-02-05 11:04:29 +01:00
yonasberhe23 3099aefcab
ui automation: global settings (#9458)
* ui automation: global settings

---------

Co-authored-by: Yonas Berhe <yberhe@Yonass-MacBook-Pro.local>
2024-02-01 15:06:03 -08:00
Alexandre Alves a35ebb2c2b
Fix for custom banner header without fontSize breaks top navigation (old obj structure) (#10242)
* support old ui-banner setting structure + update unit test to cover this scenario

* fix lint issue

---------

Co-authored-by: Alexandre Alves <aalves@Alexandres-MacBook-Pro.local>
2024-01-24 09:55:28 +00:00
Cody Jackson 48e1b0b3bb Layout removal
fixes #10059
2024-01-22 06:30:17 -07:00
Alexandre Alves f475841448
Fix highlight main nav menu items (#10212)
* add method to add class to highlight main menu items based on current route + make fleet routes use 'blank' cluster

* update e2e tests to check for active class on main nav menu in strategic specs that cover the main nav

* fix merge conflicts

* fix lint issue

* move higlight check to burguer menu po + remove duplicate condition check

* address pr comments

---------

Co-authored-by: Alexandre Alves <aalves@Alexandres-MacBook-Pro.local>
2024-01-15 14:10:49 +00:00
Alexandre Alves 0b1a331c3a
recreate pr 9831 + fix e2e tests (#10245)
Co-authored-by: Alexandre Alves <aalves@Alexandres-MacBook-Pro.local>
2024-01-10 17:09:53 +00:00
LiuYan c9bb8a19f0
fix(ContainerLogs): fix display error if log is truncated (#10197)
* fix(ContainerLogs): fix display error if log is truncated

* test(ContainerLogs): adding test cases for truncated log processing

* add test for empty string

---------

Co-authored-by: Alexandre Alves <aalves@Alexandres-MacBook-Pro.local>
2024-01-02 17:37:29 +00:00
Neil MacDougall 29d8f34ba5
Fix for Monitoring Helm chart sometimes adds empty selector (#10085)
* Fix for Monitoring Helm chart sometimes adds empty selector

* Correct close icon styling

* Tweak close icon width

* Fix lint issues
2023-12-14 13:23:25 +00:00
Alexandre Alves 6637583874
remove "process." mentions from Dashboard and adjust code (#10119)
* remove process.client and process.server mentions and adjust code

* fix a couple of missing conditions for process.server

* remove commented line

* remove process.static

* fix lint errors

* uncomment code

---------

Co-authored-by: Alexandre Alves <aalves@Alexandres-MacBook-Pro.local>
2023-12-13 08:41:26 +00:00
Richard Cox 73f28fb262 Ensure action header enabled arg used in invoke process matches that of button disabled 2023-11-15 19:12:16 +00:00
Neil MacDougall fdb061bfbb
Fix bug with container log formatting (#9967)
* Fix bug with container log formatting

* Fix lint issue
2023-11-03 09:05:32 +00:00
Giuseppe Leo ece9a33f2a
Add navigation menu item test (#9879) 2023-10-11 18:26:34 +02:00