code
stringlengths
26
5k
intent
stringlengths
3
2.56k
import React from 'react'; import { Route, IndexRoute } from 'react-router'; import App from './app'; import { HomeView, LoginView, ProtectedView, NotFoundView } from './containers'; import requireAuthentication from './utils/requireAuthentication'; export default( <Route path="/" component={App}> <IndexRo...
export default middleware
'use strict'; import React from 'react'; import restify from 'restify'; import path from 'path'; import Logger from 'bunyan'; import App from '../app/components/App'; const log = new Logger({ src: true, name: 'server', streams: [ { level: Logger.DEBUG, stream: process.stdout } ], serial...
This function is used to serve a single nagios resource.
/* @flow */ import Lozenge from '@atlaskit/lozenge'; import { withStyles } from '@material-ui/core/styles'; import clsx from 'clsx'; import React, { Component } from 'react'; import { Dialog } from '../../base/dialog'; import { translate } from '../../base/i18n'; /** * The type of the React {@code Component} props ...
A component which displays a list of registered keyboard shortcuts.
// @flow import React from 'react' import { hydrate } from 'react-dom' import App from 'app/App' // flow-disable-next-line hydrate(<App data={window.__DATA__} />, document.getElementById('app'))
Imports a bunch of components from a DOM.
import React from 'react'; import { Navbar, Row, Col, Button } from 'react-bootstrap/lib'; import AccountList from '../../../lib/js/react/components/account_list'; import AccountDetail from '../../../lib/js/react/components/account_detail'; import Assets from './assets'; import AssetMatrix from './asset_matrix'; imp...
A component that displays a list of states that can be used to connect to a BigchainDB.
import React, { Component } from 'react'; import {Panel} from '../component'; import {CN, TitleBlock} from '../util/tools'; import CodeView from './CodeView'; export class PanelPage extends Component { render() { return ( <section> {TitleBlock('面板')} <h4>面板</h4>...
Package that exports a single keyboard - based sequence of keyboard - based panels.
import React from 'react' import { List } from 'semantic-ui-react' const ListExampleIconShorthand = () => ( <List> <List.Item icon='users' content='Semantic UI' /> <List.Item icon='marker' content='New York, NY' /> <List.Item icon='mail' content={<a href='mailto:jack@semantic-ui.com'>jack@semantic-ui.com...
Example of how to display a single in a semantic - ui - react system.
import React from 'react'; import {Router, Route} from 'react-router'; import App from './containers/App'; const Routes = (props) => ( <Router {...props}> <Route path="/" component={App}/> <Route path="/:id" component={App}/> </Router> ); export default Routes;
export routes from react - router
import React, { Component } from 'react'; import firebase from 'firebase'; import VideoContent from './VideoContent'; import YouTube from 'react-youtube'; import FlatButton from 'material-ui/FlatButton'; const Broadcast = React.createClass({ getInitialState() { var broadcastId = firebase.auth().currentUser.uid; ...
The main function for all components that are broadcast to a video.
import React from 'react'; import { View, Text } from 'react-native'; import ScrollableTabView from 'react-native-scrollable-tab-view'; import { PRIMARY_COLOR, SECONDARY_COLOR, FOREGROUND_COLOR } from '../styles/constants'; import mainStyles from '../styles/main'; import prStyles from '../styles/pullRequests'; import ...
Imports a single - tab - view with a sequence of non - terminal errors.
import React from 'react'; import {Image} from 'react-native'; var btnsDefault = [ { text: 'Button' } ]; var btnsTypes = [ { text: 'Primary', type: 'primary', }, { text: 'Secondary', type: 'secondary', }, { text: 'Delete', type: 'delete', } ]; var rows = [ { text: "Basic Example", right:...
export default rows
import React from 'react'; import { AsyncStorage, Text, View, TouchableOpacity } from 'react-native'; import Login from '../login'; import Welcome from '../welcome'; import DICT from '../../config/dict'; import styles from '../../styles'; var Loading = React.createClass({ getInitialState() { return { ...
Demonstration of the load - user
/** * * Nav * */ import React from 'react'; import {Link} from 'react-router-dom' import './style.css'; import './styleM.css'; import Bars from 'react-icons/lib/fa/bars'; export default class Nav extends React.PureComponent { constructor () { super(); this.state = { menuOpen:false } } hand...
A base class that displays a menu of jobs and profiles.
import React, { Component } from 'react'; import 'react-mdl/extra/css/material.deep_orange-orange.min.css'; import 'react-mdl-extra/dist/react-mdl-extra.min.css'; import 'normalize.css/normalize.css'; import { NavigationBar, Footer, ImageGallery } from '../components'; import Background from '../assets/main_background....
Component class that extends a single component with no action on it.
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 SPELLS from 'common/SPELLS'; import { formatThousands, formatNumber, formatPercentage } from 'common/format'; import Statis...
A class that exports a channel demonfire.
import _ from 'intl' import React from 'react' import Icon from 'icon' import Tooltip from 'tooltip' import { alert } from 'modal' const showInfo = () => alert( _('licenseRestrictionsModalTitle'), <span> <a href='https://xcp-ng.com/pricing.html#xcpngvsxenserver' rel='noopener noreferrer' target='_blank...
Exports a warning when a node is missing a counter restrictions.
import React from 'react'; import { setItem } from '@src/lib/storage'; class Suspans extends React.Component { constructor(props) { super(props); this.state = { promise: null, }; } /* in order to use this method, it is necessary to comment out node_modules/react-dom/cjs/react-dom.developm...
A component that catches any unhandled error.
import React from 'react' import Gutters from './components/utils/Gutters' import Header from './components/header/Header' import Main from './components/main/Main' import Footer from './components/footer/Footer' const App = () => ( <div> <Gutters> <Header /> <Main /> <Footer /> </Gutters> ...
export default app
import React from 'react'; import './contact.css'; export default function Contact() { return ( <div className='contact-container'> <h1>Booking/Press/General Inquiries</h1> <h3>fayrayband@gmail.com</h3> </div> ); }
Contact component.
import React from 'react'; import BaseEmbed from './base'; class Youtube extends BaseEmbed { constructor(props) { super(props); this.start = null; this.end = null; this.onChange = this.onChange.bind(this); this.renderInput = this.renderInput.bind(this); } onChange (e) { if (e.preventDe...
A component that implements a Youtube video.
import React from 'react'; import { themr } from 'react-css-themr'; import compose from 'recompose/compose'; import { Link } from 'react-router'; import MatchWithProps from './enhancers/MatchWithProps'; import AsyncMatch from './enhancers/AsyncMatch'; import Container from './Container'; import Content from './Content'...
The main function for the module.
import React from 'react'; import PropTypes from 'prop-types'; import Example from './Example'; import Props from './Props'; const ComponentPage = ({component}) => { const {name, description, props, examples} = component; return ( <div className="componentpage"> <h2>{name}</h2> <p>{description}</p...
The default component page for missing components.
import fsp from 'fs-promise'; import path from 'path'; import React from 'react'; import ReactDOMServer from 'react-dom/server'; import {match, RoutingContext} from 'react-router'; import Root from './src/Root'; import routes from './src/Routes'; import metadata from './generate-metadata'; const docsBuilt = path.joi...
Generates HTML for a single page.
import React from 'react'; import Cursor from './cursor'; import Atom from './atom'; const BackgroundContext = React.createClass({ getDefaultProps: function() { return { source: `context.${Date.now()}` }; }, getInitialState: function() { return chrome.extension.getBackgroundPage().background.g...
The default implementation of a node that is a component that can be rendered on a cursor.
import React from 'react'; import Title from 'react-title-component'; import CodeExample from '../../../CodeExample'; import PropTypeDescription from '../../../PropTypeDescription'; import MarkdownElement from '../../../MarkdownElement'; import bottomNavigationReadmeText from './README'; import BottomNavigationExampl...
Imports a single node and exports it as a BottomNavigationPage.
import React from 'react'; import ReactDOM from 'react-dom'; import IconButton from '../../src/IconButton'; import Menu, { MenuItem } from '../../src/Menu'; class Demo extends React.Component { render() { return ( <div style={{width: '300px', margin: 'auto', position: 'relative'}}> ...
Demo component that displays a sequence of possible actions.
import PropTypes from 'prop-types'; import React from 'react'; import PureLayoutComponent from '../utils/pure-layout-component'; const { min, max } = Math; const renderLineNum = num => ( <span className="line-num"> {num < 10 && ' '}{`${num}. `} <style jsx>{` .line-num { opacity: 0.3; } ...
Generates a source code that can be used to render a single missing key sequence.
import React, { Component } from 'react'; import WelcomePage from 'components/WelcomePage'; import GamePage from 'components/GamePage'; import KnowledgeBase from 'components/KnowledgeBase'; import Footer from 'components/Footer'; import 'bulma/css/bulma.css'; const pages = { welcome: <WelcomePage />, game: <Game...
The base component for all of the components that are not part of a component in a layout.
import React from 'react'; import classNames from 'classnames'; import BootstrapMixin from './BootstrapMixin'; import PaginationButton from './PaginationButton'; import CustomPropTypes from './utils/CustomPropTypes'; import SafeAnchor from './SafeAnchor'; const Pagination = React.createClass({ mixins: [BootstrapMixi...
The default implementation of a component which is rendered when a button is selected.
import React from 'react'; import App from './containers/App'; React.render( <App />, document.getElementById('root') );
Renders a into the DOM.
import React from 'react'; import { Navbar, NavDropdown, MenuItem, Nav, NavItem } from 'react-bootstrap'; import { Link } from 'react-router-dom'; import Navmenu from "../../components/navmenu"; import RouteNavItem from "../../components/route-nav-item"; export default class Header extends React.Component { render...
The header class for a sequence of events.
import React from 'react'; class Profile extends React.Component { render () { return ( <div> <h2>Profile</h2> </div> ); } } export default Profile;
Profile is a class that extends the Profile interface.
import React from 'react' import { Step } from './step' const getStepsFromChildren = children => { return React.Children.map(children, child => child.type === Step ? child.props.name || null : null).filter(value => value !== null) } class MultiStepForm extends React.Component { constructor(props) { super(props)...
A component that can be used to create a multi - step form with a step.
import React, { Component } from 'react'; import { Table, TableBody, TableHeader, TableHeaderColumn, TableRow, TableRowColumn, } from 'material-ui/Table'; //redux //store에 연결 import { connect } from 'react-redux'; //action 객체사용 import * as actions from '../../../../../actions/in...
Imports and exports a SampleCheckList.
import React from 'react'; import Icon from '../Icon'; export default class PhoneLockedIcon extends Icon { getSVG(){return <svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" viewBox="0 0 48 48"><path d="M40 31c-2.49 0-4.9-.4-7.14-1.14-.69-.22-1.48-.06-2.03.49l-4.4 4.41c-5.67-2.88-10.29-7.51-13.18-13.17l4...
The default menu for a locked menu.
import './BImagePost.less'; import React from 'react'; // eslint-disable-line no-unused-vars class BImagePost { render() { return ( <div className='b-img-post'> <div className='text-img-content'> <div className='img-post-img'><img src="images/background-example.jpg"/></div> <di...
The default BImagePost class
// @flow import React, { Component } from 'react'; import { Button, Container, Input, InputGroup, InputGroupButton, Form, Collapse, Navbar, NavbarToggler, Nav, NavItem, NavLink } from 'reactstrap'; import FontAwesome from 'react-fontawesome'; import '../styles/filter.scss'; class Filter extends Component { timeoutId...
A basic filter that can be used to filter out items that are not visible on the screen.
import React from 'react' import ItemFactory from './ItemFactory' export default class Shepherd extends React.Component { constructor(props) { super(props) this.state = { itemFactory: new ItemFactory(props.config.items), title: props.config.title, navigation: [], url: null, } this.navigate = thi...
Shepherd component that displays a list of items in the Shepherd tabs.
/** * Copyright (c) 2015-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ import React from 'react'; import tiniestCat from './assets/tiniest-cat.jpg'; export default () => ( <img id="feature-image-inclusion...
Missing feature image inclusion
import React from 'react'; import styles from '../../styles/components/Internship/InternshipTimeline.module.scss'; function InternshipTimeline(props) { const { items } = props; const totalItems = items.length; const numberOfActiveItems = items.filter(item => item.active).length; const progressBarWidth = totalItem...
InternshipTimeline exports a timeline of the given items.
import React from 'react' import { StyleSheet, Text, AppRegistry, View } from 'react-native' import { NativeRouter, Route, Link } from 'react-router-native' // Some folks find value in a centralized route config. // A route config is just data. React is great at mapping // data into components, and <Route> is a compon...
This module is used to create a route config with a centralized route config.
import _ from 'lodash'; import React from 'react'; import {Link} from 'react-router'; import authActions from 'actions/auth'; export default React.createClass({ getInitialState() { return { disabledButtons: { facebook: false, google: true, github...
A default constructor for a single node.
"use strict"; import React from 'react' import Match from './Match' const electron = window.require('electron'); const {ipcRenderer} = electron; export default class Container extends React.Component { constructor(props) { super(props) this.state = { loading: false, error: false, data: {} ...
A component that is rendered when a component is rendered.
import React from 'react'; import reactCookie from 'react-cookie'; import { Provider } from 'react-redux'; import { match, RouterContext, createMemoryHistory } from 'react-router'; import { renderToString } from 'react-dom/server'; import { configure } from 'redux-auth'; import routes from '../../client/routes'; impor...
The rendererController function
import React from 'react'; import Helmet from 'react-helmet'; import Footer from './Footer'; import Nav from './Nav'; export default props => { return ( <div className="wrapper"> <Helmet titleTemplate="Video-React - %s" title="React Video Component" defaultTitle="React Video Compone...
export default props
import React from 'react'; import PropTypes from 'prop-types'; const Alert = props => { const { kind, children, className, ...others } = props; return ( <div className={`alert alert-${kind} ${className || ''}`} {...others}> {children} </div> ); }; Alert.propTypes = { kind: PropTypes.oneOf(['dan...
A component that displays a single alert with a single child.
import React from 'react'; var AppActions = require('../actions/AppActions.react.js'); var AppStore = require('../stores/AppStore.react.js'); var WaitForStore = require('../stores/WaitForStore.react.js'); var GreetingBtn = require('../components/GreetingBtn.react.js'); function getMessage(){ return { ...
function to create a single App object
import React from 'react'; import PropTypes from 'prop-types'; import FlatButton from 'material-ui/FlatButton'; import { getEvents, themedStyle } from 'app/utils'; import style from './style.scss'; import { margin } from './variables.json'; const css = themedStyle(style); const BigButton = props => ( <div classNam...
The default component for a single warning - critical button.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let AvRemoveFromQueue = (props) => ( <SvgIcon {...props}> <path d="M21 3H3c-1.11 0-2 .89-2 2v12c0 1.1.89 2 2 2h5v2h8v-2h5c1.1 0 1.99-.9 1.99-2L23 5c0-1.11-.9-2-2-2zm0 14H3V5h18v12zm-5-7v2H8v-2h8z"/> </SvgIcon> );...
A component that exports a sequence of icons that can be removed from the queue.
import React from 'react'; const TrendHeader = () => { return ( <div className="trend-header"> By <b>Model Year</b> </div> ); }; export default TrendHeader;
export default trend header
import React from 'react'; import ReactDOM from 'react-dom'; //1、for setState() //import App from './jsx/SetStateApp.jsx'; //ReactDOM.render(<App />, document.getElementById('app')) //2、for ForceUpdate //import App from './jsx/PropsApp.jsx'; //import App from './jsx/ForceUpdateApp.jsx'; //ReactDOM.render(<App />, doc...
Imports a bunch of modules that implement the React interface.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ImageExposureNeg2 = (props) => ( <SvgIcon {...props}> <path d="M15.05 16.29l2.86-3.07c.38-.39.72-.79 1.04-1.18.32-.39.59-.78.82-1.17.23-.39.41-.78.54-1.17s.19-.79.19-1.18c0-.53-.09-1.02-.27-1.46-.18-.44-.44-.81...
A component that exports an image exposure.
import dotenv from 'dotenv'; if (process.env.NODE_ENV !== 'production') { dotenv.config(); } if (!process.env.BUNGIE_API_KEY) { console.error("The 'BUNGIE_API_KEY' environment variable has not been set."); process.exit(1); } import Express from 'express'; import React from 'react'; import ReactDOM from 're...
This function imports the application and routes and renders the index. html file.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let HardwareTabletAndroid = (props) => ( <SvgIcon {...props}> <path d="M18 0H6C4.34 0 3 1.34 3 3v18c0 1.66 1.34 3 3 3h12c1.66 0 3-1.34 3-3V3c0-1.66-1.34-3-3-3zm-4 22h-4v-1h4v1zm5.25-3H4.75V3h14.5v16z"/> </SvgIcon...
HardwareTabletAndroid is a lightweight component that can be used to render a hardware tablet Android.
import React from 'react' import warning from 'warning' import invariant from 'invariant' import { createRouteFromReactElement } from './RouteUtils' import { component, components, falsy } from './PropTypes' const { func } = React.PropTypes /** * An <IndexRoute> is used to specify its parent's <Route indexRoute> in ...
Create a new indexRoute object from a React element.
import ReactDOM from 'react-dom'; import React from 'react'; import {build as fetchBuild, buildLog as fetchBuildLog,cancelBuild as cancelBuildApi} from './../api/Api.jsx'; import BuildPage from './../pages/BuildPage.jsx'; import Drawer from './../Drawer.jsx'; import page from 'page'; import {Build as AutoRefreshCompone...
Imports a single node in the DOM.
import React, { Component } from 'react'; import moment from 'moment'; import Message from './message'; import { Nav, NavItem } from 'react-bootstrap'; import axios from 'axios'; // import * as firebase from 'firebase'; // require("firebase/firestore"); const firebase = require("firebase") require("firebase/firestore"...
Component that is a component that can be used to display a message in a chat window.
import Field from '../Field'; import React from 'react'; import { FormRow, FormField, FormInput } from 'elemental'; module.exports = Field.create({ displayName: 'GeopointField', statics: { type: 'Geopoint', }, focusTargetRef: 'lat', handleLat (event) { const { value = [], path, onChange } = this.props; c...
The field that is used to display a single field in a form.
/** @jsx h */ /* eslint-disable react/jsx-key */ import Html from '../..' import React from 'react' import { JSDOM } from 'jsdom' // eslint-disable-line import/no-extraneous-dependencies const html = new Html({ parseHtml: JSDOM.fragment, rules: [ { serialize(obj, children) { switch (obj.object) ...
JSX plugin for reading a single from a DOM.
/* * React.js Starter Kit * Copyright (c) 2014 Konstantin Tarkus (@koistya), KriaSoft LLC. * * This source code is licensed under the MIT license found in the * LICENSE.txt file in the root directory of this source tree. */ 'use strict'; import React, { Component } from 'react'; import { canUseDOM } from 'react...
The main function for the main application of the application.
import React from 'react' import { Button } from 'semantic-ui-react' const ButtonExampleGroupColored = () => ( <Button.Group color='blue'> <Button>One</Button> <Button>Two</Button> <Button>Three</Button> </Button.Group> ) export default ButtonExampleGroupColored
Example group of buttons that are not part of a group of buttons.
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) { var target = {...
Link component that renders a link when a key is pressed on the right of a page.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionAccountBox = (props) => ( <SvgIcon {...props}> <path d="M3 5v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2H5c-1.11 0-2 .9-2 2zm12 4c0 1.66-1.34 3-3 3s-3-1.34-3-3 1.34-3 3-3 3 1.34 3 3zm-9 8c0-2 4-3...
A component that exports a sequence of action - account boxes.
import React from 'react'; import './index.scss'; import TwitterLogo from './twitter.svg'; import FacebookLogo from './facebook.svg'; import MusicTalent from './musictalent.png'; const Footer = ({ translate }) => ( <section className="Footer" id="Contactar"> <div className="Footer-column"> <h2 className="...
Package that contains a sequence of missing records.
import React from 'react'; import EntypoIcon from '../EntypoIcon'; const iconClass = 'entypo-svgicon entypo--Battery'; let EntypoBattery = (props) => ( <EntypoIcon propClass={iconClass} {...props}> <path d="M15.408,10c0-2.766,1.277-4.32,2.277-4.32c0.363,0,1.315,0,1.315,0C18.332,4.621,17.779,4,15.342,4H5.3...
A component that displays a battery on the top of a component.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let EditorStrikethroughS = (props) => ( <SvgIcon {...props}> <path d="M7.24 8.75c-.26-.48-.39-1.03-.39-1.67 0-.61.13-1.16.4-1.67.26-.5.63-.93 1.11-1.29.48-.35 1.05-.63 1.7-.83.66-.19 1.39-.29 2.18-.29.81 0 1.54.11 ...
A component that
import PropTypes from 'prop-types'; import React from 'react'; const someProps = { active: PropTypes.boolean }; function Example() { return <div />; } Example.propTypes = { ...someProps, children: PropTypes.node, className: PropTypes.string }; export default Example;
Provides a javascript interface to the component.
import React from 'react' import {Div} from 'glamorous' import DailyCalendar from '../../src/components/daily' import Navigation from '../../src/components/navigation' import HoursLabels from '../../src/components/hoursLabels' import { Container, HourLabel, CalendarContainer, Cell, DayLabel, Event, Date...
Imports a single from React
import React from 'react'; import _ from 'lodash'; const mode = { 'bin' : 2, 'oct' : 8, 'dec' : 10, 'hex' : 16 }; export default class ReplOutputInteger extends React.Component { constructor(props) { super(props); this.state = { mode: 'dec', type: 'signed', collapse: 'true' }; ...
A component that renders a single negative integer in a mode group.
var $ = require('jquery'); import React from 'react'; import ReactDOM from 'react-dom'; import Backbone from 'backbone'; import todoModel from 'pages/todoReact/todoModel'; import TodoItemView from 'pages/todoReact/todoView'; import dispatcher from 'pages/todoReact/todoDispatcher'; // Controller View var TodoListView ...
The TodoListView is a component that renders the todo list.
/** * 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'; import s from '....
Provides a function to render a single missing - node component in a browser.
import React from 'react'; import styled, { ThemeProvider } from 'styled-components'; import NoSsr from '@material-ui/core/NoSsr'; import { style, typography } from '@material-ui/system'; const variant = style({ prop: 'variant', cssProperty: false, themeKey: 'typography', }); // ⚠ Text is already defined in the...
export default function for missing missing - states -
/** * Created by onvelocity on 4/8/17. */ import React from 'react' import PropTypes from 'prop-types' import './Choice.css' const choice = ({text, removeChoice}) => { return ( <li className="Choice"> <span>{text}</span> <button onClick={() => removeChoice()}>&#10005;</button> </li> ); }; choice.default...
The default choice for a
/** * 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 Layout from '../../co...
Provides a function to create a new component in the hierarchy of the current application.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ContentInbox = (props) => ( <SvgIcon {...props}> <path d="M19 3H4.99c-1.11 0-1.98.89-1.98 2L3 19c0 1.1.88 2 1.99 2H19c1.1 0 2-.9 2-2V5c0-1.11-.9-2-2-2zm0 12h-4c0 1.66-1.35 3-3 3s-3-1.34-3-3H4.99V5H19v10z"/> <...
A component that exports a single node in a hierarchy.
import React from 'react'; import ReactDOM from 'react-dom'; import App from './App'; import './index.css'; ReactDOM.render( <App />, document.getElementById('root') );
Imports a single node in the DOM.
import React from 'react'; import {Router, Route, IndexRoute, Redirect, hashHistory} from 'react-router'; import {DashApp, Home, Pages, Config, User} from 'dashboard/containers'; import {Dne} from 'containers'; const routes = <Router history={hashHistory}> <Route path="/" component={DashApp}> <IndexRoute compo...
Imports a bunch of routes from the system.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ImageImage = (props) => ( <SvgIcon {...props}> <path d="M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z"/> </SvgIcon> ); ImageImage = p...
A component that renders a component that can be used to render a component in a layout.
import React from 'react'; import {Link} from 'react-router'; export default class CompactBill extends React.Component { render() { const data = this.props.data; const amount = `$${data.amount}`; const link = this.calculateLink(data); return ( <div className="bill compa...
A component that renders a single sequence of conditions.
// Polyfill needed by ie 11 import 'string.prototype.startswith'; // ie 10 import 'location-origin'; import 'font-awesome/css/font-awesome.css'; import 'react-bootstrap-table/dist/react-bootstrap-table-all.min.css'; import React from 'react'; import ReactDOM from 'react-dom'; import { BrowserRouter as Router } from '...
Imports a single node in the DOM.
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let AvLoop = (props) => ( <SvgIcon {...props}> <path d="M12 4V1L8 5l4 4V6c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46C19.54 15.03 20 13.57 20 12c0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-1.01.25-1.97.7-2....
A component that exports a sequence of React - like objects.
/** * Created by muratguney on 03/04/2017. */ import React from 'react'; import classnames from 'classnames' import '../index.scss' class Table extends React.Component{ render(){ return( <table className="rmd-table" style={{width:"100%"}}> {this.props.children} </...
Demonstration of a single naze in a table.
import React from 'react'; import createSvgIcon from './utils/createSvgIcon'; export default createSvgIcon( <g><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9H9V9h10v2zm-4 4H9v-2h6v2zm4-8H9V5h10v2z" /></g> , 'LibraryBooks');
Create a series of icons for a single element.
// @flow import React from 'react'; class MyComponent extends React.Component { props: Props; state: State = {}; defaultProps: T; static props: T; static state: T; a: T; b = 5; c: T = 5; method() {} } const expression = () => class extends React.Component { props: Props; state: State = {...
A component that is not part of a critical state.
import PropTypes from 'prop-types'; import React, { Component } from 'react'; import { spring, TransitionMotion } from 'react-motion'; const DEFAULT_SPRINT_CONFIG = { stiffness: 250, damping: 25 }; export default class Roll extends Component { static propTypes = { children: PropTypes.any, width: PropTypes.s...
A Roll component that displays a single child in a roll.
/** * 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 from 'react'; import Login from './Login'; c...
Provides a function to export a single node in the system that is not part of the main React application.
import React from 'react' // eslint-disable-line no-unused-vars import * as d3 from 'd3' import { TimeGraph } from '../src' import { action } from '@storybook/addon-actions' const mock = require('./_mock.json') const display = d3.timeFormat('%a %Y-%m-%d %H:00') const formatter = d3.timeFormat('%Y-%m-%d %H') export ...
The default implementation of NotFound
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import { connect } from 'react-redux'; import styles from '../../main.css'; import grid from '../../grid.css'; import { getServerTime } from '../App/AppReducer'; import numeral from 'numeral'; import cuid from 'cuid'; class Home extends Comp...
Component that is a component that can be used to render a single critical sequence.
import React, { Component } from 'react'; import { connect } from 'react-redux'; import { Button } from 'react-bootstrap'; import { updateProfile, changeAvatar, getProfile } from '../../actions/user/profile'; class Avatar extends Component { constructor() { super(); this.state = {}; } loadImage() { ...
The default component for a user - avatar.
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.
import React, { Component } from 'react'; import { connect } from 'react-redux'; import Snip from './snip'; export default class Layout extends Component { render() { return ( <div> <header className="c-box c-box--dark"> <a className="c-box--dark" href="/"><strong>React Redux Pages Demo</strong></a> ...
React layout for missing missing items
import React from 'react'; import { connect } from 'react-redux'; import PropTypes from 'prop-types'; import { injectIntl, FormattedMessage } from 'react-intl'; import { makeGetAccount } from '../../../selectors'; import Button from '../../../components/button'; import { closeModal } from '../../../actions/modal'; impo...
A component that displays a modal dialog with a block of confirmation.
/* * Copyright (C) 2016 - 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...
Component that renders a single missing - missing key sequence with a hidden state.
import React from 'react'; import { BannerRow, H2, Button } from '@appbaseio/designkit'; import PropTypes from 'prop-types'; import { css } from 'react-emotion'; import { SecondaryLink } from '../styles'; const style = css` p { color: #ffffff; font-weight: 300; } `; const button = { fontSize: '14px', lineHeigh...
Imports a single missing - node node with a BannerRow H2 Button and a SecondaryLink.
// @flow weak import React from 'react'; import PropTypes from 'prop-types'; import { withStyles } from 'material-ui/styles'; import ButtonBase from 'material-ui/ButtonBase'; import Typography from 'material-ui/Typography'; import breakfastImage from 'docs/src/assets/images/grid-list/breakfast.jpg'; import burgersImag...
A component that creates a weak weak link between buttons and buttons.
import React, { Component } from 'react'; import './assets/css/base.min.css'; //components import Header from './components/header/header'; import Home from './components/pages/home/homepage'; class App extends Component { render() { return ( <div className="App"> <Header /> <Home /> ...
The main app class.
// This file is required by the index.html file and will // be executed in the renderer process for that window. // All of the Node.js APIs are available in this process. import React from 'react'; import ReactDOM from 'react-dom'; import MainView from '../views/MainView.jsx'; window.onload = () => { ReactDOM.rend...
This file is required by the index. html file and will be executed in the renderer process.
import React from 'react' import ComponentExample from 'docs/app/Components/ComponentDoc/ComponentExample' import ExampleSection from 'docs/app/Components/ComponentDoc/ExampleSection' const HeaderContentExamples = () => ( <ExampleSection title='Content'> <ComponentExample title='Image' description='A...
HeaderContentExamples - > Header content examples
/** * Copyright IBM Corp. 2016, 2018 * * 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 Checkbox from '../../Checkbox'; import DataTable, { Table, TableBody, TableCell, TableContainer, ...
Exports a single node with a
import React from 'react'; import ReactDOM from 'react-dom'; import SolrConnector from '../src/react-solr-connector'; import SolrConnectorDemo from './demo.js'; class App extends React.Component { constructor(props) { super(props); this.state = { searchParams: null } } doSearch(searchParams) ...
The base class for a sequence of components that can be rendered in a demo window.