rancher / dashboard

The Rancher UI
https://rancher.com
Apache License 2.0
451 stars 258 forks source link

Several issues on Pod detail view #11905

Open cnotv opened 2 weeks ago

cnotv commented 2 weeks ago

Description

Several issues have been found in the Pod details page.

  1. Extra editor tab
  2. Extra Namespace column in the table
  3. Tiny cosmetic issue: the space is trimmed

2.10

Screenshot 2024-09-12 at 21 11 24

2.9

Screenshot 2024-09-12 at 21 10 49
gaktive commented 1 week ago

@richard-cox believes this is tied to the inherent attributes being missing, so it needs to be added to the components.

aalves08 commented 1 week ago

1- There's a PR that fixes the problem with the lack of spacing in the restart counts.

2 - The namespace col is not appearing anymore... Couldn't repro that.

2.9 Image

2.10 Image

3- The YAML button part:

in 2.9: https://github.com/rancher/dashboard/blob/release-2.9/shell/components/ResourceDetail/index.vue#L389 https://github.com/rancher/dashboard/blob/release-2.9/shell/components/ResourceDetail/Masthead.vue#L31-L88 -> note that there is no prop canViewYaml hence why the button is not appearing, because all of the plumbing was there already…

master: https://github.com/rancher/dashboard/blob/master/shell/components/ResourceDetail/index.vue#L392 -> same prop being passed https://github.com/rancher/dashboard/blob/master/shell/components/ResourceDetail/Masthead.vue#L89-L92 -> Phil added the missing prop…. Now it’s connected, therefore the YAML button appears -----> part of vue3 migration PR

This is now a global problem.... Either we display it or we don't. I think that the lack of prop was on "purpose" to avoid lengthy changes in configs for individual resources and all. If the decision is to not show it, maybe we can "fix" it by explicitly defining the canYaml as false in the resource-class model.

I don't know if it has implications in the Edit via YAML or not, which should be pondered, but if possible, I would like to avoid setting configs individually...

Food for thought 🤔

aalves08 commented 5 days ago

@richard-cox , regarding the YAML button part, what is the best course of action? I am only missing that part to move this PR out of draft 🙏

richard-cox commented 5 days ago

Seems like this is an issue as old as time. Can you bring it up in the sync? i have a feeling then the visibility of the YAML button should remain

aalves08 commented 5 days ago

As discussed with @richard-cox and @kwwii , the extra editor tab (YAML button) is to be present on all views