Add documentation for regenerate rule from template - #2518
Conversation
✅ Thanks for your pull request to the openHAB documentation! The result can be previewed at the URL below (this comment and the preview will be updated if you add more commits).Built without sensitive environment variables
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
@rkoshak Since you have written the existing documentation for this, I don't feel comfortable modifying it as I'm not sure I fully "follow your train of thoughts". Therefore, I've created this PR more as an input of where different bits might fit in. I think it would be preferable if you used "your words and style", but I hope it's helpful that I've tried to figure out what information could be put where. |
| However pay attention and if there is more information that might be useful to you later add that. | ||
| ~~The title and description are optional and will be automatically populated with meaningful information when you select the trigger. | ||
| However pay attention and if there is more information that might be useful to you later add that.~~ | ||
|
|
There was a problem hiding this comment.
@rkoshak I made a change here just as a reminder that this no longer matches how MainUI looks. You can no longer enter title and description at this stage of the "wizard", so it might be confusing to the user when what's shown doesn't match what they see.
|
It should probably also be mentioned somewhere that rules generated from templates in previous versions of OH cannot be regenerated, since they lack the reference to the template. It's thus only rules that have been created in 5.0 or later that can be regenerated. |
|
I don't claim ownership for any part of the docs. I'm not even a maintainer on this repo. It wouldn't be fair to the project if I tried to claim such control as I rarely have the time to devote to it these days. I have no problems with contributions from others and in fact encourage it. At this point, if we want these changes in before OH 5.0 release someone who is not me needs to complete it. But upon review I have no issue with what's here. Remove that one section that doesn't match any more and the additions look good as written. I don't really have anything to add or correct. I'm really happy with the feature. It saves me a lot of time. LGTM! |
|
@Nadahar : in case it is ready and inline with what will be available inb OH 5, you have to exit the draft mode and ping @stefan-hoehn for a review & merge. |
I know, I'm still trying to address some issues. In particular, I've been trying to figure out a way to have inline images/icons, so that you can e.g. show the button that should be clicked instead of just describing it. But, to no avail this far. The layout options of vuepress seem very limited. |
I couldn't figure that out way back when I wrote this either, which is why the screenshots are shown the way they are. Things may have changed since then but at least as of a couple years ago inline images were not supported in any way I could figure out. |
|
I found a way to make inline icons/images, but I had to create a Vue component to do it. I don't know if this approach is acceptable, but it seems to work, as can be seen from the preview. I'm not sure who to ask if this is an acceptable approach, input is appreciated. If this is deemed acceptable, I can prepare the PR for review. |
|
This pull request has been mentioned on openHAB Community. There might be relevant details there: https://community.openhab.org/t/inline-images-icons-in-documentation/164965/4 |
|
@stefan-hoehn is probably the main person who can comment on the approach. |
|
@stefan-hoehn What do you think of the solution I made for inline icons/small images? I'm thinking specifically of InlineIcon.vue. |
82ebfb7 to
53dbc9f
Compare
|
I've created openhab/openhab-website#527 which hopefully is what's needed to make this work. That means that this PR depends on openhab/openhab-website#527. Apart from that, I think it's now ready for review. |
florian-h05
left a comment
There was a problem hiding this comment.
Overall LGTM, just two comments.
There was a problem hiding this comment.
I would rather name this component InlineImage.
Please also add a section documenting it to https://github.com/openhab/openhab-docs?tab=readme-ov-file#contributing-to-the-documentation.
There was a problem hiding this comment.
I would rather name this component InlineImage
That was the name I used originally. But then I thought it was too generic, indicating that it was meant for inline images of any size, not aligned to the text, so I changed it. But, I've changed it back now ;)
There was a problem hiding this comment.
@florian-h05 Please check out my addition to the README. As always, brevity isn't my strength, so tell me if there's something I should remove.
There was a problem hiding this comment.
That was the name I used originally. But then I thought it was too generic, indicating that it was meant for inline images of any size, not aligned to the text, so I changed it. But, I've changed it back now ;)
This is a good point, though I think both names can be confusing. Icon means icon for me, not any small image.
There was a problem hiding this comment.
The docs look good, thanks.
02af906 to
0c1b086
Compare
Signed-off-by: Ravi Nadahar <nadahar@rediffmail.com>
0c1b086 to
a911689
Compare
|
@stefan-hoehn openhab/openhab-website#527 is merged, this should be good to go. |
|
Did you run and test this locally? |
|
The deploy preview works fine, why do we need to test that locally? |
Yes, I've used the local build to test this all the way since the inception of the component. How else would I figure out what works and doesn't work? |
|
@stefan-hoehn I'm not sure what more to do with this, as far as I can tell it's ready. If you need me to do something more, please tell me. |
Signed-off-by: Ravi Nadahar <nadahar@rediffmail.com> Co-authored-by: Ravi Nadahar <nadahar@rediffmail.com> (cherry picked from commit c7c7ef9)
|
Now this needs to be cherry-picked to final-stable to get into the 5.0.x docs ... I have just done this. |
This is more of a suggestion than a "full PR" at this point.
Since regeneration of rules from template is possible from 5.0, we should modify the documentation to reflect this.