• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

IQSS / dataverse-frontend / 10219381635

02 Aug 2024 05:08PM CUT coverage: 98.403%. Remained the same
10219381635

push

github

GermanSaracca
feat: back to disable button

86 of 90 branches covered (95.56%)

Branch coverage included in aggregate %.

222 of 223 relevant lines covered (99.55%)

198.27 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

100.0
/packages/design-system/src/lib/components/alert/AlertIcon.tsx
1
import { AlertVariant } from './AlertVariant'
336✔
2
import {
3
  CheckCircleFill,
4
  ExclamationCircleFill,
5
  ExclamationTriangleFill,
6
  InfoCircleFill
7
} from 'react-bootstrap-icons'
8

9
interface AlertIconProps {
10
  variant: AlertVariant
11
}
12
export function AlertIcon({ variant }: AlertIconProps) {
48✔
13
  interface AlertIcons {
14
    [key: string]: JSX.Element
15
  }
16
  const ALERT_ICONS: AlertIcons = {
210✔
17
    success: <CheckCircleFill></CheckCircleFill>,
18
    info: <InfoCircleFill></InfoCircleFill>,
19
    warning: <ExclamationTriangleFill></ExclamationTriangleFill>,
20
    danger: <ExclamationCircleFill></ExclamationCircleFill>
21
  }
22
  function getAlertIcon(variant: AlertVariant): JSX.Element {
23
    return ALERT_ICONS[variant]
210✔
24
  }
25
  return (
210✔
26
    <span role="img" aria-label={`alert-icon-${variant}`}>
27
      {getAlertIcon(variant)}
28
    </span>
29
  )
30
}
48✔
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc