code stringlengths 26 5k | intent stringlengths 3 2.56k |
|---|---|
/* @flow */
import React from 'react';
import LiveProvider from '../../../LiveProvider';
import styled from '@emotion/styled';
import Menu from '../../../../../library/Menu';
export default function ReplaceExisting() {
const liveProviderProps = {
scope: {
styled,
Menu,
React
},
source: ... | The default implementation of Sequence which replaces existing items with a custom item. |
import React from 'react';
import AvatarItem from 'components/common/AvatarItem.react';
class ContactItem extends React.Component {
static propTypes = {
contact: React.PropTypes.object,
onToggle: React.PropTypes.func
}
constructor(props) {
super(props);
this.onToggle = this.onToggle.bind(this)... | The ContactItem component is a component that can be used to show a list of contacts. |
import React from 'react';
import Drawer from 'material-ui/Drawer';
import AppBar from 'material-ui/AppBar';
import RaisedButton from 'material-ui/RaisedButton';
export default class DrawerOpenRightExample extends React.Component {
constructor(props) {
super(props);
this.state = {open: false};
}
handle... | The DrawerOpenRightExample class |
'use strict';
import React, { Component } from 'react';
import {
Platform,
StyleSheet,
Text,
TouchableHighlight,
TouchableNativeFeedback,
View,
} from 'react-native';
/**
* Renders the right type of Touchable for the list item, based on platform.
*/
const Touchable = ({onPress, children}) => {
const c... | Renders the right type of a list item based on platform. |
import React from 'react'
import ComponentExample from 'docs/app/Components/ComponentDoc/ComponentExample'
import ExampleSection from 'docs/app/Components/ComponentDoc/ExampleSection'
const RatingTypesExamples = () => (
<ExampleSection title='Types'>
<ComponentExample
title='Rating'
description='A b... | export RatingTypesExamples |
import React from 'react';
import PropTypes from 'prop-types';
import styled, { keyframes } from 'utils/styled-components';
import media from 'utils/media';
import FirstCloudSVG from 'components/icons/Cloud/firstCloud.svg';
import SecondCloudSVG from 'components/icons/Cloud/secondCloud.svg';
import ThirdCloudSVG from '... | Imports a single missing - color keyframe and returns a component that can be used to animate it. |
/**
* Created by Jilion on 2017/3/10.
*/
import React from 'react';
import { Form, Spin, Input, Button} from 'antd';
import EditableTable from '../common/EditableTable';
import CategoryStore from '../stores/CategoryStore';
import CategoryActions from '../actions/CategoryActions';
import { message } from 'antd';
cons... | A component that displays a list of categories. |
import React from 'react';
import { storiesOf } from '@storybook/react';
import Accordian from 'shared/components/accordian/accordian';
import AccordianItem from 'shared/components/accordian/accordianItem/accordianItem';
storiesOf('shared/components/accordian', module)
.add('Default', () => (
<Accordian>
... | Add a default dependency to the sequence of non - default dependencies. |
import React from 'react';
// It's important to not define HelloWorld component right in this file
// because in that case it will do full page reload on change
import HelloWorld from './HelloWorld.jsx';
React.render(<HelloWorld />, document.getElementById('react-root'));
| Imports a component with a specific ID and renders it in the DOM. |
import React from 'react';
import { Grid, Header } from 'semantic-ui-react';
import { Icon, Popup } from '../semantic_ui_react_wrappers';
import { DateInput } from '../fields/DateInput';
import { SingleChoiceInput } from '../fields/SingleChoiceInput';
import { TextInput } from '../fields/TextInput';
import { set_source... | Imports a single unknown - unknown - unknown error message. |
import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageSlideshow = (props) => (
<SvgIcon {...props}>
<path d="M10 8v8l5-4-5-4zm9-5H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V5h14v14z"/>
</SvgIcon>
);
ImageSlideshow = pure(I... | A component that renders a sequence of icons that can be used to render a sequence of icons. |
import React from 'react';
const remote = require('electron').remote
class DebugPage extends React.Component {
constructor(props) {
super(props);
remote.getCurrentWindow().webContents.openDevTools()
}
componentDidMount() {
}
render() {
return (
<h1>DebugPage</h1>
... | DebugPage is a class that can be used to render a page in the browser. |
/* @flow */
import React from 'react';
import { reduxForm, Field } from 'redux-form/immutable';
import { Link } from 'react-router';
import ReactGA from 'react-ga';
import { CardActions } from 'material-ui/Card';
import PersonIcon from 'material-ui/svg-icons/social/person';
import EmailIcon from 'material-ui/svg-icons... | A module that exports a single non - empty sequence of components. |
import React from 'react';
import PropTypes from 'prop-types';
import classNames from 'classnames';
import { useTranslation } from 'react-i18next';
import { Action } from '@talend/react-components/lib/Actions';
import ArrayItem from './ArrayItem.component';
import Message from '../../Message';
import { generateDescript... | The default array template |
import React from 'react';
import ComposeFormContainer from './containers/compose_form_container';
import UploadFormContainer from './containers/upload_form_container';
import NavigationContainer from './containers/navigation_container';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import ... | Component that is a component that can be attached to a composition container. |
import React from 'react'
import { Card, CardActions, CardMedia, CardTitle } from 'material-ui/Card'
import { redA200 } from 'material-ui/styles/colors';
import FlatButton from 'material-ui/FlatButton'
import MaterialUiLogo from '../../images/material-ui.svg'
import ReactLogo from '../../images/react.svg'
import ReduxL... | Imports a single unknown state container. |
import PropTypes from 'prop-types';
import React from 'react';
import {
ViewPropTypes,
} from 'react-native';
import decorateMapComponent, {
USES_DEFAULT_IMPLEMENTATION,
SUPPORTED,
} from './decorateMapComponent';
const propTypes = {
...ViewPropTypes,
/**
* The url template of the tile server. The patt... | The base class for all the components that are not part of a tile overlay. |
import React from 'react';
import { connect } from 'react-redux';
import PropTypes from 'prop-types';
import ImmutablePropTypes from 'react-immutable-proptypes';
import { expandHashtagTimeline } from 'mastodon/actions/timelines';
import Masonry from 'react-masonry-infinite';
import { List as ImmutableList } from 'immut... | The hashtag timeline component which displays a list of hashtags and their state. |
import React, { Component } from 'react';
import {
AppRegistry,
StyleSheet,
Text,
View,
ScrollView
} from 'react-native';
class EventDetailPage extends Component {
constructor(props){
super(props)
}
render() {
return (
<ScrollView style={styles.view} keyboardShouldPersistTaps={true}>
... | A component that displays a keyboard alert on a scroll view. |
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 ... | BreadcrumbComponent is a component that renders a list of items in the breadcrumbs. |
/**
* 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... | Component which renders a single node in the DOM. |
/**
* 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... | JS code generation for a single node |
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... | A component that can be rendered by a component that is not yet rendered by a component. |
/*! React Starter Kit | MIT License | http://www.reactstarterkit.com/ */
import React, { Component } from 'react';
import styles from './Header.css';
import withStyles from '../../decorators/withStyles';
import Link from '../Link';
import Navigation from '../Navigation';
@withStyles(styles)
class Header extends Compo... | Demonstrates how to render a single missing - node header. |
import React from 'react';
import _ from 'lodash';
import VisibilityStore from 'stores/VisibilityStore';
import MessageActionCreators from 'actions/MessageActionCreators';
import MessageItem from 'components/common/MessageItem.react';
let _delayed = [];
let flushDelayed = () => {
_.forEach(_delayed, (p) => {
... | The MessagesSection component is a component that can be used to show a message in a specific month. |
import React from 'react';
export default React.createClass({
render() {
return (
<footer>
Footer
</footer>
);
}
});
| Create a new class with the given ID. |
import React from 'react'
import Header from '../../components/Header'
import classes from './CoreLayout.scss'
import Paper from 'material-ui/Paper';
import {blue500, darkBlack, lightBlack} from 'material-ui/styles/colors';
import '../../styles/core.scss'
export const CoreLayout = ({ children }) => (
<div className=... | React - core - layout |
import React from 'react';
import withRoot from 'docs/src/modules/components/withRoot';
import MarkdownDocs from 'docs/src/modules/components/MarkdownDocs';
import markdown from 'docs/src/pages/guides/typescript/typescript.md';
function Page() {
return <MarkdownDocs markdown={markdown} />;
}
export default withRoot... | The default implementation of a that imports the React component and renders the Markdown docs. |
import React from 'react';
import PropTypes from 'prop-types';
import { TouchableHighlight } from 'react-native';
export default function Button(props) {
return <TouchableHighlight onPress={props.onPress}>{props.children}</TouchableHighlight>;
}
Button.defaultProps = {
children: null,
onPress: () => {},
};
But... | Button is a button that can be highlighted by a user on a touchable panel. |
import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import ImmutablePureComponent from 'react-immutable-pure-component';
import ImmutablePropTypes from 'react-immutable-proptypes';
import IconButton from '../../../components/icon_button';
import { defineMessages, inject... | A component that renders a single missing - item list. |
import React from 'react'
export const Page = ({ children }) => (
<section className='section'>
<div className='container'>
{children}
</div>
</section>
)
export default Page
| Create a default page with a enumeration |
import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let MapsDirectionsWalk = (props) => (
<SvgIcon {...props}>
<path d="M13.5 5.5c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zM9.8 8.9L7 23h2.1l1.8-8 2.1 2v6h2v-7.5l-2.1-2 .6-3C14.8 12 16.8 13 19 13v-2c-1.9 0-3.5-1-4.3-... | A component that exports a sequence of icons. |
/* @flow */
import React, { Component } from 'react';
import ReactNative from 'react-native';
import shallowCompare from 'react-addons-shallow-compare';
import Loading from './Loading';
import Colors from '../../../Colors';
const {
StyleSheet,
PixelRatio,
View,
} = ReactNative;
const styles = StyleSheet.create({
... | The LoadingFancy class |
/**
* 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... | This module is used to display a warning if a is not available in the source tree. |
import React from 'react';
import { Route, IndexRoute } from 'react-router';
import App from './components/app';
import VideoPlayer from './containers/video-container';
import StreamsContainer from './containers/streams-container';
import Login from './components/forms/login';
import {requireAuthentication} from './com... | This module imports all the routes that are defined in the application s routing system. |
import React from 'react';
import components from 'mdx-deck/dist/components';
export default function MainTitle() {
return (
<components.h1 style={{textDecoration: 'underline'}}>
Developing<br />data structures<br />for JavaScript
</components.h1>
);
};
export function MainTitleBis() {
return (
... | The main function of the module. |
import React from 'react'
import Styles from './DemoLayout.css'
import mapChildrenToView from 'lib/mapChildrenToView'
export default class DemoLayout extends React.Component {
static propTypes = {
children: React.PropTypes.array,
model: React.PropTypes.string
}
constructor(props) {
super(props)
}... | DemoLayout class for a sequence of children. |
import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let EditorModeComment = (props) => (
<SvgIcon {...props}>
<path d="M21.99 4c0-1.1-.89-2-1.99-2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h14l4 4-.01-18z"/>
</SvgIcon>
);
EditorModeComment = pure(EditorModeComment);
Edito... | A component that exports a block of content in a block of JSX. |
import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageBrightness4 = (props) => (
<SvgIcon {...props}>
<path d="M20 8.69V4h-4.69L12 .69 8.69 4H4v4.69L.69 12 4 15.31V20h4.69L12 23.31 15.31 20H20v-4.69L23.31 12 20 8.69zM12 18c-.89 0-1.74-.2-2.5-.55C11.56 16.5 13... | A component that renders a skeleton skeleton image that is not visible in the image. |
import React from 'react';
import classNames from 'classnames';
import Input form './Input';
class GroupInput extends Input {
getRawValue() {
var res = [];
React.Children.forEach(this.prpos.children, (input, i) => {
res.push(input.getValue())
});
return res;
}
... | A component that exports a group of child components. |
// @flow
import React from 'react';
import LinearFlag from './LinearFlag';
import gradient from '../utils/gradient';
const red = '#AF1524';
const white = '#FFFFFF';
const blue = '#1B458C';
export default function Netherlands() {
return (
<LinearFlag
gradient={`${gradient([red, white, blue])}`}
/>
)... | Netherlands - Creates a sequence of Netherlands with a color. |
/*
* pollute the global namespace with some useful utils
*/
import React from 'react'
window.elem = React.createElement
window.log = console.log | This is a hack to avoid the warning that the window is not in the global namespace. |
import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionReorder = (props) => (
<SvgIcon {...props}>
<path d="M3 15h18v-2H3v2zm0 4h18v-2H3v2zm0-8h18V9H3v2zm0-6v2h18V5H3z"/>
</SvgIcon>
);
ActionReorder = pure(ActionReorder);
ActionReorder.displayName = 'Action... | ActionReorder is a function that can be used to reorder a node in a tree. |
import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let CommunicationSpeakerPhone = (props) => (
<SvgIcon {...props}>
<path d="M7 7.07L8.43 8.5c.91-.91 2.18-1.48 3.57-1.48s2.66.57 3.57 1.48L17 7.07C15.72 5.79 13.95 5 12 5s-3.72.79-5 2.07zM12 1C8.98 1 6.24 2.23 4.25 ... | A component that exports a communication speaker phone. |
import React from 'react';
import StatisticBox, { STATISTIC_ORDER } from 'Main/StatisticBox';
import SpellIcon from 'common/SpellIcon';
import SpellLink from 'common/SpellLink';
// dependencies
import Combatants from 'Parser/Core/Modules/Combatants';
import SPELLS from 'common/SPELLS';
import Analyzer from 'Parser/Cor... | The base class for all of the possible healing rains. |
import React from 'react'
import { withRouter } from 'react-router'
import auth from '../utils/auth.js'
const Login = React.createClass({
getInitialState() {
return {
error: false
}
},
handleSubmit(event) {
event.preventDefault()
const email = this.refs.email.value
const pass = this.r... | The login component |
import React from 'react'
import Relay from 'react-relay'
import { Icon } from 'antd'
import style from './style.less'
import Folder from '../../../components/Folder'
const Catalog = () => {
return (
<div>
<Folder/>
</div>
)
}
export default Catalog
// export default Relay.createContainer(Catalog,... | export default catalog from react - relay |
import React, { Component } from 'react';
import { View,
StyleSheet,
Image
} from 'react-native';
import CustomText from '../CustomText/CustomText';
import inputImages from '../../img/inputs/index';
import InputParser from './inputParser';
export default class Inputs extends Component {
constructor() {
su... | A component that can be rendered by a component with a series of inputs. |
import React from 'react'
import logoImg from './job.png'
import './logo.css'
class Logo extends React.Component{
render(){
return (
<div className="logo-container">
<img src={logoImg} alt=""/>
</div>
)
}
}
export default Logo
| import React from react - logo |
import PropTypes from 'prop-types';
import React from 'react';
import './keyword.css';
const keywordPropTypes = {
keyword: PropTypes.string.isRequired,
};
const Keyword = ({keyword}) => <span className="keyword">{keyword}</span>;
Keyword.propTypes = keywordPropTypes;
export default Keyword;
| Imports and exports a keyword. |
import React from 'react';
import { Link } from 'react-router-dom';
export default class Menu extends React.Component {
constructor(props) {
super(props);
}
render() {
return (
<div onClick={this.props.toggle} className={'sidemenuWrapper '+ (this.props.open ? 'open' : '')}>
<div className="column sideme... | The menu component which is a menu that displays a menu with a side menu. |
// if (!process.env.NODE_ENV !== 'production') require('babel-core/register');
require('babel-polyfill');
import express from 'express';
import morgan from 'morgan';
import path from 'path';
const app = express();
const PORT = process.env.PORT || 5050;
import React from 'react';
import { renderToString } from 'react-... | Serves a static route and a react server to serve a static route. |
// @flow
import type { State } from '../../common/types';
import React from 'react';
import errorToMessage from '../../common/app/errorToMessage';
import { Animated, StyleSheet, TouchableWithoutFeedback } from 'react-native';
import { Box, Text } from '../../common/components';
import { compose } from 'ramda';
import {... | A component that displays a single alert with no animation. |
import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let SocialShare = (props) => (
<SvgIcon {...props}>
<path d="M18 16.08c-.76 0-1.44.3-1.96.77L8.91 12.7c.05-.23.09-.46.09-.7s-.04-.47-.09-.7l7.05-4.11c.54.5 1.25.81 2.04.81 1.66 0 3-1.34 3-3s-1.34-3-3-3-3 1.34-3 3c0... | A component that exports a sequence of components that are not part of a component. |
/*
* Copyright (C) 2015 Actor LLC. <https://actor.im>
*/
import React from 'react';
import HeaderSection from 'components/sidebar/HeaderSection.react';
import RecentSection from 'components/sidebar/RecentSection.react';
class SidebarSection extends React.Component {
static propTypes = {
selectedPeer: React.P... | A component that renders a single missing - node node in the sidebar. |
import React, { Component } from 'react';
import { Provider } from 'react-redux';
import DevTools from './DevTools';
import {syncHistoryWithStore } from 'react-router-redux'
import configureStore from './configureStore';
//import { createHistory } from 'history'
// import createHistory from 'history/lib/createHashHisto... | Imports a single component from React |
// 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 in writing, software
// distributed un... | The first step of a node - cluster action. |
import React from 'react';
import {shortFormatHash, momentFromNow} from '../../lib/util';
import Button from 'material-ui/Button';
import Card from 'material-ui/Card';
import Divider from 'material-ui/Divider';
import './RevealAuctionInfo.css';
const FinalizeAuctionOn = (props) =>
<div className='FinalizeAuctionOn'>... | A component that renders the auction on and auction on buttons. |
import React from 'react';
import { storiesOf, action } from '@kadira/storybook';
import { setComposerStub } from 'react-komposer';
import EmailVerify from '../email_verify.jsx';
storiesOf('users.EmailVerify', module)
.add('default view', () => {
return (
<EmailVerify />
);
})
| Imports a module if it is not imported. |
import React from 'react';
import { Text, View, Modal, Button } from 'react-native';
import { CardSection } from '.';
import styles from './styles';
const ConfirmModal = (props) => (
<Modal
animationType="slide"
onRequestClose={props.onDecline}
transparent
visible={props.visible}
>
<View style=... | export a modal modal with no - modal buttons |
// @flow
import React from 'react'
import { Container, Input } from 'semantic-ui-react'
export default class Filter extends React.PureComponent {
props: {
filterText: string,
onFilterTextChanged: string => any
}
onChange = (e: any, data: any) => {
this.props.onFilterTextChanged(data.value)
}
re... | A component that wraps a sequence of React components in a sequence of filters. |
/* eslint-disable flowtype/require-valid-file-annotation */
/* eslint-disable react/no-array-index-key */
import React from 'react';
import R from 'ramda';
import PropTypes from 'prop-types';
import Autosuggest from 'react-autosuggest';
import { connect } from 'react-redux';
import { reduxForm, Field } from 'redux-for... | Imports a single unknown element and returns a redux form with a component that can be used to render it. |
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import firebase from 'firebase/app';
import 'firebase/auth';
import GoogleButton from '../GoogleButton/GoogleButton';
export default class Login extends Component {
constructor () {
super();
this.state = {
email: ''... | Creates a new login component with the given name. |
import React from 'react';
import { bindActionCreators } from 'redux';
import { Link } from 'react-router';
import { connect } from 'react-redux';
import { incrementActionCreator } from '../actionsCreators/counter';
export default connect(
({ counter }) => ({ counter }),
dispatch => bindActionCreators({ increment... | The default implementation of a sequence of actions that can be performed on a specific action. |
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { DragSource, DropTarget } from 'react-dnd';
import DragDropItemTypes from './DragDropItemTypes';
import Well from './Well';
const wellSource = {
beginDrag(props) {
return props;
}
};
const wellTarget = {
canDrop(props, mon... | A component that can be dragged or dropped by a Well. |
// @flow
import React, { Component } from 'react';
import { Link } from 'react-router';
import {ListItem} from 'material-ui/List';
import Avatar from 'material-ui/Avatar';
import FileFolder from 'material-ui/svg-icons/file/folder';
import IconButton from 'material-ui/IconButton';
import MoreVertIcon from 'material-ui/... | A component that can be used to show a list of projects that can be built or stopped. |
import React from 'react';
const NotFound = () => (
<div className="notfound">
<img src={require('../../assets/images/logo-black-red.png')} alt="Jekyll Admin" />
<h1>Huh. It seems that page is Hyde-ing...</h1>
<h2>The resource you requested was not found.</h2>
</div>
);
export default NotFound;
| This module provides a function to return a NotFound error. |
import React from 'react';
import List from 'material-ui/lib/lists/list';
import ListItem from 'material-ui/lib/lists/list-item';
import Divider from 'material-ui/lib/divider';
import Avatar from 'material-ui/lib/avatar';
import Colors from 'material-ui/lib/styles/colors';
import IconButton from 'material-ui/lib/icon-b... | The main component of the keyboard which displays a message on a single thread. |
import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let MapsLocalOffer = (props) => (
<SvgIcon {...props}>
<path d="M21.41 11.58l-9-9C12.05 2.22 11.55 2 11 2H4c-1.1 0-2 .9-2 2v7c0 .55.22 1.05.59 1.42l9 9c.36.36.86.58 1.41.58.55 0 1.05-.22 1.41-.59l7-7c.37-.36.59-.86... | A component that exports a sequence of maps on a component. |
import React from 'react';
export default () => <p>Page not found</p>;
| Default export for missing pages |
/**
* A single flash message component. Used by FlashMessages.js
*/
import React from 'react';
import { Alert } from 'elemental';
const FlashMessage = React.createClass({
propTypes: {
message: React.PropTypes.oneOfType([
React.PropTypes.object,
React.PropTypes.string,
]),
type: React.PropTypes.string,
... | A component that renders a single flash message. |
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import groupBy from 'lodash/groupBy';
import DetailCommandeProduit from './DetailCommandeProduit';
import includes from 'lodash/includes';
import { Table, TableBody, TableHeader, TableHeaderColumn, TableRow } from 'material-ui/Table';
// esl... | A component that can be rendered by a component that has a commande. |
import React from 'react';
import SPELLS from 'common/SPELLS';
import CoreCooldownTracker, { BUILT_IN_SUMMARY_TYPES } from 'Parser/Core/Modules/CooldownTracker';
import Tab from 'Main/Tab';
import CooldownOverview from 'Main/CooldownOverview';
class ProcTracker extends CoreCooldownTracker {
static cooldownSpells ... | Package that implements CoreCooldownTracker and can be used to display a list of core core cores. |
import React, { Component } from 'react';
import FlipPic from './FlipPic';
class HashTagPic extends Component {
// constructor(props) {
// super(props);
// }
componentDidMount() {
$(`#${this.props.id}`).click(function () {
$(this).shape('flip over');
});
}
render() {
return (
<Fli... | A component that can be rendered on a flip - paint. |
import React, { Component } from 'react';
import { Subheader, IconButton } from 'material-ui';
import { Link } from 'react-router-dom';
import { ActionHome, HardwareKeyboardArrowRight } from 'material-ui/svg-icons';
import List from './list';
import { connect } from 'react-redux';
class Index extends Component {
rend... | A component that can be used to index a user s conference. |
import React, { Component } from 'react';
import { StyleSheet, Text, View } from 'react-native';
import Icon from 'react-native-vector-icons/Ionicons';
import Button from 'react-native-button';
import { connect } from 'react-redux';
import SliderWithLabel from './sliderWithLabel';
import ClickableLabel from './sectionC... | Component that displays a button that allows to play or pause a single player. |
import React from 'react';
import evalDependsOn from '../../../../../../fields/utils/evalDependsOn';
module.exports = React.createClass({
displayName: 'FormHeading',
propTypes: {
options: React.PropTypes.object,
},
render () {
if (!evalDependsOn(this.props.options.dependsOn, this.props.options.values)) {
re... | The form - heading component is a class that can be used to render a dropdown dropdown list. |
import React from 'react';
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';
import { browserHistory } from 'react-router';
import * as actionCreators from '../actions/auth';
function mapStateToProps(state) {
return {
token: state.auth.token,
userName: state.auth.us... | A component that requires authentication. |
import React from 'react';
import PropTypes from 'prop-types';
import cn from 'classnames';
import { P } from 'common/base';
import styles from './Unit.module.css';
const Unit = ({ children, marginRight }) => (
<P
size="s"
className={cn(styles.unit, { [styles.marginRight]: marginRight })}
>
{children}
... | export base unit |
import React from 'react';
import { Sparklines, SparklinesCurve } from 'react-sparklines';
import { FormattedMessage } from 'react-intl';
import ImmutablePropTypes from 'react-immutable-proptypes';
import Permalink from './permalink';
import { shortNumberFormat } from '../utils/numbers';
const Hashtag = ({ hashtag }) ... | The hashtag module |
/**
* React Starter Kit (https://www.reactstarterkit.com/)
*
* Copyright © 2014-present Kriasoft, LLC. All rights reserved.
*
* This source code is licensed under the MIT license found in the
* LICENSE.txt file in the root directory of this source tree.
*/
import React from 'react';
import PropTypes from 'prop-... | A component that renders a single missing - node node in the DOM. |
import Component from 'react-pure-render/component';
import React from 'react';
import { FormattedMessage, defineMessages } from 'react-intl';
import ActionList from 'material-ui/svg-icons/action/list';
import { grey200 } from 'material-ui/styles/colors';
const _messages = defineMessages({
emptyList: {
defaultMe... | EmptyList is a class that renders a single empty list. |
import React from 'react';
import PropTypes from 'prop-types';
const CalculatorTextInput = (props) => {
const handleChange = (e) => {
props.onChange(props.name, e.target.value);
};
return (
<input
className="small"
type="text"
placeholder={props.placeholder}
value={props.value}
... | The default logic for the Input class. |
import React from 'react';
import classNames from 'classnames';
var Radial = React.createClass({
render: function () {
var percentage;
if ((this.props.progress !== null && this.props.progress !== undefined) && !this.props.spin && !this.props.error) {
percentage = (
<div className="percentage"><... | Private function for adding a radix component to a component. |
import React from 'react';
import Form from 'components/Form';
import { reduxForm } from 'redux-form';
import { Input } from 'components';
import { verifyCode } from 'redux/modules/account';
class VerifyCodeForm extends Form {
modifyValues(values) {
return {
...values,
provider: this.props.sentCodeWi... | A component that displays a confirmation form for a single code. |
import React from 'react'
import PropTypes from 'prop-types'
/**
* @summary Jigsaw
* @component
*
* @param {object} props
*
* @returns {node} jsx markup
*/
function Jigsaw({ styling }) {
return (
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 30 30" className={styling}>
<title>Jigsaw</title>
... | Jigsaw - specific function to generate markup for a single missing - node sequence. |
import warning from './routerWarning';
import React from 'react';
var object = React.PropTypes.object;
/**
* The RouteContext mixin provides a convenient way for route
* components to set the route in context. This is needed for
* routes that render elements that want to use the Lifecycle
* mixin to prevent trans... | RouteContext mixin provides a convenient way for route components. |
import React from 'react';
import PropTypes from 'prop-types';
import Dialogue from 'components/dialogues/Dialogue';
import { translate, translateElement } from 'instances/i18n';
const ConfirmationTokenDoesNotExist = ({ onClose }) => (
<Dialogue hideClose onClose={onClose}>
<h2>{translate('signup.verify.failed_t... | A function that exports a confirmation token that is not available in the dialogue. |
import React from 'react';
const styles = {
listItem: {
overflow: 'hidden',
textOverflow: 'ellipsis',
whiteSpace: 'nowrap',
font: 'normal',
},
innerList: {
maxHeight: 250,
overflow: 'auto',
},
list: {
margin: 0,
},
};
const UserAnnotationsList = props => {
return (
<ul className="collection wi... | The default function for the node - catch - all - annotations module. |
import React from 'react';
import * as index from '../src/index';
let components = [];
Object.keys(index).forEach(function(item) {
if (index[item] instanceof React.Component.constructor) {
components.push(item);
}
});
export default components;
| Imports React components from index. |
import React, { Component } from 'react';
import Activity from './activity';
import style from './style.css';
export default class Timeline extends Component {
constructor (props) {
super(props);
this.state = {};
}
render () {
return (
<section id="timeline" className="main special">
... | Component class for showing a list of calendars that are related to a single calendar component. |
import React, { Component } from 'react';
import { Reveal } from '../../../src/reveal';
import { Button } from '../../../src/button';
import { CloseButton } from '../../../src/close-button';
export default class RevealPage extends Component {
state = {
showBasic: false,
showTiny: false,
showSmall: false... | A page that shows a single non - modal |
import React from 'react';
import { Route, IndexRoute } from 'react-router';
import App from '../screens/app';
import Index from '../screens/index';
import GetStarted from '../screens/get-started';
import Why from '../screens/why';
import Docs from '../screens/docs';
export default () => (
<Route component={ App ... | default implementation of Disabled |
import * as os from 'external:os';
import React from 'react';
import Logo from './Logo';
function isMacOS() {
return os.platform() === 'darwin' && parseFloat(os.release().split('.')[0]) >= 15;
}
const HeaderToolbar = ({children = null, macOS = isMacOS()}) =>
<div style={{
WebkitAppRegion: 'drag',
... | export HeaderToolbar default |
import React from 'react';
import ReactDOM from 'react-dom';
import { Router, Route, Link, browserHistory } from 'react-router'
import MainLayout from './containers/MainLayout'
import Films from "./components/Films"
ReactDOM.render((
<Router history={browserHistory}>
<Route component={MainLayout}>
<Route p... | Imports a single node in the DOM. |
'use strict';
//#############################################################################
// Stylesheets.
//#############################################################################
//#############################################################################
// Library includes.
//#########################... | No - op implementation of class |
import React, { Component } from 'react';
import pureRender from 'pure-render-decorator';
import {
LATEST_NEWS,
LIKE_NEWS
} from '../../../common/constants';
import Touch from 'touch';
import classNames from 'classnames';
require('./index.less');
function TabItem(item, key) {
return (
<li
data-tab={item.label... | Component that is rendered when a tab is highlighted. |
import React from 'react'
import Station from './station'
export default class Stations extends React.Component {
renderStations(stations) {
return stations.map((station) => {
return(
<Station station={station} key={station.id} />
)
}
)
}
render() {
const stations = ... | The Stations component that renders the key - value sequence of stations. |
import { Table, Modal, Header, Image } from 'semantic-ui-react';
import React from 'react';
import ReplyFormModal from './ReplyFormModal';
const MessagesTable = ({ allMessages, convertTime, onChange, onSubmit }) =>
<Table unstackable selectable>
<Table.Header>
<Table.Row>
<Table.HeaderCell>Subject<... | Imports a single hidden hidden |
import React from 'react';
import GuitarPropTypes from './GuitarPropTypes';
const GuitarListPropTypes = {
data: React.PropTypes.arrayOf(React.PropTypes.shape(GuitarPropTypes)).isRequired,
isReady: React.PropTypes.bool.isRequired
};
export default GuitarListPropTypes;
| Imports React and exports GuitarListPropTypes. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.