path stringlengths 5 304 | repo_name stringlengths 6 79 | content stringlengths 27 1.05M |
|---|---|---|
test/demo/ssr/createElement.js | picidaejs/picidaejs | import React from 'react'
import NProgress from 'nprogress'
export default function createElement(Component, props) {
// console.log('Custom createElement: ');
// console.log(' Component: ', Component);
// console.log(' props: ', props);
NProgress.done();
return React.createElement(Componen... |
node_modules/react-icons/md/create-new-folder.js | bairrada97/festival |
import React from 'react'
import Icon from 'react-icon-base'
const MdCreateNewFolder = props => (
<Icon viewBox="0 0 40 40" {...props}>
<g><path d="m31.6 23.4v-3.4h-5v-5h-3.2v5h-5v3.4h5v5h3.2v-5h5z m1.8-13.4q1.4 0 2.3 1t0.9 2.4v16.6q0 1.4-0.9 2.4t-2.3 1h-26.8q-1.4 0-2.3-1t-0.9-2.4v-20q0-1.4 0.9-2.4t2.3-1h... |
ajax/libs/yui/3.2.0/simpleyui/simpleyui-debug.js | Dervisevic/cdnjs |
/**
* The YUI module contains the components required for building the YUI seed file.
* This includes the script loading mechanism, a simple queue, and the core utilities for the library.
* @module yui
* @submodule yui-base
*/
if (typeof YUI != 'undefined') {
var _YUI = YUI;
}
/**
* The YUI global namespac... |
js/index.js | cdesautels22/thewizaaad | import 'babel-polyfill'
import React from 'react'
import { render } from 'react-dom'
import { Provider } from 'react-redux'
import App from './containers/App'
import configureStore from './store/configureStore'
const store = configureStore({})
render(
<Provider store={store}>
<App />
</Provider>,
document.g... |
src/components/Footer/Footer.js | Rockyluoqi/map_realtime_render | /**
* React Starter Kit (https://www.reactstarterkit.com/)
*
* Copyright © 2014-2016 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, { Component } from 'react';
import withStyle... |
fixture/baz-alpha-test.js | jussikan/leyati | import React from 'react';
import {shallow, mount} from 'enzyme';
import expect from 'expect';
import Baz from './Baz';
describe("Baz", () => {
it("succeeds at full mount without props", () => {
mount(<Baz />);
});
describe("renders", () => {
// @leyati-retain
it("renders an eleme... |
src/TimePicker/TimePicker.spec.js | ngbrown/material-ui | /* eslint-env mocha */
import React from 'react';
import {shallow} from 'enzyme';
import {assert} from 'chai';
import TimePicker from './TimePicker';
import {addHours, formatTime} from './timeUtils';
import getMuiTheme from '../styles/getMuiTheme';
describe('<TimePicker />', () => {
const muiTheme = getMuiTheme();
... |
techCurriculum/ui/solutions/4.4/src/components/Message.js | AnxChow/EngineeringEssentials-group | /**
* Copyright 2017 Goldman Sachs.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to... |
src/interface/common/thirdpartybuttons/GitHub.js | sMteX/WoWAnalyzer | import React from 'react';
import PropTypes from 'prop-types';
import GitHubIcon from 'interface/icons/GitHubMarkSmall';
import './ThirdPartyButtons.css';
const GithubButton = ({ text, ...others }) => (
<a
className="btn github"
role="button"
href="https://github.com/WoWAnalyzer/WoWAnalyzer"
{...ot... |
src/containers/Survey/Survey.js | Nuriddinkhuja/photoshare | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import Helmet from 'react-helmet';
import { initialize } from 'redux-form';
import SurveyForm from 'components/SurveyForm/SurveyForm';
@connect(
() => ({}),
{ initialize })
export default class Surv... |
src/components/configuration/NodeType.component.js | acateland/react-flow-designer | import PropTypes from 'prop-types';
import React from 'react';
import invariant from 'invariant';
class NodeType extends React.Component {
static displayName = 'NodeType';
static propTypes = {
type: PropTypes.string.isRequired,
component: PropTypes.func.isRequired,
};
render() {
invariant(
false,
'<No... |
src/parser/priest/shadow/modules/talents/VoidTorrent.js | fyruna/WoWAnalyzer | import React from 'react';
import SPELLS from 'common/SPELLS/index';
import SpellLink from 'common/SpellLink';
import Analyzer from 'parser/core/Analyzer';
import TalentStatisticBox, { STATISTIC_ORDER } from 'interface/others/TalentStatisticBox';
import ItemDamageDone from 'interface/others/ItemDamageDone';
import Vo... |
app/index.js | cskeppstedt/electron-tap-view | import React from 'react'
import { render } from 'react-dom'
import { Provider } from 'react-redux'
import configureStore from './store/configureStore'
import AppContainer from './containers/App'
import './app.global.css'
const store = configureStore()
render(
<Provider store={store}>
<AppContainer />
</Prov... |
docs/app/Components/Logo/Logo.js | jamiehill/stardust | import React from 'react'
import { Image } from 'src'
const Logo = (props) => <Image {...props} src={__BASE__ + '/logo.png'} />
Logo.propTypes = Image.propTypes
export default Logo
|
docs/src/app/components/pages/components/Slider/Page.js | mtsandeep/material-ui | import React from 'react';
import Title from 'react-title-component';
import CodeExample from '../../../CodeExample';
import PropTypeDescription from '../../../PropTypeDescription';
import MarkdownElement from '../../../MarkdownElement';
import sliderReadmeText from './README';
import SliderExampleSimple from './Exam... |
src/shipit/frontend/src/components/Spinner/index.js | lundjordan/services | import React from 'react';
import { dot, line, back, spin, center } from './styles.css';
// These are roughly in clockwise order starting from the northwest
const Spinner = ({ height = 48, width = 48 }) => (
<div style={{ textAlign: 'center', marginTop: '2rem' }}>
<svg height={height} width={width}>
<g tra... |
extensions/amp-sidebar/1.0/component.type.js | lannka/amphtml | /**
* Copyright 2020 The AMP HTML Authors. All Rights Reserved.
*
* 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 require... |
src/pay/Pay.js | tsengkasing/LottoStar | /**
* Created by Think on 2017/5/20.
*/
import React from 'react';
import { Redirect } from 'react-router-dom';
import {
Step,
Stepper,
StepLabel,
} from 'material-ui/Stepper';
import {
Table,
TableBody,
TableHeader,
TableHeaderColumn,
TableRow,
TableRowColumn,
TableFooter
} fr... |
client/me/purchases/confirm-cancel-domain/cancellation-reasons.js | tinkertinker/wp-calypso | /**
* External Dependencies
*/
import React from 'react';
import i18n from 'i18n-calypso';
/**
* Internal Dependencies
*/
import support from 'lib/url/support';
export default [
{
value: 'misspelled',
label: i18n.translate( 'I misspelled the domain' ),
helpMessage: i18n.translate(
'If you misspelled the... |
example/components/City/components/Image/index.js | Wildhoney/ReactShadow | import React from 'react';
import * as e from './styles';
export default function Image(props) {
return <e.Image {...props} />;
}
|
src/components/Scene.js | spcoder/movietrivia | import React, { Component } from 'react';
import { Link } from 'react-router-dom';
import './Scene.css';
class Scene extends Component {
goBack(e) {
e.preventDefault();
window.history.back();
}
render() {
return (
<div className="Scene">
<h1 className="title">{this.props.title}</h1>
... |
ajax/libs/rxjs/4.0.8/rx.compat.js | Amomo/cdnjs | // Copyright (c) Microsoft, All rights reserved. See License.txt in the project root for license information.
;(function (undefined) {
var objectTypes = {
'function': true,
'object': true
};
function checkGlobal(value) {
return (value && value.Object === Object) ? value : null;
}
var freeExpor... |
webpack/scenes/Subscriptions/components/SubscriptionsTable/components/Dialogs/DeleteDialog.js | mccun934/katello | import React from 'react';
import PropTypes from 'prop-types';
import { MessageDialog } from 'patternfly-react';
import { sprintf, translate as __ } from 'foremanReact/common/I18n';
const DeleteDialog = ({
show, selectedRows, onDeleteSubscriptions, onSubscriptionDeleteModalClose,
}) => (
<MessageDialog
show={s... |
ajax/libs/inferno-router/0.8.0-alpha3/inferno-router.js | holtkamp/cdnjs | /*!
* inferno-router v0.8.0-alpha3
* (c) 2016 Dominic Gannaway
* Released under the MIT License.
*/
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global.InfernoRout... |
ajax/libs/react-textarea-autosize/5.0.1/react-textarea-autosize.js | holtkamp/cdnjs | (function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory(require('react'), require('prop-types')) :
typeof define === 'function' && define.amd ? define(['react', 'prop-types'], factory) :
(global.TextareaAutosize = factory(global.React,global.PropTypes)... |
server/sonar-web/src/main/js/components/ui/Rating.js | Builders-SonarSource/sonarqube-bis | /*
* SonarQube
* Copyright (C) 2009-2016 SonarSource SA
* mailto:contact AT sonarsource DOT com
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 3 of the License... |
ajax/libs/material-ui/5.0.0-alpha.34/Grow/Grow.js | cdnjs/cdnjs | import _extends from "@babel/runtime/helpers/esm/extends";
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/esm/objectWithoutPropertiesLoose";
import * as React from 'react';
import PropTypes from 'prop-types';
import { elementAcceptingRef } from '@material-ui/utils';
import { Transition } from 'react-... |
src/svg-icons/social/group.js | ngbrown/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let SocialGroup = (props) => (
<SvgIcon {...props}>
<path d="M16 11c1.66 0 2.99-1.34 2.99-3S17.66 5 16 5c-1.66 0-3 1.34-3 3s1.34 3 3 3zm-8 0c1.66 0 2.99-1.34 2.99-3S9.66 5 8 5C6.34 5 5 6.34 5 8s1.34 3 3 3zm0 2c-2.3... |
src/components/movies/movie-card.js | scholtzm/arnold | import React, { Component } from 'react';
import { Card, Image, Container } from 'semantic-ui-react';
import PlayMovieButton from './play-button.js';
class MovieCard extends Component {
render() {
return (
<Card>
<Image src={this.props.movie.thumbnail} onClick={this.props.showDetail} style={{curso... |
packages/material-ui-icons/src/Stop.js | allanalexandre/material-ui | import React from 'react';
import createSvgIcon from './utils/createSvgIcon';
export default createSvgIcon(
<React.Fragment><path fill="none" d="M0 0h24v24H0z" /><path d="M6 6h12v12H6z" /></React.Fragment>
, 'Stop');
|
ajax/libs/vue/1.0.19-csp/vue.common.js | sajochiu/cdnjs | /*!
* Vue.js v1.0.19-csp
* (c) 2016 Evan You
* Released under the MIT License.
*/
'use strict';
function set(obj, key, val) {
if (hasOwn(obj, key)) {
obj[key] = val;
return;
}
if (obj._isVue) {
set(obj._data, key, val);
return;
}
var ob = obj.__ob__;
if (!ob) {
obj[key] = val;
r... |
Libraries/Components/Navigation/NavigatorIOS.ios.js | adamterlson/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... |
src/components/Section/Section.js | sjchmiela/inspirowani.pl | import React from 'react';
import classnames from 'classnames';
import './Section.scss';
export default ({ zIndex, children, className, backLayerClassName, wrapperClassName, id }) => (
<div className={classnames('Section', wrapperClassName)} style={{ zIndex: zIndex }} id={id}>
{backLayerClassName && <div classN... |
examples/shopping-cart/test/components/ProductsList.spec.js | joaomilho/redux | import expect from 'expect'
import React from 'react'
import { shallow } from 'enzyme'
import ProductsList from '../../components/ProductsList'
function setup(props) {
const component = shallow(
<ProductsList title={props.title}>{props.children}</ProductsList>
)
return {
component: component,
childr... |
packages/insights-web/src/scenes/explorer/connection/index.js | mariusandra/insights | import './styles.scss'
import React from 'react'
import { Button } from "antd";
import { useValues } from 'kea'
import Database from './database'
import Subset from './subset'
import connectionsLogic from './logic'
export default function Connection () {
const { selectedConnection } = useValues(connectionsLogic)
... |
stories/SideNav.stories.js | react-materialize/react-materialize | import React from 'react';
import { storiesOf } from '@storybook/react';
import SideNav from '../src/SideNav';
import SideNavItem from '../src/SideNavItem';
import Button from '../src/Button';
import Icon from '../src/Icon';
const stories = storiesOf('Javascript/SideNav', module);
const reactMaterializeLogo = require(... |
vam-client/scripts/start.js | vistadataproject/nodeVISTAClients | 'use strict';
// Do this as the first thing so that any code reading it knows the right env.
process.env.BABEL_ENV = 'development';
process.env.NODE_ENV = 'development';
// Makes the script crash on unhandled rejections instead of silently
// ignoring them. In the future, promise rejections that are not handled will
... |
ajax/libs/angular-google-maps/1.0.7/angular-google-maps.js | iwdmb/cdnjs | /*
Author Nick McCready
Intersection of Objects if the arrays have something in common each intersecting object will be returned
in an new array.
*/
(function() {
_.intersectionObjects = function(array1, array2, comparison) {
var res,
_this = this;
if (comparison == null) {
compariso... |
src/Dialog/DialogButton.js | react-fabric/react-fabric | import React from 'react'
import cx from 'classnames'
import Icon from '../Icon'
import fabricComponent from '../fabricComponent'
import style from './Dialog.scss'
const DialogButton = ({
children,
className,
close,
onClick
}) => (
<button onClick={onClick}
styleName={cx('ms-Dialog-button', {
'ms... |
tests/Rules-isEmail-spec.js | etshi/optiopay-form | import React from 'react';
import TestUtils from 'react-dom/test-utils';
import Formsy from './..';
import { InputFactory } from './utils/TestInput';
const TestInput = InputFactory({
render() {
return <input value={this.props.getValue()} readOnly/>;
}
});
class TestForm extends React.Component {
render() {... |
test/integration/AutoComplete/AutoComplete.spec.js | lawrence-yu/material-ui | /* eslint-env mocha */
import React from 'react';
import {assert} from 'chai';
import {mount} from 'enzyme';
import AutoComplete from 'src/AutoComplete';
import getMuiTheme from 'src/styles/getMuiTheme';
describe('<AutoComplete />', () => {
const muiTheme = getMuiTheme();
const mountWithContext = (node) => mount(... |
src/preview/containers/WithIntl/__tests__/index.js | truffls/storybook-addon-intl | import React from 'react';
import renderer from 'react-test-renderer';
import { IntlProvider } from 'react-intl';
import WithIntl from '../';
import { EVENT_SET_LOCALE_ID, EVENT_GET_LOCALE_ID } from '../../../../shared';
describe('WithIntl', () => {
test('initialize correctly', () => {
let nextEventId = 1... |
ajax/libs/highmaps/5.0.5/js/highcharts.src.js | jonobr1/cdnjs | /**
* @license Highcharts JS v5.0.5 (2016-11-29)
*
* (c) 2009-2016 Torstein Honsi
*
* License: www.highcharts.com/license
*/
'use strict';
(function(root, factory) {
if (typeof module === 'object' && module.exports) {
module.exports = root.document ?
factory(root) :
factory;
... |
ajax/libs/flocks.js/0.14.3/flocks.js | steadiest/cdnjs | /** @jsx React.DOM */
/* jshint node: true, browser: true, newcap: false */
/**
* The Flocks library module.
*
* @module Flocks
* @main Flocks
*/
// if it's in a <script> it's defined already
// otherwise assume commonjs
if (typeof React === 'undefined') {
var React = require('react');
}
// wrap ... |
packages/material-ui-icons/src/InsertInvitationRounded.js | kybarg/material-ui | import React from 'react';
import createSvgIcon from './utils/createSvgIcon';
export default createSvgIcon(
<path d="M16 12h-3c-.55 0-1 .45-1 1v3c0 .55.45 1 1 1h3c.55 0 1-.45 1-1v-3c0-.55-.45-1-1-1zm0-10v1H8V2c0-.55-.45-1-1-1s-1 .45-1 1v1H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2... |
client/src/pages/order/OrderProductListItem.js | ccwukong/lfcommerce-react | import React from 'react';
import PropTypes from 'prop-types';
import numeral from 'numeral';
import { MdDeleteForever } from 'react-icons/md';
const OrderProductListItem = props => {
const { code, name, currencySign, unitPrice, quantity, onDeleteClick } = props;
return (
<tr>
<td>{name}</td>
<td>... |
src/svg-icons/action/visibility.js | pradel/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ActionVisibility = (props) => (
<SvgIcon {...props}>
<path d="M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5zM12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-... |
src/main/webapp/js/main.js | NemesisShooter/CI346 | import React from 'react';
import {render} from 'react-dom';
class EmployeeList extends React.Component {
render() {
console.log(this.props);
var employeelist = Object.values(this.props.employees).map(employeeObject =>
<Employee employeeObject = {JSON.parse(employeeObject)}/>
... |
src/Timer.js | zenway-js/ztime | import React, { Component } from 'react';
import styles from './styles/styles.css';
// function tick() {
// let x = 0;
// setInterval(function () {
// x += 1;
// console.log( x );
// }, 1000);
//
// return x;
// };
//
// export default class Timer extends Component {
//
//
// render() {
//
// //... |
src/js/reducers/index.js | julianburr/wp-react-theme | import { combineReducers } from 'redux';
import { routerReducer } from 'react-router-redux';
// Import reducers
import settings from './settings';
import content from './content';
import list from './list';
export default combineReducers({
settings,
content,
list,
routing: routerReducer
}); |
test/integration/image-component/unicode/pages/index.js | zeit/next.js | import React from 'react'
import Image from 'next/image'
import img from '../public/äöüščří.png'
const Page = () => {
return (
<div>
<h1>Unicode Image URL</h1>
<Image id="static" src={img} />
<Image id="internal" src="/äöüščří.png" width={400} height={400} />
<Image
id="external"
... |
shared/routes.js | kweestian/TreeID | import { Route, IndexRoute } from 'react-router';
import React from 'react';
import App from './container/App';
import PostContainer from './container/PostContainer/PostContainer';
import PostDetailView from './container/PostDetailView/PostDetailView';
const routes = (
<Route path="/" component={App} >
<IndexRou... |
src/Tab.js | apkiernan/react-bootstrap | import React from 'react';
import TabContainer from './TabContainer';
import TabContent from './TabContent';
import TabPane from './TabPane';
const propTypes = {
...TabPane.propTypes,
disabled: React.PropTypes.bool,
title: React.PropTypes.node,
/**
* tabClassName is used as className for the associated ... |
app/containers/NotFoundPage/index.js | dcarneiro/my-react-boilerplate | /**
* NotFoundPage
*
* This is the page we show when the user visits a url that doesn't have a route
*
* NOTE: while this component should technically be a stateless functional
* component (SFC), hot reloading does not currently support SFCs. If hot
* reloading is not a necessity for you then you can refactor it... |
site/components/basic-table/table.js | JamesHageman/redux-datagrid | import React from 'react';
import { FlexTable, FlexColumn, AutoSizer } from 'react-virtualized';
import { reduxDatagrid } from 'redux-datagrid';
import '!!style!css!react-virtualized/styles.css';
const BasicTable = ({ datagrid: { data, filtered, columns, controls: { search, sortBy, sortDirection } }}) =>
<div>
<... |
ajax/libs/htm/2.1.1/preact/index.js | cdnjs/cdnjs | !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("preact"),require("htm")):"function"==typeof define&&define.amd?define(["exports","preact","htm"],t):t(e.htmPreact={},e.preact,e.htm)}(this,function(e,t,n){var r=(n=n&&n.hasOwnProperty("default")?n.default:n).bind(t.h);e.h=t.h,e.Compo... |
website/src/components/References.js | plouc/mozaik | import React from 'react'
import styled from 'styled-components'
import Container from './Container'
import media from '../styles/media'
const Root = styled(Container)`
background: ${props => props.theme.contentBackgroundHighlightColor};
border-top: 1px solid ${props => props.theme.borderColor};
border-bo... |
src/NavItem.js | cgvarela/react-bootstrap | import React from 'react';
import classNames from 'classnames';
import BootstrapMixin from './BootstrapMixin';
import SafeAnchor from './SafeAnchor';
const NavItem = React.createClass({
mixins: [BootstrapMixin],
propTypes: {
linkId: React.PropTypes.string,
onSelect: React.PropTypes.func,
active: React... |
packages/cf-component-card/src/CardDrawers.js | koddsson/cf-ui | import React from 'react';
import PropTypes from 'prop-types';
import CardSection from './CardSection';
import CardToolbar from './CardToolbar';
import CardToolbarLink from './CardToolbarLink';
import CardPropTypes from './CardPropTypes';
let UNIQUE_ID = 0;
class CardDrawers extends React.Component {
constructor(pr... |
ui/src/js/Root.prod.js | waynelkh/OpenADM | import React from 'react';
import { Provider } from 'react-redux';
import RootRouter from './routes.jsx';
/* eslint-disable react/prop-types */
const Root = ({ store, history }) => (
<Provider store={store}>
<RootRouter history={history} />
</Provider>
);
/* eslint-enable react/prop-types */
export default Ro... |
src/svg-icons/code.js | und3fined/material-ui | /* eslint-disable */
import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../SvgIcon';
let Code = (props) => (
<SvgIcon {...props}>
<path d="M9.4 16.6L4.8 12l4.6-4.6L8 6l-6 6 6 6 1.4-1.4zm5.2 0l4.6-4.6-4.6-4.6L16 6l6 6-6 6-1.4-1.4z"/>
</SvgIcon>
);
Code = pure(Code);
Code.muiName... |
ajax/libs/ui-router-extras/0.0.11-pre1/ct-ui-router-extras.js | BitsyCode/cdnjs | /**
* UI-Router Extras: Sticky states, Future States, Deep State Redirect, Transition promise
* @version v0.0.11-pre1-BROKEN!!!
* 0.0.11-pre1 is broken, please use 0.0.11-pre2
* @link http://christopherthielen.github.io/ui-router-extras/
* @license MIT License, http://www.opensource.org/licenses/MIT
*/
(function... |
examples/users/src/components/User.js | kompot/rjanko-forms | import React from 'react';
import {branch} from 'baobab-react/decorators';
@branch({
cursors: {
user: ['user'],
data: ''
}
})
export default class User extends React.Component {
render() {
return (
<div>
{this.props.user.username}
<pre>
{JSON.stringify(this.props.dat... |
packages/material-ui-icons/src/VideoLibraryTwoTone.js | Kagami/material-ui | import React from 'react';
import createSvgIcon from './utils/createSvgIcon';
export default createSvgIcon(
<React.Fragment><path fill="none" d="M0 0h24v24H0V0z" /><path d="M8 16h12V4H8v12zm4-10.5l6 4.5-6 4.5v-9z" opacity=".3" /><path d="M4 6H2v14c0 1.1.9 2 2 2h14v-2H4V6z" /><path d="M20 2H8c-1.1 0-2 .9-2 2v12c0 1.1... |
docs/app/Examples/modules/Dropdown/Content/index.js | mohammed88/Semantic-UI-React | import React from 'react'
import ComponentExample from 'docs/app/Components/ComponentDoc/ComponentExample'
import ContributionPrompt from 'docs/app/Components/ComponentDoc/ContributionPrompt'
import ExampleSection from 'docs/app/Components/ComponentDoc/ExampleSection'
const DropdownContentExamples = () => (
<Example... |
examples/flux-utils-todomvc/js/app.js | jeremyhu9/flux | /**
* Copyright (c) 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 directory.
*
* @flow
*/
'use s... |
src/Gamepad.js | SBRK/react-gamepad | import React from 'react'
import { XBOX } from './layouts'
class Gamepad extends React.Component {
static defaultProps = {
layout: XBOX,
stickThreshold: 0.5,
deadZone: 0.08,
gamepadIndex: 0,
onConnect: () => {},
onDisconnect: () => {},
onButtonDown: () => {},
onButtonUp: () => {}... |
docs/src/pages/components/grid/CenteredGrid.js | kybarg/material-ui | import React from 'react';
import { makeStyles } from '@material-ui/core/styles';
import Paper from '@material-ui/core/Paper';
import Grid from '@material-ui/core/Grid';
const useStyles = makeStyles(theme => ({
root: {
flexGrow: 1,
},
paper: {
padding: theme.spacing(2),
textAlign: 'center',
color... |
addons/comments/src/index.js | enjoylife/storybook | import PropTypes from 'prop-types';
import React from 'react';
const buttonStyles = {
border: '1px solid #eee',
borderRadius: 3,
backgroundColor: '#FFFFFF',
cursor: 'pointer',
fontSize: 15,
padding: '3px 10px',
};
const Button = ({ children, onClick, style = {} }) =>
<button style={{ ...buttonStyles, ..... |
ajax/libs/angular-google-maps/2.0.7/angular-google-maps.js | chriszarate/cdnjs | /*! angular-google-maps 2.0.7 2014-11-04
* AngularJS directives for Google Maps
* git: https://github.com/angular-ui/angular-google-maps.git
*/
(function() {
String.prototype.contains = function(value, fromIndex) {
return this.indexOf(value, fromIndex) !== -1;
};
String.prototype.flare = function(flare)... |
node_modules/react-bootstrap/es/MediaHeading.js | acalabano/get-committed | 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 ... |
renderer/components/UI/Modal.js | LN-Zap/zap-desktop | import React from 'react'
import PropTypes from 'prop-types'
import styled from 'styled-components'
import { Box, Flex } from 'rebass/styled-components'
import CloseButton from 'components/UI/CloseButton'
import ZapLogo from 'components/Icon/ZapLogo'
import Page from './Page'
export const ModalOverlayStyles = () => `
... |
src/components/Main.js | C3-TKO/gaiyo | require('normalize.css');
require('styles/App.css');
import React from 'react';
import IframeComponent from './IframeComponent';
import MenuComponent from './MenuComponent'
import ProgressBarComponent from './ProgressBarComponent';
import ReloaderComponent from './ReloaderComponent';
class AppComponent extends React.... |
public/App.js | chtefi/react-isomorphic | import React from 'react';
import List from './List';
export default class App extends React.Component {
render() {
return <div>
<h2>{this.props.name}</h2>
<List items={this.props.people} />
</div>;
}
}
App.propTypes = {
name: React.PropTypes.string,
people: React.PropTypes.arrayOf(
React.PropTypes... |
src/components/Layout/Navbar/Navbar.js | mmrath/react-app | /*
* React.js Starter Kit
* Copyright (c) 2014 Konstantin Tarkus (@koistya), KriaSoft LLC.
*
* This source code is licensed under the MIT license found in the
* LICENSE.txt file in the root directory of this source tree.
*/
'use strict';
import React from 'react';
export default React.createClass({
render()... |
simpleapp/app/component/app.js | ladanv/learn-react-js | import React, { Component } from 'react';
import config from '../../config';
import NavBar from './nav/navbar';
import SideNav from './nav/sidenav';
var menuItems = [{
id: 1,
label: config.menuInventory,
url: '/inventory'
}, {
id: 2,
label: config.menuWarehouse,
url: '/warehouse'
}, {
id:... |
src/encoded/static/components/reference.js | T2DREAM/t2dream-portal | import React from 'react';
import _ from 'underscore';
export default function pubReferenceList(values) {
// Render each of the links, with null for each value without an identifier property
if (values && values.length) {
const links = _.compact(values.map((value) => {
if (value.identifier... |
ajax/libs/ember-data.js/2.4.2/ember-data.js | iwdmb/cdnjs | (function(){
"use strict";
/*!
* @overview Ember Data
* @copyright Copyright 2011-2016 Tilde Inc. and contributors.
* Portions Copyright 2011 LivingSocial Inc.
* @license Licensed under MIT license (see license.js)
* @version 2.4.2
*/
var define, requireModule, require, requirejs;
(function() ... |
public/src/config/routes.js | MaciejSzaflik/CharadesAndStuff | import React from 'react';
import {Router, Route, IndexRoute} from 'react-router';
import {Provider} from 'react-redux';
import {Main} from '../main';
import {Puns} from '../puns';
import {Checkers} from '../checkers';
import {Home} from '../home';
import {history, store} from '../root.store';
import {Lobby} from '../... |
react/src/app/screens/Welcome/components/Splash.js | JasonKDarby/listopolis | import React from 'react';
import { Jumbotron, Button } from 'react-bootstrap';
import { LinkContainer } from 'react-router-bootstrap';
import './blinking-cursor.css';
export default () => (
<Jumbotron className="text-center">
<h1>1. <span className="blinking-cursor">|</span></h1>
<p>Create, keep, ... |
js/src/dapps/githubhint.js | jesuscript/parity | // 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... |
test/ThumbnailSpec.js | chrishoage/react-bootstrap | import React from 'react';
import ReactTestUtils from 'react/lib/ReactTestUtils';
import Thumbnail from '../src/Thumbnail';
describe('Thumbnail', function () {
it('Should have a thumbnail class and be an anchor', function () {
let instance = ReactTestUtils.renderIntoDocument(
<Thumbnail href="#" src="#" al... |
bower_components/bootstrap-datepicker/tests/assets/jquery-1.7.1.min.js | csooraj/wpeditor.github.io | /*! jQuery v1.7.1 jquery.com | jquery.org/license */
(function(a,b){function cy(a){return f.isWindow(a)?a:a.nodeType===9?a.defaultView||a.parentWindow:!1}function cv(a){if(!ck[a]){var b=c.body,d=f("<"+a+">").appendTo(b),e=d.css("display");d.remove();if(e==="none"||e===""){cl||(cl=c.createElement("iframe"),cl.frameBorde... |
src/Parser/Core/Modules/DeathTracker.js | enragednuke/WoWAnalyzer | import React from 'react';
import SPELLS from 'common/SPELLS';
import { formatNumber, formatMilliseconds, formatPercentage } from 'common/format';
import Analyzer from 'Parser/Core/Analyzer';
import Combatants from 'Parser/Core/Modules/Combatants';
const debug = true;
class DeathTracker extends Analyzer {
static d... |
src/components/Comment/Comments.js | KaPrimov/ArtPodarychePage | import React, { Component } from 'react';
import './Comments.css'
export default class Comment extends Component {
render() {
return (
<form onSubmit={this.props.onSubmitHandler}>
<div className="form-group">
<label>Comment:</label>
<input... |
client/modules/App/components/Footer/Footer.js | Akayeshmantha/TestReactApp | import React from 'react';
import { FormattedMessage } from 'react-intl';
// Import Style
import styles from './Footer.css';
// Import Images
import bg from '../../header-bk.png';
export function Footer() {
return (
<div style={{ background: `#FFF url(${bg}) center` }} className={styles.footer}>
<p>©... |
src/shared/HeroPicker/HeroTile.js | kashisau/enroute | /**
* HeroTile.js
*/
import React from 'react';
import './HeroTile.scss';
import classnames from 'classnames';
class HeroTile extends React.Component {
constructor(props) {
super(props);
this.state = {
active: false
};
this.changeArticle = this.changeArticle.bind(thi... |
src/svg-icons/places/business-center.js | ngbrown/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let PlacesBusinessCenter = (props) => (
<SvgIcon {...props}>
<path d="M10 16v-1H3.01L3 19c0 1.11.89 2 2 2h14c1.11 0 2-.89 2-2v-4h-7v1h-4zm10-9h-4.01V5l-2-2h-4l-2 2v2H4c-1.1 0-2 .9-2 2v3c0 1.11.89 2 2 2h6v-2h4v2h6c1... |
src/esm/components/graphics/icons-next/star-icon-next/index.js | KissKissBankBank/kitten | import _extends from "@babel/runtime/helpers/extends";
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/objectWithoutPropertiesLoose";
var _excluded = ["color", "title", "bgColor"];
import React from 'react';
import PropTypes from 'prop-types';
export var StarIconNext = function StarIconNext(_ref) {
... |
src/test/react/my-relay-component.js | foraproject/isotropy-browser-mode | import React from 'react';
import Relay from 'react-relay';
import MyComponent from "./my-component";
const relayComponent = Relay.createContainer(
MyComponent,
{
fragments: {
ship: () => Relay.QL`
fragment on Ship {
name
}
`,
}
}
);
export default relayComponent;
|
packages/cf-component-pagination/test/PaginationItem.js | mdno/mdno.github.io | import React from 'react';
import { PaginationItem } from '../../cf-component-pagination/src/index';
import { felaSnapshot } from 'cf-style-provider';
test('should render', () => {
const snapshot = felaSnapshot(
<PaginationItem type="number" label="PaginationLabel" onClick={() => {}}>
PaginationItem
</... |
src/basic/H2.js | sampsasaarela/NativeBase | import React, { Component } from 'react';
import { Text } from 'react-native';
import { connectStyle } from 'native-base-shoutem-theme';
import mapPropsToStyleNames from '../Utils/mapPropsToStyleNames';
class H2 extends Component {
render() {
return (
<Text ref={c => this._root = c} {...this.props} />
... |
testClient/components/CurrStats.js | DougCal/ServerHive | import React from 'react';
import Bar from './Bar';
const normalizeBars = (keys, currStats) => {
let divisor = 1;
for (let i = 0; i < keys.length; i += 1) {
// console.log('yo', currStats[keys[i]]);
if (currStats[keys[i]] > 75 && currStats[keys[i]] / 75 > divisor) divisor = Math.floor(currStats[keys[i]] / ... |
src/components/FormFields/HorizontalRadioGroup.spec.js | opencredo/opencredo-react-boilerplate | import React from 'react';
import TestUtils from 'react-addons-test-utils';
import HorizontalRadioGroup from './HorizontalRadioGroup';
const shallowRender = (component) => {
const renderer = TestUtils.createRenderer();
renderer.render(component);
return renderer.getRenderOutput();
};
const shallowRenderWithPr... |
app/javascript/mastodon/components/short_number.js | tootsuite/mastodon | import React from 'react';
import PropTypes from 'prop-types';
import { toShortNumber, pluralReady, DECIMAL_UNITS } from '../utils/numbers';
import { FormattedMessage, FormattedNumber } from 'react-intl';
// @ts-check
/**
* @callback ShortNumberRenderer
* @param {JSX.Element} displayNumber Number to display
* @para... |
src/svg-icons/social/poll.js | kasra-co/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let SocialPoll = (props) => (
<SvgIcon {...props}>
<path d="M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9 17H7v-7h2v7zm4 0h-2V7h2v10zm4 0h-2v-4h2v4z"/>
</SvgIcon>
);
SocialPoll = ... |
examples/jest-snapshot-testing/src/components/AppFooter.js | ericf/react-intl | import React from 'react';
import { FormattedMessage, defineMessages } from 'react-intl';
const messages = defineMessages({
copyright: {
id: 'app-footer__copyright',
defaultMessage: '© 2017 Future Testing',
},
});
export default () => (
<footer className="app-footer">
<div classNam... |
analysis/paladinholy/src/modules/beacons/BeaconHealingBreakdown.js | yajinni/WoWAnalyzer | import React from 'react';
import PropTypes from 'prop-types';
import Toggle from 'react-toggle';
import { Trans } from '@lingui/macro';
import { Icon } from 'interface';
import { SpellLink } from 'interface';
import { formatNumber, formatPercentage } from 'common/format';
import { TooltipElement } from 'interface';
i... |
scripts/jquery.min.js | mynamesleon/wordify | /*! jQuery v1.11.1 | (c) 2005, 2014 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... |
app/javascript/mastodon/features/standalone/public_timeline/index.js | lynlynlynx/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... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.