{"version":3,"file":"PaginationDots.cjs","names":["PaginationDotsIcon","factory","useProps","Box","usePaginationContext","classes"],"sources":["../../../../src/components/Pagination/PaginationDots/PaginationDots.tsx"],"sourcesContent":["import {\n  Box,\n  BoxProps,\n  CompoundStylesApiProps,\n  ElementProps,\n  factory,\n  Factory,\n  useProps,\n} from '../../../core';\nimport { usePaginationContext } from '../Pagination.context';\nimport { PaginationDotsIcon, PaginationIconProps } from '../Pagination.icons';\nimport classes from '../Pagination.module.css';\n\nexport type PaginationDotsStylesNames = 'dots';\n\nexport interface PaginationDotsProps\n  extends BoxProps, CompoundStylesApiProps<PaginationDotsFactory>, ElementProps<'div'> {\n  /** Custom dots icon component, must accept svg element props and size prop */\n  icon?: React.FC<PaginationIconProps>;\n}\n\nexport type PaginationDotsFactory = Factory<{\n  props: PaginationDotsProps;\n  ref: HTMLDivElement;\n  stylesNames: PaginationDotsStylesNames;\n  compound: true;\n}>;\n\nconst defaultProps = {\n  icon: PaginationDotsIcon,\n} satisfies Partial<PaginationDotsProps>;\n\nexport const PaginationDots = factory<PaginationDotsFactory>((_props) => {\n  const props = useProps('PaginationDots', defaultProps, _props);\n  const { classNames, className, style, styles, vars, icon: Icon, ...others } = props;\n  const ctx = usePaginationContext();\n\n  return (\n    <Box {...ctx.getStyles('dots', { className, style, styles, classNames })} {...others}>\n      <Icon\n        style={{\n          width: 'calc(var(--pagination-control-size) / 1.8)',\n          height: 'calc(var(--pagination-control-size) / 1.8)',\n        }}\n      />\n    </Box>\n  );\n});\n\nPaginationDots.classes = classes;\nPaginationDots.displayName = '@mantine/core/PaginationDots';\n"],"mappings":";;;;;;;;;;AA4BA,MAAM,eAAe,EACnB,MAAMA,yBAAAA,oBACP;AAED,MAAa,iBAAiBC,gBAAAA,SAAgC,WAAW;CAEvE,MAAM,EAAE,YAAY,WAAW,OAAO,QAAQ,MAAM,MAAM,MAAM,GAAG,WADrDC,kBAAAA,SAAS,kBAAkB,cAAc,OAAO;AAI9D,QACE,iBAAA,GAAA,kBAAA,KAACC,YAAAA,KAAD;EAAK,GAHKC,2BAAAA,sBAAsB,CAGnB,UAAU,QAAQ;GAAE;GAAW;GAAO;GAAQ;GAAY,CAAC;EAAE,GAAI;YAC5E,iBAAA,GAAA,kBAAA,KAAC,MAAD,EACE,OAAO;GACL,OAAO;GACP,QAAQ;GACT,EACD,CAAA;EACE,CAAA;EAER;AAEF,eAAe,UAAUC,0BAAAA;AACzB,eAAe,cAAc"}