path
stringlengths
5
296
repo_name
stringlengths
5
85
content
stringlengths
25
1.05M
src/containers/book-list.js
emersonbroga/ReactReduxBooksApplication
import React, { Component } from 'react'; import { connect } from 'react-redux'; import { selectBook } from '../actions/index'; import { bindActionCreators } from 'redux'; class BookList extends Component { renderList() { return this.props.books.map((book) => { return ( <li key={book...
src/svg-icons/notification/sync.js
xmityaz/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let NotificationSync = (props) => ( <SvgIcon {...props}> <path d="M12 4V1L8 5l4 4V6c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46C19.54 15.03 20 13.57 20 12c0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-1.01.25...
src/components/video_detail.js
liyan90s/react-redux-funtime
import React from 'react'; const VideoDetail = (props) => { if (!props.selectedVideo) { return <div>Loading...</div>; } return ( <div className="video-detail col-md-8"> <div className="embed-responsive embed-responsive-16by9"> <iframe className="embed-responsive-item" src={"http://www.yout...
src/Async.js
pedroseac/react-select
import React from 'react'; import Select from './Select'; import stripDiacritics from './utils/stripDiacritics'; let requestId = 0; function initCache (cache) { if (cache && typeof cache !== 'object') { cache = {}; } return cache ? cache : null; } function updateCache (cache, input, data) { if (!cache) return...
src/components/Library.js
jansuchomel/tosine
import React, { Component } from 'react'; import { render } from 'react-dom'; import { VirtualScroll, AutoSizer } from 'react-virtualized'; export default class Library extends Component { expandLibrary(library, uri) { this.props.mopidyAction("expandLibrary", {library: library, uri: uri}); } expan...
src/index.js
Gregoor/syntactor
import React from 'react'; import ReactDOM from 'react-dom'; import { render } from './api'; import Demo from './components/demo'; const demoElement = document.getElementById('insert-syntactor-demo-here'); if (demoElement) { ReactDOM.render(<Demo />, demoElement); } else { window.Syntactor = { render: render }; }...
test/unit/Paper.spec.js
felipethome/material-ui
import React from 'react'; import {shallow} from 'enzyme'; import {assert} from 'chai'; import Paper from 'src/paper'; import getMuiTheme from 'src/styles/getMuiTheme'; describe('<Paper />', () => { const testChildren = <div className="unique">Hello World</div>; const theme = getMuiTheme(); it('renders children...
src/containers/Login/index.js
hasibsahibzada/quran.com-frontend
import React from 'react'; import FacebookTokenButton from 'components/FacebookTokenButton'; import LocaleFormattedMessage from 'components/LocaleFormattedMessage'; const logo = require('../../../static/images/logo-lg.png'); export default () => ( <div className="row" style={{ paddingTop: '10vh' }}> <div class...
src/AnimatedCircularProgress.js
kk1429/react-native-circular-progress
import React from 'react'; import PropTypes from 'prop-types'; import { View, ViewPropTypes, Animated } from 'react-native'; import CircularProgress from './CircularProgress'; const AnimatedProgress = Animated.createAnimatedComponent(CircularProgress); export default class AnimatedCircularProgress extends React.Compon...
app/javascript/mastodon/containers/video_container.js
vahnj/mastodon
import React from 'react'; import PropTypes from 'prop-types'; import { IntlProvider, addLocaleData } from 'react-intl'; import { getLocale } from '../locales'; import Video from '../features/video'; const { localeData, messages } = getLocale(); addLocaleData(localeData); export default class VideoContainer extends R...
client/scripts/main.js
stas-vilchik/bdd
import React from 'react'; import Page from './page.js'; React.render( <Page/>, document.getElementById('content') );
src/Hello.js
GWShark0/hello-package
import React, { Component } from 'react'; class Hello extends Component { render() { return ( <div className="hello">Hello, World!</div> ); } } export default Hello;
src/components/SettingsManager/Profile.js
welovekpop/uwave-web-welovekpop.club
import cx from 'classnames'; import React from 'react'; import PropTypes from 'prop-types'; import Avatar from '../Avatar'; import UserRoles from '../UserCard/UserRoles'; import ChangeUsernameButton from './ChangeUsernameButton'; const formatJoinDate = date => new Date(date).toLocaleString([], { year: 'numeric', m...
app/components/Form/Item.js
pacmessica/hackathon-frontend
import React from 'react'; import PropTypes from 'prop-types'; import styles from './Form.scss'; export const Item = ({ label, value, onUpdate }) => ( <div className={styles.field}> <label>{label}</label> <input type="text" value={value} onChange={(event) => onUpdate(event....
packages/components/src/Enumeration/Items/Item/ItemEdit.component.js
Talend/ui
import PropTypes from 'prop-types'; import React from 'react'; import classNames from 'classnames'; import keycode from 'keycode'; import { withTranslation } from 'react-i18next'; import Action from '../../../Actions/Action'; import theme from './Item.scss'; import ItemPropTypes from './Item.propTypes'; import ItemEdi...
src/Components/Comment/Comment.js
Shereminskiy/reactPJ
import React, { Component } from 'react'; export default class Comment extends Component { render() { return ( <div className="comment"> <h2 className="commentAuthor"> {this.props.author} </h2> {this.props.children} ...
test/helpers/shallowRenderHelper.js
carpeliam/timebox
/** * Function to get the shallow output for a given component * As we are using phantom.js, we also need to include the fn.proto.bind shim! * * @see http://simonsmith.io/unit-testing-react-components-without-a-dom/ * @author somonsmith */ import React from 'react'; import TestUtils from 'react-addons-test-utils'...
app/containers/Navbar/index.js
surzhik/coreola5
/** * Created by home on 21.08.2016. */ import React from 'react'; import {connect} from 'react-redux'; import {push} from 'react-router-redux'; import {createStructuredSelector} from 'reselect'; import {Row, Col, Icon, Tooltip} from 'antd'; import {selectMessages} from '../LanguageProvider/selectors'; import BreadCr...
src/Parser/DeathKnight/Unholy/Modules/Talents/DarkArbiter.js
hasseboulen/WoWAnalyzer
import React from 'react'; import SPELLS from 'common/SPELLS'; import SpellIcon from 'common/SpellIcon'; import SpellLink from 'common/SpellLink'; import Analyzer from 'Parser/Core/Analyzer'; import Combatants from 'Parser/Core/Modules/Combatants'; import StatisticBox, { STATISTIC_ORDER } from 'Main/StatisticBox'; c...
src/FlatButton/FlatButton.spec.js
manchesergit/material-ui
/* eslint-env mocha */ import React from 'react'; import {mount, shallow} from 'enzyme'; import {assert} from 'chai'; import FlatButton from './FlatButton'; import getMuiTheme from '../styles/getMuiTheme'; import ActionAndroid from '../svg-icons/action/android'; import mute from 'mute'; describe('<FlatButton />', () ...
submissions/leoasis/src/NavButton.js
winstonewert/flux-challenge
import React from 'react'; import classNames from 'classnames'; export default class NavButton extends React.Component { render() { const className = classNames( 'css-button-' + this.props.direction, this.props.disabled && 'css-button-disabled' ); return <button className={className} ...
src/index.js
iemharsh/Reduxtagram
// Set up your application entry point here... import React from 'react'; import { render } from 'react-dom'; import css from './styles/style.styl'; import { Provider} from 'react-redux'; import store, { history } from './store/index'; import App from './containers/App'; import Single from './containers/Single'; impor...
src/svg-icons/action/search.js
lawrence-yu/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionSearch = (props) => ( <SvgIcon {...props}> <path d="M15.5 14h-.79l-.28-.27C15.41 12.59 16 11.11 16 9.5 16 5.91 13.09 3 9.5 3S3 5.91 3 9.5 5.91 16 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 1...
src/svg-icons/maps/restaurant-menu.js
xmityaz/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let MapsRestaurantMenu = (props) => ( <SvgIcon {...props}> <path d="M8.1 13.34l2.83-2.83L3.91 3.5c-1.56 1.56-1.56 4.09 0 5.66l4.19 4.18zm6.78-1.81c1.53.71 3.68.21 5.27-1.38 1.91-1.91 2.28-4.65.81-6.12-1.46-1.46-4.2...
src/GridTile.js
kiloe/ui
import React from 'react'; import CSS from './utils/css'; import View from './View'; import ListItem from './ListItem'; CSS.register({ '.gridtile': { margin: '0', flexDirection: 'column', display: 'flex', flexGrow: '0', position: 'relative', }, '.gridtile.header': { flexDirection: 'colum...
src/components/input/checkbox/index.js
KleeGroup/focus-components
import PropTypes from 'prop-types'; import React, { Component } from 'react'; import ReactDOM from 'react-dom'; import Translation from '../../../behaviours/translation'; import Material from '../../../behaviours/material'; import filterProps from '../../../utils/filter-html-attributes'; const propTypes = { label:...
src/containers/AdminContainer.js
dggriffin/MPSOhhh
import React from 'react'; const Rebase = require('re-base'); const base = Rebase.createClass({ apiKey: 'AIzaSyBrgyl-UXdpEFISSGnf1isc_TkrVB2S0Hs', authDomain: 'mpsohhh.firebaseapp.com', databaseURL: 'https://mpsohhh.firebaseio.com', storageBucket: '' }); class AdminContainer extends Re...
shared/tests/components.spec.js
BitTigerInst/ElasticSearch
import expect from 'expect'; import TestUtils from 'react-addons-test-utils'; import PostListItem from '../components/PostListItem/PostListItem'; import PostCreateView from '../components/PostCreateView/PostCreateView'; import React from 'react'; import expectJSX from 'expect-jsx'; import { Link } from 'react-router'; ...
src/index.js
lomocc/react-boilerplate
import React from 'react'; import ReactDOM from 'react-dom'; import {Provider} from 'react-redux'; import {Router, match, browserHistory} from 'react-router'; import reaction from 'reaction'; import createStore from 'redux-create-store'; import routes from 'routes'; console.log('%c [%s] %s ', `background: ${process.en...
src/collections/Form/FormTextArea.js
vageeshb/Semantic-UI-React
import React from 'react' import { customPropTypes, getElementType, getUnhandledProps, META, } from '../../lib' import TextArea from '../../addons/TextArea' import FormField from './FormField' /** * Sugar for <Form.Field control={TextArea} /> * @see Form * @see TextArea */ function FormTextArea(props) { ...
src/components/redux.js
MoosemanStudios/app.moosecraft.us
// Component that demonstrates using a part of the Redux store // outside of Apollo. We can use config.addReducer(key, reducer) in `src/app.js` // to add custom Redux reducers // ---------------------- // IMPORTS /* NPM */ import React from 'react'; import PropTypes from 'prop-types'; // HOC/decorator to listen to ...
src/services/Http/Http.js
townmi/bis
/** * Created by townmi on 17/1/14. */ import React from 'react'; class Http { constructor () { this.XHR = new XMLHttpRequest(); this.options = { "method": null, "url": null, "aysnc": true, "timeout": 5000, "success": null, ...
app/components/main/NavBar.js
MarcinJarecki/React-js-Sticky-Notes
import React from 'react'; import {IndexLink} from 'react-router'; import _ from 'lodash'; import {navBarStyle} from '../../styles'; export default class NavBar extends React.Component { constructor() { super(); this.generateNavItem = this.generateNavItem.bind(this); this.handleNavItemActive = this.han...
doc/src/pages/examples/extend-graphics-developer.js
mapillary/mapillary-js
/** * Copyright (c) Facebook, Inc. and its affiliates. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * * @format */ import React from 'react'; import Layout from '@theme/Layout'; import {Code} from '../../js/components/Code'; import...
src/server.js
joaquingatica/git-demo
/** * React Starter Kit (https://www.reactstarterkit.com/) * * Copyright © 2014-present Kriasoft, LLC. All rights reserved. * * This source code is licensed under the MIT license found in the * LICENSE.txt file in the root directory of this source tree. */ import path from 'path'; import express from 'express';...
js/components/loaders/ProgressBar.android.js
ChiragHindocha/stay_fit
import React, { Component } from 'react'; import ProgressBar from 'ProgressBarAndroid'; export default class SpinnerNB extends Component { prepareRootProps() { const type = { height: 40, }; const defaultProps = { style: type, }; return computeProps(this.props, defaultProps); } ...
src/svg-icons/action/touch-app.js
pomerantsev/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionTouchApp = (props) => ( <SvgIcon {...props}> <path d="M9 11.24V7.5C9 6.12 10.12 5 11.5 5S14 6.12 14 7.5v3.74c1.21-.81 2-2.18 2-3.74C16 5.01 13.99 3 11.5 3S7 5.01 7 7.5c0 1.56.79 2.93 2 3.74zm9.84 4.63l-4....
docs/src/Routes.js
roadmanfong/react-bootstrap
import React from 'react'; import Root from './Root'; import HomePage from './HomePage'; import IntroductionPage from './IntroductionPage'; import GettingStartedPage from './GettingStartedPage'; import ComponentsPage from './ComponentsPage'; import SupportPage from './SupportPage'; import NotFoundPage from './NotFound...
docs/index.js
epotapov/react-fix
import { Link, Route, HashRouter } from 'react-router-dom'; import React from 'react'; import Fix, { Bounds, BoundedFix } from 'react-fix'; import ReactDOM from 'react-dom'; const Text = () => ( <div className='content'> <h3>Sample long content</h3> <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit....
docs/app/Examples/collections/Table/Variations/TableExampleVeryCompact.js
clemensw/stardust
import React from 'react' import { Table } from 'semantic-ui-react' const TableExampleVeryCompact = () => { return ( <Table compact='very'> <Table.Header> <Table.Row> <Table.HeaderCell>Name</Table.HeaderCell> <Table.HeaderCell>Status</Table.HeaderCell> <Table.HeaderCel...
docs/src/app/components/pages/discover-more/Community.js
hwo411/material-ui
import React from 'react'; import Title from 'react-title-component'; import MarkdownElement from '../../MarkdownElement'; import communityText from './community.md'; const Community = () => ( <div> <Title render={(previousTitle) => `Community - ${previousTitle}`} /> <MarkdownElement text={communityText} /> ...
js/components/pages/Print.react.js
wuyuanyi135/react-template
import React, { Component } from 'react'; class PrintPage extends Component { render() { return ( <div className="print-page"> <div className="print-title-container"> <div className="print-header">温州医科大学附属第一医院图书馆</div> <div className="prin...
src/sidebar/app/components/icons/ArrowLeftIcon.js
cedricium/notes
import React from 'react'; function ArrowLeftIcon(props) { return ( <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16"> <path fill="context-fill" d="M6.414 8l4.293-4.293a1 1 0 0 0-1.414-1.414l-5 5a1 1 0 0 0 0 1.414l5 5a1 1 0 0 0 1.414-1.414z"></path> </svg> ); } expor...
src/components/App/index.js
jiangxy/react-antd-admin
import React from 'react'; import {connect} from 'react-redux' import {Link} from 'react-router'; import {bindActionCreators} from 'redux' import {Spin, message, Tabs, Icon} from 'antd'; import Header from '../Header'; import Footer from '../Footer'; import Sidebar from '../Sidebar'; import Login from '../Login'; impor...
packages/bonde-admin-canary/src/components/Gadget/index.js
ourcities/rebu-client
import React from 'react' import PropTypes from 'prop-types' import { Flexbox2 as Flexbox, Title, Spacing } from 'bonde-styleguide' const GadgetTitle = ({ children }) => ( <Title.H5 uppercase fontWeight='bold'> {children} </Title.H5> ) const Gadget = ({ children, title, renderFilter, WrapperComponent }) => ( ...
src/js/app.js
nicksenger/JSchematic
import React from 'react'; import ReactDOM from 'react-dom'; import { Provider } from 'react-redux'; import { createStore, applyMiddleware } from 'redux'; import App from './components/app'; import reducers from './reducers'; const createStoreWithMiddleware = applyMiddleware()(createStore); ReactDOM.render...
front_end/skax/src/modal.js
julianpr/workflow-automation
import React from 'react' import { Button, Header, Image, Modal } from 'semantic-ui-react' const ModalModalExample = () => ( <Modal trigger={<Button>Show Modal</Button>}> <Modal.Header>Select a Photo</Modal.Header> <Modal.Content image> <Image wrapped size='medium' src='/assets/images/avatar/large/rach...
docs/app/Examples/collections/Grid/Types/GridExampleCelled.js
vageeshb/Semantic-UI-React
import React from 'react' import { Grid, Image } from 'semantic-ui-react' const GridExampleCelled = () => ( <Grid celled> <Grid.Row> <Grid.Column width={3}> <Image src='http://semantic-ui.com/images/wireframe/image.png' /> </Grid.Column> <Grid.Column width={13}> <Image src='http...
docs/app/Examples/elements/Icon/Variations/IconExampleFitted.js
ben174/Semantic-UI-React
import React from 'react' import { Icon } from 'semantic-ui-react' const IconExampleFitted = () => ( <div> <p>Tight spacing</p> <Icon fitted name='help' /> <p>Tight spacing</p> </div> ) export default IconExampleFitted
examples/src/custom-styles.js
madox2/react-tagcloud
import React from 'react' import { TagCloud } from 'react-tagcloud' const data = [ { value: 'jQuery', count: 25 }, { value: 'MongoDB', count: 18 }, { value: 'JavaScript', count: 38 }, { value: 'React', count: 30 }, { value: 'Nodejs', count: 28 }, { value: 'Express.js', count: 25 }, { value: 'HTML5', coun...
src/svg-icons/action/query-builder.js
pradel/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionQueryBuilder = (props) => ( <SvgIcon {...props}> <path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm.5...
components/connected/composer/input/emoji/table/index.js
marrus-sh/mastodon-go
// <ConnectedComposerInputEmojiTable> // ================================== // This simply renders a list of emoji in a table. // * * * * * * * // // Imports // ------- // Package imports. import classNames from 'classnames'; import PropTypes from 'prop-types'; import React from 'react'; // DOM imports. i...
packages/cf-builder-pagination/test/PaginationBuilder.js
mdno/mdno.github.io
import React from 'react'; import { mount } from 'enzyme'; import { PaginationBuilder } from '../../cf-builder-pagination/src/index'; import { createStub } from '../../cf-test-stub/src/index'; import { felaSnapshot } from 'cf-style-provider'; import { felaTestContext } from 'cf-style-provider'; test('should render pag...
src/components/cart/CartCheckOutComponent.js
bluebill1049/cart
'use strict'; import React from 'react'; import HeaderComponent from '../common/HeaderComponent.js'; import CartCheckOutListItemComponent from './cartCheckOut/CartCheckOutListItemComponent.js'; import CartCheckOutCtrlComponent from './cartCheckOut/CartCheckOutCtrlComponent.js'; import CartStore from '../CartStore.js';...
src/components/EyeIcon/EyeIcon.js
arnarleifs/ps-react-arnar
import React from 'react'; /** SVG Eye Icon */ function EyeIcon() { // Attribution: Fabián Alexis at https://commons.wikimedia.org/wiki/File:Antu_view-preview.svg return ( <svg width="16" height="16" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 22 22"> <g transform="matrix(.02146 0 0 .02146 1 1)" fill...
src/AffixMixin.js
xiaoking/react-bootstrap
import React from 'react'; import domUtils from './utils/domUtils'; import EventListener from './utils/EventListener'; const AffixMixin = { propTypes: { offset: React.PropTypes.number, offsetTop: React.PropTypes.number, offsetBottom: React.PropTypes.number }, getInitialState() { return { a...
components/GameSection.js
turntwogg/final-round
import React from 'react'; import { useTheme } from '@turntwo/react-ui'; export const GameSectionHeader = ({ children, ...rest }) => { const theme = useTheme(); return ( <div className="game-section__header" {...rest}> {children} <style jsx>{` .game-section__header { display: flex...
webapp/src/containers/layout/siteMap.js
alliance-genome/agr
import React, { Component } from 'react'; import { Link } from 'react-router'; import style from './style.css'; import SubMenu from './subMenu'; import { MENU, WP_PAGES ,WP_PATH ,WP_POST_PATH } from '../../constants'; class SiteMap extends Component { render() { let container=[]; for(var index in MENU){ ...
src/parser/mage/fire/CHANGELOG.js
FaideWW/WoWAnalyzer
import React from 'react'; import { Sharrq } from 'CONTRIBUTORS'; import SPELLS from 'common/SPELLS'; import SpellLink from 'common/SpellLink'; export default [ { date: new Date('2018-11-17'), changes: <>Updated the <SpellLink id={SPELLS.HEATING_UP.id} /> module to fix some incorrect values and to properly ...
app/pages/components/loader.js
ibjohansen/acando-react-boilerplate
'use strict'; import React from 'react'; export default React.createClass({ displayName: 'app/pages/components/loader.js', render() { return ( <div className="loader"></div> ) } });
routes/Statistic/components/Card/BorderTop.js
YongYuH/Ludo
import React from 'react'; import styled from 'styled-components'; const Wrapper = styled.div` background-color: #838383; border-bottom: 5px solid #838383; border-top: 5px solid #838383; color: white; font-size: 12px; font-weight: bold; padding: 5px 0; text-align: center; width: 100%; `; const Borde...
src/components/FooterBar/Responses/Button.js
welovekpop/uwave-web-welovekpop.club
import cx from 'classnames'; import React from 'react'; import PropTypes from 'prop-types'; import Tooltip from '@material-ui/core/Tooltip'; /* eslint-disable */ const Button = ({ onClick, disabled, count, children, tooltip, }) => ( // Wrapped in a <div> so the tooltip can listen for mouse events. <Toolt...
src/components/nav/Nav.js
lany9527/react-explore
/** * Created by littlestone on 2017/3/24. */ import React from 'react'; import {NavLink} from 'react-router-dom'; import './Nav.css'; const Nav = () => { return ( <nav className="nav"> <ul className="nav-list" data-flex="dir:left main:center box: mean"> <li className="nav-item" data-f...
src/components/Overview/Overview.react.js
DeveloperAlfa/chat.susi.ai
import './Overview.css'; import $ from 'jquery'; import allDevices from '../../images/all_devices.png'; import androidMockup from '../../images/android-mockup.jpg'; import bots from '../../images/bots.jpg'; import Close from 'material-ui/svg-icons/navigation/close'; import Footer from '../Footer/Footer.react'; import g...
src/routes/not-found/index.js
kuao775/mandragora
/** * React Starter Kit (https://www.reactstarterkit.com/) * * Copyright © 2014-present Kriasoft, LLC. All rights reserved. * * This source code is licensed under the MIT license found in the * LICENSE.txt file in the root directory of this source tree. */ import React from 'react'; import Layout from '../../co...
fields/types/name/NameField.js
udp/keystone
import Field from '../Field'; import React from 'react'; import { FormField, FormInput, FormRow } from 'elemental'; module.exports = Field.create({ displayName: 'NameField', focusTargetRef: 'first', valueChanged: function(which, event) { this.props.value[which] = event.target.value; this.props.onChange({ ...
test/containers/CounterPage.spec.js
dxu/cotimer
import { expect } from 'chai'; import React from 'react'; import { renderIntoDocument, scryRenderedDOMComponentsWithTag, findRenderedDOMComponentWithClass, Simulate } from 'react-addons-test-utils'; import { Provider } from 'react-redux'; import CounterPage from '../../app/containers/CounterPage'; import config...
scripts/utils/connectToStores.js
rigorojas/flux-react-router-example
import React, { Component } from 'react'; import shallowEqual from 'react-pure-render/shallowEqual'; /** * Exports a higher-order component that connects the component to stores. * This higher-order component is most easily used as an ES7 decorator. * Decorators are just a syntax sugar over wrapping class in a func...
src/components/listview.js
butterproject/butter-desktop
import React from 'react' import { TransitionGroup, CSSTransition } from 'react-transition-group' import {Navbar, Toolbar, Dropdowns} from 'butter-base-components' import {RouterMenu} from 'butter-component-menu' const {Dropdown} = Dropdowns import deepEqual from 'deep-equal' import ListContainer from '../container...
src/containers/DevTools/DevTools.js
huangc28/palestine-2
import React from 'react'; import { createDevTools } from 'redux-devtools'; import LogMonitor from 'redux-devtools-log-monitor'; import DockMonitor from 'redux-devtools-dock-monitor'; export default createDevTools( <DockMonitor toggleVisibilityKey="ctrl-H" changePositionKey="ctrl-Q"> <LogMonitor /...
demo/src/components/Footer/Footer.js
unsplash/react-trend
import React from 'react'; import './Footer.css'; const Footer = () => ( <footer className="footer"> Released under the <a href="https://github.com/unsplash/react-trend/blob/master/LICENSE.md">MIT</a> license. <a href="https://github.com/unsplash/react-trend">View source</a>. </footer> ); export default Foot...
docs/src/SupportPage.js
xsistens/react-bootstrap
import React from 'react'; import NavMain from './NavMain'; import PageHeader from './PageHeader'; import PageFooter from './PageFooter'; export default class Page extends React.Component { render() { return ( <div> <NavMain activePage="support" /> <PageHeader title="Nee...
src/app/component/form-row/form-row.story.js
all3dp/printing-engine-client
import React from 'react' import {storiesOf} from '@storybook/react' import FormRow from '.' const column = () => ( <div style={{ backgroundColor: '#fff' }} > column </div> ) storiesOf('FormRow', module) .add('default', () => <FormRow>{column()}</FormRow>) .add('layout: half-half', () => ...
packages/material-ui-icons/src/Filter1.js
AndriusBil/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from 'material-ui/SvgIcon'; let Filter1 = props => <SvgIcon {...props}> <path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm11 10h2V5h-4v2h2v8zm7-14H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14z" /> </...
test/specs/shape/RectangleSpec.js
recharts/recharts
import React from 'react'; import { expect } from 'chai'; import { Surface, Rectangle } from 'recharts'; import { mount, render } from 'enzyme'; describe('<Rectangle />', () => { it('Render 1 rectangle in simple Rectangle', () => { const wrapper = render( <Surface width={400} height={400}> <Rectang...
src/routes/blog/index.js
goldylucks/adamgoldman.me
import React from 'react' import Blog from './Blog' import Layout from '../../components/Layout' const title = 'Blog' function action({ path }) { return { chunks: ['blog'], title, path, description: 'A blog with my humble thoughts and diabolical schemes', component: ( <Layout path={path}...
app/components/Footer.js
rondobley/meal-planner
import React from 'react'; import { Link } from 'react-router'; class Footer extends React.Component { render() { return ( <footer> <div className='container'> <div className='row'> <div className='col-sm-12'> ...
definitions/npm/react-body-classname_v1.x.x/flow_v0.53.x-/react-body-classname_v1.x.x.js
mkscrg/flow-typed
import React from 'react'; declare module 'react-body-classname' { declare type Props = { children?: React.ChildrenArray<any>, className: string, }; declare class BodyClassName extends React$Component<Props> { static rewind(): string; } declare var exports: typeof BodyClassName; }
app/containers/ContestsPage/index.js
zmora-agh/zmora-ui
import React from 'react'; import { connect } from 'react-redux'; import { FormattedMessage } from 'react-intl'; import { gql, graphql } from 'react-apollo'; import autobind from 'autobind-decorator'; import { ContestsTable } from '../../components/ContestsTable'; import EmptyMessage from '../../components/EmptyMessag...
app/javascript/mastodon/components/avatar_overlay.js
imas/mastodon
import React from 'react'; import PropTypes from 'prop-types'; import ImmutablePropTypes from 'react-immutable-proptypes'; import { autoPlayGif } from '../initial_state'; export default class AvatarOverlay extends React.PureComponent { static propTypes = { account: ImmutablePropTypes.map.isRequired, friend:...
src/svg-icons/action/highlight-off.js
tan-jerene/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionHighlightOff = (props) => ( <SvgIcon {...props}> <path d="M14.59 8L12 10.59 9.41 8 8 9.41 10.59 12 8 14.59 9.41 16 12 13.41 14.59 16 16 14.59 13.41 12 16 9.41 14.59 8zM12 2C6.47 2 2 6.47 2 12s4.47 10 10 1...
src/svg-icons/hardware/keyboard-capslock.js
tan-jerene/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let HardwareKeyboardCapslock = (props) => ( <SvgIcon {...props}> <path d="M12 8.41L16.59 13 18 11.59l-6-6-6 6L7.41 13 12 8.41zM6 18h12v-2H6v2z"/> </SvgIcon> ); HardwareKeyboardCapslock = pure(HardwareKeyboardCaps...
benchmarks/src/implementations/css-modules/Box.js
rofrischmann/fela
/* eslint-disable react/prop-types */ import classnames from 'classnames'; import React from 'react'; import View from './View'; import styles from './box-styles.css'; const Box = ({ color, fixed = false, layout = 'column', outer = false, ...other }) => ( <View {...other} className={classnames(styles[`color$...
src/cms/preview-templates/AboutPagePreview.js
hunterclarke/hunterclarke.me
import React from 'react' import PropTypes from 'prop-types' import { AboutPageTemplate } from '../../templates/about-page' const AboutPagePreview = ({ entry, widgetFor }) => ( <AboutPageTemplate title={entry.getIn(['data', 'title'])} content={widgetFor('body')} /> ) AboutPagePreview.propTypes = { entry...
src/components/loading-indicators/loading-modal.component.js
housseindjirdeh/git-point
import React from 'react'; import { StyleSheet, View, Modal, ActivityIndicator } from 'react-native'; const styles = StyleSheet.create({ container: { flex: 1, position: 'absolute', top: 0, left: 0, right: 0, bottom: 0, backgroundColor: 'rgba(0, 0, 0, 0.8)', justifyContent: 'center', ...
docs/src/pages/components/app-bar/PrimarySearchAppBar.js
lgollut/material-ui
import React from 'react'; import { alpha, makeStyles } from '@material-ui/core/styles'; import AppBar from '@material-ui/core/AppBar'; import Toolbar from '@material-ui/core/Toolbar'; import IconButton from '@material-ui/core/IconButton'; import Typography from '@material-ui/core/Typography'; import InputBase from '@m...
src/PersonItem2/index.js
christianalfoni/ducky-components
import React from 'react'; import PropTypes from 'prop-types'; import Typography from '../Typography'; import classNames from 'classnames'; import styles from './styles.css'; import Wrapper from '../Wrapper'; import PersonItem1 from '../PersonItem1'; function PersonItem2(props) { let opt = ''; opt = ( <T...
test/client/components/App.spec.js
toomastahves/react-gulp-starter
import React from 'react'; import TestUtils from 'react-addons-test-utils'; import { expect } from 'chai'; import { App } from 'client/components/App'; import Hello from 'client/components/Hello'; const setup = () => { const renderer = TestUtils.createRenderer(); renderer.render(<App />); const output = renderer...
src/routes.js
aleksa95/universal-redux-boilerplate
/* eslint react/jsx-filename-extension: 0 */ import React from 'react'; import cookie from 'react-cookie'; import { IndexRoute, Route } from 'react-router'; import { App, Homepage, NotFound, Login, SignUp, Dashboard, EnsureAuthentication } from './containers'; import { checkAuth as _checkAuth } from './actions/auth-act...
src/components/common/FileInfo.js
redux-autoform/redux-autoform-material-ui
import React from 'react'; import filesize from 'filesize'; import PropTypes from 'prop-types'; import Dialog from 'material-ui/Dialog/Dialog'; import { cyan500 } from 'material-ui/styles/colors'; import FontIcon from 'material-ui/FontIcon/FontIcon'; import FlatButton from 'material-ui/FlatButton/FlatButton'; export d...
app/javascript/mastodon/features/status/components/detailed_status.js
rutan/mastodon
import React from 'react'; import PropTypes from 'prop-types'; import ImmutablePropTypes from 'react-immutable-proptypes'; import Avatar from '../../../components/avatar'; import DisplayName from '../../../components/display_name'; import StatusContent from '../../../components/status_content'; import MediaGallery from...
src/components/Calculator/CalculatorInput.js
Batname/Yeoman_react_tests
import React from 'react'; // import _ from 'lodash'; import CalculatorButton from './CalculatorButton'; // class CalculatorActions{ // constructor(elem){ // _.assign(this, elem); // this.elem = elem; // } // addEventListener(){ // this.elem.addEventListener('click', this.handleClick.bind(this)); // ...
src/svg-icons/content/flag.js
xmityaz/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ContentFlag = (props) => ( <SvgIcon {...props}> <path d="M14.4 6L14 4H5v17h2v-7h5.6l.4 2h7V6z"/> </SvgIcon> ); ContentFlag = pure(ContentFlag); ContentFlag.displayName = 'ContentFlag'; ContentFlag.muiName = '...
src/components/ScrollView.js
omeid/react-native-mock
import React from 'react'; import EdgeInsetsPropType from '../propTypes/EdgeInsetsPropType'; import PointPropType from '../propTypes/PointPropType'; import ScrollResponder from '../mixins/ScrollResponder'; import View from './View'; import ViewStylePropTypes from '../propTypes/ViewStylePropTypes'; import ScrollViewMana...
app/pages/admin/Info/index.js
czy0729/react-alumni
/** * 校友录基本信息 * @Date: 2017-01-27 15:58:37 * @Last Modified by: Administrator * @Last Modified time: 2017-03-21 05:43:30 */ 'use strict'; import React from 'react'; import { form, observer } from 'decorators'; import { $alumni } from 'stores'; import { Button } from 'antd-mobile'; import { Spin, ButtonWrap, App...
src/components/OverlayBookmarkIllustButton.js
alphasp/pxview
/* eslint-disable camelcase */ import React from 'react'; import { View, StyleSheet, Text } from 'react-native'; import BookmarkIllustButton from './BookmarkIllustButton'; const styles = StyleSheet.create({ container: { backgroundColor: 'rgba(0,0,0,0.6)', bottom: 0, right: 0, position: 'absolute', ...
modules/State.js
gdi2290/react-router
import React from 'react'; var { object } = React.PropTypes; /** * A mixin for components that need to know the path, routes, URL * params and query that are currently active. * * Example: * * import { State } from 'react-router'; * * var AboutLink = React.createClass({ * mixins: [ State ], * re...
Gryffindor/app/containers/Nav.js
Acheron-VAF/Acheron
import React, { Component } from 'react'; import Radium, { Style } from 'radium'; import {StyleRoot} from 'radium'; import { ipcRenderer } from "electron"; import Search from '../components/Search'; class Nav extends Component { constructor(props) { super(props); this.state = {}; } getStyles(...
zoho-experiments/internals/templates/containers/App/index.js
glandre/prototypes
/** * * App.js * * This component is the skeleton around the actual pages, and should only * contain code that should be seen on all pages. (e.g. navigation bar) * * NOTE: while this component should technically be a stateless functional * component (SFC), hot reloading does not currently support SFCs. If hot ...
src/components/colorChoser.js
EncontrAR/backoffice
import React, { Component } from 'react'; import Button from './uielements/button'; import Popover from './uielements/popover'; import '../style/colorChooser.less'; export default class ColorChoser extends Component { constructor(props) { super(props); this.handleVisibleChange = this.handleVisibleChange.bind...