How to use @ant-design/icons - 3 common examples

To help you get started, we’ve selected a few @ant-design/icons examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github ant-design / ant-design / site / theme / template / Icon / index.jsx View on Github external
/* eslint-disable camelcase */
import React from 'react';
import AntdIcon, { createFromIconfontCN } from '@ant-design/icons';

import { withThemeSuffix, removeTypeTheme, getThemeFromTypeName } from './utils';
import warning from '../../../../components/_util/warning';

const IconFont = createFromIconfontCN({
  scriptUrl: '//at.alicdn.com/t/font_1329669_t1u72b9zk8s.js',
});

const OldIcon = props => {
  const { type, theme } = props;
  let computedType = type;
  if (theme) {
    const themeInName = getThemeFromTypeName(type);
    warning(
      !themeInName || theme === themeInName,
      'Icon',
      `The icon name '${type}' already specify a theme '${themeInName}',` +
        ` the 'theme' prop '${theme}' will be ignored.`,
    );
  }
  computedType = withThemeSuffix(removeTypeTheme(computedType), theme || 'outlined');
github SolidZORO / leaa / packages / leaa-dashboard / src / components / Rcon / Rcon.tsx View on Github external
export const Rcon = forwardRef((props: IProps, ref: any) => {
  // ANTD OFFICIAL ICON --> '//at.alicdn.com/t/font_1329669_t1u72b9zk8s.js'
  const CustomIcon: any = createFromIconfontCN({ scriptUrl: localIconfont, extraCommonProps: { ...props } });

  return (
    
  );
});
github dotnetcore / WTM / demo / WalkingTec.Mvvm.ReactDemo / ClientApp / src / pages / frameworkmenu / views / models.tsx View on Github external
import { WtmCascader, WtmCheckbox, WtmDatePicker, WtmEditor, WtmRadio, WtmSelect, WtmTransfer, WtmUploadImg, WtmUpload } from 'components/form';
import { FormItem } from 'components/dataView';
import * as React from 'react';
import lodash from 'lodash';
import { Observable } from 'rxjs';
import Regular from 'utils/Regular';
import AntIcons from "@ant-design/icons/lib/manifest";
import Fonts from "assets/font/font";
import Request from 'utils/Request';
import { BindAll } from 'lodash-decorators';
import { mergeLocales, getLocalesValue, getLocalesTemplate } from 'locale';
import { FormattedMessage } from 'react-intl';
Fonts.unshift({
    name: "Antd",
    class: "Antd",
    icons: AntIcons.fill,
})

mergeLocales({
    "zh-CN": {
        'frameworkmenu.PageName': '页面名称',
        'frameworkmenu.SelectedModule': '模块名称',
        'frameworkmenu.SelectedActionIDs': '动作名称',
        'frameworkmenu.FolderOnly': '目录',
        'frameworkmenu.ShowOnMenu': '菜单显示',
        'frameworkmenu.IsPublic': '公开',
        'frameworkmenu.DisplayOrder': '顺序',
        'frameworkmenu.IsInside': '地址类型',
        'frameworkmenu.IsInside.0': '内部地址',
        'frameworkmenu.IsInside.1': '外部地址',
        'frameworkmenu.Url': 'Url',
        'frameworkmenu.ICon': '图标',

@ant-design/icons

[![NPM version](https://img.shields.io/npm/v/@ant-design/icons.svg?style=flat)](https://npmjs.org/package/@ant-design/icons) [![NPM downloads](http://img.shields.io/npm/dm/@ant-design/icons.svg?style=flat)](https://npmjs.org/package/@ant-design/icons)

MIT
Latest version published 2 months ago

Package Health Score

79 / 100
Full package analysis

Similar packages