Centering short codes, specifically YouTube #31
-
Hello Will, This works in my markdown file... div style="text-align: center;" div This doesn't... div style="text-align: center;" Any ideas? I pulled off the opening and closing brackets to stop my question from rendering. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
Your HTML isn't formatting correctly, so I might be missing something. I think you want to align it with flexbox instead of text-align. Have you tried wrapping paige/youtube in paige/figure? See https://willfaught.com/paige/shortcodes/youtube/#figure for an example |
Beta Was this translation helpful? Give feedback.
I forgot to say that videos are automatically sized to be the width of the outermost Bootstrap container, so there's no way to make them smaller width-wise without turning that off. If you want to do so, you'll want to override https://github.com/willfaught/paige/blob/master/layouts/partials/paige/scripts.html in your site and comment out these lines. However, you'll then have to set the width manually for all videos.
Note that setting the width to 50% will also apply to mobile layouts, which might not be what you want.