frontend icon indicating copy to clipboard operation
frontend copied to clipboard

Alignment YAML configuration reloading page

Open jeroen85 opened this issue 3 years ago • 17 comments

Checklist

  • [X] I have updated to the latest available Home Assistant version.
  • [X] I have cleared the cache of my browser.
  • [X] I have tried a different browser to see if it is related to my browser.

Describe the issue you are experiencing

Alignment of YAML configuration reloading page is a bit strange at low page width (for example on my Android mobile app)

Describe the behavior you expected

Everything left aligned.

Steps to reproduce the issue

...

What version of Home Assistant Core has the issue?

2022.12.8

What was the last working version of Home Assistant Core?

No response

In which browser are you experiencing the issue with?

No response

Which operating system are you using to run this browser?

No response

State of relevant entities

No response

Problem-relevant frontend configuration

No response

Javascript errors shown in your browser console/inspector

No response

Additional information

No response

jeroen85 avatar Dec 24 '22 08:12 jeroen85

Chrome + Win10: image

iOS Companion App, iPhone 5S (iOS 12.5.x): image

iOS Companion App, iPad Air 2 (iOS 15.x): image

ildar170975 avatar Dec 24 '22 08:12 ildar170975

It occurs when the page width is smaller than 420 px Screenshot 2022-12-24 at 11 57 17

jeroen85 avatar Dec 24 '22 10:12 jeroen85

I managed to reproduce in in Chrome + Win10: image Resizing to a minimum width does not allow to get a narrow window (some "min-width" limitation here), but then I scaled the window (ctrl + mouse wheel) - and then reproduced it.

ildar170975 avatar Dec 24 '22 11:12 ildar170975

Resizing to a minimum width does not allow to get a narrow window (some "min-width" limitation here), but then I scaled the window (ctrl + mouse wheel) - and then reproduced it.

Just FYI, if you open up developer tools menu in Chrome or Firefox, they both have a tiny button that looks like a tablet, it puts the website into "Responsive design mode", and you can resize the page down to like 50-100px wide, much smaller than the normal resizing will get you.

image

karwosts avatar Dec 29 '22 23:12 karwosts

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Mar 30 '23 00:03 github-actions[bot]

Not stale

jeroen85 avatar Mar 30 '23 07:03 jeroen85

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Jun 28 '23 08:06 github-actions[bot]

Related: #9910 #7639

karwosts avatar Jun 28 '23 13:06 karwosts

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Sep 26 '23 20:09 github-actions[bot]

Not fixed

jeroen85 avatar Sep 27 '23 04:09 jeroen85

Probably can be "fixed" by adding this to "developer-yaml-config.ts":

        @media all and (max-width: 440px) {
          .content > *:nth-child(2) .card-actions {
            justify-content: center;
          }
        }

For "narrow" screens it will show all "reload" buttons centered.

Please test someone this fix.

Update: no, this is wrong.

ildar170975 avatar Sep 29 '23 22:09 ildar170975

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Dec 28 '23 23:12 github-actions[bot]

Not stale Screenshot_20231229-062616

jeroen85 avatar Dec 29 '23 05:12 jeroen85

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Mar 28 '24 07:03 github-actions[bot]

No

jeroen85 avatar Mar 28 '24 09:03 jeroen85

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Jun 26 '24 11:06 github-actions[bot]

Not stale, looks bad on mobile still

SeanPM5 avatar Jun 26 '24 16:06 SeanPM5

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Sep 24 '24 18:09 github-actions[bot]

No

jeroen85 avatar Sep 25 '24 05:09 jeroen85

I found a way to fix it locally: add an external js-file:

customElements.whenDefined('developer-yaml-config').then(() => {
  const Panel = customElements.get('developer-yaml-config');
  const { html, css } = Panel.prototype;
  
  const newStyle = css`
  ha-call-service-button {
    --ha-mwc-button-text-align: start;
  }
  `;

  const newStyles = [].concat(Panel.styles, newStyle);
  Object.defineProperty(Panel, 'styles',        {value: newStyles, configurable: true, enumerable: false});
  Object.defineProperty(Panel, 'elementStyles', {value: newStyles, configurable: true, enumerable: false});
});

customElements.whenDefined('mwc-button').then(() => {
  const mwcButton = customElements.get('mwc-button');
  const { html, css } = mwcButton.prototype;
  
  const newStyle = css`
  .mdc-button {text-align: var(--ha-mwc-button-text-align, center);}
  `;

  const newStyles = [].concat(mwcButton.styles, newStyle);
  Object.defineProperty(mwcButton, 'styles',        {value: newStyles, configurable: true, enumerable: false});
  Object.defineProperty(mwcButton, 'elementStyles', {value: newStyles, configurable: true, enumerable: false});
});

image

Have not found out yet how to add this as PR...

ildar170975 avatar Oct 29 '24 03:10 ildar170975

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Jan 27 '25 04:01 github-actions[bot]

up

ildar170975 avatar Jan 28 '25 22:01 ildar170975

Hi, we are a group of computer science students that are planning to fix this issue as part of a course. Perhaps this issue can be assigned to me?

lukaas33 avatar Mar 25 '25 14:03 lukaas33

Not fixed, fix got reverted https://github.com/home-assistant/frontend/pull/25377

jeroen85 avatar May 09 '25 08:05 jeroen85

There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates. Please make sure to update to the latest Home Assistant version and check if that solves the issue. Let us know if that works for you by adding a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] avatar Aug 07 '25 09:08 github-actions[bot]

Seems to be fixed with 2025.8

wendevlin avatar Aug 07 '25 11:08 wendevlin