Skip to content

rux-monitoring-icon can't be resized #970

@run2xs

Description

@run2xs

We have a rux-monitoring-icon in our rux-global-status-bar and are refactoring our status bar to match the latest Astro guidelines (confirmed with Austin). The current rux-monitoring-icon won't fit nicely in the new design:

image

I am unable to find a way to resize a rux-monitoring-icon without doing something like this:

  ngAfterViewInit() {
    this.resizeIcon(0);
  }

  resizeIcon(attempts) {
    const ruxIcon = document.querySelector('#rmi').shadowRoot.querySelector('rux-icon');
    if (ruxIcon) {
      ruxIcon.size = '.8rem';
    } else if (attempts < 10) {
      setTimeout(() => {
        this.resizeIcon(attempts++);
      }, 10);
    }
  }

Unfortunately, that only changes the main icon, and the secondary icon is out of place and too big relative to the main one. Adding a part selector for the rux-icon wouldn't help because of this. I am unable to control the size or position of the secondary icon.

Screen Shot 2022-12-08 at 8 39 27 AM

Could you please add a "size" attribute to the rux-monitoring-icon so we can control how big it is? Resizing the div containing the rux-monitoring-icon helps a little but that leads to other wonkiness.

Metadata

Metadata

Assignees

Labels

designRelated to design - Needs design or UX inputenhancementNew feature or request. These should be converted into discussions.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions