1
0
mirror of https://github.com/yldio/copilot.git synced 2024-11-14 23:30:05 +02:00
copilot/ui/src/components/tooltip
2017-01-12 19:04:52 +00:00
..
index.js convert every px measure into rem 2017-01-12 19:04:52 +00:00
readme.md implimenting tooltip component 2016-12-21 11:19:59 +00:00
story.js moving stories to directory folders 2017-01-11 14:22:42 +00:00

<Tooltip>

demo

const React = require('react');
const ReactDOM = require('react-dom/server');
const Base = require('../base');
const Container = require('../container');
const Row = require('../row');
const Column = require('../column');
const Tooltip = require('./index.js');
const styles = require('./style.css');

nmodule.exports = ReactDOM.renderToString(
  <Base>
    <Row>
      <Column>
        <Tooltip color='#35a8c0' name='Alex' />
      </Column>
      <Column>
        <Tooltip color='#ef6176' name='Alex' src='https://openclipart.org/image/2400px/svg_to_png/177482/ProfilePlaceholderSuit.png' />
      </Column>
    </Row>
  </Base>
);

usage

const React = require('react');
const Tooltip = require('ui/avatar');

module.exports = () => {
  return (
    <Tooltip color='#35a8c0' name='Alex' />
    <Tooltip color='#ef6176' name='Alex' src='path/to/image.png' />
  );
}