path stringlengths 5 296 | repo_name stringlengths 5 85 | content stringlengths 25 1.05M |
|---|---|---|
app/javascript/mastodon/features/ui/components/tabs_bar.js | 8796n/mastodon | import React from 'react';
import { Link } from 'react-router';
import { FormattedMessage } from 'react-intl';
class TabsBar extends React.Component {
render () {
return (
<div className='tabs-bar'>
<Link className='tabs-bar__link primary' activeClassName='active' to='/statuses/new'><i className='... |
modules/frontend/src/js/components/widgets/Panel.js | fleximaps/fleximaps | import styles from './Panel.css';
import React from 'react';
import CSSModules from 'react-css-modules';
export default CSSModules(class Panel extends React.Component {
render() {
return (
<div styleName='panel'>{this.props.children}</div>
);
}
}, styles); |
src/interface/icons/Agility.js | yajinni/WoWAnalyzer | import React from 'react';
const icon = props => (
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="16 16 32 32" className="icon" {...props}>
<path d="M46.804,34.219c0.179,3.128-6.415,10.197-7.82,4.58c-0.414-1.655,0.806-3.86,1.905-5.034 c0.877-0.937,3.26-2.676,4.614-2.312c0.515,0.139,1.057,0.698,1.... |
components/Cards/PictureCard/PictureCard.js | rdjpalmer/bloom | import PropTypes from 'prop-types';
import React from 'react';
import cx from 'classnames';
import css from './PictureCard.css';
import Card from '../Card/Card';
const PictureCard = (props) => {
const {
src,
href,
children,
className,
center,
style,
overlayClassName,
...rest,
} = p... |
test/popup/Info.js | MrMamen/traktflix | import { mount } from '../../test-helpers/EnzymeHelper';
import browser from 'sinon-chrome';
import React from 'react';
import Info from '../../src/class/popup/Info';
window.browser = browser;
const messages = [`Info Message`, `About Message`];
const component = mount(
<Info messages={messages}/>
);
delete window.... |
index.js | waywaaard/spectacle | import React from 'react';
import { render } from 'react-dom';
import Presentation from './example/src';
render(<Presentation/>, document.getElementById('root'));
|
front_end/skax/src/component/Mainmenu.js | julianpr/workflow-automation | import React, { Component } from 'react';
import { Menu } from 'semantic-ui-react';
import { Link } from 'react-router-dom';
class Mainmenu extends Component {
state = { activeItem: 'home' }
handleItemClick = (e, { name }) => this.setState({ activeItem: name })
render() {
const { activeItem }... |
client/common/components/SearchResult.js | Haaarp/geo | import React from 'react';
import SearchList from './SearchList';
import Scrollbars from 'konux/common/components/Scrollbars';
class SearchResult extends React.Component {
_getClassName(){
return "search-result " +
(this.props.className ? this.props.className : "");
}
render() {
r... |
components/animals/jerabMandzusky.adult.js | marxsk/zobro | import React, { Component } from 'react';
import { Text } from 'react-native';
import styles from '../../styles/styles';
import InPageImage from '../inPageImage';
import AnimalText from '../animalText';
import AnimalTemplate from '../animalTemplate';
const IMAGES = [
require('../../images/animals/jerabMandzusky/01.... |
app/components/Chat/Message.js | SynapseNetwork/Synapse-Desktop | /* **************************************************************
* Synapse - Desktop Client
* @author Marco Fernandez Pranno <mfernandezpranno@gmail.com>
* @licence MIT
* @link https://github.com/SynapseNetwork/Synapse-Desktop
* @version 1.0
* ****************************************************... |
stories/rangeformgroup.stories.js | JimBarrows/Bootstrap-React-Components | import {storiesOf} from '@storybook/react'
import {action} from '@storybook/addon-actions'
import React from 'react'
import RangeFormGroup from '../src/formgroups/RangeFormGroup'
storiesOf('Form Groups/Range', module)
.addDecorator((story) => <div className="container">{<form>{story()}</form>}</div>)
.add('Defau... |
demo/snippets/archive/demo4/00_shell.js | simonswiss/react-music | import React, { Component } from 'react';
import { Analyser, Song, Sequencer, Sampler, Synth, Delay, MoogFilter } from '../src';
import { BASS, CHORDS, TUNE_LOW, TUNE_HIGH } from './snippets/demo4/data/steps'
import { STATE } from './snippets/demo4/data/state'
import Instrument from './snippets/demo4/components/Instru... |
packages/mineral-ui-icons/src/IconCloudUpload.js | mineral-ui/mineral-ui | /* @flow */
import React from 'react';
import Icon from 'mineral-ui/Icon';
import type { IconProps } from 'mineral-ui/Icon/types';
/* eslint-disable prettier/prettier */
export default function IconCloudUpload(props: IconProps) {
const iconProps = {
rtl: false,
...props
};
return (
<Icon {...iconPr... |
client/app/scripts/components/help-panel.js | dilgerma/scope | import React from 'react';
const GENERAL_SHORTCUTS = [
{key: 'esc', label: 'Close active panel'},
{key: '/', label: 'Activate search field'},
{key: '?', label: 'Toggle shortcut menu'},
];
const CANVAS_METRIC_SHORTCUTS = [
{key: '<', label: 'Select and pin previous metric'},
{key: '>', label: 'Select and pin... |
app/components/H3/index.js | w01fgang/react-boilerplate | import React from 'react';
function H3(props) {
return (
<h3 {...props} />
);
}
export default H3;
|
demos/menus/demos/lowerRight.js | isogon/styled-mdl-website | import React from 'react'
import { Menu, MenuItem, MenuDivider, Button } from 'styled-mdl'
import More from 'react-icons/lib/md/more-vert'
import { Container, Bar, Bg } from './styled'
const demo = () => (
<Container align="right">
<Bar>
<Menu
bottomRight
control={
<Button icon>
... |
fixtures/output/webpack-message-formatting/src/AppCss.js | IamJoseph/create-react-app | import React, { Component } from 'react';
import './AppCss.css';
class App extends Component {
render() {
return <div className="App" />;
}
}
export default App;
|
src/index.js | oiricaud/horizon-education | import React from 'react';
import ReactDOM from 'react-dom';
import './index.css';
import App from './App';
import registerServiceWorker from './registerServiceWorker';
ReactDOM.render(<App />, document.getElementById('root'));
registerServiceWorker();
|
src/containers/DevTools.js | jfmaggie/reading-list | import React from 'react';
import { createDevTools } from 'redux-devtools';
import LogMonitor from 'redux-devtools-log-monitor';
export default createDevTools(<LogMonitor />);
|
src/mobile/components/DrawerMenu/index.js | welovekpop/uwave-web-welovekpop.club | import React from 'react';
import PropTypes from 'prop-types';
import { translate } from 'react-i18next';
import compose from 'recompose/compose';
import withHandlers from 'recompose/withHandlers';
import Drawer from '@material-ui/core/Drawer';
import MenuList from '@material-ui/core/MenuList';
import MenuItem from '@m... |
js/src/views/Status/components/RpcNav/RpcNav.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/adminTools/index.js | marchisbogdan/licenta-front | import React from 'react';
import cookie from 'react-cookies'
import s from './style.css';
import pageConfig from '../pageProps.json';
import SignUp from '../../components/SignUp';
import LobbyLayout from '../../components/LobbyLayout';
import AdminTools from '../../components/AdminTools';
import history from "../../s... |
examples/react-native/__tests__/App-test.js | oblador/loki | /**
* @format
*/
import 'react-native';
import React from 'react';
import App from '../App';
// Note: test renderer must be required after react-native.
import renderer from 'react-test-renderer';
it('renders correctly', () => {
renderer.create(<App />);
});
|
src/svg-icons/notification/event-available.js | ArcanisCz/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let NotificationEventAvailable = (props) => (
<SvgIcon {...props}>
<path d="M16.53 11.06L15.47 10l-4.88 4.88-2.12-2.12-1.06 1.06L10.59 17l5.94-5.94zM19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-1.99.9-1.99 2L3 19c0 1.1.89 2 2 ... |
js/ShowCard.js | ysdevys/ci-demo-jslab | import React from 'react'
const { string } = React.PropTypes
const ShowCard = React.createClass({
propTypes: {
poster: string,
title: string,
year: string,
description: string
},
render () {
const { poster, title, year, description } = this.props
return (
<div className='show-card'>... |
react/IconAlert/IconAlert.js | seekinternational/seek-asia-style-guide | import svgMarkup from './IconAlert.svg';
import React from 'react';
import Icon from '../private/Icon/Icon';
export default function IconAlert(props) {
return <Icon markup={svgMarkup} {...props} />;
}
IconAlert.displayName = 'Alert Icon';
|
src/App.js | AlexKVal/react-hot-boilerplate | import React, { Component } from 'react';
export default class App extends Component {
render() {
return (
<h1>Hello, world.</h1>
);
}
}
|
src/components/NotFoundPage/NotFoundPage.js | jurgob/jurgo.me | /*
* 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';
//require('./NotFoundPage.less');
import React from 'react';
export defa... |
src/components/calculatorSmall/presentation/CSCounter.js | edu-affiliates/promo_calculators | 'use strict';
import React from 'react';
import {connect} from 'react-redux'
import PropTypes from 'prop-types'
import {plusPage, minusPage, handleInputPageNumber} from '../../../store/actions'
//presentation of the counter in calc small
class CSCounter extends React.Component {
constructor(props) {
supe... |
modules/openy_features/openy_node/modules/openy_node_alert/js/openy-alerts/src/AppHeader.js | hamrant/openy | /*global location b:true*/
/*global drupalSettings b:true*/
/*eslint no-restricted-globals: ["warn", "drupalSettings"]*/
import React, { Component } from 'react';
import { connect } from 'react-redux';
import 'slick-carousel/slick/slick.css';
import 'slick-carousel/slick/slick-theme.css';
import HeaderAlertItem from '.... |
fields/types/markdown/MarkdownColumn.js | stunjiturner/keystone | import React from 'react';
import ItemsTableCell from '../../../admin/client/components/ItemsTableCell';
import ItemsTableValue from '../../../admin/client/components/ItemsTableValue';
var MarkdownColumn = React.createClass({
displayName: 'MarkdownColumn',
propTypes: {
col: React.PropTypes.object,
data: React.Pr... |
__tests__/components/Todos.js | epicsharp/react-boilerplate | jest.unmock('routes/Todos/Todos')
import React from 'react'
import { shallow, mount } from 'enzyme'
import { TodosComponent } from 'routes/Todos/Todos'
import { fetchTodosIfNeeded, completeTodo, removeCompletedTodos } from 'actions/todos'
describe('<TodosComponent />', () => {
let wrapper
let dispatch
beforeE... |
consoles/my-joy-instances/src/mocks/store.js | yldio/joyent-portal | import React from 'react';
import { ApolloProvider } from 'react-apollo';
import createClient from '@state/apollo-client';
export default ({ children }) => (
<ApolloProvider client={createClient()}>{children}</ApolloProvider>
);
|
src/svg-icons/av/play-arrow.js | pradel/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let AvPlayArrow = (props) => (
<SvgIcon {...props}>
<path d="M8 5v14l11-7z"/>
</SvgIcon>
);
AvPlayArrow = pure(AvPlayArrow);
AvPlayArrow.displayName = 'AvPlayArrow';
export default AvPlayArrow;
|
src/js/components/icons/base/LinkTop.js | linde12/grommet | // (C) Copyright 2014-2015 Hewlett Packard Enterprise Development LP
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import classnames from 'classnames';
import CSSClassnames from '../../../utils/CSSClassnames';
import Intl from '../../../utils/Intl';
import Props from '../../../utils/Pro... |
src/context/UwaveContext.js | u-wave/web | import React from 'react';
export default React.createContext(null);
|
docs/src/app/components/pages/components/Popover/ExampleSimple.js | igorbt/material-ui | import React from 'react';
import RaisedButton from 'material-ui/RaisedButton';
import Popover from 'material-ui/Popover';
import Menu from 'material-ui/Menu';
import MenuItem from 'material-ui/MenuItem';
export default class PopoverExampleSimple extends React.Component {
constructor(props) {
super(props);
... |
imports/ui/components/tools/tools.js | guillefix/augmath | import React from 'react';
import ReactDOM from 'react-dom';
// import * as manip from '../../maths/manipulations.js';
import * as hist from '../history';
import * as act from '../../../redux/actions/action-creators';
import RecordPlayControl from './record-play-control.js';
export default class Tools extends React.C... |
app/components/LoadingIndicator/index.js | adoveil/max | import React from 'react';
import styles from './styles.css';
function LoadingIndicator() {
return (
<div>
<div className={styles['sk-fading-circle']}>
<div className={styles.skCircle}></div>
<div className={styles['sk-circle2']}></div>
<div className={styles['sk-circle3']}></div>
... |
pages/terms/index.js | ISMAELMARTINEZ/linkuk | import React from 'react';
import Layout from '../../components/Layout';
import s from './terms.css'
class TermsPage extends React.Component {
componentDidMount() {
document.title = 'Terms'
}
render() {
return (
<Layout>
<div className={s.terms}>
<h1>Link-SF Terms of Service</h1... |
tests/framework.spec.js | dfalling/todo | import assert from 'assert'
import React from 'react'
import {mount, render, shallow} from 'enzyme'
class Fixture extends React.Component {
render () {
return (
<div>
<input id='checked' defaultChecked />
<input id='not' defaultChecked={false} />
</div>
)
}
}
describe('(Framewo... |
lib/controllers/dashboard.js | ebertmi/webbox | 'use strict';
import React from 'react';
import ReactDOMServer from 'react-dom/server';
import { Provider } from 'react-redux';
import Hoek from 'hoek';
import { RouterContext, match } from 'react-router';
import dashboardStore from '../../common/store/dashboardStore';
import adminRoutes from '../../common/route/Admin... |
app/components/Header/Header.js | rakasiwi23/currency-converter | import React from 'react';
import { View, TouchableOpacity, Image } from 'react-native';
import PropTypes from 'prop-types';
import styles from './styles';
const gear = require('./images/gear.png');
const Header = ({ onPress }) => (
<View style={styles.container} >
<TouchableOpacity style={styles.button} onPres... |
examples/03 - Basic auth/vendor/requireAuth.js | gilesvangruisen/browserify-react-live | import React from 'react';
import auth from './auth';
export default (Component) => {
return class Authenticated extends React.Component {
static willTransitionTo(transition) {
if (!auth.loggedIn()) {
transition.redirect('/login', {}, {
'nextPath': transition.path,
});
}
... |
js/fw/components/list/list-separator.js | linh918/react-native-starter-kit-demo- | import React, { Component } from 'react';
import {
Container,
Header,
Title,
Content,
Button,
Icon,
List,
ListItem,
Text,
Left,
Right,
Body,
Separator,
} from 'native-base';
import styles from './styles';
class NHListSeparator extends Component {
render() {
return (
<Container style={styles.contain... |
src/App/Recipes/Recipes.js | trevorgk/kilvo | import React from 'react';
import { AsidedLayout, Card } from 'seek-style-guide/react';
import { Route } from 'react-router-dom';
import CategoryAccordion from './CategoryAccordion/CategoryAccordion';
import recipes from './dads_recipes.json';
import RecipeDetails from './RecipeDetails/RecipeDetails';
import Welcome fr... |
packages/benchmarks/src/implementations/styled-jsx/Box.js | css-components/styled-components | /* eslint-disable react/prop-types */
import classnames from 'classnames';
import React from 'react';
import { style } from './View';
const getColor = color => {
switch (color) {
case 0:
return '#14171A';
case 1:
return '#AAB8C2';
case 2:
return '#E6ECF0';
case 3:
return '#FFA... |
src/js/react/presentational/inputs/NumberInput.js | koluch/db-scheme | // @flow
import React from 'react'
import cn from 'bem-cn'
import FilteredInput from './FilteredInput'
const bem = cn('number-input')
const numbersFilter = (value: string): boolean => {
return /^[0-9]*$/g.test(value)
}
const numbersConverter = (value: string): number => {
if (!numbersFilter(value)) {
... |
ReactApp/components/__tests__/loading-tests.js | feirari/ITS484Project | /**
* Test to check if the component renderes correctly
*/
'use strict';
import 'react-native'
import React from 'react'
import Loading from '../loading'
import renderer from 'react-test-renderer'
/**
* Check if alerts renders correcly
* and asserting it to the matching snapshot
*/
it('Loading renders correcly',... |
src/parser/priest/shadow/modules/spells/VoidformAverageStacks.js | fyruna/WoWAnalyzer | import React from 'react';
import SPELLS from 'common/SPELLS';
import Analyzer from 'parser/core/Analyzer';
import { formatNumber } from 'common/format';
import SpellIcon from 'common/SpellIcon';
import SpellLink from 'common/SpellLink';
import { TooltipElement } from 'common/Tooltip';
import StatisticBox from 'inte... |
src/components/GithubButton/GithubButton.js | zunperior/wear4cast | import React from 'react';
const GithubButton = (props) => {
const {user, repo, type, width, height, count, large} = props;
let src = `https://ghbtns.com/github-btn.html?user=${user}&repo=${repo}&type=${type}`;
if (count) src += '&count=true';
if (large) src += '&size=large';
return (
<iframe
src=... |
admin/client/App/index.js | helloworld3q3q/keystone | /**
* This is the main entry file, which we compile the main JS bundle from. It
* only contains the client side routing setup.
*/
// Needed for ES6 generators (redux-saga) to work
import 'babel-polyfill';
import React from 'react';
import ReactDOM from 'react-dom';
import { Router, Route, browserHistory, IndexRoute... |
app/components/Home/RightPanel/RightPanel.js | rjzheng/kzhomepanel | import React from 'react';
import PhotoWidget from 'PhotoWidget';
import NewsWidget from 'NewsWidget';
function RightPanel() {
return (
<div className="right-panel">
<PhotoWidget />
<NewsWidget />
</div>
)
};
export default RightPanel;
|
src/layouts/layout-4-4.js | nuruddeensalihu/binary-next-gen | import React from 'react';
export default (components, className, onClick) => (
<div className={className} onClick={onClick}>
<div className="horizontal">
{components[0]}
</div>
<div className="vertical">
{components[1]}
{components[2]}
{compo... |
mobile/src/App.js | lnmx/goread | import React, { Component } from 'react';
import ReactDOM from 'react-dom';
import idbKeyval from 'idb-keyval';
import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider';
import AppBar from 'material-ui/AppBar';
import Dialog from 'material-ui/Dialog';
import IconButton from 'material-ui/IconButton';
import ... |
docs/app/Examples/views/Feed/Content/FeedExampleIconLabelShorthand.js | vageeshb/Semantic-UI-React | import React from 'react'
import { Feed } from 'semantic-ui-react'
const FeedExampleIconLabelShorthand = () => (
<Feed>
<Feed.Event
icon='pencil'
date='Today'
summary="You posted on your friend Stevie Feliciano's wall."
/>
<Feed.Event>
<Feed.Label icon='pencil' />
<Feed.Con... |
blueocean-material-icons/src/js/components/svg-icons/action/android.js | jenkinsci/blueocean-plugin | import React from 'react';
import SvgIcon from '../../SvgIcon';
const ActionAndroid = (props) => (
<SvgIcon {...props}>
<path d="M6 18c0 .55.45 1 1 1h1v3.5c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5V19h2v3.5c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5V19h1c.55 0 1-.45 1-1V8H6v10zM3.5 8C2.67 8 2 8.67 2 9.5v7c0 .83.67 1.5 1.5 ... |
public/src/components/rss-app_es6.js | alannesta/redux-rss | import React from 'react';
import FeedList from './feed-list_es6';
import FeedSearchInput from './feed-search-input_es6';
import {FeedContent} from './feed-content_es6' // another syntax of import
import ViewManager from './view-manager';
var FeedStore = require('../stores/feed-store');
var FeedAction = require('../a... |
Front-End/components/login.component.js | brandonrninefive/prIDE | import React from 'react';
import ReactDOM from 'react-dom';
import {Grid, Row, Col, Button, FormGroup, FormControl} from 'react-bootstrap';
class Login extends React.Component {
constructor(props){
super(props);
this.state = {
loggingIn:false
};
this.handleSubmit = this.handleSubmit.bind(this);
this.login = t... |
src/AgesEditor.js | OCMC-Translation-Projects/ioc-liturgical-react | import React from 'react';
import PropTypes from 'prop-types';
import {Alert, Button, Col, ControlLabel, Glyphicon, Grid, Row, Table, Well} from 'react-bootstrap';
import ModalParaRowEditor from './ModalParaRowEditor';
import { get } from 'lodash';
import Spinner from './helpers/Spinner';
import server from './helpers/... |
app/jsx/assignments_2/student/components/AttemptType/UrlEntry.js | djbender/canvas-lms | /*
* Copyright (C) 2019 - present Instructure, Inc.
*
* This file is part of Canvas.
*
* Canvas is free software: you can redistribute it and/or modify it under
* the terms of the GNU Affero General Public License as published by the Free
* Software Foundation, version 3 of the License.
*
* Canvas is distribut... |
src/icons/AddCircleOutlineIcon.js | kiloe/ui | import React from 'react';
import Icon from '../Icon';
export default class AddCircleOutlineIcon extends Icon {
getSVG(){return <svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" viewBox="0 0 48 48"><path d="M26 14h-4v8h-8v4h8v8h4v-8h8v-4h-8v-8zM24 4C12.95 4 4 12.95 4 24s8.95 20 20 20 20-8.95 20-20S35.05... |
packages/material-ui-icons/src/DirectionsRailway.js | cherniavskii/material-ui | import React from 'react';
import createSvgIcon from './utils/createSvgIcon';
export default createSvgIcon(
<g><path d="M4 15.5C4 17.43 5.57 19 7.5 19L6 20.5v.5h12v-.5L16.5 19c1.93 0 3.5-1.57 3.5-3.5V5c0-3.5-3.58-4-8-4s-8 .5-8 4v10.5zm8 1.5c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm6-7H6V5h12v5z" /></g>
, 'Directi... |
src/main.js | koyumeishi/atcoder_script | //import React from 'react';
//import ReactDOM from 'react-dom';
import AtCoderCutomStandings from './app.js'
import injectCustomCSS from './css.js'
$('div.table-responsive').hide();
$('#pagination-standings').hide();
$('#standings-csv-link').after('<div id="content"></div>');
//$('head').append('<link href="https://f... |
node_modules/rc-dialog/es/Dialog.js | prodigalyijun/demo-by-antd | import _classCallCheck from 'babel-runtime/helpers/classCallCheck';
import _createClass from 'babel-runtime/helpers/createClass';
import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';
import _inherits from 'babel-runtime/helpers/inherits';
var __assign = this && this.__assign || Obje... |
frontend/src/components/pdf-viewer.js | miurahr/seahub | import React from 'react';
import { gettext } from '../utils/constants';
class PDFViewer extends React.Component {
render() {
return (
<React.Fragment>
<div id="outerContainer">
<div id="sidebarContainer" className="sf-hide">
<div id="toolbarSidebar">
<div clas... |
src/admin/components/component/index.js | ccetc/platform | import React from 'react'
import _ from 'lodash'
import { connect } from 'react-redux'
import { getActiveTeam } from 'admin/components/admin/selectors'
import * as actions from './actions'
export default (mapComponentStateToProps, mapComponentDispatchToProps, PlainComponent, namespace, isNew) => {
const wrappedMapC... |
src/app/presentation/view/components/SearchBar.js | RPallas92/GrausJS | /**
* The MIT License (MIT)
*
* Copyright (c) 2016 Ricardo Pallas
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to... |
app/containers/App/index.js | lizhaogai/lyda-dada-v | /**
*
* App.react.js
*
* This component is the skeleton around the actual pages, and should only
* contain code that should be seen on all pages. (e.g. navigation bar)
*/
import React from 'react';
import Helmet from 'react-helmet';
import styled from 'styled-components';
const AppWrapper = styled.div`
margin... |
pootle/static/js/admin/components/Language/LanguageController.js | Yelp/pootle | /*
* Copyright (C) Pootle contributors.
*
* This file is a part of the Pootle project. It is distributed under the GPL3
* or later license. See the LICENSE file for a copy of the license and the
* AUTHORS file for copyright and authorship information.
*/
import React from 'react';
import Search from '../Search'... |
src/app/components/pages/About.js | cmseguin/react-express-boilerplate | import Nav from '~/app/components/modules/Nav'
import React from 'react'
export default class About extends React.Component {
render () {
return (
<div>
<Nav />
<h1>About</h1>
</div>
)
}
}
|
frontend/src/components/forms/fields/projectFields/organizationType.js | unicef/un-partner-portal |
import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import SelectForm from '../../selectForm';
import { selectNormalizedOrganizationTypes } from '../../../../store';
const CountryField = (props) => {
const { fieldName, label, values, ...other } = props;
return (... |
tests/components/Header/Header.spec.js | jaronoff97/listmkr | import React from 'react'
import { Header } from 'components/Header/Header'
import { IndexLink, Link } from 'react-router'
import { shallow } from 'enzyme'
describe('(Component) Header', () => {
let _wrapper
beforeEach(() => {
_wrapper = shallow(<Header/>)
})
it('Renders a welcome message', () => {
c... |
src/routes/Grid/Route/components/HomeView.js | taikongfeizhu/webpack-develop-startkit | import React from 'react'
import moment from 'moment'
import PropTypes from 'prop-types'
import { Link } from 'react-router'
import { Button, Row, Col } from 'antd'
import CustomCard from 'components/CustomCard'
import './HomeView.less'
const EnumPostStatus = {
UNPUBLISH: '1',
PUBLISHED: '2'
}
class HomeView exte... |
js/jqwidgets/demos/react/app/chart/100stackedareaseries/app.js | luissancheza/sice | import React from 'react';
import ReactDOM from 'react-dom';
import JqxChart from '../../../jqwidgets-react/react_jqxchart.js';
class App extends React.Component {
render() {
let source =
{
datatype: 'tab',
datafields: [
{ name: 'Date' },
... |
lib/PressRippleAnimation.js | timomeh/react-native-material-bottom-navigation | import React from 'react'
import PropTypes from 'prop-types'
import { Animated, Dimensions, Platform } from 'react-native'
import * as easings from './utils/easing'
export default class PressRippleAnimation extends React.PureComponent {
static propTypes = {
x: PropTypes.number.isRequired,
y: PropTypes.numbe... |
src/Sidenav/test/SidenavSpec.js | suitejs/suite | import React from 'react';
import ReactTestUtils from 'react-dom/test-utils';
import { getDOMNode } from '@test/testUtils';
import Sidenav from '../Sidenav';
import Nav from '../../Nav';
import Dropdown from '../../Dropdown';
describe('Sidenav', () => {
it('Should render a navigation', () => {
const instance = ... |
packages/storybook-cmf/src/register.js | Talend/ui | import React from 'react';
import addons from '@storybook/addons';
export default function register() {
addons.register('react-storybook-cmf', api => {
const channel = addons.getChannel();
addons.addPanel('react-storybook-cmf/panel', {
title: 'CMF',
render: () => (
<div>
{channel} {api}
</div>
... |
acceptance/src/components/Nav.js | Autodesk/hig | import React from 'react';
import { Link } from 'react-router-dom';
function Nav({ routes }) {
return (
<nav>
<ul style={{ display: "flex" }}>
{routes.map(r => (
<div key={r.path} style={{ padding: "4px" }}>
<Link to={r.path}>{r.label}</Link>
</div>
))}
... |
src/app/Header.js | jiv-e/preact-widget-boilerplate | import React from 'react'
import logo from '../assets/logo.svg'
const Header = () => (
<div className="app-header">
<img src={logo} className="app-logo" alt="logo" />
<h1>Preact widget boilerplate</h1>
</div>
)
export default Header |
app/static/scripts/main.js | joshleeb/Tobio-PreRelease | import LandingView from './landingView/main.js';
import Layout from './layout/main.js';
import React from 'react';
import ReactDOM from 'react-dom';
require('./style/global.scss');
ReactDOM.render(
<Layout><LandingView /></Layout>,
document.getElementById('tobioweb')
);
|
fields/types/textarray/TextArrayFilter.js | matthieugayon/keystone | import React from 'react';
import ReactDOM from 'react-dom';
import { FormField, FormInput, FormSelect } from 'elemental';
const MODE_OPTIONS = [
{ label: 'Contains', value: 'contains' },
{ label: 'Exactly', value: 'exactly' },
{ label: 'Begins with', value: 'beginsWith' },
{ label: 'Ends with', value: 'endsWith'... |
docs/src/app/components/pages/components/Toggle/Page.js | verdan/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 toggleReadmeText from './README';
import ToggleExampleSimple from './Exam... |
app/components/CountdownTimer/index.js | markmadej/foosball-ref | /*
* CountdownTimer
*
* This component represents the number of seconds left on a given rod.
* When clicked, this starts counting down the time.
*
*/
import React from 'react';
export default class CountdownTimer extends React.PureComponent { // eslint-disable-line react/prefer-stateless-function
render() {
... |
src/components/ActivityIndicator.js | dingbat/react-native-mock | /**
* https://github.com/facebook/react-native/blob/master/Libraries/Components/ActivityIndicator/ActivityIndicator.js
*/
import React from 'react';
import NativeMethodsMixin from '../mixins/NativeMethodsMixin';
import View from './View';
import ColorPropType from '../propTypes/ColorPropType';
const { PropTypes } = ... |
packages/material-ui-icons/src/RepeatOne.js | dsslimshaddy/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from 'material-ui/SvgIcon';
let RepeatOne = props =>
<SvgIcon {...props}>
<path d="M7 7h10v3l4-4-4-4v3H5v6h2V7zm10 10H7v-3l-4 4 4 4v-3h12v-6h-2v4zm-4-2V9h-1l-2 1v1h1.5v4H13z" />
</SvgIcon>;
RepeatOne = pure(RepeatOne);
RepeatOne.muiN... |
src/EditTextField.js | ml7757/To-Do-React | import React from 'react';
import { Link } from 'react-router';
class EditTextField extends React.Component {
constructor() {
super();
this.props = {
isEditable: true
};
this.state = {
editing: false,
value: ""
};
}
textChanged(event) {
console.log(this.refs.input.val... |
src/index.js | andela-milesanmi/mai-docs | import 'babel-polyfill';
import React from 'react';
import { render } from 'react-dom';
import { Provider } from 'react-redux';
import store from './store';
import Routes from './components/Routes.jsx';
import { setDefaultHeader } from './utils/helper';
import '../node_modules/materialize-css/dist/js/materialize.min';... |
routes.js | Sigfried/minerva | import React from 'react';
import { Route } from 'react-router';
import App from './containers/App';
import PatientViz from './components/PatientViz';
//import UserPage from './containers/UserPage';
//import RepoPage from './containers/RepoPage';
export default (
<Route path="/" component={App}>
<Route path="/pa... |
src/components/BricksList.js | pjamieson/react-redux-landing-page | import React, { Component } from 'react';
import { bindActionCreators } from 'redux';
import { connect } from 'react-redux';
import { selectTechnology } from '../actions/index.js';
import { Button } from 'reactstrap';
import './BricksList.css';
class BricksList extends Component {
renderList() {
return this.prop... |
app/index.js | PHPiotr/phpiotr4 | import React from 'react';
import {hydrate} from 'react-dom';
import {AppContainer, setConfig} from 'react-hot-loader';
import {Provider} from 'react-redux';
import {BrowserRouter as Router} from 'react-router-dom';
import 'isomorphic-fetch';
import configureStore from './configureStore';
import reducers from './reduce... |
src/Layout/__tests__/Header-test.js | Graf009/react-mdl | /* eslint-env mocha */
import expect from 'expect';
import React from 'react';
import { render } from '../../__tests__/render';
import { Header, HeaderRow, HeaderTabs } from '../';
describe('Layout', () => {
describe('Header', () => {
it('should render a header with the specific css class', () => {
... |
app/containers/SettingsPage/TableEmployment.js | zebbra-repos/Zeiterfassung-medi | import React from 'react';
import PropTypes from 'prop-types';
import moment from 'moment';
class EmploymentSettingTable extends React.PureComponent {
render() {
const genRows = (sectionIndex) => {
const rows = [];
this.props.employments.forEach((employment, index) => {
const hours = ((emplo... |
src/utils/createContextWrapper.js | collinwu/react-bootstrap | import React from 'react';
/**
* Creates new trigger class that injects context into overlay.
*/
export default function createContextWrapper(Trigger, propName) {
return function (contextTypes) {
class ContextWrapper extends React.Component {
getChildContext() {
return this.props.context;
}... |
app/tabs/TabsView.ios.js | future-challenger/react-native-dribbble-app | /*
Created by Uncle Charlie, 2016/12/24
@flow
*/
import React from 'react'
import {
TabBarIOS,
Navigator
} from 'react-native'
import {connect} from 'react-redux'
import {switchTab} from '../actions'
class TabsView extends React.Component {
onTabSelect(tab) {
if(this.props.tab !== tab) {
this.pr... |
app/containers/PanelContainer/index.js | mwksl/HL7 | /*
*
* PanelContainer
*
*/
import React from 'react';
import { connect } from 'react-redux';
import selectPanelContainer from './selectors';
import styles from './styles.css';
export class PanelContainer extends React.Component { // eslint-disable-line react/prefer-stateless-function
render() {
return (
... |
app/javascript/mastodon/features/lists/index.js | rutan/mastodon | import React from 'react';
import { connect } from 'react-redux';
import PropTypes from 'prop-types';
import ImmutablePropTypes from 'react-immutable-proptypes';
import LoadingIndicator from '../../components/loading_indicator';
import Column from '../ui/components/column';
import ColumnBackButtonSlim from '../../compo... |
fields/types/relationship/RelationshipColumn.js | vokal/keystone | import React from 'react';
import ItemsTableCell from '../../components/ItemsTableCell';
import ItemsTableValue from '../../components/ItemsTableValue';
const moreIndicatorStyle = {
color: '#bbb',
fontSize: '.8rem',
fontWeight: 500,
marginLeft: 8,
};
var RelationshipColumn = React.createClass({
displayName: 'Rel... |
client/src/components/BackButton/tests/BackButton-story.js | open-sausages/silverstripe-asset-admin | import React from 'react';
// eslint-disable-next-line import/no-extraneous-dependencies
import { storiesOf } from '@storybook/react';
import { Component as BackButton } from 'components/BackButton/BackButton';
storiesOf('AssetAdmin/BackButton', module)
.add('Default', () => (
<BackButton />
))
.add('With ba... |
postcss-with-react/app/routes.js | sunitJindal/react-tutorial | import React from 'react';
import IndexRoute from 'react-router/lib/IndexRoute';
import Route from 'react-router/lib/Route';
import App from './index';
import ProductList from './components/ProductList/container/ProductList';
import Product from './components/Product/container/Product';
export default (
<Route path... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.