{"ast":null,"code":"\"use client\";\n\nvar __rest = this && this.__rest || function (s, e) {\n  var t = {};\n  for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n  if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n    if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n  }\n  return t;\n};\nimport React, { forwardRef, useContext, useMemo } from 'react';\nimport classNames from 'classnames';\nimport omit from \"rc-util/es/omit\";\nimport { devUseWarning } from '../_util/warning';\nimport Badge from '../badge';\nimport { ConfigContext } from '../config-provider';\nimport Tooltip from '../tooltip';\nimport FloatButtonGroupContext from './context';\nimport Content from './FloatButtonContent';\nimport useStyle from './style';\nexport const floatButtonPrefixCls = 'float-btn';\nconst FloatButton = /*#__PURE__*/forwardRef((props, ref) => {\n  const {\n      prefixCls: customizePrefixCls,\n      className,\n      rootClassName,\n      type = 'default',\n      shape = 'circle',\n      icon,\n      description,\n      tooltip,\n      badge = {}\n    } = props,\n    restProps = __rest(props, [\"prefixCls\", \"className\", \"rootClassName\", \"type\", \"shape\", \"icon\", \"description\", \"tooltip\", \"badge\"]);\n  const {\n    getPrefixCls,\n    direction\n  } = useContext(ConfigContext);\n  const groupShape = useContext(FloatButtonGroupContext);\n  const prefixCls = getPrefixCls(floatButtonPrefixCls, customizePrefixCls);\n  const [wrapSSR, hashId] = useStyle(prefixCls);\n  const mergeShape = groupShape || shape;\n  const classString = classNames(hashId, prefixCls, className, rootClassName, `${prefixCls}-${type}`, `${prefixCls}-${mergeShape}`, {\n    [`${prefixCls}-rtl`]: direction === 'rtl'\n  });\n  // 虽然在 ts 中已经 omit 过了，但是为了防止多余的属性被透传进来，这里再 omit 一遍，以防万一\n  const badgeProps = useMemo(() => omit(badge, ['title', 'children', 'status', 'text']), [badge]);\n  const contentProps = useMemo(() => ({\n    prefixCls,\n    description,\n    icon,\n    type\n  }), [prefixCls, description, icon, type]);\n  let buttonNode = /*#__PURE__*/React.createElement(\"div\", {\n    className: `${prefixCls}-body`\n  }, /*#__PURE__*/React.createElement(Content, Object.assign({}, contentProps)));\n  if ('badge' in props) {\n    buttonNode = /*#__PURE__*/React.createElement(Badge, Object.assign({}, badgeProps), buttonNode);\n  }\n  if ('tooltip' in props) {\n    buttonNode = /*#__PURE__*/React.createElement(Tooltip, {\n      title: tooltip,\n      placement: direction === 'rtl' ? 'right' : 'left'\n    }, buttonNode);\n  }\n  if (process.env.NODE_ENV !== 'production') {\n    const warning = devUseWarning('FloatButton');\n    process.env.NODE_ENV !== \"production\" ? warning(!(shape === 'circle' && description), 'usage', 'supported only when `shape` is `square`. Due to narrow space for text, short sentence is recommended.') : void 0;\n  }\n  return wrapSSR(props.href ? /*#__PURE__*/React.createElement(\"a\", Object.assign({\n    ref: ref\n  }, restProps, {\n    className: classString\n  }), buttonNode) : /*#__PURE__*/React.createElement(\"button\", Object.assign({\n    ref: ref\n  }, restProps, {\n    className: classString,\n    type: \"button\"\n  }), buttonNode));\n});\nif (process.env.NODE_ENV !== 'production') {\n  FloatButton.displayName = 'FloatButton';\n}\nexport default FloatButton;","map":{"version":3,"names":["__rest","s","e","t","p","Object","prototype","hasOwnProperty","call","indexOf","getOwnPropertySymbols","i","length","propertyIsEnumerable","React","forwardRef","useContext","useMemo","classNames","omit","devUseWarning","Badge","ConfigContext","Tooltip","FloatButtonGroupContext","Content","useStyle","floatButtonPrefixCls","FloatButton","props","ref","prefixCls","customizePrefixCls","className","rootClassName","type","shape","icon","description","tooltip","badge","restProps","getPrefixCls","direction","groupShape","wrapSSR","hashId","mergeShape","classString","badgeProps","contentProps","buttonNode","createElement","assign","title","placement","process","env","NODE_ENV","warning","href","displayName"],"sources":["/Users/chrishaack/UC_Trains_Voice/react-demo/node_modules/antd/es/float-button/FloatButton.js"],"sourcesContent":["\"use client\";\n\nvar __rest = this && this.__rest || function (s, e) {\n  var t = {};\n  for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];\n  if (s != null && typeof Object.getOwnPropertySymbols === \"function\") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\n    if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];\n  }\n  return t;\n};\nimport React, { forwardRef, useContext, useMemo } from 'react';\nimport classNames from 'classnames';\nimport omit from \"rc-util/es/omit\";\nimport { devUseWarning } from '../_util/warning';\nimport Badge from '../badge';\nimport { ConfigContext } from '../config-provider';\nimport Tooltip from '../tooltip';\nimport FloatButtonGroupContext from './context';\nimport Content from './FloatButtonContent';\nimport useStyle from './style';\nexport const floatButtonPrefixCls = 'float-btn';\nconst FloatButton = /*#__PURE__*/forwardRef((props, ref) => {\n  const {\n      prefixCls: customizePrefixCls,\n      className,\n      rootClassName,\n      type = 'default',\n      shape = 'circle',\n      icon,\n      description,\n      tooltip,\n      badge = {}\n    } = props,\n    restProps = __rest(props, [\"prefixCls\", \"className\", \"rootClassName\", \"type\", \"shape\", \"icon\", \"description\", \"tooltip\", \"badge\"]);\n  const {\n    getPrefixCls,\n    direction\n  } = useContext(ConfigContext);\n  const groupShape = useContext(FloatButtonGroupContext);\n  const prefixCls = getPrefixCls(floatButtonPrefixCls, customizePrefixCls);\n  const [wrapSSR, hashId] = useStyle(prefixCls);\n  const mergeShape = groupShape || shape;\n  const classString = classNames(hashId, prefixCls, className, rootClassName, `${prefixCls}-${type}`, `${prefixCls}-${mergeShape}`, {\n    [`${prefixCls}-rtl`]: direction === 'rtl'\n  });\n  // 虽然在 ts 中已经 omit 过了，但是为了防止多余的属性被透传进来，这里再 omit 一遍，以防万一\n  const badgeProps = useMemo(() => omit(badge, ['title', 'children', 'status', 'text']), [badge]);\n  const contentProps = useMemo(() => ({\n    prefixCls,\n    description,\n    icon,\n    type\n  }), [prefixCls, description, icon, type]);\n  let buttonNode = /*#__PURE__*/React.createElement(\"div\", {\n    className: `${prefixCls}-body`\n  }, /*#__PURE__*/React.createElement(Content, Object.assign({}, contentProps)));\n  if ('badge' in props) {\n    buttonNode = /*#__PURE__*/React.createElement(Badge, Object.assign({}, badgeProps), buttonNode);\n  }\n  if ('tooltip' in props) {\n    buttonNode = /*#__PURE__*/React.createElement(Tooltip, {\n      title: tooltip,\n      placement: direction === 'rtl' ? 'right' : 'left'\n    }, buttonNode);\n  }\n  if (process.env.NODE_ENV !== 'production') {\n    const warning = devUseWarning('FloatButton');\n    process.env.NODE_ENV !== \"production\" ? warning(!(shape === 'circle' && description), 'usage', 'supported only when `shape` is `square`. Due to narrow space for text, short sentence is recommended.') : void 0;\n  }\n  return wrapSSR(props.href ? /*#__PURE__*/React.createElement(\"a\", Object.assign({\n    ref: ref\n  }, restProps, {\n    className: classString\n  }), buttonNode) : /*#__PURE__*/React.createElement(\"button\", Object.assign({\n    ref: ref\n  }, restProps, {\n    className: classString,\n    type: \"button\"\n  }), buttonNode));\n});\nif (process.env.NODE_ENV !== 'production') {\n  FloatButton.displayName = 'FloatButton';\n}\nexport default FloatButton;"],"mappings":"AAAA,YAAY;;AAEZ,IAAIA,MAAM,GAAG,IAAI,IAAI,IAAI,CAACA,MAAM,IAAI,UAAUC,CAAC,EAAEC,CAAC,EAAE;EAClD,IAAIC,CAAC,GAAG,CAAC,CAAC;EACV,KAAK,IAAIC,CAAC,IAAIH,CAAC,EAAE,IAAII,MAAM,CAACC,SAAS,CAACC,cAAc,CAACC,IAAI,CAACP,CAAC,EAAEG,CAAC,CAAC,IAAIF,CAAC,CAACO,OAAO,CAACL,CAAC,CAAC,GAAG,CAAC,EAAED,CAAC,CAACC,CAAC,CAAC,GAAGH,CAAC,CAACG,CAAC,CAAC;EAChG,IAAIH,CAAC,IAAI,IAAI,IAAI,OAAOI,MAAM,CAACK,qBAAqB,KAAK,UAAU,EAAE,KAAK,IAAIC,CAAC,GAAG,CAAC,EAAEP,CAAC,GAAG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