{"version":3,"sources":["../../../src/components/branding/HelpwaveBadge.tsx","../../../src/components/layout-and-navigation/Tile.tsx","../../../src/components/icons-and-geometry/Helpwave.tsx"],"sourcesContent":["import clsx from 'clsx'\nimport { Tile } from '../layout-and-navigation/Tile'\nimport { Helpwave } from '../icons-and-geometry/Helpwave'\n\ntype Size = 'small' | 'large'\n\nexport type HelpwaveBadgeProps = {\n  size?: Size,\n  title?: string,\n  className?: string,\n}\n\n/**\n * A Badge with the helpwave logo and the helpwave name\n */\nexport const HelpwaveBadge = ({\n                                size = 'small',\n                                title = 'helpwave',\n                                className = ''\n                              }: HelpwaveBadgeProps) => {\n  const iconSize: number = size === 'small' ? 24 : 64\n\n  return (\n    <Tile\n      prefix={(<Helpwave size={iconSize}/>)}\n      title={title}\n      titleClassName={size === 'small' ? 'textstyle-title-lg text-base' : 'textstyle-title-xl'}\n      className={clsx(\n        {\n          'px-2 py-1 rounded-md': size === 'small',\n          'px-4 py-1 rounded-md': size === 'large',\n        }, className\n      )}\n    />\n  )\n}\n","import type { ReactNode } from 'react'\nimport clsx from 'clsx'\nimport { Check } from 'lucide-react'\n\nexport type TileProps = {\n  title: ReactNode,\n  titleClassName?: string,\n  description?: ReactNode,\n  descriptionClassName?: string,\n  onClick?: () => void,\n  disabled?: boolean,\n  isSelected?: boolean,\n  isListItem?: boolean,\n  prefix?: ReactNode,\n  suffix?: ReactNode,\n  className?: string,\n  normalClassName?: string,\n  selectedClassName?: string,\n  disabledClassName?: string,\n}\n\n/**\n * A component for creating a tile similar to the flutter ListTile\n */\nexport const Tile = ({\n                       title,\n                       titleClassName,\n                       description,\n                       descriptionClassName,\n                       onClick,\n                       isSelected = false,\n                       disabled = false,\n                       prefix,\n                       suffix,\n                       normalClassName = 'hover:bg-primary/40 cursor-pointer',\n                       selectedClassName = 'bg-primary/20',\n                       disabledClassName = 'text-disabled-text bg-disabled-background cursor-not-allowed',\n                       className\n                     }: TileProps) => {\n  return (\n    <div\n      className={clsx(\n        'flex-row-2 w-full items-center',\n        {\n          [normalClassName]: onClick && !disabled,\n          [selectedClassName]: isSelected && !disabled,\n          [disabledClassName]: disabled,\n        },\n        className\n      )}\n      onClick={disabled ? undefined : onClick}\n    >\n      {prefix}\n      <div className=\"flex-col-0 w-full\">\n        <span className={clsx(titleClassName ?? ('textstyle-title-normal'))}>{title}</span>\n        {!!description &&\n          <span className={clsx(descriptionClassName ?? 'textstyle-description')}>{description}</span>}\n      </div>\n      {suffix ?? (isSelected ? (<Check size={24}/>) : undefined)}\n    </div>\n  )\n}\n\nexport type ListTileProps = TileProps\n\nexport const ListTile = ({\n  ...props\n}: ListTileProps) => {\n  return (\n    <Tile\n      {...props}\n      titleClassName={props.titleClassName ?? 'font-semibold'}\n      className={clsx('px-2 py-1 rounded-md', props.className)}\n      disabledClassName={props.disabledClassName ?? 'text-disabled-text cursor-not-allowed'}\n    />\n  )\n}\n","import type { SVGProps } from 'react'\nimport { clsx } from 'clsx'\n\nexport type HelpwaveProps = SVGProps<SVGSVGElement> & {\n  color?: string,\n  animate?: 'none' | 'loading' | 'pulse' | 'bounce',\n  size?: number,\n}\n\n/**\n * The helpwave loading spinner based on the svg logo.\n */\nexport const Helpwave = ({\n                           color = 'currentColor',\n                           animate = 'none',\n                           size = 64,\n                           ...props\n                         }: HelpwaveProps) => {\n  const isLoadingAnimation = animate === 'loading'\n  let svgAnimationKey = ''\n\n  if (animate === 'pulse') {\n    svgAnimationKey = 'animate-pulse'\n  } else if (animate === 'bounce') {\n    svgAnimationKey = 'animate-bounce'\n  }\n\n  if (size < 0) {\n    console.error('size cannot be less than 0')\n    size = 64\n  }\n\n  return (\n    <svg\n      width={size}\n      height={size}\n      viewBox=\"0 0 888 888\"\n      fill=\"none\"\n      strokeLinecap=\"round\"\n      strokeWidth={48}\n      {...props}\n    >\n      <g className={clsx(svgAnimationKey)}>\n        <path className={clsx({ 'animate-wave-big-left-up': isLoadingAnimation })}\n              d=\"M144 543.235C144 423.259 232.164 326 340.92 326\" stroke={color} strokeDasharray=\"1000\"/>\n        <path className={clsx({ 'animate-wave-big-right-down': isLoadingAnimation })}\n              d=\"M537.84 544.104C429.084 544.104 340.92 446.844 340.92 326.869\" stroke={color} strokeDasharray=\"1000\"/>\n        <path className={clsx({ 'animate-wave-small-left-up': isLoadingAnimation })}\n              d=\"M462.223 518.035C462.223 432.133 525.348 362.495 603.217 362.495\" stroke={color}\n              strokeDasharray=\"1000\"/>\n        <path className={clsx({ 'animate-wave-small-right-down': isLoadingAnimation })}\n              d=\"M745.001 519.773C666.696 519.773 603.218 450.136 603.218 364.233\" stroke={color}\n              strokeDasharray=\"1000\"/>\n      </g>\n    </svg>\n  )\n}\n"],"mappings":";AAAA,OAAOA,WAAU;;;ACCjB,OAAO,UAAU;AACjB,SAAS,aAAa;AAmDhB,SACE,KADF;AA7BC,IAAM,OAAO,CAAC;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,aAAa;AAAA,EACb,WAAW;AAAA,EACX;AAAA,EACA;AAAA,EACA,kBAAkB;AAAA,EAClB,oBAAoB;AAAA,EACpB,oBAAoB;AAAA,EACpB;AACF,MAAiB;AACpC,SACE;AAAA,IAAC;AAAA;AAAA,MACC,WAAW;AAAA,QACT;AAAA,QACA;AAAA,UACE,CAAC,eAAe,GAAG,WAAW,CAAC;AAAA,UAC/B,CAAC,iBAAiB,GAAG,cAAc,CAAC;AAAA,UACpC,CAAC,iBAAiB,GAAG;AAAA,QACvB;AAAA,QACA;AAAA,MACF;AAAA,MACA,SAAS,WAAW,SAAY;AAAA,MAE/B;AAAA;AAAA,QACD,qBAAC,SAAI,WAAU,qBACb;AAAA,8BAAC,UAAK,WAAW,KAAK,kBAAmB,wBAAyB,GAAI,iBAAM;AAAA,UAC3E,CAAC,CAAC,eACD,oBAAC,UAAK,WAAW,KAAK,wBAAwB,uBAAuB,GAAI,uBAAY;AAAA,WACzF;AAAA,QACC,WAAW,aAAc,oBAAC,SAAM,MAAM,IAAG,IAAM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