All files / src HomePage.js

100% Statements 3/3
100% Branches 0/0
100% Functions 1/1
100% Lines 3/3

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94                  3x   3x 4x                                                                                                                                                                  
// @flow strict
import React from 'react';
 
import LayoutCell from './material-toolbox/layout-grid/Cell';
import Text from './material-toolbox/typography/Text';
 
import Highlighter from './Highlighter';
import ThemedLink from './ThemedLink';
 
const importCode = '@import "@material/drawer/mdc-drawer";';
 
const HomePage = () => (
  <LayoutCell align="bottom" span={12}>
    <Text as="div" text="body2">
      <Text as="p" text="overline">
        NOTE.- This library is under deep changes, searching the best way to
        follow the React Style. Please use it with caution.
      </Text>
      <p>Second note.- Most of examples, design and content are from:</p>
      <p>
        <ThemedLink
          to="https://material.io/components/web/catalog/"
          target="_blank"
        >
          https://material.io/components/web/catalog/
        </ThemedLink>
      </p>
      <p>
        <ThemedLink
          to="https://material-components-web.appspot.com"
          target="_blank"
        >
          https://material-components-web.appspot.com
        </ThemedLink>
      </p>
      <p>
        <ThemedLink to="https://react-mdc.github.io/" target="_blank">
          https://react-mdc.github.io/
        </ThemedLink>
      </p>
      <p>
        <ThemedLink to="https://jamesmfriedman.github.io/" target="_blank">
          https://jamesmfriedman.github.io/
        </ThemedLink>
      </p>
    </Text>
 
    <Text as="h2" text="headline5">
      Getting started
    </Text>
 
    <Text as="p" text="body1">
      Get up and running with React Material Components web
    </Text>
 
    <Highlighter language="bash">
      $ npm install --save material-toolbox
    </Highlighter>
 
    <Text as="h2" text="headline5">
      Notes
    </Text>
 
    <p>
      1. As React is a Javascript library css only versions is not available.
    </p>
 
    <p>
      2. As this is a React wrapper will skip some MRC events and props this in
      favor of React declarative style.
    </p>
 
    <p>
      3. You have to import the css/scss files from material components, into
      your scss or the css as needed.
    </p>
 
    <Highlighter language="css">{importCode}</Highlighter>
 
    <Text as="h2" text="headline5">
      Development Notes
    </Text>
 
    <p>
      1. Adapters.- classNames will use javascript native add, remove, contain
      code. This because exists some transitions where react does not handle
      well because state is asynchronous and does bulk update and we need to
      update classes in the same time.
    </p>
  </LayoutCell>
);
 
export default HomePage;