generated from cloudoperators/repository-template
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDescriptionList.stories.tsx
More file actions
54 lines (49 loc) · 1.47 KB
/
DescriptionList.stories.tsx
File metadata and controls
54 lines (49 loc) · 1.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
/*
* SPDX-FileCopyrightText: 2026 SAP SE or an SAP affiliate company and Juno contributors
* SPDX-License-Identifier: Apache-2.0
*/
import React from "react"
import type { Meta, StoryObj } from "@storybook/react-vite"
import { DescriptionList } from "./DescriptionList.component"
import { DT } from "../DescriptionTerm/DescriptionTerm.component"
import { DD } from "../DescriptionDefinition/DescriptionDefinition.component"
const meta: Meta<typeof DescriptionList> = {
title: "Components/DescriptionList",
component: DescriptionList,
argTypes: {
children: {
control: false,
},
},
}
export default meta
type Story = StoryObj<typeof DescriptionList>
export const Default: Story = {
render: (args) => (
<DescriptionList {...args}>
<DT>Warranty</DT>
<DD>2 years limited warranty with options for extension.</DD>
</DescriptionList>
),
}
/**
* You can use many definitions per term.
*/
export const MultiplePairsRightAligned: Story = {
render: (args) => (
<DescriptionList alignTerms="right" {...args}>
<DT>Shipping</DT>
<DD>Standard shipping: 5-7 business days.</DD>
<div className="custom1">
<DT>Payment Options</DT>
<DD>
Credit/Debit cards, PayPal, and bank transfer. Lots and lots and lots of options. Oh so many, many options.
</DD>
</div>
<div className="custom2">
<DT>Delivery Time</DT>
<DD>1 day, 2 days, 3 days.</DD>
</div>
</DescriptionList>
),
}