path stringlengths 5 195 | repo_name stringlengths 5 79 | content stringlengths 25 1.01M |
|---|---|---|
src/scripts/page/todolist/redux/devTools.js | sdwangbaotong/react-study | import React from 'react';
import { createDevTools } from 'redux-devtools';
import Inspector from 'redux-devtools-inspector';
export default createDevTools(
<Inspector />
); |
packages/react-scripts/fixtures/kitchensink/src/features/webpack/UnknownExtInclusion.js | RobzDoom/frame_trap | /**
* Copyright (c) 2015-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*/
import Rea... |
src/svg-icons/editor/insert-link.js | mit-cml/iot-website-source | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let EditorInsertLink = (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... |
src/svg-icons/hardware/smartphone.js | mtsandeep/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let HardwareSmartphone = (props) => (
<SvgIcon {...props}>
<path d="M17 1.01L7 1c-1.1 0-2 .9-2 2v18c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V3c0-1.1-.9-1.99-2-1.99zM17 19H7V5h10v14z"/>
</SvgIcon>
);
HardwareSmartphone = p... |
app/javascript/mastodon/features/notifications/index.js | 3846masa/mastodon | import React from 'react';
import { connect } from 'react-redux';
import PropTypes from 'prop-types';
import ImmutablePropTypes from 'react-immutable-proptypes';
import Column from '../ui/components/column';
import { expandNotifications, clearNotifications, scrollTopNotifications } from '../../actions/notifications';
i... |
imports/ui/components/ClassroomList.js | hanstest/hxgny | import React from 'react'
import DataList from '../components/DataList'
import { insertClassroom, updateClassroom, removeClassroom } from '../../api/data/methods'
class ClassroomList extends React.Component {
state = {
key: (new Date()).getTime(),
}
refresh = () => {
this.setState({ key: (new Date()).... |
webpack/JobWizard/steps/Schedule/StartEndDates.js | adamruzicka/foreman_remote_execution | import React from 'react';
import PropTypes from 'prop-types';
import { FormGroup, Checkbox } from '@patternfly/react-core';
import { translate as __ } from 'foremanReact/common/I18n';
import { DateTimePicker } from '../form/DateTimePicker';
export const StartEndDates = ({
starts,
setStarts,
ends,
setEnds,
i... |
example/src/screens/types/ListScreen.js | junedomingo/react-native-navigation | import _ from 'lodash';
import React, { Component } from 'react';
import {
View,
ScrollView,
Dimensions,
Text,
StyleSheet,
Button
} from 'react-native';
const Colors = [
"#1abc9c",
"#2ecc71",
"#3498db",
"#9b59b6",
"#34495e",
"#16a085",
"#27ae60",
"#2980b9",
"#8e44ad",
"#2c3e50",
"#f1c... |
components/Navigation/Navigation.js | keithk/cfa-dance | /**
* React Static Boilerplate
* https://github.com/koistya/react-static-boilerplate
* Copyright (c) Konstantin Tarkus (@koistya) | MIT license
*/
import React from 'react';
import './Navigation.scss';
import Link from '../Link';
function Navigation() {
// <ul className="Navigation" role="menu">
// <li clas... |
templates/rubix/relay/relay-seed/src/common/header.js | jeffthemaximum/jeffline | import React from 'react';
import ReactDOM from 'react-dom';
import classNames from 'classnames';
import { Link, withRouter } from 'react-router';
import l20n, { Entity } from '@sketchpixy/rubix/lib/L20n';
import {
Label,
SidebarBtn,
Dispatcher,
NavDropdown,
NavDropdownHover,
Navbar,
Nav,
NavItem,
... |
docs/src/app/components/pages/components/List/ExampleChat.js | spiermar/material-ui | import React from 'react';
import MobileTearSheet from '../../../MobileTearSheet';
import Avatar from 'material-ui/Avatar';
import {List, ListItem} from 'material-ui/List';
import Subheader from 'material-ui/Subheader';
import Divider from 'material-ui/Divider';
import CommunicationChatBubble from 'material-ui/svg-icon... |
web/src/Dashboard/Home/ProjectActivity/ProjectActivity.js | wasong/cmpt433 | import React from 'react'
import PropTypes from 'prop-types'
import Radium from 'radium'
import FlatCard from 'components/FlatCard'
import Divider from 'material-ui/Divider'
import List from './List'
const styles = {
title: {
fontSize: 18,
margin: '0 0 5px',
color: '#b1b1b1',
},
projectCard: {
... |
lib-es/elements/subtitle.js | bokuweb/re-bulma | var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
import React, { Component } from 'react';
import PropTypes fr... |
client/src/javascript/components/torrent-list/Torrent.js | jfurrow/flood | import React from 'react';
import CalendarIcon from '../icons/CalendarIcon';
import ClockIcon from '../icons/ClockIcon';
import DiskIcon from '../icons/DiskIcon';
import DownloadThickIcon from '../icons/DownloadThickIcon';
import InformationIcon from '../icons/InformationIcon';
import PeersIcon from '../icons/PeersIco... |
shared/container/DevTools/DevTools.js | ITJacob/glory | import React from 'react';
import { createDevTools } from 'redux-devtools';
import LogMonitor from 'redux-devtools-log-monitor';
import DockMonitor from 'redux-devtools-dock-monitor';
export default createDevTools(
<DockMonitor
toggleVisibilityKey="ctrl-h"
changePositionKey="ctrl-w"
>
<LogMonitor />
... |
src/parser/warlock/affliction/modules/features/DotUptimes/index.js | sMteX/WoWAnalyzer | import React from 'react';
import Analyzer from 'parser/core/Analyzer';
import { STATISTIC_ORDER } from 'interface/others/StatisticsListBox';
import StatisticBar from 'interface/statistics/StatisticBar';
import AgonyUptime from './AgonyUptime';
import CorruptionUptime from './CorruptionUptime';
import UnstableAfflic... |
packages/react-scripts/fixtures/kitchensink/template/src/features/webpack/SvgInclusion.js | jdcrensh/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 from 'react';
import logo from './assets/logo.svg';
const SvgInclusion = () => (
<img id="feature-svg-inclusion" src={lo... |
src/svg-icons/device/widgets.js | mit-cml/iot-website-source | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let DeviceWidgets = (props) => (
<SvgIcon {...props}>
<path d="M13 13v8h8v-8h-8zM3 21h8v-8H3v8zM3 3v8h8V3H3zm13.66-1.31L11 7.34 16.66 13l5.66-5.66-5.66-5.65z"/>
</SvgIcon>
);
DeviceWidgets = pure(DeviceWidgets);
... |
salesledger-frontend/src/index.js | zooyalove/salesledger | import React from 'react';
import ReactDOM from 'react-dom';
import './index.css';
import App from './App';
import registerServiceWorker from './registerServiceWorker';
ReactDOM.render(<App />, document.getElementById('root'));
registerServiceWorker();
|
src/withStyles.js | garposmack/react-decorators | /**
* React Decorators
* Copyright (c) Konstantin Tarkus | MIT License
*/
import React, { Component } from 'react'; // eslint-disable-line no-unused-vars
import { canUseDOM } from 'react/lib/ExecutionEnvironment';
import EventEmitter from 'eventemitter3';
let EE;
let viewport = {width: 1366, height: 768}; // Defau... |
src/main/resources/ui/components/Footer.js | lionelnicolas/chronos | import React from 'react'
const Footer = () => (
<footer>
<p className="text-center">© 2016 <a href="https://mesosphere.com/" target="_blank">Mesosphere, Inc.</a></p>
</footer>
)
export default Footer
|
webapp/components/widgets/GridWidget.js | marinvvasilev/homeinfotainment | /* eslint-disable import/default */
import React from 'react';
import { render } from 'react-dom';
export default class GridWidget extends React.Component {
constructor(props) {
super(props);
}
componentWillMount() {
this.state = {
items: this.props.items || []
};
... |
src/svg-icons/maps/local-library.js | verdan/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let MapsLocalLibrary = (props) => (
<SvgIcon {...props}>
<path d="M12 11.55C9.64 9.35 6.48 8 3 8v11c3.48 0 6.64 1.35 9 3.55 2.36-2.19 5.52-3.55 9-3.55V8c-3.48 0-6.64 1.35-9 3.55zM12 8c1.66 0 3-1.34 3-3s-1.34-3-3-3-... |
demos/demo/src/index.js | bdjnk/cerebral | import React from 'react'
import {render} from 'react-dom'
import {Controller} from 'cerebral'
import {Container} from 'cerebral/react'
import FirebaseProvider from 'cerebral-provider-firebase'
import firebaseConfig from './firebaseConfig'
import * as visibility from './helpers/visibility'
// Modules
import Devtools f... |
node_modules/case-sensitive-paths-webpack-plugin/demo/src/AppRoot.component.js | millerman86/CouponProject | import React, { Component } from 'react';
export default class AppRoot extends Component {
// we can't use `connect` in this component, so must do naiively:
constructor(props) {
super(props);
this.state = {
};
}
render() {
return (
<div>
<h1>This is just an empty demo</h1>
... |
client/src/components/PatientDetailOverview.js | wilimitis/DoctorIQ | import React from 'react';
export default props => {
const patient = props.patient;
return (
patient ?
<div>
<h2>{patient.name}</h2>
<p>
Age: {patient.age}
</p>
<p>
Email: {patient.email}
</p>
<p>
Address: {patient.address}
</p>
<p>
... |
packages/react-interactions/events/src/dom/Hover.js | flarnie/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 {
ReactDOMResponderEvent,
ReactDOMResponderContext,
PointerType,
} from 'shared/ReactDOMTypes';
impo... |
step4-router/node_modules/react-router/es6/IndexLink.js | jintoppy/react-training | 'use strict';
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
import React from 'react';
import Link from '.... |
aaf-enrollment/src/components/enrollment/test-authenticator/method-tests/WebAuthenticationTest.js | MicroFocus/CX | import React from 'react';
import {clearStorageItem, loadStorageItem, saveStorageItem} from '../../../../utils/local-storage';
const LOGON_PROCESS_ID_KEY = 'LOGON_PROCESS_ID';
// Tests web authentication in two phases.
// The first redirects the user, the second sets the logon state and waits for the identity provide... |
src/esm/components/graphics/icons-next/speech-bubble-icon-next/index.js | KissKissBankBank/kitten | import _extends from "@babel/runtime/helpers/extends";
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/objectWithoutPropertiesLoose";
var _excluded = ["color", "title"];
import React from 'react';
import PropTypes from 'prop-types';
export var SpeechBubbleIconNext = function SpeechBubbleIconNext(_ref)... |
geonode/contrib/monitoring/frontend/src/components/cels/response-table/index.js | MapStory/geonode | import React from 'react';
import PropTypes from 'prop-types';
import HR from '../../atoms/hr';
import styles from './styles';
class ResponseTable extends React.Component {
static propTypes = {
average: PropTypes.number,
errorNumber: PropTypes.number,
max: PropTypes.number,
requests: PropTypes.numbe... |
src/svg-icons/notification/folder-special.js | nathanmarks/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let NotificationFolderSpecial = (props) => (
<SvgIcon {...props}>
<path d="M20 6h-8l-2-2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-2.06 11L15 15.28 12.06 17l.78-3.33-2.59-2.24 3.41-.29... |
src/containers/recipes/Browse/BrowseView.js | shojil/bifapp | /**
* Receipe Tabs Screen
* - Shows tabs, which contain receipe listings
*
* React Native Starter App
* https://github.com/mcnamee/react-native-starter-app
*/
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import {
View,
StyleSheet,
InteractionManager,
} from 'react-native';
... |
src/js/pages/Proposals/Project/AvailabilityPage.js | nekuno/client | import PropTypes from 'prop-types';
import React, { Component } from 'react';
import translate from '../../../i18n/Translate';
import TopNavBar from '../../../components/TopNavBar/TopNavBar.js';
import '../../../../scss/pages/proposals/project/availability.scss';
import StepsBar from "../../../components/ui/StepsBar/St... |
judge/client/src/Components/Problem.js | istamenov/NodeJS_Judge | import React, { Component } from 'react';
import UserSolution from './UserSolution';
class Problem extends Component {
render() {
console.log(this.props.problem.author);
return (
<div className="Problem">
<h1>{this.props.problem.title}</h1>
<h2>{this.props.problem.description}</h2>
... |
src/components/AddAppointment/components/AppointmentNotes/AppointmentNotes.js | TheModevShop/craft-app | import React from 'react';
import _ from 'lodash';
import './appointment-notes.less';
class AppointmentNotes extends React.Component {
constructor(...args) {
super(...args);
this.state = {};
}
render() {
return (
<div className="appointment-notes">
<div className="designed-form">
... |
node_modules/react-bootstrap/es/CarouselCaption.js | GregSantulli/react-drum-sequencer | import _extends from 'babel-runtime/helpers/extends';
import _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties';
import _classCallCheck from 'babel-runtime/helpers/classCallCheck';
import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';
import _inherits from ... |
src/components/GlobalNav/index.js | hasibsahibzada/quran.com-frontend | /* global window */
import React, { Component } from 'react';
import * as customPropTypes from 'customPropTypes';
import { connect } from 'react-redux';
import debug from 'helpers/debug';
import styled from 'styled-components';
import Link from 'react-router/lib/Link';
import LocaleSwitcher from 'components/LocaleSwitc... |
client/containers/messages.js | ckiss/vidi-dashboard | 'use strict'
import React from 'react'
import {connect} from 'react-redux'
import Panel from '../components/panel'
import LineChart from '../components/line-chart'
import Moment from 'moment'
export const Messages = React.createClass({
render () {
const {data} = this.props
return (
<div className="pa... |
client/src/components/Header.js | shamb0t/orbit | 'use strict';
import React from 'react';
import TransitionGroup from "react-addons-css-transition-group";
import AppStateStore from 'stores/AppStateStore';
import UIActions from "actions/UIActions";
import 'styles/Header.scss';
class Header extends React.Component {
constructor(props) {
super(props);
this.s... |
src/routes/home/ComponentsList/index.js | balmbees/overwatch | import React from 'react';
import moment from 'moment';
import withStyles from 'isomorphic-style-loader/lib/withStyles';
import s from './index.css';
import ComponentStatus from './ComponentStatus';
class ComponentsList extends React.Component {
constructor(props) {
super(props);
this.state = {
compon... |
node_modules/react-router/es6/withRouter.js | signalcat/UIportfolio | var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
import invariant from 'invariant';
import React from 'react';... |
lib/components/ChromeNotice.js | codebhendi/filepizza | import React from 'react'
import DownloadStore from '../stores/DownloadStore'
import SupportStore from '../stores/SupportStore'
function getState() {
return {
active: SupportStore.getState().isChrome && DownloadStore.getState().fileSize >= 500000000
}
}
export default class ChromeNotice extends React.Compone... |
TurnerStarterKit.Web/stories/Welcome.js | turner-industries/web-starter-kit | import React from 'react';
const styles = {
main: {
margin: 15,
maxWidth: 600,
lineHeight: 1.4,
fontFamily: '"Helvetica Neue", Helvetica, "Segoe UI", Arial, freesans, sans-serif',
},
logo: {
width: 200,
},
link: {
color: '#1474f3',
textDecoration: 'none',
borderBottom: '1px ... |
node_modules/react-router/es6/Lifecycle.js | victor335882/ReduxSimpleStarter-4 | import warning from './routerWarning';
import React from 'react';
import invariant from 'invariant';
var object = React.PropTypes.object;
/**
* 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 stan... |
src/components/shared/Title.js | chrisrzhou/interviews | import React from 'react';
import './Title.css';
const Title = ({value}) => (
<div className="Title">
{value}
</div>
);
export default Title;
|
client/src/core-components/form.js | opensupports/opensupports | import React from 'react';
import _ from 'lodash';
import classNames from 'classnames';
import {reactDFS, renderChildrenWithProps} from 'lib-core/react-dfs';
import ValidationFactory from 'lib-app/validations/validator-factory';
import FormField from 'core-components/form-field';
class Form extends React.Component {... |
browser/app/index.js | dutchcoders/minio | /*
* Minio Cloud Storage (C) 2016 Minio, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law... |
frontend/app/site/pages/Styles/Grid.js | briancappello/flask-react-spa | import React from 'react'
import { DocComponent } from 'components'
import './grid.scss'
export default class Grid extends React.Component {
render() {
return (
<div className="grid-docs">
<h2 id="grid">Grid</h2>
<DocComponent {...this.columns} />
<DocComponent {...this.fractions}... |
app/components/Nav.js | stratigos/stormsreach | import React from 'react';
import { NavLink } from 'react-router-dom';
/**
* Stateless Functional Component to display available navigation.
*/
const Nav = () => {
return (
<ul className='nav'>
<li>
<NavLink exact activeClassName='active' to='/'>
Home
</NavLink>
</li>
... |
docs/src/app/components/pages/components/Chip/Page.js | igorbt/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 chipReadmeText from './README';
import ChipExampleSimple from './ExampleS... |
pootle/static/js/auth/components/SocialVerification.js | Jobava/pootle | /*
* Copyright (C) Pootle contributors.
*
* This file is a part of the Pootle project. It is distributed under the GPL3
* or later license. See the LICENSE file for a copy of the license and the
* AUTHORS file for copyright and authorship information.
*/
'use strict';
import assign from 'object-assign';
import ... |
app/containers/LanguageProvider/index.js | ledminh/ledminh-home | /*
*
* LanguageProvider
*
* this component connects the redux state language locale to the
* IntlProvider component and i18n messages (loaded from `app/translations`)
*/
import React from 'react';
import { connect } from 'react-redux';
import { createSelector } from 'reselect';
import { IntlProvider } from 'reac... |
src/components/options/OptionsHeader.js | m0sk1t/react_email_editor | import React from 'react';
const OptionsHeader = ({ block, language, onPropChange }) => {
const aligns = {
"left": "0",
"right": "2",
"center": "1",
}
const initialAlign = aligns[block.options.elements[0].textAlign];
return (
<div>
<div>
<label>{language["Custom style"]}: <input type="checkbox" chec... |
docs/app/Examples/elements/Button/Content/index.js | ben174/Semantic-UI-React | import React from 'react'
import ComponentExample from 'docs/app/Components/ComponentDoc/ComponentExample'
import ExampleSection from 'docs/app/Components/ComponentDoc/ExampleSection'
const ButtonContentExamples = () => (
<ExampleSection title='Content'>
<ComponentExample
title='Conditionals'
descrip... |
src/svg-icons/image/movie-creation.js | frnk94/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageMovieCreation = (props) => (
<SvgIcon {...props}>
<path d="M18 4l2 4h-3l-2-4h-2l2 4h-3l-2-4H8l2 4H7L5 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4h-4z"/>
</SvgIcon>
);
ImageMovieCreati... |
app/containers/FeaturePage/index.js | c-dagostino/react-boilerplate-example | /*
* FeaturePage
*
* List all the features
*/
import React from 'react';
import Helmet from 'react-helmet';
import { FormattedMessage } from 'react-intl';
import H1 from 'components/H1';
import messages from './messages';
import List from './List';
import ListItem from './ListItem';
import ListItemTitle from './Li... |
client/src/routes.js | korczis/microcrawler-webapp | import React from 'react';
import {IndexRoute, Route} from 'react-router';
// import { isLoaded as isAuthLoaded, load as loadAuth } from 'redux/modules/auth';
import App from './containers/App';
import Clients from './containers/Clients';
import Crawlers from './containers/Crawlers';
import Intro from './containers/In... |
frontend/src/Artist/Details/ArtistAlternateTitles.js | lidarr/Lidarr | import PropTypes from 'prop-types';
import React from 'react';
import styles from './ArtistAlternateTitles.css';
function ArtistAlternateTitles({ alternateTitles }) {
return (
<ul>
{
alternateTitles.map((alternateTitle) => {
return (
<li
key={alternateTitle}
... |
app/src/pages/LoadingScreen.js | skunkmb/Ablo | import React, { Component } from 'react';
import { View, StyleSheet } from 'react-native';
import Logo from '../common/Logo.js';
import { darkTheme } from '../themes.js';
let styleOptions = darkTheme.options;
export default class LoadingScreen extends Component {
render() {
return (
<View style... |
app/javascript/mastodon/features/favourited_statuses/index.js | Toootim/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 { fetchFavouritedStatuses, expandFavouritedStatuses } from '../../actions/favourites... |
fields/types/geopoint/GeoPointColumn.js | Yaska/keystone | import React from 'react';
import ItemsTableCell from '../../components/ItemsTableCell';
import ItemsTableValue from '../../components/ItemsTableValue';
var GeoPointColumn = React.createClass({
displayName: 'GeoPointColumn',
propTypes: {
col: React.PropTypes.object,
data: React.PropTypes.object,
},
renderValue... |
src/app/tutorials/Tutorials.js | elgatoylacaja/Kandel | import React from 'react'
import { GenericHeader, MiniLogo } from '../shared'
const TutorialLink = ({label}) =>
<a
className='tutorial-link'
href='/tutorial'
>
<span className='tutorial-link-label'>
{label}
</span>
<i className='fa fa-chevron-right tutorial... |
web_frontend/react_tic-tac-toe/src/index.js | axnion/playground | import React from 'react';
import ReactDOM from 'react-dom';
import './index.css';
function Square(props) {
return (
<button className="square" onClick={props.onClick}>
{props.value}
</button>
)
}
class Board extends React.Component {
renderSquare(i) {
return (
<Squar... |
client/node_modules/react-router/es/Prompt.js | bourdakos1/Visual-Recognition-Tool | function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call &... |
front-end/containers/DevTools.js | lybo/dcms | import React from 'react';
// Exported from redux-devtools
import { createDevTools } from 'redux-devtools';
// Monitors are separate packages, and you can make a custom one
import LogMonitor from 'redux-devtools-log-monitor';
import DockMonitor from 'redux-devtools-dock-monitor';
// createDevTools takes a monitor an... |
src/notification-alert.js | knledg/react-blur-admin | import React from 'react';
export class NotificationAlert extends React.Component {
static propTypes = {
user: React.PropTypes.object,
subject: React.PropTypes.string,
createdAt: React.PropTypes.string,
onClick: React.PropTypes.func,
relativeTime: React.PropTypes.string,
timeStamp: React.Pro... |
node_modules/material-ui/src/hoc/selectable-enhance.js | Sporks/Doc-tor | import React from 'react';
import getMuiTheme from '../styles/getMuiTheme';
import StylePropable from '../mixins/style-propable';
import ColorManipulator from '../utils/color-manipulator';
export const SelectableContainerEnhance = (Component) => {
const composed = React.createClass({
displayName: `Selectable${C... |
src/index.js | akoskaaa/typ-fastr | import React from 'react';
import ReactDOM from 'react-dom';
import { App } from './components/App.jsx';
import { createStore } from 'redux';
import { typFastrApp } from './reducers';
import { connect, Provider } from 'react-redux';
let store = createStore(typFastrApp);
ReactDOM.render(
<Provider store={store}>
... |
admin/client/App/components/Footer/index.js | dvdcastro/keystone | /**
* The global Footer, displays a link to the website and the current Keystone
* version in use
*/
import React from 'react';
import { Container } from 'elemental';
var Footer = React.createClass({
displayName: 'Footer',
propTypes: {
appversion: React.PropTypes.string,
backUrl: React.PropTypes.string,
br... |
src/components/video_list_item.js | Bentopi/React_Youtube_UI | import React from 'react';
const VideoListItem = ({video, onVideoSelect}) => {
const imageUrl = video.snippet.thumbnails.default.url
return (
<li onClick={() => onVideoSelect(video)} className="list-group-item">
<div className="video-list media">
<div className="media-left">
<img classN... |
docs/src/app/components/pages/components/List/ExampleNested.js | verdan/material-ui | import React from 'react';
import MobileTearSheet from '../../../MobileTearSheet';
import {List, ListItem} from 'material-ui/List';
import ActionGrade from 'material-ui/svg-icons/action/grade';
import ContentInbox from 'material-ui/svg-icons/content/inbox';
import ContentDrafts from 'material-ui/svg-icons/content/draft... |
src/containers/community/CommunityProfile.js | Hylozoic/hylo-redux | import React from 'react'
import { compose } from 'redux'
import { connect } from 'react-redux'
import { prefetch, defer } from 'react-fetcher'
import { get } from 'lodash'
import { FETCH_COMMUNITY } from '../../actions/constants'
import {
fetchCommunity, fetchCommunitiesForNetworkNav, saveCurrentCommunityId
} from '... |
src/app/components/home/song-table-row.js | feedm3/unhypem-frontend | /**
* This component is used to display a song as a table row. It also displays the songs streaming url status with a
* corresponding background color.
*
* The component does not implement any click handler logic. It can only delegate to a click handler from the properties.
*
* @author Fabian Dietenberger
*/
'u... |
src/components/ContainerProgress.react.js | nevercast/kitematic | import React from 'react';
/*
Usage: <ContainerProgress pBar1={20} pBar2={70} pBar3={100} pBar4={20} />
*/
var ContainerProgress = React.createClass({
render: function () {
var pBar1Style = {
height: this.props.pBar1 + '%'
};
var pBar2Style = {
height: this.props.pBar2 + '%'
};
va... |
src/parser/paladin/holy/modules/azeritetraits/RadiantIncandescence.js | ronaldpereira/WoWAnalyzer | import React from 'react';
import Analyzer, { SELECTED_PLAYER } from 'parser/core/Analyzer';
import { formatNumber, formatPercentage } from 'common/format';
import SPELLS from 'common/SPELLS/index';
import TraitStatisticBox, { STATISTIC_ORDER } from 'interface/others/TraitStatisticBox';
import ItemHealingDone from 'int... |
examples/react/src/api/Media.stories.js | oblador/loki | import React from 'react';
import './MediaAwareComponent.css';
export default {
title: 'Media',
};
export const MediaAwareComponent = () => (
<div className="MediaAwareComponent" />
);
MediaAwareComponent.storyName = 'with media queries';
export const LightSchemeComponent = () => (
<div className="FeaturesAwa... |
src/TaskStats.js | uqbar-project/redux-workshop | import React from 'react';
export default class TaskStats extends React.Component {
render() {
let total = this.props.stats.reduce((accum, stat) => accum + stat.count, 0);
let stats = this.props.stats.map( (stat) => ({...stat, avg: percent(stat.count, total) }) );
let statsLegend = stats.map( stat =>
... |
public/js/cat_source/es6/components/segments/SimpleEditor.js | Ostico/MateCat | import React from 'react'
import TagUtils from '../../utils/tagUtils'
import SegmentUtils from '../../utils/segmentUtils'
class SimpleEditor extends React.Component {
constructor(props) {
super(props)
}
render() {
const {isTarget, sid, text, segment} = this.props
let htmlText = SegmentUtils.checkCu... |
test/test_helper.js | mbestwick/medication-search | import _$ from 'jquery';
import React from 'react';
import ReactDOM from 'react-dom';
import TestUtils from 'react-addons-test-utils';
import jsdom from 'jsdom';
import chai, { expect } from 'chai';
import chaiJquery from 'chai-jquery';
import { Provider } from 'react-redux';
import { createStore } from 'redux';
import... |
src/svg-icons/editor/format-align-left.js | igorbt/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let EditorFormatAlignLeft = (props) => (
<SvgIcon {...props}>
<path d="M15 15H3v2h12v-2zm0-8H3v2h12V7zM3 13h18v-2H3v2zm0 8h18v-2H3v2zM3 3v2h18V3H3z"/>
</SvgIcon>
);
EditorFormatAlignLeft = pure(EditorFormatAlignL... |
client/src/navigators/AppNavigator.js | wapjude/labify | import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { addNavigationHelpers, StackNavigator } from 'react-navigation';
import LoginScreen from '../components/LoginScreen';
import ProfileScreen from '../components/ProfileScreen';
import BookLab from '../components/... |
src/svg-icons/action/opacity.js | w01fgang/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionOpacity = (props) => (
<SvgIcon {...props}>
<path d="M17.66 8L12 2.35 6.34 8C4.78 9.56 4 11.64 4 13.64s.78 4.11 2.34 5.67 3.61 2.35 5.66 2.35 4.1-.79 5.66-2.35S20 15.64 20 13.64 19.22 9.56 17.66 8zM6 14c.... |
src/ui/elements/MaterialTextarea.js | gouxlord/dev-insight | import React from 'react'
import styles from './MaterialTextarea.scss';
var MaterialTextarea = React.createClass({
render: function(){
return (
<div className={styles.group}>
<textarea placeholder=" " className={styles.textarea} onChange={this.props.onChange} required value... |
hunt/src/components/EventIPPastries.js | StamusNetworks/scirius | import React from 'react';
import { Col } from 'patternfly-react';
import PropTypes from 'prop-types';
const EventIPPastries = (props) => {
const baseUrl = 'https://pastebin.com/';
return (
<Col md={6}>
<h4>Pastries info</h4>
<dl>
{props.data.map((item) => {
if (item['@type'] === ... |
examples/src/app.js | confide/react-autosuggest | require('./app.less');
import React, { Component } from 'react';
import { render } from 'react-dom';
import Badges from './Badges/Badges';
import Examples from './Examples';
import Footer from './Footer/Footer';
import ForkMeOnGitHub from './ForkMeOnGitHub/ForkMeOnGitHub';
import TrackLinks from './TrackLinks/TrackLin... |
src/components/BottomNav/index.js | flasco/Reader_X | import React, { Component } from 'react';
import { StyleSheet, Text, View, Dimensions, TouchableOpacity, InteractionManager } from 'react-native';
import { Icon } from 'react-native-elements';
import { NavigationActions } from 'react-navigation';
import styles from './index.style';
const { height, width } = Dimension... |
imports/api/Routes.js | deortiz10/ProyectoFinal | import React from 'react';
// import { FlowRouter } from 'meteor/kadira:flow-router';
// import { mount } from 'react-mounter';
import Log from '../ui/log.jsx';
// FlowRouter.route('/login', {
// name: 'iniciar',
// action() {
// mount(AppContainer, {
// main: <Log/>,
// });
// },
// },
// ... |
yarn-workspace/modules/input-data-widget/src/index.js | gamerson/liferay-blade-samples | import React from 'react';
import ReactDOM from 'react-dom';
import AppComponent from './AppComponent';
/**
* This is the main entry point of the portlet.
*
* See https://tinyurl.com/js-ext-portlet-entry-point for the most recent
* information on the signature of this function.
*
* @param {Object} params a has... |
src/browser/ui.js | nullstyle/wallet-one | import React from 'react';
import { Router, Route, Link, IndexRoute } from 'react-router';
import * as Screen from "./screens.js";
const style = {
flex: 2,
position: "relative",
};
export default class UI extends React.Component {
render() {
return <div style={style}>
<Router>
<Route path="/" c... |
src/js/pages/test-editor.js | daniel-madera/pijs | import React from 'react'
import { inject, observer } from 'mobx-react'
import { Grid, Row, Col } from 'react-bootstrap'
import { ListGroup, ListGroupItem, Form, FormGroup, FormControl, Glyphicon, Well, ControlLabel, Checkbox, Button } from 'react-bootstrap'
import { SimpleInput, GlyphButton } from '../components/oth... |
tests/mock-react-project/file_0-1.js | nickzuber/infrared | import React from 'react';
import PropTypes from 'prop-types';
import {Remote} from './source'
import * as Specifier from './source'
import Default, {Remote} from './source'
class MyComponent extends React.Component {
static propTypes = {
id,
'lit': 2,
[2 + 2]: 4,
children: PropTypes.node.isRequired
... |
demo/app/components/QRScannerView.js | MarnoDev/AC-QRCode-RN | import React, { Component } from 'react';
import {
StyleSheet,
View,
Animated,
Easing,
Text,
Image,
AppState,
} from 'react-native';
import PropTypes from 'prop-types';
import { RNCamera } from 'react-native-camera';
const defaultRectStyle = { height: 300, width: 300, borderWidth: 0, borderColor: '#00000... |
docs/src/examples/elements/Divider/Types/DividerExampleHorizontalTable.js | Semantic-Org/Semantic-UI-React | import React from 'react'
import { Divider, Header, Icon, Table } from 'semantic-ui-react'
const DividerExampleHorizontalTable = () => (
<>
<Divider horizontal>
<Header as='h4'>
<Icon name='tag' />
Description
</Header>
</Divider>
<p>
Doggie treats are good for all time... |
lib/components/index.js | natdm/go-types-atom | 'use babel';
import React, { Component } from 'react';
import ReactDOM from 'react-dom';
import PropTypes from 'prop-types';
import { Tabs } from './components';
const groupMethodsWithTypes = entries => {
// group methods by type name
let methods = {};
// group methods with types while still preserving li... |
ui/js/icons/YouTube.js | ericsoderberg/pbc-web | import React from 'react';
import Icon from './Icon';
export default class Vimeo extends Icon {}
Vimeo.defaultProps = { ...Icon.defaultProps,
children:
<path d="M23.7585211,6.97245459 C23.7585211,6.97245459 23.5241088,5.31811237 22.8045016,4.58950584 C21.8918793,3.63342939 20.8697217,3.62922968 20.4009829,3.57360... |
src/view/sms/sms-dashboard/components/btnCard.js | fishmankkk/mircowater2.0 | import React from 'react'
import PropTypes from 'prop-types'
import { Icon, Card, Row, Col } from 'antd'
import 'gobal'
function btnCard ({ icon, color, title, onClickFunc }) {
return (
<Card className="m_water_cusor-point m_water_margin-lg-b m_water_padding-lg m_water_bg-white m_water_align-center"
borde... |
app/counter/index.js | littlethree/demo | /**
* Redux Demo 01
* 应用中所有的 state 都以一个对象树的形式储存在一个单一的 store 中。
* 惟一改变 state 的办法是触发 action,一个描述发生什么的对象。
* 为了描述 action 如何改变 state 树,你需要编写 reducers。
*/
import React, { Component } from 'react';
//import DevToolsApp from 'remotedev-app';
import configureStore from './store/configureStore';
import Router from './rout... |
jenkins-design-language/src/js/components/material-ui/svg-icons/av/play-circle-outline.js | alvarolobato/blueocean-plugin | import React from 'react';
import SvgIcon from '../../SvgIcon';
const AvPlayCircleOutline = (props) => (
<SvgIcon {...props}>
<path d="M10 16.5l6-4.5-6-4.5v9zM12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/>
</SvgIcon>
);
AvPlayCircl... |
mysite/draw_svg/src/index.js | raccoongang/socraticqs2 | import React from 'react';
import ReactDOM from 'react-dom';
import './index.css';
import DrawApp from './DrawApp';
import registerServiceWorker from './registerServiceWorker';
document.drawToElement = function (elements, onChange) {
Array.from(elements).forEach((e) => {
ReactDOM.render(<DrawApp onChange=... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.