path
stringlengths
5
296
repo_name
stringlengths
5
85
content
stringlengths
25
1.05M
src/client/components/base/Belt/WorkSlider.component.js
DBCDK/content-first
import React from 'react'; import './WorkSlider.component.css'; import {get, debounce} from 'lodash'; import WorkCard from '../../work/WorkCard/WorkCard.container'; import Slider from './Slider.component'; import Title from '../../base/Title'; import T from '../T'; export default class WorkSlider extends React.Compone...
fixtures/dom/src/components/fixtures/input-change-events/RadioClickFixture.js
yangshun/react
import React from 'react'; import Fixture from '../../Fixture'; class RadioClickFixture extends React.Component { constructor(props, context) { super(props, context); this.state = { changeCount: 0, }; } handleChange = () => { this.setState(({changeCount}) => { return { chan...
src/components/Footer/Footer.js
cmosguy/react-redux-auth0
/** * 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 from 'react'; import withStyles from 'isomorp...
src/Accordion/__tests__/AccordionItem.spec.js
ClarityMovement/clarity-components
/* eslint-env jest */ import React from 'react'; import { shallow } from 'enzyme'; import enzymeToJson from 'enzyme-to-json'; import snapshotHocProps from 'react-render-counter/utils/testHelpers/snapshotHocProps'; import AccordionItem, { AccordionItemRenderer } from '../AccordionItem'; import asAccordionItem from '../a...
tests/index-test.js
unlayer/react-email-editor
import expect from 'expect' import React from 'react' import {render, unmountComponentAtNode} from 'react-dom' import Component from 'src/' describe('Component', () => { let node beforeEach(() => { node = document.createElement('div') }) afterEach(() => { unmountComponentAtNode(node) }) it('dis...
src/__tests__/AutosizeInput-test.js
JedWatson/react-input-autosize
'use strict'; /* global describe, it, expect */ import React from 'react'; import TestUtils from 'react-dom/test-utils'; import AutosizeInput from '../AutosizeInput'; describe('AutosizeInput test', function () { function logChange (val) { console.log('Selected: ' + val); } // Render an instance of the component v...
node_modules/react-bootstrap/es/TabContainer.js
mohammed52/something.pk
import _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties'; import _classCallCheck from 'babel-runtime/helpers/classCallCheck'; import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn'; import _inherits from 'babel-runtime/helpers/inherits'; import React from 'r...
src/containers/HomeSmplx.js
pjkarlik/ReactUI
import React from 'react'; import { resolve } from '../styles'; import GridLayout from '../components/GridLayout'; import GridLayoutStyles from '../components/GridLayout.less'; import SiteStyles from '../styles/Site.less'; /* eslint no-console: 0 */ /* eslint arrow-body-style: 0 */ /* eslint react/jsx-no-bind: 0 */ ex...
docs/src/SupportPage.js
gianpaj/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...
blueocean-material-icons/src/js/components/svg-icons/action/room.js
kzantow/blueocean-plugin
import React from 'react'; import SvgIcon from '../../SvgIcon'; const ActionRoom = (props) => ( <SvgIcon {...props}> <path d="M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5c-1.38 0-2.5-1.12-2.5-2.5s1.12-2.5 2.5-2.5 2.5 1.12 2.5 2.5-1.12 2.5-2.5 2.5z"/> </SvgIcon> ); ActionRoom.di...
app/components/static/Footer.js
communicode-source/communicode
import React from 'react'; import main from '../../assets/css/main.scss'; import footer from '../../assets/css/static/footer.scss'; import classNames from 'classnames'; import FacebookSocialButton from '../layout/FacebookSocialButton'; import TwitterSocialButton from '../layout/TwitterSocialButton'; import InstagramSoc...
src/components/EndScene.js
spcoder/movietrivia
import React, { Component } from 'react'; import Scene from './Scene'; import Button from './Button'; class EndScene extends Component { render() { return ( <Scene title="game over" noback> <Button to="/length">Again?</Button> </Scene> ); } } export default EndScene;
src/interface/layout/NavigationBar/LoadingBar/index.js
sMteX/WoWAnalyzer
import React from 'react'; import PropTypes from 'prop-types'; import './LoadingBar.scss'; class LoadingBar extends React.PureComponent { static propTypes = { progress: PropTypes.number, chunks: PropTypes.number, }; static defaultProps = { progress: 0, chunks: 12, }; constructor(props) { ...
plugins/Logs/js/main.js
NebulousLabs/Sia-UI
import React from 'react' import { createStore } from 'redux' import { Provider } from 'react-redux' import loggingReducer from './reducer.js' import App from './components/app.js' import * as actions from './actions.js' export const logsPlugin = () => { const store = createStore(loggingReducer) setInterval(() => ...
ReactComponents/NetworkImage.js
DoSomething/LetsDoThis-iOS
'use strict'; import React from 'react'; import { StyleSheet, Text, Image, ActivityIndicatorIOS, View, } from 'react-native'; import Dimensions from 'Dimensions'; var Style = require('./Style.js'); // Borrowed heavily from the React Native Image example // @see https://facebook.github.io/react-native/docs/...
modules/gui/src/app/home/body/process/recipe/indexChange/panels/inputImage/assetSection.js
openforis/sepal
import {AssetInput} from 'widget/assetInput' import {msg} from 'translate' import PropTypes from 'prop-types' import React from 'react' import style from './inputImage.module.css' export default class AssetSection extends React.Component { render() { const {input, onLoading} = this.props return ( ...
Sobiens.Web.Components.ReactTutorial/ClientApp/src/App.js
sobiens/webcomponents
import React, { Component } from 'react'; import { Route } from 'react-router'; import { Layout } from './components/Layout'; import { Home } from './components/Home'; import { FetchData } from './components/FetchData'; import { Counter } from './components/Counter'; import { config } from './config'; export default c...
test/module/Exam.spec.js
NUS-Workload-Predictor/front-end
import React from 'react'; import { mount, shallow } from 'enzyme'; import { expect } from 'chai'; import configureStore from 'redux-mock-store'; const fetch = require('isomorphic-fetch'); import App from '../containers/App'; const middlewares = []; const mockStore = configureStore(middlewares); function setup() {...
component/ProductList.js
jimju/BNDemo
import React, { Component } from 'react'; import { AppRegistry, StyleSheet, Text, View, ListView, TouchableHighlight, ToastAndroid, InteractionManager, Image } from 'react-native'; import ProductDetail from '../page/ProductDetail'; var Dimensions = require('Dimensions'); var ScreenWidth = Dimension...
src/client/react/admin/views/TeamsView/TeamRemove.js
bwyap/ptc-amazing-g-race
import React from 'react'; import PropTypes from 'prop-types'; import autobind from 'core-decorators/es/autobind'; import { graphql } from 'react-apollo'; import { Button, Intent, Dialog } from '@blueprintjs/core'; import { removeTeam } from '../../../../graphql/team'; import NotificationToaster from '../../../componen...
src/svg-icons/editor/bubble-chart.js
jacklam718/react-svg-iconx
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let EditorBubbleChart = (props) => ( <SvgIcon {...props}> <circle cx="7.2" cy="14.4" r="3.2"/><circle cx="14.8" cy="18" r="2"/><circle cx="15.2" cy="8.8" r="4.8"/> </SvgIcon> ); EditorBubbleChart = pure(EditorBub...
src/js/Components/HeroBanner.js
7sleepwalker/addicted-to-mnt
import React, { Component } from 'react'; import logo from '../../img/logo.png'; import video from '../../mov/background.mp4'; class HeroBanner extends Component { render() { return ( <div className='hero-banner'> <video poster="https://s3-us-west-2.amazonaws.com/s.cdpn.io/4273/polina.jpg" classNa...
src/frontend/containers/auth/token.js
PiTeam/garage-pi
import React, { Component } from 'react'; import { connect } from 'react-redux'; import { bindActionCreators } from 'redux'; import { browserHistory } from 'react-router'; import { processActivateUser } from 'actions'; import { getAuthPropType } from 'proptypes'; class TokenAuth extends Component { constructor(prop...
app/javascript/mastodon/features/list_editor/index.js
lindwurm/mastodon
import React from 'react'; import PropTypes from 'prop-types'; import ImmutablePropTypes from 'react-immutable-proptypes'; import { connect } from 'react-redux'; import ImmutablePureComponent from 'react-immutable-pure-component'; import { injectIntl } from 'react-intl'; import { setupListEditor, clearListSuggestions, ...
app/addons/documents/doc-editor/components/AttachmentsPanelButton.js
michellephung/couchdb-fauxton
// Licensed under the Apache License, Version 2.0 (the "License"); you may not // use this file except in compliance with the License. You may obtain a copy of // the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed un...
src/svg-icons/notification/enhanced-encryption.js
igorbt/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let NotificationEnhancedEncryption = (props) => ( <SvgIcon {...props}> <path d="M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zM8.9 6c0-1.71 1.39-3....
src/svg-icons/communication/chat-bubble.js
ArcanisCz/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let CommunicationChatBubble = (props) => ( <SvgIcon {...props}> <path d="M20 2H4c-1.1 0-2 .9-2 2v18l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2z"/> </SvgIcon> ); CommunicationChatBubble = pure(CommunicationChatBubble)...
examples/complex/src/routes.js
vgno/roc-web-react
import React from 'react'; import { Route, IndexRoute } from 'react-router'; import App from './components/app'; import Main from './components/main'; import About from './components/about'; export default () => ( <Route component={ App }> <IndexRoute component={ Main } /> <Route path="about/" com...
src/svg-icons/maps/directions-car.js
owencm/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let MapsDirectionsCar = (props) => ( <SvgIcon {...props}> <path d="M18.92 6.01C18.72 5.42 18.16 5 17.5 5h-11c-.66 0-1.21.42-1.42 1.01L3 12v8c0 .55.45 1 1 1h1c.55 0 1-.45 1-1v-1h12v1c0 .55.45 1 1 1h1c.55 0 1-.45 1-1...
public/plugin/lokka-archives/src/index.js
morygonzalez/portalshit.net
import React from 'react' import { createRoot } from 'react-dom/client' import App from './App' const container = document.getElementById('root') const root = createRoot(container) root.render( <App />)
source/shared/components/app/index.js
gacosta89/knightsTour
import React from 'react'; import createViewport from 'shared/components/viewport'; import createSection from 'shared/components/section'; import createJumbo from 'shared/components/jumbo'; import createLoadPanel from 'shared/containers/loadpanel'; import createBoard from 'shared/containers/board'; import createControl...
node_modules/react-router/es/IndexRoute.js
rafser01/installer_electron
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 <IndexRoute> i...
packages/react-dom/src/client/ReactDOMOption.js
rricard/react
/** * 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. * * @flow */ import React from 'react'; import warning from 'shared/warning'; import {getToStringValue, toString} from './ToStringV...
src/routes/Home/components/HomeView.js
miyanokomiya/b-net
import React from 'react' import DuckImage from '../assets/Duck.jpg' import './HomeView.scss' import { IndexLink, Link } from 'react-router' export const HomeView = () => ( <div> <h4>Welcome!</h4> <img alt='This is a duck, because Redux!' className='duck' src={DuckImage} /> <Link to='/room'> Let's ...
classic/src/scenes/wbfa/generated/FARMagic.free.js
wavebox/waveboxapp
import React from 'react' import { FontAwesomeIcon } from '@fortawesome/react-fontawesome' import { faMagic } from '@fortawesome/free-solid-svg-icons/faMagic' export default class FARMagic extends React.Component { render () { return (<FontAwesomeIcon {...this.props} icon={faMagic} />) } }
src/client/components/work/TaxDescription.component.js
DBCDK/content-first
import React from 'react'; const TaxDescription = ({text}) => { if (!text) { return ''; } return text.split('\n').map((line, i) => { return ( <span key={i}> {line} <br /> </span> ); }); }; export default TaxDescription;
src/svg-icons/editor/format-size.js
ArcanisCz/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let EditorFormatSize = (props) => ( <SvgIcon {...props}> <path d="M9 4v3h5v12h3V7h5V4H9zm-6 8h3v7h3v-7h3V9H3v3z"/> </SvgIcon> ); EditorFormatSize = pure(EditorFormatSize); EditorFormatSize.displayName = 'EditorFo...
src/index.js
leonzhang2008/gallery-by-react
import 'core-js/fn/object/assign'; import React from 'react'; import ReactDOM from 'react-dom'; import App from './components/Main'; // Render the main component into the dom ReactDOM.render(<App />, document.getElementById('app'));
react-fundamentals/composable-apis/src/index.js
FMCalisto/react-get-started
import React from 'react'; import ReactDOM from 'react-dom'; import App from './App'; ReactDOM.render( <App cat={5} />, document.getElementById('root') );
packages/wix-style-react/src/TableActionCell/docs/examples/PrimaryWithOnlyVisibleSecondaryExample.js
wix/wix-style-react
import React from 'react'; import Download from 'wix-ui-icons-common/Download'; import Duplicate from 'wix-ui-icons-common/Duplicate'; import { classes } from '../TableActionCell.story.st.css'; import { TableActionCell } from 'wix-style-react'; const Example = () => ( <div className={classes.exampleRow}> <TableA...
renderer/vectors/settings.js
wulkano/kap
import React from 'react'; import Svg from './svg'; const SettingsIcon = props => ( <Svg {...props}> <path d="M0 0h24v24H0z" fill="none"/> <path d="M12 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm7-7H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2zm-1.75 9c0 .23-.02.46-.05.68l1.48 1.16c....
src/containers/billing/index.js
dylanlott/bridge-gui
import React, { Component } from 'react'; import { connect } from 'react-apollo'; import { hashHistory } from 'react-router'; import client from 'utils/api-client'; import gql from 'graphql-tag'; import moment from 'moment'; import BalancePanel from 'components/billing/balance-panel'; import PaymentInfoPanel from 'comp...
webpack/scenes/ModuleStreams/ModuleStreamsTableSchema.js
Katello/katello
import React from 'react'; import { Link } from 'react-router-dom'; import { urlBuilder } from 'foremanReact/common/urlHelpers'; import { translate as __ } from 'foremanReact/common/I18n'; import { headerFormatter, cellFormatter, } from '../../components/pf3Table'; const TableSchema = [ { property: 'name', ...
src/Posts/Standardization/customizablePlot.js
jasongforbes/jforbes.io
import React from 'react'; import { connect } from 'react-redux'; import PropTypes from 'prop-types'; import Grid from '@material-ui/core/Grid'; import Slider from '@material-ui/lab/Slider'; import { withStyles } from '@material-ui/core/styles'; import Typography from '@material-ui/core/Typography'; const styles = the...
src/components/LinkSpec.js
samlawrencejones/react-starter
import expect from 'expect' import React from 'react' import TestUtils from 'react-addons-test-utils' import Link from './Link' describe('link componenet', () => { const linkText = 'foobar' const setup = (active) => { let props = { active: active, text: linkText, onClick: expect.createSpy() ...
src/components/Select/SelectInput.js
sk-iv/iva-app
import React from 'react'; import PropTypes from 'prop-types'; import classNames from 'classnames'; import keycode from 'keycode'; import warning from 'warning'; import Menu from '../Menu/Menu'; import { isDirty } from '../Input/Input'; import {ChevronDown} from '../SvgIcon'; /** * @ignore - internal component. */ c...
src/views/components/Switch.js
physiii/home-gateway
import React from 'react'; import PropTypes from 'prop-types'; import './Switch.css'; export const Switch = (props) => { const {isOn, showLabels, offLabel, onLabel, ...inputProps} = {...props}; return ( <div styleName={'container' + (props.disabled ? ' isDisabled' : '')}> {showLabels && <span styleName="offLab...
src/containers/search_bar.js
framirez224/weather-app
import React, { Component } from 'react'; import { connect } from 'react-redux'; import { bindActionCreators } from 'redux'; import { fetchWeather } from '../actions/index'; class SearchBar extends Component { constructor(props) { super(props); this.state = { term: '' }; // Need to bind the method cal...
app/containers/HomePage/index.js
jakubrohleder/aurelius
/* * HomePage * * This is the first thing users see of our App, at the '/' route * * NOTE: while this component should technically be a stateless functional * component (SFC), hot reloading does not currently support SFCs. If hot * reloading is not a necessity for you then you can refactor it and remove * the l...
src/svg-icons/action/cached.js
kasra-co/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionCached = (props) => ( <SvgIcon {...props}> <path d="M19 8l-4 4h3c0 3.31-2.69 6-6 6-1.01 0-1.97-.25-2.8-.7l-1.46 1.46C8.97 19.54 10.43 20 12 20c4.42 0 8-3.58 8-8h3l-4-4zM6 12c0-3.31 2.69-6 6-6 1.01 0 1.97....
src/components/AboutButton/AboutButton.js
Zoomdata/nhtsa-dashboard
import flowRight from 'lodash.flowright'; import React from 'react'; import { observer, inject } from 'mobx-react'; import image from '../../images/about-button.png'; const AboutButton = ({ store }) => { return ( <img alt="" className="about-button" width="119" height="28.5" src={im...
lib/component-library-slides/ComponentDecorator.js
waynecraig/encoding-present
import React from 'react'; import CodeBlock from '../components/CodeBlock'; const decoratorCode = `@PureRender @WithValidation class TextInput extends React.Component { ... } ... function WithValidation(TargetComponent) { return class WithValidation extends React.Component { ... render = () => { c...
wagtail/admin/static_src/wagtailadmin/app/wagtailadmin.entry.js
nimasmi/wagtail
import React from 'react'; import ReactDOM from 'react-dom'; import { Icon, Portal, initExplorer, initFocusOutline, initSubmenus, initUpgradeNotification, } from 'wagtail-client'; if (process.env.NODE_ENV === 'development') { // Run react-axe in development only, so it does not affect performance // in...
src/components/widget/Labels/Label.js
metasfresh/metasfresh-webui-frontend
import React, { Component } from 'react'; import PropTypes from 'prop-types'; const noOp = () => {}; /** * @file Class based component. * @module Label * @extends Component */ class Label extends Component { /** * @method handleClick * @summary ToDo: Describe the method * @todo Write the documentation ...
src/index.js
NemethNorbert/restaurant-website
import React from 'react'; import 'bootstrap/dist/css/bootstrap.css'; import './index.css'; import App from './App'; import registerServiceWorker from './registerServiceWorker'; import { render } from 'react-snapshot'; import { BrowserRouter } from 'react-router-dom'; import ScrollToTop from './components/ScrollToTop'...
src/components/ProfileRow.js
kamilpodlasek/carrot-admin-panel
import React from 'react'; import PropTypes from 'prop-types'; import ButtonGroup from 'react-bootstrap/lib/ButtonGroup'; import Button from 'react-bootstrap/lib/Button'; import TdCenter from './styledComponents/TdCenter'; const ProfileRow = ({profile, deleteCarrots, addCarrots, deleteProfile}) => ( <tr> <td>{p...
web/client/test/components/Home.spec.js
nictuku/stardew-rocks
/* eslint-disable no-magic-numbers */ import React from 'react'; import {mount} from 'enzyme'; import chai, {expect} from 'chai'; chai.use(require('sinon-chai')); chai.use(require('chai-enzyme')()); import options from '../mocks/mockOptions'; import mockFarms from '../mocks/mockFarms'; import mockProps from '../mocks...
src/components/Select.js
nikgraf/belle
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import ReactDOM from 'react-dom'; import { omit, filter, filterReactChildren, find, first, flattenReactChildren, isEmpty, findIndex, has, some, last, uniqueId, } from '../utils/helpers'; import { canUseDOM } from 'exen...
node_modules/react-bootstrap/es/MediaHeading.js
xuan6/admin_dashboard_local_dev
import _extends from 'babel-runtime/helpers/extends'; import _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties'; import _classCallCheck from 'babel-runtime/helpers/classCallCheck'; import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn'; import _inherits from ...
classic/src/scenes/wbui/WaveboxRouter/WaveboxRouterNoMatch.js
wavebox/waveboxapp
import React from 'react' const NO_MATCH_HASHES = new Set(['', '#', '#/']) export default class WaveboxRouterNoMatch extends React.Component { /* **************************************************************************/ // Rendering /* **************************************************************************...
BaiSi/app/pages/main/mainContainer.js
MisterZhouZhou/ReactNativeLearing
import React, { Component } from 'react'; import { AppRegistry, StyleSheet, Text, View, TouchableOpacity, InteractionManager } from 'react-native'; import Icon from 'react-native-vector-icons/Ionicons'; // import NavBar from 'react-native-navbar'; // import ScrollableTabView, {DefaultTabBar, S...
client/components/dashboard/FeedContainer.js
creativcoder/rio
import React from 'react'; import {Tabs, Tab } from 'react-bootstrap'; import Tweetlist from './Tweetlist'; import Profile from './Profile'; import Searchbar from './Searchbar'; import { connect } from 'react-redux'; import { bindActionCreators } from 'redux'; import {home_timeline, user_timeline, search_tweets } from ...
node_modules/react-router/es6/RouteContext.js
937aaron/reduxblog
import warning from './routerWarning'; import React from 'react'; var object = React.PropTypes.object; /** * The RouteContext mixin provides a convenient way for route * components to set the route in context. This is needed for * routes that render elements that want to use the Lifecycle * mixin to prevent trans...
src/components/styledCommons.js
davosolo/davosolo.github.io
import React from 'react' import styled from 'styled-components' import { injectGlobal } from 'styled-components'; /* * Global Styles */ injectGlobal` @import url('https://fonts.googleapis.com/css?family=Hammersmith+One'); body { font-family: 'Slabo 27px', serif; color: palevioletred; background: papayawhip; ...
presentation/index.js
AlanFoster/react-native-presentation
// Import React import React from "react"; // Import Spectacle Core tags import { Appear, BlockQuote, Cite, CodePane, ComponentPlayground, Deck, Fill, Heading, Image, Layout, Link, ListItem, List, Quote, Slide, SlideSet, TableBody, TableHeader, TableHeaderItem, TableItem, TableRow, Table, Text } from "spectacle"...
app/index.js
Velenir/workers-journey
import React from 'react'; import {render} from 'react-dom'; import { Router, Route, applyRouterMiddleware, browserHistory} from 'react-router'; import App from './components/App'; import NotFound from './components/NotFound'; import Footer from './components/Footer'; import useScroll from 'react-router-scroll/lib/u...
app/containers/App/index.js
KyleAWang/react-boilerplate
/** * * App * * 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) */ import React from 'react'; import Helmet from 'react-helmet'; import styled from 'styled-components'; import Header from 'components/Header'; import F...
src/svg-icons/image/navigate-before.js
matthewoates/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ImageNavigateBefore = (props) => ( <SvgIcon {...props}> <path d="M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z"/> </SvgIcon> ); ImageNavigateBefore = pure(ImageNavigateBefore); ImageNavigateBefore.displayName...
react-app/f2a-click-video-editor/src/app.js
rotanov/f2a-click-video-editor
import React, { Component } from 'react'; import './app.css'; import Cutlist from './cutlist.js' class App extends Component { URL = window.URL || window.webkitURL; displayMessage(message, isError) { console.log(message); } playSelectedFile(event) { console.log(event); let file = event.target.files...
src/js/containers/IndexPage.js
rmhowe/picross
import React from 'react'; import { connect } from 'react-redux'; import { selectPuzzle, setModal, setNightMode, setAppColor } from '../actions'; import { COLOR_CHANGE } from '../constants'; import PuzzleSelector from '../components/PuzzleSelector'; import Settings from '../components/Settings'; import { shade...
src/components/__tests__/general/loading-test.js
OlivierVillequey/hackathon
/** * Test to check if the component renders correctly */ /* global it expect */ import 'react-native'; import React from 'react'; import renderer from 'react-test-renderer'; import Loading from '@components/general/Loading'; it('Loading renders correctly', () => { const tree = renderer.create( <Loading />, ...
src/ui/views/HomeView.js
gouxlord/gx-js-starterkit
import React from 'react'; import AddTextForm from 'src/containers/AddTextForm'; import TextList from 'src/containers/TextList'; var HomeView = React.createClass({ render () { return ( <div className="homeView"> <AddTextForm className="form"> </AddTextForm> ...
src/client/replies/Replies.js
busyorg/busy
import React from 'react'; import PropTypes from 'prop-types'; import Helmet from 'react-helmet'; import { injectIntl } from 'react-intl'; import { connect } from 'react-redux'; import { getIsAuthenticated, getAuthenticatedUserName, getFeed } from '../reducers'; import { getFeedFromState, getFeedLoadingFromState, ...
src/FlexboxGrid/test/FlexboxGridSpec.js
suitejs/suite
import React from 'react'; import { getDOMNode } from '@test/testUtils'; import FlexboxGrid from '../FlexboxGrid'; describe('FlexboxGrid', () => { it('Should render a FlexboxGrid', () => { const instance = getDOMNode(<FlexboxGrid>Test</FlexboxGrid>); assert.include(instance.className, 'rs-flex-box-grid'); ...
grails-app/assets/javascripts/dependencies/node_modules/react-router/es6/RouteContext.js
puaykai/noodles
import warning from './routerWarning'; import React from 'react'; var object = React.PropTypes.object; /** * The RouteContext mixin provides a convenient way for route * components to set the route in context. This is needed for * routes that render elements that want to use the Lifecycle * mixin to prevent trans...
examples/using-preact/pages/about.js
dizlexik/next.js
import React from 'react' export default () => ( <div>About us</div> )
src/js/__tests__/NewsList.react-test.js
colw/cowpat
// NewsList.react-test.js import React from 'react'; import NewsItem from '../NewsItem'; import renderer from 'react-test-renderer'; import NewsList from '../NewsList'; const data = { "newsItems": [{ "author": "Associated Press", "guid": "https://www.washingtonpost.com/world/asia_pacific/afghan-official-7-killed-...
mi9_dj/client/main.js
nhardy/mi9-dj
import React from 'react'; import ReactDOM from 'react-dom'; import App from './components/App'; import appState from './state'; import {addVideo} from './websocket'; let priorState = { playlist: [], searchResults: [], } function renderPage(state) { const newState = { ...priorState, ...state, }; p...
examples/components/Debug.js
neilff/react-d3-examples
import React from 'react'; const Debug = ({ value, spacing = 2 }) => { return ( <pre className="p1 mt1 mb1" style={ styles.base }> { `${ JSON.stringify(value, null, spacing) }` } </pre> ); }; const styles = { base: { overflow: 'hidden', }, }; export default Debug;
frontend/src/Settings/Indexers/Indexers/EditIndexerModalContentConnector.js
Radarr/Radarr
import PropTypes from 'prop-types'; import React, { Component } from 'react'; import { connect } from 'react-redux'; import { createSelector } from 'reselect'; import { saveIndexer, setIndexerFieldValue, setIndexerValue, testIndexer } from 'Store/Actions/settingsActions'; import createProviderSettingsSelector from 'Sto...
src/universal/pages/EventsList/Drawer/CalendarSelect/index.js
sanchitgangwar/remind-plus
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import { connect } from 'react-redux'; import { bindActionCreators } from 'redux'; import cx from 'classnames'; import List, { ListItem, ListItemText, ListItemIcon } from 'material-ui/List'; import Collapse from 'material-ui/transitions/Coll...
node_modules/react-navigation/lib-rn/TypeDefinition.js
RahulDesai92/PHR
import React from 'react'; // @todo when we split types into common, native and web, // we can properly change Animated.Value to its real value /** * NavigationState is a tree of routes for a single navigator, where each child * route may either be a NavigationScreenRoute or a NavigationRouterRoute. * NavigationS...
client/index.js
Jeffrey-Meesters/React-Shoot
import React from 'react' import { render } from 'react-dom' import { Provider } from 'react-redux' import store, { history } from './store' import { Router, Route, IndexRoute } from 'react-router' import injectTapEventPlugin from 'react-tap-event-plugin' import App from './App' import Home from './containers/Home' im...
src/containers/EffectView/EffectView.js
redux-saga/redux-saga-devtools
import PropTypes from 'prop-types'; import React from 'react'; import styled from 'styled-components' import { connect } from 'react-redux' import { isParentOf } from '../../store/selectors' import EffectList from '../EffectList' import EffectPath from './EffectPath' const EffectViewContainer = styled.div` display: ...
packages/core/src/components/IconLink/IconLink.js
appearhere/bloom
// @flow import React from 'react'; import cx from 'classnames'; import Icon from '../Icon/Icon'; import css from './IconLink.css'; type Props = { href: string, text: string, iconName: string, target: string, inverted: boolean, } const IconLink = ({ href, iconName, target, text, inverted, ...rest}: Props) =...
src/components/auction/teams/Roster.js
akeely/twoguysandadream-js
import React from 'react'; import WonPlayer from './WonPlayer'; export default class Roster extends React.Component { render() { var playersWon = this.props.team.roster.map((entry) => <WonPlayer key={'won.' + entry.player.id} rosterEntry={entry} /> ); return ( <t...
modules/RouteUtils.js
samidarko/react-router
import React from 'react' import warning from 'warning' function isValidChild(object) { return object == null || React.isValidElement(object) } export function isReactChildren(object) { return isValidChild(object) || (Array.isArray(object) && object.every(isValidChild)) } function checkPropTypes(componentName, p...
src/esm/components/action/close-button/index.js
KissKissBankBank/kitten
import _extends from "@babel/runtime/helpers/extends"; import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/objectWithoutPropertiesLoose"; var _excluded = ["closeButtonLabel", "buttonModifier"]; import React from 'react'; import { Button } from '../../action/button'; import { CrossIcon } from '../../graphi...
site/pages/APIPage.js
tomulin1/react-dnd
import React from 'react'; import Header from '../components/Header'; import PageBody from '../components/PageBody'; import SideBar from '../components/SideBar'; import StaticHTMLBlock from '../components/StaticHTMLBlock'; import { APIPages } from '../Constants'; export default class APIPage { render() { return ...
EventEmitter.Client/src/routes/Registrations/components/RegistrationsView.js
Stelmashenko-A/EventEmitter
import React from 'react' import { Link } from 'react-router' import { DataTable, TableHeader, Checkbox, Button } from 'react-mdl' function buildLink (name, id) { var link = '/event/' + id return <Link to={link} activeClassName='route--active'>{name}</Link> } function buildLinkForCalendar (id) { var link = 'http...
Components/ViewSwitcher.js
webismymind/Mycelium
import React from 'react'; import {View,Text} from 'react-native'; import Component from './Component'; export default class extends Component { constructor(props) { super(props); this.views = {}; this.state = { active : <View></View> }; this.history = []; ...
client/src/components/Draftail/blocks/ImageBlock.js
mixxorz/wagtail
import PropTypes from 'prop-types'; import React from 'react'; import { STRINGS } from '../../../config/wagtailConfig'; import MediaBlock from '../blocks/MediaBlock'; /** * Editor block to preview and edit images. */ const ImageBlock = (props) => { const { blockProps } = props; const { entity, onEditEntity, on...
src/js/components/icons/base/AccessVolumeControl.js
linde12/grommet
// (C) Copyright 2014-2015 Hewlett Packard Enterprise Development LP import React, { Component } from 'react'; import PropTypes from 'prop-types'; import classnames from 'classnames'; import CSSClassnames from '../../../utils/CSSClassnames'; import Intl from '../../../utils/Intl'; import Props from '../../../utils/Pro...
packages/bonde-admin/src/components/forms/help-block.js
ourcities/rebu-client
import PropTypes from 'prop-types' import React from 'react' import classnames from 'classnames' const HelpBlock = ({ children, className }) => ( <div className={classnames('muted my2', className)}> <small className='block'> <dfn>{children}</dfn> </small> </div> ) HelpBlock.propTypes = { className...
examples/react-refetch/src/Characters.js
gaearon/react-hot-loader
import React from 'react'; import { connect } from 'react-refetch'; const Characters = ({ charactersFetch }) => charactersFetch.fulfilled ? ( <ul>{charactersFetch.value.results.map(result => <li key={result.url}>{result.name}</li>)}</ul> ) : null; export default connect(() => ({ charactersFetch: 'https://sw...
docs/app/Examples/views/Statistic/Content/StatisticExampleValues.js
koenvg/Semantic-UI-React
import React from 'react' import { Icon, Image, Statistic } from 'semantic-ui-react' const StatisticExampleValues = () => ( <Statistic.Group> <Statistic> <Statistic.Value>22</Statistic.Value> <Statistic.Label>Saves</Statistic.Label> </Statistic> <Statistic> <Statistic.Value text> ...
docs/src/pages/demos/tables/CustomPaginationActionsTable.js
cherniavskii/material-ui
import React from 'react'; import PropTypes from 'prop-types'; import { withStyles } from 'material-ui/styles'; import Table, { TableBody, TableCell, TableFooter, TablePagination, TableRow, } from 'material-ui/Table'; import Paper from 'material-ui/Paper'; import IconButton from 'material-ui/IconButton'; impo...
definitions/npm/fixed-data-table-2_v7.x.x/test_fixed-data-table-2_v7.x.x.js
echenley/flow-typed
/* @flow */ import React from 'react'; import {Cell, Column, ColumnGroup, Table} from 'fixed-data-table-2'; let cell = <Cell/>; cell = <Cell onColumnResize={(left, width, minWidth, maxWidth, columnKey, event) => {event.target;}}/>; // $ExpectError cell = <Cell onColumnResize={(left, width, minWidth, maxWidth, columnKe...
packages/mineral-ui-icons/src/IconRepeat.js
mineral-ui/mineral-ui
/* @flow */ import React from 'react'; import Icon from 'mineral-ui/Icon'; import type { IconProps } from 'mineral-ui/Icon/types'; /* eslint-disable prettier/prettier */ export default function IconRepeat(props: IconProps) { const iconProps = { rtl: false, ...props }; return ( <Icon {...iconProps}>...
client/node_modules/eslint-config-airbnb/test/test-react-order.js
ronniehedrick/scapeshift
import test from 'tape'; import { CLIEngine } from 'eslint'; import eslintrc from '../'; import reactRules from '../rules/react'; import reactA11yRules from '../rules/react-a11y'; const cli = new CLIEngine({ useEslintrc: false, baseConfig: eslintrc, rules: { // It is okay to import devDependencies in tests....