Ejemplo n.º 1
0
const styles = StyleSheet.create({
  default: {
    display: 'inline-block',
    padding: '6px 12px',
    marginBottom: 0,
    fontSize: 14,
    fontWeight: 'normal',
    lineHeight: 1.5,
    textAlign: 'center',
    whiteSpace: 'nowrap',
    verticalAlign: 'middle',
    touchAction: 'manipulation',
    cursor: 'pointer',
    userSelect: 'none',
    backgroundImage: 'none',
    border: '1px solid transparent',
    borderRadius: 4,
    color: '#fff',
    backgroundColor: '#337ab7',
    borderColor: '#2e6da4',

    '@media only screen and (max-width: 640px)': {
      display: 'block',
      width: '100%'
    },

    ':focus': {
      color: '#fff',
      backgroundColor: '#286090',
      borderColor: '#122b40',
      outline: 'thin dotted',
      outlineOffset: -2
    },

    ':hover': {
      color: '#fff',
      backgroundColor: '#286090',
      borderColor: '#204d74',
      textDecoration: 'none'
    },

    ':active': {
      color: '#fff',
      backgroundColor: '#286090',
      borderColor: '#204d74',
      backgroundImage: 'none',
      outline: 0,
      boxShadow: 'inset 0 3px 5px rgba(0, 0, 0, .125)',

      ':hover': {
        color: '#fff',
        backgroundColor: '#204d74',
        borderColor: '#122b40'
      }
    },

    '[disabled]': {
      backgroundColor: '#337ab7',
      borderColor: '#2e6da4',
      cursor: 'not-allowed',
      filter: 'alpha(opacity=65)',
      boxShadow: 'none',
      opacity: .65,
      pointerEvents: 'none'
    }
  },

  large: {
    padding: '10px 16px',
    fontSize: 18,
    lineHeight: 1.33,
    borderRadius: 6
  },

  small: {
    padding: '5px 10px',
    fontSize: 12,
    lineHeight: 1.5,
    borderRadius: 3
  },

  block: {
    display: 'block',
    width: '100%'
  }
});
Ejemplo n.º 2
0
import React from 'react';
import StyleSheet from 'react-inline';

const styles = StyleSheet.create({
  container: {
    textAlign: 'center'
  },
  button: {
    backgroundColor: '#ff0000',
    width: 320,
    padding: 20,
    borderRadius: 5,
    border: 'none',
    outline: 'none',
    ':hover': {
      color: '#fff'
    },
    ':active': {
      position: 'relative',
      top: 2
    },
    '@media (max-width: 480px)': {
      width: 160
    }
  }
});

class Button extends React.Component {
  render() {
    return (
      <div className={styles.container}>
Ejemplo n.º 3
0
    return buttons.map((button, i) => {
      return <li key={i}>{button}</li>;
    });
  }

  getButtonSizes() {
    return [undefined].concat(Button.sizes);
  }

  getButtonKinds() {
    return [undefined].concat(Button.kinds);
  }
}

export default ButtonList;

var styles = StyleSheet.create({
  blackButton: {
    color: '#999',
    backgroundColor: 'black',
    borderColor: 'black'
  },

  list: {
    paddingLeft: 0,
    listStyleType: 'none'
  }
});