Icon

Overview

BigDesign offers a variety of icon components that can be used in a project. We also provide Country flags icons that can be imported.

To use the icons install @bigcommerce/big-design-icons package from npm.

When to use:

  • To represent an action or a status.
  • To provide additional visual cues.

Implementation

A complete list of available flags is located here.

To use a flag import the component from the package:

Code example

import { USFlagIcon } from '@bigcommerce/big-design-icons/flags';

Use it anywhere in your app:

US flag

Edit the code below to see your changes live!

<USFlagIcon size="xxxLarge" />

    Edit the code below to see your changes live!

    function Example() {
      const [value, setValue] = useState('');
      const handleChange = (val) => setValue(val);
    
      return (
        <Form>
          <FormGroup>
            <Select
              filterable={false}
              label="Countries"
              maxHeight={300}
              onOptionChange={handleChange}
              options={[
                { value: 'us', content: 'United States', icon: <USFlagIcon /> },
                { value: 'mx', content: 'Mexico', icon: <MXFlagIcon /> },
                { value: 'ca', content: 'Canada', icon: <CAFlagIcon /> },
                { value: 'en', content: 'England', icon: <GBFlagIcon /> },
                { value: 'fr', content: 'France', icon: <FRFlagIcon /> },
                { value: 'gr', content: 'Germany', icon: <DEFlagIcon /> },
                { value: 'ar', content: 'Argentina', icon: <ARFlagIcon /> },
                {
                  value: 'ru',
                  content: 'Russia',
                  disabled: true,
                  icon: <RUFlagIcon />,
                },
                { value: 'ch', content: 'Chile', icon: <CLFlagIcon /> },
                { value: 'jp', content: 'Japan', icon: <JPFlagIcon /> },
                { value: 'cn', content: 'China', icon: <CNFlagIcon /> },
                { value: 'sk', content: 'South Korea', icon: <KRFlagIcon /> },
                { value: 'au', content: 'Australia', icon: <AUFlagIcon /> },
              ]}
              placeholder="Choose country"
              placement="bottom-start"
              required
              value={value}
            />
          </FormGroup>
        </Form>
      );
    }
    

    Props

    Prop name
    Type
    Default
    Description
    titlestring

    SVG Title, for accessibility purposes.

    colorColor

    Sets the icon color given a color name from our palette.

    sizeSpacing | number

    Determines the size of the icon. Accepts a Spacing value or a number of px.

    Props ending with * are required

    Available icons

    <AddCircleOutlineIcon />
    <AddIcon />
    <AllInclusiveIcon />
    <ArrowBackIcon />
    <ArrowDownwardIcon />
    <ArrowDropDownIcon />
    <ArrowForwardIcon />
    <ArrowUpwardIcon />
    <AssignmentIcon />
    <AutoAwesomeIcon />
    <BaselineHelpIcon />
    <BrushIcon />
    <CheckCircleIcon />
    <CheckIcon />
    <ChevronLeftIcon />
    <ChevronRightIcon />
    <CloseIcon />
    <CloudUploadIcon />
    <CodeIcon />
    <ContentCopyIcon />
    <DeleteIcon />
    <DraftIcon />
    <DragIndicatorIcon />
    <EditIcon />
    <ErrorIcon />
    <ExpandLessIcon />
    <ExpandMoreIcon />
    <FileCopyIcon />
    <FileDownloadIcon />
    <FilterListIcon />
    <FolderIcon />
    <GetAppIcon />
    <HomeIcon />
    <InfoIcon />
    <InsertDriveFileIcon />
    <InvertColorsIcon />
    <KeyboardDoubleArrowLeftIcon />
    <LanguageIcon />
    <LogoutIcon />
    <MenuIcon />
    <MoreHorizIcon />
    <NotificationsIcon />
    <OpenInNewIcon />
    <PinIcon />
    <PublicIcon />
    <ReceiptIcon />
    <RedoIcon />
    <RemoveCircleOutlineIcon />
    <RemoveIcon />
    <RestoreIcon />
    <SearchIcon />
    <SettingsIcon />
    <StarBorderIcon />
    <StarHalfIcon />
    <StarIcon />
    <StoreIcon />
    <SwapHorizIcon />
    <UndoIcon />
    <VisibilityIcon />
    <VisibilityOffIcon />
    <WarningIcon />
    <WindowExpandIcon />
    <WindowMinimizeIcon />