shmuelzon / home-assistant-floor-plan

Home Assistant Floor Plan Generator Plugin For Sweet Home 3D
MIT License
129 stars 4 forks source link

feat: Avoid exposing "Home" from SH3D to UI; Use function for empty project #41

Closed guimatheus92 closed 3 days ago

guimatheus92 commented 1 week ago
          I'd rather not expose `Home` directly to the UI. If you really want to indicate the project is empty, create a function specifically for that

_Originally posted by @shmuelzon in https://github.com/shmuelzon/home-assistant-floor-plan/pull/40#discussion_r1667321494_

guimatheus92 commented 1 week ago

@shmuelzon How would you suggest doing this please? To be honest I didn't understand much and I am no expert in Java. So I would like to get some inputs from you please, so I can try to make this work in a proper way then. Thanks!

shmuelzon commented 1 week ago

We could create a function in the controller called isProjectEmpty() or something like that and it would contain the same logic you had in the panel to check if there's any furniture in the project.

guimatheus92 commented 1 week ago

Thanks @shmuelzon! Will follow your input. Do you want me to send one PR at a time? I don't know if I should wait your approval or send all of them, based on your last comment.

shmuelzon commented 1 week ago

Thank you for putting the effort! I prefer one pull request for each new feature/task. It'll make things simpler in the git history and release notes for the new version

guimatheus92 commented 1 week ago

Ok, thanks! Can you review my opened PR and approve it please? I followed your previous suggestions. So that I can open another one.