{"mappings":";;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;AAqBM,MAAM,0DAAiB,CAAA,GAAA,0BAAY,EAAkD,CAAC;AAEtF,MAAM,0DAAU,CAAA,GAAA,uBAAS,EAAE,SAAS,QACzC,KAAmB,EACnB,GAAqC;IAErC,CAAC,OAAO,IAAI,GAAG,CAAA,GAAA,yCAAc,EAAE,OAAO,KAAK;IAC3C,IAAI,YAAC,QAAQ,SAAE,QAAQ,cAAG,SAAS,EAAE,GAAG,UAAS,GAAG;IACpD,IAAI,UAAU,CAAA,GAAA,6BAAE,CAAC,CAAC,CAAC,CAAC,EAAE,OAAO,CAAC;IAE9B,qBACE,0DAAC;QAAS,GAAG,QAAQ;QAAE,KAAK;QAAK,WAAW,aAAa;OACtD;AAGP","sources":["packages/react-aria-components/src/Heading.tsx"],"sourcesContent":["/*\n * Copyright 2022 Adobe. All rights reserved.\n * This file is licensed to you under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License. You may obtain a copy\n * of the License at http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software distributed under\n * the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR REPRESENTATIONS\n * OF ANY KIND, either express or implied. See the License for the specific language\n * governing permissions and limitations under the License.\n */\n\nimport {ContextValue, dom, DOMRenderProps, useContextProps} from './utils';\nimport React, {createContext, ForwardedRef, forwardRef, HTMLAttributes} from 'react';\n\nexport interface HeadingProps extends HTMLAttributes<HTMLElement>, DOMRenderProps<'h1', undefined> {\n  /**\n   * The CSS [className](https://developer.mozilla.org/en-US/docs/Web/API/Element/className) for the\n   * element.\n   *\n   * @default 'react-aria-Heading'\n   */\n  className?: string;\n  /**\n   * The heading level.\n   *\n   * @default 3\n   */\n  level?: number;\n}\n\nexport const HeadingContext = createContext<ContextValue<HeadingProps, HTMLHeadingElement>>({});\n\nexport const Heading = forwardRef(function Heading(\n  props: HeadingProps,\n  ref: ForwardedRef<HTMLHeadingElement>\n) {\n  [props, ref] = useContextProps(props, ref, HeadingContext);\n  let {children, level = 3, className, ...domProps} = props;\n  let Element = dom[`h${level}`];\n\n  return (\n    <Element {...domProps} ref={ref} className={className ?? 'react-aria-Heading'}>\n      {children}\n    </Element>\n  );\n});\n"],"names":[],"version":3,"file":"Heading.cjs.map"}