import * as React from 'react'; import styled from 'styled-components'; import { AntDesignOutlined, DashboardOutlined, TwitterOutlined } from '../../src'; const Div = styled.div` position: relative; margin-bottom: 1rem; line-height: 1; &:after { width: 100%; height: 1px; content: ''; position: absolute; bottom: 0.125em; left: 0; background-color: hotpink; z-index: -100; } &:before { width: 100%; height: 1px; content: ''; position: absolute; top: 0.125em; left: 0; background-color: hotpink; z-index: -100; } `; export default class SimpleDemo extends React.Component<{}> { static displaySize = ['64px', '48px', '32px', '24px', '16px', '12px', '8px']; static relatedHref = 'https://blog.prototypr.io/align-' + 'svg-icons-to-text-and-say-goodbye-to-font-icons-d44b3d7b26b4'; static renderStatement(fontSize: string, index: number) { const style: React.CSSProperties = { fontSize, color: (fontSize === '48px' && 'lightblue') || 'inherit', }; return (
{fontSize} Ant Design 0123 你好
); } render() { return (

Simple Demo - Icons Alignments

{ SimpleDemo.displaySize.map((fontSize, index) => SimpleDemo.renderStatement(fontSize, index), ) } See{' '} related blog {' '} for detail.
); } }