plugins icon indicating copy to clipboard operation
plugins copied to clipboard

os-theme-advanced : Missing "Delete" Icon under System -> Snapshots

Open drinn opened this issue 1 year ago • 2 comments

Important notices Before you add a new report, we ask you kindly to acknowledge the following:

  • [X] I have read the contributing guide lines at https://github.com/opnsense/plugins/blob/master/CONTRIBUTING.md
  • [X] I have searched the existing issues, open and closed, and I'm convinced that mine is new.
  • [X] The title contains the plugin to which this issue belongs

Describe the bug The os-theme-advanced theme is missing an icon to delete a given snapshot.

To Reproduce Steps to reproduce the behavior:

  1. Go to System -> Snapshots
  2. On the right under commands, there are icons for Activate, Edit, and Clone, but Delete is missing as it is in the default theme.

Expected behavior A Delete button present like it is in the default theme.

Screenshots os-theme-advanced: image

default theme: image

Relevant log files N/A

Additional context N/A

Environment OPNsense 24.7.3 (amd64).

drinn avatar Aug 30 '24 13:08 drinn

Same situation in Haproxy list view, and the Add/Delete button seems narrower than usual. image

youring avatar Sep 12 '24 02:09 youring

Looking at the Settings -> Cron it seems table head has width of 7em. This causes issue with overflow that hiddes "Delete button".

image

Jackysi avatar Oct 21 '24 11:10 Jackysi

This issue has been automatically timed-out (after 180 days of inactivity).

For more information about the policies for this repository, please read https://github.com/opnsense/plugins/blob/master/CONTRIBUTING.md for further details.

If someone wants to step up and work on this issue, just let us know, so we can reopen the issue and assign an owner to it.

OPNsense-bot avatar Feb 26 '25 13:02 OPNsense-bot

@Jackysi are you still up for this? :)

fichtner avatar Mar 21 '25 07:03 fichtner

This issue has been automatically timed-out (after 180 days of inactivity).

For more information about the policies for this repository, please read https://github.com/opnsense/plugins/blob/master/CONTRIBUTING.md for further details.

If someone wants to step up and work on this issue, just let us know, so we can reopen the issue and assign an owner to it.

OPNsense-bot avatar Mar 21 '25 08:03 OPNsense-bot

@Jackysi are you still up for this? :)

Of course, but this isn't something I can fix on theme side? Since settings col width in HTML overrides CSS values there isn't much I can do. Unless I am missing something?

Jackysi avatar Mar 21 '25 10:03 Jackysi

@Jackysi hello! kind of, changing it in core will modify all even when not necessary, but:

@swhite2 I heard you were considering a sizing option for such cases as this?

fichtner avatar Mar 21 '25 12:03 fichtner

@fichtner the option would involve user input, however, the "default" should always show all commands with proper spacing.

If the theming influences the sizing of the buttons in a different way than core, there's not much we can do here except make it more spacious in all cases, which is not preferable.

As far as I can see the snapshots' commands width is hardcoded to 9em, which is fine in core and the theme should probably account for that

swhite2 avatar Mar 21 '25 13:03 swhite2

@fichtner the option would involve user input, however, the "default" should always show all commands with proper spacing.

If the theming influences the sizing of the buttons in a different way than core, there's not much we can do here except make it more spacious in all cases, which is not preferable.

As far as I can see the snapshots' commands width is hardcoded to 9em, which is fine in core and the theme should probably account for that

It would be preferable to switch such widths into CSS itself. So it can be overridden. E.g. using a class "action-buttons" and set 7-9em width there.

Hardcoding width into HTML where you have possibility to theme UI, seems odd.

Jackysi avatar Mar 21 '25 14:03 Jackysi

It would be preferable to switch such widths into CSS itself. So it can be overridden. E.g. using a class "action-buttons" and set 7-9em width there.

Hardcoding width into HTML where you have possibility to theme UI, seems odd.

The table plugin defines such properties via data-* attributes as the use-case is on a per-column basis (managing the width internally). Theme issues have rarely popped up because of it.

Moreover, each page may maintain a different set of commands and therefore different widths, so the problem isn't exactly generic.

I think the column width is beyond the scope of a theme plugin. If the theme causes a column to overflow, while the core product doesn't, the styling issue is likely not the width of the column.

swhite2 avatar Mar 21 '25 14:03 swhite2