path stringlengths 5 195 | repo_name stringlengths 5 79 | content stringlengths 25 1.01M |
|---|---|---|
packages/xo-web/src/xo-app/backup/restore/delete-backups-modal-body.js | vatesfr/xo-web | import _ from 'intl'
import classNames from 'classnames'
import Component from 'base-component'
import React from 'react'
import { forEach, map, orderBy } from 'lodash'
import { createFilter, createSelector } from 'selectors'
import { Toggle } from 'form'
import { getRenderXoItemOfType } from 'render-xo-item'
const BA... |
src/Home/List/components/VirtualList/components/Survey/components/ErrorMessage.js | NERC-CEH/irecord-app | import React from 'react';
import { IonItemDivider, IonLabel } from '@ionic/react';
import { observer } from 'mobx-react';
import PropTypes from 'prop-types';
function ErrorMessage({ sample }) {
if (!sample.error.message) {
return null;
}
return (
<IonItemDivider color="danger">
<IonLabel class="i... |
examples/react/can-assign-array-to-jsx.js | kjirou/nodejs-codes | //
// Run by babel-node
//
import assert from 'assert';
import React, { Component } from 'react';
import { renderToStaticMarkup } from 'react-dom/server';
class Foo extends Component {
render() {
const items = [1, 2].map((v) => {
return <div key={v}>{v}</div>;
});
return <div>{ items }</div>;
... |
packages/nausicaa/src/components/AmpComponent.js | accosine/poltergeist | import React from 'react';
export default Element => ({ className, theme, ...props }) => (
<Element class={className} {...props} />
);
|
src/components/Post/Meta/Meta.js | colmdoyle/colmdoyle.github.io | // @flow strict
import React from 'react';
import styles from './Meta.module.scss';
type Props = {
date: string
};
const Meta = ({ date }: Props) => (
<div className={styles['meta']}>
<p className={styles['meta__date']}>Published {new Date(date).toLocaleDateString('en-US', { year: 'numeric', month: 'short', d... |
src/components/MessageContent.js | JailBreakC/react-redux-wechat | import React, { Component } from 'react';
import { Scrollbars } from 'react-custom-scrollbars';
import PropTypes from 'prop-types'
import MessageItem from './MessageItem'
import './MessageContent.less';
class MessageContent extends Component {
static propTypes = {
user: PropTypes.object.isRequired,
chat: Pro... |
app/javascript/mastodon/components/admin/Dimension.js | glitch-soc/mastodon | import React from 'react';
import PropTypes from 'prop-types';
import api from 'mastodon/api';
import { FormattedNumber } from 'react-intl';
import { roundTo10 } from 'mastodon/utils/numbers';
import Skeleton from 'mastodon/components/skeleton';
export default class Dimension extends React.PureComponent {
static pr... |
client/src/components/index.js | adityasharat/react-readable | import React, { Component } from 'react';
import { Link, Route, withRouter, Switch } from 'react-router-dom';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import '../css/font-awesome-4.7.0/css/font-awesome.min.css';
import '../css/index.css';
import { sortPost } from '../actions/PostActi... |
app/javascript/mastodon/features/account_timeline/containers/header_container.js | Kirishima21/mastodon | import React from 'react';
import { connect } from 'react-redux';
import { makeGetAccount } from '../../../selectors';
import Header from '../components/header';
import {
followAccount,
unfollowAccount,
unblockAccount,
unmuteAccount,
pinAccount,
unpinAccount,
} from '../../../actions/accounts';
import {
m... |
src/components/Sidebar/Menu/Menu.js | dalareo/dalareo.github.io | // @flow strict
import React from 'react';
import { Link } from 'gatsby';
import styles from './Menu.module.scss';
type Props = {
menu: {
label: string,
path: string
}[]
};
const Menu = ({ menu }: Props) => (
<nav className={styles['menu']}>
<ul className={styles['menu__list']}>
{menu.map((ite... |
src/components/Resume/A4Resume/Details.js | breezykermo/lachlankermode.com | import React from 'react'
const styles = {
details: {
display: 'flex',
justifyContent: 'center',
alignItems: 'center',
},
listElement: {
height: 20,
padding: 0,
marginBottom: 0,
},
list: {
listStyleType: 'none',
paddingLeft: '5px',
textAlign: 'right',
},
detail: {
... |
index.android.js | kesjien/member-cards | /**
* Sample React Native App
* https://github.com/facebook/react-native
* @flow
*/
import React, { Component } from 'react';
import {
AppRegistry,
StyleSheet,
Text,
View
} from 'react-native';
export default class MemberCards extends Component {
render() {
return (
<View style={styles.contain... |
src/containers/About/About.js | staszekj/react-redux-universal | import React, { Component } from 'react';
import Helmet from 'react-helmet';
import { MiniInfoBar } from 'components';
export default class About extends Component {
state = {
showKitten: false
}
handleToggleKitten = () => this.setState({ showKitten: !this.state.showKitten });
render() {
const { sho... |
src/browser/app/components/View.js | VigneshRavichandran02/3io | /* @flow */
import React from 'react';
import { Base } from 'rebass';
const View = (props: Object) => (
<Base {...props} is="div" />
);
export default View;
|
src/Month.js | atondelier/react-moment-datepicker | "use strict";
import moment from 'moment';
import momentPropTypes from 'react-moment-proptypes';
import React from 'react';
import classnames from 'classnames';
import './Month.css';
const Month = ({
displayedStartDate,
date,
defaultDate,
DayComponent = require('./Day.js'),
dayProps,
onSelect,... |
src/index.js | Addej018/react-presis | import React from 'react';
import ReactDOM from 'react-dom';
import App from './components/ProductListingPage';
ReactDOM.render(<App />, document.getElementById('root'));
|
src/components/HelloWorld/HelloWorld.js | xujihui1985/my-component | import React from 'react';
import PropTypes from 'prop-types';
/**
* A super lame component that says hello
*/
function HelloWorld({ message }) {
return (
<div>
Hello {message}
</div>
);
}
HelloWorld.propTypes = {
/**
* Message to display
*/
message: PropTypes.string,
};
HelloWorld.def... |
Depmon.Server.Portal.React/app/controllers/report.js | devmankz/Depmon | import React from 'react';
import Controller from '../base/controller';
import ReportView from '../views/report';
export default class ReportController extends Controller {
index (ctx, done) {
this.renderView(<ReportView />, done);
}
}
|
packages/react-interactions/events/src/dom/Tap.js | mjackson/react | /**
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
* @flow
*/
import type {
ReactDOMResponderContext,
ReactDOMResponderEvent,
PointerType,
} from 'shared/ReactDOMTypes';
impo... |
client/components/leaderboard.js | chesterhow/leaderboard | import React, { Component } from 'react';
import { createContainer } from 'meteor/react-meteor-data';
import { Listings } from '../../imports/collections/listings';
import Listing from './listing';
class Leaderboard extends Component {
constructor(props) {
super(props);
this.state = {
page: 1,
... |
packages/react-scripts/fixtures/kitchensink/src/features/syntax/ObjectSpread.js | christiantinauer/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: '... |
src/app/index.js | skratchdot/js-playground | import React from 'react';
import { render } from 'react-dom';
import { Router } from 'react-router';
import { Provider } from 'react-redux';
import createBrowserHistory from 'history/lib/createBrowserHistory';
import configureStore from './store/configureStore';
import routes from './routes';
const store = configureSt... |
src/svg-icons/action/fingerprint.js | hwo411/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionFingerprint = (props) => (
<SvgIcon {...props}>
<path d="M17.81 4.47c-.08 0-.16-.02-.23-.06C15.66 3.42 14 3 12.01 3c-1.98 0-3.86.47-5.57 1.41-.24.13-.54.04-.68-.2-.13-.24-.04-.55.2-.68C7.82 2.52 9.86 2 12... |
examples/simple/components/App.js | idream3/react-custom-scrollbars | import React, { Component } from 'react';
import { Scrollbars } from 'react-custom-scrollbars';
export default class App extends Component {
render() {
return (
<div>
<Scrollbars style={{ height: 300, marginBottom: 50}}>
<p>Lorem ipsum dolor sit amet, consete... |
newclient/scripts/components/config/editable-item/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... |
client/src/react/all.react.js | sggdv/vegan | import React from 'react';
import ReactDOM from 'react-dom';
import VerifyBox from './verify.react';
ReactDOM.render(
<VerifyBox />,
document.getElementById('content')
);
|
src/components/pages/ocr/index.js | modern-translator/client | /* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
/* global document */
import React from 'react';
import PropTypes from 'prop-types';
import Fab from '@material-u... |
src/svg-icons/content/filter-list.js | hai-cea/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ContentFilterList = (props) => (
<SvgIcon {...props}>
<path d="M10 18h4v-2h-4v2zM3 6v2h18V6H3zm3 7h12v-2H6v2z"/>
</SvgIcon>
);
ContentFilterList = pure(ContentFilterList);
ContentFilterList.displayName = 'Con... |
Libraries/Touchable/TouchableHighlight.web.js | sprightco/react-web | /**
* Copyright (c) 2015-present, Alibaba Group Holding Limited.
* All rights reserved.
*
* Copyright (c) 2015, Facebook, Inc. All rights reserved.
*
* @providesModule ReactTouchableHighlight
*/
'use strict';
import React from 'react';
import View from 'ReactView';
import TimerMixin from 'react-timer-mixin';
i... |
src/components/notifications/Notification.js | metasfresh/metasfresh-webui-frontend | import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { connect } from 'react-redux';
import classnames from 'classnames';
import { deleteNotification } from '../../actions/AppActions';
class Notification extends Component {
constructor(props) {
super(props);
this.state = {
... |
client/fragments/quizzes/main.js | yeoh-joer/synapse | /**
* External dependencies
*/
import React from 'react'
import { connect } from 'react-redux'
/**
* Internal dependencies
*/
import './style.scss'
import Collection from './collection'
import { fetchQuizzes } from 'client/state/quizzes/actions'
class Quizzes extends React.Component {
componentDidMount() {
co... |
lib/components/message-input.js | StephanieEA/shoot-the-breeze | import React from 'react';
export default class MessageInput extends React.Component {
render() {
return (
<div className='MessageInput'>
<input type='text'
onChange={e => this.props.handleChange(e)}/>
</div>
);
}
}
|
src/shared/utils/category-select.js | rvboris/financebutler | import React from 'react';
const indent = (node, rootLevel = false, spacer = ' ', rate = 3) => {
const repeatCount = node.getPath().length - (1 + Number(!rootLevel));
return `${repeatCount ? spacer.repeat(repeatCount * rate) : ''}${node.model.name}`;
};
export const optionRenderer = (rootLevel = false) => (o... |
docs/app.js | amazeui/amazeui-react | import React from 'react';
import ReactDOM from 'react-dom';
import {
Router,
Route,
IndexRoute,
hashHistory,
browserHistory,
} from 'react-router';
import {
useBasename,
} from 'history';
const history = useBasename(() => browserHistory)({basename: `/react`});
// style
import './docs.less';
// img
impor... |
src/components/app.js | lcpunch/react-blog | import React, { Component } from 'react';
export default class App extends Component {
render() {
return (
<div>
{this.props.children}
</div>
);
}
}
|
components/page.js | sullenor/react-server-rendering | import React from 'react';
export default ({ children, title }) => {
return (
<html>
<head>
<title>{ title }</title>
<meta charSet='utf-8'/>
</head>
<body>
{ children }
</body>
</html>
);
};
|
src/svg-icons/action/settings-applications.js | mtsandeep/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionSettingsApplications = (props) => (
<SvgIcon {...props}>
<path d="M12 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm7-7H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.11 0 2-.9 2-2V5c0-1.1-.89-2-2-2zm-1.75 9c... |
src/ProgressBar.js | martonbognar/bali-react | import React, { Component } from 'react';
import './ProgressBar.css'
class ProgressBar extends Component {
render() {
return (
<div>
<div id='progress-bar'>
<img alt='Progress bar' src={process.env.PUBLIC_URL + '/img/progress.png'} />
</div>
</div>
);
}
}
export defau... |
src/svg-icons/action/alarm.js | ngbrown/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionAlarm = (props) => (
<SvgIcon {...props}>
<path d="M22 5.72l-4.6-3.86-1.29 1.53 4.6 3.86L22 5.72zM7.88 3.39L6.6 1.86 2 5.71l1.29 1.53 4.59-3.85zM12.5 8H11v6l4.75 2.85.75-1.23-4-2.37V8zM12 4c-4.97 0-9 4.03... |
react-tutorial/src/index.js | cherise-bryan/21daysofREACT | import React from 'react';
import ReactDOM from 'react-dom'; // these need to be here or npm start will fail
import './index.css'; // brings in css styles
// WHERE I STOPPED: https://facebook.github.io/react/tutorial/tutorial.html#wrapping-up
// TODO: https://facebook.github.io/react/blog/2014/01/02/react-chrome-devel... |
front/src/index.js | dherault/Aquest | import './index.css';
import 'flexpad/dist/flexpad.min.css';
import React from 'react';
import ReactDOM from 'react-dom';
import { BrowserRouter as Router, Route, Switch } from 'react-router-dom';
import Landing from './scenes/Landing';
import Login from './scenes/Login';
import VocationsMap from './scenes/VocationsMa... |
fields/components/columns/IdColumn.js | cermati/keystone | import React from 'react';
import ItemsTableCell from '../../components/ItemsTableCell';
import ItemsTableValue from '../../components/ItemsTableValue';
var IdColumn = React.createClass({
displayName: 'IdColumn',
propTypes: {
col: React.PropTypes.object,
data: React.PropTypes.object,
list: React.PropTypes.obje... |
server/sonar-web/src/main/js/components/shared/issues-link.js | vamsirajendra/sonarqube | import React from 'react';
import { getComponentIssuesUrl } from '../../helpers/urls';
export const IssuesLink = React.createClass({
render() {
let url = getComponentIssuesUrl(this.props.component, this.props.params);
return <a className={this.props.className} href={url}>{this.props.children}</a>;
}
});
|
src/index.js | TimothyBom/react-redux-instagram | import React from 'react'
import { render } from 'react-dom'
import { Provider } from 'react-redux'
import { createStore, applyMiddleware, compose } from 'redux'
import thunk from 'redux-thunk'
import jwt from 'jsonwebtoken'
import reducer from './reducers'
import { setAuthorization } from './utils/setAuthorization'
im... |
src/Containers/FAQ/FAQ.js | rahulp959/airstats.web | import React from 'react'
import './FAQ.scss'
class FAQ extends React.Component {
render () {
return (
<div className='faq'>
<h2>FAQ</h2>
<h4>1. Why can I not find my flight on AirStats?</h4>
<p>AirStats has a specific set of requirements to keep flights logged. These include, but a... |
src/icons/SocialAndroidOutline.js | fbfeix/react-icons | import React from 'react';
import IconBase from './../components/IconBase/IconBase';
export default class SocialAndroidOutline extends React.Component {
render() {
if(this.props.bare) {
return <g>
<g>
<g>
<path d="M352,208v60.5V357h-22.5H313v15.5V424c0,4.4-3,7.9-7.3,8l0,0l-0.1,0c-0.1,0-0.2,0-0.3,0c-1.6,0-3.1-0... |
src/components/children/WordBox.js | rxtATX/Lyrical | import React from 'react';
import WordBlank from './WordBlank'
const WordBox = (props) => {
const eachWord = props.songLyrics.map((word, index) => {
if (props.guessWord.indexOf(word) === -1 && props.isGameOver === false) {
return <WordBlank key={index} word={word} correct={false} />
} e... |
client/src/pages/Recipe/index.js | alexandernanberg/luncha | import React from 'react'
import { observer, inject } from 'mobx-react'
import Hero from '../../components/common/Hero'
import Section from '../../components/common/Section'
import PageNotFound from '../PageNotFound'
import Info from './Info'
import Text from '../../components/common/Text'
@inject('recipeStore')
@obse... |
src/Parser/Priest/Discipline/Modules/Spells/TouchOfTheGrave.js | enragednuke/WoWAnalyzer | import React from 'react';
import SPELLS from 'common/SPELLS';
import SpellIcon from 'common/SpellIcon';
import StatisticBox, { STATISTIC_ORDER } from 'Main/StatisticBox';
import { formatPercentage, formatNumber } from 'common/format';
import Combatants from 'Parser/Core/Modules/Combatants';
import Analyzer from 'P... |
app/components/Home.js | MyPrivateLibrary/MyPrivateLibrary | import React from 'react';
class Home extends React.Component {
render() {
return (
<div className='l-container'>
<h1>MyPrivateLibrary</h1>
</div>
);
}
}
export default Home;
|
test/test-utils.js | aperezdc/matrix-react-sdk | "use strict";
import sinon from 'sinon';
import Promise from 'bluebird';
import React from 'react';
import PropTypes from 'prop-types';
import peg from '../src/MatrixClientPeg';
import dis from '../src/dispatcher';
import jssdk from 'matrix-js-sdk';
const MatrixEvent = jssdk.MatrixEvent;
/**
* Perform common actions... |
internals/templates/containers/HomePage/index.js | Frai/Events | /*
* HomePage
*
* This is the first thing users see of our App, at the '/' 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 necessity for you then you can refactor it and remove
* the l... |
src/index.js | joellanciaux/Griddle | import { createStore, combineReducers, bindActionCreators, applyMiddleware } from 'redux';
import Immutable from 'immutable';
import { createProvider } from 'react-redux';
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import _ from 'lodash';
import * as dataReducers from './reducers/dat... |
client/components/codeArea.js | richard-chen-1985/hosts-manager | import React, { Component } from 'react';
import CodeMirror from 'codemirror';
import 'codemirror/mode/ttcn-cfg/ttcn-cfg';
class CodeArea extends Component {
constructor(props) {
super(props);
this.state = {
initialValue: props.value,
};
}
render() {
const { className } = this.props;
re... |
app/javascript/mastodon/features/compose/components/text_icon_button.js | mstdn-jp/mastodon | import React from 'react';
import PropTypes from 'prop-types';
export default class TextIconButton extends React.PureComponent {
static propTypes = {
label: PropTypes.string.isRequired,
title: PropTypes.string,
active: PropTypes.bool,
onClick: PropTypes.func.isRequired,
ariaControls: PropTypes.s... |
src/components/LoadingPage.js | ztplz/CNode-react-native | /**
* React Native App
* https://github.com/ztplz/CNode-react-native
* email: mysticzt@gmail.com
*/
import React from 'react';
import {
View,
Text,
ActivityIndicator,
StyleSheet,
} from 'react-native';
import {
NIGHT_BACKGROUND_COLOR,
NIGHT_LOADINGPAGE_TEXT
} from '../constants/themecolor';
const Load... |
src/components/views/MainView.js | ello/webapp | import React from 'react'
import PropTypes from 'prop-types'
import classNames from 'classnames'
export const MainView = ({ children, className }) =>
(<main className={classNames(className, 'MainView')} role="main">
{children}
</main>)
MainView.propTypes = {
children: PropTypes.node.isRequired,
className:... |
newclient/scripts/components/user/entities/entity-form/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... |
OleksiiOnSoftware.Apps.Blog/client/components/Post/index.js | boades/PpmSystem | /* @flow */
// Framework
import React from 'react'
// Custom UI
import {
LongPost,
LeftNavigation,
TopBar
} from 'components'
// Semantic UI
import {
Grid,
Segment,
Item,
Icon,
Sidebar,
Menu,
Breadcrumb
} from 'semantic-ui-react'
// Types
import type { Tag, Category, Post as PostType, Link } fro... |
client/components/RawText.js | VoiSmart/Rocket.Chat | import React from 'react';
const RawText = ({ children }) => <span dangerouslySetInnerHTML={{ __html: children }} />;
export default RawText;
|
src/Notification.js | mukuljainx/react-videoplayer | import React from 'react';
import Proptypes from 'prop-types';
const Notification = ({values, className}) => {
const getNotificationText = () => {
return values.map((value, i) => {
return (<p key={i}> {value} </p>);
});
};
const notificationText = getNotificationText();
return (
<div classNa... |
src/container/Footer/footer.js | randomlysa/react-weather | import React, { Component } from 'react';
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';
import { deleteForecast } from '../Cities/actions-forecast';
import { deleteCity } from '../Cities/actions-weather';
import Modal from 'react-modal';
import MaterialIcon from 'material-icons-reac... |
react/redux/client/src/components/dashboard/messaging/conversation-list.js | sabertazimi/st-proj | import React, { Component } from 'react';
import cookie from 'react-cookie';
const moment = require('moment');
import ConversationItem from './conversation-item';
class ConversationList extends Component {
constructor(props) {
super(props);
this.userCookie = cookie.load('user');
}
render(... |
packages/ringcentral-widgets-docs/src/app/pages/Components/Environment/Demo.js | ringcentral/ringcentral-js-widget | import React from 'react';
// eslint-disable-next-line
import Environment from 'ringcentral-widgets/components/Environment';
const props = {};
props.server = 'test string';
props.recordingHost = 'test string';
props.enabled = false;
props.onSetData = () => null;
props.defaultHidden = false;
/**
* A example of `Envir... |
src/decorators/withViewport.js | clickbuster/smite-calculator | /*! React Starter Kit | MIT License | http://www.reactstarterkit.com/ */
import React, { Component } from 'react'; // eslint-disable-line no-unused-vars
import EventEmitter from 'eventemitter3';
import { canUseDOM } from 'fbjs/lib/ExecutionEnvironment';
let EE;
let viewport = {width: 1366, height: 768}; // Default si... |
source/FileUploadInput.js | halt-hammerzeit/react-responsive-ui | import React from 'react'
import PropTypes from 'prop-types'
import classNames from 'classnames'
export default class FileUploadInput extends React.Component {
static propTypes = {
onChange: PropTypes.func.isRequired,
multiple: PropTypes.bool,
// Indicates that the input is invalid.
error: PropTypes.oneOfType... |
exercises/02-components/index.js | samarpanda/react-intro | import React from 'react'
import { render } from 'react-dom'
const styles = {}
styles.tab = {
display: 'inline-block',
padding: 10,
margin: 10,
borderBottom: '4px solid',
borderBottomColor: '#ccc',
cursor: 'pointer'
}
styles.activeTab = {
...styles.tab,
borderBottomColor: '#000'
}
styles.panel = {
... |
src/views/agenda/Edit.js | airloy/objective | /**
* Created by Layman(http://github.com/anysome) on 16/3/1.
*/
import React from 'react';
import {StyleSheet, ScrollView, View, Text, TouchableOpacity, LayoutAnimation} from 'react-native';
import moment from 'moment';
import Button from 'react-native-button';
import {analytics, styles, colors, airloy, api, L, toas... |
src/routes.js | lucasmonteiro001/react-redux-posts-crud | /**
* Created by lucas on 3/2/17.
*/
import React from 'react';
import {Route, IndexRoute} from 'react-router';
import App from './components/app';
import PostsIndex from './components/posts_index';
import PostsNew from './components/posts_new';
import PostsShow from './components/posts_show';
export default (
<... |
openex-front/src/components/ColorPickerField.js | Luatix/OpenEx | import React from 'react';
import { Field } from 'react-final-form';
import MuiTextField from '@mui/material/TextField';
import { SketchPicker } from 'react-color';
import IconButton from '@mui/material/IconButton';
import Popover from '@mui/material/Popover';
import InputAdornment from '@mui/material/InputAdornment';
... |
frontend/src/Components/Form/SelectInput.js | Radarr/Radarr | import classNames from 'classnames';
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import styles from './SelectInput.css';
class SelectInput extends Component {
//
// Listeners
onChange = (event) => {
this.props.onChange({
name: this.props.name,
value: event.targ... |
projeto/fatec/src/OiMundo.js | frbaroni/curso_react | import React, { Component } from 'react';
class OiMundo extends Component {
static defaultProps = {
nomeee: 'FATEC'
}
render() {
return (
<p>{this.props.nomeee}</p>
);
}
}
export default OiMundo;
|
src/icons/WarningIcon.js | kiloe/ui | import React from 'react';
import Icon from '../Icon';
export default class WarningIcon extends Icon {
getSVG(){return <svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" viewBox="0 0 48 48"><path d="M2 42h44L24 4 2 42zm24-6h-4v-4h4v4zm0-8h-4v-8h4v8z"/></svg>;}
}; |
src/hoc/requireAuthentication.js | AndreyWeber/fes-react-course-marksboard | import React from 'react';
import { connect } from 'react-redux';
import { replace } from 'react-router-redux';
import PropTypes from 'prop-types';
import { isLoggedIn } from '../selectors/login';
import { getPathname, getQuery } from '../selectors/routing';
import NotAuthorized from '../components/NotAuthorized.jsx'... |
src/svg-icons/content/clear.js | hwo411/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ContentClear = (props) => (
<SvgIcon {...props}>
<path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"/>
</SvgIcon>
);
ContentClear = pure(ContentClea... |
examples/MediaBox.js | 15lyfromsaturn/react-materialize | import React from 'react';
import MediaBox from '../src/MediaBox';
export default
<MediaBox src="assets/sample-1.jpg" caption="A demo media box1" width="650"/>;
|
src/svg-icons/image/navigate-next.js | barakmitz/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageNavigateNext = (props) => (
<SvgIcon {...props}>
<path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"/>
</SvgIcon>
);
ImageNavigateNext = pure(ImageNavigateNext);
ImageNavigateNext.displayName = 'Ima... |
js/BaseComponents/DialogueHeader.js | telldus/telldus-live-mobile-v3 | /**
* Copyright 2016-present Telldus Technologies AB.
*
* This file is part of the Telldus Live! app.
*
* Telldus Live! app is free : you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
*... |
console/src/app/taskrecords/taskrecord_detail.js | alfredking12/hp-scheduler | import React from 'react';
import BaseComponent from '../libs/BaseComponent';
import TaskDetail from '../tasks/task_detail';
export default class TaskRecordDetail extends TaskDetail.View {
constructor(props, context) {
super(props, context);
Object.assign(this.state, {
nameEditable: fa... |
src/svg-icons/editor/border-left.js | spiermar/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let EditorBorderLeft = (props) => (
<SvgIcon {...props}>
<path d="M11 21h2v-2h-2v2zm0-4h2v-2h-2v2zm0-12h2V3h-2v2zm0 4h2V7h-2v2zm0 4h2v-2h-2v2zm-4 8h2v-2H7v2zM7 5h2V3H7v2zm0 8h2v-2H7v2zm-4 8h2V3H3v18zM19 9h2V7h-2v2z... |
imports/ui/components/NestedCategoriesWidget/NestedCategories.js | muhammadsasmito/meteor-solr | /* eslint-disable react/prefer-es6-class */
import React from 'react';
import classNames from 'classnames';
const NestedCategories = React.createClass({
propTypes: {
categories: React.PropTypes.object.isRequired,
onCategorySelect: React.PropTypes.func.isRequired,
selectedCategoryPath: React.PropTypes.st... |
packages/mineral-ui-icons/src/IconPermScanWifi.js | mineral-ui/mineral-ui | /* @flow */
import React from 'react';
import Icon from 'mineral-ui/Icon';
import type { IconProps } from 'mineral-ui/Icon/types';
/* eslint-disable prettier/prettier */
export default function IconPermScanWifi(props: IconProps) {
const iconProps = {
rtl: false,
...props
};
return (
<Icon {...iconP... |
src/components/FAQ/Question/Question-story.js | Tarabyte/foodlr-web | import React from 'react'
import { storiesOf } from '@kadira/storybook'
import Question from './Question'
const question = {
id: '54dbb245f08e85d01b3ef0ec',
question: 'Как отбираются рецепты?',
answer: `<p>Каждый рецепт проходит 10 стадий отбора и проверки...</p>
<ul>
<li>Lorem ipsum dolor sit amet, ex pop... |
spec/javascripts/jsx/external_apps/components/ConfigurationFormLti2Spec.js | djbender/canvas-lms | /*
* Copyright (C) 2014 - present Instructure, Inc.
*
* This file is part of Canvas.
*
* Canvas is free software: you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License as published by the Free
* Software Foundation, version 3 of the License.
*
* Canvas is distribut... |
blueocean-material-icons/src/js/components/svg-icons/hardware/keyboard-arrow-up.js | kzantow/blueocean-plugin | import React from 'react';
import SvgIcon from '../../SvgIcon';
const HardwareKeyboardArrowUp = (props) => (
<SvgIcon {...props}>
<path d="M7.41 15.41L12 10.83l4.59 4.58L18 14l-6-6-6 6z"/>
</SvgIcon>
);
HardwareKeyboardArrowUp.displayName = 'HardwareKeyboardArrowUp';
HardwareKeyboardArrowUp.muiName = 'SvgIcon'... |
app/javascript/mastodon/features/favourites/index.js | increments/mastodon | import React from 'react';
import { connect } from 'react-redux';
import PropTypes from 'prop-types';
import ImmutablePropTypes from 'react-immutable-proptypes';
import LoadingIndicator from '../../components/loading_indicator';
import { fetchFavourites } from '../../actions/interactions';
import { ScrollContainer } fr... |
app/templates/src/App/Core/Routes.js | luisrudge/generator-simple-react-browserify | import React from 'react';
import Router from 'react-router';
var {DefaultRoute, Route} = Router;
import Layout from './Layout';
import Home from '../Views/Home';
import Dashboard from '../Views/Dashboard';
var routes = (
<Route name="app" path="/" handler={Layout}>
<Route name="dashboard" handler={Dashboard}/>... |
src/clincoded/static/components/image.js | ClinGen/clincoded | 'use strict';
import React from 'react';
import createReactClass from 'create-react-class';
import url from 'url';
import { content_views, bindEvent, unbindEvent } from './globals';
// Fixed-position lightbox background and image
var Lightbox = module.exports.Lightbox = createReactClass({
getInitialState: functio... |
src/index.js | serban-petrescu/serban-petrescu.github.io | import React from 'react';
import ReactDOM from 'react-dom';
import mixpanel from 'mixpanel-browser';
import './index.scss';
import App from './App';
mixpanel.init('c4cc21bf5d9a0b60ab5fa4dcef19e808', {
api_host: "https://api-eu.mixpanel.com",
disable_persistence: true
});
mixpanel.track('Visit');
ReactDOM.... |
src/svg-icons/image/filter-9-plus.js | ngbrown/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageFilter9Plus = (props) => (
<SvgIcon {...props}>
<path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm11 7V8c0-1.11-.9-2-2-2h-1c-1.1 0-2 .89-2 2v1c0 1.11.9 2 2 2h1v1H9v2h3c1.1 0 2-.89 2-2zm-3-3V8h1v1h-1zm10-8H7c-1.1... |
src/views/LeadCard.js | cernanb/personal-chef-react-app | import React from 'react';
import styled from 'styled-components';
import { Link } from 'react-router-dom';
import PropTypes from 'prop-types';
import numeral from 'numeral';
const StyledLead = styled.div`
width: 31%;
text-align: center;
padding: 20px;
border: 1px solid black;
border-radius: 5px;
margin: 1... |
src/Demo/index.js | Aprillion/data_viewer | import React from 'react'
import './index.css'
import DataViewer from '../DataViewer'
import data from './data-1.json'
import {standardize, deleteOnServer} from './data-1.config'
const Demo = () => (
<div className="Demo">
<header className="Demo-header">DataViewer demo</header>
<DataViewer {...{data, standa... |
src/templates/post-template.js | apalhu/website | // @flow strict
import React from 'react';
import { graphql } from 'gatsby';
import Layout from '../components/Layout';
import Post from '../components/Post';
import { useSiteMetadata } from '../hooks';
import type { MarkdownRemark } from '../types';
type Props = {
data: {
markdownRemark: MarkdownRemark
}
};
... |
docs/app/Examples/elements/List/Types/ListExampleLink.js | ben174/Semantic-UI-React | import React from 'react'
import { List } from 'semantic-ui-react'
const ListExampleLink = () => (
<List link>
<List.Item active>Home</List.Item>
<List.Item as='a'>About</List.Item>
<List.Item as='a'>Jobs</List.Item>
<List.Item as='a'>Team</List.Item>
</List>
)
export default ListExampleLink
|
docs/app/Examples/elements/Image/States/ImageExampleHidden.js | clemensw/stardust | import React from 'react'
import { Image } from 'semantic-ui-react'
const ImageExampleHidden = () => (
<Image src='/assets/images/wireframe/image.png' size='small' hidden />
)
export default ImageExampleHidden
|
docs/app/Examples/elements/Segment/Variations/index.js | vageeshb/Semantic-UI-React | import React from 'react'
import ComponentExample from 'docs/app/Components/ComponentDoc/ComponentExample'
import ExampleSection from 'docs/app/Components/ComponentDoc/ExampleSection'
import { Message } from 'semantic-ui-react'
const SegmentVariationsExamples = () => (
<ExampleSection title='Variations'>
<Compon... |
03-testing-stateless-components/src/User.js | dtanzer/react-basic-examples | import React from 'react';
class User extends React.PureComponent {
render() {
const email = this.props.email ? <span className="email"> {this.props.email}</span> : null;
const active = this.props.active || false;
const activeInfo = <span class="active"> active: {active.toString()}</span>;
return (
... |
src/svg-icons/image/loupe.js | pomerantsev/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageLoupe = (props) => (
<SvgIcon {...props}>
<path d="M13 7h-2v4H7v2h4v4h2v-4h4v-2h-4V7zm-1-5C6.49 2 2 6.49 2 12s4.49 10 10 10h8c1.1 0 2-.9 2-2v-8c0-5.51-4.49-10-10-10zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.... |
src/components/GamesList/GamesList.js | lucaslencinas/react-node-template | import React from 'react';
import PropTypes from 'prop-types';
import Game from './Game';
import CreateGame from './CreateGame';
import styles from './GamesList.css';
const GamesList = ({
games,
selectedGame,
onSelectGame,
onDeleteGame,
onOpenCreateGameForm,
isFormOpen
}) => (
<div className={styles.game... |
src/Components/MeasurementsProvider.js | vpodolyan/measurements | import React from 'react';
import PropTypes from 'prop-types';
export default class MeasurementsProvider extends React.Component {
static childContextTypes = {
data: PropTypes.object
}
state = {
data: {}
}
eventSource = null;
constructor(props) {
super(props);
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.