-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Content Section display alignment
- Loading branch information
Showing
2 changed files
with
99 additions
and
6 deletions.
There are no files selected for viewing
86 changes: 86 additions & 0 deletions
86
src/stories/templates/sections/SectionGetStarted.stories.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
|
||
import ContentSection from '../../../templates/contentsection' | ||
import LinkButton from '../../../templates/linkbutton' | ||
import Tile from '../../../templates/tile' | ||
|
||
export default { | ||
title: 'Blocks/Sections/Get Started', | ||
tags: ['autodocs'], | ||
} | ||
|
||
const MOCK = { | ||
overline: 'Get Started', | ||
title: "Sign-up and <span class='animate-pretty bg-clip-text text-transparent bg-gradient-to-r from-orange-500 to-orange-400'>get $300,00 </span> to use for 12 months. Ready to deploy?", | ||
"buttons": [ | ||
{ | ||
"label": "Free Account", | ||
"link": "https://console.azion.com/signup" | ||
}, | ||
{ | ||
"label": "Talk to an Expert", | ||
"link": "https://console.azion.com/signup", | ||
"outlined": true | ||
} | ||
], | ||
items: [ | ||
{ | ||
icon: "pi pi-tags", | ||
text: "Access to all products" | ||
}, | ||
{ | ||
icon: "pi pi-credit-card", | ||
text: "No credit card required" | ||
}, | ||
{ | ||
icon: "pi pi-dollar", | ||
text: "Credit available to use for 12 months" | ||
} | ||
] | ||
} | ||
|
||
const template = ` | ||
<div class="surface-ground py-10"> | ||
<ContentSection :overline="args.overline" titleTag="h2" position="full"> | ||
<template #title> | ||
<h2 v-html="args.title" /> | ||
</template> | ||
<template #content> | ||
<div class="flex flex-col md:flex-row gap-3 md:justify-end md:min-w-fit md:items-end"> | ||
<LinkButton | ||
class="md:w-fit w-full" | ||
v-for="{ link, label, outlined } in args.buttons" | ||
:link="link" | ||
:label="label" | ||
:outlined="outlined" | ||
/> | ||
</div> | ||
</template> | ||
<template #main> | ||
<div class="flex flex-col md:flex-row gap-3 justify-between"> | ||
<div v-for="{ icon, text } in args.items" class="flex gap-3"> | ||
<Tile> <i :class="icon" class="text-sm" /> </Tile> | ||
<p class="font-medium">{{ text }}</p> | ||
</div> | ||
</div> | ||
</template> | ||
</ContentSection> | ||
</div>` | ||
|
||
const Template = (args) => ({ | ||
components: { ContentSection, LinkButton, Tile }, | ||
setup() { | ||
return { args } | ||
}, | ||
template: template | ||
}) | ||
|
||
export const Default = Template.bind({}) | ||
Default.args = MOCK | ||
|
||
Default.parameters = { | ||
docs: { | ||
description: { | ||
story: '' | ||
}, | ||
source: { code: template } }, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters