path
stringlengths
5
195
repo_name
stringlengths
5
79
content
stringlengths
25
1.01M
Examples/UIExplorer/js/ActivityIndicatorExample.js
charlesvinette/react-native
/** * Copyright (c) 2013-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. * * The examp...
src/svg-icons/av/recent-actors.js
mmrtnz/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let AvRecentActors = (props) => ( <SvgIcon {...props}> <path d="M21 5v14h2V5h-2zm-4 14h2V5h-2v14zM14 5H2c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h12c.55 0 1-.45 1-1V6c0-.55-.45-1-1-1zM8 7.75c1.24 0 2.25 1.01 2.25 2.25S9....
blueocean-material-icons/src/js/components/svg-icons/action/update.js
kzantow/blueocean-plugin
import React from 'react'; import SvgIcon from '../../SvgIcon'; const ActionUpdate = (props) => ( <SvgIcon {...props}> <path d="M21 10.12h-6.78l2.74-2.82c-2.73-2.7-7.15-2.8-9.88-.1-2.73 2.71-2.73 7.08 0 9.79 2.73 2.71 7.15 2.71 9.88 0C18.32 15.65 19 14.08 19 12.1h2c0 1.98-.88 4.55-2.64 6.29-3.51 3.48-9.21 3.48-1...
src/docs/examples/Label/ExampleOptional.js
alexcondorachi/ps-react-alexc
import React from 'react'; import Label from 'ps-react/Label'; /** Optional label */ export default function ExampleOptional() { return <Label htmlFor="test" label="test" /> }
src/components/icons/GiftCard.js
OpenCollective/frontend
import React from 'react'; import { lighten } from 'polished'; import CustomStyledIcon from './CustomStyledIcon'; const GiftCard = props => { const gradientID = `gradient-${props.color.replace('#', '')}`; return ( <CustomStyledIcon width={props.size || '26'} height={props.size || '18'} viewBo...
src/components/section/index.js
adrienlozano/stephaniewebsite
import React from 'react'; import styled from 'styled-components'; import { color, width, space, removeProps } from 'styled-system'; import { defaultProps, compose, setDisplayName } from 'recompose'; const Section = ({children, className, ...props}) => { var next = removeProps(props); return ( <div classNa...
src/components/Character/Pool.js
ryanabragg/VanguardLARP
import React from 'react'; import PropTypes from 'prop-types'; import Ability from './styled/Ability'; class Pool extends React.Component { constructor(props) { super(props); } render() { const rest = Object.assign({}, this.props); delete rest.id; delete rest.name; delete rest.category; ...
app/main.js
allecsro/dynotool
import React from 'react'; import ReactDOM from 'react-dom'; import { Provider } from 'react-redux'; import { AppContainer } from 'react-hot-loader'; import createStore from './store/createStore'; import Root from './config/Root'; // ======================================================== // Store and History Instan...
src/svg-icons/notification/system-update.js
manchesergit/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let NotificationSystemUpdate = (props) => ( <SvgIcon {...props}> <path d="M17 1.01L7 1c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14zm-1-6h-3V8h-2v5H8l4 4 4-4z"/> </Sv...
lib/ui/src/modules/ui/components/left_panel/index.js
shilman/storybook
import PropTypes from 'prop-types'; import React from 'react'; import Header from './header'; import Stories from './stories'; import TextFilter from './text_filter'; import pick from 'lodash.pick'; const scrollStyle = { height: 'calc(100vh - 105px)', marginTop: 10, overflowY: 'auto', }; const mainStyle = { p...
src/components/video_list_item.js
aloaiza/ReduxSimpleStarter
import React from 'react'; const VideoListItem = ({video, onVideoSelect}) => { // const video = props.video; // This is the same as doing {video} in constructor // console.log(video); const imageUrl = video.snippet.thumbnails.default.url; return ( <li onClick={()=>onVideoSelect(video)} classNa...
src/components/optimizely.js
mozilla/advocacy.mozilla.org
import React from 'react'; var optimizelyActive = process.env.OPTIMIZELY_ACTIVE || 'yes'; var optimizelyID = process.env.OPTIMIZELY_ID || '206878104'; var optimizelyURL = 'https://cdn.optimizely.com/js/' + optimizelyID + '.js'; module.exports = React.createClass({ render: function() { if (optimizelyActive === '...
examples/universal/client/index.js
lifeiscontent/redux
import 'babel-polyfill' import React from 'react' import { render } from 'react-dom' import { Provider } from 'react-redux' import configureStore from '../common/store/configureStore' import App from '../common/containers/App' const preloadedState = window.__PRELOADED_STATE__ const store = configureStore(preloadedStat...
src/svg-icons/hardware/device-hub.js
frnk94/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let HardwareDeviceHub = (props) => ( <SvgIcon {...props}> <path d="M17 16l-4-4V8.82C14.16 8.4 15 7.3 15 6c0-1.66-1.34-3-3-3S9 4.34 9 6c0 1.3.84 2.4 2 2.82V12l-4 4H3v5h5v-3.05l4-4.2 4 4.2V21h5v-5h-4z"/> </SvgIcon>...
app/containers/HomePage.js
opensprints/opensprints-electron
import React, { Component } from 'react'; import Home from '../components/Home'; export default class HomePage extends Component { render() { return ( <Home /> ); } }
node_modules/react-router/es6/IndexRoute.js
rekyyang/ArtificalLiverCloud
'use strict'; import React from 'react'; import warning from './routerWarning'; import invariant from 'invariant'; import { createRouteFromReactElement as _createRouteFromReactElement } from './RouteUtils'; import { component, components, falsy } from './InternalPropTypes'; var func = React.PropTypes.func; /** * An...
app/main.js
xiaoyaomaopp/BigData-WebArt
import React from 'react'; import ReactDOM from 'react-dom'; import routes from './routes'; ReactDOM.render(routes,document.getElementById('app'));
blog/src/index.js
unhommequidort/react_redux
import React from 'react'; import ReactDOM from 'react-dom'; import { Provider } from 'react-redux'; import { createStore, applyMiddleware } from 'redux'; import { Router, browserHistory } from 'react-router'; import reducers from './reducers'; import routes from './routes'; import promise from 'redux-promise'; const ...
packages/@vega/review-tool/src/components/ReviewProcess.js
VegaPublish/vega-studio
// @flow import React from 'react' import styles from './styles/ReviewProcess.css' import withPropsStream from '@vega/utils/withPropsStream' import ArticleSnapshot from './ArticleSnapshot' import {tap, map, switchMap, distinctUntilChanged} from 'rxjs/operators' import {combineLatest} from 'rxjs' import {debounce} from ...
Example/App.js
kyo504/react-native-sample-module
/** * Sample React Native App * https://github.com/facebook/react-native * @flow */ import React, { Component } from 'react'; import { StyleSheet, Text, View, Button, DeviceEventEmitter, Slider, } from 'react-native'; import Player from 'react-native-sample-module'; export default class Example extend...
demo/src/index.js
stowball/react-accessible-tabs
import React from 'react'; import { render } from 'react-dom'; import Tabs from '../../src'; var tabContent = [ { label: 'Section 1', content: ` <h3>Section 1</h3> <p>Duis sagittis, est sit amet gravida tristique, purus lectus venenatis urna, id molestie magna risus ut nunc...
src/app/components/RecorderControls.js
DmitryKorlas/js-test-recorder
import React from 'react'; import {Grid, Row, Col} from 'react-flexbox-grid/lib/index'; import {Button} from './Button'; import {Icon} from './Icon'; import classnames from 'classnames'; import style from './RecorderControls.pcss'; export class RecorderControls extends React.Component { static propTypes = { ...
app/components/Calendar.js
kassyn/me
import React from 'react'; import DatePicker from 'react-datepicker'; import moment from 'moment'; import '../stylesheets/components/calendar.scss'; class Calendar extends React.Component { render() { return ( <div> <DatePicker inline selected={moment('2016-09-30')} locale='pt-br' /> </...
src/DatePicker/DatePicker.js
pradel/material-ui
import React from 'react'; import {formatIso, isEqualDate} from './dateUtils'; import DatePickerDialog from './DatePickerDialog'; import TextField from '../TextField'; import deprecated from '../utils/deprecatedPropType'; class DatePicker extends React.Component { static propTypes = { /** * Constructor for ...
src/layouts/CoreLayout/CoreLayout.js
kesslern/ascient-react
import React from 'react' import PropTypes from 'prop-types' import Header from '../../components/Header' import './CoreLayout.scss' import '../../styles/core.scss' export const CoreLayout = ({ children, location }) => ( <div id='main-container'> <Header active={location.pathname} /> <section id='main-conte...
packages/react-scripts/fixtures/kitchensink/src/features/syntax/TemplateInterpolation.js
picter/create-react-app
/** * Copyright (c) 2015-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ import React, { Component } from 'react'; import PropTypes from 'prop-types'; function load(name) { return [ { id: 1, name: `${na...
packages/node_modules/@webex/react-component-day-separator/src/calculateDateText.js
adamweeks/react-ciscospark-1
import React from 'react'; import moment from 'moment'; import { FormattedDate, FormattedMessage } from 'react-intl'; export default function calculateDateText(fromDate, now, toDate) { let text; // toDate and fromDate aren't in the same year OR // toDate is not in current year, then show year. const sameYe...
src/components/ColumnSort/index.js
DataSF/open-data-explorer
import './@ColumnSort.css' import React from 'react' import PropTypes from 'prop-types' import { ControlLabel, FormControl } from 'react-bootstrap' const ColumnSort = ({onSort, sort}) => { const handleOnSelect = (e) => { onSort(e.target.value) } return (<div className='ColumnSort-container'> <ControlLa...
jenkins-design-language/src/js/components/material-ui/svg-icons/editor/border-bottom.js
alvarolobato/blueocean-plugin
import React from 'react'; import SvgIcon from '../../SvgIcon'; const EditorBorderBottom = (props) => ( <SvgIcon {...props}> <path d="M9 11H7v2h2v-2zm4 4h-2v2h2v-2zM9 3H7v2h2V3zm4 8h-2v2h2v-2zM5 3H3v2h2V3zm8 4h-2v2h2V7zm4 4h-2v2h2v-2zm-4-8h-2v2h2V3zm4 0h-2v2h2V3zm2 10h2v-2h-2v2zm0 4h2v-2h-2v2zM5 7H3v2h2V7zm14-4v...
public/app/components/home/welcome-info-entry.js
feedm3/unhypem
/** * @author Fabian Dietenberger */ 'use strict'; import React from 'react'; import InfoEntry from './info-entry'; export default class WelcomeEntry extends React.Component { constructor(props) { super(props); } render() { const body = <div>The charts are based on the <a className='no...
src/client/components/pages/parts/editor-achievements.js
bookbrainz/bookbrainz-site
/* * Copyright (C) 2016 Daniel Hsing * 2016 Max Prettyjohns * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later versi...
frontend/App/Admin.js
shoumma/ReForum
import React, { Component } from 'react'; import { Link, browserHistory } from 'react-router'; import { connect } from 'react-redux'; import { Helmet } from 'react-helmet'; import { getUser } from './actions'; import AdminHeader from 'Containers/AdminHeader'; import appLayout from 'SharedStyles/appLayout.css'; import...
scripts/Chat/WriteToSeller.js
krulmacius/sdasdasdasfgasdawsdwadawd
import React from 'react'; import axios from 'axios'; const base_url = "http://" + window.location.href.split("/")[2]; class WriteToSeller extends React.Component { constructor(props) { super(props); this.state = { seller: [] } this.handleClick = this.handleClick.bi...
src/main.js
poshaughnessy/es6-react-starter-template
import React from 'react'; import Placeholder from './components/placeholder'; React.render( React.createElement( Placeholder, {history: true} ), document.getElementById('app') );
node_modules/antd/es/input/TextArea.js
yhx0634/foodshopfront
import _extends from 'babel-runtime/helpers/extends'; import _defineProperty from 'babel-runtime/helpers/defineProperty'; import _classCallCheck from 'babel-runtime/helpers/classCallCheck'; import _createClass from 'babel-runtime/helpers/createClass'; import _possibleConstructorReturn from 'babel-runtime/helpers/possib...
src/client/client.js
dherault/Playlister
import React from 'react'; import { render } from 'react-dom'; import createApp from '../shared/createApp'; import registerSideEffects from './registerSideEffects'; import registerShortcuts from './registerShortcuts'; import registerWebsocket from './registerWebsocket'; import { logStart, log } from '../shared/utils/l...
03-HelloWorldWithState/src/index.js
s-buss/ReactIntro
import React from 'react'; import ReactDOM from 'react-dom'; import './index.css'; import './HelloWorld.css'; class HelloWorld extends React.Component { constructor(props) { super(props); this.state = { isHovered: false, dummy: 17 }; } handleMouseEnter() { this.setState({ isHove...
stories/Notification/index.js
nirhart/wix-style-react
import React from 'react'; import {storiesOf} from '@kadira/storybook'; import InteractiveCodeExample from '../utils/Components/InteractiveCodeExample'; import Markdown from '../utils/Components/Markdown'; import Readme from '../../src/Notification/README.md'; import ExampleStandard from './ExampleStandard'; storiesO...
src/app/core/create-routes.js
jl-/bronote
import React from 'react'; import Route from 'react-router/lib/Route'; import IndexRoute from 'react-router/lib/IndexRoute'; import App from '../app'; import Main from '../main'; export default function({ dispatch, getState }) { const routes = ( <Route path='/' component={App}> <Route path='main' componen...
test/unit/theme/primary-nav-test.js
travi/admin.travi.org-components
import {string, url, listOf} from '@travi/any'; import React from 'react'; import dom from 'react-dom/server'; import cheerio from 'cheerio'; import {assert} from 'chai'; import HistoryWrapper from '../../helpers/history-wrapper'; import {PrimaryNav} from '../../../src/main'; suite('primary navigation', () => { te...
react-advanced-boilerplate/app/pages/Home.js
rwachtler/react-twitstats
import React from 'react'; import {shouldPureComponentUpdate} from 'react-pure-render'; import {connect} from 'react-redux'; import getAuthToken from '../actions/getAuthToken'; import Button from '../components/Button'; import cookie from 'react-cookie'; class Home extends React.Component { shouldComponentUpdate =...
src/components/BooksDashboard/BooksDashboard.js
sbalay/reacting
import React, { Component } from 'react'; import BooksDashboardFilters from '../BooksDashboardFilters/BooksDashboardFilters'; import BookDetail from '../BookDetail/BookDetail'; export default class BooksDashboard extends Component { constructor (props) { super(props); this.state = { books: [ ...
src/components/widget/Image.js
metasfresh/metasfresh-webui-frontend
import counterpart from 'counterpart'; import React, { Component } from 'react'; import PropTypes from 'prop-types'; import { getImageAction, postImageAction } from '../../actions/AppActions'; import Loader from '../app/Loader'; /** * @file Function based component. * @module Placeholder * @param {object} props *...
src/util/render-element.js
nkohari/tutorial-navigator
import React from 'react'; import ReactDOM from 'react-dom'; import NavigatorAndTutorialView from '../view/navigator-and-tutorial-view'; export default function renderElement(mountPoint, options) { ReactDOM.render( React.createElement(NavigatorAndTutorialView, options), mountPoint ); }
examples/_nesting-sources/Target.js
prometheusresearch/react-dnd
'use strict'; import React from 'react'; import Colors from './Colors'; import { DragDropMixin } from 'react-dnd'; function makeDropTarget(color) { return { acceptDrop(component) { component.setState({ lastDroppedColor: color }); } }; } const style = { border: '1px dashed gray', h...
shared/components/SubComponents/Question/Checkbox.js
KCPSoftware/KCPS-React-Starterkit
import React, { Component } from 'react'; import { connect } from 'react-redux'; import { saveQuestion } from '../../../actions/questionActions'; import Validation from '../../../utils/validation/Validation'; import InputValidation from '../../../utils/validation/InputValidation'; @connect(store => ({})) class Checkbo...
packages/reactor-kitchensink/src/examples/Charts/Pie/BasicPie/BasicPie.js
markbrocato/extjs-reactor
import React, { Component } from 'react'; import { Container } from '@extjs/ext-react'; import { Polar } from '@extjs/ext-react-charts'; import createData from './createData'; import ChartToolbar from '../../ChartToolbar'; Ext.require([ 'Ext.chart.series.Pie' ]); export default class BasicPieChartExample extends ...
src/icons/BorderInnerIcon.js
kiloe/ui
import React from 'react'; import Icon from '../Icon'; export default class BorderInnerIcon extends Icon { getSVG(){return <svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" viewBox="0 0 48 48"><path d="M6 42h4v-4H6v4zm8 0h4v-4h-4v4zm-4-28H6v4h4v-4zM6 34h4v-4H6v4zM18 6h-4v4h4V6zm-8 0H6v4h4V6zm24 0h-4v4h4...
src/components/nav/Header.js
brancusi/lingo-client-react
import React from 'react'; import Radium from 'radium'; import { Link } from 'react-router'; import LoginUI from 'components/nav/LoginUI'; @Radium export default class Header extends React.Component { static propTypes = { login: React.PropTypes.func.isRequired, logout: React.PropTypes.func.isRequired, au...
exercise-06-solution/src/components/AddPokemonCard.js
learnapollo/pokedex-react
import React from 'react' import { withRouter } from 'react-router' import { graphql } from 'react-apollo' import gql from 'graphql-tag' import styled from 'styled-components' const Button = styled.div` background-color: ${props => props.save ? '#2BC3A1' : ''}; color: ${props => props.save ? 'white' : '#A3A3A3'}; ...
templates/rubix/demo/src/routes/StaticTimeline.js
jeffthemaximum/Teachers-Dont-Pay-Jeff
import React from 'react'; import { Row, Col, Panel, PanelBody, LoremIpsum, TimelineBody, TimelineIcon, TimelineView, TimelineItem, TimelineTitle, TimelineHeader, PanelContainer, } from '@sketchpixy/rubix'; export default class StaticTimeline extends React.Component { render() { return (...
src/components/pages/Products/ProductPage.js
ESTEBANMURUZABAL/bananaStore
/** * Imports */ import React from 'react'; import async from 'async'; import connectToStores from 'fluxible-addons-react/connectToStores'; import {FormattedMessage, FormattedNumber} from 'react-intl'; import {slugify} from '../../../utils/strings'; // Flux import CartStore from '../../../stores/Cart/CartStore'; im...
client/extensions/woocommerce/woocommerce-services/views/service-settings/settings-form/settings-item.js
Automattic/woocommerce-services
/** @format */ /** * External dependencies */ import React from 'react'; import PropTypes from 'prop-types'; import { localize } from 'i18n-calypso'; /** * Internal dependencies */ import NumberField from 'woocommerce/woocommerce-services/components/number-field'; import Text from 'woocommerce/woocommerce-service...
curator-web/src/js/components/common/description.js
rajeshnaroth/curator
import React from 'react' const Description = ({text}) => <p>{text.substr(0, 300)}</p> export default Description
src/index.js
dreamware-io/react-phone-input
// TODO - fix the onlyContries props. Currently expects that as an array of country object, but users should be able to send in array of country isos import { trim, startsWith } from './utils.js'; import _ from 'underscore'; import React from 'react'; import countryData from './country_data.js'; import classNames from...
src/common/components/Authentications/SignInWindow.js
jspsych/jsPsych-Redux-GUI
import React from 'react'; import { connect } from 'react-redux'; import TextField from 'material-ui/TextField'; import Paper from 'material-ui/Paper'; import RaisedButton from 'material-ui/RaisedButton'; import CircularProgress from 'material-ui/CircularProgress'; import FlatButton from 'material-ui/FlatButton'; con...
src/components/withViewport.js
Futurealms/noDelay.co
/** * React Starter Kit (https://www.reactstarterkit.com/) * * Copyright © 2014-2016 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, { Component } from 'react'; // eslint-disabl...
admin/client/App/shared/AlertMessages.js
Yaska/keystone
import React from 'react'; import { Alert } from 'elemental'; import { upcase } from '../../utils/string'; /** * This renders alerts for API success and error responses. * Error format: { * error: 'validation errors' // The unique error type identifier * detail: { ... } // Optional details specific to t...
packages/cli/template/src-react/HelloWorld/HelloWorld.js
daniloster/react-experiments
import React from 'react'; import PropTypes from 'prop-types'; import styles from './HelloWorld.scss'; const HelloWorld = (props) => { const { children, } = props; return ( <div className={styles.helloWorld} >{children}</div> ); }; HelloWorld.propTypes = { children: PropTypes.string.isRequ...
lib/site/topic-layout/topic-article/comments/list/comment/footer/component.js
democracy-os-fr/democracyos
import React from 'react' import t from 't-component' export default function CommentFooter (props) { return ( <footer className='actions'> <div className='votes'> <span className='score'> <span>{props.score}</span> {' '} </span> {!props.isOwner && ( <b...
src/components/Layout/Header.js
fishmankkk/mircowater2.0
import React from 'react' import PropTypes from 'prop-types' import { Menu, Icon, Popover } from 'antd' import classnames from 'classnames' import styles from './Header.less' import Menus from './Menu' const SubMenu = Menu.SubMenu const Header = ({ user, logout, switchSider, siderFold, isNavbar, menuPopoverVisible, l...
src/components/ShiftListView.js
kosmologist/andromeda-web
import React from 'react' import ShiftItem from "./ShiftItem"; import {store} from "../store/DataStore"; import {SnackbarProvider} from "notistack"; import ListItem from "@material-ui/core/es/ListItem/ListItem"; import Divider from "@material-ui/core/es/Divider/Divider"; import {List, Paper, IconButton, ListItemSeconda...
src/Layout/Footer.js
kondoSoft/react-car-rental
import React, { Component } from 'react'; import { Icon, Grid, Container,Divider } from 'semantic-ui-react' class Footer extends Component { render() { return ( <footer> <Container> <Grid> <Grid.Row> <Grid.Column mobile={16} tablet={16} computer={3}> ...
src/GridList/GridList.js
rscnt/material-ui
import React from 'react'; function getStyles(props) { return { root: { display: 'flex', flexWrap: 'wrap', margin: -props.padding / 2, }, item: { boxSizing: 'border-box', padding: props.padding / 2, }, }; } class GridList extends React.Component { static propTypes =...
src/entypo/MailWithCircle.js
cox-auto-kc/react-entypo
import React from 'react'; import EntypoIcon from '../EntypoIcon'; const iconClass = 'entypo-svgicon entypo--MailWithCircle'; let EntypoMailWithCircle = (props) => ( <EntypoIcon propClass={iconClass} {...props}> <path d="M10,0.3999634c-5.3019409,0-9.5999756,4.2980957-9.5999756,9.6000366S4.6980591,19.59997...
lib/codemod/src/transforms/__testfixtures__/storiesof-to-csf/parameters-as-var.input.js
storybooks/react-storybook
/* eslint-disable import/no-extraneous-dependencies */ import React from 'react'; import { storiesOf } from '@storybook/react'; import Canvas from './Canvas'; const CHROMATIC_DELAY = { chromatic: { delay: 500 } }; storiesOf('Canvas', module).add('loading', () => <Canvas loading />, CHROMATIC_DELAY);
frontend/src/components/guild_overview.js
aliasfalse/rowboat
import React, { Component } from 'react'; import {globalState} from '../state'; import {withRouter} from 'react-router'; import GuildIcon from './guild_icon' class GuildWidget extends Component { render() { const source = `https://discordapp.com/api/guilds/${this.props.guildID}/widget.png?style=banner2`; ret...
web/src/components/Header.js
jhonfredynova/Scaffolding-Nodejs-Reactjs
import React, { Component } from 'react'; import { Link } from 'react-router'; import { Navbar, Nav, NavDropdown, MenuItem, NavItem, FormGroup, FormControl } from 'react-bootstrap'; import { LinkContainer } from 'react-router-bootstrap'; import { FormattedMessage } from 'react-intl'; import logo from './../media/tuplac...
html/app.js
hasanali2/schoolms
import { flux } from './flux' /*importing react and react-router*/ import React from 'react'; import { render } from 'react-dom' import { Router, useRouterHistory } from 'react-router' import { createHashHistory } from 'history'; /*importing routes*/ import routes from './components/routes'; // useRouterHistory cr...
node_modules/bs-recipes/recipes/webpack.react-hot-loader/app/js/main.js
Jbeagle/writeItEasy2.0
import React from 'react'; import { render } from 'react-dom'; // It's important to not define HelloWorld component right in this file // because in that case it will do full page reload on change import HelloWorld from './HelloWorld.jsx'; render(<HelloWorld />, document.getElementById('react-root'));
wrappers/yaml.js
orleans-tech/orleans-tech.com
import React from 'react' import yaml from 'js-yaml' import DocumentTitle from 'react-document-title' import { config } from 'config' module.exports = React.createClass({ propTypes () { return { route: React.PropTypes.object, } }, render () { const data = this.props.route.page.data return (...
app/components/Package/PackageActivity.js
alexindigo/ndash
import React, { Component } from 'react'; import { } from 'react-native'; import { prettifyNumber } from '../../helpers/text'; import ContentBlock from '../ContentBlock'; import NamedBlock from '../NamedBlock'; import LabeledText from '../LabeledText'; import Drawers from '../Drawers'; import styles from '../../styl...
client/visual/primitives.js
quarterto/almanac
import React from 'react' import styled, { css } from 'styled-components' import colours from '@quarterto/colours' import contrast from 'contrast' export const background = ({ colour = 'sky', shade = 3 }) => { const bg = colours[colour][shade] return css` background: ${bg}; color: ${contrast(bg) === 'dark' ? 'w...
demos/react-redux/todo/components/TodoList.react.js
andrewimm/parse-lite
import React from 'react'; import TodoCreator from './TodoCreator.react'; import TodoItem from './TodoItem.react'; export default class TodoList extends React.Component { constructor(props) { super(props); this.refresh = this.refresh.bind(this); } componentWillMount() { this.props.fetch(); } r...
app/index.js
charlesjandulio/c-j
import React from 'react' import ReactDOM from 'react-dom' import routes from './config/routes' ReactDOM.render(routes, document.getElementById('app'))
src/components/layout/index.js
yyjazsf/react-study
import React from 'react' import { connect } from 'dva' const MainLayout = ({ children, auth, location, dispatch, }) => ( <div> <h2>I'm layout</h2> {auth.login ? children : null} </div> ) export default connect(({ auth }) => ({ auth }))(MainLayout)
src/svg-icons/image/filter-vintage.js
lawrence-yu/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ImageFilterVintage = (props) => ( <SvgIcon {...props}> <path d="M18.7 12.4c-.28-.16-.57-.29-.86-.4.29-.11.58-.24.86-.4 1.92-1.11 2.99-3.12 3-5.19-1.79-1.03-4.07-1.11-6 0-.28.16-.54.35-.78.54.05-.31.08-.63.08-.9...
src/svg-icons/av/playlist-play.js
pancho111203/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let AvPlaylistPlay = (props) => ( <SvgIcon {...props}> <path d="M19 9H2v2h17V9zm0-4H2v2h17V5zM2 15h13v-2H2v2zm15-2v6l5-3-5-3z"/> </SvgIcon> ); AvPlaylistPlay = pure(AvPlaylistPlay); AvPlaylistPlay.displayName = '...
src/svg-icons/action/reorder.js
pancho111203/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionReorder = (props) => ( <SvgIcon {...props}> <path d="M3 15h18v-2H3v2zm0 4h18v-2H3v2zm0-8h18V9H3v2zm0-6v2h18V5H3z"/> </SvgIcon> ); ActionReorder = pure(ActionReorder); ActionReorder.displayName = 'Action...
src/components/Service/Service.js
easingthemes/easingthemes.github.io
import React from 'react'; import TextRow from '../TextRow'; import getPageData from '../../utils/getPageData'; export class Service extends React.Component { constructor(props) { super(props); this.state = { post: { leadTitle: '', title: '', leadText: '', text: '' }, isLoading: true };...
src/pages/Home.js
ayltai/fishing-club
// @flow 'use strict'; import React from 'react'; import muiThemeable from 'material-ui/styles/muiThemeable'; import { Card, CardMedia, CardTitle, CardText } from 'material-ui/Card'; import LogoImage from '../images/logo.jpg'; class Home extends React.Component { componentDidMount() : void { window.scroll...
src/components/QuestionList.js
gsans/handsup-react
import React from 'react' import PropTypes from 'prop-types' import Question from './Question' import { graphql } from 'react-apollo' import update from 'immutability-helper' import { isDuplicate, POLLING_TIME } from '../utils/helpers' import Loading from './Loading' import QUESTIONS_QUERY from '../graphql/Questions....
src/components/details/SortedSetDetails.js
cpsubrian/redis-explorer
import React from 'react' import pureRender from 'pure-render-decorator' import ImmutablePropTypes from 'react-immutable-proptypes' import clipboard from 'clipboard' import Details from '../../components/details/Details' import Highlight from '../../components/Highlight' import Icon from '../../components/Icon' @pureR...
client/screens/Users/UserForgotPwdSendEmail/index.js
francixcoag/trace_packages
import React from 'react'; import UsersNavBar from '../components/UsersNavBar'; import FormContainer from './FormContainer.js'; export default () => ( <div> <UsersNavBar label="Send Forgot Password Email" screen="user/forgotpwdsendemail" /> <FormContainer /> </div> );
src/containers/book-detail.js
timseo/tinder_redux
import React, { Component } from 'react'; import { connect } from 'react-redux'; class BookDetail extends Component { render() { if (!this.props.book) { return <div>Select a book to get started.</div>; } return ( <div> <h3>Details for:</h3> <div>Title: {this.props.book.title}...
mealbotui/src/js/components/CustomToggle.js
qjflores/mealbot
import React, { Component } from 'react'; export class CustomToggle extends Component { constructor(props, context) { super(props, context); this.handleClick = this.handleClick.bind(this); } handleClick(e) { e.preventDefault(); this.props.onClick(e); } render() { return ( <a hr...
ext/lib/site/topic-layout/topic-article-propuesta/comments/list/comment/footer/component.js
DemocraciaEnRed/vicentelopez
import React from 'react' import t from 't-component' export default function CommentFooter (props) { return ( <footer className='actions'> <div className='votes'> <span className='score'> <span>{props.score}</span> {' '} </span> {!props.isOwner && ( <b...
packages/material-ui-icons/src/SettingsSystemDaydream.js
AndriusBil/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from 'material-ui/SvgIcon'; let SettingsSystemDaydream = props => <SvgIcon {...props}> <path d="M9 16h6.5c1.38 0 2.5-1.12 2.5-2.5S16.88 11 15.5 11h-.05c-.24-1.69-1.69-3-3.45-3-1.4 0-2.6.83-3.16 2.02h-.16C7.17 10.18 6 11.45 6 13c0 1.66 1...
stories/utils/Components/ComponentMetaInfoGetter/index.js
skyiea/wix-style-react
import {normalize} from 'path'; import React from 'react'; import PropTypes from 'prop-types'; import parser from '../AutoDocs/parser'; export default class ComponentMetaInfoGetter extends React.PureComponent { static propTypes = { componentSrcFolder: PropTypes.string, showStoryContent: PropTypes.func.isRe...
client/acp/index.js
NicolasSiver/nodebb-plugin-ns-twitch-monitor
import Application from './components/Application'; import Define from 'define'; import React from 'react'; Define('admin/plugins/twitch-monitor', [], () => { return { init: function () { React.render( <Application />, document.getElementById('acpTwitchMonitor') ...
react_docs/src/index.js
GobHash/GobHash-Backend
import 'babel-polyfill'; import React from 'react'; import ReactDOM from 'react-dom'; import App from './components/app'; import remark from 'remark'; import slug from 'remark-slug'; import content from './custom/content'; var ast = remark() .use(slug) .runSync(remark().parse(content)); ReactDOM.render( <App as...
alcarin_frontend/src/character_dashboard/CharacterDashboardPage.js
alcarin-org/alcarin-elixir
// @flow import React from 'react'; import { Socket, Channel } from 'phoenix'; import CharacterFeed from './character-feed/CharacterFeed'; import { PushNamespace, PushAction, type PushNamespaceType, type PushActionType, } from './ChannelPushTypes'; type ComponentPropsType = {| onSubmit?: (state: string) =>...
src/App/Error/Error.js
shaine/squidtree-react
import React from 'react'; import Helmet from 'react-helmet'; const ErrorPage = ({ error }) => ( <div className="errorPage"> <Helmet title={error} /> {error} </div> ); ErrorPage.defaultProps = { error: 'Not found' }; export default ErrorPage;
src/components/shop/InfoItems.js
visa-innovation-sf/ldn-retail-demo
import React, { Component } from 'react'; import { View, Image, StyleSheet, Animated, Easing, TouchableOpacity } from 'react-native'; import { Text, Spacer } from '@components/ui/'; import { AppColors, AppStyles, AppSizes} from '@theme/'; /* Styles ================================= */ const styles = StyleSheet.create...
docs/pages/components/pagination.js
lgollut/material-ui
import React from 'react'; import MarkdownDocs from 'docs/src/modules/components/MarkdownDocs'; import { prepareMarkdown } from 'docs/src/modules/utils/parseMarkdown'; const pageFilename = 'components/pagination'; const requireDemo = require.context('docs/src/pages/components/pagination', false, /\.(js|tsx)$/); const ...
src/board/components/AWPol.js
corbig/AfterWorkManager
import React from 'react'; import {Card, CardActions, CardHeader, CardMedia, CardTitle, CardText} from 'material-ui/Card'; import TextField from 'material-ui/TextField'; import Paper from 'material-ui/Paper'; import {List, ListItem} from 'material-ui/List'; import Divider from 'material-ui/Divider'; import Floati...
service_2/src/routes.js
cleverbridge/spike_living_styleguide
// src/routes.js import React from 'react'; import { Route, IndexRoute } from 'react-router'; import Layout from './components/layout'; import PaymentData from './components/payment_data'; import NotFoundPage from './components/not_found_page'; const routes = ( <Route path="/" component={Layout}> <IndexRou...
javascript/youtube-search/src/components/video_list_item.js
sandislonjsak/react-learning-projects
import React from 'react'; const VideoListItem = ({ video, onVideoSelect }) => { const snippet = video.snippet; const imageUrl = snippet.thumbnails.default.url; return ( <li onClick={() => onVideoSelect(video)} className="list-group-item"> <div className="video-list media"> <div className="med...
src/parser/warrior/arms/modules/spells/azeritetraits/LordOfWar.js
sMteX/WoWAnalyzer
import { calculateAzeriteEffects } from 'common/stats'; import SPELLS from 'common/SPELLS'; import Analyzer, { SELECTED_PLAYER } from 'parser/core/Analyzer'; import TraitStatisticBox, { STATISTIC_ORDER } from 'interface/others/TraitStatisticBox'; import React from 'react'; import Events from 'parser/core/Events'; impor...
app/views/LoadingView/index.js
omeryagmurlu/algoriv
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import FlatButton from 'material-ui/FlatButton'; import { themedStyle, themeVars } from 'app/utils'; import { ballGridPulse } from 'loaders.css/loaders.css'; import style from './style.scss'; const css = themedStyle(style); const getOverla...