1.0.0-beta.10 • Published 6 years ago
ethstats-ui v1.0.0-beta.10
ethstats-ui
React component library for EthStats apps
Prerequisites
- Node 8+ for development
- ES2015+ compliant browser for runtime
Installation
npm i ethstats-ui- Copy files from
public/cssandpublic/fontsinto your root app folder and import CSS in your index.html. - Just import any component with
import { ... } from "ethstats-ui/lib/path/to/Component"
Development
npm installnpm run buildfor production ornpm run watchfor development.
Project structure
📁ethstats-ui
├─📁lib - target folder for application that contains deployables
├─📁public - contains static assets that are copied to the dist folder as they are
└─📁src - source files
├─📁control - reusable ui controls and widgets
├─📁data - components for displaying and formatting various types of data
├─📁fx - Effects and animations
├─📁icon - reusable icon components (SVG or icon font wrappers)
└─📁layout - components for layout / arrangementManaging SVG icons
Original SVG sources should be kept in the dev/original-svg folder. To create SVG icon components from them, the following steps should be taken:
- Copy the SVG markup in the render method of a new React component
- Replace all dash (-) attributes with camelCase
- Remove any unneeded attributes or run the SVG through an optimizer tool
- The viewBox of the icon should be a square. If needed use
<g transform="translate(x,y)">to center the icon in the new viewBox. This allows proper sizing viasizeprop - Replace the main fill/stroke color with
currentColor, to ensure proper cascading, or parametrize if more than one color - The resulting component should be configured with a size prop that applies to both width and height
1.0.0-beta.10
6 years ago
1.0.0-beta.9
6 years ago
1.0.0-beta.8
6 years ago
1.0.0-beta.7
6 years ago
1.0.0-beta.6
7 years ago
1.0.0-beta.5
7 years ago
1.0.0-beta.4
7 years ago
1.0.0-beta.3
7 years ago
1.0.0-beta.2
7 years ago
1.0.0-beta.1
7 years ago