path stringlengths 5 296 | repo_name stringlengths 5 85 | content stringlengths 25 1.05M |
|---|---|---|
src/containers/Asians/TabControls/_components/TeamChip/index.js | westoncolemanl/tabbr-web | import React from 'react'
import { connect } from 'react-redux'
import Avatar from 'material-ui/Avatar'
import Chip from 'material-ui/Chip'
export default connect(mapStateToProps)(({
team,
teamStandings,
teamsById,
institutionsById,
round
}) => {
return (
<Chip
avatar={
<Avatar>
... |
app/features/landing/Form.js | Kaniwani/KW-Frontend | import React from 'react';
import PropTypes from 'prop-types';
import { compose, lifecycle } from 'recompose';
import { reduxForm, Field } from 'redux-form';
import { WK_API_KEY_URL } from 'common/constants';
import {
requiredValid,
emailValid,
minLengthValid,
confirmPasswordValid,
} from 'common/validations';... |
src/containers/Review/Content.js | pmg1989/lms_mobile | import React from 'react'
import PropTypes from 'prop-types'
import Immutable from 'immutable'
import moment from 'moment'
import styles from './Content.less'
const Content = ({ info, comment, curLesson }) => {
const commentText = comment.getIn(['suggestion', 'student'])
const gradeTime = info.get('gradetime')
r... |
src/app/components/ProductDetail.js | akzuki/BoardgameAPI | import React from 'react';
import { Carousel } from './Carousel';
import { Link } from 'react-router';
import {Router, Route, browserHistory, IndexRoute} from 'react-router';
export class ProductDetail extends React.Component {
constructor() {
super();
this.state = { item: {}, store: {} };
}
... |
index.js | asarode/react-pokemon | 'use strict';
import React from 'react';
import cx from 'classname';
import axios from 'axios';
import Promise from 'bluebird';
import capitalize from 'capitalize';
import empty from 'is-empty';
class Pokemon extends React.Component {
constructor(props) {
super(props);
this.state = {
pokemon: {},
... |
packages/television/src/components/Tags/Documents.js | accosine/poltergeist | import React from 'react';
import { styled } from 'styletron-react';
import Link from '../Link';
import { withTheme } from '../../util/ThemeContext';
import formatDate from '../../util/formatDate';
const Article = withTheme(
styled('div', ({ $theme, $collection }) => ({
display: 'flex',
flexDirection: 'colu... |
src/svg-icons/navigation/chevron-right.js | lawrence-yu/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let NavigationChevronRight = (props) => (
<SvgIcon {...props}>
<path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/>
</SvgIcon>
);
NavigationChevronRight = pure(NavigationChevronRight);
NavigationChevronRigh... |
node_modules/bs-recipes/recipes/webpack.react-hot-loader/app/js/main.js | CAIOFCP/telocoach | import React from 'react';
import { render } from 'react-dom';
// It's important to not define HelloWorld component right in this file
// because in that case it will do full page reload on change
import HelloWorld from './HelloWorld.jsx';
render(<HelloWorld />, document.getElementById('react-root'));
|
packages/cp-frontend/test/unit/components/messaging/warning.js | yldio/copilot | /**
* @jest-environment jsdom
*/
import React from 'react';
import renderer from 'react-test-renderer';
import 'jest-styled-components';
import Warning from '@components/messaging/warning';
it('renders <Warning /> without throwing', () => {
const tree = renderer.create(<Warning message="Warning message" />).toJS... |
tests/mocha/unit-tests/react/components/CoreFonts/core.font.list.results.spec.js | blueliquiddesigns/gravity-forms-pdf-extended | import React from 'react'
import { shallow, mount } from 'enzyme'
import { createHashHistory } from 'history'
import CoreFontListResults from '../../../../../../src/assets/js/react/components/CoreFonts/CoreFontListResults'
describe('<CoreFontListResults />', () => {
it('Render nothing', () => {
const comp = sha... |
react-ui/src/components/Reviewer/Dashboard.js | civicparty/legitometer | import React from 'react';
import axios from 'axios';
import ReviewList from './ReviewList';
class StudentDashboard extends React.Component {
constructor() {
super();
this.state = {
missions: [],
}
}
componentWillMount() {
axios.get('/api/missions')
.then((res) => {
this.set... |
demos/demo/src/components/Client/Header.js | FWeinb/cerebral | import React from 'react'
export default function ClientHeader ({item}) {
return (
<div className='media'>
<div className='media-left'>
<figure className='image is-32x32'>
{typeof item.$imageProgress !== 'undefined'
? <progress className='progress is-small'
value={it... |
src/components/fleet/locations/LocationContainer.js | fusionalliance/autorenter-react | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { bindActionCreators } from 'redux';
import { connect } from 'react-redux';
import * as LocationActions from '../../../actions/LocationGenerators';
import LocationList from './LocationList';
import AddNewButton from '../../common/AddNe... |
modules/__tests__/History-test.js | ThibWeb/react-router | /*eslint-env mocha */
import expect from 'expect'
import React from 'react'
import History from '../History'
import Router from '../Router'
import Route from '../Route'
import createHistory from 'history/lib/createMemoryHistory'
describe('History Mixin', function () {
var node
beforeEach(function () {
node = d... |
example/src/screens/transitions/sharedElementTransitions/Masonry/Item.js | coteries/react-native-navigation | import React from 'react';
import {StyleSheet, View, Text, Image} from 'react-native';
import {SharedElementTransition} from 'react-native-navigation';
const SHOW_DURATION = 240;
const HIDE_DURATION = 200;
class Item extends React.Component {
static navigatorStyle = {
navBarHidden: true,
drawUnderNavBar: t... |
src/components/common/svg-icons/hardware/phonelink.js | abzfarah/Pearson.NAPLAN.GnomeH | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let HardwarePhonelink = (props) => (
<SvgIcon {...props}>
<path d="M4 6h18V4H4c-1.1 0-2 .9-2 2v11H0v3h14v-3H4V6zm19 2h-6c-.55 0-1 .45-1 1v10c0 .55.45 1 1 1h6c.55 0 1-.45 1-1V9c0-.55-.45-1-1-1zm-1 9h-4v-7h4v7z"/>
... |
docs/src/js/prettify.js | wuguanghai45/react-ui | 'use strict'
import React from 'react'
export default function prettify (Component) {
class Prettify extends React.Component {
static displayName = 'Prettify'
static propTypes = {
children: React.PropTypes.array
}
componentDidMount () {
window.prettyPrint(null, React.findDOMNode(this.r... |
server/sonar-web/src/main/js/components/mixins/tooltips-mixin.js | joansmith/sonarqube | /*
* SonarQube
* Copyright (C) 2009-2016 SonarSource SA
* mailto:contact AT sonarsource DOT com
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 3 of the License... |
src/post/LikesList.js | Sekhmet/busy | import React, { Component } from 'react';
import { Link } from 'react-router';
import numeral from 'numeral';
import Avatar from '../widgets/Avatar';
import { ProfileTooltipOrigin } from '../widgets/tooltip/ProfileTooltip';
import {
getUpvotes,
getDownvotes,
} from '../helpers/voteHelpers';
import './LikesList.scss... |
src/Grid.js | victorzhang17/react-bootstrap | import React from 'react';
import classNames from 'classnames';
import CustomPropTypes from './utils/CustomPropTypes';
const Grid = React.createClass({
propTypes: {
/**
* Turn any fixed-width grid layout into a full-width layout by this property.
*
* Adds `container-fluid` class.
*/
fluid... |
packages/cf-component-input/example/basic/component.js | mdno/mdno.github.io | import React from 'react';
import { Input } from 'cf-component-input';
class InputComponent extends React.Component {
constructor(props) {
super(props);
this.state = {
inputValue: 'Hello World'
};
this.handleChange = this.handleChange.bind(this);
}
handleChange(e) {
const value = e.tar... |
internals/templates/notFoundPage.js | PanJ/SimplerCityGlide | /**
* NotFoundPage
*
* This is the page we show when the user visits a url that doesn't have a route
*
* NOTE: while this component should technically be a stateless functional
* component (SFC), hot reloading does not currently support SFCs. If hot
* reloading is not a neccessity for you then you can refactor i... |
client/app/components/Button/index.js | Kielan/onDemanager | /**
*
* Button.react.js
*
* A common button, if you pass it a prop "route" it'll render a link to a react-router route
* otherwise it'll render a link with an onclick
*/
import React from 'react';
import styles from './styles.css';
function Button(props) {
const className = props.className ? props.className ... |
src/svg-icons/device/location-disabled.js | kasra-co/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let DeviceLocationDisabled = (props) => (
<SvgIcon {...props}>
<path d="M20.94 11c-.46-4.17-3.77-7.48-7.94-7.94V1h-2v2.06c-1.13.12-2.19.46-3.16.97l1.5 1.5C10.16 5.19 11.06 5 12 5c3.87 0 7 3.13 7 7 0 .94-.19 1.84-.5... |
lib/components/modifications-map/__tests__/draw-polygon.js | conveyal/scenario-editor | // @flow
import React from 'react'
import {Map} from 'react-leaflet'
import renderer from 'react-test-renderer'
import DrawPolygon from '../draw-polygon'
describe('Project-Map > DrawPolygon', () => {
it('works correctly', () => {
const tree = renderer
.create(
<Map>
<DrawPolygon
... |
temp/Boy.js | duangangqiang/GitHubTrending | import React, { Component } from 'react';
import {
View,
Text,
TouchableOpacity,
Image,
StyleSheet
} from 'react-native';
import Girl from './Girl';
import NavigationBar from './NavigationBar';
export default class Boy extends Component {
constructor(props) {
super(props);
thi... |
docs/app/Examples/elements/Reveal/Content/RevealExampleHidden.js | mohammed88/Semantic-UI-React | import React from 'react'
import { Image, Reveal } from 'semantic-ui-react'
const RevealExampleHidden = () => (
<Reveal animated='small fade'>
<Reveal.Content visible>
<Image src='http://semantic-ui.com/images/wireframe/square-image.png' size='small' />
</Reveal.Content>
<Reveal.Content hidden>
... |
src/components/common/svg-icons/av/web.js | abzfarah/Pearson.NAPLAN.GnomeH | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let AvWeb = (props) => (
<SvgIcon {...props}>
<path d="M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-5 14H4v-4h11v4zm0-5H4V9h11v4zm5 5h-4V9h4v9z"/>
</SvgIcon>
);
AvWeb = pur... |
docs/app/Examples/collections/Grid/Variations/GridExampleVerticalAlignmentRow.js | mohammed88/Semantic-UI-React | import React from 'react'
import { Grid, Image } from 'semantic-ui-react'
const GridExampleVerticalAlignmentRow = () => (
<Grid columns={4} centered>
<Grid.Row verticalAlign='top'>
<Grid.Column>
<Image src='http://semantic-ui.com/images/wireframe/image.png' />
</Grid.Column>
<Grid.Colum... |
app/containers/App/AppFooter/index.js | josueorozco/parlay | import React from 'react';
import classNames from 'classnames';
/*
|--------------------------------------------------------------------------
| AppFooter
|--------------------------------------------------------------------------
|
| Stateless component
|
*/
const AppFooter = props => (
<div
className={c... |
app/components/IssueIcon/index.js | nimzco/takemyidea-ui | import React from 'react';
class IssueIcon extends React.Component {
render() {
return (
<svg
height="1em"
width="0.875em"
className={ this.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.1... |
src/components/profile/DeleteProfile.js | Team-Banana-Guava/JobOrNot-React | import React from 'react';
import { connect } from 'react-redux';
import { deleteProfile } from '../../actions/DeleteProfile-actions';
import { Link } from 'react-router-dom';
import { userLogoutSuccess } from '../../actions/auth-actions';
class DeleteProfile extends React.Component {
constructor(props) {
... |
server/frontend/components/CenteredLayout/CenteredLayout.js | AlexHatesUnicorns/FDTD_Solver | import React from 'react';
import styles from './CenteredLayout.css';
export const CenteredLayout = ({ children }) => (
<div className={styles.container}>
{children}
</div>
);
export default CenteredLayout;
|
src/components/forms/reset-password/ResetPasswordSent.js | LenaKari/happy-days | import React, { Component } from 'react';
import { Link } from 'react-router-dom';
// MaterialUI
import RaisedButton from 'material-ui/RaisedButton';
class ResetPasswordSent extends Component {
render() {
return (
<div>
<p>An email has been sent to the address provided with instructions on how to reset you... |
src/svg-icons/action/info.js | lawrence-yu/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionInfo = (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 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"/>
</SvgIcon>
);
ActionInfo = pure(ActionInfo);
ActionI... |
test/createDevTools.spec.js | hetony/redux-devtools | import expect from 'expect';
import jsdom from 'mocha-jsdom';
import React, { Component } from 'react';
import TestUtils from 'react-addons-test-utils';
import createDevTools from '../src/createDevTools';
import devTools from '../src/devTools';
import { createStore } from 'redux';
class MockMonitor extends Component {... |
src/components/pages/ColorInteractionsPage/index.js | RussHR/github_page_src | import React from 'react';
import ContentLayout from '../../layout/ContentLayout';
import VideoIFrame from '../../VideoIFrame';
export default function HomageToBarraganPage() {
return (
<ContentLayout header="color interactions"
subheader="completed - march 2017"
... |
examples/counter-2/src/Button.js | rerx/rerx | import React, { Component } from 'react';
import { dispatch } from 'rerx/core';
import { helper } from 'rerx/utils';
export class Button extends Component {
constructor(props) {
super(props);
const thisEvent = helper.thisEvent.bind(this);
this.event = {
click: thisEvent('click')
};
this.... |
src/components/Notification/Notification.js | joshblack/carbon-components-react | /**
* Copyright IBM Corp. 2016, 2018
*
* This source code is licensed under the Apache-2.0 license found in the
* LICENSE file in the root directory of this source tree.
*/
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import classNames from 'classnames';
import { settings } from '... |
src/components/SponsorsItem/SponsorsItem.js | hack-duke/hackduke-ideate-website | import React from 'react'
import classes from './SponsorsItem.scss'
const determineSize = (size) => {
switch (size) {
case 4:
return {'maxWidth': '375px'}
case 3:
return {'maxWidth': '225px', 'maxHeight': '150px'}
case 2:
return {'maxWidth': '150px'}
case 1:
return {'maxWidth'... |
assets/jqwidgets/demos/react/app/chart/chartcrosshairs/app.js | juannelisalde/holter | import React from 'react';
import ReactDOM from 'react-dom';
import JqxChart from '../../../jqwidgets-react/react_jqxchart.js';
class App extends React.Component {
render() {
let source =
{
datatype: 'csv',
datafields: [
{ name: 'Date' },
... |
tp-3/recursos/react-slingshot/src/components/Root.js | jpgonzalezquinteros/sovos-reactivo-2017 | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import App from './App';
import { BrowserRouter as Router } from 'react-router-dom';
export default class Root extends Component {
render() {
return (
<Router>
<App />
</Router>
);
}
}
Root.propTypes = {
h... |
src/helpers/__tests__/connectData-test.js | sseppola/react-redux-universal-hot-example | import { expect } from 'chai';
import React from 'react';
import { div } from 'react-dom';
import connectData from '../connectData';
describe('connectData', () => {
let fetchData;
let fetchDataDeferred;
let WrappedComponent;
let DataComponent;
beforeEach(() => {
fetchData = 'fetchDataFunction';
fetc... |
imports/old/signup/dob.js | jiyuu-llc/jiyuu | import React from 'react';
const DOB = () => ({
dobNext(){
var data = $("#questionInput").val();
if(data){
Session.set('dob', data);
FlowRouter.go("/register/8");
}else{
alert("Please enter your birthday.");
}
},
render() {
return (
<div id="jiyuu">
<h2 cla... |
voting_app/frontend/src/containers/CreatePollContainer.js | azaleas/sentio | import React, { Component } from 'react';
import ReactDOM from 'react-dom';
import PropTypes from 'prop-types';
import Redirect from 'react-router-dom/Redirect';
import {api} from './../utils/Api';
class CreatePollContainer extends Component {
constructor(props) {
super(props);
this.state = {
... |
src/parser/shaman/elemental/modules/checklist/Module.js | fyruna/WoWAnalyzer | import React from 'react';
import BaseChecklist from 'parser/shared/modules/features/Checklist/Module';
import CastEfficiency from 'parser/shared/modules/CastEfficiency';
import Combatants from 'parser/shared/modules/Combatants';
import PreparationRuleAnalyzer from 'parser/shared/modules/features/Checklist/Preparation... |
docs/src/app/components/pages/discover-more/Showcase.js | ichiohta/material-ui | import React from 'react';
import Title from 'react-title-component';
import {GridList, GridTile} from 'material-ui/GridList';
import IconButton from 'material-ui/IconButton';
import FontIcon from 'material-ui/FontIcon';
import MarkdownElement from '../../MarkdownElement';
import showcaseText from './showcase.md';
con... |
test/helpers/shallowRenderHelper.js | puregardenia/gallery-by-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'... |
public/app/index.js | crimsonskyrem/BetaAssisstant | import React from 'react';
import ReactDOM from 'react-dom';
import { Router, Route, hashHistory} from 'react-router'
import IndexHello from './components/IndexHello';
import NotFound from './components/NotFound';
import Usr from './components/Usr';
ReactDOM.render(
(
<Router history={hashHistory}>
... |
src/components/AlbumPhotos.js | qubbit/gopal.io | import React, { Component } from 'react';
import { connect } from 'react-redux';
import { fetchAlbumPhotos } from '../actions';
import Loader from './Loader';
import Gallery from 'react-photo-gallery';
import Measure from 'react-measure';
import Lightbox from 'react-images';
class AlbumPhotos extends Component {
com... |
examples/src/components/App.js | kenfehling/react-designable-audio-player | import React from 'react';
import Simple from './Simple';
import WithPlaylist from './WithPlaylist';
import Unstyled from './Unstyled';
import CustomPlaylist from './CustomPlaylist';
import Fixed from './Fixed';
const rowStyle = {display: 'flex', marginTop: '40px'};
const playlistContainerStyle = {margin: 'auto'};
ex... |
app/components/Footer.js | kensworth/olyranks | import React from 'react';
import {Link} from 'react-router';
import FooterStore from '../stores/FooterStore'
import FooterActions from '../actions/FooterActions';
class Footer extends React.Component {
constructor(props) {
super(props);
this.state = FooterStore.getState();
this.onChange = this.onChange.... |
styleguide/Styleguide.js | rdjpalmer/bloom | import React, { Component } from 'react';
import { BrowserRouter, Switch, Route } from 'react-router-dom';
import SiteHeader from './components/SiteHeader/SiteHeader';
import Navigation from './components/Navigation/Navigation';
import OffCanvasPanel from './components/OffCanvasPanel/OffCanvasPanel';
import BtnContain... |
src/Popover.js | aparticka/react-bootstrap | import React from 'react';
import classNames from 'classnames';
import BootstrapMixin from './BootstrapMixin';
import CustomPropTypes from './utils/CustomPropTypes';
const Popover = React.createClass({
mixins: [ BootstrapMixin ],
propTypes: {
/**
* An html id attribute, necessary for accessibility
... |
docs/src/components/clients/Filters.js | tannerlinsley/react-table | import React from 'react'
export const Filters = () => (
<>
<svg width={0} height={0}>
<defs>
<filter id="high-threshold">
<feColorMatrix type="saturate" values="0" />
<feComponentTransfer>
<feFuncR type="discrete" tableValues="0" />
<feFuncG type="discret... |
src/index.js | rindhane/totalsolv | import React from 'react';
import ReactDOM from 'react-dom';
import './index.css';
import App from './App';
import reportWebVitals from './reportWebVitals';
ReactDOM.render(
<React.StrictMode>
<App />
</React.StrictMode>,
document.getElementById('root')
);
// If you want to start measuring performance in yo... |
src/app.js | saschaishikawa/planetary-response-network | import React from 'react';
import ReactDOM from 'react-dom';
import { Router, IndexRoute, Route } from 'react-router';
import createBrowserHistory from 'history/lib/createBrowserHistory';
import { IndexPage, UploadPage, BuildsPage, SettingsPage, LoginPage } from './pages';
ReactDOM.render(
<Router history={createBro... |
src/js/routes/Multiplier/components/Multiplier.js | vladiibine/trust-network | import React from 'react'
export const Multiplier = (props) => (
<div style={{ margin: '0 auto' }} >
<h2>Multiplier: {props.counter}</h2>
<button className='btn btn-default' onClick={props.increment}>
Double
</button>
{' '}
<button className='btn btn-default' onClick={props.doubleAsync}>
... |
pathfinder/vtables/appmap2etom/src/common/TableUtilities.js | leanix/leanix-custom-reports | import React from 'react';
import Utilities from './Utilities';
import Link from './Link';
import LinkList from './LinkList';
/* formatting functions for the table */
const OVERFLOW_CELL_STYLE = {
maxHeight: '100px',
overflow: 'auto'
};
function formatLinkFactsheet(setup) {
const baseUrl = Utilities.getFrom(setup... |
src/index.js | brychanrobot/recipes | import React from 'react'
import ReactDOM from 'react-dom'
import Root from './components/Root'
import store from './store'
ReactDOM.render(
<Root store={store} />,
document.getElementById('root')
)
|
pages/roster/men.js | cindytung/calwtcrew | import React from 'react';
import Roster from '../../components/Roster';
import photo from '../../assets/images/mensroster.jpg';
import '../../css/rosters.scss';
const RosterPage = () => (
<div className="container">
<div className="page__header">
2015-2016 Varsity & Novice Men
</div>
<div classNa... |
src/layouts/header.js | kevin-roark/spaghettis-site | import React from 'react'
const Header = () => null
export default Header
|
src/index.js | NazarenoL/smart-mirror-front | import React from 'react';
import ReactDOM from 'react-dom';
import AppContainer from './components/AppContainer';
import '../styles/base.scss';
ReactDOM.render(
<AppContainer />,
document.getElementById('root')
);
|
src/TableViewCell.js | aksonov/react-native-tableview | import React from 'react';
import { requireNativeComponent } from 'react-native';
const RNCellView = requireNativeComponent('RNCellView', null);
export default class TableViewCell extends React.Component {
constructor(props) {
super(props);
this.state = { width: 0, height: 0 };
}
render() {
return ... |
src/components/MessageView.js | saas-plat/saas-plat-native | import React from 'react';
import {
View,
Text,
Platform,
StatusBar,
TouchableOpacity
} from 'react-native';
import {autobind} from 'core-decorators';
import {connectStyle} from '../core/Theme';
import {translate} from '../core/I18n';
import { tx } from '../utils/internal';
// 消息提示
@translate('core.MessageVi... |
ui/src/components/Switch.js | untoldwind/eightyish | import React from 'react'
import shallowEqual from '../util/shallowEqual'
export default class Switch extends React.Component {
static propTypes = {
onText: React.PropTypes.string.isRequired,
offText: React.PropTypes.string.isRequired,
id: React.PropTypes.string,
label: React.PropT... |
test/specs/elements/Icon/Icon-test.js | clemensw/stardust | import React from 'react'
import Icon from 'src/elements/Icon/Icon'
import IconGroup from 'src/elements/Icon/IconGroup'
import * as common from 'test/specs/commonTests'
describe('Icon', () => {
common.isConformant(Icon)
common.hasSubComponents(Icon, [IconGroup])
common.implementsCreateMethod(Icon)
common.prop... |
app/javascript/flavours/glitch/features/ui/components/tabs_bar.js | Kirishima21/mastodon | import React from 'react';
import PropTypes from 'prop-types';
import { NavLink, withRouter } from 'react-router-dom';
import { FormattedMessage, injectIntl } from 'react-intl';
import { debounce } from 'lodash';
import { isUserTouching } from 'flavours/glitch/util/is_mobile';
import Icon from 'flavours/glitch/componen... |
src/client/app/panels/assign.dashboard.panel.js | mapkiwiz/sectorisation | import React from 'react';
import {MenuLink} from './menu.link';
export function AssignDashboardPanel(props, context) {
return (
<div className="col-md-4 col-md-offset-8 panel-container">
<h3>
Tableau de bord
<MenuLink />
</h3>
<hr/>
<p className="help-block">Pas encore im... |
react-weather-forecast/src/index.js | majalcmaj/ReactJSCourse | import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from 'react-redux';
import { createStore, applyMiddleware } from 'redux';
import ReduxPromise from 'redux-promise';
import App from './components/app';
import reducers from './reducers';
const createStoreWithMiddleware = applyMiddleware(... |
src/routes/routes.react.js | ricca509/geckboard_challenge | import React from 'react';
import Router from 'react-router';
import App from '../components/App/App.react.js';
import ReposController from '../components/ReposController/ReposController.react.js';
import RepoDetailsController from '../components/RepoDetailsController/RepoDetailsController.react.js';
let Route = Route... |
src/app/components/navigation/components/NavMenuItem.js | backpackcoder/world-in-flames | import React from 'react'
import {Link} from 'react-router'
import Msg from '../../i18n/Msg'
import SmartMenuList from './NavMenuList'
export default class SmartMenuItem extends React.Component {
static contextTypes = {
router: React.PropTypes.object.isRequired
};
render() {
const item = this.props.i... |
src/Parser/Warlock/Affliction/Modules/Items/Legendaries/TheMasterHarvester.js | enragednuke/WoWAnalyzer | import React from 'react';
import ITEMS from 'common/ITEMS';
import Analyzer from 'Parser/Core/Analyzer';
import Combatants from 'Parser/Core/Modules/Combatants';
import ItemDamageDone from 'Main/ItemDamageDone';
import SoulHarvest from '../../Talents/SoulHarvest';
class TheMasterHarvester extends Analyzer {
stati... |
src/js/components/Remembers.js | amovah/DiveTodo | import React, { Component } from 'react';
import {
removeRemember,
editRemember,
showModal,
moveRemember
} from '../actions';
export default class extends Component {
constructor() {
super();
this.editRemember = this.editRemember.bind(this);
}
editRemember(text, id) {
this.props.dispatch(sho... |
client/index.js | michaelkirschbaum/ender-site | /**
* Client entry point
*/
import React from 'react';
import { render } from 'react-dom';
import { AppContainer } from 'react-hot-loader';
import App from './App';
import { configureStore } from './store';
// Initialize store
const store = configureStore(window.__INITIAL_STATE__);
const mountApp = document.getEleme... |
test/index.spec.js | JLHwung/react-props-viewer | import { test } from 'tap'
import React from 'react'
import Enzyme, { shallow } from 'enzyme'
import Adapter from 'enzyme-adapter-react-16'
import JSONTree from 'react-json-tree'
import PropsViewer from '../src'
Enzyme.configure({ adapter: new Adapter() })
test('props-viewer should generate a component', (t) => {
... |
src/pages/404.js | muniz95/muniz95.github.io | import React from 'react'
import { Link } from 'gatsby'
import styled from 'styled-components'
import SEO from '../components/Seo'
import GlobalStyles from '../styles/global'
const Container = styled.section`
align-items: center;
background-image: url('https://muniz95.com.br/assets/img/john-404.gif');
backgroun... |
src/atoms/Trackable/index.js | policygenius/athenaeum | import React from 'react';
import PropTypes from 'prop-types';
import { dataAttributes } from './utils';
function wrappedChild(children, data) {
const child = React.Children.only(children);
if (child.type === Trackable) return child;
return React.cloneElement(child, data);
}
function Trackable(props) {
con... |
node_modules/bs-recipes/recipes/webpack.react-hot-loader/app/js/main.js | s941622/Angular2_angular-tour-of-heroes | import React from 'react';
import { render } from 'react-dom';
// It's important to not define HelloWorld component right in this file
// because in that case it will do full page reload on change
import HelloWorld from './HelloWorld.jsx';
render(<HelloWorld />, document.getElementById('react-root'));
|
node_modules/react-scripts/template/src/App.js | CodeShareRepeat/ReactBookStore | import React, { Component } from 'react';
import logo from './logo.svg';
import './App.css';
class App extends Component {
render() {
return (
<div className="App">
<div className="App-header">
<img src={logo} className="App-logo" alt="logo" />
<h2>Welcome to React</h2>
... |
app/js/views/Icons/SimpleLineIcons/SimpleLineIcons.js | jagatjeevan/dakiya | import React, { Component } from 'react';
class SimpleLineIcons extends Component {
render() {
return (
<div className="animated fadeIn">
<div className="card card-default">
<div className="card-header">
<i className="fa fa-picture-o" /> Simple Line Icons
</div>
... |
client/reactComponents/EnemyTank.js | ourvrisrealerthanyours/tanks | import React from 'react';
import Turret from './Turret';
import TankBody from './TankBody';
import LifeBar from './LifeBar';
import { TANK_RADIUS } from '../../simulation/constants';
class EnemyTank extends React.Component {
constructor(props) {
super(props);
this.radius = TANK_RADIUS;
this.rotation = ... |
index.android.js | fakerabbit/SenalesDelFinRNA | /**
* SenalesDelFin React Native App for Android
* https://github.com/facebook/react-native
* @flow
*/
'use strict';
import React from 'react';
const ReactNative = require('react-native');
const ListViewFeed = require('./ListViewFeed');
const AboutView = require('./AboutView');
const GoldNavHeaderBackBtn =... |
src/components/Search/Search.js | TalentedEurope/te-app | import React from 'react';
import { TabNavigator } from 'react-navigation';
import Icon from 'react-native-vector-icons/FontAwesome';
import Main from './Main/Main';
import SearchStudents from './Students/Students';
import SearchCompanies from './Companies/Companies';
import SearchInstitutions from './Institutions/Inst... |
quick-bench/src/App.js | FredTingaud/quick-bench-front-end | import React, { Component } from 'react';
import { Dropdown } from 'react-bootstrap';
import QuickBenchmark from './QuickBenchmark.js';
import Header from 'components/Header.js';
import 'components/resources/css/Shared.css';
import { BrowserRouter, Route, Redirect } from 'react-router-dom';
import AboutDialog from './d... |
docs/app/Examples/elements/Icon/IconSet/IconExampleMedia.js | ben174/Semantic-UI-React | import React from 'react'
import { Grid, Icon } from 'semantic-ui-react'
const IconExampleMedia = () => (
<Grid columns='5' doubling>
<Grid.Column>
<Icon name='area chart' />
<p>area chart</p>
</Grid.Column>
<Grid.Column>
<Icon name='bar chart' />
<p>bar chart</p>
</Grid.Colum... |
admin/templates/src/components/layout/footer.js | TangMonk/tuols | import React from 'react'
import styles from './main.less'
import { config } from '../../utils'
const Footer = () => <div className={styles.footer}>
{config.footerText}
</div>
export default Footer
|
es6/Breadcrumb/BreadcrumbItem.js | yurizhang/ishow | var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, des... |
docs/src/NavMain.js | gearz-lab/react-ui | import React from 'react';
import Router, { Link } from 'react-router';
import Navbar from 'react-bootstrap/lib/Navbar';
import Nav from 'react-bootstrap/lib/Nav';
const NAV_LINKS = {
'getting-started': {
link: 'getting-started',
title: 'Getting started'
},
'components': {
link: 'components',
tit... |
src/containers/Charts/echarts/dynamicChartComponent.js | EncontrAR/backoffice | import React, { Component } from 'react';
import { connect } from 'react-redux';
import ReactEcharts from 'echarts-for-react';
import { updateOption } from '../../../redux/dynamicEchart/reducer';
class DynamicChartComponent extends Component {
constructor(props) {
super(props);
this.fetchNewDate = this.fetch... |
Examples/WithGroups/index.js | bapmrl/bapmrl-react-multiselect | import React, { Component } from 'react';
import ReactDOM from 'react-dom';
import Multiselect from 'bapmrl-react-multiselect';
class WithGroups extends Component {
constructor(props) {
super(props);
this.state = {
items: {
'0': {
key: '0',
label: 'Group 0',
option... |
src/lib/Page.js | reapp/reapp-kit | import React from 'react';
import ContextTypes from './ContextTypes';
import ShouldUpdate from './ShouldUpdate';
import RoutedViewListMixin from 'reapp-routes/react-router/RoutedViewListMixin';
import AutoBind from './AutoBind';
import setupGetters from './setupGetters';
const Base = React.createClass(Object.assign(
... |
20161208/RN-router/index.ios.js | fengnovo/react-native | import React, { Component } from 'react';
import {
AppRegistry
} from 'react-native';
import App from './rn/app.js';
class RNRouter extends Component {
render() {
return <App />
}
}
AppRegistry.registerComponent('RNRouter', () => RNRouter);
|
src/svg-icons/image/looks-two.js | jacklam718/react-svg-iconx | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageLooksTwo = (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-4 8c0 1.11-.9 2-2 2h-2v2h4v2H9v-4c0-1.11.9-2 2-2h2V9H9V7h4c1.1 0 2 .89 2 ... |
examples/webpack-example/src/app/app.js | tan-jerene/material-ui | import React from 'react';
import ReactDOM from 'react-dom';
import injectTapEventPlugin from 'react-tap-event-plugin';
import Main from './Main'; // Our custom react component
//Needed for onTouchTap
//Can go away when react 1.0 release
//Check this repo:
//https://github.com/zilverline/react-tap-event-plugin
injectT... |
node_modules/styled-components/src/models/StyleTags.js | esteladiaz/esteladiaz.github.io | // @flow
/* eslint-disable flowtype/object-type-delimiter */
/* eslint-disable react/prop-types */
import React from 'react'
import { IS_BROWSER, DISABLE_SPEEDY, SC_ATTR } from '../constants'
import { type ExtractedComp } from '../utils/extractCompsFromCSS'
import { splitByRules } from '../utils/stringifyRules'
import... |
src/components/Admin/AdminStudents/Student.js | unihackhq/skilled-acolyte-frontend | import React from 'react';
import PropTypes from 'prop-types';
import { Link } from 'react-router-dom';
import { Button } from 'bloomer';
// TODO: make student specific UI
const Student = ({ student: s }) => (
<React.Fragment>
<pre>{JSON.stringify(s, null, 4)}</pre>
<Button
render={props => <Link to={`... |
src/components/Header.js | burakcan/framer-modules | import React, { Component } from 'react';
class Header extends Component {
render() {
return (
<header className="header">
<div className="container">
<h1 className="header_title">Framer modules</h1>
<a className="add-plugin" href="https://github.com/interacthings/framer-modules... |
imports/ui/components/FeedBacks/SurveyFeedBack/SurveyQuestion.js | haraneesh/mydev | /* eslint-disable max-len, no-return-assign */
import React from 'react';
import PropTypes from 'prop-types';
const SurveyQuestion = ({questionIndexNumber, questionText, ratingsObjectArray, selectedRatingValue, selectedRatingClass, onChange}) => {
let ratingRows = [];
const groupName = `groupName${questionIn... |
frontend/src/components/poll/voting/select.js | 1905410/Misago | // jshint ignore:start
import React from 'react';
export default function(props) {
return (
<ul className="list-unstyled poll-select-choices">
{props.choices.map((choice) => {
return (
<ChoiceSelect
choice={choice}
key={choice.hash}
toggleChoice={props.... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.