path
stringlengths
5
296
repo_name
stringlengths
5
85
content
stringlengths
25
1.05M
src/components/icon/icons/index.js
quark-ui/quark-ui
import React from 'react'; import account from './account.svg'; import arrowDown from './arrow-down.svg'; import arrowLeft from './arrow-left.svg'; import arrowRight from './arrow-right.svg'; import arrowUp from './arrow-up.svg'; import attachment from './attachment.svg'; import car from './car.svg'; import caution fro...
app/javascript/mastodon/components/column_back_button_slim.js
pointlessone/mastodon
import React from 'react'; import { FormattedMessage } from 'react-intl'; import ColumnBackButton from './column_back_button'; export default class ColumnBackButtonSlim extends ColumnBackButton { render () { return ( <div className='column-back-button--slim'> <div role='button' tabIndex='0' onClic...
src/components/TextArea/TextArea.Skeleton.js
wfp/ui
/* eslint-disable jsx-a11y/label-has-for */ /* eslint-disable jsx-a11y/label-has-associated-control */ import PropTypes from 'prop-types'; import React from 'react'; const TextAreaSkeleton = ({ hideLabel, id }) => { const label = hideLabel ? null : ( <label className="wfp--label wfp--skeleton" htmlFor={id} /> ...
src/components/dashboards/Upload.js
DarwinSmith/tentara-pelajar-client
import React from 'react' import FineUploaderS3 from 'fine-uploader-wrappers/s3' import Gallery from 'react-fine-uploader' const profilePicUrl = '' const uploader = new FineUploaderS3({ options: { request: { endpoint: "https://s3-us-west-2.amazonaws.com/uploader-tentara-pelajar/", accessKey: "AKIAIZ...
src/layouts/index.js
linosorice/personal-website
import React from 'react' import Header from '../components/header' import styles from './styles.module.css' import '../css/reset.css' import '../css/document.css' import '../css/typography.css' const Layout = ({ children, location }) => { // Need to pass in location here on build. On development the props come fr...
packages/mui-codemod/src/v5.0.0/jss-to-styled.test/sixth.actual.js
oliviertassinari/material-ui
import React from 'react'; import PropTypes from 'prop-types'; import clsx from 'clsx'; import IconButton from '@material-ui/core/IconButton'; import Badge from '@material-ui/core/Badge'; import { connect } from 'react-redux'; import withStyles from '@material-ui/styles/withStyles'; import ShoppingCartIcon from '@mater...
react/Card/Card.demo.js
seek-oss/seek-style-guide
import React from 'react'; import PropTypes from 'prop-types'; import { Card, Text, PageBlock, Section } from 'seek-style-guide/react'; const CardContainer = ({ component: DemoComponent, componentProps }) => ( <PageBlock> <Section> <DemoComponent {...componentProps} /> </Section> </PageBlock> ); Card...
packages/ringcentral-widgets/components/VoicemailPlayer/index.js
u9520107/ringcentral-js-widget
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import classnames from 'classnames'; import formatDuration from '../../lib/formatDuration'; import DownloadIcon from '../../assets/images/Download.svg'; import PlayIcon from '../../assets/images/Play.svg'; import PauseIcon from '../../assets...
frontend/src/components/controls/StarRating.js
technoboom/it-academy
import React from 'react'; import { Rating } from 'semantic-ui-react'; /** * Star rating * Defines rating bar with stars * The stars are selectable. */ export default class StarRating extends React.Component { render() { return ( <div className="star-rating"> <Rating maxRati...
src/svg-icons/communication/call-missed.js
ruifortes/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let CommunicationCallMissed = (props) => ( <SvgIcon {...props}> <path d="M19.59 7L12 14.59 6.41 9H11V7H3v8h2v-4.59l7 7 9-9z"/> </SvgIcon> ); CommunicationCallMissed = pure(CommunicationCallMissed); CommunicationC...
src/components/Inspector/Files/FileRow.js
Secretmapper/react-transmission
import React from 'react'; import CSSModules from 'react-css-modules'; import FileList from './FileList'; import PriorityButton from './PriorityButton'; import WantedButton from './WantedButton'; import styles from './styles/index.css'; function FileRow({ name, node, setPriority, setWanted }) { const { priority, f...
src/components/common/icons/Minus.js
chejen/GoodJobShare
import React from 'react'; /* eslint-disable */ const Minus = (props) => ( <svg {...props} width="148" height="148" viewBox="0 0 148 148"> <polygon points="0 .778 148 .778 148 17.222 0 17.222" transform="translate(0 65)"/> </svg> ); /* eslint-enable */ export default Minus;
pnpm-cached/.pnpm-store/1/registry.npmjs.org/react-bootstrap/0.31.0/es/CarouselCaption.js
JamieMason/npm-cache-benchmark
import _extends from 'babel-runtime/helpers/extends'; import _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties'; import _classCallCheck from 'babel-runtime/helpers/classCallCheck'; import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn'; import _inherits from ...
20170525/zhihu/src/App5.js
fengnovo/react-native
import React, { Component } from 'react'; import { WebView } from 'react-native'; class App extends Component { render() { return ( <WebView source={{uri: 'https://github.com/facebook/react-native'}} style={{marginTop: 20}} /> ); } } export default App;
src/scenes/home/team/team.js
OperationCode/operationcode_frontend
import React, { Component } from 'react'; import axios from 'axios'; import config from 'config/environment'; import Section from 'shared/components/section/section'; import QuoteBanner from 'shared/components/quoteBanner/quoteBanner'; import TeamCard from 'shared/components/teamCard/teamCard'; import styles from './te...
TestDemos/examples/LessonExamples/IIID-News/Components/NewsDetail.js
AzenXu/ReactNativeTest
/** * Created by Azen on 16/9/5. */ import React, { Component } from 'react'; import { View, Text, Image, NavigatorIOS, StyleSheet } from 'react-native' var Detail = React.createClass({ render() { return( <View style={styles.container}> </View...
frontend/js/components/environments/NewUserForm.js
ttavenner/okcandidate-platform
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import Card from './../atoms/Card'; class NewUserForm extends Component { render() { return ( <section className="container"> <Card> <pre>New User</pre> <form action="/api/v1/user" ...
docs/app/Examples/collections/Form/Types/index.js
clemensw/stardust
import React from 'react' import ExampleSection from 'docs/app/Components/ComponentDoc/ExampleSection' import ComponentExample from 'docs/app/Components/ComponentDoc/ComponentExample' import { Message, Icon } from 'src' const FormTypesExamples = () => ( <ExampleSection title='Types'> <ComponentExample tit...
src/docs/Docs.js
coryhouse/ps-react
import React from 'react'; import Navigation from './Navigation'; import ComponentPage from './ComponentPage'; import componentData from '../../config/componentData'; export default class Docs extends React.Component { constructor(props) { super(props); this.state = { route: window.location.hash.substr...
lib/SGListView.js
sghiassy/react-native-sglistview
import React from 'react'; import PropTypes from 'prop-types'; import createReactClass from 'create-react-class'; import { ListView, ScrollView, Platform } from 'react-native'; import SGListViewCell from './SGListViewCell'; /** * Some methods are stored here. The benefit of doing so are: * 1. The methods are truly p...
src/routes.js
TonyJen/react-redux-universal-hot-example
import React from 'react'; import {IndexRoute, Route} from 'react-router'; import { isLoaded as isAuthLoaded, load as loadAuth } from 'redux/modules/auth'; import { App, Chat, Home, Experiment, Widgets, About, Hello, Login, LoginSuccess, Survey, NotFound, } from 'containers...
src/modals/EncounterOptionsModal.js
emfmesquita/beyondhelp
import { Button, FormControl, FormGroup, Glyphicon, InputGroup, ListGroup, ListGroupItem } from 'react-bootstrap'; import React, { Component } from 'react'; import BhModal from "./BhModal"; import C from "../Constants"; import ColorPicker from "../forms/ColorPicker"; import DiceExp from "../services/DiceExp"; import F...
config/flow/definitions/react.js
nicksp/redux-webpack-es6-boilerplate
/* @flow */ // Note: we already have the definitions from // https://github.com/facebook/flow/blob/master/lib/react.js // so the below are merely helpful extensions import React from 'react'; declare type $React$Element = React.Element<*>; declare type $React$Node = string | number | $React$Element | Array<$React$E...
docs/src/components/Hero.js
oyvindhermansen/easy-state
import React from 'react'; import styled from 'styled-components'; import { PrimaryButton, ExternalSecondaryButton } from './Common'; const StyledHero = styled.div` display: flex; justify-content: center; align-items: center; padding: 4rem 0; text-align: center; /* Permalink - use to edit and share this g...
assets/jqwidgets/demos/react/app/input/defaultfunctionality/app.js
juannelisalde/holter
import React from 'react'; import ReactDOM from 'react-dom'; import JqxInput from '../../../jqwidgets-react/react_jqxinput.js'; class App extends React.Component { render() { let countries = new Array('Afghanistan', 'Albania', 'Algeria', 'Andorra', 'Angola', 'Antarctica', 'Antigua and Barbuda', 'Argentina...
src/containers/Member.js
TeodorKolev/Help
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import { connect } from 'react-redux'; import { logout, getMemberData } from '../actions/member'; class Member extends Component { static propTypes = { Layout: PropTypes.func.isRequired, memberLogout: PropTypes.func.isRequired, ...
client/components/Header.js
glenrage/another-chance
import React from 'react'; import { Link } from 'react-router'; import { connect } from 'react-redux'; const LoggedOutView = props => { if (!props.currentUser) { return ( <ul className="nav navbar-nav navbar-right"> <li className="nav-item"> <Link to="/" className="nav-link"> ...
src/components/Score/Score.js
gxoptg/Colr
import React from 'react'; import { connect } from 'react-redux'; import styles from './Score.css'; const DumbScore = ({ children, isVisible }) => <div className={isVisible ? styles.scoreVisible : styles.scoreInvisible}> {children} </div>; DumbScore.propTypes = { children: React.PropTypes.node.is...
client/src/app.js
SivanMehta/chatroom
// React import React from 'react' import { render } from 'react-dom' import { Router, Route, Link, hashHistory, IndexRoute } from 'react-router' // Material UI import injectTapEventPlugin from 'react-tap-event-plugin'; injectTapEventPlugin() import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider' import Ap...
test/PanelSpec.js
PeterDaveHello/react-bootstrap
import React from 'react'; import ReactTestUtils from 'react/lib/ReactTestUtils'; import Panel from '../src/Panel'; import Table from '../src/Table'; describe('Panel', function () { it('Should have class and body', function () { let instance = ReactTestUtils.renderIntoDocument( <Panel>Panel content</Panel>...
src/pages/projects.js
jameslutley/jameslutley.com
import React from 'react' import Link from 'gatsby-link' const ProjectsPage = () => ( <div> <h1>Projects</h1> <p>Welcome to projects page</p> <Link to="/">Go back to the homepage</Link> </div> ) export default ProjectsPage
src/containers/Statistics.js
kennethaa/vanvikil-live
import React, { Component } from 'react'; class Statistics extends Component { render() { return ( <div> {'Stats'} </div> ); } } export default Statistics;
packages/native/src/components/screens/budget/BudgetScreen.js
hwaterke/inab
import React from 'react' import {View} from 'react-native' import {globalStyles} from '../../../constants/styles' import {Banner} from '../../Banner' import {MonthSelector} from './MonthSelector' import {BudgetList} from './BudgetList' import {BudgetHeader} from './BudgetHeader' export class BudgetScreen extends Reac...
app/views/anonymous/views/ProjectDetails/ProjectProperties/index.js
AamuLumi/IdeaBox
'use strict'; import React, { Component } from 'react'; export default class ProjectProperties extends Component { static propTypes = { project: React.PropTypes.object.isRequired } render() { if (this.props.project.isPrivate){ return ( <div className="projectProperties"> <h4>Pro...
client/index.js
mdixon47/freecodecamp
import Rx from 'rx'; import React from 'react'; import { Router } from 'react-router'; import { history } from 'react-router/lib/BrowserHistory'; import debugFactory from 'debug'; import { hydrate } from 'thundercats'; import { Render } from 'thundercats-react'; import { app$ } from '../common/app'; const debug = deb...
src/components/Html.js
keenethics/estimateit
/** * React Starter Kit (https://www.reactstarterkit.com/) * * Copyright © 2014-present Kriasoft, LLC. All rights reserved. * * This source code is licensed under the MIT license found in the * LICENSE.txt file in the root directory of this source tree. */ import React from 'react'; import PropTypes from 'prop-...
src/routes.js
AmmarCloudtech/Simple-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'; import PostsShow from './components/posts_show'; export default ( <Route path="/" component={App} > <...
MyApp/__tests__/index.android.js
liwei0505/react-native
import 'react-native'; import React from 'react'; import Index from '../index.android.js'; // Note: test renderer must be required after react-native. import renderer from 'react-test-renderer'; it('renders correctly', () => { const tree = renderer.create( <Index /> ); });
src/gm3/components/catalog/tools/up.js
geomoose/gm3
/* * The MIT License (MIT) * * Copyright (c) 2016-2017 Dan "Ducky" Little * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights...
front/app/app/rh-components/rh-Pagination.js
nudoru/React-Starter-2-app
import React from 'react'; import {fillIntArray} from '../utils/Toolbox'; const Pagination = ({ prev = false, next = true, start = 1, end = 5, current = 1 }) => { let numbers = fillIntArray(start, end); prev = prev ? ( <a href="#"><i className="fa fa-step-backward"/></a>) : ( <span classNam...
src/PageItem.js
justinanastos/react-bootstrap
import React from 'react'; import classNames from 'classnames'; import SafeAnchor from './SafeAnchor'; const PageItem = React.createClass({ propTypes: { href: React.PropTypes.string, target: React.PropTypes.string, title: React.PropTypes.string, disabled: React.PropTypes.bool, previous: React.Pr...
client/admin/info/RocketChatSection.js
Sing-Li/Rocket.Chat
import { Skeleton } from '@rocket.chat/fuselage'; import React from 'react'; import Subtitle from '../../components/basic/Subtitle'; import { useTranslation } from '../../contexts/TranslationContext'; import { useFormatDateAndTime } from '../../hooks/useFormatDateAndTime'; import { useFormatDuration } from '../../hook...
example/normal(react)/client/static/js/index.wp.js
dnxbf321/npx
import React from 'react' import ReactDom from 'react-dom' import App from './app.jsx' console.log('client = ', client, typeof client) console.log('client.publicPath = ', client.publicPath) console.log('debug = ' + debug, typeof debug) console.log('array1 = ', array1) let arr = [1, 2, 3] let copyArr = [...arr] consol...
examples-react/app/components/tables.js
zcoding/dashboard
import React from 'react' export default class Tables extends React.Component { constructor(props) { super(props) } render() { return ( <div className="grid padding"> <div className="u-sm-8"> <div className="panel panel-primary"> <div className="panel-header">Table i...
frontend/app/components/Repairs/CommentView.js
sabbir044/AutoRepair
import React from 'react'; import PropTypes from 'prop-types'; import { Button, Modal, FormGroup, FormControl, ControlLabel, Panel } from 'react-bootstrap'; export default function CommentView(props) { return ( <Modal show={props.showModal} onHide={props.onModalHide} bsSize="large"> <Modal.Header closeButt...
example/examples/ZIndexMarkers.js
ali-alamine/react-native-maps
import React from 'react'; import { Dimensions, StyleSheet, Text, View, } from 'react-native'; import MapView from 'react-native-maps'; const { width, height } = Dimensions.get('window'); const ASPECT_RATIO = width / height; const LATITUDE = 37.733858; const LONGITUDE = -122.446549; const MARKERS_LATITUDE_DE...
packages/react-scripts/fixtures/kitchensink/src/features/webpack/ImageInclusion.js
bttf/create-react-app
/** * Copyright (c) 2015-present, Facebook, Inc. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. An additional grant * of patent rights can be found in the PATENTS file in the same directory. */ import Rea...
packages/idyll-template-projects/templates/multipage/template/components/custom-d3-component.js
idyll-lang/idyll
import React from 'react'; import D3Component from 'idyll-d3-component'; import * as d3 from 'd3'; const size = 600; class CustomD3Component extends D3Component { initialize(node, props) { const svg = (this.svg = d3.select(node).append('svg')); svg .attr('viewBox', `0 0 ${size} ${size}`) .style(...
source/server/head.js
Pro-YY/universal-web-kit
import React from 'react' import ReactDOM from 'react-dom/server' import Helmet from 'react-helmet' export function initHead(args) { const { title, description, style, script } = args // NOTE: server rendered css will be removed and changed by client after ssr, see client.js let helmet = ReactDOM.renderToString(...
fields/types/location/LocationFilter.js
Ftonso/keystone
import React from 'react'; import { FormField, FormInput, FormRow, SegmentedControl } from 'elemental'; const TOGGLE_OPTIONS = [ { label: 'Matches', value: false }, { label: 'Does NOT Match', value: true }, ]; function getDefaultValue () { return { inverted: TOGGLE_OPTIONS[0].value, street: undefined, city:...
app/src/index.js
DaveGee/words
import React from 'react' import ReactDOM from 'react-dom' import App from './App' import './index.css' ReactDOM.render( <App />, document.getElementById('root') )
src/views/NotFoundView/NotFoundView.js
aredmon/new-plotting-dashboard
import React from 'react'; import { Link } from 'react-router'; export class NotFoundView extends React.Component { render () { return ( <div className='container text-center'> <h1>Aw Snap!</h1> <p>Something went wrong...where were you trying to go?</p> <hr /> <Link to='/'>B...
ajax/libs/react-instantsearch/5.0.1/Dom.js
sashberd/cdnjs
/*! ReactInstantSearch 5.0.1 | © Algolia, inc. | https://community.algolia.com/react-instantsearch */ (function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('react')) : typeof define === 'function' && define.amd ? define(['exports', 'react'], factory) : ...
src/components/organisms/PostForm/index.stories.js
DimensionLab/narc
import React from 'react' import { storiesOf } from '@storybook/react' import { PostForm } from 'containers' storiesOf('PostForm', module) .add('default', () => ( <PostForm /> ))
packages/cf-component-modal/src/ModalClose.js
mdno/mdno.github.io
import React from 'react'; import PropTypes from 'prop-types'; import Icon from 'cf-component-icon'; class ModalClose extends React.Component { render() { return ( <span className="cf-modal__close" onClick={this.props.onClick}> <Icon type="close" label={this.props.label} size="2x" /> </span> ...
Study/Udemy Docker and Kubernetes/Section05/frontend/src/components/UI/Card.js
tarsoqueiroz/Docker
import React from 'react'; import './Card.css'; function Card(props) { return <div className='card'>{props.children}</div>; } export default Card;
actor-apps/app-web/src/app/components/modals/Contacts.react.js
liruqi/actor-platform
// // 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...
app/components/FoodCell.js
EleTeam/Shop-React-Native
/** * ShopReactNative * * @author Tony Wong * @date 2016-08-13 * @email 908601756@qq.com * @copyright Copyright © 2016 EleTeam * @license The MIT License (MIT) */ import React from 'react'; import { StyleSheet, TouchableOpacity, View, Text, Image, } from 'react-native'; import Common from ...
versions/2-react/2-variable/client/src/index.js
hamczu/techsummit-web2016
import React from 'react' import { render } from 'react-dom' import App from './App' render(<App/>, document.getElementById('root'))
web_client/src/index.js
nikGayko/Messenger
import React from 'react'; import ReactDOM from 'react-dom'; import './styles/index.css'; import App from './components/App.jsx'; import * as firebase from 'firebase'; //inintial firebase config var config = { apiKey: "AIzaSyA-6uja5L0oGUza6K4JIG14Pq57Ak9GNZA", authDomain: "messenger-7b700.firebaseapp.com", ...
fields/types/date/DateColumn.js
lojack/keystone
import React from 'react'; import moment from 'moment'; import ItemsTableCell from '../../../admin/src/components/ItemsTableCell'; import ItemsTableValue from '../../../admin/src/components/ItemsTableValue'; var DateColumn = React.createClass({ displayName: 'DateColumn', propTypes: { col: React.PropTypes.object, ...
src/svg-icons/image/gradient.js
spiermar/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ImageGradient = (props) => ( <SvgIcon {...props}> <path d="M11 9h2v2h-2zm-2 2h2v2H9zm4 0h2v2h-2zm2-2h2v2h-2zM7 9h2v2H7zm12-6H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 18H7v-2h2v2z...
webapp/app/components/MigrationHistory/Create/index.js
EIP-SAM/SAM-Solution-Node-js
// // Migration History Create component // import React from 'react'; import { Modal, Form, Col, Alert, } from 'react-bootstrap'; import StatusSelect from 'containers/MigrationHistory/Create/StatusSelect'; import UserSelect from 'containers/MigrationHistory/Create/UserSelect'; import ImageSelect from 'contain...
test/PanelSpec.js
egauci/react-bootstrap
import React from 'react'; import ReactTestUtils from 'react/lib/ReactTestUtils'; import ReactDOM from 'react-dom'; import Panel from '../src/Panel'; import Table from '../src/Table'; describe('Panel', () => { it('Should have class and body', () => { let instance = ReactTestUtils.renderIntoDocument( <Pane...
examples/huge-apps/routes/Course/components/Dashboard.js
jwaltonmedia/react-router
import React from 'react' class Dashboard extends React.Component { render() { return ( <div> <h3>Course Dashboard</h3> </div> ) } } export default Dashboard
frontend/pages/dashboard/index.js
ecmadao/hacknical
import 'babel-polyfill' import React from 'react' import ReactDOM from 'react-dom' import createHistory from 'history/createBrowserHistory' import AppContainer from './AppContainer' import AppStore from './redux/store' import routes from './routes' const history = createHistory() const renderApp = (id, props = {}) =...
packages/mineral-ui-icons/src/IconColorize.js
mineral-ui/mineral-ui
/* @flow */ import React from 'react'; import Icon from 'mineral-ui/Icon'; import type { IconProps } from 'mineral-ui/Icon/types'; /* eslint-disable prettier/prettier */ export default function IconColorize(props: IconProps) { const iconProps = { rtl: false, ...props }; return ( <Icon {...iconProps...
components/AddTodoForm.js
lipp/next-todos
import React from 'react' export default ({addTodo, setAllCompleted, setAllValue, toggleSetAllValue}) => ( <form action='javascript:' onSubmit={({target: {title}}) => { addTodo(title.value) title.value = '' }} > <input type='checkbox' onClick={() => { setAllCompleted(setAllValue) toggleSetA...
frontend/src/screens/camera-log/camera-log.js
desihub/qlf
import React from 'react'; import PropTypes from 'prop-types'; import Terminal from '../../components/terminal/terminal'; import Paper from '@material-ui/core/Paper'; const styles = { close: { float: 'right', cursor: 'pointer', }, main: { width: 'calc(100vw - 64px)', margin: '16px', padding: ...
src/js/components/ViewMoreViewLess/index.js
grommet/grommet-cms-boilerplate
/* @flow */ import React from 'react'; import Box from 'grommet/components/Box'; import DownIcon from 'grommet/components/icons/base/Down'; import UpIcon from 'grommet/components/icons/base/Up'; import Button from 'grommet/components/Button'; export default function ViewMoreViewLess(props: { children: React$Element<...
spec/javascripts/components/story/story_item_spec.js
Codeminer42/cm42-central
import React from 'react'; import { shallow } from 'enzyme'; import { StoryItem } from 'components/story/StoryItem'; import storyFactory from '../../support/factories/storyFactory'; import ExpandedStory from 'components/story/ExpandedStory'; import CollapsedStory from 'components/story/CollapsedStory'; import moment fr...
assets/js/index.js
mlapierre/Winds
import React from 'react' import { render } from 'react-dom' import { Provider } from 'react-redux' import { syncHistoryWithStore, routerReducer } from 'react-router-redux' import { createStore, combineReducers, applyMiddleware, compose } from 'redux' import { browserHistory, Router, Route, IndexRoute, IndexRedirect } ...
docs/pages/api-docs/toggle-button-group.js
lgollut/material-ui
import React from 'react'; import MarkdownDocs from 'docs/src/modules/components/MarkdownDocs'; import { prepareMarkdown } from 'docs/src/modules/utils/parseMarkdown'; const pageFilename = 'api/toggle-button-group'; const requireRaw = require.context('!raw-loader!./', false, /\/toggle-button-group\.md$/); export defa...
src/modules/components/Select/index.js
ruebel/synth-react-redux
import React from 'react'; import PropTypes from 'prop-types'; import ReactSelect from 'react-select'; import styled from 'styled-components'; import H3 from '../typography/H3'; const Wrapper = styled.div` .Select-arrow { border-width: 8px 6px 1.5px; } .Select-arrow-zone { padding-right: 1.8rem; } ...
src/parser/warlock/destruction/modules/azerite/ChaosShards.js
fyruna/WoWAnalyzer
import React from 'react'; import Analyzer, { SELECTED_PLAYER } from 'parser/core/Analyzer'; import Events from 'parser/core/Events'; import calculateBonusAzeriteDamage from 'parser/core/calculateBonusAzeriteDamage'; import StatTracker from 'parser/shared/modules/StatTracker'; import SPELLS from 'common/SPELLS'; impo...
src/index.js
bgoldman/todomvc-react
import React from 'react'; import { render } from 'react-dom'; import App from './components/app'; render(<App />, document.getElementById('app'));
index.ios.js
tarun29061990/react-native-weather
/** * Sample React Native App * https://github.com/facebook/react-native * @flow */ import React, { Component } from 'react'; import { AppRegistry, StyleSheet, Text, View } from 'react-native'; class weather extends Component { render() { return ( <View style={styles.container}> <Text ...
client/modules/Layouts/AppLayout/__tests__/Components/Footer.spec.js
sharvit/my-blog-react
import React from 'react'; import test from 'ava'; import { shallow } from 'enzyme'; import { Footer } from '../../components/Footer/Footer'; test('renders the footer properly', t => { const wrapper = shallow( <Footer /> ); t.is(wrapper.find('p').length, 1); });
app/components/Cell.js
nihgwu/react-native-sudoku
'use strict'; import React, { Component } from 'react'; import { LayoutAnimation, StyleSheet, Animated, Platform, View, Text, } from 'react-native'; import { CellSize, BorderWidth, } from './GlobalStyle'; import Touchable from './Touchable'; class Cell extends Component { state = { number: thi...
frontend/src/Components/Form/FormGroup.js
Radarr/Radarr
import classNames from 'classnames'; import PropTypes from 'prop-types'; import React from 'react'; import { map } from 'Helpers/elementChildren'; import { sizes } from 'Helpers/Props'; import styles from './FormGroup.css'; function FormGroup(props) { const { className, children, size, advancedSettin...
utils/AnimatedSVGState/index.js
codesinghanoop/react-native-d3multiline-chart
import React, { Component } from 'react'; import omit from 'lodash/omit'; /** * Problem: Some props cannot be animated through setNativeProps * Solution: Use state for those and use setNativeProps for the rest */ function createState(props, keys) { return keys.reduce((acc, key) => { const value = props[key];...
src/svg-icons/social/domain.js
jacklam718/react-svg-iconx
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let SocialDomain = (props) => ( <SvgIcon {...props}> <path d="M12 7V3H2v18h20V7H12zM6 19H4v-2h2v2zm0-4H4v-2h2v2zm0-4H4V9h2v2zm0-4H4V5h2v2zm4 12H8v-2h2v2zm0-4H8v-2h2v2zm0-4H8V9h2v2zm0-4H8V5h2v2zm10 12h-8v-2h2v-2h-2v...
backoffice/src/main.js
sebprunier/necmergitur
import React from 'react'; import ReactDOM from 'react-dom'; import { Router, Route, IndexRoute } from 'react-router'; import createHistory from 'history/lib/createHashHistory'; import HopitauxPage from './pages/hopitaux'; import HopitalPage from './pages/hopital'; import PostesMedicauxAvancesPage from './pages/poste...
src/components/DashboardHome.react.js
danesparza/Dashboard
import React, { Component } from 'react'; import * as Sentry from '@sentry/browser'; // The components import DateTimeDisplay from './DateTimeDisplay.react'; import WeatherDisplay from './WeatherDisplay.react'; import CalendarDisplay from './CalendarDisplay.react'; import NewsDisplay from './NewsDisplay.react'; impor...
src/Parser/Hunter/Shared/Modules/Items/TheApexPredatorsClaw.js
hasseboulen/WoWAnalyzer
import React from 'react'; import ITEMS from 'common/ITEMS'; import SPELLS from 'common/SPELLS'; import PETS from 'common/PETS'; import Analyzer from 'Parser/Core/Analyzer'; import Combatants from 'Parser/Core/Modules/Combatants'; import getDamageBonus from 'Parser/Hunter/Shared/Modules/getDamageBonus'; import CorePet...
app/javascript/mastodon/features/compose/components/upload_button.js
primenumber/mastodon
import React from 'react'; import IconButton from '../../../components/icon_button'; import PropTypes from 'prop-types'; import { defineMessages, injectIntl } from 'react-intl'; import { connect } from 'react-redux'; import ImmutablePureComponent from 'react-immutable-pure-component'; import ImmutablePropTypes from 're...
src/svg-icons/action/find-in-page.js
kasra-co/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ActionFindInPage = (props) => ( <SvgIcon {...props}> <path d="M20 19.59V8l-6-6H6c-1.1 0-1.99.9-1.99 2L4 20c0 1.1.89 2 1.99 2H18c.45 0 .85-.15 1.19-.4l-4.43-4.43c-.8.52-1.74.83-2.76.83-2.76 0-5-2.24-5-5s2.24-5 5...
src/pages/about/articles/index.js
jcmnunes/josenunesxyz
import React from 'react'; import List from '../../../components/List'; import Heading from '../../../styles/Heading'; import articlesData from '../../../content/articles'; const CoursesIndex = () => { return ( <> <Heading> Recent articles I{' '} <span role="img" aria-label="heart-eyes-em...
src/routes/toolJsonEditor/index.js
goldylucks/adamgoldman.me
import React from 'react' import ToolJsonEditor from './ToolJsonEditor' const title = 'Brain Hacking Automation Tools Generator' async function action({ path }) { return { chunks: ['toolEditor'], title, path, description: 'Create a brain tool', component: <ToolJsonEditor />, } } export defau...
src/app/components/icons/GithubIcon.js
skratchdot/web-audio-api-archive
/*eslint max-len:0 */ import React from 'react'; import SvgIcon from 'material-ui/SvgIcon'; const GithubIcon = (props) => ( <SvgIcon {...props} viewBox="0 0 16 16"> <path d="M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59.4.07.55-.17.55-.38 0-.19-.01-.82-.01-1.49-2.01.37-2.53-.49-2.69-.94-.09-.23-.48-.94-.82-1...
scripts/pages/home.js
zupzup/reactgym
'use strict'; import React from 'react'; import List from '../components/List'; import TrainingStore from '../stores/TrainingStore.js'; import SimpleHeaderMixin from '../mixins/SimpleHeaderMixin'; import AppState from '../stores/AppState'; let Home = React.createClass({ contextTypes: { router: React.PropT...
move/src-react/javascripts/index.js
mortzmortz/kolder
import '../styles/styles.scss'; /** * https://github.com/babel/babel/tree/master/packages/babel-preset-env include only the polyfills and * transforms needed for the browsers we specified in kolder.config.js */ import 'babel-polyfill'; import React from 'react'; import ReactDOM from 'react-dom'; import Demo from '...
src/library/tabs/components/Tab.js
zdizzle6717/react-redux-arc
'use strict'; import React from 'react'; export default class Tab extends React.Component { constructor() { super(); this.state = {} } componentDidMount() { // let elem = ReactDOM.findDOMNode(this); // let childForm = elem.getElementsByTagName('form'); // console.log(childForm[0]); } render() { re...
internals/templates/containers/App/index.js
PokerGuy/react-boilerplate
/** * * App.react.js * * This component is the skeleton around the actual pages, and should only * contain code that should be seen on all pages. (e.g. navigation bar) * * NOTE: while this component should technically be a stateless functional * component (SFC), hot reloading does not currently support SFCs. If...
app/javascript/mastodon/features/audio/index.js
Kirishima21/mastodon
import React from 'react'; import PropTypes from 'prop-types'; import { defineMessages, injectIntl } from 'react-intl'; import { formatTime } from 'mastodon/features/video'; import Icon from 'mastodon/components/icon'; import classNames from 'classnames'; import { throttle } from 'lodash'; import { getPointerPosition, ...
client/components/NotFound/NotFound.js
gusaiani/react-moodboard
import React, { Component } from 'react'; class NotFound extends Component { render() { return ( <section> <h2 ref="title">404. Not found.</h2> <p> <img src="http://i.imgur.com/ooWW6.gif" /> </p> <p><a href="/">Go to index</a></p> </section> ); } } exp...
src/Button/Button.js
resmio/mantecao
import React from 'react' import PropTypes from 'prop-types' import styled from 'styled-components' import { darken } from 'polished' import { colors } from '../variables' import { media } from '../utils/style' const getHoverColor = props => { return props.hollow ? props.color : darken(0.1, props.color) } const St...
src/react/native/src/__tests__/App.js
stopbystop/sbs-app
import 'react-native'; import React from 'react'; import App from '../App'; // Note: test renderer must be required after react-native. import renderer from 'react-test-renderer'; it('renders correctly', () => { const tree = renderer.create( <App /> ); });
frontend/src/components/dialog/set-org-user-contact-email.js
miurahr/seahub
import React from 'react'; import PropTypes from 'prop-types'; import { Modal, ModalHeader, ModalBody, ModalFooter } from 'reactstrap'; import { gettext } from '../../utils/constants'; import { seafileAPI } from '../../utils/seafile-api'; import { Utils } from '../../utils/utils'; const propTypes = { orgID: PropType...
app/routes.js
jpsierens/budget
import React from 'react'; import { Route, IndexRoute } from 'react-router'; import App from './components/App'; import BudgetsContainer from './containers/BudgetsContainer'; import About from './components/About'; import BudgetDetailContainer from './containers/BudgetDetailContainer'; export default ( <Route path="/...