Skip to content

Commit

Permalink
New home/Themes.astro component + usage in index.astro
Browse files Browse the repository at this point in the history
  • Loading branch information
julien-deramond committed Feb 20, 2023
1 parent b500805 commit 4f91a1d
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 4 deletions.
29 changes: 29 additions & 0 deletions site-new/components/home/Themes.astro
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
import { getVersionedDocsPath } from '../../libs/config'
---
<section class="row g-3 g-md-5 pb-md-5 mb-5 align-items-center">
<div class="col-lg-6">
<div class="masthead-followup-icon d-inline-block mb-3" style="--bg-rgb: var(--bd-violet-rgb);">
<!--TODO: handle partial icons -->
<!--{{ partial "icons/droplet-fill.svg" (dict "width" "32" "height" "32") }}-->
</div>
<h2 class="display-5 mb-3 fw-semibold lh-sm">Make it yours with official Bootstrap Themes</h2>
<!--TODO: handle .Site.Params.themes-->
<!--<p class="lead fw-normal">
Take Bootstrap to the next level with premium themes from the <a href="{{ .Site.Params.themes }}">official Bootstrap Themes marketplace</a>. Themes are built on Bootstrap as their own extended frameworks, rich with new components and plugins, documentation, and powerful build tools.
</p>-->
<p class="d-flex justify-content-start lead fw-normal mb-md-0">
<!-- TODO: handle .Site.Params.themes -->
<!--<a href="{{ .Site.Params.themes }}" class="icon-link icon-link-hover fw-semibold">
Browse Bootstrap Themes
<svg class="bi"><use xlink:href="#arrow-right"></use></svg>
</a>-->
</p>
</div>
<div class="col-lg-6">
<img class="img-fluid mt-3 mx-auto" srcset={`${getVersionedDocsPath('assets/img/bootstrap-themes.png')},
${getVersionedDocsPath('assets/img/[email protected]')} 2x"
src=${getVersionedDocsPath('assets/img/bootstrap-themes.png')}`}
alt="Bootstrap Themes" width="700" height="500" loading="lazy">
</div>
</section>
6 changes: 2 additions & 4 deletions site-new/pages/index.astro
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import CSSVariables from '../components/home/CSSVariables.astro'
import ComponentUtilities from '../components/home/ComponentUtilities.astro'
import Plugins from '../components/home/Plugins.astro'
import Icons from '../components/home/Icons.astro'
import Themes from '../components/home/Themes.astro'
import { getConfig, getVersionedDocsPath } from '../libs/config'
---

Expand Down Expand Up @@ -58,9 +59,6 @@ import { getConfig, getVersionedDocsPath } from '../libs/config'
<ComponentUtilities />
<Plugins />
<Icons />
<!--
TODO: each partial must become a component
{{ partial "home/themes" . }}
-->
<Themes />
</div>
</BaseLayout>

0 comments on commit 4f91a1d

Please sign in to comment.