"use client"
import { Box, For, HStack, Stack, Text, defaultSystem } from "@chakra-ui/react"
import { TokenDoc } from "./token-doc"
const { tokens, _config } = defaultSystem
const fonts = Object.keys(_config.theme?.tokens?.fonts ?? {})
const fontSizes = Object.keys(_config.theme?.tokens?.fontSizes ?? {})
const fontWeights = Object.keys(_config.theme?.tokens?.fontWeights ?? {})
const lineHeights = Object.keys(_config.theme?.tokens?.lineHeights ?? {})
const letterSpacings = Object.keys(_config.theme?.tokens?.letterSpacings ?? {})
export const FontTokenDoc = () => {
return (
{(font) => {
const token = tokens.getByName(`fonts.${font}`)
return (
Ag
{font}
{token?.originalValue}
)
}}
)
}
export const FontSizeTokenDoc = () => {
return (
{fontSizes.map((fontSize) => {
const token = tokens.getByName(`fontSizes.${fontSize}`)!
return (
{token.extensions.prop}
{token.value}
Ag
)
})}
)
}
export const FontWeightTokenDoc = () => {
return (
{fontWeights.map((fontWeight) => {
const token = tokens.getByName(`fontWeights.${fontWeight}`)!
return (
{token.extensions.prop}
{token.value}
Ag
)
})}
)
}
export const LineHeightTokenDoc = () => {
return (
{lineHeights.map((lineHeight) => {
const token = tokens.getByName(`lineHeights.${lineHeight}`)!
return (
{token.extensions.prop} / {token.value}
Naruto is a Japanese manga series written and illustrated by
Masashi Kishimoto. It tells the story of Naruto Uzumaki, a young
ninja who seeks recognition from his peers and dreams of
becoming the Hokage, the leader of his village.
)
})}
)
}
export const LetterSpacingTokenDoc = () => {
return (
{letterSpacings.map((letterSpacing) => {
const token = tokens.getByName(`letterSpacings.${letterSpacing}`)!
return (
{token.extensions.prop} / {token.value}
Naruto Uzumaki
)
})}
)
}