-
Notifications
You must be signed in to change notification settings - Fork 7
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
Update 0.2 #11
Update 0.2 #11
Conversation
@pietroppeter any features you are missing in nimiSlides that you would like in your NimConf slides? |
|
I'll try and hack together something with CSS Grid tomorrow.
Oh, had forgotten about #7 :o I'll look into it again. |
Quarto has a section on multiple columns, not sure how they do it: https://quarto.org/docs/presentations/revealjs/ |
I had a similar idea in mind, the only difference right now is that you can't decide how wide each column is, they are equally wide: slide:
columns:
column:
nbText: "This is column left"
column:
nbText: "This is column right" |
I would guess equal width columns will likely be the most common use case, we probably we can start supporting just that. Implementation looks very clean! |
Yeah, it's easy enough to fix in the future if someone requests it I guess.
Yep, the beauty of nimib 😎 It almost feels wasteful though, the way I define template column(bodyInner: untyped) =
nbRawHtml: "<div>"
bodyInner
nbRawHtml: "</div>" |
I have got a footer working now, only problem is that it is shown on top of literally every slide including videos 🤣 |
The footer is now implemented, and it automatically hides when the background is set to some full-screen content. |
nice. I was looking at the footer where the string should be html. why not markdown (which in particular includes html)? |
No reason in particular I realize now 😅 the footer can't be implemented as a block so somehow I thought I couldn't use markdown then 🙃 but I could just run the nim-markdown on the text directly. I might add an option so you can pass in raw Html as well, if I recall correctly, the markdown library we use didn't support every html tag in the past |
Yes, you can use markdown directly (remember to use the GitHub version to see how we do it in nimib in renders.nim). As far as I know markdown should support all html tags, I think it is kind of part of the spec. What it does not support is if you put markdown inside html and expect to have your markdown transformed. There might be some cases where it works, but mostly I would expect it to not work. |
pietroppeter/nimib#28 (comment) Found what was troubling me back then. It didn't handle |
Well, to be fair in that example it cannot parse |
It is indeed weird though that span fails but div does not |
found a bug when using |
Good catch, I always forget that templates in templates aren't just available inside the code block 😅 should work if we just move it outside the columns template And regarding the markdown html, I think I'll leave it as an option as it is now. So by default it treats it as markdown, but if the user had any similar problems, they can use the option to use raw html. |
On a different note, I find the footer quite distracting. 😅 I might turn down the text size and opacity a bit (and I might as well add those as options to the template as well then) |
it should be fixed now |
@pietroppeter if I understood you correctly, it was what Quarto calls a "Logo" that you wanted as well? |
Not really, a logo appears in all slides, I wanted a way to add something in one corner (like the logo, but I should be able to fix the corner) for a single slide |
Ok, then I get it 👍 Do we want to use it only for images or allow text as well? |
I guess it could be implemented using a div or similar that contains stuff, so in principle it could contain generic nimib blocks... the use case I had in mind though is about the QR code link to slides, so: image gets priority |
My main concern with allowing anything is size. We want to limit the content in the corner's size, and if we allow anything in there, that will be very hard to do. If we only allow images for now, we could have the size of the image as a parameter to the template as well. So I think I'll go with image-only for now (and will name it something with |
|
the only thing that came up to me that is simple enough is adding a |
Here all changes for the v0.2 update will be added. It is planned to be released before NimConf 2022 (22 Oct).
Changes: