Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changing from fixed size back to auto messes up LED size #68

Closed
yoiang opened this issue Jan 26, 2021 · 5 comments
Closed

Changing from fixed size back to auto messes up LED size #68

yoiang opened this issue Jan 26, 2021 · 5 comments
Labels
bug Something isn't working

Comments

@yoiang
Copy link
Member

yoiang commented Jan 26, 2021

Reported by kuema here: https://discourse.nodered.org/t/announce-node-red-contrib-ui-led-0-4-6/39472/3

Describe the bug
Size of LED grows to incorrect size if going from fixed size to auto size

To Reproduce

  1. Add an LED set to auto
  2. Change size to a fixed on, say 1x1
  3. Close Edit panel
  4. Change size back to auto
  5. Close Edit panel
  6. Deploy

Expected behavior
Should return to auto size

Screenshots

From the flow, looks like width and height are being saved as strings

Versions

  • node-red-contrib-ui-led: 0.4.6
@yoiang yoiang added the bug Something isn't working label Jan 26, 2021
@kuema
Copy link

kuema commented Jan 27, 2021

I did a little digging, too. 🤓

It seems only the initial values are numbers. As soon as you change the size in any way, they end up as strings as well, like "width": "1". So this might be a general Dashboard thing.

The problem is this strict comparison.

So, one can either use == or convert the width to a number first.

@bburkett52
Copy link

I am seeing another issue that may be related to this issue.
When displayed on my iPhone, in portrait orientation, the LED initially shows as a thin vertical slit.
If I rotate the device 90 degrees, to landscape mode, the LED displays properly and then even when rotated back to portrait mode.
This anomaly began with the 0.4.7 version.

62195

Regards,
Bob

@yoiang
Copy link
Member Author

yoiang commented Feb 4, 2021

I have addressed the bug @kuema you and others had run into with 0.4.8, please let me know if you have any issues!

@bburkett52 let me take some time to reproduce the issue, if it's still happening I'll make a new issue. Thanks so much for reporting it :)

@bburkett52
Copy link

@yoiang,

Thanks you for your work!
I have updated to version 0.4.8 and still have the same issue on my phone.
All is good on on larger displays.

Regards,
Bob

@yoiang
Copy link
Member Author

yoiang commented Feb 13, 2021

@bburkett52 please track progress on the issue you're seeing #72 !

@yoiang yoiang closed this as completed Feb 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants