Merged in fix/3697-prettier-configs (pull request #3396)

fix(SW-3691): Setup one prettier config for whole repo

* Setup prettierrc in root and remove other configs


Approved-by: Joakim Jäderberg
Approved-by: Linus Flood
This commit is contained in:
Rasmus Langvad
2026-01-07 12:45:50 +00:00
parent 932413412b
commit d0546926a9
500 changed files with 18367 additions and 18419 deletions

View File

@@ -1,28 +1,28 @@
import { MaterialIcon } from '../Icons/MaterialIcon'
import { Typography } from '../Typography'
import Image from '../Image'
import { MaterialIcon } from "../Icons/MaterialIcon"
import { Typography } from "../Typography"
import Image from "../Image"
import { variants } from './variants'
import type { AvatarProps } from './types'
import { variants } from "./variants"
import type { AvatarProps } from "./types"
export function Avatar({
src,
alt,
initials,
size = 'md',
size = "md",
className,
}: AvatarProps) {
const classNames = variants({ size, className })
const pixelSize = size === 'sm' ? 24 : size === 'md' ? 32 : 55
const iconSize = size === 'sm' ? 16 : 24
const pixelSize = size === "sm" ? 24 : size === "md" ? 32 : 55
const iconSize = size === "sm" ? 16 : 24
return (
<div className={classNames}>
{src ? (
<Image src={src} alt={alt || ''} width={pixelSize} height={pixelSize} />
<Image src={src} alt={alt || ""} width={pixelSize} height={pixelSize} />
) : initials ? (
<Typography
variant={size === 'lg' ? 'Title/Overline/sm' : 'Tag/sm'}
variant={size === "lg" ? "Title/Overline/sm" : "Tag/sm"}
className={variants.initials}
>
<span data-hj-suppress>{initials}</span>