path
stringlengths
5
296
repo_name
stringlengths
5
85
content
stringlengths
25
1.05M
docs/src/pages/StartPage.js
gocreating/react-tocas
import React from 'react'; import PageLayout from '../utils/PageLayout'; import CodeBlock from '../utils/CodeBlock'; import { Segment, Header, } from '../../../lib'; import 'codemirror/mode/htmlmixed/htmlmixed'; import 'codemirror/mode/jsx/jsx'; import 'codemirror/theme/solarized.css'; let JSX_DEMO = `import Butto...
scr-app/src/redux/devtools/showDevTools.js
tlatoza/SeeCodeRun
import React from 'react'; import {render} from 'react-dom'; import DevTools from './DevTools'; /** * Renders Redux Dev tools * @param {Object} store - the Redux store to be debugged. * @return {number} - The timeout id in case of cancellation. */ export default function showDevTools(store) { return setTimeout((...
src/components/containers/article-container.js
mberneti/ReactAdmin
import React from 'react'; import { connect } from 'react-redux'; import Article from '../views/article'; import store from '../../store'; import { loadDashboardCompleted } from '../../actions/dashboard-actions'; import { resetArticleModel } from '../../actions/article-actions'; import * as articleApi from '../../api/a...
test/react/ModalFooter.spec.js
onap-sdc/sdc-ui
import React from 'react'; import ModalFooter from '../../src/react/ModalFooter.js'; import renderer from 'react-test-renderer'; describe('ModalFooter', () => { test('basic test', () => { const footer = renderer.create(<ModalFooter closeButtonText='Ok'/>).toJSON(); expect(footer).toMatchSnapshot(); }); ...
examples/react-redux-example/test/todomvc/components/Footer.spec.js
demones/react-guide
import expect from 'expect' import React from 'react' import TestUtils from 'react-addons-test-utils' import Footer from '../../../app/todomvc/components/Footer' import { SHOW_ALL, SHOW_ACTIVE } from '../../../app/todomvc/constants/TodoFilters' function setup(propOverrides) { const props = Object.assign({ comple...
webapp/src/App.js
gcallah/Indra
import React from 'react'; import { HashRouter, Route, Switch } from 'react-router-dom'; import styled, { withTheme } from 'styled-components'; import Layout from './components/Layout'; import Home from './components/Home'; import WIP from './components/WIP'; import ModelDetail from './components/ModelDetail'; import A...
src/svg-icons/notification/wc.js
ruifortes/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let NotificationWc = (props) => ( <SvgIcon {...props}> <path d="M5.5 22v-7.5H4V9c0-1.1.9-2 2-2h3c1.1 0 2 .9 2 2v5.5H9.5V22h-4zM18 22v-6h3l-2.54-7.63C18.18 7.55 17.42 7 16.56 7h-.12c-.86 0-1.63.55-1.9 1.37L12 16h3v6...
src/components/footer.js
jennywin/donate-for-good
import React, { Component } from 'react'; export default class Footer extends Component { render() { return ( <footer className="footer"> </footer> ); } }
app/components/TabContainer/index.js
JSSolutions/Perfi
import React from 'react'; import T from 'prop-types'; import { StyleSheet, View } from 'react-native'; const s = StyleSheet.create({ container: { position: 'absolute', top: 0, bottom: 0, }, show: { left: 0, right: 0, }, hide: { left: 90000, // over the screen, right: -90000, // o...
app/main.js
wvicioso/dapr
import React, { Component } from 'react'; import { Navigator, StyleSheet, Text, TextInput, ScrollView, TouchableOpacity, View, Image, ListView, LayoutAnimation } from 'react-native'; const Carousel = require('react-native-carousel'); const SideMenu = require('react-native-side-menu'); import Day fr...
client/src/containers/CategoryPage/CategoryDetail/index.js
steThera/react-mobx-koa
import React, { Component } from 'react'; import { observer, inject } from 'mobx-react'; import { SlideLeftTransition } from 'components/RouteTransition'; import { mode } from 'components/FormMobx/utils'; import { getCategory, updateCategory } from '../DetailForm/actions'; import DetailForm from '../DetailForm'; cla...
src/icons/BlurOffIcon.js
kiloe/ui
import React from 'react'; import Icon from '../Icon'; export default class BlurOffIcon extends Icon { getSVG(){return <svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" viewBox="0 0 48 48"><path d="M28 14c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm-.4 8.96c.13.02.26.04.4.04 1.66 0 3-1.34 3-3s-1.34-3-3-...
src/svg-icons/image/crop-7-5.js
verdan/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ImageCrop75 = (props) => ( <SvgIcon {...props}> <path d="M19 7H5c-1.1 0-2 .9-2 2v6c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V9c0-1.1-.9-2-2-2zm0 8H5V9h14v6z"/> </SvgIcon> ); ImageCrop75 = pure(ImageCrop75); ImageCrop75...
js/components/loaders/ProgressBar.android.js
phamngoclinh/PetOnline_vs2
/* @flow */ import React from 'react'; import ProgressBarAndroid from 'react-native'; import NativeBaseComponent from 'native-base/Components/Base/NativeBaseComponent'; import computeProps from 'native-base/Utils/computeProps'; export default class SpinnerNB extends NativeBaseComponent { prepareRootProps() { ...
code/workspaces/web-app/src/components/common/ConfirmDialog.js
NERC-CEH/datalab
import React from 'react'; import PropTypes from 'prop-types'; import Dialog from '@material-ui/core/Dialog'; import DialogTitle from '@material-ui/core/DialogTitle'; import DialogContent from '@material-ui/core/DialogContent'; import DialogActions from '@material-ui/core/DialogActions'; import DialogContentText from '...
src/main.js
idealgardens/codeword
import React from 'react' import ReactDOM from 'react-dom' import createBrowserHistory from 'history/lib/createBrowserHistory' import { useRouterHistory } from 'react-router' import { syncHistoryWithStore } from 'react-router-redux' import createStore from './store/createStore' import AppContainer from './containers/Ap...
src/data-table/DataTable.js
Synchro-TEC/apollo-11
import React from 'react'; import PropTypes from 'prop-types'; import DataTableBody from './data-table-body/DataTableBody'; import DataTableHeader from './data-table-header/DataTableHeader'; class DataTable extends React.Component { constructor(props) { super(props); this.keys = React.Children.map(props.chil...
cuttlebelle/code/listPosts.js
staystatic/staystatic
import PropTypes from 'prop-types'; import React from 'react'; /** * The listing posts component */ const ListPosts = ({ title, _pages, _relativeURL, _ID }) => ( <div> <b>{ title }</b> <ul className="news"> { Object.keys( _pages ) .filter( page => _pages[ page ]._url.startsWith('/posts/') ) .s...
resources/assets/javascript/components/plantsViewPage.js
colinjeanne/garden
import PlantList from './plantList'; import PlantListAddBox from './plantListAddBox'; import PlantView from './plantView'; import React from 'react'; const plantsViewPage = props => { let plantView; if (props.selectedPlant) { plantView = ( <PlantView plant={props.selectedPla...
examples/with-jsxstyle/src/Home.js
jaredpalmer/razzle
import { Block, InlineBlock } from 'jsxstyle'; import React, { Component } from 'react'; class Home extends Component { render() { return ( <Block textAlign="center"> <Block backgroundColor="#222"> <Block fontSize="3rem" color="#fff" padding="6rem 0" fontWeight="800"> Razzle x...
code/web/node_modules/react-bootstrap/es/FormControlStatic.js
zyxcambridge/RecordExistence
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 ...
src/index.js
koden-km/sc-react-redux
import SC from 'soundcloud'; import React from 'react'; import ReactDOM from 'react-dom'; import { Router, Route, IndexRoute, browserHistory } from 'react-router'; import { syncHistoryWithStore } from 'react-router-redux'; import { Provider } from 'react-redux'; import configureStore from './stores/configureStore'; imp...
src/ui/Item.js
touchstonejs/touchstonejs
import blacklist from 'blacklist'; import classnames from 'classnames'; import React from 'react'; module.exports = React.createClass({ displayName: 'Item', propTypes: { children: React.PropTypes.node.isRequired, component: React.PropTypes.any, className: React.PropTypes.string, showDisclosureArrow: React.P...
node_modules/semantic-ui-react/dist/es/elements/Label/LabelDetail.js
mowbell/clickdelivery-fed-test
import _extends from 'babel-runtime/helpers/extends'; import _isNil from 'lodash/isNil'; import cx from 'classnames'; import PropTypes from 'prop-types'; import React from 'react'; import { customPropTypes, getElementType, getUnhandledProps, META } from '../../lib'; function LabelDetail(props) { var children = pro...
src/components/home/Home.js
uxlayouts/spidermonkey
import React from 'react' const Home = () => ( <div className="container-fluid padding-top-3 padding-bottom-3"> <h2>Home</h2> </div> ) export default Home
dist/frontend/app.js
angeloocana/freecomclub
import React from 'react'; import ReactDOM from 'react-dom'; import Relay from 'react-relay'; import UserReport from './users/components/UserReport'; console.log('Hello app.tsx'); class HomeRoute extends Relay.Route { } HomeRoute.routeName = 'Home'; HomeRoute.queries = { store: (Component) => Relay.QL ` ...
src/components/result.js
ShaneFairweather/React-iTunes
import React, { Component } from 'react'; const Result = (props) => { function parseTime(milliseconds) { var minutes = Math.floor(milliseconds / 60000); var seconds = ((milliseconds % 60000) / 1000).toFixed(0); return minutes + ":" + (seconds < 10 ? '0' : '') + seconds; } return (...
src/parser/shared/modules/features/BaseHealerStatValues.js
FaideWW/WoWAnalyzer
import React from 'react'; import InformationIcon from 'interface/icons/Information'; import SPELLS from 'common/SPELLS/index'; import { formatNumber } from 'common/format'; import { calculatePrimaryStat, calculateSecondaryStatDefault } from 'common/stats'; import Analyzer from 'parser/core/Analyzer'; import HIT_TYPE...
node_modules/react-router/es/RouterContext.js
NickingMeSpace/questionnaire
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; }; var _typeof = typeof Symbol === "function" && typeof Symbol.i...
src/components/couchdb/plain/CouchdbPlain.js
fpoumian/react-devicon
import React from 'react' import PropTypes from 'prop-types' import SVGDeviconInline from '../../_base/SVGDeviconInline' import iconSVG from './CouchdbPlain.svg' /** CouchdbPlain */ function CouchdbPlain({ width, height, className }) { return ( <SVGDeviconInline className={'CouchdbPlain' + ' ' + className...
Libraries/Components/WebView/WebView.ios.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...
node_modules/react-bootstrap/es/Jumbotron.js
okristian1/react-info
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 ...
node/webpack/react/es6/es6.js
wushi27/nodejs201606
'use strict'; import React from 'react'; import ReactDOM from 'react-dom'; class HelloWorld extends React.Component{ render(){ return ( <p> hello,you aaa! It is {this.props.date.toTimeString()} </p> ); } } var sampleNameSpace = { myDi...
node_modules/react-bootstrap/es/SplitToggle.js
cmccandless/SolRFrontEnd
import _extends from 'babel-runtime/helpers/extends'; import _classCallCheck from 'babel-runtime/helpers/classCallCheck'; import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn'; import _inherits from 'babel-runtime/helpers/inherits'; import React from 'react'; import DropdownToggle fr...
app/components/TransferSelect/index.js
bruceli1986/react-qdp
/** * * TransferSelect * */ import React from 'react'; import _ from 'lodash'; import { Modal, Button, Input, Transfer } from 'antd'; import classNames from 'classnames'; import { FormattedMessage } from 'react-intl'; import styles from './styles.css'; const InputGroup = Input.Group; class TransferSelect extends Re...
src/components/book_display_component.js
allenyin55/reading_with_Annie
import React from 'react'; import { Link } from 'react-router'; import moment from 'moment-timezone'; const BookDisplay = ({book, isInList}) => { if(isInList){ // for teh sake of the book that doesn't have bookinfo or volumeinfo if(book.bookinfo === null || book.bookinfo.volumeInfo === undefined) return <L...
app/javascript/flavours/glitch/components/status_list.js
glitch-soc/mastodon
import { debounce } from 'lodash'; import React from 'react'; import ImmutablePropTypes from 'react-immutable-proptypes'; import PropTypes from 'prop-types'; import StatusContainer from 'flavours/glitch/containers/status_container'; import ImmutablePureComponent from 'react-immutable-pure-component'; import LoadGap fro...
examples/basic/components/Input.js
babotech/redux-uniform
import React from 'react' const Input = (props) => { const style = { ...defaultStyle, borderColor: !props.dirty ? `none` : !props.valid ? `#ff0000` : `#363636` } return ( <input style={style} {...props} /> ) } export default Input const defaultStyle = { display: `block`,...
app/components/TimelineEvent/index.js
samtgarson/MyFirstReactNativeApp
/* * * TimelineEvent * */ import ReactNative from 'react-native'; import React, { Component } from 'react'; import styles from './styles'; const { Animated, View, Text, ScrollView } = ReactNative; const FINAL_HEIGHT = 120 const RELEASE_OFFSET = 80 class TimelineEvent extends Component { constructor (props) { ...
packages/showcase/plot/labeled-stacked-vertical-bar-chart.js
uber-common/react-vis
// Copyright (c) 2016 - 2017 Uber Technologies, Inc. // // 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 // to use, copy, modify...
examples/src/components/StatesField.js
namuol/react-select-seamstress
import React from 'react'; import Select from 'react-select'; const STATES = require('../data/states'); var id = 0; function logChange() { console.log.apply(console, [].concat(['Select value changed:'], Array.prototype.slice.apply(arguments))); } var StatesField = React.createClass({ displayName: 'StatesField', p...
internals/templates/containers/App/index.js
gtct/wallet.eine.com
/** * * 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...
src/routes.js
sylnp0201/react-redux-universal-hot-example
import React from 'react'; import {Route} from 'react-router'; import { App, Home, Widgets, About, Login, RequireLogin, LoginSuccess, Survey, NotFound, } from 'containers'; export default function(store) { return ( <Route component={App}> <Route path="/" component={Hom...
dashboard/client/src/js/components/modules/VariationStats.js
jigarjain/sieve
import React from 'react'; import Loader from './base/Loader'; import Helpers from '../../utils/helpers'; const statTypes = [ { type: 'count', text: 'Counts' }, { type: 'convRate', text: 'Conversion Rate' }, { type: 'zScore', text: 'Z Score' }, ...
test/BootstrapMixinSpec.js
mengmenglv/react-bootstrap
import React from 'react'; import ReactTestUtils from 'react/lib/ReactTestUtils'; import BootstrapMixin from '../src/BootstrapMixin'; import styleMaps from '../src/styleMaps'; import { shouldWarn } from './helpers'; let Component; describe('BootstrapMixin', function () { beforeEach(function() { Component = Reac...
examples/todomvc/containers/TodoApp.js
Lucifier129/redux
import React, { Component } from 'react'; import { bindActionCreators } from 'redux'; import { connect } from 'react-redux'; import Header from '../components/Header'; import MainSection from '../components/MainSection'; import * as TodoActions from '../actions/todos'; class TodoApp extends Component { render() { ...
src/svg-icons/editor/format-align-right.js
pancho111203/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let EditorFormatAlignRight = (props) => ( <SvgIcon {...props}> <path d="M3 21h18v-2H3v2zm6-4h12v-2H9v2zm-6-4h18v-2H3v2zm6-4h12V7H9v2zM3 3v2h18V3H3z"/> </SvgIcon> ); EditorFormatAlignRight = pure(EditorFormatAlign...
examples/with-apollo-auth/lib/with-data.js
arunoda/next.js
import React from 'react' import cookie from 'cookie' import PropTypes from 'prop-types' import { ApolloProvider, getDataFromTree } from 'react-apollo' import initApollo from './init-apollo' function parseCookies (ctx = {}, options = {}) { return cookie.parse( ctx.req && ctx.req.headers.cookie ? ctx.req.h...
src/svg-icons/maps/beenhere.js
mit-cml/iot-website-source
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let MapsBeenhere = (props) => ( <SvgIcon {...props}> <path d="M19 1H5c-1.1 0-1.99.9-1.99 2L3 15.93c0 .69.35 1.3.88 1.66L12 23l8.11-5.41c.53-.36.88-.97.88-1.66L21 3c0-1.1-.9-2-2-2zm-9 15l-5-5 1.41-1.41L10 13.17l7.59...
admin/client/components/Navigation/SecondaryNavigation.js
pswoodworth/keystone
import React from 'react'; import { Container } from 'elemental'; var SecondaryNavItem = React.createClass({ displayName: 'SecondaryNavItem', propTypes: { children: React.PropTypes.node.isRequired, className: React.PropTypes.string, href: React.PropTypes.string.isRequired, path: React.PropTypes.string, tit...
app/components/Notice.js
Toreant/monster_web
/** * Created by apache on 15-10-30. */ import React from 'react'; import NoticeActions from '../actions/NoticeActions'; import NoticeStore from '../stores/NoticeStore'; import {Link} from 'react-router'; import Loading from './Loading'; class Notice extends React.Component { constructor(props) { super(p...
packages/cp-frontend/src/components/services/list-item.js
yldio/copilot
import React from 'react'; import PropTypes from 'prop-types'; import styled from 'styled-components'; import forceArray from 'force-array'; import sortBy from 'lodash.sortby'; import { isNot } from 'styled-is'; import { Col, Row } from 'react-styled-flexboxgrid'; import remcalc from 'remcalc'; import { InstancesIcon,...
app/javascript/mastodon/features/standalone/public_timeline/index.js
ashfurrow/mastodon
import React from 'react'; import { connect } from 'react-redux'; import PropTypes from 'prop-types'; import ImmutablePropTypes from 'react-immutable-proptypes'; import { expandPublicTimeline, expandCommunityTimeline } from 'mastodon/actions/timelines'; import Masonry from 'react-masonry-infinite'; import { List as Imm...
packages/ringcentral-widgets-demo/dev-server/containers/App/index.js
ringcentral/ringcentral-js-widget
import React from 'react'; import PropTypes from 'prop-types'; import { Provider } from 'react-redux'; import { Router, Route } from 'react-router'; import sleep from 'ringcentral-integration/lib/sleep'; import AlertContainer from 'ringcentral-widgets/containers/AlertContainer'; import ConnectivityBadgeContainer from ...
tests/lib/rules/vars-on-top.js
ronkorving/eslint
/** * @fileoverview Tests for vars-on-top rule. * @author Danny Fritz * @author Gyandeep Singh * @copyright 2014 Danny Fritz. All rights reserved. * @copyright 2014 Gyandeep Singh. All rights reserved. */ "use strict"; //------------------------------------------------------------------------------ // Requiremen...
src/svg-icons/image/grid-on.js
mit-cml/iot-website-source
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ImageGridOn = (props) => ( <SvgIcon {...props}> <path d="M20 2H4c-1.1 0-2 .9-2 2v16c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zM8 20H4v-4h4v4zm0-6H4v-4h4v4zm0-6H4V4h4v4zm6 12h-4v-4h4v4zm0-6h-4v-4h4v4zm0-6...
docs/app/Examples/views/Card/Types/CardExampleGroupProps.js
shengnian/shengnian-ui-react
import React from 'react' import { Card } from 'shengnian-ui-react' const items = [ { header: 'Project Report - April', description: 'Leverage agile frameworks to provide a robust synopsis for high level overviews.', meta: 'ROI: 30%', }, { header: 'Project Report - May', description: 'Bring t...
src/App.js
xindeling/Kyo-Demo
import React, { Component } from 'react'; import Scroll from 'react-scroll'; import logo from './logo.svg'; import './stylesheets/style.css'; let Link = Scroll.Link; let Element = Scroll.Element; let Events = Scroll.Events; let scroll = Scroll.animateScroll; let scrollSpy = Scroll.scrollSpy; class ...
src/frontend/components/AdminEventsSection.js
al3x/ground-control
import React from 'react'; import ReactDOM from 'react-dom'; import Relay from 'react-relay'; import EventPreview from './EventPreview'; import EventEdit from './EventEdit'; import {Toolbar, ToolbarGroup, ToolbarSeparator, ToolbarTitle, SelectField, DropDownMenu, DropDownIcon, Dialog, Tabs, Tab, FlatButton, RaisedButto...
src/components/Account.js
opsukka/fantasy-map
import React from 'react'; import { connect } from 'react-redux'; import { compose } from 'recompose'; import { PasswordForgetForm } from './PasswordForget'; import PasswordChangeForm from './PasswordChange'; import withAuthorization from './Session/withAuthorization'; const AccountPage = ({ authUser }) => <div cla...
src/auth/screens/auth-profile.screen.js
dyesseyumba/git-point
import React, { Component } from 'react'; import styled from 'styled-components'; import { connect } from 'react-redux'; import { bindActionCreators } from 'redux'; import { RefreshControl, View, ActivityIndicator, Dimensions, } from 'react-native'; import { ListItem } from 'react-native-elements'; import { ...
src/index.js
ernestofreyreg/react-calendar-month
import React from 'react'; import classNames from 'classnames'; export function zfill(num, len) { return (Array(len).join('0') + num).slice(-len); } export function isFirsDay(day) { return day.ordinal === 1; } export function monthDays(date) { const d = new Date(date.getFullYear(), date.getMonth() + 1, 0); return ...
todomvc/test/components/Footer.spec.js
samlatif-uk/redux-tdd-hw
import expect from 'expect' import React from 'react' import TestUtils from 'react-addons-test-utils' import Footer from '../../components/Footer' import { SHOW_ALL, SHOW_ACTIVE } from '../../constants/TodoFilters' function setup(propOverrides) { const props = Object.assign({ completedCount: 0, activeCount: ...
assets/jqwidgets/demos/react/app/expander/fluidsize/app.js
juannelisalde/holter
import React from 'react'; import ReactDOM from 'react-dom'; import JqxExpander from '../../../jqwidgets-react/react_jqxexpander.js'; class App extends React.Component { render() { return ( <JqxExpander width={'50%'} height={'50%'}> <div>Early History of the Internet</div> ...
src/pages/TodoList.js
marktani/react-native-express-1
import React from 'react' import markdown from 'markdown-in-js' import markdownOptions from '../utils/MarkdownOptions' import Page from './Page' import { PageHeader } from '../components' const content = markdown(markdownOptions)` Our first exercise will be a simple Todo List. If you get stuck at any point, you can ...
examples/blockly-react/src/App.js
google/blockly-samples
/** * @license * * Copyright 2019 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 ...
src/RadioGroup.js
sazl/react-bootstrap-validation
import React from 'react'; import Radio from './Radio'; import InputContainer from './InputContainer'; import classNames from 'classnames'; export default class RadioGroup extends InputContainer { constructor(props) { super(props); this.state = { value: props.defaultValue || ...
stories/ChangingContent/index.js
henrybuilt/react-sticky-table
import React, { Component } from 'react'; import { StickyTable, Row, Cell } from '../../src'; import Button from '../Button'; export default class ChangingContent extends Component { constructor(props) { super(props); var rows = []; var cells; for (var r = 0; r < 50; r++) { cells = []; ...
src/routes/workTeam/NavSidebar/NavSidebar.js
nambawan/g-old
import React from 'react'; import PropTypes from 'prop-types'; import withStyles from 'isomorphic-style-loader/withStyles'; import s from './NavSidebar.css'; import Sidebar from '../../../components/Sidebar'; import Label from '../../../components/Label'; import Heading from '../../../components/Heading'; import Image ...
app/components/H3/index.js
ReelTalkers/reeltalk-web
import React from 'react' function H3(props) { return ( <h3 { ...props } /> ) } export default H3
MobileApp/node_modules/react-native-elements/src/checkbox/CheckBox.js
VowelWeb/CoinTradePros.com
import PropTypes from 'prop-types'; import React from 'react'; import { StyleSheet, TouchableOpacity, View, Platform, Text as NativeText, } from 'react-native'; import TextElement from '../text/Text'; import fonts from '../config/fonts'; import colors from '../config/colors'; import FAIcon from 'react-native-...
ui/src/containers/municipalities-grid/index.js
indraneel/sustainability-dashboard
import React, { Component } from 'react'; import {GridList, GridTile} from 'material-ui/GridList'; import style from './municipalities-grid.style.js'; import MunicipalitiesGridTile from '../../components/municipalities-grid-tile'; import CategoryMapper from '../../constants/category-map'; import {LoadingIndicator} fro...
src/esm/components/graphics/icons/envelope-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 EnvelopeIcon = function EnvelopeIcon(_ref) { var color =...
common/containers/ArticleBrowser/ArticleBrowser.js
kherrick/postpress
import { connect } from 'react-redux' import { getArticles } from '../../actions/creators/articleBrowser/thunks/articleBrowser' import Article from './Article' import config from '../../../config/config' import InfiniteScroll from 'react-infinite-scroller' import PropTypes from 'prop-types' import React from 'react' c...
src/Parser/Mage/Frost/Modules/Features/WintersChill.js
enragednuke/WoWAnalyzer
import React from 'react'; import Analyzer from 'Parser/Core/Analyzer'; import Combatants from 'Parser/Core/Modules/Combatants'; import EnemyInstances from 'Parser/Core/Modules/EnemyInstances'; import SPELLS from 'common/SPELLS'; import SpellIcon from 'common/SpellIcon'; import SpellLink from 'common/SpellLink'; impor...
src/index.js
rmoliva/bacon_react_pet
/* import 'core-js/fn/object/assign'; import React from 'react'; import ReactDOM from 'react-dom'; import App from './components/Main'; */ // Render the main component into the dom // ReactDOM.render(<App />, document.getElementById('app')); import React from 'react'; import ReactDOM from 'react-dom'; import ToDo from...
src/Interpolate.js
pandoraui/react-bootstrap
// https://www.npmjs.org/package/react-interpolate-component // TODO: Drop this in favor of es6 string interpolation import React from 'react'; import ValidComponentChildren from './utils/ValidComponentChildren'; const REGEXP = /\%\((.+?)\)s/; const Interpolate = React.createClass({ displayName: 'Interpolate', ...
src/components/Root.js
qkevinto/kevinto.me
import React from 'react'; import { root } from './Root.module.scss'; import About from '../components/About'; import SocialActivities from '../components/SocialActivities'; export default class Root extends React.Component { render() { return ( <div className={root}> <About></About> <Soci...
src/components/video_list.js
IanY57/ReduxSimpleStarter
import React from 'react'; import VideoListItem from './video_list_item'; const VideoList = (props) => { const videoItems = props.videos.map((video) => { return( <VideoListItem onVideoSelect={props.onVideoSelect} key={video.etag} video={video} ...
tests/client/ui/components/TestSwitch.js
jasonthomas/addons-frontend
import React from 'react'; import { Simulate, renderIntoDocument } from 'react-addons-test-utils'; import { findDOMNode } from 'react-dom'; import Switch from 'ui/components/Switch'; describe('<Switch />', () => { function renderButton(props = {}) { const renderProps = { dispatch: sinon.spy(), labe...
src/BootstrapMixin.js
insionng/react-bootstrap
import React from 'react'; import styleMaps from './styleMaps'; import CustomPropTypes from './utils/CustomPropTypes'; const BootstrapMixin = { propTypes: { /** * bootstrap className * @private */ bsClass: CustomPropTypes.keyOf(styleMaps.CLASSES), /** * Style variants * @type {("...
front_end/src/pages/Reporting/Reporting-Reports.js
oyiptong/splice
import React from 'react'; import {connect} from 'react-redux'; import moment from 'moment'; import Select from 'react-select'; import {Table} from 'react-tabular'; import {fetchCampaigns, fetchCampaign, campaignSetFilter} from 'actions/Campaigns/CampaignActions'; import {fetchAccounts} from 'actions/Accounts/Account...
__tests__/index.android.js
yarikgenza/gainster
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 /> ); });
packages/icons/src/md/action/ViewModule.js
suitejs/suitejs
import React from 'react'; import IconBase from '@suitejs/icon-base'; function MdViewModule(props) { return ( <IconBase viewBox="0 0 48 48" {...props}> <path d="M7 23h10V11H7v12zm0 14h10V25H7v12zm12 0h10V25H19v12zm12 0h10V25H31v12zM19 23h10V11H19v12zm12-12v12h10V11H31z" /> </IconBase> ); } export de...
site/src/components/ExampleColumnGroupsNoHeader.js
pbeshai/react-taco-table
import React from 'react'; import { TacoTable, DataType, SortDirection, Formatters } from 'react-taco-table'; import cellLinesData from '../data/cell_lines.json'; /** * An example demonstrating how to use column groups without headers */ const columns = [ { id: 'name', value: rowData => rowData.cellLine, ...
app/javascript/mastodon/features/status/components/action_bar.js
ikuradon/mastodon
import React from 'react'; import PropTypes from 'prop-types'; import { connect } from 'react-redux'; import IconButton from '../../../components/icon_button'; import ImmutablePropTypes from 'react-immutable-proptypes'; import DropdownMenuContainer from '../../../containers/dropdown_menu_container'; import { defineMess...
src/containers/icons.js
BryceKrah/Portfolio
import React, { Component } from 'react'; import Nav from './nav_bar'; export default class Icons extends Component { render() { return ( <div className="icon-container"> <a href="//github.com/brycekrah"><div className="icon-image icon-github"></div></a> <a href="//linkedin.com/in/bry...
webpack/scenes/Subscriptions/components/SubscriptionsTable/SubscriptionTypeFormatter.js
cfouant/katello
import React from 'react'; import { Link } from 'react-router-dom'; import helpers from '../../../../move_to_foreman/common/helpers'; export const subscriptionTypeFormatter = (value, { rowData }) => { let cellContent; if (rowData.virt_only === false) { cellContent = __('Physical'); } else if (rowData.hyperv...
docs/src/app/index.js
ButuzGOL/constructor
require('./assets/styles/main.less'); import React from 'react'; import Router from 'react-router'; import routes from './routes'; window.React = React; Router.run(routes, (Handler) => { React.render(<Handler />, document.body); });
third_party/prometheus_ui/base/web/ui/node_modules/reactstrap/es/NavItem.js
GoogleCloudPlatform/prometheus-engine
import _extends from "@babel/runtime/helpers/esm/extends"; import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose"; var _excluded = ["className", "cssModule", "active", "tag"]; import React from 'react'; import PropTypes from 'prop-types'; import classNames from 'classnames';...
src/js/admin/articles/filters/state-filter/state-filter.js
ucev/blog
import React from 'react' import { connect } from 'react-redux' import FilterSelect from '../filter-select' const STATE_OPTIONS = [ { value: '-1', title: '全部' }, { value: 'on', title: '已上线' }, { value: 'off', title: '已下线' }, ] const StateFilter = ({ value }) => ( <FilterSelect key="state" title="stat...
src/svg-icons/communication/present-to-all.js
rscnt/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let CommunicationPresentToAll = (props) => ( <SvgIcon {...props}> <path d="M21 3H3c-1.11 0-2 .89-2 2v14c0 1.11.89 2 2 2h18c1.11 0 2-.89 2-2V5c0-1.11-.89-2-2-2zm0 16.02H3V4.98h18v14.04zM10 12H8l4-4 4 4h-2v4h-4v-4z"/...
src/components/Post/Meta/Meta.js
bapti/blog
// @flow strict import React from 'react'; import moment from 'moment'; import styles from './Meta.module.scss'; type Props = { date: string }; const Meta = ({ date }: Props) => ( <div className={styles['meta']}> <p className={styles['meta__date']}>Published {moment(date).format('D MMM YYYY')}</p> </div> );...
test/components/OpenClose.spec.js
martinkwan/HNGRY
import React from 'react'; import { shallow } from 'enzyme'; import OpenClose from '../../src/components/openClose'; describe('(Component) OpenClose', () => { let wrapper; beforeEach(() => { wrapper = shallow(<OpenClose />); }); it('renders self successfully', () => { expect(wrapper).to.have.length(1);...
definitions/npm/styled-components_v2.x.x/flow_v0.53.x-/test_styled-components_native_v2.x.x.js
davidohayon669/flow-typed
// @flow import nativeStyled, { ThemeProvider as NativeThemeProvider, withTheme as nativeWithTheme, keyframes as nativeKeyframes, } from 'styled-components/native' import React from 'react' import type { Theme as NativeTheme, Interpolation as NativeInterpolation, ReactComponentFunctional as NativeReactCompo...
stories/modal/modal.js
JerryBerton/dh-component
import React from 'react'; import { Modal, Button, Menu, Dropdown, Form, Input } from '../../src'; class ModalDemo extends React.Component { constructor(props) { super(props); this.state = { visible: false, visibleForm: false }; this.handleClick = this.handleClick.bind(this); } handleC...
example/examples/SetNativePropsOverlays.js
j0ergo/react-native-maps
import React from 'react'; import { StyleSheet, View, Text, TouchableOpacity, Dimensions, } from 'react-native'; import MapView from 'react-native-maps'; const { width, height } = Dimensions.get('window'); const ASPECT_RATIO = width / height; const LATITUDE = 37.78825; const LONGITUDE = -122.4324; const LA...
packages/material-ui-icons/src/PictureInPictureAlt.js
dsslimshaddy/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from 'material-ui/SvgIcon'; let PictureInPictureAlt = props => <SvgIcon {...props}> <path d="M19 11h-8v6h8v-6zm4 8V4.98C23 3.88 22.1 3 21 3H3c-1.1 0-2 .88-2 1.98V19c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2zm-2 .02H3V4.97h18v14.05z" /> </SvgIco...
app/components/RButton.js
qinfuji/vpt
import React from 'react'; import styles from '../styles/button.less'; import classnames from 'classnames'; export default class RButton extends React.Component { componentWillUnmount(){ let {remove , id} = this.props; remove(id); } clickHandle(e){ this.props.onClick(e); } ...
app/containers/Spa/SpaReport/index.js
vollmerr/app-hub
import React from 'react'; import PropTypes from 'prop-types'; import styled from 'styled-components'; import { compose } from 'redux'; import { connect } from 'react-redux'; import { withRouter } from 'react-router'; import { createStructuredSelector } from 'reselect'; import { SelectionMode } from 'office-ui-fabric-r...