GithubHelp home page GithubHelp logo

fodpeter / react-github-fork-ribbon Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jessy1092/react-github-fork-ribbon

0.0 2.0 0.0 1.14 MB

Pure inline style github fork ribbon on React component.

Home Page: http://jessy1092.github.io/react-github-fork-ribbon/

JavaScript 100.00%

react-github-fork-ribbon's Introduction

React GitHub Fork Ribbon

npm Dependency Status

Pure inline style github fork ribbon on React component. The inline style css is from "Fork me on GitHub" CSS ribbon.

React = 0.12 React = 0.13 React >= 0.14
Version <= 0.2 >= 0.3 < 0.5 >= 0.5

Usage

npm install react-github-fork-ribbon

Ex. React 15.5

import React            from 'react';
import ReactDOM         from 'react-dom';
import GitHubForkRibbon from 'react-github-fork-ribbon';

const Content = () => (
  <GitHubForkRibbon href="//www.google.com"
                    target="_blank"
                    position="right">
    Fork me on GitHub
  </GitHubForkRibbon>
);

ReactDOM.render(
  <Content />,
  document.getElementById('content')
);

Attribute

href

It would be <a> tag's attribute href

target

It would be <a> tag's attribute target

position

It has four positions.

  • left
  • right
  • left-bottom
  • right-bottom

color

It has four color.

  • red
  • orange
  • black
  • green

className

It would be an html tag's attribute class.

Release Notes

Version 0.5.1 - 2017/10/05

  • Support react 16
  • Upgrade development environment

Version 0.5.0 - 2017/04/11

  • Drop react 0.13 support
  • Support react 15.5 for preparing upgrade to react 16
  • Add jest for snapshot testing

Version 0.4.5 - 2017/03/11

  • Refactor position and color set function
  • Remove object-assign library
  • Use storybook to help develop

Version 0.4.4 - 2016/04/30

  • Fix React 15 unitless number warning

Version 0.4.3 - 2016/04/18

  • Support React 15.0
  • Browserify bundle js file for web usage.

Version 0.4.2 - 2015/10/11

  • Support React 0.14

Version 0.4.1 - 2015/06/29

  • Insert the relevant browser prefix.
    • Webkit, Moz, O, ms.

Version 0.4.0 - 2015/06/28

  • Switch to vanilla inline styles. PR#7
  • Update Dev-dependencies version. babel => 5.6.14, browserify => 10.2.4

Version 0.3.0 - 2015/03/28

  • Support react 0.13.x and react-style 0.5.x version
  • Use ES6 feature.

Version 0.2.0 - 2015/03/07

  • Add attribute: color
  • Transpile into vanilla js during prepublish.

Version 0.1.0 - 2015/01/16

  • Init
  • Add attribute: href, target, position

Contribute

devDependency Status

  1. Fork it.
  2. Create your feature-branch git checkout -b your-new-feature-branch
  3. Commit your change git commit -am 'Add new feature'
  4. Push to the branch git push origin your-new-feature-branch
  5. Create new Pull Request with master branch

License

The MIT License (MIT)

Copyright (c) 2015-2017 Lee < [email protected] >

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

react-github-fork-ribbon's People

Contributors

a-deluna avatar andreypopp avatar jessy1092 avatar lquixada avatar pokatomnik avatar sanderspies avatar sugarshin avatar tomchentw avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.