path stringlengths 5 304 | repo_name stringlengths 6 79 | content stringlengths 27 1.05M |
|---|---|---|
tests/routes/Home/components/HomeView.spec.js | rwade628/react-redux-starter-kit | import React from 'react'
import { HomeView } from 'routes/Home/components/HomeView'
import { render } from 'enzyme'
describe('(View) Home', () => {
let _component
beforeEach(() => {
_component = render(<HomeView />)
})
it('Renders a welcome message', () => {
const welcome = _component.find('h4')
... |
internal/scripts/preinstall.js | dariobanfi/react-avocado-starter | /**
* This script will ensure that users are using a supported version of node
* for the project.
*
* NOTE: Ensure this script uses ES5 only as the user may be running an old
* version of Node, which this script wants to test against.
*/
/* eslint-disable */
var exec = require('child_process').exec;
var existsS... |
app/routes/components/WeiXinShareTips/index.js | bugknightyyp/leyizhu | import React from 'react'
import {observer} from 'mobx-react'
import './weiXinShareTips.less'
export default observer(
(props) => (
(
<div className="wxshare-component" onClick={props.onClick}>
<i className="iconfont icon-live_icon_share" />
<div className="tips">点击右上角<br />分享给你的好... |
actor-apps/app-web/src/app/components/modals/CreateGroup.react.js | chenbk85/actor-platform | import React from 'react';
import CreateGroupActionCreators from 'actions/CreateGroupActionCreators';
import CreateGroupStore from 'stores/CreateGroupStore';
import CreateGroupForm from './create-group/Form.react';
import Modal from 'react-modal';
import { KeyCodes } from 'constants/ActorAppConstants';
const appEl... |
presentation/examples/with-react-router/client/routes.js | iansinnott/react-static-presentation | import React from 'react';
import { Route, IndexRoute } from 'react-router';
import { App, Home, NotFound } from './components/App.js';
import { About } from './components/About.js';
export const routes = (
<Route path='/' title='App' component={App}>
<IndexRoute component={Home} />
<Route path='about' comp... |
docs/app/Examples/elements/Rail/Types/RailExampleRail.js | aabustamante/Semantic-UI-React | import React from 'react'
import { Grid, Image, Rail, Segment } from 'semantic-ui-react'
const RailExampleRail = () => (
<Grid centered columns={3}>
<Grid.Column>
<Segment>
<Image src='/assets/images/wireframe/paragraph.png' />
<Rail position='left'>
<Segment>Left Rail Content</S... |
packages/material-ui-icons/src/LocalTaxiSharp.js | kybarg/material-ui | import React from 'react';
import createSvgIcon from './utils/createSvgIcon';
export default createSvgIcon(
<path d="M18.58 5H15V3H9v2H5.43L3 12v9h3v-2h12v2h3v-9l-2.42-7zM6.5 16c-.83 0-1.5-.67-1.5-1.5S5.67 13 6.5 13s1.5.67 1.5 1.5S7.33 16 6.5 16zm11 0c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5... |
actor-apps/app-web/src/app/components/sidebar/HeaderSection.react.js | cnbin/actor-platform | import _ from 'lodash';
import React from 'react';
import mixpanel from 'utils/Mixpanel';
import ReactMixin from 'react-mixin';
import { IntlMixin, FormattedMessage } from 'react-intl';
import classNames from 'classnames';
import MyProfileActions from 'actions/MyProfileActions';
import LoginActionCreators from 'action... |
js/jquery.min.js | CoughDrop/coughdrop.github.io | /*! jQuery v1.11.3 | (c) 2005, 2015 jQuery Foundation, Inc. | jquery.org/license */
!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof wind... |
src/examples/todomvc/client.js | z81/moonlight | import React from 'react';
import ReactDOM from 'react-dom';
import schema from './schema';
import MoonLight from '../../client/component';
import 'todomvc-common/base.css';
import 'todomvc-app-css/index.css';
const filters = {
All: item => true,
Active: item => !item.done,
Completed: item => item.done
};
... |
src/components/app.js | xingjianpan/react-redux-news-reader | import React, { Component } from 'react';
// relative import
import Header from './Header';
export default class App extends Component {
render() {
return (
<div>
<Header />
{this.props.children}
</div>
);
}
}
|
src/components/common/Spinner.js | ChenLi0830/RN-Auth | import React from 'react';
import { View, ActivityIndicator } from 'react-native';
const Spinner = ({ size = 'large' }) => {
return (
<View style={styles.spinnerStyle}>
<ActivityIndicator size={size} />
</View>
);
};
const styles = {
spinnerStyle: {
flex: 1,
justifyContent: 'center',... |
src/server.js | stan-kondrat/test-work-for-storia | /*! React Starter Kit | MIT License | http://www.reactstarterkit.com/ */
import 'babel-core/polyfill';
import path from 'path';
import express from 'express';
import React from 'react';
import ReactDOM from 'react-dom/server';
import Router from './routes';
import Html from './components/Html';
const server = global.... |
src/components/JoinChannel.js | orbitdb/orbit-web | 'use strict'
import React from 'react'
import PropTypes from 'prop-types'
import { useTranslation } from 'react-i18next'
import '../styles/JoinChannel.scss'
function JoinChannel ({ onSubmit, theme, inputRef }) {
const [t] = useTranslation()
return (
<div className='JoinChannel'>
<form onSubmit={onSubmi... |
FourStage-Es6/node_modules/babel-preset-es2015/node_modules/babel-plugin-transform-es2015-arrow-functions/node_modules/babel-runtime/node_modules/core-js/client/library.js | ColinLoveLucky/UIApplication | /**
* core-js 2.5.0
* https://github.com/zloirock/core-js
* License: http://rock.mit-license.org
* © 2017 Denis Pushkarev
*/
!function(__e, __g, undefined){
'use strict';
/******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/
/******/ // The r... |
web/static/js/index.js | josephyi/hextech | // Phoenix' dependencies
import '../../../deps/phoenix/priv/static/phoenix'
import '../../../deps/phoenix_html/priv/static/phoenix_html'
// Shiny new, hot React component
import React from 'react'
import { render } from 'react-dom'
import { browserHistory } from 'react-router'
import { syncHistoryWithStore } from 'rea... |
node_modules/react-icons/ti/arrow-loop-outline.js | bengimbel/Solstice-React-Contacts-Project |
import React from 'react'
import Icon from 'react-icon-base'
const TiArrowLoopOutline = props => (
<Icon viewBox="0 0 40 40" {...props}>
<g><path d="m31.7 12c0-0.1 0-0.2 0-0.3 0-1.4-0.6-2.6-1.5-3.6-0.9-0.9-2.2-1.4-3.5-1.4s-2.6 0.5-3.6 1.4l-4.8 4.8c-0.9-0.8-2-1.2-3.3-1.2h-1.7c-6.4 0-11.6 5.2-11.6 11.6s5.2 ... |
client/src/components/settings/SolutionViewer.js | BhaveshSGupta/FreeCodeCamp | import React from 'react';
import PropTypes from 'prop-types';
import { Panel } from '@freecodecamp/react-bootstrap';
import Prism from 'prismjs';
import Helmet from 'react-helmet';
import './solution-viewer.css';
const prismLang = {
css: 'css',
js: 'javascript',
jsx: 'javascript',
html: 'markup'
};
function... |
ajax/libs/backbone.radio/0.2.0/backbone.radio.js | jasonpang/cdnjs | // Backbone.Radio v0.1.0
(function(root, factory) {
if (typeof define === 'function' && define.amd) {
define(['backbone', 'underscore'], function(Backbone, _) {
return factory(Backbone, _);
});
}
else if (typeof exports !== 'undefined') {
var Backbone = require('backbone');
var _ = require('... |
examples/todos-with-undo/src/components/App.js | heyesther/redux | import React from 'react'
import Footer from './Footer'
import AddTodo from '../containers/AddTodo'
import VisibleTodoList from '../containers/VisibleTodoList'
import UndoRedo from '../containers/UndoRedo'
const App = () => (
<div>
<AddTodo />
<VisibleTodoList />
<Footer />
<UndoRedo />
</div>
)
e... |
examples/basic/src/index.js | calvinrbnspiess/react-static | import React from 'react'
import ReactDOM from 'react-dom'
import { AppContainer } from 'react-hot-loader'
// Your top level component
import App from './App'
// Export your top level component as JSX (for static rendering)
export default App
// Render your app
if (typeof document !== 'undefined') {
const render =... |
src/components/Settings/ReciterDropdown/index.js | hasibsahibzada/quran.com-frontend | import React, { Component } from 'react';
import * as customPropTypes from 'customPropTypes';
import { connect } from 'react-redux';
import Menu, { MenuItem } from 'quran-components/lib/Menu';
import Radio from 'quran-components/lib/Radio';
import Loader from 'quran-components/lib/Loader';
import Icon from 'quran-compo... |
node_modules/react-icons/go/file-zip.js | bairrada97/festival |
import React from 'react'
import Icon from 'react-icon-base'
const GoFileZip = props => (
<Icon viewBox="0 0 40 40" {...props}>
<g><path d="m17.5 22.5v-2.5h-2.5v2.5h2.5z m0-5v-2.5h-2.5v2.5h2.5z m0-5v-2.5h-2.5v2.5h2.5z m-5 2.5h2.5v-2.5h-2.5v2.5z m15-12.5h-22.5v35h30v-27.5l-7.5-7.5z m5 32.5h-25v-30h7.5v2.5h... |
src/components/Game.js | mrholeechit/react-chess | import React, { Component } from 'react';
import { object, node } from 'prop-types';
import { Provider } from 'react-redux';
import Board from './Board';
import Header from './Header';
export default class Game extends Component {
render() {
const { store } = this.props;
console.log(store.getState());
... |
ajax/libs/draft-js/0.6.0/Draft.js | dc-js/cdnjs | /**
* Draft v0.6.0
*
* Copyright (c) 2013-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 directo... |
app/common/components/SentencePair/MarkedSentence/index.js | Kaniwani/KW-Frontend | import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import splitSentenceByMatch from 'common/utils/splitSentenceByMatch';
import A from 'common/components/A';
import { Sentence, VocabMark } from './styles';
MarkedSentence.propTypes = {
sentence: PropTypes.string.isR... |
src/svg-icons/image/filter-center-focus.js | pradel/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageFilterCenterFocus = (props) => (
<SvgIcon {...props}>
<path d="M5 15H3v4c0 1.1.9 2 2 2h4v-2H5v-4zM5 5h4V3H5c-1.1 0-2 .9-2 2v4h2V5zm14-2h-4v2h4v4h2V5c0-1.1-.9-2-2-2zm0 16h-4v2h4c1.1 0 2-.9 2-2v-4h-2v4zM12 9... |
ajax/libs/6to5/3.2.1/browser.js | Download/cdnjs | !function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.to5=e()}}(function(){var define,module,exports;return... |
client/src/components/Profile/deleteProfileModal.js | Velocies/raptor-ads | import React from 'react';
import { Button, Header, Modal } from 'semantic-ui-react';
const DeleteProfileModal = ({onDeleteClick}) =>
<Modal
trigger={
<Button
className="ui red right floated button"
type="button"
>
Delete Profile
</Button>
}
>
<Header icon="trash... |
src/cells/Cell.js | itsolutions-dev/react-tablify | // @flow
import React from 'react';
export default class Cell extends React.Component {
static defaultProps = {
component: 'td',
};
props: {
component: string | Function,
data: any,
field: number | string,
onCreate: any => any,
children: any
};
render() {
const {
componen... |
lib/controllers/reviews-controller.js | atom/github | import React from 'react';
import path from 'path';
import PropTypes from 'prop-types';
import {createFragmentContainer, graphql} from 'react-relay';
import {RemoteSetPropType, BranchSetPropType, EndpointPropType, WorkdirContextPoolPropType} from '../prop-types';
import ReviewsView from '../views/reviews-view';
import... |
src/js/root.js | cheriejiajia/react-seed | import React from 'react';
import { render } from 'react-dom';
import { Router, Route, hashHistory, IndexRoute } from 'react-router';
import App from './components/app';
import Main from './components/main';
import Detail from './components/detail';
let router = (
<Router history={hashHistory}>
<Route path="/" c... |
ajax/libs/ionic-framework/2.0.0-alpha.42/ionic.js | Amomo/cdnjs | module.exports =
/******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId])
/******/ ret... |
components/admin/PageLayoutForm.js | BanManagement/BanManager-WebUI | import { useEffect, useMemo, useState } from 'react'
import GridLayout from 'react-grid-layout'
import { find, maxBy, pick } from 'lodash-es'
import ErrorMessages from '../ErrorMessages'
import PageHeader from '../PageHeader'
import Button from '../Button'
import { breakpoints } from '../Media'
import { useMutateApi } ... |
src/components/Navigation/Navigation.js | fvalencia/react-vimeo | /**
* 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 cx from 'classnames';... |
ajax/libs/angular.js/0.9.18/angular-scenario.js | barkinet/cdnjs | /*!
* jQuery JavaScript Library v1.4.2
* http://jquery.com/
*
* Copyright 2010, John Resig
* Dual licensed under the MIT or GPL Version 2 licenses.
* http://jquery.org/license
*
* Includes Sizzle.js
* http://sizzlejs.com/
* Copyright 2010, The Dojo Foundation
* Released under the MIT, BSD, and GPL Licenses.
... |
packages/material-ui-icons/src/AirlineSeatReclineNormal.js | kybarg/material-ui | import React from 'react';
import createSvgIcon from './utils/createSvgIcon';
export default createSvgIcon(
<path d="M7.59 5.41c-.78-.78-.78-2.05 0-2.83.78-.78 2.05-.78 2.83 0 .78.78.78 2.05 0 2.83-.79.79-2.05.79-2.83 0zM6 16V7H4v9c0 2.76 2.24 5 5 5h6v-2H9c-1.66 0-3-1.34-3-3zm14 4.07L14.93 15H11.5v-3.68c1.4 1.15 3.6... |
ajax/libs/react-data-grid/0.13.16/react-data-grid.min.js | seogi1004/cdnjs | !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react")):"function"==typeof define&&define.amd?define(["react"],t):"object"==typeof exports?exports.ReactDataGrid=t(require("react")):e.ReactDataGrid=t(e.React)}(this,function(e){return function(e){function t(o){if(r[o])return r[... |
src/Menu/index.js | reactivers/react-material-design | /**
* Created by Utku on 27/03/2017.
*/
import React from 'react';
import PropTypes from 'prop-types';
import '@material/menu/dist/mdc.menu.css'
import {MDCSimpleMenu} from '@material/menu/dist/mdc.menu';
import classNames from 'classnames';
import '../index.scss';
export class MenuItem extends React.PureComponent {... |
src/smif/app/src/components/ConfigForm/General/Buttons.js | tomalrussell/smif | import React from 'react'
import PropTypes from 'prop-types'
/**
* SuccessButton
*
* Primary button
*/
const SuccessButton = (props) => (
<input
id={props.id}
className="btn btn-success btn-margin"
type="button"
value={props.value}
onClick={props.onClick} />
)
SuccessBu... |
app/javascript/mastodon/features/account_timeline/index.js | kazh98/social.arnip.org | import React from 'react';
import { connect } from 'react-redux';
import ImmutablePropTypes from 'react-immutable-proptypes';
import PropTypes from 'prop-types';
import { fetchAccount } from '../../actions/accounts';
import { expandAccountFeaturedTimeline, expandAccountTimeline } from '../../actions/timelines';
import ... |
src/client/components/test/list.js | adamgruber/mochawesome-report-generator | import React from 'react';
import PropTypes from 'prop-types';
import { Test } from 'components/test';
import classNames from 'classnames/bind';
import styles from './test.css';
const cx = classNames.bind(styles);
const TestList = ({
className,
tests,
beforeHooks,
afterHooks,
enableCode,
}) => (
<ul class... |
react-ui/src/components/Course/Video.js | michaelcheng429/bestactprep | import React from 'react';
import { Link } from 'react-router-dom';
import css from 'classnames';
export class VideoSection extends React.Component {
constructor(props) {
super(props);
this.state = {
showVideo: false
};
this.showVideo = this.showVideo.bind(this);
}... |
EventEmitter.Client/src/routes/WhiteList/components/WhiteListView.js | Stelmashenko-A/EventEmitter | import React from 'react'
import { DataTable, TableHeader, Button, Textfield } from 'react-mdl'
import UserLoader from '../../../components/UserLoader'
import './WhiteListView.scss'
export const WhiteListView = (props) => (
<div className='whiteList'>
<div className='wrapper'>
<h1 className='eventName'>{pr... |
generators/component/templates/Component.js | gmmendezp/generator-nyssa-fe | import React, { Component } from 'react';
import { translate } from 'react-i18next';
import { style } from 'typestyle';<% if (container){%>
import { connect } from 'react-redux';<% } %>
export class <%= name %> extends Component {
static defaultProps = {
styles: {}
}
constructor() {
super();
this.st... |
src/components/Nav/__tests__/Nav.spec.js | thangngoc89/react-code-playground | import React from 'react'
import $ from 'teaspoon'
import Nav from '../Nav'
import Tab from '../Tab'
import styles from '../Nav.scss'
const render = props => $(<Nav {...props} />).render()
const shallowRender = props => $(<Nav {...props} />).shallowRender()
describe('(component) Nav', () => {
describe('Nav', () => ... |
js/src/dapps/localtx/Application/application.js | immartian/musicoin | // Copyright 2015, 2016 Parity Technologies (UK) Ltd.
// This file is part of Parity.
// Parity is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any la... |
src/app/components/ParsedText.js | meedan/check-web | import React from 'react';
import Linkify from 'react-linkify';
import { toArray } from 'react-emoji-render';
import PropTypes from 'prop-types';
import styled from 'styled-components';
import reactStringReplace from 'react-string-replace';
import { units } from '../styles/js/shared';
const StyledEmojiOnly = styled.sp... |
src/containers/Articles/NewArticlePage/NewArticlePage.js | ReactPoland/react-community | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import _isEmpty from 'lodash/isEmpty';
import { slate } from 'utils';
// STORE
import { addArticle } from 'redux/modules/articlesModule';
// COMPONENTS
import { PlainTextEditor, RichTextEditor } from 'co... |
ajax/libs/rxjs/2.3.24/rx.lite.js | jmusicc/cdnjs | // Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. See License.txt in the project root for license information.
;(function (undefined) {
var objectTypes = {
'boolean': false,
'function': true,
'object': true,
'number': false,
'string': false,
'undefined': false... |
src/svg-icons/action/account-box.js | spiermar/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionAccountBox = (props) => (
<SvgIcon {...props}>
<path d="M3 5v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2H5c-1.11 0-2 .9-2 2zm12 4c0 1.66-1.34 3-3 3s-3-1.34-3-3 1.34-3 3-3 3 1.34 3 3zm-9 8c0-2 4-3... |
ajax/libs/react/0.12.1/react-with-addons.min.js | brix/cdnjs | /**
* React (with addons) v0.12.1
*
* Copyright 2013-2014, 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... |
yycomponent/header/Child.js | 77ircloud/yycomponent | import React from 'react';
import StaticContainer from './StaticContainer';
class Child extends React.Component {
render() {
const { children } = this.props;
return <div className="header-container-item-container">
<StaticContainer shouldUpdate={true}>
{children}
</StaticContainer>
... |
public/src/components/app.js | agnieszkabugla/React-Movie-Project | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';
import { fetchMovies, getInitialPage, getMovieDetails } from '../actions/index';
import SearchBar from '../containers/search_bar';
import MovieList from '... |
src/views/SettingsView.js | orbitdb/orbit-web | 'use strict'
import React from 'react'
import { hot } from 'react-hot-loader'
import { useObserver } from 'mobx-react'
import { useTranslation } from 'react-i18next'
import settingsOptions from '../config/setting.options.json'
import locales from '../locales'
import themes from '../themes'
import RootContext from '... |
src/components/MyCircleChart.js | codingInSpace/nordic-bikes | import React from 'react';
import AnnotatedMeter from 'grommet-addons/components/AnnotatedMeter';
class MyCircleChart extends React.Component {
render() {
return (
<AnnotatedMeter legend={true}
type="circle"
units="options"
size="medium"
max={ this.props.op... |
django/webcode/webcode/frontend/node_modules/create-react-class/create-react-class.js | OpenKGB/webcode | (function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory(require("react"));
else if(typeof define === 'function' && define.amd)
define(["react"], factory);
else if(typeof exports === 'object')
exports["createReactClass"] ... |
client/App/Competitions/index.js | JohannesAnd/SKWebsite | import React from 'react';
import { connect } from '@cerebral/react';
import { state, sequences } from 'cerebral';
import {
Wrapper,
CompetitionCard,
CardContainer,
SectionHeader,
NewCompetitionCard,
NotLoggedIn,
} from './elements';
import UserLanguage from 'common/UserLanguage';
const dependencies = {
... |
components/CounterApp/CounterApp.js | thiagodebastos/react-future-stack | // @flow
import React from 'react';
import Button from '../Button';
type Props = {
counterApp: {
count: number
},
increment: CounterAction,
decrement: CounterAction
};
const Counter = (props: Props) =>
<div>
Counter: {props.counterApp.count} <br />
<Button onClick={props.increment} primary> + </... |
ajax/libs/angular.js/0.10.1/angular.js | DinhAnhTu/cdnjs | /**
* @license AngularJS v0.10.1
* (c) 2010-2011 AngularJS http://angularjs.org
* License: MIT
*/
'use strict';
(function(window, document, undefined){
////////////////////////////////////
if (typeof document.getAttribute == $undefined)
document.getAttribute = function() {};
/**
* @ngdoc function
* @name ang... |
actor-apps/app-web/src/app/components/modals/Contacts.react.js | hzy87email/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... |
02_ReactIntroduction/Code/start/app/components/Store.js | joacoleonelli/react-zerotohero | import React from 'react';
import PureRenderMixin from 'react-addons-pure-render-mixin';
import autoBind from 'react-autobind';
class Store extends React.Component {
constructor(props) {
super(props);
autoBind(this);
this.shouldComponentUpdate = PureRenderMixin.shouldComponentUpdate.bind(this);
}
... |
app/components/PlaceModal/index.js | GuiaLa/guiala-web-app | /**
*
* PlaceModal
*
*/
import React from 'react';
import {
Step,
Stepper,
StepLabel,
} from 'material-ui/Stepper';
import { Tabs, Tab } from 'material-ui/Tabs';
import Dialog from 'material-ui/Dialog';
import FlatButton from 'material-ui/FlatButton';
import SelectField from 'material-ui/SelectField';
import Me... |
ajax/libs/forerunnerdb/1.3.832/fdb-core+persist.min.js | nolsherry/cdnjs | !function a(b,c,d){function e(g,h){if(!c[g]){if(!b[g]){var i="function"==typeof require&&require;if(!h&&i)return i(g,!0);if(f)return f(g,!0);var j=new Error("Cannot find module '"+g+"'");throw j.code="MODULE_NOT_FOUND",j}var k=c[g]={exports:{}};b[g][0].call(k.exports,function(a){var c=b[g][1][a];return e(c?c:a)},k,k.ex... |
js/jquery-1.12.0.min.js | xiazemin/MyBlog | /*! jQuery v1.12.0 | (c) jQuery Foundation | jquery.org/license */
!function(a,b){"object"==typeof module&&"object"==typeof module.exports?module.exports=a.document?b(a,!0):function(a){if(!a.document)throw new Error("jQuery requires a window with a document");return b(a)}:b(a)}("undefined"!=typeof window?window:this,fu... |
docs/src/app/components/pages/components/IconButton/ExampleTouch.js | hai-cea/material-ui | import React from 'react';
import IconButton from 'material-ui/IconButton';
import ActionGrade from 'material-ui/svg-icons/action/grade';
const IconButtonExampleTouch = () => (
<div>
<IconButton tooltip="bottom-right" touch={true} tooltipPosition="bottom-right">
<ActionGrade />
</IconButton>
<IconB... |
src/views/tutorial.js | lijunle/depcheck-web | import React from 'react';
import markdown from 'marked';
import Navbar from './navbar';
import Layout from './layout';
export default React.createClass({
render() {
return (
<Layout>
<h1 className="text-center">Tutorial</h1>
<Navbar {...this.props} />
<div className="row">
... |
test/test-cases/public-path/src/render.js | seek-oss/sku | import React from 'react';
import { renderToString } from 'react-dom/server';
import dedent from 'dedent';
import App from './app';
export default {
renderApp: ({ SkuProvider }) =>
renderToString(
<SkuProvider>
<App />
</SkuProvider>,
),
renderDocument: ({ app, bodyTags, headTags }) => ... |
test/App.spec.js | cognicreative/cognicreative-website | import React from 'react';
import expect from 'expect';
import { shallow } from 'enzyme';
import App from '../src/components/App';
describe('Component: App', () => {
it('should render the App component', () => {
const wrapper = shallow(
<App name="World" />
);
expect(wrapper.find('h1').text()).to... |
components/table/Table.js | soyjavi/react-toolbox | import React, { Component, PropTypes } from 'react';
import classnames from 'classnames';
import { themr } from 'react-css-themr';
import { TABLE } from '../identifiers.js';
import InjectCheckbox from '../checkbox/Checkbox.js';
import tableHeadFactory from './TableHead.js';
import tableRowFactory from './TableRow.js';
... |
src/svg-icons/image/style.js | hwo411/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageStyle = (props) => (
<SvgIcon {...props}>
<path d="M2.53 19.65l1.34.56v-9.03l-2.43 5.86c-.41 1.02.08 2.19 1.09 2.61zm19.5-3.7L17.07 3.98c-.31-.75-1.04-1.21-1.81-1.23-.26 0-.53.04-.79.15L7.1 5.95c-.75.31-1.... |
example/screens/FirstView.js | hlz2103/SwipeMe | import React from 'react';
import {
StyleSheet,
View,
Text,
Dimensions,
TouchableHighlight
} from 'react-native';
import CardHolderMap from './CardHolderMap.js';
import NeedASwipe from './NeedASwipe.js';
class FirstView extends React.Component{
render(){
return(
<View style={{flex:1... |
Examples/UIExplorer/ImageCapInsetsExample.js | shinate/react-native | /**
* The examples provided by Facebook are for non-commercial testing and
* evaluation purposes only.
*
* Facebook reserves all rights not expressly granted.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
* OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
... |
src/containers/misc/NotFound.js | c764023940/reactDemo | import React, { Component } from 'react';
export default class NotFound extends Component {
render() {
return (
<div className="container">
<h1>404!</h1>
<p>Oops, no such page exists.</p>
</div>
);
}
}
|
packages/xo-web/src/xo-app/backup/file-restore/index.js | vatesfr/xo-web | import _ from 'intl'
import ActionButton from 'action-button'
import Component from 'base-component'
import Icon from 'icon'
import React from 'react'
import SortedTable from 'sorted-table'
import Upgrade from 'xoa-upgrade'
import { addSubscriptions, noop } from 'utils'
import { confirm } from 'modal'
import { error } ... |
app/components/AddCategory/index.js | trevornelson/wld-frontend | /**
*
* AddCategory
*
*/
import React, { PropTypes } from 'react';
import { bind } from 'lodash';
import styled from 'styled-components';
import InputLabel from 'components/InputLabel';
import TextInput from 'components/TextInput';
const Wrapper = styled.div`
width: 75%;
margin: 10px auto;
`;
class AddCategory ... |
client/src/transforms/TreeDropdownField/moveTreeDropdownField.js | open-sausages/silverstripe-asset-admin | import React from 'react';
import { connect } from 'react-redux';
import { compose } from 'redux';
import { findTreeByPath } from 'components/TreeDropdownField/TreeDropdownField';
/**
* Enables a treepdropdown field to have individually disabled items
*/
const disabledTreeDropdownField = (TreeDropdownField) => (prop... |
node_modules/react-bootstrap/es/ModalHeader.js | caughtclean/but-thats-wrong-blog | 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 ... |
ajax/libs/intl-tel-input/6.0.0/js/intlTelInput.js | itvsai/cdnjs | /*
International Telephone Input v6.0.0
https://github.com/Bluefieldscom/intl-tel-input.git
*/
// wrap in UMD - see https://github.com/umdjs/umd/blob/master/jqueryPlugin.js
(function(factory) {
if (typeof define === "function" && define.amd) {
define([ "jquery" ], function($) {
factory($, window... |
packages/ddp-client/livedata_connection.js | steedos/meteor | if (Meteor.isServer) {
var path = Npm.require('path');
var Fiber = Npm.require('fibers');
var Future = Npm.require(path.join('fibers', 'future'));
}
// @param url {String|Object} URL to Meteor app,
// or an object as a test hook (see code)
// Options:
// reloadWithOutstanding: is it OK to reload if there are... |
example/__tests__/index.android.js | georgest/react-native-select-list | 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/applications/static-pages/health-care-manage-benefits/schedule-view-va-appointments-page/components/AuthContent/index.js | department-of-veterans-affairs/vets-website | // Node modules.
import React from 'react';
import PropTypes from 'prop-types';
// Relative imports.
import CernerCallToAction from '../../../components/CernerCallToAction';
import MoreInfoAboutBenefits from '../../../components/MoreInfoAboutBenefits';
import { appointmentsToolLink, getCernerURL } from 'platform/utilit... |
src/components/DragList/DragList.js | Bandwidth/shared-components | import React from 'react';
import PropTypes from 'prop-types';
import get from 'extensions/themeGet';
import styled from 'styled-components';
import DragListItem from './DragListItem';
import DragContainer from 'components/DragContainer';
const StyledDiv = styled.div`
& > * + * {
margin-top: ${get('spacing.mediu... |
ajax/libs/reactive-coffee/0.0.1/reactive-coffee.js | hpneo/cdnjs | (function() {
var DepArray, DepCell, DepMgr, Depmap, Ev, MappedDepArray, ObsArray, ObsCell, ObsMap, RawHtml, Recorder, SrcArray, SrcCell, SrcMap, bind, depMgr, ev, events, lagBind, mkMap, mktag, mkuid, nextUid, popKey, recorder, rx, rxt, specialAttrs, tag, tags, _fn, _i, _len, _ref, _ref1, _ref2, _ref3,
__hasProp... |
package.js | ObelixSWE/monolith-sdk | /*
* Name : package.js
* Author: Nicolò Rigato
* Creation Date: 2017-07-24
* Description: package
*/
Package.describe({
name: 'monolith-sdk',
version: '0.0.1',
// Brief, one-line summary of the package.
summary: '',
// URL to the Git repository containing the source code for this package.
git: '',
// By d... |
src/svg-icons/device/battery-20.js | manchesergit/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let DeviceBattery20 = (props) => (
<SvgIcon {...props}>
<path d="M7 17v3.67C7 21.4 7.6 22 8.33 22h7.33c.74 0 1.34-.6 1.34-1.33V17H7z"/><path fillOpacity=".3" d="M17 5.33C17 4.6 16.4 4 15.67 4H14V2h-4v2H8.33C7.6 4 7... |
src/client/tests/components/home/hompage.spec.js | kingisaac95/docmanager | import React from 'react';
import expect from 'expect';
import { shallow } from 'enzyme';
import SignInForm from '../../../components/home/SignInForm';
import SignUpModal from '../../../components/modals/SignUpModal';
import { HomePage } from '../../../components/home/HomePage';
/**
* @function
* @returns {jsx} - ho... |
fields/types/embedly/EmbedlyField.js | riyadhalnur/keystone | import React from 'react';
import Field from '../Field';
import { FormField, FormInput } from 'elemental';
module.exports = Field.create({
displayName: 'EmbedlyField',
// always defers to renderValue; there is no form UI for this field
renderField () {
return this.renderValue();
},
renderValue (path, label, ... |
ajax/libs/forerunnerdb/1.3.905/fdb-core+persist.js | maruilian11/cdnjs | (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.ex... |
stories/Tile.js | propertybase/react-lds | import React from 'react';
import { storiesOf } from '@storybook/react';
import { NameValueList, Tile, IconButton, Icon, Avatar, Checkbox } from '../src';
const stories = storiesOf('Tile', module);
stories
.add('Default', () => (
<Tile
title={<a href="javascript:void(0)">Salesforce UX</a>}
titleText... |
ajax/libs/forerunnerdb/1.3.678/fdb-core+views.min.js | emmy41124/cdnjs | !function a(b,c,d){function e(g,h){if(!c[g]){if(!b[g]){var i="function"==typeof require&&require;if(!h&&i)return i(g,!0);if(f)return f(g,!0);var j=new Error("Cannot find module '"+g+"'");throw j.code="MODULE_NOT_FOUND",j}var k=c[g]={exports:{}};b[g][0].call(k.exports,function(a){var c=b[g][1][a];return e(c?c:a)},k,k.ex... |
examples/universal/client/index.js | tweinfeld/redux | import 'babel-core/polyfill';
import React from 'react';
import { Provider } from 'react-redux';
import configureStore from '../common/store/configureStore';
import App from '../common/containers/App';
const initialState = window.__INITIAL_STATE__;
const store = configureStore(initialState);
const rootElement = do... |
docs/components/Highlight.js | enjoylife/storybook | import hljs from 'highlight.js';
import PropTypes from 'prop-types';
import React from 'react';
import ReactDOM from 'react-dom';
class Highlight extends React.Component {
componentDidMount() {
this.highlightCode();
}
componentDidUpdate() {
this.highlightCode();
}
highlightCode() {
const domNod... |
src/components/sales_chart_x_axis.js | intrepion/hojberg-mastering-reactjs-tutorial | import React from 'react';
import moment from 'moment';
import { range } from 'underscore';
function getXTicks(num) {
const today = moment();
const earliest = today.clone().subtract(num, 'months');
return range(num).map((n) => {
return earliest.clone().add(n, 'months').format('MMM');
});
}
cla... |
packages/veritone-widgets/src/widgets/Table/story.js | veritone/veritone-sdk | import React from 'react';
import { storiesOf } from '@storybook/react';
import { action } from '@storybook/addon-actions';
import faker from 'faker';
import VeritoneApp from '../../shared/VeritoneApp';
import { TableWidget } from './';
import { startCase, upperCase, map, flow, truncate, range } from 'lodash';
const ... |
src/client.js | fkenk/Majsternia | /**
* 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 ReactDOM from 'react-... |
app/javascript/mastodon/components/autosuggest_emoji.js | PlantsNetwork/mastodon | import React from 'react';
import PropTypes from 'prop-types';
import unicodeMapping from '../features/emoji/emoji_unicode_mapping_light';
const assetHost = process.env.CDN_HOST || '';
export default class AutosuggestEmoji extends React.PureComponent {
static propTypes = {
emoji: PropTypes.object.isRequired,
... |
src/Input.js | deerawan/react-bootstrap | import React from 'react';
import InputBase from './InputBase';
import * as FormControls from './FormControls';
import deprecationWarning from './utils/deprecationWarning';
class Input extends InputBase {
render() {
if (this.props.type === 'static') {
deprecationWarning('Input type=static', 'StaticText');
... |
src/components/exercises/MissingText.js | cognostics/serlo-abc | import { addIndex, map } from 'ramda';
import React from 'react';
import { View, Text } from 'react-native';
import speakerImage from '../../assets/images/speaker.png';
import { PRIMARY } from '../../styles/colors';
import { DEFAULT } from '../../styles/text';
import { loadSounds, playAll } from '../helpers/audio';
i... |
src/js/components/login/IndexPage.js | FBDevCLagos/fb-group-stat | import React, {PropTypes} from 'react'; // eslint-disable-line no-unused-vars
import LoginPanel from './LoginPanel';
const IndexPage = ({
onPhoneNumberLogin,
onEmailLogin,
onFBLogin,
children
}) => {
return (
<div className="login-box">
<div id="loginbox" className="main-box">
{children ?
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.