path stringlengths 5 195 | repo_name stringlengths 5 79 | content stringlengths 25 1.01M |
|---|---|---|
react-router-demo/lessons/13-server-rendering/modules/Repo.js | zhangjunhd/react-examples | import React from 'react'
export default React.createClass({
render() {
const { userName, repoName } = this.props.params
return (
<div>
<h2>{userName} / {repoName}</h2>
</div>
)
}
})
|
app/components/slide_up_panel/slide_up_panel_indicator.js | mattermost/mattermost-mobile | // Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import React from 'react';
import {Animated, Platform, StyleSheet, View} from 'react-native';
export default function slideUpPanelIndicator() {
if (Platform.OS === 'android') {
return null;
... |
app/components/newAppDialog.js | JustinBeckwith/trebuchet | import React from 'react';
import Dialog from 'material-ui/Dialog';
import FlatButton from 'material-ui/FlatButton';
import RaisedButton from 'material-ui/RaisedButton';
import TextField from 'material-ui/TextField';
import SelectField from 'material-ui/SelectField';
import MenuItem from 'material-ui/MenuItem';
import ... |
src/components/buttons/demos/Icon.js | isogon/material-components | import React from 'react'
import { Button, Icon } from '../../../'
export default () => (
<Button icon>
<Icon name="add" />
</Button>
)
|
src/desktop/apps/consign/components/submission_flow/index.js | kanaabe/force | import PropTypes from 'prop-types'
import React from 'react'
import _StepMarker from '../step_marker'
import block from 'bem-cn-lite'
import _stepsConfig from '../../client/steps_config'
import { connect } from 'react-redux'
import {
resizeWindow
} from '../../client/actions'
// FIXME: Rewire
let StepMarker = _StepM... |
src/templates/allTagsIndex.js | gvlachos/gvlachos.github.io | import React from 'react';
import {Link} from 'gatsby';
export default ({data, pageContext}) => {
const {tags} = pageContext;
return (
<div style={{fontFamily: 'avenir'}}>
<div>
<ul>
{tags.map((tagName, index) => {
return (
<li key={index}>
<Lin... |
src/components/Containers.react.js | virajkanwade/kitematic | import $ from 'jquery';
import _ from 'underscore';
import React from 'react';
import Router from 'react-router';
import containerStore from '../stores/ContainerStore';
import ContainerList from './ContainerList.react';
import Header from './Header.react';
import metrics from '../utils/MetricsUtil';
import shell from '... |
node_modules/react-native/Libraries/Utilities/throwOnWrongReactAPI.js | ninamanalo19/react-native-sliding-up-panel | /**
* 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/common/lib/redux-firebase/firebase.js | robinpokorny/este | // @flow
import * as actions from './actions';
import React from 'react';
// // Example
// OnlineUsers = firebase((database, props) => {
// const usersPresenceRef = database.child('users-presence');
// return [
// [usersPresenceRef, 'on', 'value', props.onUsersPresence],
// ]
// })(OnlineUsers);
type Query ... |
src/components/KeyDetails.js | cpsubrian/redis-explorer | import React from 'react'
import pureRender from 'pure-render-decorator'
import ImmutablePropTypes from 'react-immutable-proptypes'
import HashDetails from '../components/details/HashDetails'
import ListDetails from '../components/details/ListDetails'
import SetDetails from '../components/details/SetDetails'
import Sor... |
docs/src/app/components/pages/components/IconMenu/ExampleSimple.js | ruifortes/material-ui | import React from 'react';
import IconMenu from 'material-ui/IconMenu';
import MenuItem from 'material-ui/MenuItem';
import IconButton from 'material-ui/IconButton/IconButton';
import MoreVertIcon from 'material-ui/svg-icons/navigation/more-vert';
const IconMenuExampleSimple = () => (
<div>
<IconMenu
iconB... |
src/components/molecules/IconButton/index.stories.js | DimensionLab/narc | import React from 'react'
import { storiesOf } from '@storybook/react'
import { IconButton } from 'components'
storiesOf('IconButton', module)
.add('default', () => (
<IconButton icon="close">Hello</IconButton>
))
.add('transparent', () => (
<IconButton icon="close" transparent>Hello</IconButton>
))
... |
node_modules/@expo/vector-icons/website/src/index.js | jasonlarue/react-native-flashcards | import React from 'react';
import ReactDOM from 'react-dom';
import App from './App';
import './index.css';
ReactDOM.render(<App />, document.getElementById('root'));
|
src/svg-icons/maps/transfer-within-a-station.js | jacklam718/react-svg-iconx | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let MapsTransferWithinAStation = (props) => (
<SvgIcon {...props}>
<path d="M16.49 15.5v-1.75L14 16.25l2.49 2.5V17H22v-1.5zm3.02 4.25H14v1.5h5.51V23L22 20.5 19.51 18zM9.5 5.5c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 ... |
src/index.js | shawnzhang009/react-starter | import { AppContainer } from 'react-hot-loader';
import React from 'react'
import ReactDOM from 'react-dom'
import App from './components/App'
import injectTapEventPlugin from 'react-tap-event-plugin'
injectTapEventPlugin()
ReactDOM.render(
<div>
<App />
</div>,
document.getElementById('main')
)
if (modul... |
Hebrides/SmartHome/Me/HeaderCell.js | HarrisLee/React-Native-Express | /**
* Sample React Native App
* https://github.com/facebook/react-native
* @flow
*/
import React, { Component } from 'react';
import {
StyleSheet,
View,
Text,
Image,
TouchableHighlight,
PixelRatio
} from 'react-native';
import Constant from '../Global/Constant.js';
export default class He... |
app/javascript/mastodon/features/ui/components/drawer_loading.js | koba-lab/mastodon | import React from 'react';
const DrawerLoading = () => (
<div className='drawer'>
<div className='drawer__pager'>
<div className='drawer__inner' />
</div>
</div>
);
export default DrawerLoading;
|
src/components/FolderButton.js | feedreaderco/web | import React, { Component } from 'react';
export default class FolderButton extends Component {
constructor(props) {
super(props);
let className = 'pillbox empty';
if (this.props.folders.indexOf(this.props.folder) !== -1) {
className = 'pillbox';
}
this.state = { className };
}
onClick... |
src/main/webapp/resources/modules/lobby/CreateGameDialog/CreateGameDialog.js | cwoolner/flex-poker | import React from 'react'
import Button from 'react-bootstrap/Button'
import Modal from 'react-bootstrap/Modal'
import Form from 'react-bootstrap/Form'
export default ({showModal, hideDialogCallback, submitFormCallback}) => {
return (
<Modal size="sm" show={showModal} onHide={hideDialogCallback}>
<Modal.Hea... |
src/svg-icons/image/palette.js | xmityaz/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImagePalette = (props) => (
<SvgIcon {...props}>
<path d="M12 3c-4.97 0-9 4.03-9 9s4.03 9 9 9c.83 0 1.5-.67 1.5-1.5 0-.39-.15-.74-.39-1.01-.23-.26-.38-.61-.38-.99 0-.83.67-1.5 1.5-1.5H16c2.76 0 5-2.24 5-5 0-4.4... |
maodou/events/client/components/events.js | ShannChiang/meteor-react-redux-base | import React from 'react';
import {Link} from 'react-router';
import moment from 'moment';
import Loading from 'client/components/common/loading';
export default (props) => {
const T = props.context.T;
return (
<div className="container" style={{ paddingTop: '60px'}}>
<div className="row">
{
... |
src/components/containers/Header/Header.js | PulseTile/PulseTile-React | import React from 'react';
import { Switch, Route } from 'react-router-dom'
import HeaderToolbar from './HeaderToolbar/HeaderToolbar';
import HeaderTitle from './HeaderTitle/HeaderTitle';
import { clientUrls } from '../../../config/client-urls.constants'
import { routersPluginConfig } from '../../../plugins.config';
... |
react/src/components/FileHoverButtons/index.js | sinfin/folio | import React from 'react'
const FileHoverButtons = ({ destroy, edit, onDestroy, onEdit }) => {
return (
<React.Fragment>
{destroy && (
<button
type='button'
className='f-c-file-list__file-btn f-c-file-list__file-btn--destroy btn btn-danger fa fa-times'
onClick={(e) => ... |
src/index.js | cichy/redux-login | import React from 'react'
import ReactDOM from 'react-dom'
import createStore from './store/createStore'
import 'normalize.css'
import './styles/main.scss'
// Store Initialization
// ------------------------------------
const store = createStore(window.__INITIAL_STATE__)
// Render Setup
// ---------------------------... |
admin/client/App/index.js | cermati/keystone | /**
* This is the main entry file, which we compile the main JS bundle from. It
* only contains the client side routing setup.
*/
// Needed for ES6 generators (redux-saga) to work
import 'babel-polyfill';
import React from 'react';
import ReactDOM from 'react-dom';
import { Router, Route, browserHistory, IndexRoute... |
common/components/ide/panels/ProcessPanel.js | ebertmi/webbox | import React from 'react';
import Terminal from '../Terminal';
import optionManager from '../../../models/options';
const bell = new Audio('/public/audio/bell.ogg');
export default class ProcessPanel extends React.Component {
constructor(props) {
super(props);
this.onChangeOption = this.onChangeOption.bind... |
src/icons/CloseIcon.js | kiloe/ui | import React from 'react';
import Icon from '../Icon';
export default class CloseIcon extends Icon {
getSVG(){return <svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" viewBox="0 0 48 48"><path d="M38 12.83L35.17 10 24 21.17 12.83 10 10 12.83 21.17 24 10 35.17 12.83 38 24 26.83 35.17 38 38 35.17 26.83 24... |
client/index.js | alan-jordan/gamr-v2 | import React from 'react'
import {render} from 'react-dom'
import {Provider} from 'react-redux'
import store from './store'
import App from './components/App'
document.addEventListener('DOMContentLoaded', () => {
render(
<Provider store={store}>
<App />
</Provider>,
document.getElementById('app')
... |
react/features/video-menu/components/native/MuteEveryonesVideoDialog.js | jitsi/jitsi-meet | // @flow
import React from 'react';
import Dialog from 'react-native-dialog';
import { Divider } from 'react-native-paper';
import { ColorSchemeRegistry } from '../../../base/color-scheme';
import { ConfirmDialog } from '../../../base/dialog';
import { translate } from '../../../base/i18n';
import { connect } from '.... |
src/components/ServerListItem.react.js | bygloam/desktop | import React from 'react';
import RetinaImage from 'react-retina-image';
var SingleValue = React.createClass({
propTypes: {
placeholder: React.PropTypes.string,
value: React.PropTypes.object
},
render () {
var obj = this.props.value;
var size = 15;
var flagStyle = {
display: 'inline-block',
marginRi... |
frontend/src/components/ShareIcon.js | carlosascari/opencollective-website | import React from 'react';
import Icon from './Icon';
export default ({type, url, name, description}) => {
const tweet = encodeURIComponent(`I just backed the ${name} collective.\nJoin me in supporting them! ${url}`);
const subject = encodeURIComponent(`I just backed the ${name} collective. Join me in supporting... |
src/components/header/stories.js | chuckharmston/testpilot-contribute | import React from 'react';
import { storiesOf } from '@kadira/storybook';
import { wrapper } from '../wrapper/decorator';
import Header, { HomeNav } from './index';
storiesOf('Header', module)
.addDecorator(wrapper('dark'))
.add('With no navigation', () => <Header />)
.add('With homepage navigation', () => <He... |
src/internal/Transition.js | AndriusBil/material-ui | // @flow
import React from 'react';
import type { Element } from 'react';
import ReactDOM from 'react-dom';
import transitionInfo from 'dom-helpers/transition/properties';
import addEventListener from 'dom-helpers/events/on';
import classNames from 'classnames';
import type { SyntheticUIEventHandler } from './dom';
c... |
src/parser/hunter/beastmastery/modules/talents/KillerInstinct.js | sMteX/WoWAnalyzer | import React from 'react';
import SpellLink from 'common/SpellLink';
import TalentStatisticBox from 'interface/others/TalentStatisticBox';
import ItemDamageDone from 'interface/others/ItemDamageDone';
import StatisticListBoxItem from 'interface/others/StatisticListBoxItem';
import calculateEffectiveDamage from 'parser/... |
frontend/src/components/Main.js | textilemuseum/spinningjenny | import React from 'react'
// components
import ConnectNavigationBar from './ConnectNavigationBar'
import EditProfile from './EditProfile'
import Login from './Login'
import NotFound from './NotFound'
import RestrictedRoute from './RestrictedRoute'
import { Route, Switch } from 'react-router-dom'
import UserProfile from... |
src/ReactBoilerplate/Scripts/routes.js | theonlylawislove/react-dot-net | import React from 'react';
import { IndexRoute, Route } from 'react-router';
import {
App,
Home,
About,
Contact,
NotFound,
Register,
Login,
ForgotPassword,
ResetPassword,
ConfirmEmail,
Manage,
ManageIndex,
ManageSecurity,
ManageChangePassword,
ManageLogins,
ManageEmail
} from './containe... |
react-poc-main/app/components/Card/index.js | Meesayen/react-poc | /**
*
* Card
*
*/
import React from 'react';
import styles from './styles.css';
function Card(props) {
return (
<div className={styles.card}>
{props.content}
</div>
);
}
Card.propTypes = {
content: React.PropTypes.node,
};
export default Card;
|
src/pages/AboutPage.js | numieco/patriot-trading | import React from 'react'
import Header from '../components/Header'
import SideBar from './../components/SideBar'
import Footer from './../components/Footer'
import SinglePostArticle from '../components/SinglePostArticle'
export default class AboutPage extends React.Component {
render () {
return (
<div>... |
techCurriculum/ui/solutions/4.3/src/components/Title.js | AnxChow/EngineeringEssentials-group | /**
* Copyright 2017 Goldman Sachs.
* 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... |
src/Badge/Badge.js | AndriusBil/material-ui | // @flow weak
import React from 'react';
import PropTypes from 'prop-types';
import classNames from 'classnames';
import withStyles from '../styles/withStyles';
import { capitalizeFirstLetter } from '../utils/helpers';
const RADIUS = 12;
export const styles = (theme: Object) => ({
root: {
position: 'relative',... |
frontend/app/js/containers/rules_v2/index.js | serverboards/serverboards | import React from 'react'
import connect from '../connect'
import View from 'app/components/rules_v2'
import i18n from 'app/utils/i18n'
import { rules_v2_list, rules_v2_list_clear } from 'app/actions/rules_v2'
import rpc from 'app/rpc'
import Flash from 'app/flash'
export default connect({
state(state, props){
r... |
docs/client/components/pages/Counter/CustomCounterEditor/index.js | koaninc/draft-js-plugins | import React, { Component } from 'react';
import Editor, { createEditorStateWithText } from 'draft-js-plugins-editor'; // eslint-disable-line import/no-unresolved
import createCounterPlugin from 'draft-js-counter-plugin'; // eslint-disable-line import/no-unresolved
import editorStyles from './editorStyles.css';
import ... |
native/app/components/ListPanelLoading.js | cedricium/notes |
import React from 'react';
import { View, ProgressBarAndroid } from 'react-native';
import { COLOR_NOTES_BLUE } from '../utils/constants';
class ListPanelLoading extends React.Component {
render() {
return (
<View style={{ flex: 1, alignItems: 'center', justifyContent: 'center' }}>
<ProgressBarAn... |
client/src/App.js | m-m-k/philosophy | import React from 'react';
import {Form, Button, FormControl, FormGroup, ControlLabel, Navbar} from 'react-bootstrap';
class App extends React.Component {
constructor() {
super();
this.state = {
value: '',
path:[],
found: false
};
this.handleChange = this.handleChange.bind(this);
... |
src/entry/secret.js | liaozhongwu95/blog | import React from 'react'
import ReactDOM from 'react-dom'
import Secret from '../page/secret'
var props = window.APP_PROPS
ReactDOM.render(<Secret {...props}/>, document.getElementById("app")) |
src/web/forms/fields/SubformList/Row.js | asha-nepal/AshaFusionCross | /**
* Copyright 2017 Yuichiro Tsuchiya
*
* 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 agr... |
src/components/Nav.js | RucaLove/GameifyYoSummah | import React from 'react';
import {Button, Icon, SideNav, SideNavItem} from 'react-materialize';
const Nav = ({
}) => {
return (
<SideNav
trigger={<Button>SIDE NAV DEMO</Button>}
options={{ closeOnClick: true }}
>
<SideNavItem userView
user={{
backgroun... |
test/helpers/shallowRenderHelper.js | icancy/test-gallery-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'... |
src/svg-icons/places/smoke-free.js | jacklam718/react-svg-iconx | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let PlacesSmokeFree = (props) => (
<SvgIcon {...props}>
<path d="M2 6l6.99 7H2v3h9.99l7 7 1.26-1.25-17-17zm18.5 7H22v3h-1.5zM18 13h1.5v3H18zm.85-8.12c.62-.61 1-1.45 1-2.38h-1.5c0 1.02-.83 1.85-1.85 1.85v1.5c2.24 0 ... |
step7-unittest/node_modules/react-router/modules/Redirect.js | jintoppy/react-training | import React from 'react'
import invariant from 'invariant'
import { createRouteFromReactElement } from './RouteUtils'
import { formatPattern } from './PatternUtils'
import { falsy } from './PropTypes'
const { string, object } = React.PropTypes
/**
* A <Redirect> is used to declare another URL path a client should
... |
src/App.js | cernanb/personal-chef-react-app | import React, { Component } from 'react';
import './App.css';
import { css } from 'glamor';
import styled from 'styled-components';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { BrowserRouter as Router, Route, Switch } from 'react-router-dom';
import { Container } from 'semantic-u... |
app/javascript/mastodon/features/ui/components/boost_modal.js | esetomo/mastodon | import React from 'react';
import ImmutablePropTypes from 'react-immutable-proptypes';
import PropTypes from 'prop-types';
import { defineMessages, injectIntl, FormattedMessage } from 'react-intl';
import Button from '../../../components/button';
import StatusContent from '../../../components/status_content';
import Av... |
src/js/container/Layout.js | tpucci/jobads-webapp | import React from 'react';
import ScrollSpy from './ScrollSpy';
import Menu from './Menu';
export default class Layout extends React.Component {
constructor(props) {
super(props);
}
render() {
return (
<div className="mainLayout">
<ScrollSpy>
... |
src/svg-icons/action/visibility-off.js | ruifortes/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionVisibilityOff = (props) => (
<SvgIcon {...props}>
<path d="M12 7c2.76 0 5 2.24 5 5 0 .65-.13 1.26-.36 1.83l2.92 2.92c1.51-1.26 2.7-2.89 3.43-4.75-1.73-4.39-6-7.5-11-7.5-1.4 0-2.74.25-3.98.7l2.16 2.16C10.7... |
src/routes.js | ecovirtual/dclv-calculator | import React from 'react';
import { Route, IndexRoute } from 'react-router';
import App from './components/App';
// import HomePage from './components/HomePage';
import CalculatorPage from './containers/CalculatorPage'; // eslint-disable-line import/no-named-as-default
import AboutPage from './components/AboutPage';
im... |
app/components/H1/index.js | simon-johansson/PB-labz | import React from 'react';
import styles from './styles.css';
function H1(props) {
return (
<h1 className={styles.heading1} {...props} />
);
}
export default H1;
|
tripwreck_mobile/src/components/Search_Components/SearchButton.js | CupNCup/tripwreck | import React, { Component } from 'react';
import { connect } from 'react-redux';
import { searchRestaurant } from '../../actions';
import { Button, CardSection } from '../common';
class SearchButton extends Component {
onButtonPress() {
const { searchInput } = this.props;
this.props.searchRestaurant(searchI... |
src/pages/family-planning/FamilyPlanning.js | RHoKAustralia/madapt-react-frontend | import React, { Component } from 'react';
import CardGrid from '../../components/cardgrid/CardGrid';
import Card from '../../components/card/Card';
import BirthSpacingIcon from '../../images/icons/familyplanning/birthspacing.png'
import ContraceptionIcon from '../../images/icons/familyplanning/contraception-types.png'... |
src/js/components/tag-selector.js | donnierayjones/dayone-js-html | import React from 'react';
import ReactDOM from 'react-dom';
import $ from 'jquery';
export default class TagSelector extends React.Component {
constructor(props) {
super(props);
this.state = {
value: ""
};
this.onChange = this.onChange.bind(this);
}
onChange() {
this.setState({
... |
src/components/Menu/components/Header.js | MityaDSCH/MityaDSCH.github.io | import React from 'react'
import Isvg from 'react-inlinesvg'
import { IndexLink, Link } from 'react-router'
import classes from '../styles/Header.scss'
import EmbeddingLogo from '../assets/embeddingLogo.svg'
import FallbackLogo from '../assets/logo.svg'
const p = React.PropTypes
export default class Header extends ... |
demo/src/components/field-views/example3-text-field-view.js | tuantle/hypertoxin | 'use strict'; // eslint-disable-line
import { Ht } from 'hypertoxin';
import React from 'react';
import ReactNative from 'react-native'; // eslint-disable-line
import PropTypes from 'prop-types';
// import DefaultTheme from '../../themes/default-theme';
const {
RowLayout,
ColumnLayout,
TextField,
... |
fall-colors/components/default/float.js | mathisonian/idyll | import React from 'react';
class Float extends React.PureComponent {
render() {
return (
<div className={`float ${this.props.position}`} style={{float: this.props.position, width: this.props.width || '50%'}}>
{this.props.children}
</div>
);
}
}
export default Float;
|
src/index.js | jwmickey/picture-puzzle | import React from 'react';
import ReactDOM from 'react-dom';
import App from './js/components/App';
require('./less/style.less');
ReactDOM.render(<App />, document.getElementById('root'));
|
src/containers/plandetail.js | emreekd/reservationsite | import React, { Component } from 'react';
class PlanDetail extends Component{
constructor(props) {
super(props);
}
render() {
return (
<div>asdas</div>
);
}
}
export default PlanDetail; |
frontend/src/components/Add.js | mqklin/results | import React from 'react';
export default class extends React.Component {
constructor(options) {
super(options);
this.state = {"rate": "1"};
}
addArticle() {
this.props.controller.addArticle(this.state);
}
inputChange(e) {
this.setState({[e.target.getAttribute("data-field")]: e.target.val... |
src/svg-icons/maps/map.js | hwo411/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let MapsMap = (props) => (
<SvgIcon {...props}>
<path d="M20.5 3l-.16.03L15 5.1 9 3 3.36 4.9c-.21.07-.36.25-.36.48V20.5c0 .28.22.5.5.5l.16-.03L9 18.9l6 2.1 5.64-1.9c.21-.07.36-.25.36-.48V3.5c0-.28-.22-.5-.5-.5zM15 ... |
src/common/_navigation_component.js | Bilprospekt/bilprospekt-ui | import React, { Component } from 'react';
var NavigationComponent = React.createClass({
componentDidMount() {
var that = this;
$('#navigation-wrapper ul:first-of-type li').click(function(){
if ($(this).hasClass('dropdown')) {
$(this).toggleClass('show-children');
} else {
$(this).sib... |
packages/generator-electron/template/src/renderer/index.js | my-dish/dish | // @flow
import React from 'react';
import ReactDOM from 'react-dom';
import { AppContainer } from 'react-hot-loader';
import App from './containers';
import 'normalize.css';
const rootEl = document.getElementById('root');
const render = () => {
ReactDOM.render((
<AppContainer>
<App />
</AppContaine... |
examples/simple.js | xiefei89/react-transformable-div | import React from 'react'
import ReactDOM from 'react/lib/ReactDOM'
import TransformableDiv from '../index.jsx'
class Test extends React.Component {
state = {
zoom: 0,
wrapTopOffset: 0,
wrapLeftOffset: 0,
wrapSize: {
width: 960,
height: 540
},
rotate: 0
}
rend... |
src/components/app.js | tylergraf/react-twitter | import React from 'react';
import Catalog from './catalog/app-catalog';
import HomeTimelinePage from '../containers/HomeTimelinePage';
import Cart from './cart/app-cart';
import CatalogDetail from './product/app-catalogdetail';
import Template from './app-template';
import { Router, Route, IndexRoute } from 'react-rout... |
docs/src/Anchor.js | tonylinyy/react-bootstrap | import React from 'react';
const Anchor = React.createClass({
propTypes: {
id: React.PropTypes.string
},
render() {
return (
<a id={this.props.id} href={'#' + this.props.id} className='anchor'>
<span className='anchor-icon'>#</span>
{this.props.children}
</a>
);
}
});
e... |
app/home.js | CKrawczyk/electron-subject-uploader | import React from 'react';
import ProjectListDisplay from './project-list';
const Home = (props, context) => {
let projectList;
if (context.user) {
projectList = <ProjectListDisplay />;
} else {
projectList = (
<div>
Please sign in to see your projects
</div>
);
}
return (
... |
src/index.js | jansplichal2/reactnd-project-readable-starter | import React from 'react';
import ReactDOM from 'react-dom'
import App from './components/App'
import {BrowserRouter} from 'react-router-dom';
import {Provider} from 'react-redux';
import store from './store';
ReactDOM.render(<BrowserRouter>
<Provider store={store}>
<App/>
</Provider>
... |
admin/client/App/screens/Home/index.js | michaelerobertsjr/keystone | /**
* The Home view is the view one sees at /keystone. It shows a list of all lists,
* grouped by their section.
*/
import React from 'react';
import { Container, Spinner } from 'elemental';
import { connect } from 'react-redux';
import Lists from './components/Lists';
import Section from './components/Section';
i... |
src/main/webapp/resources/js/components/echarts/heatmapcartesian.js | peterchenhdu/webbf | import React from 'react'
import echarts from 'echarts'
export default class HeatmapCartesian extends React.Component{
constructor(props){
super(props);
}
autoResize() {
var chartdiv = document.getElementById('heatmap-chart');
chartdiv.style.width = '100%';
chartdiv.style.height = '500px';
}
... |
node_modules/@material-ui/core/es/Grid/Grid.js | pcclarke/civ-techs | import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/objectWithoutPropertiesLoose";
import _extends from "@babel/runtime/helpers/extends";
// A grid component using the following libs as inspiration.
//
// For the implementation:
// - http://v4-alpha.getbootstrap.com/layout/flexbox-grid/
// - https://githu... |
app/components/CodeEditor.js | dikalikatao/fil | import React from 'react';
import AceEditor from 'react-ace';
import 'brace/mode/python';
import 'brace/mode/ruby';
import 'brace/mode/javascript';
import 'brace/theme/tomorrow_night';
import {getExtension} from 'helpers';
import {byExtension} from 'interpreters';
class CodeEditor extends React.Component {
constr... |
demo/card/card.js | darkyen/react-mdl | import React from 'react';
import Card, { CardTitle, CardText, CardActions, CardMenu } from '../../src/card/Card';
import Button from '../../src/Button';
import IconButton from '../../src/IconButton';
import Icon from '../../src/Icon';
class Demo extends React.Component {
render() {
return (
<d... |
actor-apps/app-web/src/app/components/activity/UserProfile.react.js | luoxiaoshenghustedu/actor-platform | import _ from 'lodash';
import React from 'react';
import ReactMixin from 'react-mixin';
import { IntlMixin, FormattedMessage } from 'react-intl';
import classnames from 'classnames';
import ContactActionCreators from 'actions/ContactActionCreators';
import DialogActionCreators from 'actions/DialogActionCreators';
im... |
client/scripts/components/config/undo-button/index.js | kuali/research-coi | /*
The Conflict of Interest (COI) module of Kuali Research
Copyright © 2005-2016 Kuali, Inc.
This program 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, either version 3 of the
Lic... |
src/RadioGroup/RadioGroup.driver.js | skyiea/wix-style-react | import React from 'react';
import ReactDOM from 'react-dom';
import ReactTestUtils from 'react-dom/test-utils';
import toArray from 'lodash/toArray';
import {isClassExists} from '../../test/utils';
const radioGroupDriverFactory = ({element, wrapper, component}) => {
const radios = toArray(element.children) || [];
... |
src/components/SearchComponent.js | krzysztofkolek/react-github-client | 'use strict';
require('styles//Search.css');
import React from 'react';
import * as SearchAction from '../actions/SearchAction'
import SearchStore from '../stores/SearchStore'
import dispatcher from '../dispatcher/Dispatcher'
import * as MainAction from '../actions/MainAction'
class SearchComponent extends React.Com... |
src/client/components/component.react.js | grabbou/este | import React from 'react';
import shallowEqual from 'react-pure-render/shallowEqual';
// import diff from 'immutablediff';
/**
* Purified React.Component. Goodness.
* http://facebook.github.io/react/docs/advanced-performance.html
*/
class Component extends React.Component {
shouldComponentUpdate(nextProps, next... |
src/views/components/shared/tracks.js | EragonJ/Kaku | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import ReactTooltip from 'react-tooltip';
import Track from './track/track';
import NoTrack from './track/no-track';
import L10nSpan from './l10n-span';
import ActionButton from './action-button';
import TrackModeButton from './track-mode-but... |
features/toolbar/components/Toolbar.native.js | jitsi/jitsi-meet-react | import React from 'react';
import { View } from 'react-native';
import { connect } from 'react-redux';
import {
MEDIA_TYPE,
toggleCameraFacingMode
} from '../../base/media';
import { Container } from '../../base/react';
import { ColorPalette } from '../../base/styles';
import {
AbstractToolbar,
mapSta... |
examples/sidebar/app.js | ThibWeb/react-router | import React from 'react';
import { Router, Route, Link } from 'react-router';
import data from './data';
var Category = React.createClass({
render() {
var category = data.lookupCategory(this.props.params.category);
return (
<div>
<h1>{category.name}</h1>
{this.props.children || (
... |
src/Parser/Warlock/Destruction/Modules/Items/Legendaries/MagistrikeRestraints.js | enragednuke/WoWAnalyzer | import React from 'react';
import SPELLS from 'common/SPELLS';
import ITEMS from 'common/ITEMS';
import Analyzer from 'Parser/Core/Analyzer';
import Combatants from 'Parser/Core/Modules/Combatants';
import ItemDamageDone from 'Main/ItemDamageDone';
class MagistrikeRestraints extends Analyzer {
static dependencies =... |
app/javascript/mastodon/features/report/rules.js | cobodo/mastodon | import React from 'react';
import PropTypes from 'prop-types';
import ImmutablePropTypes from 'react-immutable-proptypes';
import { connect } from 'react-redux';
import { FormattedMessage } from 'react-intl';
import Button from 'mastodon/components/button';
import Option from './components/option';
const mapStateToPro... |
src/pages/imprint.js | JovaniPink/measuredstudios | import React from 'react';
import PropTypes from 'prop-types';
import { graphql } from 'gatsby';
import styled from 'styled-components';
import { MDXRenderer } from 'gatsby-plugin-mdx';
import GlobalStateProvider from '../context/provider';
import ContentWrapper from '../styles/contentWrapper';
import Layout from '../... |
packages/react-scripts/fixtures/kitchensink/src/features/syntax/ObjectSpread.js | reedsa/create-react-app | /**
* Copyright (c) 2015-present, Facebook, Inc.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
import React, { Component } from 'react';
import PropTypes from 'prop-types';
function load(baseUser) {
return [
{ id: 1, name: '... |
client/components/NoResultsPage.js | HelpAssistHer/help-assist-her | import React from 'react'
import injectSheet from 'react-jss'
import { Link } from 'react-router-dom'
import Button from './Button'
import { Phone, BigPhone, Tablet, Desktop } from './Breakpoints'
import Spacer from './Spacer'
const noResultsMessage = 'No results match your search.'
const buttonText = 'Return to Sear... |
generators/app/templates/app/web/static/js/components/form.js | TFarla/generator-phoenix-react | import React from 'react';
export default ({handleSubmit}) => {
let input;
return (
<form onSubmit={
e => {
e.preventDefault();
handleSubmit(input.value);
input.value = '';
}
}>
<div className='form-group'>
<input
className='form-control'
... |
conserve/src/Map.js | lrobinsonco/conserve | import React from 'react';
import PropTypes from 'prop-types';
import Map from 'google-maps-react';
export class Container extends React.Component {
render() {
if (!this.props.loaded) {
return <div>Loading...</div>
}
return (
<div>Map will go here</div>
)
}
}
export default GoogleApiC... |
data-browser-ui/public/app/components/tableComponents/td/aclComponents/viewAcl.js | CloudBoost/cloudboost | import React from 'react'
import ReactDOM from 'react-dom'
class ViewACL extends React.Component {
constructor(){
super()
this.state = {
}
}
componentDidMount(){
}
render() {
let users = 0
let roles = 0
let all = 0
let str = ''
let write = false
let read = false
if(this.props.aclList){
... |
components/Navigation/Navigation.js | HashtasticDesign/build | /**
* React Static Boilerplate
* https://github.com/koistya/react-static-boilerplate
* Copyright (c) Konstantin Tarkus (@koistya) | MIT license
*/
import React from 'react';
import './Navigation.scss';
import Link from '../Link';
function Navigation() {
return (
<ul className="navigation" role="menu">
... |
docs/app/Examples/elements/Input/Variations/InputExampleIconProps.js | ben174/Semantic-UI-React | import React from 'react'
import { Input } from 'semantic-ui-react'
const InputExampleIconProps = () => (
<Input
icon={{ name: 'search', circular: true, link: true }}
placeholder='Search...'
/>
)
export default InputExampleIconProps
|
src/components/Layout/Header.js | 102010cncger/antd-admin | import React from 'react'
import PropTypes from 'prop-types'
import { Menu, Icon, Popover } from 'antd'
import classnames from 'classnames'
import styles from './Header.less'
import Menus from './Menu'
const SubMenu = Menu.SubMenu
const Header = ({ user, logout, switchSider, siderFold, isNavbar, menuPopoverVisible, l... |
src/flipper/Card.js | rudyyazdi/site | import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { cardFlip } from './actions';
const _Card = ({ isFlipped, isGuessed, id, pairId, onClick }) => {
const isVisible = isFlipped || isGuessed;
const outerStyle = {
cursor: 'pointer',
backgroundImage:... |
src/components/services/content/WebviewCrashHandler.js | GustavoKatel/franz | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { observer } from 'mobx-react';
import { defineMessages, intlShape } from 'react-intl';
import Button from '../../ui/Button';
const messages = defineMessages({
headline: {
id: 'service.crashHandler.headline',
defaultMessage... |
renderer/components/UI/Button.js | LN-Zap/zap-desktop | import React from 'react'
import PropTypes from 'prop-types'
import styled from 'styled-components'
import { Button as BaseButton, Flex, Box } from 'rebass/styled-components'
import Spinner from './Spinner'
const Wrapper = styled(BaseButton)`
transition: all 0.25s;
outline: none;
font-weight: 300;
line-height:... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.