path stringlengths 5 195 | repo_name stringlengths 5 79 | content stringlengths 25 1.01M |
|---|---|---|
src/components/RunnerForm/RunnerForm.js | tonimoeckel/lap-counter-react | /**
* 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 PropTypes from 'prop-... |
app/clients/next/components/utils.js | koapi/koapp | import React from 'react'
import { isFunction } from 'lodash'
import { compose, withState, withHandlers, branch } from 'recompose'
import Loadable from 'react-loading-overlay'
import numeral from 'numeral'
export const Formatters = {
Price (props) {
const { className = 'price', children, format = '$0,0.00', ...o... |
demo/client.js | redux-autoform/redux-autoform | import React from 'react';
import {render} from 'react-dom';
import configureStore from './store/configureStore';
import {Provider} from 'react-redux';
import DevTools from './components/DevTools';
import AutoForm from '../src/AutoForm';
import { getDemoFactory } from './demoFactory/demoFactoryHelper';
import ButtonToo... |
admin/src/javascripts/signin.all.js | sggdv/vegan | import React from 'react';
import ReactDOM from 'react-dom';
import SignInBox from '../react/signin-page';
ReactDOM.render(
<SignInBox title="登陆" />,
document.getElementById('content')
);
|
app/javascript/mastodon/components/permalink.js | pinfort/mastodon | import React from 'react';
import PropTypes from 'prop-types';
export default class Permalink extends React.PureComponent {
static contextTypes = {
router: PropTypes.object,
};
static propTypes = {
className: PropTypes.string,
href: PropTypes.string.isRequired,
to: PropTypes.string.isRequired,
... |
src/parser/druid/balance/modules/talents/azeritetraits/PowerOfTheMoon.js | ronaldpereira/WoWAnalyzer | import React from 'react';
import SPELLS from 'common/SPELLS';
import { formatNumber, formatPercentage } from 'common/format';
import { calculateAzeriteEffects } from 'common/stats';
import HIT_TYPES from 'game/HIT_TYPES';
import Analyzer from 'parser/core/Analyzer';
import AzeritePowerStatistic from 'interface/statis... |
react-dev/pages/post.js | InsidiousMind/code.LiquidThink | import React, { Component } from 'react';
import Paper from 'material-ui/Paper';
import { blueGrey800, grey50, teal900, green900, green500, teal500, cyan500 } from 'material-ui/styles/colors';
import darkBaseTheme from 'material-ui/styles/baseThemes/darkBaseTheme';
import MuiThemeProvider from 'material-ui/styles/Mui... |
src/sentry/static/sentry/app/index.js | BuildingLink/sentry | import jQuery from 'jquery';
import plugins from './plugins';
const csrfCookieName = window.csrfCookieName || 'sc';
// setup jquery for CSRF tokens
function getCookie(name) {
let cookieValue = null;
if (document.cookie && document.cookie !== '') {
let cookies = document.cookie.split(';');
for (let i = 0;... |
client/src/app/components/ribbon/Ribbon.js | zraees/sms-project | /**
* Created by griga on 11/24/15.
*/
import React from 'react'
import {OverlayTrigger, Tooltip} from 'react-bootstrap'
import ResetWidgets from './ResetWidgets'
import SmallBreadcrumbs from './SmallBreadcrumbs'
const tooltip = (
<Tooltip id="reset-widgets-suggestion"><i className='text-warning fa fa-warning'... |
src/components/Slider.js | rohan-deshpande/react-dat-gui | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import ReactDOM from 'react-dom';
import clamp from 'lodash.clamp';
import { toNumber } from './utils';
export default class Slider extends Component {
static propTypes = {
value: PropTypes.oneOfType([ PropTypes.number, PropTypes.stri... |
src/components/voteAction.js | Scya597/Caltcha | import React, { Component } from 'react';
export default class VoteAction extends Component {
constructor(props) {
super(props);
// this.idCheckOut = this.idCheckOut.bind(this);
// this.checkNormal = this.checkNormal.bind(this);
// this.checkOptional = this.checkOptional.bind(this);
}
// checkN... |
examples/redirect-using-index/app.js | moudy/react-router | import React from 'react';
import { Router, Route, IndexRoute, Link } from 'react-router';
var App = React.createClass({
render() {
return (
<div>
{this.props.children}
</div>
);
}
});
var Index = React.createClass({
render () {
return (
<div>
<h1>You should not se... |
app/start-page/OpenHouse.js | tscok/annsjon-spa | import React from 'react'
import purebem from 'purebem'
import getText from '../../assets/js/data/mygettext'
const block = purebem.of('open-house')
const OpenHouse = () => (
<section className={block()}>
<div className="container">
<h6 className={block('header')}>{getText('openhouse_header')}</h6>
... |
src/components/Repos.js | shierby/shierby.github.io | import React, { Component } from 'react';
import Spinner from 'react-spinkit';
import {Tabs, Tab} from 'material-ui/Tabs';
import DropDownMenu from 'material-ui/DropDownMenu';
import MenuItem from 'material-ui/MenuItem';
import SelectField from 'material-ui/SelectField';
import {grey600, grey50} from 'material-ui... |
tests/utils/TestInputHoc.js | meraki/mki-formsy-react | import React from 'react';
import { HOC as formsyHoc } from './../..';
import createReactClass from 'create-react-class';
const defaultProps = {
methodOnWrappedInstance(param) {
return param;
},
render() {
return (<input />);
},
};
export default formsyHoc(createReactClass(defaultProps));
|
src/components/Controls.js | leebradley/BomberBox | import React from 'react';
import styles from './Controls.css';
const instruction = (label, caption) => (
<div>
<span className={styles.dark}>{label}:</span> {caption}
</div>
);
const instructionsTouch = () => (
<div>
{instruction('Drag Anywhere', 'Move Player')}
{instruction('Tap', 'Drop Bomb')}
... |
frontend/src/components/common/timeline/datePoint.js | unicef/un-partner-portal | import React from 'react';
import PropTypes from 'prop-types';
import { withStyles } from 'material-ui/styles';
import SvgIcon from 'material-ui/SvgIcon';
import Tooltip from 'material-ui/Tooltip';
import Typography from 'material-ui/Typography';
import className from 'classnames';
import { formatDateForPrint } from '.... |
node_modules/semantic-ui-react/dist/es/views/Item/ItemExtra.js | mowbell/clickdelivery-fed-test | import _extends from 'babel-runtime/helpers/extends';
import _isNil from 'lodash/isNil';
import cx from 'classnames';
import PropTypes from 'prop-types';
import React from 'react';
import { createShorthandFactory, customPropTypes, getElementType, getUnhandledProps, META } from '../../lib';
/**
* An item can contain... |
examples/counter/index.js | tamascsaba/redux | import React from 'react';
import App from './containers/App';
React.render(
<App />,
document.getElementById('root')
);
|
src/routes/CreateB/components/index.js | bayun2/edict | import React from 'react';
import * as ReactRouter from 'react-router';
import fetch from 'isomorphic-fetch';
const {Link, browserHistory} = ReactRouter;
class CreateB extends React.Component {
constructor(props) {
super(props);
this.funcName = ['handleChange', 'sendEdict', 'replyEdict'];
this.funcName... |
src/admin/client/modules/orders/listHead/index.js | cezerin/cezerin | import React from 'react';
import { connect } from 'react-redux';
import { withRouter } from 'react-router';
import { fetchOrders, setFilter, deleteOrders, createOrder } from '../actions';
import Buttons from './components/buttons';
const mapStateToProps = (state, ownProps) => {
return {
search: state.orders.filter... |
meteor/RNApp/app/button.js | merxer/kata | import React from 'react'
import {
View,
Text,
TouchableOpacity,
StyleSheet
} from 'react-native';
export default React.createClass({
render() {
let { text, onPress } = this.props;
return (
<TouchableOpacity style={styles.button} onPress={onPress}>
<Text>{text}</Text>
</Touch... |
examples/src/components/States.js | DanielHeath/react-select | import React from 'react';
import Select from 'react-select';
const STATES = require('../data/states');
var StatesField = React.createClass({
displayName: 'StatesField',
propTypes: {
label: React.PropTypes.string,
searchable: React.PropTypes.bool,
},
getDefaultProps () {
return {
label: 'States:',
sea... |
src/components/Webcam/index.js | jmikrut/keen-2017 | import React, { Component } from 'react';
import { connect } from 'react-redux';
import './Webcam.css';
const mapStateToProps = (state) => ({
windowWidth: state.common.windowWidth,
windowHeight: state.common.windowHeight
});
class Webcam extends Component {
componentDidMount() {
const canvas = document.getElem... |
src/components/post/stories/row.js | JaspervRijbroek/JaspervRijbroek.github.io | import React from 'react';
import PostRow from "../row";
export default {
title: 'Components/Post/Row',
component: PostRow,
argTypes: {
isArchive: { control: 'boolean' },
},
args: {
standfirst: {
childMarkdownRemark: {
html: 'The first blog'
}... |
pages/api/drawer.js | AndriusBil/material-ui | // @flow
import React from 'react';
import withRoot from 'docs/src/modules/components/withRoot';
import MarkdownDocs from 'docs/src/modules/components/MarkdownDocs';
import markdown from './drawer.md';
function Page() {
return <MarkdownDocs markdown={markdown} />;
}
export default withRoot(Page);
|
src/App.js | crisisbox/crisisbox-io | import React from 'react'
import injectTapEventPlugin from 'react-tap-event-plugin';
import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider'
import Hero from './Components/Hero'
import HomeTabs from './Components/HomeTabs'
export default class App extends React.Component {
constructor(props) {
inject... |
plugins/nexus-coreui-plugin/src/frontend/src/components/pages/admin/ProprietaryRepositories/ProprietaryRepositoriesMachine.js | sonatype/nexus-public | /*
* Sonatype Nexus (TM) Open Source Version
* Copyright (c) 2008-present Sonatype, Inc.
* All rights reserved. Includes the third-party code listed at http://links.sonatype.com/products/nexus/oss/attributions.
*
* This program and the accompanying materials are made available under the terms of the Eclipse Public... |
src/index.js | instructure/canvas-planner | /*
* Copyright (C) 2017 - present Instructure, Inc.
*
* This file is part of Canvas.
*
* Canvas is free software: you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License as published by the Free
* Software Foundation, version 3 of the License.
*
* Canvas is distribut... |
src/components/Background/index.stories.js | ghrecommender/ghrecommender-frontend | import React from 'react'
import Background from './index'
const style = { backgroundColor: '#1b1c1d', width: '100%', height: '100%', position: 'absolute' }
export default {
title: 'Components|Background',
decorators: [story => <div style={style}>{story()}</div>],
component: Background,
}
export const backgro... |
client/containers/Project/Setting/ProjectMock/index.js | YMFE/yapi | import React, { Component } from 'react';
import { connect } from 'react-redux';
import PropTypes from 'prop-types';
import { Form, Switch, Button, Icon, Tooltip, message } from 'antd';
import AceEditor from '../../../../components/AceEditor/AceEditor';
const FormItem = Form.Item;
import { updateProjectMock, getProject... |
node_modules/react-icons/ti/social-github.js | bairrada97/festival |
import React from 'react'
import Icon from 'react-icon-base'
const TiSocialGithub = props => (
<Icon viewBox="0 0 40 40" {...props}>
<g><path d="m24.1 21.6c0.4 0 0.8 0.2 1.1 0.7 0.3 0.4 0.5 1 0.5 1.6 0 0.6-0.2 1.2-0.5 1.6-0.3 0.5-0.7 0.7-1.1 0.7-0.5 0-0.9-0.2-1.2-0.7-0.4-0.4-0.5-1-0.5-1.6 0-0.6 0.1-1.2 0.... |
src/containers/LoseBillAnalysis/ReasonAnalysis/LosePercentChart.js | UncleYee/crm-ui | import React from 'react';
import {mutilColors} from 'utils/mutilColors';
import Highcharts from 'highcharts';
const styles = {
root: {
marginTop: 10,
marginBottom: 10
},
graph: {
height: 450,
width: 950,
margin: '0 auto'
}
};
const getConfig = (months, data) => {
return {
credits: {... |
test/fixtures/export-default-dynamic-return-block/App.js | wyze/babel-plugin-transform-react-stateless-component-name | import React from 'react'
export default () => {
const loading = true
if ( loading ) {
return (
<h1>Loading...</h1>
)
} else {
return (
<h1>Hello!</h1>
)
}
}
|
resources/assets/pages/SignupIndex.js | DoSomething/rogue | import React from 'react';
import Shell from '../components/utilities/Shell';
import SignupsTable from '../components/SignupsTable';
const SignupIndex = () => {
const title = 'Signups';
document.title = title;
return (
<Shell title={title}>
<div className="container__block">
<SignupsTable />
... |
actor-apps/app-web/src/app/components/dialog/MessagesSection.react.js | tsdl2013/actor-platform | import React from 'react';
import _ from 'lodash';
import VisibilityStore from 'stores/VisibilityStore';
import MessageActionCreators from 'actions/MessageActionCreators';
import MessageItem from 'components/common/MessageItem.react';
let _delayed = [];
let flushDelayed = () => {
_.forEach(_delayed, (p) => {
... |
examples/05 Customize/Drop Effects/Container.js | hiddentao/react-dnd | import React, { Component } from 'react';
import { DragDropContext } from 'react-dnd';
import HTML5Backend from 'react-dnd/modules/backends/HTML5';
import SourceBox from './SourceBox';
import TargetBox from './TargetBox';
@DragDropContext(HTML5Backend)
export default class Container extends Component {
render() {
... |
app/components/hourlyPieChart.component.js | bryantwang1/react-weather | import React from 'react';
class HourlyPieChart extends React.Component {
fillGap(counter, rightSlices, leftSlices) {
if(this.props.data.length < 25) {
for(let idx = 0; idx < (25 - this.props.data.length); idx++) {
let divStyle = { backgroundColor: 'Beige', transform: 'rotate(0deg)' };
le... |
app/react-icons/fa/linkedin-square.js | scampersand/sonos-front | import React from 'react';
import IconBase from 'react-icon-base';
export default class FaLinkedinSquare extends React.Component {
render() {
return (
<IconBase viewBox="0 0 40 40" {...this.props}>
<g><path d="m8.3 31.6h5.1v-15.5h-5.1v15.5z m5.5-20.3q0-1.2-0.8-1.9t-2.1-0.8-2.1 0... |
client/src/containers/Home/index.js | martindavid/hackathon-starter | import React from 'react';
const Home = () => (
<div>
<h1 className="display-4">What are you going to build today?</h1>
<p className="lead">
A boilerplate for Node.js / ReactJS web applications.
</p>
<hr />
</div>
);
export default Home;
|
example/example-slack-message/src/SlackMessage.js | FaridSafi/react-native-gifted-chat | /* eslint-disable no-underscore-dangle, no-use-before-define */
import PropTypes from 'prop-types'
import React from 'react'
import { View, ViewPropTypes, StyleSheet } from 'react-native'
import { Avatar, Day, utils } from 'react-native-gifted-chat'
import Bubble from './SlackBubble'
const { isSameUser, isSameDay } ... |
src/Parser/VengeanceDemonHunter/CombatLogParser.js | mwwscott0/WoWAnalyzer | import React from 'react';
import SuggestionsTab from 'Main/SuggestionsTab';
import Tab from 'Main/Tab';
import Talents from 'Main/Talents';
import CoreCombatLogParser from 'Parser/Core/CombatLogParser';
import HealingDone from 'Parser/Core/Modules/HealingDone';
import DamageDone from 'Parser/Core/Modules/DamageDone'... |
demo/src/components/Switch/index.js | bkrem/react-d3-tree | import PropTypes from 'prop-types'
import React, { Component } from 'react';
import './styles.css';
class Input extends Component {
static propTypes = {
name: PropTypes.string.isRequired,
onChange: PropTypes.func.isRequired,
checked: PropTypes.bool.isRequired,
variable: PropTypes.object
};
rende... |
app/App.js | oneillci/egghead-react-app | // var React = require('react');
// var Router = require('react-router'); // installed via npm install --save react-router
// var routes = require('./config/routes');
import React from 'react';
import Router from 'react-router';
import routes from './config/routes';
Router.run(routes, function(Root) {
React.render(<... |
app/jsx/external_apps/components/ConfigurationFormManual.js | venturehive/canvas-lms | /*
* Copyright (C) 2014 - present Instructure, Inc.
*
* This file is part of Canvas.
*
* Canvas is free software: you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License as published by the Free
* Software Foundation, version 3 of the License.
*
* Canvas is distribut... |
src/pages/resume/components/projects/project/index.js | picchietti/picchietti.io | import React from 'react';
import PropTypes from 'prop-types';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import '../index.css';
function Project(props) {
return (
<a href={ props.link }>
<div styleName="project">
<div styleName="project-contents">
<FontAwesomeIcon... |
app/app.js | michiganhackers/website | /**
* app.js
*
* This is the entry file for the application, only setup and boilerplate
* code.
*/
import 'babel-polyfill';
/* eslint-disable import/no-unresolved, import/extensions */
// Load the manifest.json file and the .htaccess file
import '!file?name=[name].[ext]!./manifest.json';
import 'file?name=[name].... |
example/src/controlled.js | manufont/react-swipeable-bottom-sheet | import React from 'react';
import ReactDOM from 'react-dom';
import SwipeableBottomSheet from 'react-swipeable-bottom-sheet';
class App extends React.Component {
constructor(props){
super(props);
this.state = {
open: false
};
};
openBottomSheet(open){
this.setState({ open });
};
toggleBottomSheet(){... |
src/components/form/RegisterMachineForm.js | blockchain-IoT/blockchain-IoT-core | /* eslint-disable react/prop-types */
import React from 'react';
const registerMachineForm = props => (
<div className="uk-card uk-card-default uk-card-body">
<h3 className="uk-card-title">Register new Machine</h3>
<p>After creating MachineOwner contract you should be able to register new Machine</p>
<fo... |
docs/src/app/components/pages/components/Snackbar/Page.js | pomerantsev/material-ui | import React from 'react';
import Title from 'react-title-component';
import CodeExample from '../../../CodeExample';
import PropTypeDescription from '../../../PropTypeDescription';
import MarkdownElement from '../../../MarkdownElement';
import SnackbarReadmeText from './README';
import SnackbarExampleSimple from './... |
js/jqwidgets/demos/react/app/responsivepanel/integrationwithjqxmenu/app.js | luissancheza/sice | import React from 'react';
import ReactDOM from 'react-dom';
import JqxResponsivePanel from '../../../jqwidgets-react/react_jqxresponsivepanel.js';
import JqxPanel from '../../../jqwidgets-react/react_jqxpanel.js';
import JqxMenu from '../../../jqwidgets-react/react_jqxmenu.js';
import JqxButton from '../../../jqwidge... |
src/shared/components/join/join.js | miaket/operationcode_frontend | import React from 'react';
import Section from 'shared/components/section/section';
import LinkButton from 'shared/components/linkButton/linkButton';
import styles from './join.css';
const Join = (props) => {
const { ...otherProps } = props;
return (
<Section
title="Join Today!" {...otherProps}
cla... |
client/src/js/components/Overlay.js | Siddharth11/iTunes-Remote | // essentials
import React from 'react'
import { connect } from 'react-redux'
// actions
import toggleTracklistWindow from '../actions/toggleTracklistWindow'
import togglePlaylistWindow from '../actions/togglePlaylistWindow'
const Overlay = React.createClass({
getInitialState() {
return {
el... |
src/js/components/ui/TopLeftLink.js | nekuno/client | import PropTypes from 'prop-types';
import React, { Component } from 'react';
import shouldPureComponentUpdate from 'react-pure-render/function';
import RouterActionCreators from '../../actions/RouterActionCreators';
export default class TopLeftLink extends Component {
static contextTypes = {
router: PropTypes.obje... |
actor-apps/app-web/src/app/components/dialog/TypingSection.react.js | jiguoling/actor-platform | import React from 'react';
import { PureRenderMixin } from 'react/addons';
import classNames from 'classnames';
import DialogStore from 'stores/DialogStore';
export default React.createClass({
mixins: [PureRenderMixin],
getInitialState() {
return {
typing: null,
show: false
};
},
compon... |
sitedeo/src/Layout/Header/Header.js | jobportalcompunnel/bkcust | import React, { Component } from 'react';
import { BrowserRouter as Router, Switch, Route, Link } from 'react-router-dom';
import Home from '../../Home/Home';
import Pages from '../../Pages/Pages';
class Header extends Component {
render() {
return (
<div>
<nav className="navbar navbar-expand-lg navba... |
app/javascript/mastodon/features/directory/components/account_card.js | primenumber/mastodon | import React from 'react';
import ImmutablePureComponent from 'react-immutable-pure-component';
import ImmutablePropTypes from 'react-immutable-proptypes';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { makeGetAccount } from 'mastodon/selectors';
import Avatar from 'mastodon/compone... |
resume-app/src/components/Footer.js | robsonperassoli/robsonperassoli.github.io | import React from 'react'
import styled from 'styled-components'
const Container = styled.footer`
display: flex;
align-items: center;
justify-content: center;
padding-bottom: 1.5em;
`
function Footer() {
return (
<Container>
<a href='mailto:robsonperassoli@gmail.com'>
robsonperassoli@gmail... |
stories-src/EdgeLabelSample.js | dunnock/react-sigma | import React from 'react'
import { Sigma, RandomizeNodePositions, RelativeSize, EdgeShapes, ForceAtlas2 } from '../src/index';
class EdgeLabelSample extends React.Component {
render() {
let graph = {
nodes: [
{id: 'a', label: 'A'},
{id: 'b', label: 'B'},
{id: 'c', label: 'C'}
... |
src/modules/Listen/Listen.js | hdngr/mantenuto | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { updateUser } from 'modules/user/redux';
import Connecting from './components/Connecting';
import Preferences from './components/Preferences';
export class ListenComponent extends Component {... |
src/svg-icons/action/settings-overscan.js | nathanmarks/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionSettingsOverscan = (props) => (
<SvgIcon {...props}>
<path d="M12.01 5.5L10 8h4l-1.99-2.5zM18 10v4l2.5-1.99L18 10zM6 10l-2.5 2.01L6 14v-4zm8 6h-4l2.01 2.5L14 16zm7-13H3c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h18... |
9-React-crud/src/app/Modal.js | ekaaditiac/React-Basic-API | import React from 'react';
import Button from './Button';
class Modal extends React.Component {
constructor(props){
super(props);
this.state = {}
}
componentWillReceiveProps(nextProps){
if(nextProps.isOpen === true){
this.setState({
inputUsername : nextProps.dataEdit... |
src/components/common/mediaPicker/results/CollectionSearchResultsContainer.js | mitmedialab/MediaCloud-Web-Tools | import PropTypes from 'prop-types';
import React from 'react';
import { injectIntl, FormattedMessage } from 'react-intl';
import { connect } from 'react-redux';
import CollectionResultsTable from './CollectionResultsTable';
import MediaPickerSearchForm from '../MediaPickerSearchForm';
import { selectMediaPickerQueryArg... |
RestaurantList.js | maximveksler/EatWell | import React from 'react'
import Restaurant from './Restaurant'
import RestaurantModel from './RestaurantModel'
class RestaurantList extends React.Component {
constructor(props) {
super(props)
this.displayName = "RestaurantList"
this.state = {
selectedRestaurant : 0
}
}
handleSelectedResta... |
src/shared/element-react/dist/npm/es6/src/menu/MenuItem.js | thundernet8/Elune-WWW | import _classCallCheck from 'babel-runtime/helpers/classCallCheck';
import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';
import _inherits from 'babel-runtime/helpers/inherits';
import React from 'react';
import { PropTypes } from '../../libs';
import MixinComponent from './MixinCom... |
src/icons/SimCardAlertIcon.js | kiloe/ui | import React from 'react';
import Icon from '../Icon';
export default class SimCardAlertIcon extends Icon {
getSVG(){return <svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" viewBox="0 0 48 48"><path d="M36 4H20L8.05 16 8 40c0 2.2 1.8 4 4 4h24c2.2 0 4-1.8 4-4V8c0-2.2-1.8-4-4-4zM26 34h-4v-4h4v4zm0-8h-4V1... |
src/components/topic/media/MediaSearchContainer.js | mitmedialab/MediaCloud-Web-Tools | import PropTypes from 'prop-types';
import React from 'react';
import { connect } from 'react-redux';
import { injectIntl } from 'react-intl';
import { Grid, Row, Col } from 'react-flexbox-grid/lib';
import { push } from 'react-router-redux';
import SimpleSourceSearchContainer from '../../common/SimpleSourceSearchConta... |
app/components/Header/GrommetHeader.js | antoligy/healthbeacon | import React from 'react';
import {Link} from 'react-router';
import Header from 'grommet/components/Header';
import Title from 'grommet/components/Title';
import Menu from 'grommet/components/Menu';
import Anchor from 'grommet/components/Anchor';
import Favorite from 'grommet/components/icons/base/Favorite'
class Gro... |
src/hoc/withLive.js | philpl/react-live | import React, { Component } from 'react';
import LiveContext from '../components/Live/LiveContext';
export default function withLive(WrappedComponent) {
class WithLive extends Component {
render() {
return (
<LiveContext.Consumer>
{live => <WrappedComponent live={live} {...this.props} />}... |
src/index.js | Vasyl1989/Opus.ua | import 'babel-polyfill';
import React from 'react';
import { render } from 'react-dom';
import configureStore from './store/configureStore';
import {Router, browserHistory } from 'react-router';
import { Provider } from 'react-redux';
import routes from './routes';
require('./favicon.ico'); // Tell webpack to load f... |
src/components/Home/JuzList/index.js | korabh/quran.com-frontend | import React, { Component } from 'react';
import * as customPropTypes from 'customPropTypes';
import debug from 'helpers/debug';
import Link from 'react-router/lib/Link';
const styles = require('./styles.scss');
class JuzList extends Component {
renderJuz(juz) {
const { chapters } = this.props;
const juzzCh... |
app/auth/containers/AuthPage/SignupPage.js | in42/internship-portal | import React from 'react';
import _ from 'lodash';
import PropTypes from 'prop-types';
import { withRouter } from 'react-router-dom';
import SignupForm from '../../components/AuthPage/SignupForm';
class SignupPage extends React.Component {
constructor(props) {
super(props);
this.state = {
errors: {
... |
src/Backoffice/Tooltip/Tooltip.driver.js | skyiea/wix-style-react | import React from 'react';
import ReactTestUtils from 'react-dom/test-utils';
import ReactDOM from 'react-dom';
import Tooltip from './Tooltip';
import $ from 'jquery';
const tooltipDriverFactory = ({element, wrapper}) => {
const target = $(element).find('[data-hook=\'target\']').children(0)[0];
const tooltipInner... |
src/js/components/common/alert.js | michaelatmender/gui | import React from 'react';
const Alert = ({ children, className, severity, style }) => (
<div className={(className || '') + ' alert ' + (severity ? 'alert-' + severity : '')} style={style}>
{children}
</div>
);
export default Alert;
|
src/svg-icons/check-box.js | dsslimshaddy/material-ui | // @flow weak
import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../SvgIcon';
let CheckBox = props =>
<SvgIcon {...props}>
<path d="M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-9 14l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z" />
</SvgIcon>... |
node_modules/react-icons/fa/wpforms.js | bairrada97/festival |
import React from 'react'
import Icon from 'react-icon-base'
const FaWpforms = props => (
<Icon viewBox="0 0 40 40" {...props}>
<g><path d="m14.5 20.3v2.9h-5.6v-2.9h5.6z m0-5.7v2.9h-5.6v-2.9h5.6z m16.9 11.4v2.9h-7.6v-2.8h7.6z m0-5.7v2.9h-15v-2.9h15z m0-5.7v2.9h-15v-2.9h15z m3 19.2v-27.6q0-0.2-0.1-0.4t-0.3... |
packages/giu/src/inputs/iosFloatWrapper.js | guigrpa/giu | // @flow
import React from 'react';
import classnames from 'classnames';
import { stopPropagation } from '../gral/helpers';
import type { FloatPosition, FloatAlign } from '../components/floats';
type Props = {
children?: any,
floatPosition?: FloatPosition,
floatAlign?: FloatAlign,
};
const IosFloatWrapper = ({... |
examples/basic/src/components/WrappedButton/WrappedButton.js | sapegin/react-styleguidist | import React, { Component } from 'react';
import PropTypes from 'prop-types';
/**
* A button wrapped by a Decorator/Enhancer
*
* @version 1.0.1
* @author [Jeremy Gayed](https://github.com/tizmagik)
* @deprecated Use the [only true button](#button) instead
*/
const WrappedButton = ({ color, size, children }) => {... |
src/components/Header/Header.js | omelhoro/devshop-vtex | import React from 'react';
import {IndexLink, Link} from 'react-router';
import classes from './Header.css';
import {connect} from 'react-redux';
export const Header = props => (
<div className='text-center'>
<h1 className={classes.heading}>Developers Shop</h1>
<IndexLink to='/' className={classes.headerLin... |
src/index.js | karmapa17/garchen-panel | require('babel-polyfill');
require('font-awesome-sass-loader!./../assets/styles/font-awesome-sass.config.js');
import React from 'react';
import ReactDOM from 'react-dom';
import rootReducer from './redux/modules/reducer';
import thunk from 'redux-thunk';
import {Router, hashHistory} from 'react-router';
import {IntlP... |
modules/Router.js | taion/rrtr | import createHashHistory from 'history/lib/createHashHistory'
import useQueries from 'history/lib/useQueries'
import React from 'react'
import createTransitionManager from './createTransitionManager'
import { routes } from './PropTypes'
import RouterContext from './RouterContext'
import { createRoutes } from './RouteU... |
src/shared/views/map/MapRoute.js | in-depth/indepth-demo | import React from 'react'
import { MapTabs } from './index'
const mapsStorage = `${process.env.IMAGE_STORAGE_URL}/maps/demo`
const mapLevels = [
{
title: 'Level 1',
imageUrl: `${mapsStorage}/level1/level1.dzi`,
},
{
title: 'Level 2',
imageUrl: `${mapsStorage}/level2/level2.dzi`,
},
{
ti... |
docs/src/components/usage-example.js | adisuryadi/nuclear-js | import React from 'react'
import { Reactor, Store, toImmutable } from 'nuclear-js'
import Code from './code'
const storeCode = `import { Reactor, Store, toImmutable } from 'nuclear-js'
import React from 'react'
const reactor = new Reactor({ debug: true });
reactor.registerStores({
typeFilter: Store({
getInitia... |
Example/src/page/TabBar/TabBarItem/index.js | rnxteam/rnx-ui | /**
* TabBar item 组件
*/
import React from 'react';
import {
StyleSheet,
View,
Text,
} from 'react-native';
import PropTypes from 'prop-types';
import { Icon } from '../../../component';
const styles = StyleSheet.create({
all: {
flex: 1,
justifyContent: 'center',
alignItems: 'center',
},
icon... |
js/sabertoot.js | furgat/sabertoot | 'use strict';
import React from 'react';
import ReactDOM from 'react-dom';
import { Router, Route, IndexRoute, hashHistory } from 'react-router';
import Layout from './components/Layout';
import Index from './components/Pages/Index';
import Settings from './components/Pages/Settings';
import Timelines from './componen... |
src/index.js | nickgreengithub/mortgagecalc | import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from 'react-redux';
import { createStore } from 'redux';
import rootReducer from './ducks';
import App from './components/App';
import './index.css';
const store = createStore(rootReducer);
ReactDOM.render(
<Provider store={store}>
... |
src/LocationMessage/LocationMessage.js | abdurrahmanekr/react-chat-elements | import React, { Component } from 'react';
import './LocationMessage.css';
const classNames = require('classnames');
const STATIC_URL = 'https://maps.googleapis.com/maps/api/staticmap?markers=color:MARKER_COLOR|LATITUDE,LONGITUDE&zoom=ZOOM&size=270x200&scale=2&key=KEY';
const MAP_URL = 'https://www.google.com/maps/sea... |
src/loading.js | HsuTing/cat-components | 'use strict';
import React from 'react';
import PropTypes from 'prop-types';
import radium, {StyleRoot} from 'radium';
import * as d3 from 'd3';
import eases from 'eases';
import * as style from './style/loading';
export const loadingStyle = style;
@radium
export default class Loading extends React.Component {
st... |
src/components/form/error/index.js | rangle/react-redux-starter | import React from 'react';
import classNames from 'classnames';
function FormError({ children, isVisible, testid = 'form-error', ...props}) {
const formErrorClasses = classNames('bold', 'black', { 'hide': !isVisible });
return (
<div data-testid={testid} className={ formErrorClasses } {...props}>
{ chil... |
src/interface/common/DelayRender.js | ronaldpereira/WoWAnalyzer | import React from 'react';
import PropTypes from 'prop-types';
class DelayRender extends React.PureComponent {
static propTypes = {
delay: PropTypes.number.isRequired,
children: PropTypes.node.isRequired,
fallback: PropTypes.node,
};
state = {
timerExpired: false,
};
timer = null;
construc... |
client/src/components/Header/components/UserState.js | HKuz/FreeCodeCamp | import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { createSelector } from 'reselect';
import Spinner from 'react-spinkit';
import { isSignedInSelector, userFetchStateSelector } from '../../../redux';
import Login from './Login';
import SignedIn from './SignedI... |
src/svg-icons/hardware/videogame-asset.js | verdan/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let HardwareVideogameAsset = (props) => (
<SvgIcon {...props}>
<path d="M21 6H3c-1.1 0-2 .9-2 2v8c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-10 7H8v3H6v-3H3v-2h3V8h2v3h3v2zm4.5 2c-.83 0-1.5-.67-1.5-1.5s.67-... |
src/containers/ServerError.js | roybailey/research-react | import React, { Component } from 'react';
const styles={
root:{
textAlign:'center'
},
alert:{
fontSize:80,
fontWeight: 'bold',
color:'#e9ab2d'
}
};
class ServerError extends Component {
render() {
return (
<div style={styles.root}>
<div style={styles.alert}>⚠</div> {/... |
src/pages/404.js | ArturJS/ArturJS.github.io | import React from 'react'
import Layout from '../components/Layout'
const NotFoundPage = () => (
<Layout>
<div>
<h1>NOT FOUND</h1>
<p>You just hit a route that doesn't exist... the sadness.</p>
</div>
</Layout>
)
export default NotFoundPage
|
src/svg-icons/editor/format-quote.js | mtsandeep/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let EditorFormatQuote = (props) => (
<SvgIcon {...props}>
<path d="M6 17h3l2-4V7H5v6h3zm8 0h3l2-4V7h-6v6h3z"/>
</SvgIcon>
);
EditorFormatQuote = pure(EditorFormatQuote);
EditorFormatQuote.displayName = 'EditorFor... |
src/views/NotFoundView/NotFoundView.js | VinSpee/react-redux-postcss-boilerplate | import React from 'react';
import { Link } from 'react-router';
class NotFoundView extends React.Component {
render() {
return (
<div className="container text-center">
<h1>This is a demo 404 page!</h1>
<Link to="/">Back To Home View</Link>
</div>
);
}
}
export default NotFoundView;
|
web/src/components/About.js | jhonfredynova/Scaffolding-Nodejs-Reactjs | import React, { Component } from 'react';
import { FormattedMessage } from 'react-intl';
class About extends Component {
render() {
return (
<h1 className="text-center"><FormattedMessage id={ 'about' } /></h1>
);
}
}
export default About;
|
app/screens/containers/seller/quick-build-goods.js | yiyinsong/react-native-example-jdh | /**
* Component: 添加商品
* author: yiyinSong
* date: 2017-10-18
*/
import React, { Component } from 'react';
import {
Image,
ImageBackground,
Text,
View,
ScrollView,
TouchableOpacity,
TouchableHighlight,
TextInput,
InteractionManager,
DeviceEventEmitter,
Modal,
WebView,
Animated
} from 'rea... |
src/ButtonGroup.js | rapilabs/react-bootstrap | import React from 'react';
import classNames from 'classnames';
import BootstrapMixin from './BootstrapMixin';
import CustomPropTypes from './utils/CustomPropTypes';
const ButtonGroup = React.createClass({
mixins: [BootstrapMixin],
propTypes: {
vertical: React.PropTypes.bool,
justified: React.PropTypes.b... |
src/svg-icons/device/airplanemode-active.js | hai-cea/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let DeviceAirplanemodeActive = (props) => (
<SvgIcon {...props}>
<path d="M10.18 9"/><path d="M21 16v-2l-8-5V3.5c0-.83-.67-1.5-1.5-1.5S10 2.67 10 3.5V9l-8 5v2l8-2.5V19l-2 1.5V22l3.5-1 3.5 1v-1.5L13 19v-5.5l8 2.5z"/... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.