{"mappings":";;;;;;;;;;;;;;;;AAAA;;;;;;;;;;CAUC;;;;;AAyBM,MAAM,0DAAO,CAAA,GAAA,uBAAS,EAAE,SAAS,KAA6B,KAAmB,EAAE,GAAW;IACnG,QAAQ,CAAA,GAAA,sCAAW,EAAE;IACrB,IAAI,EACF,aAAa,cAAc,KAAK,YAChC,QAAQ,EACR,GAAG,YACJ,GAAG;IACJ,IAAI,cAAC,UAAU,EAAC,GAAG,CAAA,GAAA,uCAAY,EAAE,OAAO,CAAA,GAAA,wCAAa;IACrD,IAAI,SAAS,CAAA,GAAA,mCAAQ,EAAE;IAEvB,qBACE,0DAAC;QACE,GAAG,CAAA,GAAA,6CAAa,EAAE,WAAW;QAC7B,GAAG,UAAU;QACd,KAAK;qBACL,0DAAC,CAAA,GAAA,oCAAS,SACP;AAIT","sources":["packages/@adobe/react-spectrum/src/view/View.tsx"],"sourcesContent":["/*\n * Copyright 2020 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 {ClearSlots, useSlotProps} from '../utils/Slots';\n\nimport {ColorVersion, DOMProps, DOMRef, ViewStyleProps} from '@react-types/shared';\nimport {filterDOMProps} from 'react-aria/filterDOMProps';\nimport React, {forwardRef, JSXElementConstructor, ReactElement, ReactNode} from 'react';\nimport {useDOMRef} from '../utils/useDOMRef';\nimport {useStyleProps, viewStyleProps} from '../utils/styleProps';\n\nexport interface ViewProps<C extends ColorVersion> extends ViewStyleProps<C>, DOMProps {\n  /**\n   * The element to render as the node.\n   */\n  elementType?: string | JSXElementConstructor<any>,\n  /**\n   * Children to be displayed in the View.\n   */\n  children?: ReactNode\n}\n\n/**\n * View is a general purpose container with no specific semantics that can be used for custom styling purposes.\n * It supports Spectrum style props to ensure consistency with other Spectrum components.\n */\nexport const View = forwardRef(function View<C extends ColorVersion>(props: ViewProps<C>, ref: DOMRef) {\n  props = useSlotProps(props);\n  let {\n    elementType: ElementType = 'div',\n    children,\n    ...otherProps\n  } = props;\n  let {styleProps} = useStyleProps(props, viewStyleProps);\n  let domRef = useDOMRef(ref);\n\n  return (\n    <ElementType\n      {...filterDOMProps(otherProps)}\n      {...styleProps}\n      ref={domRef}>\n      <ClearSlots>\n        {children}\n      </ClearSlots>\n    </ElementType>\n  );\n}) as <C extends ColorVersion = 5>(props: ViewProps<C> & {ref?: DOMRef}) => ReactElement;\n"],"names":[],"version":3,"file":"View.cjs.map"}