path stringlengths 5 195 | repo_name stringlengths 5 79 | content stringlengths 25 1.01M |
|---|---|---|
main.js | FlorianEdelmaier/SimpleReduxDemo | import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from 'react-redux';
import App from './containers/App';
import store from './store';
ReactDOM.render(<Provider store={store}>
<App />
</Provider>,
document.getElementById('app'));
|
src/components/Feedback/Feedback.js | sonbui00/react-starter-kit | /*! React Starter Kit | MIT License | http://www.reactstarterkit.com/ */
import React from 'react';
import styles from './Feedback.css';
import withStyles from '../../decorators/withStyles';
@withStyles(styles)
class Feedback {
render() {
return (
<div className="Feedback">
<div className="Feedba... |
client/routes/Items/components/ItemOutForm.js | patzj/ims | import React from 'react';
import { connect } from 'react-redux';
import { itemOut } from '../../../actions/items-action';
let ItemOutForm = ({currentItem, itemOut, handleInt}) => {
return (
<form className="form-horizontal" method="post" action="#" onSubmit={e => itemOut(currentItem.code, e)}>
... |
src/svg-icons/editor/title.js | frnk94/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let EditorTitle = (props) => (
<SvgIcon {...props}>
<path d="M5 4v3h5.5v12h3V7H19V4z"/>
</SvgIcon>
);
EditorTitle = pure(EditorTitle);
EditorTitle.displayName = 'EditorTitle';
EditorTitle.muiName = 'SvgIcon';
ex... |
admin/client/App/shared/Popout/PopoutList.js | trentmillar/keystone | /**
* Render a popout list. Can also use PopoutListItem and PopoutListHeading
*/
import React from 'react';
import blacklist from 'blacklist';
import classnames from 'classnames';
const PopoutList = React.createClass({
displayName: 'PopoutList',
propTypes: {
children: React.PropTypes.node.isRequired,
classNam... |
app/javascript/mastodon/components/column_header.js | imas/mastodon | import React from 'react';
import PropTypes from 'prop-types';
import { createPortal } from 'react-dom';
import classNames from 'classnames';
import { FormattedMessage, injectIntl, defineMessages } from 'react-intl';
import Icon from 'mastodon/components/icon';
const messages = defineMessages({
show: { id: 'column_h... |
src/components/IpMap.js | tombray/react-redux-dashboard | import React, { Component } from 'react';
import ReactDOM from 'react-dom';
import _ from 'lodash';
import L from 'leaflet';
import { Panel } from 'react-bootstrap';
L.Icon.Default.imagePath = 'node_modules/leaflet/dist/images/';
const popupString = (ip) => (
[
`<h2>${ip.owner}<h2>`,
`<h3>${ip.ip}<h3>`,... |
src/components/spaces/show/privacy-toggle/index.js | getguesstimate/guesstimate-app | import React from 'react'
import DropDown from 'gComponents/utility/drop-down/index.js'
import {CardListElement} from 'gComponents/utility/card/index.js'
import * as navigationActions from 'gModules/navigation/actions.js'
import './style.css'
const PublicOption = ({isSelected, onClick}) => (
<CardListElement
... |
src/components/SpeakersElement/SpeakersElement.js | hack-duke/hackduke-dayof | import React from 'react'
import classes from './SpeakersElement.scss'
// import eventInfoClasses from 'components/EventInfo/EventInfo.scss'
class SpeakersElement extends React.Component {
static propTypes = {
title: React.PropTypes.string.isRequired,
time: React.PropTypes.string.isRequired,
location: R... |
test/multi-section/AutosuggestApp.js | CoreFiling/react-autosuggest | import React, { Component } from 'react';
import sinon from 'sinon';
import Autosuggest from '../../src/Autosuggest';
import languages from './languages';
import { escapeRegexCharacters } from '../../demo/src/components/utils/utils.js';
const getMatchingLanguages = value => {
const escapedValue = escapeRegexCharacte... |
src/containers/subscription/SubscriptionPopupScreen.js | GustavoKatel/franz | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { inject, observer } from 'mobx-react';
import SubscriptionPopup from '../../components/subscription/SubscriptionPopup';
export default @inject('stores', 'actions') @observer class SubscriptionPopupScreen extends Component {
state... |
src/packages/@ncigdc/modern_components/ClinicalAnalysis/ClinicalVariableCard/modals/ContinuousCustomBinsModal/BinningMethodInput.js | NCI-GDC/portal-ui | import React from 'react';
const BinningMethodInput = ({
binningMethod, checked, handleChange, label,
}) => {
return (
<React.Fragment>
<input
checked={checked}
id={`binning-method-${binningMethod}`}
name="binning-method"
onChange={handleChange}
style={{ marginRigh... |
src/components/Menu.js | mgaebler/kicknow-client-web | import React from 'react'
import { Link } from 'react-router-dom'
import {
Drawer,
DrawerHeader,
DrawerContent,
DrawerSpacer,
DrawerHeaderContent,
Navigation,
Icon
} from 'react-mdc-web'
import { closeDrawer } from '../modules/navigation/actions'
class Menu extends React.Component {
render() {
retu... |
src/components/form/group/index.js | rangle/react-redux-starter | import React from 'react';
function FormGroup({ children, testid, ...props}) {
return (
<div data-testid={testid} className="py2" {...props}>
{children}
</div>
);
}
FormGroup.propTypes = {
children: React.PropTypes.node,
testid: React.PropTypes.string,
};
export default FormGroup;
|
src/components/subcomponent.js | brabadu/tanok | import React from 'react';
import PropTypes from 'prop-types';
import { streamKey, storeKey } from '../constants';
export class Subcomponent extends React.Component {
constructor(props, context) {
super(props, context);
const stream = context[streamKey];
const store = context[storeKey];
const {name... |
frontend/modules/list/components/GroceryList.js | RyanNoelk/OpenEats | "use strict";
import React from 'react'
import PropTypes from 'prop-types'
import { injectIntl, defineMessages } from 'react-intl'
import Items from '../containers/Items'
import MyLists from './MyLists'
import ListHeader from './ListHeader'
import NewList from './NewList'
import Error from './Error'
require("./../cs... |
storybook/stories/area-stack/index.js | JesperLekland/react-native-svg-charts | import React from 'react'
import { storiesOf } from '@storybook/react-native'
import Regular from './standard'
import WithTimeScale from './with-time-scale'
import WithGradient from './with-gradient'
import WithYAxis from './with-y-axis'
import ShowcaseCard from '../showcase-card'
storiesOf('StackedAreaChart', module... |
src/wics/src/chat.js | civiclee/Hack4Cause2017 | import React from 'react';
import Conversation from 'chat-template/dist/Conversation';
var messages = [{
message:'How do I use this messaging app?',
from: 'right',
backColor: '#3d83fa',
textColor: "white",
avatar: 'https://www.seeklogo.net/wp-content/uploads/2015/09/google-plus-new-icon-logo.png',
duration... |
app/assets/scripts/views/uhoh.js | AMT-Autoridade/amt | 'use strict';
import React from 'react';
var UhOh = React.createClass({
render: function () {
return (
<div className='container-wrapper'>
<section className='content-wrapper'>
<h1>Página não encontrada</h1>
<div className='wrapper'>
<div>
<p className=... |
src/js/components/SettingsView.js | vbence86/giftassistant-client | /*
To add togglable items to the list
<SettingsList.Header headerStyle={styles.header} headerText="Basic" />
<SettingsList.Item
hasSwitch={true}
switchState={this.props.notifications}
switchOnValueChange={this.props.onSetNotifications}
has... |
app/DribbbleNavigator.js | future-challenger/react-native-dribbble-app | /**
* Created by Uncle Charlie
*
* @flow
*/
import React from 'react'
import {
Platform,
BackAndroid,
Navigator,
StyleSheet
} from 'react-native'
import DribbbleTabsView from './DribbbleTabsView'
import { connect } from 'react-redux'
import { switchTab } from './actions'
|
src/components/Actions/index.js | fedebertolini/json-editor | import React from 'react';
import EditButton from './EditButton';
import DeleteButton from './DeleteButton';
import AddArrayItemButton from './AddArrayItemButton';
import AddObjectPropertyButton from './AddObjectPropertyButton';
import './styles.css';
const Actions = ({ path, allowAddItem, allowAddProperty, allowDelet... |
docs/app/Examples/elements/List/Content/ListExampleDescription.js | aabustamante/Semantic-UI-React | import React from 'react'
import { List } from 'semantic-ui-react'
const ListExampleDescription = () => (
<List>
<List.Item>
<List.Icon name='marker' />
<List.Content>
<List.Header as='a'>Krowlewskie Jadlo</List.Header>
<List.Description>An excellent polish restaurant, quick delivery ... |
src/index.js | didilinkin/admin-react-antd-example | // 根文件
import React from 'react'
import { render } from 'react-dom'
import { authenticate } from './utils/LocalStore'
import { configureStore, history } from './store/configureStore/index'
import Root from './common/containers/Root'
import 'babel-polyfill'
const store = configureStore()
const authState = authenticat... |
src/components/Header/Header.js | teosz/test-problem-reproduce | import React, { Component } from 'react';
import styles from './Header.css';
import withStyles from '../../decorators/withStyles';
@withStyles(styles)
class Header extends Component {
render() {
return (
<div className="Header">
<div className="Header-container">
<br />
Header
... |
client/modules/App/__tests__/Components/Header.spec.js | Bonchouuur/kimanjou | import React from 'react';
import test from 'ava';
import sinon from 'sinon';
import { shallow } from 'enzyme';
import { FormattedMessage } from 'react-intl';
import { Header } from '../../components/Header/Header';
import { intl } from '../../../../util/react-intl-test-helper';
const intlProp = { ...intl, enabledLang... |
src/svg-icons/editor/format-italic.js | frnk94/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let EditorFormatItalic = (props) => (
<SvgIcon {...props}>
<path d="M10 4v3h2.21l-3.42 8H6v3h8v-3h-2.21l3.42-8H18V4z"/>
</SvgIcon>
);
EditorFormatItalic = pure(EditorFormatItalic);
EditorFormatItalic.displayName ... |
src/main/javascript/src/index.js | themoderngeek/sonos-web-controller | import React from 'react';
import ReactDOM from 'react-dom';
import App from './Components/App/App';
//import './index.css';
ReactDOM.render(
<App />,
document.getElementById('root')
);
|
app/routes.js | epicallan/tv-chicken | import React from 'react';
import { Route, IndexRoute } from 'react-router';
import App from './containers/App';
import HomePage from './containers/HomePage';
import SinglePage from './containers/SinglePage';
export default (
<Route path="/" component={App}>
<IndexRoute component={HomePage} />
<Route path="s... |
docs/src/app/components/pages/discover-more/Contributing.js | pradel/material-ui | import React from 'react';
import Title from 'react-title-component';
import MarkdownElement from '../../MarkdownElement';
import contributingText from '../../../../../../CONTRIBUTING.md';
const Contributing = () => (
<div>
<Title render={(previousTitle) => `Contributing - ${previousTitle}`} />
<MarkdownEle... |
src/svg-icons/image/tune.js | tan-jerene/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageTune = (props) => (
<SvgIcon {...props}>
<path d="M3 17v2h6v-2H3zM3 5v2h10V5H3zm10 16v-2h8v-2h-8v-2h-2v6h2zM7 9v2H3v2h4v2h2V9H7zm14 4v-2H11v2h10zm-6-4h2V7h4V5h-4V3h-2v6z"/>
</SvgIcon>
);
ImageTune = pure... |
src/svg-icons/action/picture-in-picture-alt.js | tan-jerene/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionPictureInPictureAlt = (props) => (
<SvgIcon {...props}>
<path d="M19 11h-8v6h8v-6zm4 8V4.98C23 3.88 22.1 3 21 3H3c-1.1 0-2 .88-2 1.98V19c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2zm-2 .02H3V4.97h18v14.05z"/>
</Svg... |
lib/addons/inject-actions.js | pombredanne/nano-flux | import React from 'react';
const exists = (obj) => {
return obj !== null && typeof obj !== 'undefined';
};
export default (Component, actionsKeys, actionsFn) => {
const checkFluxProp = (props) => {
if (!exists(props.flux)) {
throw new Error('Must pass flux object on props for injectActions.');
}
... |
src/components/settings/SettingsForm.js | great-design-and-systems/cataloguing-app | import { CollapseHeader, HiddenButton, ListForm } from '../common/';
import { LABEL_CURRENCY, LABEL_FUND, LABEL_RESOURCE_TYPE } from '../../labels/';
import FontAwesome from 'react-fontawesome';
import PropTypes from 'prop-types';
import React from 'react';
import { ResourceTypeTableForm } from './ResourceTypeTableFor... |
ui/src/js/profile/tools/Tools.js | Dica-Developer/weplantaforest | import React, { Component } from 'react';
import Banner from './Banner';
import ButtonBar from './ButtonBar';
import Certificates from './Certificates';
import Overview from './Overview';
import Receipts from './Receipts';
import Widgets from './Widgets';
require('./tools.less');
export default class Tools extends Co... |
src/routes/Login/components/LoginView.js | JSChecker/JSChecker-WebClient | import React from 'react'
import './LoginView.scss'
import _ from 'lodash'
import ApiView from '../../../components/ApiView'
import Loader from '../../../components/Loader'
export class LoginView extends ApiView {
constructor(props) {
super(props)
this.state = {
data: {
username: '',
... |
docs/src/app/components/pages/components/DropDownMenu/ExampleLongMenu.js | kasra-co/material-ui | import React from 'react';
import DropDownMenu from 'material-ui/DropDownMenu';
import MenuItem from 'material-ui/MenuItem';
const items = [];
for (let i = 0; i < 100; i++ ) {
items.push(<MenuItem value={i} key={i} primaryText={`Item ${i}`} />);
}
export default class DropDownMenuLongMenuExample extends React.Compo... |
src/client/components/Error.js | hara-io/realtime-react-client | import React from 'react';
class Error extends React.Component {
constructor(props) {
super(props);
}
componentWillMount() {
}
componentWillUnmount() {
}
render() {
return (
<div className="error-message">
<span className="error-icon fa fa-exclamation-triangle"></span>
<s... |
src/svg-icons/content/add-circle.js | lawrence-yu/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ContentAddCircle = (props) => (
<SvgIcon {...props}>
<path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm5 11h-4v4h-2v-4H7v-2h4V7h2v4h4v2z"/>
</SvgIcon>
);
ContentAddCircle = pure(Cont... |
src/svg-icons/content/link.js | kasra-co/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ContentLink = (props) => (
<SvgIcon {...props}>
<path d="M3.9 12c0-1.71 1.39-3.1 3.1-3.1h4V7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h4v-1.9H7c-1.71 0-3.1-1.39-3.1-3.1zM8 13h8v-2H8v2zm9-6h-4v1.9h4c1.71 0 3.1 1.39 3.1 3.... |
client/components/Heading.js | HelpAssistHer/help-assist-her | import React from 'react'
import injectSheet from 'react-jss'
const Heading = ({ classes, text, size }) => {
return <div className={classes[`${size}`]}>{text}</div>
}
const styles = {
medium: {
color: '#D8D8D8',
'font-size': '20px',
'font-weight': 'bold',
'letter-spacing': '3.73px',
'line-height': '24px',... |
src/components/common/TextInput.js | jaggerwang/zqc-app-demo | /**
* 在球场
* zaiqiuchang.com
*/
import React from 'react'
import {StyleSheet, TextInput, Platform} from 'react-native'
import flattenStyle from 'flattenStyle'
import {COLOR} from '../../config'
export default ({onRef, style, ...props}) => {
let {fontSize} = flattenStyle(style || styles.input)
return (
<Tex... |
src/svg-icons/notification/do-not-disturb.js | skarnecki/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let NotificationDoNotDisturb = (props) => (
<SvgIcon {...props}>
<path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8 0-1.85.63-3.55 1.69-4.9L16.9 18.31C15.55 19.37 13... |
app/components/sponsor/SponsorTable.js | wp-wilsonperez/votos | import React from 'react';
class SponsorTable extends React.Component {
render() {
console.log(this.props.sponsors);
return <div>
{
this.props.sponsors.map((sponsor) => {
console.log(sponsor.name);
let img = `images/sponsors/${sponsor.img}`;
return <div... |
src/components/forms.js | LaserWeb/LaserWeb4 | import React from 'react';
import ReactDOM from 'react-dom';
import { connect } from 'react-redux';
import Toggle from "react-toggle";
import 'react-toggle/style.css';
import '../styles/forms.css';
import Select from 'react-select'
import { Tooltip, Overlay, OverlayTrigger, Popover, FormControl, InputGroup, ControlLa... |
src/server.js | OSDLabs/swd | /**
* 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 'isomorphic-fetch';
import path from 'path';
imp... |
client/src/components/Sky.js | apologeticcookie/apologeticcookie | import { Entity } from 'aframe-react';
import React from 'react';
// If there is a particular skybox image that should be used instead of a
// color, the Entity material property can take in a src instead of a
// color
// Just keep in mind that if the src points to some img url, you would want to
// do something like:... |
docs/src/app/components/pages/components/FontIcon/Page.js | matthewoates/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 iconCode from '!raw!material-ui/FontIcon/FontIcon';
import iconReadmeText... |
src/components/LeaderboardItem/index.js | slwen/lastfm-app | 'use strict';
require("./style.scss");
import React from 'react';
export default React.createClass({
displayName: 'LeaderboardItem',
propTypes: {
title: React.PropTypes.string.isRequired,
subtitle: React.PropTypes.string,
playCount: React.PropTypes.string.isRequired,
imgUrl: React.PropTypes.strin... |
src/svg-icons/editor/insert-photo.js | ngbrown/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let EditorInsertPhoto = (props) => (
<SvgIcon {...props}>
<path d="M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z"/>
</SvgIcon>
);
EditorI... |
examples/tex/js/components/TeXBlock.js | brookslyrette/draft-js | /**
* Copyright (c) 2013-present, Facebook, Inc. All rights reserved.
*
* This file provided by Facebook is for non-commercial testing and evaluation
* purposes only. Facebook reserves all rights not expressly granted.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCL... |
app/components/ToggleOption/index.js | abasalilov/react-boilerplate | /**
*
* ToggleOption
*
*/
import React from 'react';
import PropTypes from 'prop-types';
import { injectIntl, intlShape } from 'react-intl';
const ToggleOption = ({ value, message, intl }) => (
<option value={value}>
{message ? intl.formatMessage(message) : value}
</option>
);
ToggleOption.propTypes = {
va... |
app/components/About/LinkRenderer.js | sysrex/sysrex | import React from 'react';
import PropTypes from 'prop-types';
import { Link } from 'react-router-dom';
const LinkRenderer = (props) => {
if (props.href.match(/^(https?:)?\/\//)) {
return (
<a href={props.href}>
{props.children}
</a>
);
}
return (
<Link to={props.href}>{props.chil... |
providers/dashboards-url-provider/index.js | Vizzuality/gfw | import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import Url from 'components/url';
import selectMapParams from './selectors';
const DashboardsUrlProvider = ({ urlParams }) => (
<Url queryParams={urlParams} />
);
DashboardsUrlProvider.propTypes = {
urlParams: ... |
app/javascript/mastodon/containers/compose_container.js | yi0713/mastodon | import React from 'react';
import { Provider } from 'react-redux';
import PropTypes from 'prop-types';
import configureStore from '../store/configureStore';
import { hydrateStore } from '../actions/store';
import { IntlProvider, addLocaleData } from 'react-intl';
import { getLocale } from '../locales';
import Compose f... |
src/pages/Reel.js | MarioMarenco/Portfolio-Page- | import React from 'react'
import Link from 'gatsby-link'
import One from '../images/3d/2011/1.jpg'
import Two from '../images/3d/2011/2.jpg'
import Three from '../images/3d/2011/3.jpg'
import Four from '../images/3d/2011/4.jpg'
import Five from '../images/3d/2015/1.jpg'
import Six from '../images/3d/2008/1.jpg'
... |
Console/app/node_modules/rc-slider/es/common/createSlider.js | RisenEsports/RisenEsports.github.io | import _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties';
import _extends from 'babel-runtime/helpers/extends';
import _defineProperty from 'babel-runtime/helpers/defineProperty';
import _classCallCheck from 'babel-runtime/helpers/classCallCheck';
import _createClass from 'babel-runtime/help... |
modules/Navigation.js | jepezi/react-router | import React from 'react';
var { object } = React.PropTypes;
/**
* A mixin for components that modify the URL.
*
* Example:
*
* import { Navigation } from 'react-router';
*
* var MyLink = React.createClass({
* mixins: [ Navigation ],
* handleClick(event) {
* event.preventDefault();
* ... |
src/mobile/components/AppBar/index.js | Perslu/rerebrace | import React from 'react';
// import styles from './styles.css'
import {Link} from 'react-router';
const AppBar = React.createClass({
render() {
const props = this.props;
return (
<header className="AppBar">
<h1>{props.title}</h1>
<nav>
<Link to="/">Go to home</Link>
... |
src/svg-icons/notification/mms.js | rscnt/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let NotificationMms = (props) => (
<SvgIcon {...props}>
<path d="M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM5 14l3.5-4.5 2.5 3.01L14.5 8l4.5 6H5z"/>
</SvgIcon>
);
NotificationMms = ... |
src/index.js | mschipperheyn/mm-loaders | import React from 'react';
import MDSpinner from './components/MDSpinner';
export {
MDSpinner
};
|
docs/pages/company/lead-designer.js | mbrookes/material-ui | import React from 'react';
import TopLayoutCompany from 'docs/src/modules/components/TopLayoutCompany';
import {
demos,
docs,
requireDemo,
} from '!@material-ui/markdown/loader!docs/src/pages/company/lead-designer/lead-designer.md';
export default function Page() {
return <TopLayoutCompany demos={demos} docs={... |
packages/react-error-overlay/src/components/Collapsible.js | mangomint/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.
*/
/* @flow */
import React, { Component } from 'react';
import { black } from '../styles';
import type { Element as ReactElement } from '... |
src/components/contact-details/ContactDetailsPage.js | TulevaEE/onboarding-client | import React from 'react';
import { FormattedMessage } from 'react-intl';
import { PropTypes as Types } from 'prop-types';
import { bindActionCreators } from 'redux';
import { connect } from 'react-redux';
import UpdateUserForm from './updateUserForm';
import { updateUser } from '../common/user/actions';
const noop = ... |
src/index.js | siiptuo/tiima-spa | import React from 'react';
import ReactDOM from 'react-dom';
import { createStore, applyMiddleware } from 'redux';
import { Provider } from 'react-redux';
import thunkMiddleware from 'redux-thunk';
import taimioStore from './reducers';
import * as auth from './auth';
import App from './App';
import less from '../sty... |
Paths/React/05.Building Scalable React Apps/8-react-boilerplate-building-scalable-apps-m8-exercise-files/After/app/components/LinkForm/index.js | phiratio/Pluralsight-materials | /**
*
* LinkForm
*
*/
import React from 'react';
import styles from './styles.css';
import TextInput from '../TextInput';
class LinkForm extends React.Component { // eslint-disable-line react/prefer-stateless-function
static propTypes = {
addLink: React.PropTypes.func.isRequired,
topicName: React.PropTypes... |
app/Components/Footer.js | gerbilsinspace/wikilynx | import React from 'react';
const Footer = React.createClass({
render: () => {
return (
<div style={{paddingTop: 20, marginTop: 40, borderTop: '1px solid #eee', fontSize: 11}}>
<p>Wikipedia® is a registered trademark of the Wikimedia Foundation, Inc., a non-profit organization</p>
<p><a href="http://wikim... |
webApp/src/Components/BroadcastSetup.js | s-law/silent-disco | import React from 'react';
// ROUTER
import { History } from 'react-router';
import reactMixin from 'react-mixin';
// COMPONENTS
import Loading from './Loading.js';
import BroadcastSetupView from './BroadcastSetupView'
// UTILITIES
import Auth from '../utils/Auth';
import $ from '../../public/js/jquery-1.11.1.min';
... |
modules/Lifecycle.js | barretts/react-router | import React from 'react'
import invariant from 'invariant'
const { object } = React.PropTypes
/**
* The Lifecycle mixin adds the routerWillLeave lifecycle method
* to a component that may be used to cancel a transition or prompt
* the user for confirmation.
*
* On standard transitions, routerWillLeave receives ... |
assets/javascripts/kitten/components/form/radio-button-set/index.js | KissKissBankBank/kitten | import React from 'react'
import PropTypes from 'prop-types'
import deprecated from 'prop-types-extra/lib/deprecated'
import styled from 'styled-components'
import classNames from 'classnames'
import { RadioButton } from '../../form/radio-button'
import { pxToRem } from '../../../helpers/utils/typography'
import { Labe... |
src/app/components/Sidebar.js | UrgBenri/UrgBenriWeb | import React from 'react';
import { bindActionCreators } from 'redux';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import Drawer from 'material-ui/Drawer';
import { toggleSidebar } from '../actions/sidebar';
export const Sidebar = ({ width, open, onClose, children }) => (
<div>... |
src/handbook/outdoor_program.js | khayyamj/thunderbirds_troop51 | import React from 'react';
export default function() {
return (
<div>
<p className="p1"><span className="s1"><strong>Outdoor Program</strong></span></p>
<p className="p2"> </p>
<p className="p3"><span className="s1"><strong>Planning</strong></span></p>
<p className="p4"> </p>
<p className="p5"... |
src/parser/monk/brewmaster/modules/spells/RushingJadeWind.js | ronaldpereira/WoWAnalyzer | import React from 'react';
import SPELLS from 'common/SPELLS';
import SpellLink from 'common/SpellLink';
import { formatPercentage } from 'common/format';
import Analyzer from 'parser/core/Analyzer';
// the buff events all use this spell
export const RUSHING_JADE_WIND_BUFF = SPELLS.RUSHING_JADE_WIND_TALENT_BREWMASTER... |
fields/types/boolean/BooleanColumn.js | naustudio/keystone | import React from 'react';
import Checkbox from '../../components/Checkbox';
import ItemsTableCell from '../../components/ItemsTableCell';
import ItemsTableValue from '../../components/ItemsTableValue';
var BooleanColumn = React.createClass({
displayName: 'BooleanColumn',
propTypes: {
col: React.PropTypes.object,
... |
client/src/components/Course.js | AlexQianjin/aquarius | import React from 'react';
import Card from '@mui/material/Card';
import CardContent from '@mui/material/CardContent';
import Typography from '@mui/material/Typography';
function Course(courseItem, index, dayofweek) {
const bull = <span
style={{
display: 'inline-block',
margin: '0 2... |
docs/app/Examples/collections/Form/States/FormExampleFieldDisabled.js | ben174/Semantic-UI-React | import React from 'react'
import { Form, Input } from 'semantic-ui-react'
const FormExampleFieldDisabled = () => (
<Form>
<Form.Group widths='equal'>
<Form.Input label='First name' placeholder='Disabled' disabled />
<Form.Input label='Last name' placeholder='Disabled' disabled />
</Form.Group>
... |
packages/example-react-native/index.ios.js | RafalFilipek/fela | import React from 'react'
import { AppRegistry } from 'react-native'
import { createRenderer } from 'fela-native'
import { Provider } from 'react-fela'
import nativeMediaQuery, {
DimensionProvider
} from 'fela-plugin-native-media-query'
import App from './App'
const renderer = createRenderer({ plugins: [nativeMedia... |
src/parser/warlock/demonology/modules/features/Felstorm.js | sMteX/WoWAnalyzer | import React from 'react';
import Analyzer, { SELECTED_PLAYER, SELECTED_PLAYER_PET } from 'parser/core/Analyzer';
import calculateMaxCasts from 'parser/core/calculateMaxCasts';
import SPELLS from 'common/SPELLS';
import SpellLink from 'common/SpellLink';
import { formatPercentage } from 'common/format';
import Events... |
src/frontend/components/forms/GCFormField.js | al3x/ground-control | import React from 'react';
export default class GCFormField extends React.Component {
floatingLabelText() {
return this.props.floatingLabelText === false ? null : this.props.floatingLabelText || this.props.label;
}
}
|
app/containers/tutorial/fourth.js | DeividasK/tgoals | import React from 'react'
import SimpleList from 'components/lists/simple'
import { updateStep, updateHeading, updateActions } from '../../actions/TutorialActions'
import { FormattedMessage, defineMessages, injectIntl } from 'react-intl'
const content = defineMessages({
title: { id: 'app.tutorial.step4.title', defaul... |
src/index.js | findinstore/instore-landing | import React from 'react';
import ReactDOM from 'react-dom';
import App from './components/App';
ReactDOM.render(<App />, document.getElementById('root'));
|
app/src/js/components/weekly/weekly.js | tahnik/devRantron | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import Column from '../columns/column';
import rantscript from '../../consts/rantscript';
import WeeklyItem from './weekly_item';
class Weekly extends Component {
constructor() {
super();
this.state = {
weeks: [],
selec... |
src/js/components/words/WordsList.js | mikka22pl/glossa | import React from 'react';
import WordGroups from './WordGroups';
class WordsList extends React.Component {
constructor(props) {
super(props);
this.state = {
activeItem: 0
};
this.removeLexer = this.removeLexer.bind(this);
// this.onClickHandler = this.onClickHandler.bind(this);
}
onCl... |
src/index.js | jlmonroy13/brainstutor-client | /* eslint-disable import/default */
import React from 'react';
import {render} from 'react-dom';
import { Provider } from 'react-redux';
import { Router, browserHistory } from 'react-router';
import routes from './routes';
import configureStore from './store/configureStore';
require('./favicon.ico'); // Tell webpack t... |
examples/auth-with-shared-root/components/Login.js | tylermcginnis/react-router | import React from 'react'
import { withRouter } from 'react-router'
import auth from '../utils/auth.js'
const Login = React.createClass({
getInitialState() {
return {
error: false
}
},
handleSubmit(event) {
event.preventDefault()
const email = this.refs.email.value
const pass = this.r... |
static/src/js/pages/Resources.js | enginyoyen/blackcrystal | import React from 'react';
import NavMain from '../components/navigation/NavMain';
import PageFooter from '../components/PageFooter';
import PageHeader from '../components/PageHeader';
import { resourcesURI } from '../utils/Config'
import { Link } from 'react-router';
import { Grid, Row, Col } from 'react-bootstrap';
... |
fields/types/Field.js | wustxing/keystone | import _ from 'underscore';
import classnames from 'classnames';
import evalDependsOn from '../utils/evalDependsOn.js';
import React from 'react';
import { Button, FormField, FormInput, FormNote } from 'elemental';
function validateSpec(spec) {
if (!spec) spec = {};
if (!_.isObject(spec.supports)) {
spec.supports ... |
definitions/npm/react-i18next_v1.10.x/test_react-i18next_v1.10.x.js | mwalkerwells/flow-typed | // @flow
import React from 'react'
import {
loadNamespaces,
translate,
I18nextProvider,
Interpolate,
} from 'react-i18next'
import type { TFunction, Translator } from 'react-i18next'
const i18n = { loadNamespaces: () => {} };
<I18nextProvider i18n={ i18n } children={ <div /> } />;
// $ExpectError - missing ... |
templates/rubix/redux/redux-example/src/common/sidebar.js | jeffthemaximum/Teachers-Dont-Pay-Jeff | import React from 'react';
import {
Sidebar, SidebarNav, SidebarNavItem,
SidebarControls, SidebarControlBtn,
LoremIpsum, Grid, Row, Col, FormControl,
Label, Progress, Icon,
SidebarDivider
} from '@sketchpixy/rubix';
import { Link, withRouter } from 'react-router';
@withRouter
class ApplicationSidebar exten... |
src/.stories/Onboard.js | kctang/mdl-ui | import React from 'react';
import * as Mdl from 'react-mdl';
import { storiesOf, action } from '@kadira/storybook';
import { Onboard } from '../index';
storiesOf('Onboard', module)
.add('Default behavior', () => <Onboard />)
.add('2 slides', () => {
const props = {
slides: [
<div>Page 1</div>
... |
src/packages/@ncigdc/modern_components/GeneSymbol/GeneSymbol.js | NCI-GDC/portal-ui | // @flow
import React from 'react';
import { head, get } from 'lodash';
import { compose, branch, renderComponent } from 'recompose';
export default compose(
branch(
({ viewer }) => !get(viewer, 'explore.genes.hits.edges[0]'),
renderComponent(() => <div>No gene found.</div>),
),
)(({ viewer: { explore } }... |
uis/mp-react/src/components/SongsGridList.js | andrew-hai/bdgt | import React from 'react';
import PropTypes from 'prop-types'
import { connect } from 'react-redux'
import { GridList, GridTile } from 'material-ui/GridList';
import IconButton from 'material-ui/IconButton';
import Subheader from 'material-ui/Subheader';
// import StarBorder from 'material-ui/svg-icons/toggle/star-bo... |
src/components/search_bar.js | broodfusion/react-udemy | import React from 'react';
class SearchBar extends React.Component {
render() {
return <input onChange={this.onInputChange}/>;
}
onInputChange(event) {
console.log(event.target.value);
}
};
module.exports = SearchBar; |
JavaScript/React/React+Flux+Auth/test/helpers/shallowRenderHelper.js | batazor/MyExampleAndExperiments | /**
* 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'... |
app/jsx/gradebook/default_gradebook/GradebookGrid/headers/CustomColumnHeaderRenderer.js | djbender/canvas-lms | /*
* 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/mobile/screens/SignUpScreen/SignUpScreen.js | denistakeda/LifeBalance | import React from 'react';
import {
StyleSheet,
Text,
View,
TextInput,
} from 'react-native';
import Relay from 'react-relay';
import { Actions, ActionConst } from 'react-native-router-flux';
import {
mainTextColor,
normalTextSize,
greyColor,
errorColor,
linkColor,
} from '../../config/StyleConst';
im... |
react-flux-mui/js/material-ui/src/svg-icons/toggle/indeterminate-check-box.js | pbogdan/react-flux-mui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ToggleIndeterminateCheckBox = (props) => (
<SvgIcon {...props}>
<path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 10H7v-2h10v2z"/>
</SvgIcon>
);
ToggleIndeterminateCheck... |
src/examples/image_carousel/imageViewer.js | looker-open-source/custom_visualizations_v2 | import React from 'react';
import { Carousel } from 'react-responsive-carousel';
const URLREGEX = new RegExp("((http|https)(:\/\/))?([a-zA-Z0-9]+[.]{1}){2}[a-zA-Z0-9]+(\/{1}[a-zA-Z0-9]+)*\/?", "igm");
// Regular expression to check formal correctness of base64 encoded strings
// https://developer.mozilla.org/en-US/doc... |
src/routes.js | tsaarni/docker-npm-builder | import React from 'react';
import { Route, IndexRoute } from 'react-router';
import App from './components/App';
import HomePage from './components/HomePage';
import FuelSavingsPage from './containers/FuelSavingsPage'; // eslint-disable-line import/no-named-as-default
import AboutPage from './components/AboutPage.js';... |
subjects/MiniRedux/exercise/mini-redux/connect.js | integral-llc/react-interview | import React from 'react'
export default function connect(mapStateToProps) {
return function (Component) {
return Component
}
}
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.