path
stringlengths
5
296
repo_name
stringlengths
5
85
content
stringlengths
25
1.05M
src/components/Pager/Pager.js
Grusteam/spark-in-me
import React from 'react'; import cx from 'classnames'; import withStyles from 'isomorphic-style-loader/lib/withStyles'; import s from './Pager.css'; import Link from '../Link'; class Pager extends React.Component { render() { return ( <ul className={cx('pager', s.pager)}> <li className={cx('next', s.pagerNe...
__mocks__/react.js
mic4ael/indico
// This file is part of Indico. // Copyright (C) 2002 - 2020 CERN // // Indico is free software; you can redistribute it and/or // modify it under the terms of the MIT License; see the // LICENSE file for more details. /** * This module mocks some of React's hooks while providing * a way to tap into some of the inte...
test/browser/lists/list-item-spec.js
skarnecki/material-ui
import React from 'react'; import ListItem from 'List/ListItem'; import Checkbox from 'Checkbox'; import injectTheme from '../fixtures/inject-theme'; import TestUtils from 'react-addons-test-utils'; describe('ListItem', () => { let ThemedListItem; beforeEach(() => { ThemedListItem = injectTheme(ListItem); }...
src/routes.js
michaeldumalag/react-blog
import React from 'react'; import { Route, IndexRoute } from 'react-router'; import App from './components/app'; import PostsIndex from './components/posts_index'; import PostsNew from './components/posts_new'; export default ( <Route path="/" component={App}> <IndexRoute component={PostsIndex} /> <Route pa...
src/components/control-bar/PlaybackRateMenuButton.js
video-react/video-react
import PropTypes from 'prop-types'; import React, { Component } from 'react'; import classNames from 'classnames'; import MenuButton from '../menu/MenuButton'; const propTypes = { player: PropTypes.object, actions: PropTypes.object, rates: PropTypes.array, className: PropTypes.string }; const defaultProps = {...
src/components/PokemonViewer/index.js
rodrigo-puente/poke-nostalgia
import React from 'react'; import styles from '../../styles/PokemonViewer'; export const PokemonViewer = ({pokemon, isLoading}) => { return ( <div className="container" style={ styles.container }> <div className="gbScreen" style={ styles.gbScreen }> { isLoading ? ( <div style={ styles....
examples/huge-apps/routes/Course/routes/Announcements/components/Sidebar.js
brandonlilly/react-router
import React from 'react'; import { Link } from 'react-router'; export default class AnnouncementsSidebar extends React.Component { render () { var announcements = COURSES[this.props.params.courseId].announcements; return ( <div> <h3>Sidebar Assignments</h3> <ul> {announcemen...
src/Card/CardHeader.js
skarnecki/material-ui
import React from 'react'; import Avatar from '../Avatar'; function getStyles(props, context) { const {card} = context.muiTheme; return { root: { padding: 16, fontWeight: card.fontWeight, boxSizing: 'border-box', position: 'relative', whiteSpace: 'nowrap', }, text: { ...
app/javascript/src/components/conversations/appPackagePanel.js
michelson/chaskiq
import React from 'react' import FormDialog from '../../components/FormDialog' import Button from '../../components/Button' import Progress from '../../components/Progress' import ErrorBoundary from '../../components/ErrorBoundary' import { connect } from 'react-redux' import graphql from '../../graphql/client' import...
node_modules/rebass/src/SequenceMap.js
HasanSa/hackathon
import React from 'react' import Base from './Base' import SequenceMapStep from './SequenceMapStep' import config from './config' /** * Sequence map pattern for use in multi-step forms */ const SequenceMap = ({ steps, active, children, ...props }, { rebass }) => { const { fontSizes, bold, colors } = { .....
src/helpers/Html.js
hirzanalhakim/testKumparan
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import ReactDOM from 'react-dom/server'; import serialize from 'serialize-javascript'; import Helmet from 'react-helmet'; /** * Wrapper component containing HTML metadata and boilerplate tags. * Used in server-side code only to wrap the st...
app/components/printer/index.js
MakersLab/farm-client
import React from 'react'; import * as Progress from 'react-progressbar.js'; import Dropzone from 'react-dropzone'; import style from './style.css'; import { getUnits, convertMinutesDuration } from '../../lib/utils'; import Link from '../link'; import ProgressBar from '../progressBar'; const ProgressBarLine = Progres...
stories/FadeInView/index.js
Fineighbor/ui-kit
import React from 'react' import createStory from '../../storybook/createStory' import FadeInView from '../../src/FadeInView' import Text from '../../src/Text' createStory('FadeInView', module) .add('default', () => <FadeInView> <Text>Apple</Text> </FadeInView> ) .add('delay:3000', () => <FadeI...
extensions/post/containers/PostContainer.js
axax/lunuc
import React from 'react' import PropTypes from 'prop-types' import compose from 'util/compose' import {connect} from 'react-redux' import Util from 'client/util' import BaseLayout from 'client/components/layout/BaseLayout' import GenericForm from 'client/components/GenericForm' import {Row, Col, Typography, SimpleList...
src/helpers/universalRouter.js
Iced-Tea/react-redux-universal-hot-example
import React from 'react'; import Router from 'react-router'; import createRoutes from '../routes'; import {Provider} from 'react-redux'; const getFetchData = (component = {}) => { return component.WrappedComponent ? getFetchData(component.WrappedComponent) : component.fetchData; }; export function createTr...
src/components/card/Renderer.js
yuri/treillage
import React from 'react'; import marked from 'marked'; import showdown from 'showdown'; import emoji from 'node-emoji'; import PropTypes from 'prop-types'; import { enforceBlockquote, enforceHorizontalRule, replaceWikiLinks } from '../../utils/formatting/markdown'; const renderAsPreview = (markdown) => ( <div ...
docs/app/Examples/collections/Grid/ResponsiveVariations/GridExampleOnly.js
shengnian/shengnian-ui-react
import React from 'react' import { Grid, Segment } from 'shengnian-ui-react' const GridExampleOnly = () => ( <Grid> <Grid.Row columns={2} only='large screen'> <Grid.Column> <Segment>Large Screen</Segment> </Grid.Column> <Grid.Column> <Segment>Large Screen</Segment> </Grid....
app/react-icons/fa/book.js
scampersand/sonos-front
import React from 'react'; import IconBase from 'react-icon-base'; export default class FaBook extends React.Component { render() { return ( <IconBase viewBox="0 0 40 40" {...this.props}> <g><path d="m38.1 10.7q0.9 1.2 0.4 2.9l-6.1 20.2q-0.5 1.4-1.8 2.4t-2.7 0.9h-20.6q-1.7 0-3.3...
packages/react/src/components/DataTable/TableBody.js
carbon-design-system/carbon-components
/** * 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 PropTypes from 'prop-types'; const TableBody = ({ children, className, ...rest }) => ( <tbody className=...
src/parser/ui/ResourceGenerated.js
yajinni/WoWAnalyzer
import React from 'react'; import PropTypes from 'prop-types'; const ResourceGenerated = props => { const { amount, wasted, approximate, resourceType } = props; return ( <> {approximate && '≈'}{amount} {resourceType.name} generated <small>{wasted>0 && <>{approximate && '≈'}{wasted} wasted</>}</sma...
src/svg-icons/device/battery-std.js
manchesergit/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let DeviceBatteryStd = (props) => ( <SvgIcon {...props}> <path d="M15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33v15.33C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V5.33C17 4.6 16.4 4 15.67 4z"/> </SvgIcon> ); D...
app/containers/pages/Cook/index.js
romainquellec/cuistot
import React from 'react'; import CookComp from 'components/pages/Cook'; export default class Cook extends React.Component { render() { return ( <div> <CookComp id={this.props.params.cook} /> </div> ); } }
ui/js/containers/text_input.js
FujiHaruka/shakyo-programming
import React from 'react' import {connect} from 'react-redux' import { nextGameProcess, gameFinish, displayGameFinishWindow } from '../actions' let TextInput = React.createClass({ propTypes: { playing: React.PropTypes.bool, nextKey: React.PropTypes.string, dispatch: React.PropTypes.func, keyArray: Re...
jwt-test/app/components/CustomButton.js
rizip1/JS-projects
import React from 'react'; import { Button } from 'react-bootstrap'; const CustomButton = (props) => { return ( <Button style={buttonStyle} {...props} > {props.children} </Button> ); }; const buttonStyle = { background: '#091B1B', color: '#DDDDDD' }; export default Cust...
src/components/PageDropdown.js
joellanciaux/Griddle
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import _ from 'lodash'; /** Gets a range from a single value. * TODO: Could probably make this take a predicate to avoid running through the loop twice */ const getRange = (number) => { if (!_.isFinite(number)) { return [0] } return Arra...
src/science/index.js
raffidil/garnanain
import React from 'react'; import { Button, CardText, Card, CardTitle, CardMenu, CardActions, IconButton, Grid, Icon, FABButton, Cell } from 'react-mdl'; import db from 'localforage'; import QButton from '../../components/QButton'; import Layout from '../../components/Layout'; import s from './sty...
client/app/ihome/activities/index.js
jl-/r-
import React, { Component } from 'react'; import styles from './style.scss'; class Activities extends Component { render() { return ( <div> activities </div> ); } } export default Activities;
src/components/post/Tags.js
thibmaek/thibmaek.github.io
import React from 'react'; import { array } from 'prop-types'; import Link from 'gatsby-link'; import styles from './Tag.module.css'; const Tags = ({ tags }) => ( <ul className={styles.tagItems}> {tags.map(tag => ( <Link key={tag} to={`/tag/${tag}`}> <li className={styles.tagItem}> {tag....
addons/info/src/index.js
nfl/react-storybook
import React from 'react'; import _Story from './components/Story'; import { H1, H2, H3, H4, H5, H6, Code, P, UL, A, LI } from './components/markdown'; export const Story = _Story; const defaultOptions = { inline: false, header: true, source: true, propTables: [], }; const defaultMarksyConf = { h1: H1, h...
test/integration/hydration/pages/_document.js
flybayer/next.js
import Document, { Head, Html, Main, NextScript } from 'next/document' import React from 'react' class WeddingDocument extends Document { render() { return ( <Html lang="en-GB"> <Head /> <Main /> <NextScript /> </Html> ) } } export default WeddingDocument
src/components/Toolbar/VmsListToolbar.js
mareklibra/userportal
import React from 'react' import PropTypes from 'prop-types' import { List } from 'immutable' import { connect } from 'react-redux' import { saveVmsFilters } from '_/actions' import { msg } from '_/intl' import { RouterPropTypeShapes } from '_/propTypeShapes' import { filterVms, mapFilterValues } from '_/utils' impor...
src/common/components/vanilla/table-interactive/data-link.js
canonical-websites/build.snapcraft.io
import PropTypes from 'prop-types'; import React from 'react'; import { Link } from 'react-router'; import classNames from 'classnames'; import styles from './table.css'; export default function DataLink(props) { const Wrapper = (props.to || props.onClick) ? Link : 'div'; const className = classNames({ [styl...
src/svg-icons/device/battery-60.js
spiermar/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let DeviceBattery60 = (props) => ( <SvgIcon {...props}> <path fillOpacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7 4.6 7 5.33V11h10V5.33z"/><path d="M7 11v9.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 ...
example/examples/ImageOverlayWithURL.js
lelandrichardson/react-native-maps
import React, { Component } from 'react'; import { StyleSheet, View, Dimensions } from 'react-native'; import MapView from 'react-native-maps'; const { width, height } = Dimensions.get('window'); const ASPECT_RATIO = width / height; const LATITUDE = 35.679976; const LONGITUDE = 139.768458; const LATITUDE_DELTA = 0.0...
Libraries/Utilities/throwOnWrongReactAPI.js
Andreyco/react-native
/** * 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. * * @provides...
js/components/casts/index.js
bavuongco10/react-native-school-board
import React from 'react'; import { View, Text, } from 'react-native'; import { List, ListItem, Thumbnail, } from 'native-base'; import { getImageUri } from '../../helpers/function'; export default ({cast}) => ( <View> <List dataArray={cast} renderRow={(item) => <ListItem> ...
docs/src/examples/elements/List/Variations/ListExampleDivided.js
Semantic-Org/Semantic-UI-React
import React from 'react' import { Image, List } from 'semantic-ui-react' const ListExampleDivided = () => ( <List divided verticalAlign='middle'> <List.Item> <Image avatar src='/images/avatar/small/daniel.jpg' /> <List.Content> <List.Header as='a'>Daniel Louise</List.Header> </List.Con...
src/icons/TwitterIcon.js
fathomlondon/fathomlondon.github.io
import React from 'react'; export function TwitterIcon() { return ( <svg viewBox="0 0 512 512" fill="currentColor"> <path d="M419.6 168.6c-11.7 5.2-24.2 8.7-37.4 10.2 13.4-8.1 23.8-20.8 28.6-36-12.6 7.5-26.5 12.9-41.3 15.8C357.6 146 340.7 138 322 138c-42 0-72.9 39.2-63.4 79.9-54.1-2.7-102.1-28.6-134.2-68-17 29.2...
docs/app/Examples/modules/Dropdown/States/Disabled.js
jcarbo/stardust
import React from 'react' import { Dropdown } from 'stardust' const DropdownDisabledExample = () => ( <Dropdown text='Disabled' disabled /> ) export default DropdownDisabledExample
test/commands/generate_test.js
mcmunder/bija
import {expect} from 'chai' import fs from 'fs' import {generate} from '../../dist/commands' import { setupTestApp, teardownTestApp, checkFileOrDirExists } from '../test_helpers' describe('generate command', function () { beforeEach(function () { setupTestApp() }) afterEach(function () { teardown...
client/jest/clientTestUtils.js
flyrightsister/boxcharter
import React from 'react' import { Router } from 'react-router-dom' import { Provider } from 'react-redux'; import { mount } from 'enzyme' import { createMemoryHistory } from 'history' // import { createStore } from 'redux'; // import App from '../src/app/App' import { applyMiddleware, combineReducers, createStore } f...
spec/components/tooltip.js
rubenmoya/react-toolbox
import React from 'react'; import Button from '../../components/button'; import Input from '../../components/input'; import FontIcon from '../../components/font_icon'; import Tooltip, { tooltipFactory } from '../../components/tooltip'; import Chip from '../../components/chip'; import Avatar from '../../components/avata...
docs/src/pages/components/avatars/ImageAvatars.js
lgollut/material-ui
import React from 'react'; import { makeStyles } from '@material-ui/core/styles'; import Avatar from '@material-ui/core/Avatar'; const useStyles = makeStyles((theme) => ({ root: { display: 'flex', '& > *': { margin: theme.spacing(1), }, }, })); export default function ImageAvatars() { const cl...
src/ContentBlocks/BlockTypeMap.js
grommet/grommet-cms-content-blocks
import React from 'react'; import { BlockHeading, BlockHeadingWireframe, BlockParagraph, BlockParagraphWireframe, BlockParagraphForm, BlockParagraphCTA, BlockParagraphCTAWireframe, BlockParagraphCTAForm, BlockParagraphCTAs, BlockParagraphCTAsWireframe, BlockParagraphCTAsForm, BlockImage, Block...
docs/src/sections/IconSection.js
lzcmaro/react-ratchet
import React from 'react'; import Samples from '../Samples' import ReactPlayground from '../ReactPlayground' export default function IconSection() { return ( <div> <ReactPlayground id="ratchicons" title='Ratchicons' desc='字符图标' codeText={Samples.Icon} /> </div> ); };
src/components/common/svg-icons/image/brightness-1.js
abzfarah/Pearson.NAPLAN.GnomeH
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ImageBrightness1 = (props) => ( <SvgIcon {...props}> <circle cx="12" cy="12" r="10"/> </SvgIcon> ); ImageBrightness1 = pure(ImageBrightness1); ImageBrightness1.displayName = 'ImageBrightness1'; ImageBrightnes...
js/widgets/BaseComponent.js
fxdemolisher/newscats
import React from 'react' import ReactMixin from 'react-mixin' import TimerMixin from 'react-timer-mixin' /** * A base react component that all widgets and screens should extend from. * Provides common functionality but most importantly it is a PureComponent and includes the TimerMixin. */ class BaseComponent exten...
services/ui/src/pages/_error.js
amazeeio/lagoon
import React from 'react'; import PropTypes from 'prop-types'; import Head from 'next-server/head'; import StatusLayout from 'layouts/StatusLayout'; const statusCodes = { 400: 'Bad Request', 401: 'Not Authenticated', 404: 'This page could not be found', 500: 'Internal Server Error', 501: 'Not Implemented' };...
src/components/UIInputAutocompleteElement.js
oglimmer/linky
import React from 'react'; import PropTypes from 'prop-types'; import { ControlLabel, Col } from 'react-bootstrap'; import { actions } from 'react-redux-form'; import { connect } from 'react-redux'; import ReactTags from 'react-tag-autocomplete'; import ImmutablePropTypes from 'react-immutable-proptypes'; import Immut...
webapp/src/routes/rest/detail/index.js
templatetools/trace
import React from 'react' import PropTypes from 'prop-types' import { connect } from 'dva' import styles from './index.less' const Detail = ({ userDetail }) => { const { data } = userDetail const content = [] for (let key in data) { if ({}.hasOwnProperty.call(data, key)) { content.push(<div key={key} c...
src/Parser/Paladin/Holy/Modules/Features/MasteryEffectiveness.js
enragednuke/WoWAnalyzer
import React from 'react'; import SPELLS from 'common/SPELLS'; import { formatPercentage } from 'common/format'; import Analyzer from 'Parser/Core/Analyzer'; import Combatants from 'Parser/Core/Modules/Combatants'; import StatisticBox, { STATISTIC_ORDER } from 'Main/StatisticBox'; import MasteryRadiusImage from 'Mai...
src/components/feed/posts/photo.js
alexcurtis/react-fbpage
'use strict'; import React from 'react'; class PhotoPost extends React.Component { constructor(props){ super(props); } render(){ return ( <div> <img src={this.props.full_picture} style={this.props.style.image} ...
src/routes/chart/barChart/index.js
vincentdd/crm
import React from 'react' import PropTypes from 'prop-types' import { Row, Col, Card, Button } from 'antd' import { BarChart, Bar, XAxis, YAxis, CartesianGrid, Tooltip, Legend, } from 'recharts' import Container from '../Container' const data = [ { name: 'Page A', uv: 4000, pv: 2400, am...
actor-apps/app-web/src/app/components/ToolbarSection.react.js
v2tmobile/actor-platform
import React from 'react'; import ReactMixin from 'react-mixin'; import { IntlMixin } from 'react-intl'; import classnames from 'classnames'; import ActivityActionCreators from 'actions/ActivityActionCreators'; import DialogStore from 'stores/DialogStore'; import ActivityStore from 'stores/ActivityStore'; //import A...
src/universalRouter.js
sebas5384/react-redux-universal-hot-example
import React from 'react'; import Router from 'react-router'; import createRoutes from './views/createRoutes'; import { Provider } from 'react-redux'; const getFetchData = (component={}) => { return component.WrappedComponent ? getFetchData(component.WrappedComponent) : component.fetchData; }; export functi...
example/src/index.js
houseofstylist/react-native-snap-carousel
import React, { Component } from 'react'; import { Platform, View, ScrollView, Text, StatusBar, SafeAreaView } from 'react-native'; import LinearGradient from 'react-native-linear-gradient'; import Carousel, { Pagination } from 'react-native-snap-carousel'; import { sliderWidth, itemWidth } from 'example/src/styles/Sli...
src/svg-icons/editor/border-outer.js
skarnecki/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let EditorBorderOuter = (props) => ( <SvgIcon {...props}> <path d="M13 7h-2v2h2V7zm0 4h-2v2h2v-2zm4 0h-2v2h2v-2zM3 3v18h18V3H3zm16 16H5V5h14v14zm-6-4h-2v2h2v-2zm-4-4H7v2h2v-2z"/> </SvgIcon> ); EditorBorderOuter =...
app/src/main/js/components/MainScreen/ConversationList/Conversation List.js
evan01/tranasaurus
import React, { Component } from 'react'; import ContactField from './Contact Field/ContactField'; // todo render a table of contact Fields, to select class ConversationList extends Component { render() { return ( <div className='ConversationList'> <h1>List</h1> <ContactField /> </di...
src/containers/Routes.js
drakang4/creative-project-manager
import React from 'react'; import { Switch, Route, Redirect } from 'react-router-dom'; import App from '../pages/App'; import Login from '../pages/Login'; const Routes = () => { return ( <Switch> <Route path="/login" component={Login} /> <Route path="/" component={App} /> </Switch> ); }; expor...
test/specs/cartesian/AreaSpec.js
scostaqb/recharts
import React from 'react'; import { expect } from 'chai'; import { Surface, Area } from 'recharts'; import { mount, render } from 'enzyme'; describe('<Area />', () => { const data = [ { x: 10, y: 50, value: 100 }, { x: 50, y: 50, value: 100 }, { x: 90, y: 50, value: 100 }, { x: 130, y: 50, value: 100...
webApp/web_client/components/StreamLiveViewLinkbar.js
deliquescentlicorice/silent-disco
import React from 'react'; class StreamLiveViewLinkbar extends React.Component { render() { var linkBar = this.props.website ? ( <div><a href={this.props.website || this.props.soundcloud} style={styles.link}>{this.props.broadcaster}</a> </div> ) : ( <div><a href={this.props.soundcloud} style={sty...
src/client/student/PrintStudentSchedules.js
jmicmoore/merit-badge-university
import _ from 'lodash'; import React from 'react'; import {connect} from 'react-redux'; import {Link} from 'react-router-dom'; import {Table} from 'react-bootstrap'; import FontAwesome from 'react-fontawesome'; import update from 'immutability-helper'; import {getStudents} from './studentActions'; import pdf from '../c...
JS/components/TaskList.js
letsspeak/Stock
import React from 'react' import PropTypes from 'prop-types' import Task from './Task' const TaskList = ({ tasks, onTaskClick }) => ( <ul> {tasks.map((task) => <Task key={task.id} {...task} onClick={() => onTaskClick(task.id)} /> )} </ul> ) TaskList.propTypes = { task...
src/parser/mage/arcane/modules/Checklist/Component.js
fyruna/WoWAnalyzer
import React from 'react'; import PropTypes from 'prop-types'; import ITEMS from 'common/ITEMS'; import SPELLS from 'common/SPELLS'; import SpellLink from 'common/SpellLink'; import Checklist from 'parser/shared/modules/features/Checklist'; import Rule from 'parser/shared/modules/features/Checklist/Rule'; import Requir...
src/browser/todos/NewTodo.js
redcom/doctori-romani-in-berlin
// @flow import React from 'react'; import newTodoMessages from '../../common/todos/newTodoMessages'; import { Form } from '../components'; import { Text, TextInput } from '../../common/components'; import { addTodo } from '../../common/todos/actions'; import { compose } from 'ramda'; import { connect } from 'react-red...
.client/utils/index.js
okmttdhr/meteor-react-redux-boilerplate
import React from 'react'; import ReactDOM from 'react-dom'; import { Provider } from 'react-redux'; import DevTools from 'dir_src/containers/DevToolsWindow'; export function createConstants (...constants) { return constants.reduce((acc, constant) => { acc[constant] = constant; return acc; }, {}); } expor...
src/svg-icons/places/spa.js
nathanmarks/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let PlacesSpa = (props) => ( <SvgIcon {...props}> <path d="M8.55 12c-1.07-.71-2.25-1.27-3.53-1.61 1.28.34 2.46.9 3.53 1.61zm10.43-1.61c-1.29.34-2.49.91-3.57 1.64 1.08-.73 2.28-1.3 3.57-1.64z"/><path d="M15.49 9.63c...
src/Components/Chart.js
vinniejames/coinfox
import React, { Component } from 'react'; import Highcharts from 'highcharts' // import './Chart.css'; class Chart extends Component { constructor (props) { super(props); this.state = { ticker: null, chart: { Response: "no", Data: [] }, time_series: [] } } _c...
packages/react-scripts/fixtures/kitchensink/src/index.js
amido/create-react-app
/** * Copyright (c) 2015-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ import React from 'react'; import ReactDOM from 'react-dom'; import App from './App'; ReactDOM.render(<App />, document.getElementById(...
Tests/Components/AlertMessageTest.js
Ezeebube5/Nairasense
import 'react-native' import React from 'react' import AlertMessage from '../../App/Components/AlertMessage' import renderer from 'react-test-renderer' test('AlertMessage component renders correctly if show is true', () => { const tree = renderer.create(<AlertMessage title='howdy' />).toJSON() expect(tree).toMatch...
src/client/pages/popular-repositories/PopularRepositories.js
developersdo/opensource
import React from 'react' import DocumentTitle from 'react-document-title' import { orderBy, each } from 'lodash' import store from '~/store/store' import Loading from '~/components/loading/Loading' import RepositoryList from '~/components/repository-list/RepositoryList' /** * The PopularRepositories class object lis...
client/modules/App/__tests__/Components/Header.spec.js
zivkaziv/MazorTech
import React from 'react'; import test from 'ava'; import sinon from 'sinon'; import { shallow } from 'enzyme'; import { FormattedMessage } from 'react-intl'; import { Header } from '../../components/Header/Header'; import { intl } from '../../../../util/react-intl-test-helper'; const intlProp = { ...intl, enabledLang...
tests/routes/Counter/components/Counter.spec.js
alukach/react-map-app
import React from 'react' import { bindActionCreators } from 'redux' import { Counter } from 'routes/Counter/components/Counter' import { shallow } from 'enzyme' describe('(Component) Counter', () => { let _props, _spies, _wrapper beforeEach(() => { _spies = {} _props = { counter : 5, ...bindA...
src/components/onboarding/steps/Print.js
golemfactory/golem-electron
import React from 'react'; import Lottie from 'react-lottie'; import animData from './../../../assets/anims/onboarding/printer.json' const defaultOptions = { loop: false, autoplay: true, animationData: animData, rendererSettings: { preserveAspectRatio: 'xMidYMid slice' } }; export defaul...
client/pages/UploadProgressPage.js
freakimkaefig/melodicsimilarity
import React from 'react'; import AuthenticatedComponent from '../components/AuthenticatedComponent'; import DocumentTitle from 'react-document-title'; import { APP_NAME } from '../constants/AppConstants'; import ResultList from '../components/Upload/UploadProgressList'; import UploadStore from '../stores/UploadStore';...
example/app/components/Example.js
chenckang/webpack-php-mock
import React from 'react'; import connectToStores from 'alt/utils/connectToStores'; import DummyStore from 'stores/DummyStore'; import DummyActions from 'actions/DummyActions'; @connectToStores class Example extends React.Component { constructor(props) { super(props); this.state = { nam...
src/scenes/teeBox.js
Andrey11/golfmanager
'use strict'; import React, { Component } from 'react'; import { AppRegistry, ActivityIndicator, Text, View, ScrollView, Image, InteractionManager, Picker, TouchableHighlight, StyleSheet } from 'react-native'; import HoleItem from '../components/holeItem'; import HoleItemFull from '../components/ho...
src/components/vis/OrderedWordCloud.js
mitmedialab/MediaCloud-Web-Tools
import PropTypes from 'prop-types'; import React from 'react'; import * as d3 from 'd3'; import { injectIntl, FormattedMessage } from 'react-intl'; import fontSizeComputer from '../../lib/visUtil'; const localMessages = { wordCloudCount: { id: 'wordcloud.rollover.count', defaultMessage: 'Uses: {count}' }, wordClou...
client/routes.js
jchai002/acrostix
import React from 'react'; import { Route, IndexRoute } from 'react-router' import PuzzlesList from './components/puzzlesList'; import NewPuzzlePage from './components/puzzleBuilder/newPuzzlePage'; import PuzzleBuilder from './components/puzzleBuilder/builder'; import App from './components/app' export default ( <Rou...
frontend/app/js/containers/login.js
serverboards/serverboards
import React from 'react'; import rpc from 'app/rpc' import Flash from 'app/flash' import LoginView from 'app/components/login' import {login} from 'app/actions/auth' import { connect } from 'react-redux' var Login = connect( (state) => ({ lang_counter: state.auth.lang_counter, logging: state.auth.logging ...
client/src/Components/GeneralData.js
teamcrux/EmploymentOptions
import React from 'react'; const GeneralData = (props) => { return ( <div> <h3> General </h3> <p> Employment Availablity: {props.user.date_avail} </p> <p> Worked for Military: {props.user.military} </p> <p> Any Misdemeanors: {props.user.misdemeanor} </p> </div> ) } export default (...
platforms/browser/index.js
chenshuxian/ReactProject
import React from 'react' import ReactDOM from 'react-dom' import routes from '../../app/routes' import { Provider } from 'react-redux' import configureStore from '../../app/store/configureStore' const store = configureStore(window.__REDUX_STATE__) ReactDOM.render( <Provider store={store}> {routes} </Provider>...
src/addons/dragAndDrop/backgroundWrapper.js
elationemr/react-big-calendar
import PropTypes from 'prop-types'; import React from 'react' import { DropTarget } from 'react-dnd' import cn from 'classnames'; import dates from '../../utils/dates'; import BigCalendar from '../../index' export function getEventTimes({ start, end }, dropDate, type) { // Calculate duration between original start ...
src/js/components/SearchInput/index.js
waagsociety/ams.datahub.client
import React from 'react' import handlers from './events' export default function SearchInput({ props }) { const { route, view } = props.store const { SearchInput, FilterGroup } = view const { value } = SearchInput const { focus } = FilterGroup const { storeFocus, fetchQuery, fetchSuggestions, clearInput...
test/noVelocity-test.js
danieldunderfelt/react-motion
import noVelocity from '../src/noVelocity'; import React from 'react'; describe('noVelocity', () => { it('should return true on 0s', () => { expect(noVelocity({a: [0, 0, {b: 0}]})).toBe(true); }); it('should return true on collections of 0s with non-numerical vals', () => { const comp = <div />; exp...
components/SearchField/SearchField.js
websiddu/reactable
import React, { Component } from 'react'; import './SearchField.scss'; class SearchField extends Component { constructor(...props) { super(...props); this.onChange = this.onChange.bind(this); } onChange(e) { this.props.onChange(e.target.value); } render() { return ( <div className="...
docs/app/Examples/collections/Message/Types/MessageExampleMessageProps.js
mohammed88/Semantic-UI-React
import React from 'react' import { Message } from 'semantic-ui-react' const MessageExampleMessageProps = () => ( <Message header='Changes in Service' content='We updated our privacy policy here to better service our customers. We recommend reviewing the changes.' /> ) export default MessageExampleMessageP...
client/pc/src/views/AdminLayout.js
CongYunan/course_attendance
// 加载 React 相关组件 import React, { Component } from 'react'; // 加载 AntD 相关组件 import { Menu, Icon } from 'antd'; // 加载自定义组件 import Header from '../components/Header'; import Content from '../components/Content'; // 加载自定义组件 各类管理面板 import CourseAdmin from '../components/Admin/CourseAdmin'; import CollegeAdmin from '../compo...
packages/ringcentral-widgets-docs/src/app/pages/Components/FormattedMessage/index.js
ringcentral/ringcentral-js-widget
import React from 'react'; import { parse } from 'react-docgen'; import CodeExample from '../../../components/CodeExample'; import ComponentHeader from '../../../components/ComponentHeader'; import PropTypeDescription from '../../../components/PropTypeDescription'; import Demo from './Demo'; // eslint-disable-next-lin...
imaginarySet/src/App.js
HJBowers/imaginary-shrew
import React, { Component } from 'react'; import './App.css'; import Board from './board' export default class App extends Component { render () { return ( <Board /> ) } }
submissions/jas-chen/src/component/timeTravel.js
gterzian/flux-challenge
import { Observable, Subject } from 'rx'; import React from 'react'; import { dom } from 'react-reactive-class'; const { div: Div, input: Input, button: Button } = dom; function btnSubject() { const subject$ = new Subject(); const onNext = subject$.onNext.bind(subject$); const click$ = subject$.map((e) => e.tar...
src/esm/components/graphics/icons/loudspeaker-icon/index.js
KissKissBankBank/kitten
import _extends from "@babel/runtime/helpers/extends"; import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/objectWithoutPropertiesLoose"; var _excluded = ["color", "title"]; import React from 'react'; import PropTypes from 'prop-types'; export var LoudspeakerIcon = function LoudspeakerIcon(_ref) { var c...
packages/slate-html-serializer/src/index.js
6174/slate
import React from 'react' import ReactDOMServer from 'react-dom/server' import logger from 'slate-dev-logger' import typeOf from 'type-of' import { Node, State } from 'slate' import { Record } from 'immutable' /** * String. * * @type {String} */ const String = new Record({ kind: 'string', text: '' }) /** *...
Paths/React/05.Building Scalable React Apps/8-react-boilerplate-building-scalable-apps-m8-exercise-files/After/app/app.js
phiratio/Pluralsight-materials
/** * app.js * * This is the entry file for the application, only setup and boilerplate * code. */ import 'babel-polyfill'; /* eslint-disable import/no-unresolved */ // Load the manifest.json file and the .htaccess file import '!file?name=[name].[ext]!./manifest.json'; import 'file?name=[name].[ext]!./.htaccess';...
src/modules/Counter1/View-web/index.js
diegovargasg/reactjstest
import React from 'react' import _ from 'lodash' // ================================ view.js =========================================== const CounterView = ({ count = 0, increase = _.noop, decrease = _.noop }) => ( <div className="input-group"> <div className="input-group-btn"> <button classN...
src/components/LoadingPlaceholder.js
googleinterns/step236-2020
/** * Copyright 2020 Google LLC * * 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...
src/components/List.js
feliciakuo/layoutList
/** * List table */ import React from 'react' import ListBody from './../containers/ListBody' const List = () => ( <div> <table> <thead> <tr> <td>TPL</td> <td>Name</td> <td>dev link</td> <td>master link</td> <td>ver</td> <td>bulider</td> ...
packages/substyle-jss/test/StylesViaJss.spec.js
jfschwarz/substyle
import { mount } from 'enzyme' import React from 'react' import useStyles from 'substyle' import { StylesViaJss } from '../src' import createPropsDecorator from '../src/createPropsDecorator' jest.mock('css-jss', () => ({ create: () => (styles) => Buffer.from(JSON.stringify(styles)).toString('base64'), })) jest...
stories/Avatar.js
abouthiroppy/scuba
import React from 'react'; import { storiesOf } from '@kadira/storybook'; import Container, { Avatar } from '../src'; storiesOf('Avatar', module).add('list', () => ( <div style={{ padding: 30 }}> <Container theme="sea"> <Avatar src="https://avatars2.githubusercontent.com/u/3367801?v=3&s=400" ...
src/views/CodeGen/paramsModal.js
chad-ding/koala
/** *@Author: chad.ding *@Date: 2017-06-21 18:12:28 */ import React, { Component } from 'react'; import { connect } from 'react-redux'; import { Form, Modal, Select, Input } from 'antd'; import { handleModal } from './action'; class ParamsForm extends Component { constructor(props) { super(props); ...