path
stringlengths
5
296
repo_name
stringlengths
5
85
content
stringlengths
25
1.05M
src/components/entry/EntryPrompts.js
reichert621/log-book
import React from 'react' import moment from 'moment' import classNames from 'classnames' import css from './Entry.scss' import AddItem from './AddItem.js' import Prompt from './Prompt.js' export class EntryPrompts extends React.Component { constructor (props) { super(props) this.state = { saving: fal...
src/parser/shared/modules/MitigationCheck.js
sMteX/WoWAnalyzer
import React from 'react'; import Analyzer from 'parser/core/Analyzer'; import SPELLS from 'common/SPELLS/index'; import SpellIcon from 'common/SpellIcon'; import { formatNumber, formatPercentage } from 'common/format'; import SpellLink from 'common/SpellLink'; import Enemies from 'parser/shared/modules/Enemies'; im...
app/components/Catalogue.js
Byte-Code/lm-digital-store-private-test
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import ImmutablePropTypes from 'react-immutable-proptypes'; import { Link } from 'react-router'; import { Map, List } from 'immutable'; import glamorous from 'glamorous'; import ProductBadge from './ProductBadge'; import SellingAidsBadge fro...
app/containers/LanguageProvider/index.js
Budaa/coding_test
/* * * LanguageProvider * * this component connects the redux state language locale to the * IntlProvider component and i18n messages (loaded from `app/translations`) */ import React from 'react'; import { connect } from 'react-redux'; import { createSelector } from 'reselect'; import { IntlProvider } from 'reac...
src/components/TitleBar.js
tofuness/Toshocat
import React, { Component } from 'react'; import KickerContainer from '../containers/KickerContainer'; import settings from '../utils/settings'; class TitleBar extends Component { constructor(props) { super(props); this.state = { fullscreen: false }; } handleClose() { if (settings.get('min...
assets/jqwidgets/demos/react/app/grid/popupediting/app.js
juannelisalde/holter
import React from 'react'; import ReactDOM from 'react-dom'; import JqxGrid from '../../../jqwidgets-react/react_jqxgrid.js'; import JqxButton from '../../../jqwidgets-react/react_jqxbuttons.js'; import JqxInput from '../../../jqwidgets-react/react_jqxinput.js'; import JqxNumberInput from '../../../jqwidgets-react/rea...
themes/genius/Genius 2.3.1 Bootstrap 4/React_Full_Project/src/views/Icons/FontAwesome/FontAwesome.js
davidchristie/kaenga-housing-calculator
import React, { Component } from 'react'; class FontAwesome extends Component { render() { return ( <div className="animated fadeIn"> <div className="card" id="new"> <div className="card-header">20 New Icons in 4.5</div> <div className="card-block"> <div className="row text-center"> ...
ui/src/components/Portfolio.js
Ion-Petcu/StockTrainer
import React from 'react' import Position from './Position' import cst from '../utils/constants' export class Portfolio extends React.Component { render() { let positions = cst.STOCKS.map( (sym) => { let position = this.props.data.positions.find((p) => p.symbol == sym) || {uni...
react-fundamentals-es6/lessons/01-intro/App.js
3mundi/React-Bible
//https://jsbin.com/nequdiy/edit?js,output import React from 'react'; class App extends React.Component { render(){ return <h1>Hello Guys</h1> } } // const App = () => <h1>Hello Eggheads</h1> export default App
classic/src/scenes/content/src/index.js
wavebox/waveboxapp
import React from 'react' import ReactDOM from 'react-dom' import Provider from 'Scenes/Provider' import browserActions from 'stores/browser/browserActions' import querystring from 'querystring' import { WB_SEND_IPC_TO_CHILD } from 'shared/ipcEvents' import { ipcRenderer, remote } from 'electron' import { settingsStore...
src/js/components/dashboard/widgets/accepteddevices.js
michaelatmender/gui
import React from 'react'; import pluralize from 'pluralize'; // material ui import { CheckCircle as CheckIcon, ReportProblem as ReportProblemIcon } from '@mui/icons-material'; import { colors } from '../../../themes/Mender'; import { BaseWidget, styles } from './baseWidget'; const notificationStyles = { base: { ...
src/svg-icons/maps/traffic.js
barakmitz/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let MapsTraffic = (props) => ( <SvgIcon {...props}> <path d="M20 10h-3V8.86c1.72-.45 3-2 3-3.86h-3V4c0-.55-.45-1-1-1H8c-.55 0-1 .45-1 1v1H4c0 1.86 1.28 3.41 3 3.86V10H4c0 1.86 1.28 3.41 3 3.86V15H4c0 1.86 1.28 3.41...
test/views/example.js
beedeez/reactjs-md-editor
import MDEditor from '../../lib/reactjs-md-editor'; import MDViewer from 'reactjs-md-viewer'; import React, { Component } from 'react'; import ReactDOM from 'react-dom'; class MyHeading extends Component { render() { return <h1 style={{ color: 'red' }}>{this.props.text || 'test'}</h1>; } } class Example extends C...
src/components/CompanyAndJobTitle/TabLinkGroup.js
goodjoblife/GoodJobShare
import React from 'react'; import PropTypes from 'prop-types'; import { NavLink } from 'react-router-dom'; import P from 'common/base/P'; import styles from './TabLinkGroup.module.css'; const encodeFirstIsActive = to => (_, location) => { const { pathname } = location; return encodeURI(pathname) === to; }; cons...
app/javascript/mastodon/components/column.js
anon5r/mastonon
import React from 'react'; import PropTypes from 'prop-types'; import detectPassiveEvents from 'detect-passive-events'; import { scrollTop } from '../scroll'; export default class Column extends React.PureComponent { static propTypes = { children: PropTypes.node, }; scrollTop () { const scrollable = th...
src/svg-icons/image/view-compact.js
hai-cea/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ImageViewCompact = (props) => ( <SvgIcon {...props}> <path d="M3 19h6v-7H3v7zm7 0h12v-7H10v7zM3 5v6h19V5H3z"/> </SvgIcon> ); ImageViewCompact = pure(ImageViewCompact); ImageViewCompact.displayName = 'ImageVie...
frontend/component/Signup.js
caiklaus/first-node-project
import React from 'react'; import jQuery from 'jquery'; import {signup} from '../lib/client'; import {redirectURL} from '../lib/utils'; export default class Signup extends React.Component { constructor(props) { super(props); this.state = {}; } handleChange(name, e) { this.state[name] = e.target.val...
src/js/components/ui/ProposalIcon/ProposalIcon.js
nekuno/client
import PropTypes from 'prop-types'; import React, { Component } from 'react'; import styles from './ProposalIcon.scss'; export default class ProposalIcon extends Component { static propTypes = { icon : PropTypes.string, size : PropTypes.oneOf(['xx-small', 'x-small', 'small', 'med...
test/date-picker/calendar-spec.js
vmaudgalya/material-ui
import injectTapEventPlugin from 'react-tap-event-plugin'; injectTapEventPlugin(); import React from 'react'; import ReactDOM from 'react-dom'; import Calendar from 'date-picker/calendar'; import CalendarToolbar from 'date-picker/calendar-toolbar'; import IconButton from 'icon-button'; import injectTheme from '../fixt...
src/components/UserHeader/UserHeader.js
hirzanalhakim/testKumparan
import React, { Component } from 'react'; export default class UserHeader extends Component { render() { const colWidth = { width: "15%" } return ( <thead> <tr className="table-header"> <th>Nama</th> <th>Alamat</th> <th style={colWidth}>Action</th> </tr> </thead> ) } }
packages/react-art/src/ReactART.js
jameszhan/react
/** * Copyright (c) Facebook, Inc. and its affiliates. * * 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 ReactVersion from 'shared/ReactVersion'; import * as ARTRenderer from 'react-reconciler/inline.a...
tests/ssr/server.js
headzoo/react-moment
import path from 'path'; import fs from 'fs'; import express from 'express'; import React from 'react'; import ReactDOMServer from 'react-dom/server'; import App from './app'; const PORT = 8081; const app = express(); const router = express.Router(); const serverRenderer = (req, res) => { fs.readFile(path.reso...
tests/layouts/CoreLayout.spec.js
dingyoujian/webpack-react-demo
import React from 'react' import TestUtils from 'react-addons-test-utils' import CoreLayout from 'layouts/CoreLayout/CoreLayout' function shallowRender (component) { const renderer = TestUtils.createRenderer() renderer.render(component) return renderer.getRenderOutput() } function shallowRenderWithProps (props...
src/components/NavigationComponent.js
ykzts/gyazo-web-client
import React from 'react'; import { connectToStores } from 'fluxible-addons-react'; import { NavLink } from 'fluxible-router'; import RouteStore from '../stores/RouteStore'; @connectToStores([RouteStore], (context) => ({ currentRoute: context.getStore(RouteStore).getCurrentRoute() })) class NavigationComponent exten...
RN/reactjs/reactjs-demo/comment2/CommentApp.js
puyanLiu/LPYFramework
import React, { Component } from 'react'; import ReactDOM from 'react-dom'; import CommentInput from './CommentInput.js'; import CommentList from './CommentList.js'; import './index.css'; class CommentApp extends Component { constructor() { super(); this.state = { comments: [] }...
src/FormGroup.js
RichardLitt/react-bootstrap
import React from 'react'; import classNames from 'classnames'; class FormGroup extends React.Component { render() { let classes = { 'form-group': !this.props.standalone, 'form-group-lg': !this.props.standalone && this.props.bsSize === 'large', 'form-group-sm': !this.props.standalone && this.pr...
client/src/SelectedCourses.js
MOOCFetcher/moocfetcher-appliance
import CourseStore, { COURSE_SELECT_EVENT, COURSE_UNSELECT_EVENT } from './CourseStore' import CourseList from './CourseList' import React from 'react' export default class SelectedCourses extends React.Component { constructor () { super() this.state = {courses: CourseStore.getSelected()} } componen...
jenkins-design-language/src/js/components/material-ui/svg-icons/action/help-outline.js
alvarolobato/blueocean-plugin
import React from 'react'; import SvgIcon from '../../SvgIcon'; const ActionHelpOutline = (props) => ( <SvgIcon {...props}> <path d="M11 18h2v-2h-2v2zm1-16C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zm0-14c-2.21 0-4 1.79-4 4h2c0-1.1.9-2 2-...
src/components/CreatePhoto.js
sharkinsspatial/knowsnow
import React from 'react' import PhotoCarousel from './PhotoCarousel' import classNames from 'classnames' import Well from 'react-bootstrap/lib/Well' import Button from 'react-bootstrap/lib/Button' class CreatePhoto extends React.Component { constructor(props) { super(props) this.state = { submitti...
app/client.js
pasangsherpa/memenshare-ui
import React from 'react'; import ReactDOM from 'react-dom'; import { Provider } from 'react-redux'; import { Router, useRouterHistory } from 'react-router'; import { createHashHistory } from 'history'; import configureStore from './store/configure'; import routes from './routes'; const history = useRouterHistory(crea...
src/App/router/index.js
hajjiTarik/SolarNews
import React from 'react'; import { StackNavigator, TabNavigator } from 'react-navigation'; import { Icon } from 'react-native-elements'; import colors from '../../design'; import Home from '../views/Home'; import Saved from '../views/Saved'; import Settings from '../views/Settings'; import ArticleDetails from '../vi...
src/mui-components/StatusBar.js
LiveTyping/android-colors
import React, { Component } from 'react'; import PropTypes from 'prop-types'; const propTypes = { date: PropTypes.instanceOf(Date), }; const defaultProps = { date: new Date(), }; const contextTypes = { muiTheme: PropTypes.object.isRequired, }; function getStyles(props, context) { const { statusBar } = contex...
frontend/src/containers/ActivityTypes.js
viewportvr/daysinvr
import React from 'react'; import { Link } from 'react-router-dom'; import { Helmet } from 'react-helmet'; import { observer } from 'mobx-react-lite'; const Tag = props => ( <span className="bg-dark-gray white ph1 br2 f6 ma1">{props.children}</span> ); const ActivityTypes = observer(() => { return ( <div clas...
src/components/Dummy.js
paulmusso/webpack-boilerplate
import React from 'react'; export default React.createClass({ displayName: 'Dummy', render() { return ( <div> </div> ); } });
blueocean-material-icons/src/js/components/svg-icons/content/delete-sweep.js
jenkinsci/blueocean-plugin
import React from 'react'; import SvgIcon from '../../SvgIcon'; const ContentDeleteSweep = (props) => ( <SvgIcon {...props}> <path d="M15 16h4v2h-4zm0-8h7v2h-7zm0 4h6v2h-6zM3 18c0 1.1.9 2 2 2h6c1.1 0 2-.9 2-2V8H3v10zM14 5h-3l-1-1H6L5 5H2v2h12z"/> </SvgIcon> ); ContentDeleteSweep.displayName = 'ContentDeleteSwe...
src/views/people/EditPeople.js
ishgroup/lightbook
import React, { Component } from 'react'; import Config from '../../Config'; import TextInputEdited from '../../components/TextInputEdited'; import Util from '../../components/Util'; import Validate from '../../components/Validate'; import AutoComplete from '../../components/AutoComplete'; import Select from '../../com...
js2/App.js
JRFrazier/complete-intro-to-react
import React from 'react' import { Match } from 'react-router' import { Provider } from 'react-redux' import store from './store' import AsyncRoute from './AsyncRoute' import preload from '../public/data.json' if (global) { global.System = { import () {} } } const App = () => { return ( <Provider store={store}...
public/js/components/chat/chatCard.react.js
MadushikaPerera/Coupley
import React from 'react'; import Paper from 'material-ui/lib/paper'; import ChatCC from './ChatCC.react'; import MessageThread from './Messages.react'; import SelectFriend from './ChatTopBar.react'; import LoginStore from '../../stores/LoginStore'; const styleup = { height:50, width: 650, textAlign:'center', ...
src/components/Alert.js
robwalkerco/caerurfapugs
import React from 'react' import styled from 'styled-components' const Border = styled.div` border: #FF0000 2px solid; ` const Title = styled.p` font-weight: bold; color: #FF0000; ` const Alert = ({ title, children }) => ( <Border> <Title>{title}</Title> {children} </Border> ) export default Alert...
src/components/video_list_item.js
rahilka/ReactJS
// Component for each video from the list item import React from 'react'; const VideoListItem = ({video, onVideoSelect}) => { // get the video that we passed to VideoList as a property // es6 syntax: instead of pass 'props' argument and then const video = props.video; // just pass '{video}' // !! Put '{}' in...
modules/__tests__/_bc-History-test.js
aaron-goshine/react-router
import expect from 'expect' import React from 'react' import { render, unmountComponentAtNode } from 'react-dom' import History from '../History' import Router from '../Router' import Route from '../Route' import createHistory from 'history/lib/createMemoryHistory' import shouldWarn from './shouldWarn' describe('v1 Hi...
packages/icons/src/md/communication/PortableWifiOff.js
suitejs/suitejs
import React from 'react'; import IconBase from '@suitejs/icon-base'; function MdPortableWifiOff(props) { return ( <IconBase viewBox="0 0 48 48" {...props}> <path d="M35.12 29.48c.56-1.38.88-2.89.88-4.48 0-6.63-5.37-12-12-12-1.59 0-3.1.32-4.49.88l3.25 3.25c.41-.07.82-.13 1.24-.13 4.42 0 8 3.58 8 8 0 .43-.0...
rallyboard-v1/node_modules/react-router/es/Switch.js
tylerjw/rallyscores
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call &...
example/src/EmptyScreen.js
jacklam718/react-native-popup-dialog
import React from 'react'; export default () => { return null; };
src/svg-icons/content/drafts.js
hwo411/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ContentDrafts = (props) => ( <SvgIcon {...props}> <path d="M21.99 8c0-.72-.37-1.35-.94-1.7L12 1 2.95 6.3C2.38 6.65 2 7.28 2 8v10c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2l-.01-10zM12 13L3.74 7.84 12 3l8.26 4.84L12 13z"/>...
actor-apps/app-web/src/app/components/common/State.react.js
bensonX/actor-platform
import React from 'react'; import { MessageContentTypes } from 'constants/ActorAppConstants'; class State extends React.Component { static propTypes = { message: React.PropTypes.object.isRequired }; render() { const { message } = this.props; if (message.content.content === MessageContentTypes.SERVI...
src/SettingsItemBirthday/index.js
DuckyTeam/ducky-components
import React from 'react'; import PropTypes from 'prop-types'; import classNames from 'classnames'; import styles from './styles.css'; import SettingsItem from '../SettingsItem'; import Wrapper from '../Wrapper'; import moment from 'moment'; import PopoverMenuAnchor4 from '../PopoverMenuAnchor4'; function SettingsIte...
src/main/resources/ui/components/JsonEditor.js
mesos/chronos
import React from 'react' import {observer} from 'mobx-react' import brace from 'brace' import AceEditor from 'react-ace' import 'brace/mode/javascript' import 'brace/theme/monokai' @observer export default class JsonEditor extends React.Component { setAceCallback = false componentDidUpdate() { var _this = th...
src/Label.js
mengmenglv/react-bootstrap
import React from 'react'; import classNames from 'classnames'; import BootstrapMixin from './BootstrapMixin'; const Label = React.createClass({ mixins: [BootstrapMixin], getDefaultProps() { return { bsClass: 'label', bsStyle: 'default' }; }, render() { let classes = this.getBsClassSe...
web-app/src/components/Temp/LandingPage/index.js
oSoc17/code9000
import React from 'react'; import { Link } from 'react-router-dom'; import '../bootstrap.css'; import './landingpage.css'; import imageBall from '../images/bal.svg'; import imageBallRight from '../images/bal_rechts.svg'; import imageBert from './images/bert_1.svg'; import imageLeader from './images/leader.png'; impor...
packages/docs/components/Examples/hashtag/CustomHashtagEditor/index.js
draft-js-plugins/draft-js-plugins
import React, { Component } from 'react'; import Editor, { createEditorStateWithText } from '@draft-js-plugins/editor'; import createHashtagPlugin from '@draft-js-plugins/hashtag'; import editorStyles from './editorStyles.module.css'; import hashtagStyles from './hashtagStyles.module.css'; const hashtagPlugin = create...
src/svg-icons/image/add-to-photos.js
IsenrichO/mui-with-arrows
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let ImageAddToPhotos = (props) => ( <SvgIcon {...props}> <path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6zm16-4H8c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm-1 9h-4v4h-2v-4H9V9h4V5h2v4h4v2z"/> ...
scripts/App.js
ButenkoT/react-practice-
import React from 'react'; import Header from './Header'; import Content from './Content'; import Footer from './Footer'; const App = React.createClass({ render(){ return ( <div> <Header /> <Content /> <Footer /> </div> ); } }); export default App;
src/component/SectionHeader.js
dentemple/developer-portfolio
import React from 'react' import PropTypes from 'prop-types' const SingleLine = ({ children }) => { return ( <h2 className='section-header'> { children } </h2> ) } const NBSpace = () => <span>&nbsp;</span> const Lace = () => <span>{'{'}</span> const Race = () => <span>{'}'}</span> const Text = ({ tex...
frontend/src/routes/Home/components/HomeView.js
SeaItRise/SeaItRise-webportal
import React from 'react'; import DuckImage from '../assets/Duck.jpg'; import './HomeView.scss'; export const HomeView = () => ( <div> <h4>Welcome!</h4> <img alt="This is a duck, because Redux!" className="duck" src={DuckImage} /> </div> ); export default HomeView;
docs/src/examples/collections/Breadcrumb/Types/BreadcrumbExampleShorthand.js
Semantic-Org/Semantic-UI-React
import React from 'react' import { Breadcrumb } from 'semantic-ui-react' const sections = [ { key: 'Home', content: 'Home', link: true }, { key: 'Store', content: 'Store', link: true }, { key: 'Shirt', content: 'T-Shirt', active: true }, ] const BreadcrumbExampleShorthand = () => ( <Breadcrumb icon='right ang...
templates/new/src/js/index.js
primozs/grommet
import '../scss/index.scss'; import React, { Component } from 'react'; import ReactDOM from 'react-dom'; import App from 'grommet/components/App'; class Main extends Component { render () { return ( <App></App> ); } }; let element = document.getElementById('content'); ReactDOM.render(React.createEl...
components/ConfigView.js
FindEarth/app
import React from 'react' import { View, Text } from 'react-native' import PropTypes from 'prop-types' import FitImage from 'react-native-fit-image' import pure from 'recompose/pure' function ConfigView({styles}) { return ( <View style={styles.container} > <View style={styles.logoContainer}> <FitIm...
test/homePageButton-test.js
melissa-c/Comms
import test from 'ava' import React from 'react' import {shallow, render, mount} from 'enzyme' import HomePageBtn from '../src/components/homePageBtn' test ('1/2<HomePageBtn > returns button element', t => { const expected ='Schedule' const wrapper1 =mount(<HomePageBtn /> ) var div = wrapper1.html() t.deepE...
test/index.js
justinwoo/pure-render-function
import test from 'ava'; import React from 'react'; import ReactDOM from 'react-dom'; import ReactDOMServer from 'react-dom/server'; import PureRenderFunction from '../src/index.js'; test('doesnt cause errors', function (t) { var MyComponent = PureRenderFunction(function () { return <div/>; }); ReactDOMServe...
com/jessewarden/contacts/contactClasses/ImageView.js
JesterXL/react-bootstrap-express-cassandra-contacts
import React from 'react'; import ReactDOM from 'react-dom'; class ImageView extends React.Component { render() { var imageStyles = { width: '4em', height: '4em' }; var contact = this.props.contact; // console.log("ImageView::render, contact:", contact); if(typeof contact === 'undefined') { retu...
src/scripts/student-profile/js/app/components/schedule/Course.js
IronCountySchoolDistrict/student-profile
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import Attendance from './Attendance'; import GradeList from './GradeList'; export default class Course extends Component { render() { const panelDefault = 'card panel-course'; const teacherContainerClass = 'col-md-2 col-2 teacher-...
src/components/ListBox/ListBoxMenuIcon.js
carbon-design-system/carbon-components-react
/** * 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 cx from 'classnames'; import React from 'react'; import PropTypes from 'prop-types'; import ChevronDown16 from '@carbon/icons-react/li...
react/features/video-quality/components/Slider.js
gpolitis/jitsi-meet
// @flow import { makeStyles } from '@material-ui/core/styles'; import clsx from 'clsx'; import React from 'react'; import { commonClassName } from '../../base/ui/constants'; type Props = { /** * The 'aria-label' text. */ ariaLabel: string, /** * The maximum value for slider value. *...
packages/icons/src/md/editor/AttachMoney.js
suitejs/suitejs
import React from 'react'; import IconBase from '@suitejs/icon-base'; function MdAttachMoney(props) { return ( <IconBase viewBox="0 0 48 48" {...props}> <path d="M24.97 21.8c-4.54-1.18-6-2.39-6-4.29 0-2.18 2.01-3.71 5.4-3.71 3.56 0 4.88 1.7 5 4.2h4.42c-.13-3.45-2.24-6.59-6.42-7.62V6h-6v4.32c-3.88.85-7 3.35...
node_modules/recharts/demo/component/RadialBarChart.js
SerendpityZOEY/Solr-Search-React-UI
import React from 'react'; import { RadialBarChart, RadialBar, Cell, Legend, Tooltip, ResponsiveContainer } from 'recharts'; import { changeNumberOfData } from './utils'; import { scaleOrdinal, schemeCategory10 } from 'd3-scale'; const colors = scaleOrdinal(schemeCategory10).range(); const data = [ { name: '18-24',...
test/TabSpec.js
dongtong/react-bootstrap
import React from 'react'; import ReactTestUtils from 'react/lib/ReactTestUtils'; import Tab from '../src/Tab'; describe('Tab', () => { it('Should have class', () => { let instance = ReactTestUtils.renderIntoDocument( <Tab>Item content</Tab> ); assert.ok(ReactTestUtils.findRenderedDOMComponentWithC...
pages/NoMatch/NoMatch.js
mikayel/react-cv
'use strict'; import React from 'react' import Header from '../../components/header/Header'; import Navigation from '../../components/navigation/Navigation'; import Footer from '../../components/footer/Footer'; const NoMatch = React.createClass({ render() { return <div className="page_no_match"> ...
src/components/header.js
dcporter44/tunefest-frontend
import React, { Component } from 'react'; import { connect } from 'react-redux'; import { signOut } from '../actions/auth_actions'; import { AppBar, Drawer, MenuItem } from 'material-ui'; import { browserHistory } from 'react-router'; class Header extends Component { constructor(props) { super(props); this.sta...
static/node_modules/react-router/es6/Lifecycle.js
unmeshpro/easyPost
import warning from './routerWarning'; import React from 'react'; import invariant from 'invariant'; var object = React.PropTypes.object; /** * The Lifecycle mixin adds the routerWillLeave lifecycle method to a * component that may be used to cancel a transition or prompt the user * for confirmation. * * On stan...
NavigationReactNative/sample/medley/App.js
grahammendick/navigation
import React from 'react'; import {StateNavigator} from 'navigation'; import {NavigationHandler} from 'navigation-react'; import {NavigationStack} from 'navigation-react-native'; import Direction from './Direction'; const stateNavigator = new StateNavigator([ {key: 'north', trackCrumbTrail: true}, {key: 'east', tr...
app/ui/components/Note/Note.js
Jberivera/electron-react-redux-boilerplate
import React from 'react'; import style from './Note.scss'; import classNames from 'classnames/bind'; const css = classNames.bind(style); const Note = ({ count, onClick }) => { return ( <h1 className={css('counter')} onClick={(e) =>{ onClick(); }}> Ready for start to apply react, redux using web...
test/components/Dashboard.spec.js
Raathigesh/Dazzle
import { expect } from 'chai'; import React from 'react'; import { mount } from 'enzyme'; import { default as Dashboard, DashboardWithoutDndContext as DashboardWithoutDndContext } from '../../lib/components/Dashboard'; import LayoutRenderer from '../../lib/components/LayoutRenderer'; describe('<Dashboard />', () => { ...
src/components/profile_page/main_profile_page/profile_events_component.js
decaster3/hikester_redux
import React from 'react'; import FontAwesome from 'react-fontawesome'; import { connect } from 'react-redux' import { bindActionCreators } from 'redux'; import { setMyEvents } from '../../../actions/profile/profile_settings_action' import { Link } from 'react-router-dom' class ProfileEventsComponent extends React.Comp...
src/TeamHeader/index.js
christianalfoni/ducky-components
import React from 'react'; import PropTypes from 'prop-types'; import classNames from 'classnames'; import styles from './styles.css'; import LabelPair from '../LabelPair'; import Typography from '../Typography'; import Icon from '../Icon'; function TeamHeader(props) { return ( <div className={classNames(styles...
test/social-icons.spec.js
AVVS/react-social-icons
/* global describe, it, beforeEach */ import 'should'; import React from 'react'; import Mask from '../src/mask'; import SocialIcon from '../src/social-icon'; import SocialIcons from '../src/social-icons'; import { mount } from 'enzyme'; describe('< SocialIcons />', () => { const urls = ['http://pinterest.com', 'ht...
src/index.js
joedelia/automount
import ReactDOM from 'react-dom'; import React from 'react'; import _ from 'lodash'; import {toCamelCase} from './case-convert'; const components = {}, mountedComponents = {}, config = { camelCase: true, unmountRemovedComponents: true, defaultProps: {} }; export function _configure(newConfig) { _....
packages/flow-upgrade/src/upgrades/0.53.0/ReactComponentExplicitTypeArgs/__tests__/fixtures/PropsConstructor.js
mroch/flow
// @flow import React from 'react'; class MyComponent1 extends React.Component { constructor(props: Props) {} defaultProps: T; static props: T; static state: T; a: T; b = 5; c: T = 5; method() {} } class MyComponent2 extends React.Component { props: Props; constructor(props: Props) {} defaul...
src/svg-icons/maps/local-drink.js
ruifortes/material-ui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let MapsLocalDrink = (props) => ( <SvgIcon {...props}> <path d="M3 2l2.01 18.23C5.13 21.23 5.97 22 7 22h10c1.03 0 1.87-.77 1.99-1.77L21 2H3zm9 17c-1.66 0-3-1.34-3-3 0-2 3-5.4 3-5.4s3 3.4 3 5.4c0 1.66-1.34 3-3 3zm6....
node_modules/react-router/es6/RouteContext.js
Karthik9321/ReduxSimpleStarter
import warning from './routerWarning'; import React from 'react'; var object = React.PropTypes.object; /** * The RouteContext mixin provides a convenient way for route * components to set the route in context. This is needed for * routes that render elements that want to use the Lifecycle * mixin to prevent trans...
demo/Gossip/app.js
recharts/reanimate
import Animate from 'react-smooth'; import React, { Component } from 'react'; import ReactDom from 'react-dom'; const getSTEPS = onAnimationEnd => [{ duration: 1000, style: { opacity: 0, }, }, { duration: 1000, style: { opacity: 1, transformOrigin: '110px 110px', transform: 'rotate(0deg) tran...
fields/types/url/UrlColumn.js
frontyard/keystone
import React from 'react'; import ItemsTableCell from '../../components/ItemsTableCell'; import ItemsTableValue from '../../components/ItemsTableValue'; var UrlColumn = React.createClass({ displayName: 'UrlColumn', propTypes: { col: React.PropTypes.object, data: React.PropTypes.object, }, renderValue () { va...
CompositeUi/src/views/component/Thumbnail.js
kreta/kreta
/* * This file is part of the Kreta package. * * (c) Beñat Espiña <benatespina@gmail.com> * (c) Gorka Laucirica <gorka.lauzirika@gmail.com> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ import './../../scss/components/_thumbnai...
packages/cf-component-icon/src/Icon.js
jroyal/cf-ui
import React from 'react'; import PropTypes from 'prop-types'; import SVG_COMPONENTS from './reactsvgs'; import { createComponent } from 'cf-style-container'; const DEFAULT_HEIGHT = 15; const getHeight = size => { let height; switch (size) { case '1.5x': height = 22; break; case '2x': h...
react-jss/button.js
MicheleBertoli/css-in-js
import './jss'; import React from 'react'; import useSheet from 'react-jss'; const styles = { container: { textAlign: 'center' }, button: { backgroundColor: '#ff0000', width: 320, padding: 20, borderRadius: 5, border: 'none', outline: 'none', '&:hover': { color: '#fff' }...
src/components/app/Component.js
fedebertolini/uno-score-tracker
import React from 'react'; import { Router, Route, hashHistory } from 'react-router'; import GameCreationContainer from '../gameCreation/Container'; import RoundTableContainer from '../roundTable/Container'; import RoundCreationContainer from '../roundCreation/Container'; require('./style.scss'); const App = () => ( ...
packages/reactor-kitchensink/src/examples/Charts/Gauge/BasicGaugeChart/BasicGaugeChart.js
markbrocato/extjs-reactor
import React, { Component } from 'react'; import { Container, Panel } from '@extjs/ext-react'; import { Polar } from '@extjs/ext-react-charts'; import createData from './createData'; import ChartToolbar from '../../ChartToolbar'; Ext.require([ 'Ext.chart.series.Gauge' ]); export default class BasicGaugeChartExamp...
src/containers/Directory/Directory.js
YouYII/EasyReader
//@flow import React from 'react'; import { View, InteractionManager, Dimensions, Platform, Alert, } from 'react-native'; import {Actions} from 'react-native-router-flux'; import Spinner from 'react-native-spinkit'; import { Container, Navbar } from 'navbar-native'; import { connect } from 'react-redux'; imp...
docs/app/Examples/modules/Accordion/Types/AccordionExampleStyled.js
koenvg/Semantic-UI-React
import _ from 'lodash' import faker from 'faker' import React from 'react' import { Accordion } from 'semantic-ui-react' const panels = _.times(3, () => ({ title: faker.lorem.sentence(), content: faker.lorem.paragraphs(), })) const AccordionExampleStyled = () => ( <Accordion panels={panels} styled /> ) export ...
node_modules/native-base/src/basic/Text.js
tausifmuzaffar/bisApp
import React, { Component } from 'react'; import { Text as RNText } from 'react-native'; import { connectStyle } from '@shoutem/theme'; import { connectAnimation } from '@shoutem/animation'; import mapPropsToStyleNames from '../Utils/mapPropsToStyleNames'; class Text extends Component { render() { return ( ...
react-flux-mui/js/material-ui/src/svg-icons/hardware/watch.js
pbogdan/react-flux-mui
import React from 'react'; import pure from 'recompose/pure'; import SvgIcon from '../../SvgIcon'; let HardwareWatch = (props) => ( <SvgIcon {...props}> <path d="M20 12c0-2.54-1.19-4.81-3.04-6.27L16 0H8l-.95 5.73C5.19 7.19 4 9.45 4 12s1.19 4.81 3.05 6.27L8 24h8l.96-5.73C18.81 16.81 20 14.54 20 12zM6 12c0-3.31 2....
public/components/MainPage.js
ranebo/project-ipsum
import React from 'react'; import actions from '../actions/ipsumActions.js'; import { browserHistory } from 'react-router'; import { connect } from 'react-redux'; import maps from '../mappingFunctions.js'; import restHandler from '../util/restHelpers.js'; import MainPageAppView from './MainPageAppView.js'; import { Gri...
src/components/Partials/Main4.js
luanlv/comhoavang
import React from 'react' import FacebookProvider, { Comments } from 'react-facebook'; import history from '../../core/history' function isLeftClickEvent(event) { return event.button === 0; } function isModifiedEvent(event) { return !!(event.metaKey || event.altKey || event.ctrlKey || event.shiftKey); } function...
examples/forms-bootstrap/src/components/dialogs-destroy-wizard/Layout.js
lore/lore-forms
import React from 'react'; import createReactClass from 'create-react-class'; import PropTypes from 'prop-types'; import Hook from './Hook'; import hookCode from '!raw-loader!./Hook'; export default lore.connect(function(getState, props) { const { tweetId } = props.params; return { tweet: getState('tweet.byId...
src/pages/index.js
JTRiddick/jtr-webzone
import React from 'react'; import Link from 'gatsby-link'; import SuperHeader from '../components/SuperHeader.js'; import Portfolio from '../components/Portfolio.js'; import '../assets/scss/style.scss'; const IndexPage = ({data}) => { // console.log('data ', data); return( <main className="page-container"...
src/components/AddAppointment/components/AppointmentClient/AppointmentClient.js
TheModevShop/craft-app
import React from 'react'; import _ from 'lodash'; // import Select from 'react-select'; import {Creatable} from 'react-select'; import './appointment-client.less'; class AppointmentClient extends React.Component { constructor(...args) { super(...args); this.state = {}; } render() { const clients =...
src/renderer/components/add-archive-button.js
buttercup-pw/buttercup
import React from 'react'; import PropTypes from 'prop-types'; import { translate } from 'react-i18next'; import { Button } from '@buttercup/ui'; import { MdAdd as ArchiveIcon } from 'react-icons/md'; import { showContextMenu } from '../system/menu'; import { getShortcutByKey } from '../../shared/utils/global-shortcuts...
frontend/casesearch/Container.js
datoszs/czech-lawyers
import React from 'react'; import {Panel} from 'react-bootstrap'; import {Msg} from '../containers'; import {SearchStatus, PageTitle} from '../containers/search'; import {search} from './modules'; import SearchContainer from './SearchContainer'; import ResultsContainer from './ResultsContainer'; import CurrentSearch fr...
src/components/old/RowData.js
yabadabu/react-playground
import React from 'react'; import CompFormText from './form/CompFormText'; export default class RowData extends React.Component { // Only if the immutable has change we re-render shouldComponentUpdate(nextProps, nextState) { var render_it = this.props.values !== nextProps.values; if( render_it ) console...
src/components/SendScreen.js
atixlabs/atm-mobileapp
import React from 'react'; import { StyleSheet, Alert, } from 'react-native'; import { Container, Content, Card, CardItem, Text, Body, Button, Item, ListItem, Icon, } from 'native-base'; import Constants from './Constants'; import WalletService from '../services/WalletService'; const SendScre...