Merged in chore/sw-3145-move-footnote (pull request #2506)
chore(SW-3145): Move Footnote to design-system * Move Footnote to design-system Approved-by: Joakim Jäderberg
This commit is contained in:
61
packages/design-system/lib/components/Footnote/variants.ts
Normal file
61
packages/design-system/lib/components/Footnote/variants.ts
Normal file
@@ -0,0 +1,61 @@
|
||||
import { cva } from 'class-variance-authority'
|
||||
|
||||
import styles from './footnote.module.css'
|
||||
|
||||
const config = {
|
||||
variants: {
|
||||
type: {
|
||||
regular: styles.regular,
|
||||
bold: styles.bold,
|
||||
label: styles.labels,
|
||||
},
|
||||
color: {
|
||||
black: styles.black,
|
||||
burgundy: styles.burgundy,
|
||||
pale: styles.pale,
|
||||
peach50: styles.peach50,
|
||||
uiTextMediumContrast: styles.uiTextMediumContrast,
|
||||
uiTextHighContrast: styles.uiTextHighContrast,
|
||||
uiTextPlaceholder: styles.uiTextPlaceholder,
|
||||
white: styles.white,
|
||||
baseTextDisabled: styles.baseTextDisabled,
|
||||
},
|
||||
textAlign: {
|
||||
center: styles.center,
|
||||
left: styles.left,
|
||||
},
|
||||
textTransform: {
|
||||
uppercase: styles.uppercase,
|
||||
},
|
||||
},
|
||||
defaultVariants: {
|
||||
type: 'regular',
|
||||
},
|
||||
} as const
|
||||
|
||||
export const footnoteVariants = cva(styles.footnote, config)
|
||||
|
||||
const fontOnlyConfig = {
|
||||
variants: {
|
||||
type: {
|
||||
regular: styles.regular,
|
||||
bold: styles.bold,
|
||||
label: styles.labels,
|
||||
},
|
||||
textAlign: {
|
||||
center: styles.center,
|
||||
left: styles.left,
|
||||
},
|
||||
textTransform: {
|
||||
uppercase: styles.uppercase,
|
||||
},
|
||||
},
|
||||
defaultVariants: {
|
||||
type: 'regular',
|
||||
},
|
||||
} as const
|
||||
|
||||
export const footnoteFontOnlyVariants = cva(
|
||||
styles.footnoteFontOnly,
|
||||
fontOnlyConfig
|
||||
)
|
||||
Reference in New Issue
Block a user