All files ribbonStyle.js

100% Statements 2/2
100% Branches 0/0
100% Functions 0/0
100% Lines 2/2
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 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161            1x                                                                                                                                                                                                                                       1x                                                                            
/*
* "Fork me on GitHub" CSS ribbon v0.1.1 | MIT License
* https://github.com/simonwhitaker/github-fork-ribbon-css
*
* 20150116 Lee: use css source for inline style react component.
*/
export const RibbonStyle = {
 
  baseStyle: {
    /* The right and left classes determine the side we attach our banner to */
    position: 'absolute',
 
    /* Add a bit of padding to give some substance outside the "stitching" */
    padding: '2px 0',
 
    /* Set the base colour */
    backgroundColor: '#a00',
 
    /* Set a gradient: transparent black at the top to almost-transparent black at the bottom */
    // backgroundImage: '-webkit-gradient(linear, left top, left bottom, from(rgba(0, 0, 0, 0)), to(rgba(0, 0, 0, 0.15)))',
    // backgroundImage: '-webkit-linear-gradient(top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15))',
    // backgroundImage: '-moz-linear-gradient(top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15))',
    // backgroundImage: '-ms-linear-gradient(top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15))',
    // backgroundImage: '-o-linear-gradient(top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15))',
    backgroundImage: 'linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.15))',
 
    /* Add a drop shadow */
    WebkitBoxShadow: '0 2px 3px 0 rgba(0, 0, 0, 0.5)',
    MozBoxShadow: '0 2px 3px 0 rgba(0, 0, 0, 0.5)',
    boxShadow: '0 2px 3px 0 rgba(0, 0, 0, 0.5)',
 
    /* Set the font */
    font: '700 13px "Helvetica Neue", Helvetica, Arial, sans-serif',
 
    zIndex: '9999',
    pointerEvents: 'auto'
  },
 
  urlStyle: {
    /* Set the text properties */
    color: '#fff',
    textDecoration: 'none',
    textShadow: '0 -1px rgba(0, 0, 0, 0.5)',
    textAlign: 'center',
 
    /* Set the geometry. If you fiddle with these you'll also need
       to tweak the top and right values in .github-fork-ribbon. */
    width: '200px',
    lineHeight: '20px',
 
    /* Set the layout properties */
    display: 'inline-block',
    padding: '2px 0',
 
    /* Add "stitching" effect */
    borderWidth: '1px 0',
    borderStyle: 'dotted',
    // borderColor: '#fff',
    borderColor: 'rgba(255, 255, 255, 0.7)'
  },
 
  redColor: {
    backgroundColor: '#a00'
  },
 
  orangeColor: {
    backgroundColor: '#f80'
  },
 
  blackColor: {
    backgroundColor: '#333'
  },
 
  greenColor: {
    backgroundColor: '#090'
  },
 
  leftStyle: {
    top: '42px',
    left: '-43px',
 
    WebkitTransform: 'rotate(-45deg)',
    MozTransform: 'rotate(-45deg)',
    msTransform: 'rotate(-45deg)',
    OTransform: 'rotate(-45deg)',
    transform: 'rotate(-45deg)'
  },
 
  rightStyle: {
    top: '42px',
    right: '-43px',
 
    WebkitTransform: 'rotate(45deg)',
    MozTransform: 'rotate(45deg)',
    msTransform: 'rotate(45deg)',
    OTransform: 'rotate(45deg)',
    transform: 'rotate(45deg)'
  },
 
  leftBottomStyle: {
    top: '80px',
    left: '-43px',
 
    WebkitTransform: 'rotate(45deg)',
    MozTransform: 'rotate(45deg)',
    msTransform: 'rotate(45deg)',
    OTransform: 'rotate(45deg)',
    transform: 'rotate(45deg)'
  },
 
  rightBottomStyle: {
    top: '80px',
    right: '-43px',
 
    WebkitTransform: 'rotate(-45deg)',
    MozTransform: 'rotate(-45deg)',
    msTransform: 'rotate(-45deg)',
    OTransform: 'rotate(-45deg)',
    transform: 'rotate(-45deg)'
  }
};
 
export const RibbonStyleWrapper = {
 
  baseStyle: {
    width: '150px',
    height: '150px',
    position: 'absolute',
    overflow: 'hidden',
    top: 0,
    zIndex: '9999',
    pointerEvents: 'none'
  },
 
  fixedStyle: {
    position: 'fixed'
  },
 
  leftStyle: {
    left: 0
  },
 
  rightStyle: {
    right: 0
  },
 
  leftBottomStyle: {
    position: 'fixed',
    top: 'inherit',
    bottom: 0,
    left: 0
  },
 
  rightBottomStyle: {
    position: 'fixed',
    top: 'inherit',
    bottom: 0,
    right: 0
  }
};