path stringlengths 5 195 | repo_name stringlengths 5 79 | content stringlengths 25 1.01M |
|---|---|---|
examples/timeline-airtable/src/main.js | weaintplastic/react-sketchapp | import React from 'react';
import PropTypes from 'prop-types';
import { render, Artboard, Text, View, StyleSheet } from 'react-sketchapp';
const API_ENDPOINT_URL =
'https://api.airtable.com/v0/appFs7J3WdgHYCDxD/Features?api_key=keyu4dudakWLI0vAh&&sort%5B0%5D%5Bfield%5D=Target+Launch+Date&sort%5B0%5D%5Bdirection%5D=a... |
src/components/auth/signup.js | RaulEscobarRivas/client | import React, { Component } from 'react';
import { reduxForm } from 'redux-form';
import * as actions from '../../actions';
class SignUp extends Component {
handleFormSubmit({ email, password }) {
this.props.signupUser(email, password);
}
renderErrorMessage(subject) {
return subject.touche... |
ios/versioned-react-native/ABI11_0_0/Libraries/Components/WebView/WebView.ios.js | jolicloud/exponent | /**
* Copyright (c) 2015-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.
*
* @provides... |
src/TPA/Button/Button.js | skyiea/wix-style-react | import React from 'react';
import {any, oneOf, string} from 'prop-types';
import omit from 'omit';
import classNames from 'classnames';
import WixComponent from '../../BaseComponents/WixComponent';
import tpaStyleInjector from '../TpaStyleInjector';
let styles = {locals: {}};
try {
styles = require('!css-loader?modu... |
app/src/components/Header/SubHeader.js | fikrimuhal/animated-potato | import React from 'react';
import styles from './style';
const SubHeader = ({children}) => {
return <h2 className={styles.tagline}>
{children.split(' ').map((word,idx) => {
const arr = word.split('');
return (<span key={idx}><strong>{arr.shift()}</strong>{arr.join('')} </span>);
})}
</h2>;
};
... |
src/App.js | liuli0803/myapp | import React, { Component } from 'react';
import './App.css';
import RouteMap from "./RouteMap";
class App extends Component {
render() {
return (
<div>
<RouteMap />
</div>
);
}
}
export default App;
|
form/AddressField.js | ExtPoint/yii2-frontend | import React from 'react';
import ReactDOM from 'react-dom';
import PropTypes from 'prop-types';
import {connect} from 'react-redux';
import {change, getFormInitialValues} from 'redux-form';
import {saveToCache} from 'extpoint-yii2/actions/formList';
import {view, resource, locale} from 'components';
import AddressHel... |
slides/the-speaker/components/AudienseLogo.js | javivelasco/scaffolding-react-apps-slides | import React from 'react';
const AudienseLogo = (props) => (
<svg viewBox="0 0 200 48" version="1.1" {...props}>
<g id="Page-1" stroke="none" strokeWidth="1" fill="none" fillRule="evenodd">
<g id="200-width" fill="#000000">
<path d="M18.134715,11.2025374 L23.9390953,11.2025374 L23.9390953,34.772932... |
client/js/components/ui/formik/Error.js | khlieng/name_pending | import React from 'react';
import { ErrorMessage } from 'formik';
const Error = props => (
<ErrorMessage component="div" className="form-error" {...props} />
);
export default Error;
|
sc/src/main/javascript/bundles/gene-search/src/GeneSearchRouter.js | gxa/atlas | import React from 'react'
import PropTypes from 'prop-types'
import { BrowserRouter, Route } from 'react-router-dom'
import GeneSearch from './GeneSearch'
const GeneSearchRouter = ({atlasUrl, basename}) =>
<BrowserRouter basename={basename}>
<Route
path={`/search`}
render={
({match, location... |
test/helpers/shallowRenderHelper.js | jezzasan/taproom-react | /**
* Function to get the shallow output for a given component
* As we are using phantom.js, we also need to include the fn.proto.bind shim!
*
* @see http://simonsmith.io/unit-testing-react-components-without-a-dom/
* @author somonsmith
*/
import React from 'react';
import TestUtils from 'react-addons-test-utils'... |
web/src/layout/leftpanel/zonelistpanel.js | corradio/electricitymap | import React from 'react';
import { useTranslation } from '../../helpers/translation';
import { dispatchApplication } from '../../store';
import SearchBar from '../../components/searchbar';
import ZoneList from '../../components/zonelist';
import InfoText from './infotext';
const documentSearchKeyUpHandler = (key, ... |
src/Page1.js | babizhu/webApp | /**
* Created by liu_k on 2015/11/24.
*/
import React, { Component } from 'react';
import { Icon,Menu, Breadcrumb,Affix } from 'antd';
const SubMenu = Menu.SubMenu;
import App from './App';
import styles from "./page1.css";
//import astyles1 from "./css/test.scss";
class Page1 extends Component {
render() {... |
app/common/routes.js | Kaniwani/KW-Frontend | import React from 'react';
import { Switch, Route, Redirect } from 'react-router-dom';
import { hasToken } from 'common/utils/auth';
import LandingPage from 'pages/LandingPage/Loadable';
import HomePage from 'pages/HomePage/Loadable';
import VocabLevelsPage from 'pages/VocabLevelsPage/Loadable';
import VocabLevelPage... |
packages/ringcentral-widgets-docs/src/app/pages/Components/TabNavigationView/Demo.js | ringcentral/ringcentral-js-widget | import React, { Component } from 'react';
// eslint-disable-next-line
import TabNavigationView from 'ringcentral-widgets/components/TabNavigationView';
import DialPadIcon from 'ringcentral-widgets/assets/images/DialPadNav.svg';
import CallsIcon from 'ringcentral-widgets/assets/images/Calls.svg';
import MessageIcon from... |
app/javascript/mastodon/features/ui/components/column_header.js | increments/mastodon | import React from 'react';
import PropTypes from 'prop-types';
import classNames from 'classnames';
export default class ColumnHeader extends React.PureComponent {
static propTypes = {
icon: PropTypes.string,
type: PropTypes.string,
active: PropTypes.bool,
onClick: PropTypes.func,
columnHeaderId... |
src/static/index.js | CRUDNS/CRUDNS | import React from 'react';
import ReactDOM from 'react-dom';
import { browserHistory } from 'react-router';
import { syncHistoryWithStore } from 'react-router-redux';
import Root from './containers/Root/Root';
import configureStore from './store/configureStore';
import { authLoginUserSuccess } from './actions/auth';
... |
src/Card.js | HJBowers/drunk-grenadier-120-Set-Game | import React, { Component } from 'react';
import './Card.css';
export default class Card extends Component {
constructor(props) {
super(props)
this.clickHandler = this.clickHandler.bind(this)
}
clickHandler() {
this.props.selectedCard(this.props)
}
render() {
return (
<div className... |
features/apimgt/org.wso2.carbon.apimgt.store.feature/src/main/resources/devportal/source/Tests/setupTests.js | jaadds/carbon-apimgt | /*
* Copyright (c) 2019, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
*
* WSO2 Inc. licenses this file to you 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/li... |
src/browser/app/Header.js | chad099/react-native-boilerplate | // @flow
import type { State, User } from '../../common/types';
import React from 'react';
import linksMessages from '../../common/app/linksMessages';
import { Box } from '../../common/components';
import { FormattedMessage } from 'react-intl';
import { Link } from '../components';
import { compose } from 'ramda';
impo... |
src/routes.js | andbet39/reactPress | import React from 'react';
import {IndexRoute, Route} from 'react-router';
import { isLoaded as isAuthLoaded, load as loadAuth } from 'redux/modules/auth';
import {
App,
Blog,
Chat,
Home,
Widgets,
About,
Login,
LoginSuccess,
Survey,
NotFound,
Posts,
Post,
} from 'contai... |
source/shared/components/message/index.js | gacosta89/knightsTour | import React from 'react';
const spanStyle = {
padding: 5
},
messageStyle = {
border: '3px solid',
fontSize: 35,
display: 'flex',
alignItems: 'center',
justifyContent: 'center',
borderRadius: 4,
margin: 5,
cursor: 'default'
},
successStyle = {
...messageStyle,
color: 'blue',
borderColor... |
dva/porsche-e3/src/routes/GuidePage.js | imuntil/React | import React from 'react'
// import PropTypes from 'prop-types'
import { connect } from 'dva'
import { Carousel } from 'antd-mobile'
import TopBanner from '../components/TopBanner'
import BottomBar from '../components/BottomBar'
import './GuidePage.scss'
const GuidePage = () => {
console.log('guide:')
return (
... |
client/src/app/admin/panel/staff/admin-panel-departments.js | ivandiazwm/opensupports | import React from 'react';
import _ from 'lodash';
import {connect} from 'react-redux';
import i18n from 'lib-app/i18n';
import API from 'lib-app/api-call';
import ConfigActions from 'actions/config-actions';
import AreYouSure from 'app-components/are-you-sure';
import DepartmentDropDown from 'app-components/departm... |
src/components/tweet/tweet_media.js | camboio/ibis | import React from 'react';
export default class TweetMedia extends React.Component {
renderMedia(){
const media = this.props.media.map((medium) =>{
// you should probably put a switch statement here when you need to handle other media types
// just sayin'
if(medium.type === 'photo')... |
app/containers/App.js | bird-system/bs-label-convertor | // @flow
import React, { Component } from 'react';
export default class App extends Component {
props: {
children: HTMLElement
};
render() {
return (
<div>
{this.props.children}
</div>
);
}
}
|
src/views/icons/ShieldCrossedIcon.js | physiii/open-automation | import React from 'react';
import IconBase from './IconBase.js';
export const ShieldCrossedIcon = (props) => (
<IconBase {...props} viewBox="0 0 20 20">
<path d="M1.9 1.3c.2-.2.5-.2.7 0l15.5 15.5c.2.2.2.5 0 .7-.2.2-.5.2-.7 0L1.8 1.9c-.3-.2.1-.6.1-.6zM14.7 17.3c-1.1 1-2.6 1.8-4.5 2.7h-.4c-8.3-3.5-8.1-8.2-7.7-15.2v-.... |
app/ui/src/components/NavbarCharacterInfo.js | pequalsnp/eve-isk-tracker | import React from 'react';
import { connect } from 'react-redux';
import {
gql,
graphql,
} from 'react-apollo';
import { withRouter } from 'react-router';
import { NavDropdown, Nav, MenuItem, NavItem } from 'react-bootstrap';
import Logout from './Logout';
const profileQuery = gql`
query ProfileQuery {
profil... |
layouts/Archive.js | ShashwatMittal/react-wordpress-theme | import React from 'react';
import {connect} from 'react-redux';
import PostList from '../components/PostList';
import {bindActionCreators} from 'redux';
import * as Actions from '../actions/actions';
import Header from '../components/Header';
import Sidebar from '../components/Sidebar';
import Footer from '../component... |
app/components/IssueIcon/index.js | mamaracas/MEventsRegistration | import React from 'react';
function IssueIcon(props) {
return (
<svg
height="1em"
width="0.875em"
className={props.className}
>
<path d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7S10.14 13.7 7 13.7 1.3 11.14 1.3 8s2.56-5.7 5.7-5.7m0-1.3C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7S10.86 1 7 1z m1 3H6v... |
src/snowflake.js | bartonhammond/snowflake | 'use strict'
/**
* # snowflake
* Snowflake 
*/
/**
* ## imports
*
*/
/**
* ### React
*
* Necessary components from ReactNative
*/
import React from 'react'
import {
AppRegistry,
StyleSh... |
packages/react-app/server/index.js | threepointone/glam | // @flow
import React from 'react';
const express = require('express');
import { renderToNodeStream } from 'react-dom/server';
import App from '../src/App';
const app = express();
app.get('/', (req, res) => {
// res.send('hello world');
//open tags
res.write(`<!doctype html>
<html>
<head>
<met... |
stargazer/assets/js/index.js | martynvandijke/Stargazer | //import App from './App';
import React from 'react';
import ReactDOM from 'react-dom';
import Split from './SplitApp';
ReactDOM.render(
<Split />,
document.getElementById('react-app')
);
/**
* Render the app to dom node
*
*
*/
|
src/encoded/static/components/cart/remove_multiple.js | ENCODE-DCC/encoded | /**
* Displays a button to remove a specific set of datasets from the cart.
*/
// node_modules
import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
// libs/ui
import { Modal, ModalHeader, ModalBody, ModalFooter } from '../../libs/ui/modal';
// components
import { hasTy... |
src/routes/register/index.js | nicolascine/site | /**
* React Starter Kit (https://www.reactstarterkit.com/)
*
* Copyright © 2014-present Kriasoft, LLC. All rights reserved.
*
* This source code is licensed under the MIT license found in the
* LICENSE.txt file in the root directory of this source tree.
*/
import React from 'react';
import Layout from '../../co... |
src/interface/icons/GitHubMarkSmall.js | fyruna/WoWAnalyzer | import React from 'react';
// From the GitHub branding website.
const Icon = ({ ...other }) => (
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1024 1000" className="icon" {...other}>
<path d="M512 0C229.25 0 0 229.25 0 512c0 226.25 146.688 418.125 350.156 485.812 25.594 4.688 34.938-11.125 34.938-24.625 0... |
src/shared/components/Footer.js | Grace951/ReactAU | import { contactData} from '../Data/ContactData';
import { PureList} from "./Shared/Shared";
import React from 'react';
const FooterContactDetail = (props) => (
<li className="">
<i className={props.iconClass} /> | {
(props.link)?( <a href={props.link}> <PureList da... |
src/svg-icons/action/settings-bluetooth.js | frnk94/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionSettingsBluetooth = (props) => (
<SvgIcon {...props}>
<path d="M11 24h2v-2h-2v2zm-4 0h2v-2H7v2zm8 0h2v-2h-2v2zm2.71-18.29L12 0h-1v7.59L6.41 3 5 4.41 10.59 10 5 15.59 6.41 17 11 12.41V20h1l5.71-5.71-4.3-4.... |
lib/FilterPaneSearch/FilterPaneSearch.js | folio-org/stripes-components | import React from 'react';
import PropTypes from 'prop-types';
import css from './FilterPaneSearch.css';
import Icon from '../Icon';
import FocusLink from '../FocusLink';
import IconButton from '../IconButton';
const propTypes = {
clearSearchId: PropTypes.string,
onChange: PropTypes.func,
onChangeIndex: PropType... |
src/browser/app/routeConfig.js | reedlaw/read-it | // @flow
import type { State } from '../../common/types';
import HttpError from 'found/lib/HttpError';
import React from 'react';
import queryFirebase from './queryFirebase';
import { makeRouteConfig, Route } from 'found/lib/jsx';
import { onUsersPresence } from '../../common/users/actions';
import { onLoadPosts, onLoa... |
packages/icons/src/md/hardware/KeyboardArrowDown.js | suitejs/suitejs | import React from 'react';
import IconBase from '@suitejs/icon-base';
function MdKeyboardArrowDown(props) {
return (
<IconBase viewBox="0 0 48 48" {...props}>
<polygon points="14.83 17 24 26.17 33.17 17 36 19.83 24 31.83 12 19.83" />
</IconBase>
);
}
export default MdKeyboardArrowDown;
|
client/src/app/components/ui/SmartNestable.js | zraees/sms-project | import React from 'react'
import {findDOMNode} from 'react-dom'
import 'script-loader!smartadmin-plugins/bower_components/jquery-nestable/jquery.nestable.js'
export default class SmartNestable extends React.Component {
componentDidMount() {
let element = $(findDOMNode(this))
let options = {};
if (th... |
src/svg-icons/action/speaker-notes-off.js | ngbrown/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionSpeakerNotesOff = (props) => (
<SvgIcon {...props}>
<path d="M10.54 11l-.54-.54L7.54 8 6 6.46 2.38 2.84 1.27 1.73 0 3l2.01 2.01L2 22l4-4h9l5.73 5.73L22 22.46 17.54 18l-7-7zM8 14H6v-2h2v2zm-2-3V9l2 2H6zm14... |
src/components/todo/index.js | rldona/taskfire | import React, { Component } from 'react';
import {
StyleSheet,
Text,
View
} from 'react-native';
import * as firebase from 'firebase';
import * as todoListService from '../../todolist.service';
import Checkbox from '../checkbox';
export default class Todo extends Component {
constructor(props, context) {
... |
src/containers/blankPage.js | EncontrAR/backoffice | import React, { Component } from 'react';
export default class extends Component {
render() {
return(<div className="isoLayoutContentWrapper" style={{height: "100vh"}}>
<div className="isoLayoutContent">
<h1>Blank Page</h1>
</div>
</div>);
}
};
|
build/server.js | IgorKilipenko/KTS_React | require("source-map-support").install();
module.exports =
/******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/
/******/ // Check if module is in cache
... |
components/MapModal.js | vaskort/react-native | import React, { Component } from 'react';
import { View, Text, Modal, StyleSheet} from 'react-native';
import MapView from 'react-native-maps';
import {Button, Icon} from 'react-native-elements';
import Promise from 'bluebird';
class MapModal extends React.Component {
state = {
firstTime: true,
region: {
... |
src/components/common/svg-icons/places/beach-access.js | abzfarah/Pearson.NAPLAN.GnomeH | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let PlacesBeachAccess = (props) => (
<SvgIcon {...props}>
<path d="M13.127 14.56l1.43-1.43 6.44 6.443L19.57 21zm4.293-5.73l2.86-2.86c-3.95-3.95-10.35-3.96-14.3-.02 3.93-1.3 8.31-.25 11.44 2.88zM5.95 5.98c-3.94 3.95... |
client/src/components/nav/NavLabel.js | JasonProcka/venos | import React from 'react';
export default class NavLabel extends React.Component {
render() {
return (
<li {...this.props} className="navLabel">{this.props.children}</li>
);
}
}
|
src/js/components/n-text.js | bradwoo8621/parrot2 | import React from 'react'
import ReactDOM from 'react-dom'
import jQuery from 'jquery'
import classnames from 'classnames'
let $ = jQuery;
import {Envs} from '../envs'
import {NComponent, NAddonComponent} from './n-component'
class NText extends NAddonComponent {
// lifecycle
postDidUpdate() {
let value = this.get... |
src/molecules/Breadcrumbs/breadcrumbs.stories.js | sjofartstidningen/bryggan | /* eslint-disable import/no-extraneous-dependencies */
import React, { Component } from 'react';
import { storiesOf } from '@storybook/react';
import Breadcrumbs from './index';
class Wrapper extends Component<*, *> {
state = {
path: '/blog/2018/123456',
};
routes = [
{ path: '/:root', title: ({ root })... |
old/view/indexOld.js | bburns/neomem | import React from 'react'
import ReactDOM from 'react-dom'
import App from './components/App'
ReactDOM.render(<App />, document.getElementById('root'))
|
client/components/organisms/ConfirmModal/ConfirmModal.js | djizco/boilerplate-react | import React from 'react';
import PropTypes from 'prop-types';
import Modal from 'react-bulma-companion/lib/Modal';
import ConfirmDeleteTodo from '_organisms/ConfirmDeleteTodo';
export default function ConfirmModal({ confirm, closeModal, deleteTodo }) {
return (
<Modal className="confirm-modal" active={confirm... |
sandbox-react-redux/src/components/pages/PageBar.js | ohtomi/sandbox | import React from 'react'
import HeaderContainer from '../organisms/HeaderContainer'
import CountContainer from '../organisms/CountContainer'
import CalcContainer from '../organisms/CalcContainer'
import Link from '../atoms/Link'
const PageBar = ({ state: { misc: { locked }, routing: { pathname } }, actions }) => {
... |
src/svg-icons/action/android.js | hai-cea/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionAndroid = (props) => (
<SvgIcon {...props}>
<path d="M6 18c0 .55.45 1 1 1h1v3.5c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5V19h2v3.5c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5V19h1c.55 0 1-.45 1-1V8H6v10zM3.5 8C2.67 8... |
src/main/ScrollBox.js | smikhalevski/react-scroll-box | import React from 'react';
import {GenericScrollBox} from './GenericScrollBox';
export class ScrollBox extends React.Component {
render() {
return (
<GenericScrollBox {...this.props}>
<div className="scroll-box__viewport">
{this.props.children}
</div>
</GenericScrollBox>
... |
examples/real-world/index.js | javascriptjedi/redux-select | import 'babel-polyfill'
import React from 'react'
import { render } from 'react-dom'
import { browserHistory } from 'react-router'
import { syncHistoryWithStore } from 'react-router-redux'
import Root from './containers/Root'
import configureStore from './store/configureStore'
const store = configureStore()
const hist... |
src/js/components/tests/editor-row-textbook-modal.js | daniel-madera/pijs | import React from 'react'
import { observer, inject } from 'mobx-react'
import { Modal, FormControl, FormGroup, Button, Form, ListGroup, ListGroupItem } from 'react-bootstrap'
import { SimpleInput } from '../others/form'
import { SimpleList } from '../others/lists'
@inject('testStore', 'textbookPublicStore', 'textbo... |
client/src/adventures/Adventures.js | petertrotman/adventurelookup | import React from 'react';
const Adventures = () => (
<div>
<h2>Adventures</h2>
<p>Getting this continuously deployed was a mini adventure :-D</p>
</div>
);
export default Adventures;
|
blog-post-4/src/www/js/components/demo-table.js | training4developers/react-flux-blog | 'use strict';
import React from 'react'; // eslint-disable-line no-unused-vars
import DemoRow from './demo-row'; // eslint-disable-line no-unused-vars
export default (props) => <table className='table table-striped'>
<thead>
<tr>
<th>Name</th>
<th>Description</th>
<th>Link</th>
</tr>
</thead>
<tbody>
... |
text-dream/webapp/src/components/cards/LayersComponent.js | PAIR-code/interpretability | /**
* @license
* Copyright 2018 Google LLC. All Rights Reserved.
* 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 a... |
pages/counter.js | abhilashsajeev/shopping-cart-universal | import React from 'react';
import { store } from '../redux/store';
import { Counter } from '../components/Counter';
import { addNewCounter, removeCounter, incrementCounter, decrementCounter } from '../redux/actions/counterActions';
import { connectWithStore } from '../redux/connectWithStore';
import Layout from '../com... |
src/components/Footer/index.js | westoncolemanl/tabbr-web | import React from 'react'
import Responsive from 'react-responsive'
import LargeFooter from './LargeFooter'
import SmallFooter from './SmallFooter'
export default () =>
<div>
<Responsive
minWidth={961}
>
<LargeFooter />
</Responsive>
<Responsive
maxWidth={960}
minWidth={601}
... |
node_modules/semantic-ui-react/dist/es/elements/Step/StepTitle.js | SuperUncleCat/ServerMonitoring | import _extends from 'babel-runtime/helpers/extends';
import cx from 'classnames';
import PropTypes from 'prop-types';
import React from 'react';
import { childrenUtils, customPropTypes, getElementType, getUnhandledProps, META } from '../../lib';
/**
* A step can contain a title.
*/
function StepTitle(props) {
va... |
src/components/main.js | sourabh-garg/react-starter-kit | import React from 'react';
import {connect} from 'react-redux';
import Navbar from './CommonComponent/Navbar/navbar';
import Footer from './CommonComponent/Footer/footer';
class Main extends React.Component {
constructor(props) {
super(props);
}
render() {
return (
<div className="container"... |
lib/index.js | openstardrive/flight-director | import React from 'react'
import { createStore, applyMiddleware } from 'redux'
import thunk from 'redux-thunk'
import { render } from 'react-dom'
import { Provider } from 'react-redux'
import reducer from './station/reducer'
import Station from './station'
require('./index.css')
let createStoreWithThunks ... |
app/javascript/mastodon/features/account_timeline/index.js | amazedkoumei/mastodon | import React from 'react';
import { connect } from 'react-redux';
import ImmutablePropTypes from 'react-immutable-proptypes';
import PropTypes from 'prop-types';
import { fetchAccount } from '../../actions/accounts';
import { expandAccountFeaturedTimeline, expandAccountTimeline } from '../../actions/timelines';
import ... |
docs/src/app/components/pages/components/Snackbar/Page.js | hai-cea/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 './... |
packages/components/src/List/ListComposition.stories.js | Talend/ui | import React from 'react';
import { action } from '@storybook/addon-actions';
import { simpleCollection } from './ListComposition/collection';
import ActionBar from '../ActionBar';
import List from '.';
const titleProps = rowData => ({
onClick: action('onTitleClick'),
'data-feature': `list.item.title.${rowData.id}`... |
src/components/Widgets/UnknownPreview.js | radekzz/netlify-cms-test | import React from 'react';
import ImmutablePropTypes from 'react-immutable-proptypes';
import previewStyle from './defaultPreviewStyle';
export default function UnknownPreview({ field }) {
return <div style={previewStyle}>No preview for widget “{field.get('widget')}”.</div>;
}
UnknownPreview.propTypes = {
field: ... |
packages/react-router-native/examples/BasicExample.js | d-oliveros/react-router | import React from 'react'
import { StyleSheet, Text, View } from 'react-native'
import { NativeRouter, Route, Link } from 'react-router-native'
const Home = () => (
<Text style={styles.header}>
Home
</Text>
)
const About = () => (
<Text style={styles.header}>
About
</Text>
)
const Topic = ({ match })... |
js/components/LoadingIndicator.react.js | kkka/asd | /**
* LoadingIndicator.react.js
*
* A loading indicator, copied from https://github.com/tobiasahlin/SpinKit
*
*/
import React from 'react';
// Since this component doesn't need any state, make it a stateless component
function LoadingIndicator() {
return (
<div>Loading
<div className="sk-fading-circl... |
examples/index.android.js | mayuur/react-native-callout | /**
* Sample React Native App
* https://github.com/facebook/react-native
* @flow
*/
import React, { Component } from 'react';
import {
AppRegistry,
StyleSheet,
Text,
TouchableHighlight,
Animated,
View,
Dimensions,
} from 'react-native';
let { screenWidth, screenHeight } = Dimensions.get('window')
va... |
www/imports/component/Namer.js | ucscHexmap/hexagram |
// Namer.js
// A modal to prompt the user to name something.
// If you want something more complex use Modal.js instead.
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import Modal from './Modal.js';
export default class Namer extends Component {
constructor (props) {
supe... |
src/Fade.js | cgvarela/react-bootstrap | import React from 'react';
import Transition from 'react-overlays/lib/Transition';
import CustomPropTypes from './utils/CustomPropTypes';
import deprecationWarning from './utils/deprecationWarning';
class Fade extends React.Component {
render() {
let timeout = this.props.timeout || this.props.duration;
retu... |
src/modules/pages/PushLeft.js | lenxeon/react | require('../../css/drawer.less')
import React from 'react';
const ReactPropTypes = React.PropTypes;
class Drawer extends React.Component {
constructor(props) {
super(props);
this.state = {
open: props.open
};
this.props.width = 600;
}
state: {
}
componentWillUpdate() {}
compo... |
examples/esp-chat-react-es6/js/app.js | raybooysen/esp-js | import esp from 'esp-js'
import espDevTools from 'esp-js-devtools';
import React from 'react';
import ReactDOM from 'react-dom';
import model from './model';
import components from './components';
import services from './services';
// export for http://fb.me/react-devtools
window.React = React;
espDevTools.registerDe... |
src/parser/priest/shadow/modules/spells/VoidformsTab.js | ronaldpereira/WoWAnalyzer | import React from 'react';
import PropTypes from 'prop-types';
import VoidformGraph from './VoidformGraph';
const VoidformsTab = ({ voidforms = [], insanityEvents, ...modules }) => {
if (voidforms.length === 0) {
return null;
}
return (
<div className="voidforms">
{voidforms.map((voidform, i) => ... |
packages/mineral-ui-icons/src/IconLocalDrink.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 IconLocalDrink(props: IconProps) {
const iconProps = {
rtl: false,
...props
};
return (
<Icon {...iconPro... |
kit/lib/routing.js | Mahi22/MedTantra | /* eslint-disable no-param-reassign */
// ----------------------
// IMPORTS
import React from 'react';
import PropTypes from 'prop-types';
import { Route, Redirect as ReactRouterRedirect } from 'react-router-dom';
// ----------------------
// <Status code="xxx"> component. Updates the context router's context, wh... |
src/views/components/ThermostatCard.js | physiii/open-automation | import React from 'react';
import PropTypes from 'prop-types';
import ServiceCardBase from './ServiceCardBase.js';
import {connect} from 'react-redux';
import './ThermostatCard.css';
export class ThermostatCard extends React.Component {
constructor (props) {
super(props);
const temp = this.props.service.state.ge... |
project-my-demos/src/downloadList/views/downloadList.js | renhongl/Summary |
import React from 'react';
import Card from 'antd/lib/card';
import Icon from 'antd/lib/icon';
import '../style.css';
import Tooltip from 'antd/lib/tooltip';
const downloadList = [
{
title: '爱听播放器',
url: 'https://renhongl.github.io/other/AiTing.zip',
desc: '一个简洁、好看、功能丰富的播放器,相当于音乐播放器和听书软件的... |
src/svg-icons/action/http.js | xmityaz/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionHttp = (props) => (
<SvgIcon {...props}>
<path d="M4.5 11h-2V9H1v6h1.5v-2.5h2V15H6V9H4.5v2zm2.5-.5h1.5V15H10v-4.5h1.5V9H7v1.5zm5.5 0H14V15h1.5v-4.5H17V9h-4.5v1.5zm9-1.5H18v6h1.5v-2h2c.8 0 1.5-.7 1.5-1.5v-... |
src/components/data/DataCreator.js | dherault/Oso | import React from 'react';
import { connect } from 'react-redux';
import definitions from '../../models/';
import ac from '../../state/actionCreators';
import { capitalize } from '../../utils/text';
class DataCreator extends React.Component {
constructor() {
super();
const inputs = {};
const modelLis... |
src/docs/layout/DocumentComponent.js | reactstrap/component-template | import React from 'react';
import { PrismCode } from 'react-prism';
import { dedent } from 'dentist';
const DocumentProptypes = (props) => {
const {
name,
proptypes
} = props.component;
return (
<div className="docs-component-props mt-5">
<h3>{name} - PropTypes</h3>
<pre>
<PrismCo... |
src/icons/AndroidArrowDown.js | fbfeix/react-icons | import React from 'react';
import IconBase from './../components/IconBase/IconBase';
export default class AndroidArrowDown extends React.Component {
render() {
if(this.props.bare) {
return <g>
<g id="Icon_8_">
<g>
<path d="M277.375,85v259.704l119.702-119.702L427,256L256,427L85,256l29.924-29.922l119.701,118.626... |
rest-ui-scripts/fixtures/kitchensink/src/features/webpack/SvgInclusion.js | RestUI/create-rest-ui-app | /**
* Copyright (c) 2015-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.
*/
import Rea... |
node_modules/babel-plugin-react-transform/test/fixtures/code-ignore/actual.js | vinicius-ov/Livefy | import React from 'react';
const First = React.createNotClass({
displayName: 'First'
});
class Second extends React.NotComponent {}
|
projects/starter/src/index.js | ebemunk/blog | import React from 'react'
import ReactDOM from 'react-dom'
import 'react-vis/dist/style.css'
const render = (component, selector) =>
ReactDOM.render(component, document.querySelector(selector))
import A from './A'
render(<A />, '#hi')
|
packages/javascript/reactjs/react-getstart/react-contact-manager/src/components/contact-card.js | sharkspeed/dororis | // src/components/contact-card.js
import React from 'react'
import { Link } from 'react-router-dom'
import PropTypes from 'prop-types' // React v15+ 挪到额外模块中了
import { Card, Button, Icon } from 'semantic-ui-react'
import { deleteContact } from '../actions/contact-actions'
class ContactCard extends React.Component {
... |
examples/js/basic/borderless-table.js | AllenFang/react-bootstrap-table | /* eslint max-len: 0 */
import React from 'react';
import { BootstrapTable, TableHeaderColumn } from 'react-bootstrap-table';
const products = [];
function addProducts(quantity) {
const startId = products.length;
for (let i = 0; i < quantity; i++) {
const id = startId + i;
products.push({
id: id,
... |
docs/src/app/components/pages/components/Slider/ExampleStep.js | lawrence-yu/material-ui | import React from 'react';
import Slider from 'material-ui/Slider';
/**
* By default, the slider is continuous.
* The `step` property causes the slider to move in discrete increments.
*/
const SliderExampleStep = () => (
<Slider step={0.10} value={0.5} />
);
export default SliderExampleStep;
|
src/svg-icons/notification/confirmation-number.js | tan-jerene/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let NotificationConfirmationNumber = (props) => (
<SvgIcon {...props}>
<path d="M22 10V6c0-1.11-.9-2-2-2H4c-1.1 0-1.99.89-1.99 2v4c1.1 0 1.99.9 1.99 2s-.89 2-2 2v4c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2v-4c-1.1 0-2-.9-2-2... |
rest-ui-scripts/template/src/resources/Post/crud/list/Filter.js | RestUI/create-rest-ui-app | import React from 'react';
import { Filter as CrudFilter, TextInput } from 'rest-ui/lib/mui';
import { translate } from 'rest-ui';
import Chip from 'material-ui/Chip';
const QuickFilter = translate(({ label, translate }) => <Chip style={{ marginBottom: 8 }}>{translate(label)}</Chip>);
const Filter = ({ ...props }) =>... |
src/svg-icons/communication/import-contacts.js | nathanmarks/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let CommunicationImportContacts = (props) => (
<SvgIcon {...props}>
<path d="M21 5c-1.11-.35-2.33-.5-3.5-.5-1.95 0-4.05.4-5.5 1.5-1.45-1.1-3.55-1.5-5.5-1.5S2.45 4.9 1 6v14.65c0 .25.25.5.5.5.1 0 .15-.05.25-.05C3.1 2... |
src/routes/index.js | dfalling/todo | import React from 'react';
import { Route, IndexRoute, Redirect } from 'react-router';
// NOTE: here we're making use of the `resolve.root` configuration
// option in webpack, which allows us to specify import paths as if
// they were from the root of the ~/src directory. This makes it
// very easy to navigate to file... |
app/components/Info/index.js | anthonyjillions/anthonyjillions | import React from 'react';
import Icon from '../Icon';
import styles from './styles.css';
export default function Info() {
const list = [
'MERN stack dev',
'3rd party API integrations',
'Custom JS/CSS/HTML for tools like Tumblr, Shopify, Square etc.',
];
const list1 = [
'Full service music produc... |
src/ActivitySwitcher.js | siiptuo/tiima-spa | import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { startActivity } from './actions';
import * as activity from './activity';
export class ActivitySwitcher extends React.Component {
static propTypes = {
onActivityStart: PropTypes.func.isRequired,
lo... |
pages/blog/test-article-one.js | b1alpha/sdj | /**
* React Static Boilerplate
* https://github.com/koistya/react-static-boilerplate
* Copyright (c) Konstantin Tarkus (@koistya) | MIT license
*/
import React, { Component } from 'react';
export default class extends Component {
render() {
return (
<div>
<h1>Test Article 1</h1>
<p>Co... |
react/react-hn2/src/ItemList/ItemList.js | weaponhe/weaponhe.github.io | import React from 'react'
import PropTypes from 'prop-types'
import querystring from 'querystring'
import ItemStore from '../store/itemStore'
import Item from './Item'
import Spinner from '../Spinner/Spinner'
import Pager from '../pager/pager'
import './ItemList.css'
export default class ItemList extends React.Compon... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.