{"ast":null,"code":"import * as React from 'react';\nimport classNames from 'classnames';\nimport { Slot } from '@radix-ui/react-slot';\nimport { textPropDefs } from './text.props';\nimport { extractMarginProps, withMarginProps, withBreakpoints } from '../helpers';\nconst Text = React.forwardRef((props, forwardedRef) => {\n  const {\n    rest: marginRest,\n    ...marginProps\n  } = extractMarginProps(props);\n  const {\n    children,\n    className,\n    asChild = false,\n    as: Tag = 'span',\n    size = textPropDefs.size.default,\n    weight = textPropDefs.weight.default,\n    align = textPropDefs.align.default,\n    trim = textPropDefs.trim.default,\n    color = textPropDefs.color.default,\n    highContrast = textPropDefs.highContrast.default,\n    ...textProps\n  } = marginRest;\n  return React.createElement(Slot, {\n    \"data-accent-color\": color,\n    ...textProps,\n    ref: forwardedRef,\n    className: classNames('rt-Text', className, withBreakpoints(size, 'rt-r-size'), withBreakpoints(weight, 'rt-r-weight'), withBreakpoints(align, 'rt-r-ta'), withBreakpoints(trim, 'rt-r-lt'), {\n      'rt-high-contrast': highContrast\n    }, withMarginProps(marginProps))\n  }, asChild ? children : React.createElement(Tag, null, children));\n});\nText.displayName = 'Text';\nexport { Text };","map":{"version":3,"names":["React","classNames","Slot","textPropDefs","extractMarginProps","withMarginProps","withBreakpoints","Text","forwardRef","props","forwardedRef","rest","marginRest","marginProps","children","className","asChild","as","Tag","size","default","weight","align","trim","color","highContrast","textProps","createElement","ref","displayName"],"sources":["../../../src/components/text.tsx"],"sourcesContent":[null],"mappings":"AAAA,OAAO,KAAKA,KAAK,MAAM,OAAO;AAC9B,OAAOC,UAAU,MAAM,YAAY;AACnC,SAASC,IAAI,QAAQ,sBAAsB;AAC3C,SAASC,YAAY,QAAQ,cAAc;AAC3C,SAASC,kBAAkB,EAAEC,eAAe,EAAEC,eAAe,QAAQ,YAAY;AAiBjF,MAAMC,IAAI,GAAGP,KAAK,CAACQ,UAAU,CAAyB,CAACC,KAAK,EAAEC,YAAY,KAAI;EAC5E,MAAM;IAAEC,IAAI,EAAEC,UAAU;IAAE,GAAGC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