{"version":3,"file":"link-button.Bfie962q.js","sources":["../../../src/components/ui/link-button.tsx"],"sourcesContent":["import * as React from 'react'\nimport { Slot } from '@radix-ui/react-slot'\nimport { type VariantProps } from 'class-variance-authority'\n\nimport { cn } from '@lib/utils'\nimport { buttonVariants } from './button'\nimport type { AnalyticsAttributes, ContextPlacement, CtaType, PlanType } from '@lib/analytics.d'\nimport { buildAnalyticsData } from '@lib/analytics-utils'\n\n\nexport interface LinkButtonProps\n extends React.AnchorHTMLAttributes,\n VariantProps {\n asChild?: boolean\n analyticsContext?: string\n analyticsSubContext?: string\n ctaType?: CtaType\n planId?: number\n planName?: string\n planState?: string\n contextPlacement?: ContextPlacement\n planType?: PlanType\n userTarget?: string\n}\n\nconst LinkButton = React.forwardRef(\n (\n {\n className,\n variant,\n size,\n asChild = false,\n analyticsContext,\n analyticsSubContext,\n ctaType,\n planId,\n planName,\n planState,\n contextPlacement,\n planType,\n userTarget,\n ...props\n },\n ref\n ) => {\n const Comp = asChild ? Slot : 'a'\n\n const attributes: AnalyticsAttributes = {\n 'data-analytics-context': analyticsContext,\n 'data-analytics-sub-context': analyticsSubContext,\n 'data-cta-type': ctaType,\n 'data-plan-id': planId,\n 'data-plan-name': planName,\n 'data-plan-state': planState,\n 'data-context-placement': contextPlacement,\n 'data-plan-type': planType,\n 'data-user-target': userTarget\n }\n\n const analyticsData = buildAnalyticsData(attributes)\n\n return (\n \n )\n }\n)\n\nLinkButton.displayName = 'LinkButton'\n\nexport { LinkButton }\n"],"names":["LinkButton","React.forwardRef","className","variant","size","asChild","analyticsContext","analyticsSubContext","ctaType","planId","planName","planState","contextPlacement","planType","userTarget","props","ref","Comp","Slot","analyticsData","buildAnalyticsData","jsx","cn","buttonVariants"],"mappings":"0lBAyBA,MAAMA,EAAaC,EAAM,WACvB,CACE,CACE,UAAAC,EACA,QAAAC,EACA,KAAAC,EACA,QAAAC,EAAU,GACV,iBAAAC,EACA,oBAAAC,EACA,QAAAC,EACA,OAAAC,EACA,SAAAC,EACA,UAAAC,EACA,iBAAAC,EACA,SAAAC,EACA,WAAAC,EACA,GAAGC,GAELC,IACG,CACG,MAAAC,EAAOZ,EAAUa,EAAO,IAcxBC,EAAgBC,EAZkB,CACtC,yBAA0Bd,EAC1B,6BAA8BC,EAC9B,gBAAiBC,EACjB,eAAgBC,EAChB,iBAAkBC,EAClB,kBAAmBC,EACnB,yBAA0BC,EAC1B,iBAAkBC,EAClB,mBAAoBC,CAAA,CAG6B,EAGjD,OAAAO,EAAA,IAACJ,EAAA,CACC,UAAWK,EAAGC,EAAe,CAAE,QAAApB,EAAS,KAAAC,EAAM,UAAAF,CAAA,CAAW,CAAC,EAC1D,IAAAc,EACC,GAAGG,EACH,GAAGJ,CAAA,CAAA,CAGV,CACF,EAEAf,EAAW,YAAc"}