Nine Parsecs from Milwaukee

    @antv/graphin-icons

    1.0.0 • Public • Published

    @antv/graphin-icons

    中文

    Graphin's font icons

    Usage

    import React from 'react';
    import ReactDOM from 'react-dom';
    import Graphin, { Utils } from '@antv/graphin';
    import { Toolbar } from '@antv/graphin-components';
    
    // Do not forget to import CSS
    import '@antv/graphin/dist/index.css';
    import '@antv/graphin-components/dist/index.css';
    
    // font icon
    import fontLoader from '@antv/graphin-icons';
    import '@antv/graphin-icons/dist/index.css';
    
    /** 加载 font icons **/
    Graphin.registerIcon('graphin', fontLoader);
    const data = Utils.mock(10).graphin();
    
    data.nodes.forEach((node) => {
      node.style.icon = {
        fontFamilay: 'graphin',
        value: 'eye',
      };
    });
    
    const App = () => {
      return (
        <div className="App">
          <Graphin data={data}>
            <Toolbar />
          </Graphin>
        </div>
      );
    };
    
    const rootElement = document.getElementById('root');
    ReactDOM.render(<App />, rootElement);

    Keywords

    none

    Install

    npm i @antv/graphin-icons

    DownloadsWeekly Downloads

    140

    Version

    1.0.0

    License

    ISC

    Unpacked Size

    76.8 kB

    Total Files

    5

    Last publish

    Collaborators

    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar
    • avatar