path stringlengths 5 195 | repo_name stringlengths 5 79 | content stringlengths 25 1.01M |
|---|---|---|
examples/forms-material-ui/src/components/forms-update-overlay/Hook.js | lore/lore-forms | import React from 'react';
import createReactClass from 'create-react-class';
import PropTypes from 'prop-types';
export default createReactClass({
displayName: 'Hook',
propTypes: {
model: PropTypes.object.isRequired
},
render: function() {
const { model } = this.props;
return (
<div key={... |
cross-player.js | mathbruyen/u-tic-tac-toe | /* jshint node: true, esnext: true */
import React from 'react';
export default class CrossPlayer extends React.Component {
render() {
return React.DOM.div(null, 'X');
}
}
|
app/containers/NotFoundPage/index.js | BrewPi/brewpi-ui | /**
* 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 necessity for you then you can refactor it... |
src/js/components/IndexDoc.js | grommet/grommet-index-docs | // (C) Copyright 2014-2016 Hewlett Packard Enterprise Development LP
import React, { Component } from 'react';
import DocsArticle from './DocsArticle';
import Example from './Example';
import Index from 'grommet-index/components/Index';
import Query from 'grommet-index/utils/Query';
import attributes from '../attribut... |
webpack/components/TypeAhead/pf3Search/TypeAheadItems.js | snagoor/katello | import React from 'react';
import { Dropdown, MenuItem } from 'patternfly-react';
import { commonItemPropTypes } from '../helpers/commonPropTypes';
const TypeAheadItems = ({
items, activeItems, getItemProps, highlightedIndex,
}) => (
<Dropdown.Menu className="typeahead-dropdown">
{items.map(({ text, type, dis... |
node_modules/react-router-dom/node_modules/react-router/es/Switch.js | 937aaron/reduxblog | 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 &... |
docs/src/app/components/pages/components/Checkbox/Page.js | ichiohta/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 checkboxReadmeText from './README';
import checkboxCode from '!raw!materi... |
demo/src/components/App/App.js | moroshko/giant-piano | import styles from './App.less';
import React, { Component } from 'react';
import createPagination from 'createPagination';
export default class App extends Component {
constructor() {
super();
const itemsPerPage = 10;
const maxPages = 5;
const currentPage = 4;
const totalItems = 127;
const... |
src/Assignments/StudyGuideModal.js | SwimmingFishSeniorDesign/SwimmingFishWeb | import React from 'react';
import Modal from 'react-modal';
import StudyGuideForm from './StudyGuideForm';
import FlatButton from 'material-ui/FlatButton';
const styles = {
content: {
top: '50%',
left: '50%',
right: 'auto',
marginRight: '-50%',
transform: 'translate(-50%, -5... |
modules/RouterContextMixin.js | stanleycyang/react-router | import React from 'react';
import invariant from 'invariant';
import { stripLeadingSlashes, stringifyQuery } from './URLUtils';
var { func, object } = React.PropTypes;
function pathnameIsActive(pathname, activePathname) {
if (stripLeadingSlashes(activePathname).indexOf(stripLeadingSlashes(pathname)) === 0)
retu... |
tests/react/createElementRequiredProp_string.js | ylu1317/flow | // @flow
import React from 'react';
class Bar extends React.Component<{test: number}> {
render() {
return (
<div>
{this.props.test}
</div>
)
}
}
class Foo extends React.Component<{}> {
render() {
const Cmp = Math.random() < 0.5 ? 'div' : Bar;
return (<Cmp/>);
}
}
|
src/routes/adminToolResponseItem/AdminToolResponseItem.js | goldylucks/adamgoldman.me | // @flow
import React from 'react'
import axios from 'axios'
import Link from '../../components/Link'
import Markdown from '../../components/Markdown'
import { replaceVarsUtil } from '../../components/MultiStepForm/multiStepFormUtils'
type Props = {
id: string,
}
class AdminToolResponseItem extends React.Componen... |
src/parser/shared/modules/resources/mana/ManaUsageGraph.js | anom0ly/WoWAnalyzer | import BaseChart, { formatTime } from 'parser/ui/BaseChart';
import PropTypes from 'prop-types';
import React from 'react';
import { AutoSizer } from 'react-virtualized';
const COLORS = {
MANA: {
background: 'rgba(2, 109, 215, 0.25)',
border: 'rgba(2, 109, 215, 0.6)',
},
HEALING: {
background: 'rgba(... |
docs/app/Examples/modules/Dropdown/Types/DropdownExampleSelection.js | ben174/Semantic-UI-React | import React from 'react'
import { Dropdown } from 'semantic-ui-react'
import { friendOptions } from '../common'
const DropdownExampleSelection = () => (
<Dropdown placeholder='Select Friend' fluid selection options={friendOptions} />
)
export default DropdownExampleSelection
|
node-siebel-rest/siebel-claims-native/components/Avatar.js | Pravici/node-siebel | import { ColorPropType, StyleSheet, Text, View } from 'react-native';
import PropTypes from 'prop-types';
import React from 'react';
export default function Avatar({ size, backgroundColor, initials }) {
const style = {
width: size,
height: size,
borderRadius: size / 2,
backgroundColor,
};
return... |
src/components/MediaList/Actions/MoveToFirst.js | welovekpop/uwave-web-welovekpop.club | import React from 'react';
import PropTypes from 'prop-types';
import MoveToFirstIcon from '@material-ui/icons/KeyboardArrowUp';
import Action from './Action';
const MoveToFirst = ({ onFirst, ...props }) => (
<Action {...props} onAction={onFirst}>
<MoveToFirstIcon />
</Action>
);
MoveToFirst.propTypes = {
o... |
src/routes.js | k2truong/webapp-starterkit | import React from 'react';
import { IndexRoute, Route } from 'react-router';
import { isLoaded as isAuthLoaded, load as loadAuth } from 'redux/modules/auth';
import {
App,
Chat,
Home,
Widgets,
About,
Login,
Signup,
Survey,
NotFound,
} from 'containers';
export default (store) => {... |
src/widgets/PriorityPicker.android.js | anysome/objective | /**
* Created by Layman(http://github.com/anysome) on 16/3/6.
*/
import React from 'react';
import Picker from 'react-native-wheel-picker';
import Objective from '../logic/Objective';
import {colors} from '../views/styles';
export default class PriorityPicker extends React.Component {
constructor(props) {
su... |
components/animals/takinIndicky.child.js | marxsk/zobro | import React, { Component } from 'react';
import { Text } from 'react-native';
import styles from '../../styles/styles';
import InPageImage from '../inPageImage';
import AnimalText from '../animalText';
import AnimalTemplate from '../animalTemplate';
const IMAGES = [
require('../../images/animals/takinIndicky/01.jp... |
src/routes/Chapter/components/ChapterView.js | bingomanatee/wonderworld | import React from 'react';
import './chapter.scss';
import _ from 'lodash';
import ArticleListItem from '../../../components/ArticleListItem/ArticleListItem';
export class chapter extends React.Component {
constructor (props) {
super(props);
console.log('loading articles');
}
static contextTypes = {
... |
src/index.js | Jiivee/react-test | import React from 'react';
import { render } from 'react-dom'
import App from './App';
import Matches from './components/Matches'
import Rules from './components/Rules'
import Tournaments from './components/Tournaments'
import Tournament from './components/Tournament'
import NewTournament from './components/NewTourname... |
docs/src/sections/ButtonSection.js | jesenko/react-bootstrap | import React from 'react';
import Anchor from '../Anchor';
import PropTable from '../PropTable';
import ReactPlayground from '../ReactPlayground';
import Samples from '../Samples';
export default function ButtonSection() {
return (
<div className="bs-docs-section">
<h1 className="page-header">
<An... |
test/regressions/tests/LinearProgress/DeterminateLinearProgress.js | dsslimshaddy/material-ui | // @flow
import React from 'react';
import LinearProgress from 'material-ui/Progress/LinearProgress';
export default function DeterminateLinearProgress() {
return (
<LinearProgress
mode="determinate"
value={60}
style={{
width: 150,
}}
/>
);
}
|
src/client/auth/logout.react.js | Tzitzian/Oppex | import Component from '../components/component.react';
import React from 'react';
export default class Logout extends Component {
static propTypes = {
actions: React.PropTypes.object.isRequired,
msg: React.PropTypes.object.isRequired
}
render() {
const {actions, msg} = this.props;
return (
... |
src/svg-icons/hardware/devices-other.js | ruifortes/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let HardwareDevicesOther = (props) => (
<SvgIcon {...props}>
<path d="M3 6h18V4H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h4v-2H3V6zm10 6H9v1.78c-.61.55-1 1.33-1 2.22s.39 1.67 1 2.22V20h4v-1.78c.61-.55 1-1.34 1-2.22s-.39-1... |
src/svg-icons/image/filter-3.js | frnk94/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageFilter3 = (props) => (
<SvgIcon {...props}>
<path d="M21 1H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zM3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm14 8v-1.5c0-.83-.67-1.5-1... |
ui/src/main/js/components/Breadcrumb.js | medallia/aurora | import React from 'react';
import { Link } from 'react-router-dom';
function url(...args) {
return args.join('/');
}
export default function Breadcrumb({ cluster, role, env, name, instance, taskId, update }) {
const crumbs = [<Link key='cluster' to='/scheduler'>{cluster}</Link>];
if (role) {
crumbs.push(<sp... |
src/components/ProjectActivityCard/component.js | Hylozoic/hylo-redux | import React from 'react'
import Post from '../Post'
import A from '../A'
import { imageUrl } from '../../models/post'
import { humanDate } from '../../util/text'
const spacer = <span> • </span>
const ProjectActivityCard = ({ expanded, onExpand, post, parentPost }, { isMobile }) => {
const bac... |
app/containers/App/index.js | audoralc/pyxis | /**
*
* App.react.js
*
* This component is the skeleton around the actual pages, and should only
* contain code that should be seen on all pages. (e.g. navigation bar)
*
*/
import React from 'react';
import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider';
import getMuiTheme from 'material-ui/styles... |
src/components/01-atoms/Calendar/Day/index.js | buildit/bookit-web | import React from 'react'
import PropTypes from 'prop-types'
import momentPropTypes from 'react-moment-proptypes'
import { connect } from 'react-redux'
import { selectDate } from '../../../../actions'
import styles from './styles.scss'
import { day as dayConfig, dot as dotConfig } from '../config'
export const Day = ... |
react-flux-mui/js/material-ui/src/svg-icons/social/person-add.js | pbogdan/react-flux-mui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let SocialPersonAdd = (props) => (
<SvgIcon {...props}>
<path d="M15 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm-9-2V7H4v3H1v2h3v3h2v-3h3v-2H6zm9 4c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"/>
</... |
react/features/base/react/components/web/SectionList.js | gpolitis/jitsi-meet | // @flow
import React, { Component } from 'react';
import type { Section } from '../../Types';
import Container from './Container';
type Props = {
/**
* Rendered when the list is empty. Should be a rendered element.
*/
ListEmptyComponent: Object,
/**
* Used to extract a unique key for a... |
examples/search-form/modules/index.js | alexeyraspopov/react-coroutine | import React from 'react';
import ReactDOM from 'react-dom';
import SearchForm from './SearchForm';
export default class App extends React.Component {
constructor(props) {
super(props);
this.state = { query: '' };
this.handleEvent = this.handleEvent.bind(this);
}
handleEvent(event) {
let query =... |
redux/src/main/renderer/components/TweetBody.js | wozaki/twitter-js-apps | import React from 'react';
import Time from './Time';
import twitterText from 'twitter-text';
import TweetAnchorText from '../../domain/models/TweetAnchorText';
const Anchor = ({ onAnchorClicked, url, text, title }) => {
return (
<a className="Tweet-anchor"
dangerouslySetInnerHTML={{ __html: text }}
... |
packages/react/.storybook/addon-theme/register.js | carbon-design-system/carbon-components | /**
* Copyright IBM Corp. 2021, 2021
*
* 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 React from 'react';
import { addons } from '@storybook/addons';
import { CarbonThemePanel, CarbonTypePanel } from './components/Panel'... |
components/Trendline.js | cofacts/rumors-site | import React from 'react';
/**
* @param {string} props.id - String ID of article
*/
function Trendline({ id }) {
return (
<a
className="root"
href={`https://datastudio.google.com/u/0/reporting/18J8jZYumsoaCPBk9bdRd97GKvi_W5v-r/page/NrUQ?config=%7B%22df7%22:%22include%25EE%2580%25800%25EE%2580%2580I... |
src/index.js | nilvisa/LEK_react-with-redux | import _ from 'lodash';
import React, { Component } from 'react';
import ReactDOM from 'react-dom';
import YTSearch from 'youtube-api-search';
import SearchBar from './components/search_bar';
import VideoList from './components/video_list';
import VideoDetail from './components/video_detail';
const API_KEY = 'AIzaSyDf... |
src/index.js | ayonghosh/circle-chart-demo | import React from 'react';
import ReactDOM from 'react-dom';
import ReactCSSTransitionGroup from 'react-addons-css-transition-group';
import CircularMeter from './CircularMeter';
let el = document.getElementById('app');
const App = React.createClass({
render() {
return (
<div>
<CircularMeter val=... |
src/native/todos/Checkbox.js | skallet/este | // @flow
import type { ButtonProps } from '../../common/components/Button';
import React from 'react';
import { Box, Button } from '../../common/components';
import { Image } from 'react-native';
type CheckboxProps = ButtonProps & {
checked?: boolean,
};
const images = {
checked: require('./img/CheckboxChecked.pn... |
src/CarouselItem.js | PeterDaveHello/react-bootstrap | import React from 'react';
import classNames from 'classnames';
import TransitionEvents from './utils/TransitionEvents';
const CarouselItem = React.createClass({
propTypes: {
direction: React.PropTypes.oneOf(['prev', 'next']),
onAnimateOutEnd: React.PropTypes.func,
active: React.PropTypes.bool,
anima... |
admin/client/components/ListControl.js | efernandesng/keystone | import React from 'react';
import classnames from 'classnames';
var ListControl = React.createClass({
propTypes: {
onClick: React.PropTypes.func,
type: React.PropTypes.oneOf(['check', 'delete', 'sortable']).isRequired
},
renderControl () {
var icon = 'octicon octicon-';
var className = classnames('ItemLis... |
src/svg-icons/device/signal-cellular-3-bar.js | barakmitz/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let DeviceSignalCellular3Bar = (props) => (
<SvgIcon {...props}>
<path fillOpacity=".3" d="M2 22h20V2z"/><path d="M17 7L2 22h15z"/>
</SvgIcon>
);
DeviceSignalCellular3Bar = pure(DeviceSignalCellular3Bar);
DeviceS... |
src/PageHeader.js | mxc/react-bootstrap | import React from 'react';
import classNames from 'classnames';
const PageHeader = React.createClass({
render() {
return (
<div {...this.props} className={classNames(this.props.className, 'page-header')}>
<h1>{this.props.children}</h1>
</div>
);
}
});
export default PageHeader;
|
examples/sidebar/app.js | gdi2290/react-router | import React from 'react';
import HashHistory from 'react-router/lib/HashHistory';
import { Router, Route, Link } from 'react-router';
import data from './data';
var Category = React.createClass({
render() {
var category = data.lookupCategory(this.props.params.category);
return (
<div>
<h1>{cat... |
src/client/components/message/chatMessage.js | uuchat/uuchat | import React, { Component } from 'react';
import { Modal } from 'antd';
import ChatMessageItem from './chatMessageItem';
let onlineListModal = null;
let historyChatFetch = false;
class ChatMessage extends Component{
constructor(){
super();
this.state = {
markVisible: false,
... |
Project 03 - TopMovies/src/components/ListCardItem.js | DCKT/30DaysofReactNative | // @flow
import React from 'react'
import { Image } from 'react-native'
import { Card, CardItem, Left, Body, Text, Button, Icon } from 'native-base'
import type { TMovieListDetail } from '../utils/types'
type Props = {
movie: TMovieListDetail,
onPress: Function
}
export default (props: Props) => {
const { movie... |
src/svg-icons/image/crop-portrait.js | hwo411/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageCropPortrait = (props) => (
<SvgIcon {...props}>
<path d="M17 3H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H7V5h10v14z"/>
</SvgIcon>
);
ImageCropPortrait = pure(ImageCropP... |
src/components/Layout/Header.js | yining1023/thesisBook | import React from 'react'
import {Link} from 'react-router-dom'
import s from './Header.css'
import FilterMenu from '../FilterMenu/FilterMenu'
import logo from '../../img/itp-logo-tisch.svg'
import {Drawer, IconButton} from 'material-ui'
import MenuIcon from 'material-ui/svg-icons/navigation/menu'
class Header extends... |
node-red/ui/src/components/joystick/main.js | dennisdunn/botlab | import React from 'react';
import ReactDOM from 'react-dom';
import Style from './style.css'
class Joystick extends React.Component {
constructor(props) {
super(props);
};
render() {
(
<div id={this.props.id || "joystick1"}>
<canvas></canvas>
</div>
... |
frontend/src/lib/mui-components/ComboboxDialog/components/_ListVirtualized.js | jf248/scrape-the-plate | import React from 'react';
import classnames from 'classnames';
import * as Mui from '@material-ui/core';
import * as Virtualized from 'react-virtualized';
import ListItem from './ListItem';
const styles = theme => ({
root: {
backgroundColor: theme.palette.background.paper,
flex: '1 0 auto',
height: '10... |
src/components/Spinner/Spinner.js | ismaelgt/english-accents-map | import React from 'react'
class Spinner extends React.Component {
componentDidMount () {
componentHandler.upgradeDom()
}
render () {
return (
<div className='loading-indicator'>
<div ref='spinner' className='mdl-spinner mdl-spinner--single-color mdl-js-spinner is-active' />
</div>
... |
components/Footer/Footer.js | elliotec/LnL | import React from 'react';
import FaFacebookSquare from 'react-icons/lib/fa/facebook-square';
import './Footer.css';
import { Link } from 'react-router';
import inthegullyLogo from 'images/inthegullylogoblack.png';
export default class Footer extends React.Component {
render () {
return (
<div className="f... |
app/components/View/index.js | wanbinkimoon/parmigiana | /**
*
* View
*
*/
import React from 'react';
import ReactDOM from 'react-dom';
import { ViewWrap } from './styles'
import Scene from './scene'
class View extends React.Component { // eslint-disable-line react/prefer-stateless-function
componentDidMount() {
const { screen } = this.props
const ViewDOM = Re... |
src/routes/ServiceUnavailable/components/ServiceUnavailableView.js | TorinoMeteo/tm-realtime-map | import React from 'react'
export const ServiceUnavailableView = () => (
<div className='page-error'>
<h1 className='text-center'>
<i className='ion-alert-circled' /><br />
Servizio non disponibile 503
</h1>
<p className='lead text-center'>Il server è al momento incapace di risovere le richies... |
app/jsx/gradebook/SISGradePassback/PostGradesDialogSummaryPage.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... |
react-semi-theme/src/greetings/Hola.js | tsupol/semi-starter | import React from 'react';
// Since this component is simple and static, there's no parent container for it.
const Hola = () => {
return (
<div>
<h2>Hola from semi theme!</h2>
</div>
);
};
export default Hola;
|
src/components/Github/LoadMoreButton.js | jseminck/react-native-github-feed | import React from 'react';
import { View, TouchableHighlight, Text } from 'react-native';
export default class LoadMoreButton extends React.Component {
static propTypes = {
onLoadMore: React.PropTypes.func.isRequired
}
render() {
return (
<View style={styles.container}>
... |
packages/material-ui-icons/src/SignalWifi2BarLock.js | lgollut/material-ui | import React from 'react';
import createSvgIcon from './utils/createSvgIcon';
export default createSvgIcon(
<React.Fragment><path d="M23 16v-1.5c0-1.4-1.1-2.5-2.5-2.5S18 13.1 18 14.5V16c-.5 0-1 .5-1 1v4c0 .5.5 1 1 1h5c.5 0 1-.5 1-1v-4c0-.5-.5-1-1-1zm-1 0h-3v-1.5c0-.8.7-1.5 1.5-1.5s1.5.7 1.5 1.5V16z" /><path d="M15.5... |
src/components/common/svg-icons/editor/format-bold.js | abzfarah/Pearson.NAPLAN.GnomeH | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let EditorFormatBold = (props) => (
<SvgIcon {...props}>
<path d="M15.6 10.79c.97-.67 1.65-1.77 1.65-2.79 0-2.26-1.75-4-4-4H7v14h7.04c2.09 0 3.71-1.7 3.71-3.79 0-1.52-.86-2.82-2.15-3.42zM10 6.5h3c.83 0 1.5.67 1.5 1... |
packages/frontend/src/components/adminPage/MonitoringService/index.js | ks888/LambStatus | import React from 'react'
// MonitoringService is an interface the all monitoring service classes should implement.
export class MonitoringService {
// getMetricsSelector returns a React component to select monitoring service's metrics.
// The component must handle the `props` object and the `onChange` function pr... |
src/components/FreelancerInfo/FreelancerInfo.js | ortonomy/flingapp-frontend | import React, { Component } from 'react';
import InfoTable from '../InfoTable/InfoTable';
import info from './FreelancerInfo.module.css';
class FreelancerInfo extends Component {
render() {
const personalInfo = {
'first name': this.props.freelancer.flFirstName,
'last name': this.props.freelancer.flLa... |
src/routes.js | Bucko13/kinects-it | import React from 'react';
import { Route, IndexRoute } from 'react-router';
import { App } from './components/App';
import { Home } from './components/Home';
import Demo from './containers/Demo';
import LoginPage from './containers/LoginPage';
import { SignupPage } from './components/SignupPage';
import DashboardPage... |
blueocean-material-icons/src/js/components/svg-icons/hardware/smartphone.js | kzantow/blueocean-plugin | import React from 'react';
import SvgIcon from '../../SvgIcon';
const 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.displayName = 'HardwareSmartphone';
... |
13. ReactJS Fundamentals - Feb 2019/03. Events and Forms/Fog-App/src/DynamicForm/RegisterForm.js | zrusev/SoftUni_2016 | import React from 'react';
import './register.css';
class RegisterForm extends React.Component {
constructor(props) {
super(props);
this.state = {
usernameReg: '',
emailReg: '',
passwordReg: ''
}
}
handleChange = event => {
this.setState... |
src/compoments/PurpleCard.js | purple-net/react-native-purple | import React from 'react'
import { View, StyleSheet, Platform, Image } from 'react-native'
import fonts from '../config/fonts'
import colors from '../config/colors'
import Text from './PurpleText'
import Divider from './PurpleDivider'
import normalize from '../util/normalizeText'
let styles = {}
const PurpleCard = ({... |
src/applications/edu-benefits/0994/pages/bankInformation.js | department-of-veterans-affairs/vets-website | import _ from 'lodash';
import React from 'react';
import fullSchema from 'vets-json-schema/dist/22-0994-schema.json';
import ReviewCardField from 'platform/forms-system/src/js/components/ReviewCardField';
import { isValidRoutingNumber } from 'platform/forms/validations';
import { hasNewBankInformation, hasPrefillBankI... |
src/js/components/HeaderWeekDaysRow.js | Pearson-Higher-Ed/o-calendar | import React from 'react'
const HeaderWeekDaysRow = (props) => {
return(
<tr>
{props.daysOfWeek.map( (dayOfWeek,i) =>
<th id ={`weekdayHeaderRowCell${i}`} className ='weekdayHeaderRowCell' key ={`weekdayHeaderRowCell${i}`}>
{dayOfWeek}
</th>
)}
</tr>
)
}
export defau... |
src/components/MainPage/AboutPattern.js | coolshare/ReactReduxPattern | import React from 'react';
import {connect} from 'react-redux'
import cs from '../../services/CommunicationService'
import RemoteService from '../../services/RemoteService'
import Footer from './Footer';
/**
*
*/
class _AboutPattern extends React.Component{
componentDidMount(tabId) {
let self = this;
RemoteServic... |
src/uic/RightDrawer.js | ajaycheenath/abs | import React, { Component } from 'react';
import drawerStyle from "../css/drawer.css";
import Icon from "./Icon";
class Card extends Component {
componentWillMount() {
this.setState({show: true});
}
onClose = () =>{
this.props.showDrawer(false);
}
render() {
return (
<div>
<div ... |
src/carousel.js | jaketrent/react-drift | import PropTypes from 'prop-types'
import React from 'react'
import styleable from 'react-styleable'
import css from './carousel.css'
function renderSlides(props) {
return React.Children.map(props.children, (slide, i) => {
return React.cloneElement(slide, {
style: {
...slide.props.style,
w... |
src/routes/about/index.js | balmbees/overwatch | import React from 'react';
import About from './About';
export default {
path: '/about',
action() {
return (
<About />
);
},
};
|
techCurriculum/ui/solutions/2.6/src/components/Title.js | tadas412/EngineeringEssentials | /**
* Copyright 2017 Goldman Sachs.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to... |
scripts/Input.js | rachardking/react-lofty | import React from 'react';
import classNames from 'classnames';
import validator from 'validator';
import validationMessage './validationMessage';
import Base from './Base';
import addons from 'react/addons';
class Input extends Base {
constructor(props) {
super(props);
this.state = {
... |
app/jsx/assignments_2/student/components/LatePolicyStatusDisplay/index.js | djbender/canvas-lms | /*
* Copyright (C) 2018 - 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... |
newclient/scripts/components/admin/admin.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... |
app/projectList/ProjectList.js | stefanKuijers/aw-fullstack-app | // @flow
import React, { Component } from 'react';
import { remote } from 'electron';
import { getStoredState } from '../app/stateStorage';
import {Card, CardTitle, CardText} from 'material-ui/Card';
import Subheader from 'material-ui/Subheader';
import {List, ListItem} from 'material-ui/List';
import Avatar from 'mat... |
src/components/shop/OrderItem.js | mangal49/HORECA | import React from 'react';
class OrderItem extends React.Component {
render() {
return (
<div>Order Item</div>
);
}
}
export default OrderItem;
|
src/components/controls/input-file.js | kishorevarma/formsy-bulma-components | import React, { Component } from 'react';
import ControlCommon from './control-common';
// A file control can only be set to an empty string.
// I think we need to keep this as an uncontrolled component, so we override the
// value.prop.
class FileControl extends Component {
initElementRef = (element) => {
... |
src/svg-icons/image/camera-alt.js | manchesergit/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageCameraAlt = (props) => (
<SvgIcon {...props}>
<circle cx="12" cy="12" r="3.2"/><path d="M9 2L7.17 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2h-3.17L15 2H9zm3 15c-2.76 0-5-2.24-5... |
app/javascript/mastodon/features/compose/components/autosuggest_account.js | PlantsNetwork/mastodon | import React from 'react';
import Avatar from '../../../components/avatar';
import DisplayName from '../../../components/display_name';
import ImmutablePropTypes from 'react-immutable-proptypes';
import ImmutablePureComponent from 'react-immutable-pure-component';
export default class AutosuggestAccount extends Immuta... |
examples/js/others/expose-api-table.js | powerhome/react-bootstrap-table | /* eslint max-len: 0 */
/* eslint no-alert: 0 */
import React from 'react';
import { BootstrapTable, TableHeaderColumn } from 'react-bootstrap-table';
const products = [];
function addProducts(quantity) {
const startId = products.length;
for (let i = 0; i < quantity; i++) {
const id = startId + i;
product... |
src/svg-icons/image/grain.js | pancho111203/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageGrain = (props) => (
<SvgIcon {...props}>
<path d="M10 12c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zM6 8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12-8c1.... |
src/rendering/fields.js | MGrin/mgr-form-react | import React from 'react';
import PropTypes from 'prop-types';
import { FIELD_RENDERER_PROPS } from '../props';
export const input = ({ value, className, fieldNameAsCss, validate, disabled, onValueChange, ...otherProps }) => (
<input
value={value}
className={`${className} ${className}-renderer ${className}-$... |
blueocean-material-icons/src/js/components/svg-icons/action/picture-in-picture-alt.js | jenkinsci/blueocean-plugin | import React from 'react';
import SvgIcon from '../../SvgIcon';
const ActionPictureInPictureAlt = (props) => (
<SvgIcon {...props}>
<path d="M19 11h-8v6h8v-6zm4 8V4.98C23 3.88 22.1 3 21 3H3c-1.1 0-2 .88-2 1.98V19c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2zm-2 .02H3V4.97h18v14.05z"/>
</SvgIcon>
);
ActionPictureInPictureAl... |
test/integration/client-navigation/pages/dynamic/[slug]/route.js | zeit/next.js | import React from 'react'
export default class DynamicRoute extends React.Component {
static async getInitialProps({ query = { slug: 'default' } }) {
return {
query,
}
}
render() {
return <p id="dynamic-page">{this.props.query.slug}</p>
}
}
|
actor-apps/app-web/src/app/components/dialog/TypingSection.react.js | hardikamal/actor-platform | import React from 'react';
import { PureRenderMixin } from 'react/addons';
import classNames from 'classnames';
import DialogStore from 'stores/DialogStore';
export default React.createClass({
mixins: [PureRenderMixin],
getInitialState() {
return {
typing: null,
show: false
};
},
compon... |
src/shared/components/donate/donate.js | sethbergman/operationcode_frontend | import React from 'react';
import Section from 'shared/components/section/section';
import LinkButton from 'shared/components/linkButton/linkButton';
import commonUrl from 'shared/constants/commonLinks';
import styles from './donate.css';
const Donate = () => (
<Section
title="Donate"
headingLines={false}
... |
assets/js/pages/LogoutPage.js | trappar/you-should | import React, { Component } from 'react';
import Redirect from 'react-router/Redirect';
import { observer } from 'mobx-react';
import { observable } from 'mobx';
@observer(['alerts', 'user', 'decisions'])
export default class LogoutPage extends Component {
@observable redirect = false;
constructor(props) {
su... |
src/components/TaskInspector/ExpandingMetadataListItem.js | Charlie9830/pounder | import React, { Component } from 'react';
import { Typography, ListItem, List, ListSubheader, Divider, ListItemIcon, ListItemText } from '@material-ui/core';
import Expander from '../Expander';
import PersonIcon from '@material-ui/icons/Person';
import ClockIcon from '@material-ui/icons/AccessTime';
const MetadataIte... |
example.js | u-wave/react-list-lazy-load | import React from 'react'
import ReactDOM from 'react-dom'
import PropTypes from 'prop-types'
// LazyList wraps around ReactList--so we need both!
import LazyList from 'react-list-lazy-load'
import ReactList from 'react-list'
const randBetween = (min, max) =>
Math.floor(min + (Math.random() * (max - min)))
// Utili... |
src/js/components/icons/base/BrandCodepenTry.js | kylebyerly-hp/grommet | // (C) Copyright 2014-2015 Hewlett Packard Enterprise Development LP
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import classnames from 'classnames';
import CSSClassnames from '../../../utils/CSSClassnames';
import Intl from '../../../utils/Intl';
import Props from '../../../utils/Pro... |
client/src/containers/ErrorContainer.js | redcom/pinstery | // @flow
import type { State, ErrorsType } from '../store/CommonStoreTypes';
import React from 'react';
import { connect } from 'react-redux';
import { Errors } from '../components';
const ErrorContainer = ({ error }: ErrorsType) => {
if (!error.error) return null;
return (
<Errors>
{error.error.message... |
packages/reactor-kitchensink/src/examples/Grid/GroupedGrid/GroupedGrid.js | markbrocato/extjs-reactor | import React, { Component } from 'react';
import { Container, Grid, Toolbar, SegmentedButton, Button, Column } from '@extjs/ext-react';
import './data';
Ext.require([
'Ext.grid.cell.Number',
'Ext.grid.cell.Widget',
'Ext.grid.SummaryRow',
'Ext.ux.rating.Picker'
]);
export default class GroupedGridExamp... |
src/javascript/shared/components/textfields/TextFieldGroup.js | rahulharinkhede2013/xigro-dashboard |
import React from 'react';
import classnames from 'classnames';
const TextFieldGroup = ({ field, value, label, error, type, onChange, checkUserExists }) => {
return (
<div className={classnames('form-group', { 'has-error': error })}>
<label className="control-label">{label}</label>
<input
on... |
src/svg-icons/action/settings-remote.js | jacklam718/react-svg-iconx | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionSettingsRemote = (props) => (
<SvgIcon {...props}>
<path d="M15 9H9c-.55 0-1 .45-1 1v12c0 .55.45 1 1 1h6c.55 0 1-.45 1-1V10c0-.55-.45-1-1-1zm-3 6c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zM7.05 6.05l1.41... |
app/templates/blog/Posts.js | twixlyhq/react-site | import React from 'react';
import PostList from './partials/PostList';
const Posts = (props) => {
return (
<PostList {...props} />
);
};
export default Posts; |
modules/snapshots-navigator/icon/index.js | hakonhk/vaerhona | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { Container, Label, ImageCompare } from './ui';
import {
Picture,
Statistics,
Thermometer,
Droplets,
Compass,
} from '../../icons';
export default class Icon extends Component {
static propTypes = {
selected: PropTyp... |
node_modules/react-bootstrap/es/NavDropdown.js | yeshdev1/Everydays-project | import _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties';
import _classCallCheck from 'babel-runtime/helpers/classCallCheck';
import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';
import _inherits from 'babel-runtime/helpers/inherits';
import _extends from... |
actor-apps/app-web/src/app/components/sidebar/HeaderSection.react.js | liruqi/actor-platform-v0.9 | import _ from 'lodash';
import React from 'react';
import mixpanel from 'utils/Mixpanel';
import ReactMixin from 'react-mixin';
import { IntlMixin, FormattedMessage } from 'react-intl';
import classNames from 'classnames';
import MyProfileActions from '../../actions/MyProfileActionCreators';
import LoginActionCreators... |
app/app.js | kondoSoft/react-car-rental | /**
* app.js
*
* This is the entry file for the application, only setup and boilerplate
* code.
*/
// Needed for redux-saga es6 generator support
import 'babel-polyfill';
// Import all the third party stuff
import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from 'react-redux';
impor... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.