/* * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at https://mozilla.org/MPL/2.0/. * * OpenCRVS is also distributed under the terms of the Civil Registration * & Healthcare Disclaimer located at http://opencrvs.org/license. * * Copyright (C) The OpenCRVS Authors located at https://github.com/opencrvs/opencrvs-core/blob/master/AUTHORS. */ import * as React from 'react' export const DeclarationIcon = ({ isArchive, isValidatedOnReview, ...props }: React.HTMLAttributes & { isArchive?: boolean isValidatedOnReview?: boolean }) => { let fill: string let corner: string switch (props.color) { case 'green': fill = '#A4DBC6' corner = '#409877' break case 'orange': fill = '#F5CE9E' corner = '#C86E00' break case 'red': fill = '#EEA6A6' corner = '#9A4040' break case 'teal': fill = '#96E8E4' corner = '#03668D' break case 'grey': fill = '#CCCCCC' corner = '#5B5B5B' break case 'purple': fill = '#BFA4DB' corner = '#450487' break case 'blue': fill = '#99C4F7' corner = '#0A52AA' break default: fill = '#CCCCCC' corner = '#5B5B5B' } if (isValidatedOnReview) { fill = '#F5CE9E' corner = '#C86E00' } return ( {isArchive && ( )} {isValidatedOnReview && ( )} ) }