code
stringlengths
26
5k
intent
stringlengths
3
2.56k
import React, { Component } from 'react'; class TableBeta2 extends Component { constructor(props) { super(props); this.state = { login: null, user: null } this.createTable = this.createTable.bind(this); this.detailView = this.props.detailView.bind(this); } createTable(){ cons...
A component that creates a table with a table container.
import React from 'react'; import PropTypes from 'prop-types'; const Sandbox = () => { return ( <div className="outer_face"> <div className="marker oneseven"></div> <div className="marker twoeight"></div> <div className="marker fourten"></div> <div className="marker fiveeleven"></div> ...
The default Sandbox class
// Copyright (c) 2016 Esri Japan import React from 'react'; class SelectSpotTypePage extends React.Component { constructor (props) { super(props); } render () { let visibility = 'block'; if (this.props.visibility === false) { visibility = 'none'; } return ( <div className="se...
Demonstrates how to display a single missing - node tag in a page that has no photos or kujiranspot.
import React from 'react'; export default class Message extends React.Component { render() { return ( <li className="list-group-item">{this.props.author}:{this.props.children} <button onClick={()=>{this.props.click(this.props.id)}} className="btn btn-danger">删除</button> <span cla...
Component that renders a message in a group of messages.
import React from 'react'; import IconBase from 'react-icon-base'; export default class FaUserMd extends React.Component { render() { return ( <IconBase viewBox="0 0 40 40" {...this.props}> <g><path d="m13.1 30q0 0.6-0.5 1t-1 0.4-1-0.4-0.4-1 0.4-1 1-0.4 1 0.4 0.5 1z m22.8 1.4q0 ...
A component that shows a sequence of icons that can be used to show a sequence of users.
import React from 'react'; import 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 from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let NavigationSubdirectoryArrowRight = (props) => ( <SvgIcon {...props}> <path d="M19 15l-6 6-1.42-1.42L15.17 16H4V4h2v10h9.17l-3.59-3.58L13 9l6 6z"/> </SvgIcon> ); NavigationSubdirectoryArrowRight = pure(Navigat...
A component that exports a navigation subtitle in a right - to - left manner.
import React from 'react'; import Avatar from 'material-ui/lib/avatar'; import Card from 'material-ui/lib/card/card'; import CardActions from 'material-ui/lib/card/card-actions'; import CardHeader from 'material-ui/lib/card/card-header'; import CardMedia from 'material-ui/lib/card/card-media'; import CardTitle from 'ma...
A component that can be used to block a user.
import React from 'react'; import { useTranslation } from 'react-i18next'; import { Platform } from 'react-native'; import { IconClose } from '../../base/icons'; import HeaderNavigationButton from './components/HeaderNavigationButton'; /** * Close icon/text button based on platform. * * @param {Function} goBack -...
The screenHeaderCloseButton export function.
import React from 'react'; import { formatPercentage } from 'common/format'; import SpellLink from 'common/SpellLink'; import Module from 'Parser/Core/Module'; import SPELLS from 'common/SPELLS'; import Combatants from 'Parser/Core/Modules/Combatants'; const MINOR = 0.07; const AVERAGE = 0.12; const MAJOR = 0.17; cl...
The base class for all possible potential potential
import React from 'react'; import createSvgIcon from './utils/createSvgIcon'; export default createSvgIcon( <g><path d="M11.61 12.97c-.16-.24-.36-.46-.62-.65-.25-.19-.56-.35-.93-.48.3-.14.57-.3.8-.5.23-.2.42-.41.57-.64.15-.23.27-.46.34-.71.08-.24.11-.49.11-.73 0-.55-.09-1.04-.28-1.46-.18-.42-.44-.77-.78-1.06-.33-.28...
A component that creates a component with a
import React from 'react'; import Telescope from 'telescope'; import Config from '../../../portfolio.config'; import Button from '../button'; import Svg from '../svg'; class Me extends Telescope.Component{ render(){ return ( <div className='me'> <div className='image'> <img src='/assets/...
The default implementation of a single node that is a component that can be rendered by a user.
'use strict'; import React, { Component } from 'react'; import InputText from '../../../components/inputs/InputText.react'; import InputPassword from '../../../components/inputs/InputPassword.react'; import '../../../browser/javascript/mui'; class Login extends Component { constructor(props) { super(prop...
A component that opens a login page.
import React from 'react'; import h from '../helpers.js'; import v from '../services/vendorService.js'; import sign from '../services/sign.js'; import AddVendorForm from './Form.AddVendor.js'; import Cell from './Cell.js'; import Column from './Column.js'; import Table from './Table.js'; class VendorSettings extends...
Private methods - Component that creates a virtual ui that can be used to add or remove a vendor.
import 'babel-polyfill' import React from 'react' import ReactDOM from 'react-dom' import routes from './routes' import Root from './containers/Root' import { browserHistory } from 'react-router' import { syncHistory, routeReducer } from 'redux-simple-router' import thunkMiddleware from 'redux-thunk' import reducers fr...
Imports a single and renders it to the DOM.
import React from 'react'; import styled from 'styled-components'; import rafThrottle from 'raf-throttle'; import TweenOne from 'rc-tween-one'; import Heading from 'mcs-lite-ui/lib/Heading'; import last from 'ramda/src/last'; import DataPointAreaChart from 'mcs-lite-ui/lib/DataPointAreaChart'; import localTimeFormat fr...
The main function for the series chart.
import React from 'react'; var AzureFileColumn = React.createClass({ renderValue () { var value = this.props.data.fields[this.props.col.path]; if (!value) return; return <a href={value.url} target="_blank">{value.url}</a>; }, render () { return ( <td className="ItemList__col"> <div className="ItemLis...
A column that can be used to show Azure File
/*! React Starter Kit | MIT License | http://www.reactstarterkit.com/ */ import React from 'react'; import Router from 'react-routing/src/Router'; import http from './core/http'; import App from './components/App'; import ContentPage from './components/ContentPage'; import ContactPage from './components/ContactPage'; ...
The router for the missing components
import React from 'react'; import {connect} from 'react-redux'; import {bindActionCreators} from 'redux'; import * as courseActions from '../actions/courseActions'; import {departmentSelectListItem} from '../formatters/entityFromatter'; import CoursesList from './courses/CoursesList'; import CourseSave from './courses/...
Component that displays a modal dialog with a single Course.
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 clazz from 'classnames'; import PropTypes from 'prop-types'; import * as componentStyles from '../styles/base/actionBar.sass'; const ActionBar = ({ children }) => <ul className={ componentStyles['action-bar'] }>{ children }</ul>; ActionBar.Item = ({ children, right...
A component that can be rendered as a action bar.
import React from 'react'; import { Router, Route, Link, Redirect } from 'react-router'; var App = React.createClass({ render() { return ( <div> <ul> <li><Link to="/user/123">Bob</Link></li> <li><Link to="/user/abc">Sally</Link></li> </ul> {this.props.children} ...
The main function that creates a hierarchy of all components that are not part of a component hierarchy.
import React from 'react'; const First = React.createNotClass({ displayName: 'First' }); class Second extends React.NotComponent {}
The first component of a sequence
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let EditorBorderColor = (props) => ( <SvgIcon {...props}> <path d="M17.75 7L14 3.25l-10 10V17h3.75l10-10zm2.96-2.96c.39-.39.39-1.02 0-1.41L18.37.29c-.39-.39-1.02-.39-1.41 0L15 2.25 18.75 6l1.96-1.96z"/><path fillOp...
A component that exports a border color in a block of icons.
import { Trans } from '@lingui/macro'; import PropTypes from 'prop-types'; import React from 'react'; import Requirement from './Requirement'; import Rule from './Rule'; class PreparationRule extends React.PureComponent { static propTypes = { children: PropTypes.node, thresholds: PropTypes.object.isRequired...
Generate a pre - configured checklist rule.
/** * Error Screen * <Error text={'Server is down'} /> * * React Native Starter App * https://github.com/mcnamee/react-native-starter-app */ import React from 'react'; import PropTypes from 'prop-types'; import { View } from 'react-native'; import Icon from 'react-native-vector-icons/Ionicons'; // Consts and...
Error screen for missing missing node - js component
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionWatchLater = (props) => ( <SvgIcon {...props}> <path d="M12 2C6.5 2 2 6.5 2 12s4.5 10 10 10 10-4.5 10-10S17.5 2 12 2zm4.2 14.2L11 13V7h1.5v5.2l4.5 2.7-.8 1.3z"/> </SvgIcon> ); ActionWatchLater = pure(Ac...
ActionWatchLater action watch - later
import React, { Component } from 'react'; import './App.scss'; class App extends Component { constructor (props) { super(props); this.state = this.getInitialState(); } getInitialState () { return {} } render () { return ( <div className="container-...
A component that can be used to create a new app.
'use strict'; import React from 'react'; import ReactDOM from 'react-dom'; var $ = jQuery; function bindCancelClick(editor, settings) { editor.windowManager.windows[0].on('click', function(event){ const clickText = $(event.target).text().toLowerCase(); if (clickText === 'cancel') { ...
UI component that has a modal modal.
/** * Copyright (c) 2015-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ import React, { Component } from 'react'; import PropTypes from 'prop-types'; function* load(limit) { let i = 1; while (i <= limit)...
The base class for a missing - user key.
import { makeStyles } from '@material-ui/core/styles' import React from 'react' import Modal from 'src/components/Modal' import { Button } from 'src/components/buttons' import { Info2, P } from 'src/components/typography' import styles from '../UserManagement.styles' const useStyles = makeStyles(styles) const Chang...
Displays a modal window that opens a FIDO modal and opens a modal to confirm the user s authentication.
import React from 'react'; import PropTypes from 'prop-types'; import createReactNativeComponentClass from 'react-native/Libraries/Renderer/shims/createReactNativeComponentClass.js'; import {PathAttributes} from '../lib/attributes'; import Shape from './Shape'; import {pathProps} from '../lib/props'; import extractProp...
A class that exports a sequence of NgProps and a path to a ReactNativeComponent.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let NotificationAirlineSeatLegroomExtra = (props) => ( <SvgIcon {...props}> <path d="M4 12V3H2v9c0 2.76 2.24 5 5 5h6v-2H7c-1.66 0-3-1.34-3-3zm18.83 5.24c-.38-.72-1.29-.97-2.03-.63l-1.09.5-3.41-6.98c-.34-.68-1.03-1....
A component that exports a sequence of all of the individual components of a sequence of notifications.
/** * Created by Liyazhou on 16/9/6. */ import React from 'react'; import { View, StyleSheet, } from 'react-native'; export default class Toilet extends React.Component { render() { return ( <View></View> ) } } const styles= StyleSheet.create({ })
Create a toilet component that renders a single sequence.
import React from 'react'; import PropTypes from 'prop-types'; type Props = { data: PropTypes.object.isRequired, xScale: PropTypes.func.isRequired, yScale: PropTypes.func.isRequired, colorScale: PropTypes.func.isRequired } export default ({ data, xScale, yScale, colorScale }: Props) => { return ( ...
Default function for returning a object that can be used to render a single missing node.
// @flow import InlineDialog from '@atlaskit/inline-dialog'; import React from 'react'; import { areAudioLevelsEnabled } from '../../../../base/config/functions'; import { getAudioInputDeviceData, getAudioOutputDeviceData, setAudioInputDeviceAndUpdateSettings, setAudioOutputDevice as setAudioOutputDev...
A function that maps parts of a Redux state tree into component props.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let DeviceSignalWifi3BarLock = (props) => ( <SvgIcon {...props}> <path opacity=".3" d="M12 3C5.3 3 .8 6.7.4 7l3.2 3.9L12 21.5l3.5-4.3v-2.6c0-2.2 1.4-4 3.3-4.7.3-.1.5-.2.8-.2.3-.1.6-.1.9-.1.4 0 .7 0 1 .1L23.6 7c-.4-...
Devuelve un signal de l objeto DeviceSignalWifi3BarLock
import React, { Component } from 'react'; import PropTypes from 'prop-types'; // import mpLogo from './../img/MoviePrint_Logo_v002_128.jpg'; // import base64ArrayBuffer from './../utils/base64ArrayBuffer' let temp = []; class ImageComponent extends Component { componentDidMount() { const { store } = this.contex...
A component that renders a single image in a browser - backed fashion.
/** * React Starter Kit (https://www.reactstarterkit.com/) * * Copyright © 2014-2016 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, { Component } from 'react'; // eslint-disabl...
Creates a component that wraps a component in a container that is rendered on the viewport.
//import 'bootstrap/scss/bootstrap.scss' //import 'font-awesome/scss/font-awesome.scss' import 'bootstrap/dist/css/bootstrap.css' import 'font-awesome/css/font-awesome.css' import React from 'react' import ReactDOM from 'react-dom' import { AppContainer } from 'react-hot-loader' import Application from './containers/A...
Imports a single component and renders it in the application.
import React from 'react'; import { connect } from 'dva'; import MyLayout from '../components/MyLayout'; function HomePage({ children }) { return ( <div> <MyLayout> {children} </MyLayout> </div> ); } function mapStateToProps() { return {}; } export default connect(mapStateToProps)...
export default connect
// @flow import React from 'react' import { DateTimePicker } from '@material-ui/pickers' type Props = { value: Date | void, onChange: (string | void) => any } const DateTimeField = ({ value, onChange, ...otherProps }: Props) => { return ( <DateTimePicker fullWidth variant='inline' inputVar...
A component that renders a datepicker with a datepicker when a date is not specified.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let CommunicationChatBubbleOutline = (props) => ( <SvgIcon {...props}> <path d="M20 2H4c-1.1 0-2 .9-2 2v18l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 14H6l-2 2V4h16v12z"/> </SvgIcon> ); CommunicationChatBubbleOutl...
A component that renders a component that displays a communication chat bubble.
import React from 'react'; import store from './store'; import AppConstants from './constants'; import TimerConstants from '../timer/constants'; import Header from '../header/Header'; import Picker from '../picker/Picker'; import Timer from '../timer/Timer'; import Footer from '../footer/Footer'; class App extends Rea...
The base class for the App class.
import React from 'react'; import Analyzer, { SELECTED_PLAYER } from 'parser/core/Analyzer'; import Events from 'parser/core/Events'; import Enemies from 'parser/shared/modules/Enemies'; import calculateEffectiveDamage from 'parser/core/calculateEffectiveDamage'; import SPELLS from 'common/SPELLS'; import SpellLink f...
Create a new Haunt with the given options.
import React from 'react'; import PropTypes from 'prop-types'; import classNames from 'classnames'; import Icon from '@webex/react-component-icon'; import styles from './styles.css'; const propTypes = { accessibilityLabel: PropTypes.string, buttonClassName: PropTypes.string, children: PropTypes.node, iconColo...
A button that can be used to show a node in a tree.
import React from 'react'; import PropTypes from 'prop-types'; import styled from 'styled-components'; import Radio from './Radio'; import { FormattedMessage } from 'react-intl'; import { contains } from 'ramda'; import { InvisibleSpan } from './Invisible'; const Ul = styled.ul` display: flex; flex-flow: row w...
export default component
/** * Sample React Native App * https://github.com/facebook/react-native * @flow */ import React, { Component } from 'react'; import { AppRegistry, StyleSheet, Text, View } from 'react-native'; export default class HelloWorld extends Component { render() { return ( <View style={styles.containe...
Create a component which is not a component of a component type that
import React from 'react'; import IconBase from '@suitejs/icon-base'; function MdCallToAction(props) { return ( <IconBase viewBox="0 0 48 48" {...props}> <path d="M42 6c2.2 0 4 1.8 4 4v28c0 2.2-1.8 4-4 4H6c-2.2 0-4-1.8-4-4V10c0-2.2 1.8-4 4-4h36zm0 32v-6H6v6h36z" /> </IconBase> ); } export default Md...
A function to call to action on a node.
import React from 'react'; import PropTypes from 'prop-types'; import { connect } from 'react-redux'; import { FlatButton } from 'material-ui'; import AppBar from 'material-ui/AppBar'; import styles from './Layout.scss'; import Icon from '../../../icons/icons'; class _Layout extends React.Component { render() { ...
Demonstrates how to render a single missing - node node in a layout.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let PlacesCasino = (props) => ( <SvgIcon {...props}> <path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM7.5 18c-.83 0-1.5-.67-1.5-1.5S6.67 15 7.5 15s1.5.67 1.5 1.5S8.33 18 7.5 18z...
A component that exports a sequence of icons.
/** * Created by luoop on 16-7-14. */ import React from 'react' import {Component} from 'react' import call from '../api' import update from 'immutability-helper'; import {Table, TableBody, TableHeader, TableHeaderColumn, TableRow, TableRowColumn} from 'material-ui/Table'; class OrderDetail extends Component { ...
Component that can be used to show a list of items in a sequence of items.
import React from 'react' import './example.less' import Helmet from 'react-helmet' import { config } from 'config' export default class Less extends React.Component { render () { return ( <div> <Helmet title={`${config.siteTitle} | Hi lessy friends`} /> <h1 cla...
Component that exports a single hierarchical exception.
// // Deprecated // import _ from 'lodash'; import React from 'react'; import { PureRenderMixin } from 'react/addons'; import ContactActionCreators from 'actions/ContactActionCreators'; import DialogActionCreators from 'actions/DialogActionCreators'; import ContactStore from 'stores/ContactStore'; import Modal from...
Component which renders a single contact list.
import React, { Component } from 'react'; import { Provider } from 'react-redux'; import CounterApp from './CounterApp'; import configureStore from '../store/configureStore'; const store = configureStore(); export default class Root extends Component { render() { return ( <Provider store={store}> ...
The root component of a component that is not a React component.
import React from 'react' import { Dropdown } from 'semantic-ui-react' import { countryOptions } from '../common' // countryOptions = [ { value: 'af', flag: 'af', text: 'Afghanistan' }, ... ] const DropdownExampleMultipleSearchSelectionTwo = () => ( <Dropdown placeholder='Select Country' fluid multiple search sele...
Example of multiple search selection on a single node.
import React from 'react'; import RequestList from './RequestList'; import DocumentActions from '../actions/DocumentActions'; import DocumentStore from '../stores/DocumentStore'; export default class Home extends React.Component { constructor() { super(); this.state = { documents: false } } h...
A component that shows a list of documents that can be found in a request.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let DeviceUsb = (props) => ( <SvgIcon {...props}> <path d="M15 7v4h1v2h-3V5h2l-3-4-3 4h2v8H8v-2.07c.7-.37 1.2-1.08 1.2-1.93 0-1.21-.99-2.2-2.2-2.2-1.21 0-2.2.99-2.2 2.2 0 .85.5 1.56 1.2 1.93V13c0 1.11.89 2 2 2h3v3....
Devuelve un objeto DeviceUsb
import React from 'react'; import { connect } from 'react-redux'; import { withRouter } from 'react-router-dom'; import HomeShow from './home_show'; import { fetchHome } from '../../actions/home_actions'; import { openModal } from '../../actions/modal_actions'; import { clearErrors } from '../../actions/session_actio...
Imports a bunch of modules that implement a sequence of functions.
import React, { Component } from 'react'; import { Surface, Sector } from 'recharts'; export default class Demo extends Component { static displayName = 'SectorDemo'; render () { return ( <Surface width={500} height={1000}> <Sector fill="#ff7902" cx={200} cy={200} innerRadius={150} outerRadius=...
Generate a skeleton skeleton with a single component.
import React, { Component } from 'react'; import i18next from 'i18next'; class Message extends Component { constructor(props) { super(props); this.state = { title: props.title, label: props.label, message: props.message } this.closeModal = this.closeModal.bind(this); } compon...
Component that displays a modal dialog with a message.
import React from 'react'; class Home extends React.Component { render() { return ( <div> <h2>Home</h2> <p>Welcome To React Full Stack</p> </div> ); } } export default Home;
A class that exports a single node in a hierarchy.
import React from 'react'; import {View, Text} from 'react-native'; class TabOne extends React.Component { render() { return ( <View> <Text>Tab Two</Text> </View> ); } } export default TabOne;
Imports and exports a single tab one component.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionToday = (props) => ( <SvgIcon {...props}> <path d="M19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11zM7 10h5v5H7z"/> </SvgIcon> ); Ac...
A function to export a missing action from a missing node.
import React from 'react' import { Message } from 'semantic-ui-react' const MessageExampleList = () => ( <Message> <Message.Header>New Site Features</Message.Header> <Message.List> <Message.Item>You can now have cover images on blog pages</Message.Item> <Message.Item>Drafts will now auto-save whi...
This module imports the missing message examples from semantic - ui - react.
import React from 'react'; import WeatherIcon from '../components/WeatherIcon'; import {weatherCodeToColor} from '../util'; const WEEKDAYS = { 0: 'SUN', 1: 'MON', 2: 'TUE', 3: 'WED', 4: 'THU', 5: 'FRI', 6: 'SAT' }; const styles = { forecast: { margin: '0 25px', display: 'flex' }, weekday:...
export default Forecast function
/** * * Login * */ import React from 'react'; import styles from './styles.css'; import validator from 'email-validator'; import classNames from 'classnames'; class Login extends React.Component { // eslint-disable-line react/prefer-stateless-function static propTypes = { login: React.PropTypes.func.isRequired...
A component that can be used to enter a login state.
import React from 'react'; import blacklist from 'blacklist'; var FooterBar = React.createClass({ propTypes: { style: React.PropTypes.object, }, getDefaultProps () { return { style: {}, }; }, getInitialState () { return { position: 'relative', width: 'auto', height: 'auto', top: 0, }; },...
The FooterBar component is a component that wraps the footer in a div and renders it in a wrapper.
import React from 'react'; import jQuery from 'jquery'; import Project from './Project'; import AddProject from './AddProject'; class ProjectBoard extends React.Component { constructor(){ super(); this.state = { projects: [ ] }; } reloadProjectBoard(){ let component = this; ...
The base class for all of the base classes that are used to create a project board.
window.$ = window.jQuery = require("jquery"); window.Tether = require('tether'); require('bootstrap'); require('./scss/index.scss'); import React from 'react'; import ReactDOM from 'react-dom'; import PewView from './components/PewView.jsx'; ReactDOM.render(<PewView />, document.getElementById('root'));
Imports the ReactDOM and PewView.
import React from 'react'; import { HelpBlock, FormGroup, FormControl, Col, } from 'react-bootstrap'; import MaskedInput from 'react-text-mask'; import './styles/PersonalInfoSection.css'; function FieldGroup({ id, label, help, validationState, ...props }) { return ( <FormGroup controlId={id} validationS...
The base class for all non - null
import React from 'react' import ReactDOM from 'react-dom' //import application main component import AppComponent from '../app/components/app_component' class App extends React.Component { render() { return ( <AppComponent /> ) } } //render back to mark-up file ReactDOM.render( ...
The main component of a component that is not marked up in the DOM.
import React from 'react'; import {Route, IndexRoute} from 'react-router'; import Login from 'views/login'; import Signup from 'views/signup'; import Forgot from 'views/forgot'; import Application from 'views/application'; import Logout from 'views/logout'; import MainLanding from 'views/mainLanding'; import Registra...
Imports all routes in the system.
import React from 'react'; import Modal from '../src/Modal'; import Button from '../src/Button'; export default <Modal header='Modal Header' bottomSheet trigger={<Button>MODAL BUTTOM SHEET STYLE</Button>}> Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et do...
Exports a single node of type with a default header.
import React from 'react' import { BASE_URL } from '../globals' function urlize(uri) { return BASE_URL + uri } export default React.createClass({ render() { const logo = this.props.includeLogo ? <a href={BASE_URL} className="brand-logo">NuclearJS</a> : null const homeLink = this.props.includeL...
A component that renders a single missing - node error in a navbar.
import React from 'react'; import { Panel } from 'react-bootstrap'; import ResumeImg from '../assets/Michael_Chamoures_Resume.png'; import ResumeImg2 from '../assets/Michael_Chamoures_Resume_2.png'; import './About.scss'; export const Resume = (props) => ( <Panel header="Resume"> <img alt='' class...
export Resume function
'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; }; function _objectWithoutProperties(obj, keys) {...
Creates a link that links to a route.
import React from 'react'; import PropTypes from 'prop-types'; import { Form, Select} from 'antd'; const FormItem = Form.Item; const Option = Select.Option; const KeywordSelect = (props) => ( <FormItem label="关键字"> {props.getFieldDecorator('keyword')( <Select style={{width: '100%'}} size="default" allowCle...
A component that renders a keyword select for a given component.
/** * 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...
NotFoundPage - The page we show when the user visits a url that doesn t have a route .
import Component from 'components/component'; import React from 'react'; import PropTypes from 'prop-types'; import {dataConnect} from 'relate-js'; import Link from './link'; @dataConnect( (state) => ({ editing: state.pageBuilder && state.pageBuilder.editing }), (props) => { const {link} = props; le...
The base component for a link.
import React from 'react'; import { Route } from 'react-router'; import App from './App'; import SignupRoute from './SignupRoute'; import LoginRoute from './LoginRoute'; import ProfileRoute from './ProfileRoute'; import NotFound from '../components/NotFound'; import redirectBackAfter from '../utils/redirectBackAfter'; ...
This module is exported to provide a convenient way to create a route hierarchy.
import React from 'react' import PropTypes from 'prop-types' import styled from 'styled-components' import ImageWithPlaceholder from './ImageWithPlaceholder' import {truncate} from '../utils/css' const GridCellRoot = styled.a` display: block; overflow: hidden; flex: 1; padding: ${props => props.theme.layout.ga...
A component that wraps a single node in a grid cell.
import React from 'react'; import IconBase from './../components/IconBase/IconBase'; export default class AndroidPeople extends React.Component { render() { if(this.props.bare) { return <g> <path d="M337.454,232c33.599,0,61.092-27.002,61.092-60c0-32.997-27.493-60-61.092-60s-61.09,27.003-61.09,60 C276.364,204.998...
The AndroidPeople class is a class that implements the IANA - specific functionality for the IANA - specific functionality.
import React, { Component } from 'react'; import { reduxForm } from 'redux-form'; import { compose } from 'redux'; import { connect } from 'react-redux'; import FieldGroup from './fieldgroup'; import Recaptcha from 'react-recaptcha'; import { verifyReCaptcha } from '../actions/index'; import _ from 'lodash'; import { ...
The base component that is used to render a single user or password.
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import { connect } from '../../../utils/griddleConnect'; import compose from 'recompose/compose'; import mapProps from 'recompose/mapProps'; import getContext from 'recompose/getContext'; import withHandlers from 'recompose/withHandlers'; co...
A component that wraps a single node in a spacer row.
import React from 'react'; import PropTypes from 'prop-types'; const setColor = (color, led) => () => fetch(`/led/${led}/${color}`); const PlayerControls = (props) =>{ return ( <div className="player-card__controls"> <button onClick={setColor('255/0/0', props.player.ledPosition)} className="pla...
Create a function that displays a dialog with a specific color and led.
import React from 'react' import { render } from 'react-dom' import { BrowserRouter } from 'react-router-dom' import App from './App' import './index.css' render(( <BrowserRouter> <App /> </BrowserRouter> ), document.getElementById('root'))
import react - dom and react - router - dom
import React from 'react'; class About extends React.PureComponent { render() { return <h2>关于</h2> } } export default About;
About component that renders a single component in a hidden state.
import React from 'react'; import _ from 'lodash'; import Options from '../component/Options.js'; import fontAdapt from '../fontAdapter.js'; import styleSvg from '../styleSvg'; var Stock = require('paths-js/stock'); var Axis = require('../component/Axis'); var Path = require('paths-js/path'); export default class Sc...
Very basic component that shows a scatter plot of a series of keys.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let NotificationSimCardAlert = (props) => ( <SvgIcon {...props}> <path d="M18 2h-8L4.02 8 4 20c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-5 15h-2v-2h2v2zm0-4h-2V8h2v5z"/> </SvgIcon> ); NotificationSimCard...
NotificationSimCardAlert - Alerts of a component that is not available in the system.
import React from 'react'; import Button from '../Button'; import styles from './styles.css'; const RandomButton = ({ groupType = 'right', ...otherProps }) => ( <Button {...otherProps} groupType={groupType}> <svg className={styles.svg} width="16px" height="13px" viewBox="0 0 16 13" ...
Generate a random sequence of buttons.
import React, { Component } from 'react'; import { connect } from 'react-redux'; import logout from './../actions/logout'; import { browserHistory } from 'react-router'; import DbTable from './db-table'; import StepBox from './stepBox'; import fetch from 'isomorphic-fetch'; class Profile extends Component { constru...
The profile component which is a component that displays a log - out and a log - in button.
/* * SonarQube * Copyright (C) 2009-2016 SonarSource SA * mailto:contact AT sonarsource DOT com * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; either * version 3 of the License...
Diagram for the n - ary feature.
import React from 'react'; import IconBase from '@suitejs/icon-base'; function MdHourglassEmpty(props) { return ( <IconBase viewBox="0 0 48 48" {...props}> <path d="M12 5h24v10l-9 9 9 9v10H12V33l9-9-9-9V5zm20 29l-8-8-8 8v5h16v-5zm-8-12l8-8V9H16v5l8 8z" /> </IconBase> ); } export default MdHourglassE...
Microformats are not supported in the current browser
import _extends from "@babel/runtime/helpers/extends"; import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties"; import React from 'react'; import PropTypes from 'prop-types'; import clsx from 'clsx'; import withStyles from '../styles/withStyles'; import '../Button'; // So we don't have any...
Dialog actions are rendered as a div with a single child that has a margin left.
import React from 'react' import ReactDOM from 'react-dom' import { AppContainer } from 'react-hot-loader' import { launch } from '@extjs/reactor'; import App from './App' let viewport; const render = (Component, target) => { ReactDOM.render( <AppContainer> <Component/> </AppContainer>...
Imports a single component from a React application.
import React from 'react'; import { connect } from 'react-redux'; import payments from '../selectors/payments'; import Table from './Table'; export const TableMortgage = (({payments, className})=> { let output=payments.slice(1) .filter(year=>year.balance>0 || year.interestYearly>0) .reduce((acc, year, i...
Create a table that contains all the missing missing components in a given state.
import React from 'react' import links from "./../links" import ContentUseCases from "./../../../content/community/ContentUseCases" const UseCaseCard = ({ useCaseItem }) => { return ( <div className="card"> <img className="card-img-top" src={useCaseItem.image} alt={useCaseItem.name} /> ...
export a single node with a single UseCaseCard
import React from 'react' import PropTypes from 'prop-types' import classnames from 'classnames' const Header = ({title, border, children}) => { const className = { 'with-border': border } return ( <div className={classnames('box-header', className)}> {title && <h3 className='box-title'>{title}</h...
Header for
import React from 'react'; import ThemeItem from './ThemeItem'; import Head from './Head' const style = { container: { display: "flex", flex: 1 }, main: { width: "750px" }, side: { flex: 1 } }; export default class Index extends React.Component { constructo...
A component that shows a base 16 viewer on a theme.