path stringlengths 5 195 | repo_name stringlengths 5 79 | content stringlengths 25 1.01M |
|---|---|---|
client/index.js | brucelane/react-redux | import React from 'react';
import {render} from 'react-dom';
import {Router, browserHistory} from 'react-router';
import {Provider} from 'react-redux';
import thunk from 'redux-thunk';
import {createStore, applyMiddleware, compose} from 'redux';
import rootReducer from './rootReducer';
import routes from './routes';
... |
src/svg-icons/image/filter-1.js | mit-cml/iot-website-source | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageFilter1 = (props) => (
<SvgIcon {...props}>
<path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm11 10h2V5h-4v2h2v8zm7-14H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14z"/>
... |
src/svg-icons/communication/screen-share.js | rhaedes/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let CommunicationScreenShare = (props) => (
<SvgIcon {...props}>
<path d="M20 18c1.1 0 1.99-.9 1.99-2L22 6c0-1.11-.9-2-2-2H4c-1.11 0-2 .89-2 2v10c0 1.1.89 2 2 2H0v2h24v-2h-4zm-7-3.53v-2.19c-2.78 0-4.61.85-6 2.72.56... |
examples/complex/src/components/clicker/index.js | rocjs/roc-package-web-app-react | import React, { Component } from 'react';
import styles from './style.css';
import sharedStyles from './../shared.css';
export default class Clicker extends Component {
static propTypes = {
clicker: React.PropTypes.number.isRequired,
click: React.PropTypes.func.isRequired
};
render() {
... |
src/docs/Props.js | coryhouse/ps-react | import React from 'react';
import PropTypes from 'prop-types';
const Props = ({props}) => {
return (
<table className="props">
<thead>
<tr>
<th>Name</th>
<th>Description</th>
<th>Type</th>
<th>Default</th>
<th>Required</th>
</tr>
</the... |
app/components/ImgModal/index.js | vlastoun/picture-uploader-crud | import React from 'react';
import PropTypes from 'prop-types';
import Modal from 'react-modal';
import styled from 'styled-components';
import Button from 'components/Button';
/* eslint-disable react/prefer-stateless-function */
const ButtonDiv = styled.div`
margin-bottom: 10px;
`;
const modalStyle = {
content: {
... |
node_modules/react-native/local-cli/templates/HelloNavigation/views/welcome/WelcomeText.ios.js | joan17cast/Enigma | 'use strict';
import React, { Component } from 'react';
import {
StyleSheet,
Text,
View,
} from 'react-native';
export default class WelcomeText extends Component {
render() {
return (
<View style={styles.container}>
<Text style={styles.welcome}>
Welcome to React Native!
</... |
client/scripts/app.js | amitava82/radiole | /**
* Created by amitava on 30/01/16.
*/
import React from 'react';
import { connect } from 'react-redux';
import {push} from 'react-router-redux';
import Helmet from 'react-helmet';
import {SITE_DESC} from './constants';
import Header from './components/Header';
import Sidebar from './components/SideBar';
import Toa... |
app/views/profile/index.js | jtparrett/countcals | import React from 'react'
import { Text, View, ScrollView, AsyncStorage, Button } from 'react-native'
import Header from '../../components/header'
export default class Profile extends React.Component {
constructor(props) {
super(props)
this.state = {
API: props.API,
onLogout: props.onLogout,
... |
packages/react-instantsearch-dom/src/widgets/Snippet.js | algolia/react-instantsearch | import { connectHighlight } from 'react-instantsearch-core';
import Snippet from '../components/Snippet';
/**
* Renders any attribute from an hit into its highlighted snippet form when relevant.
*
* Read more about it in the [Highlighting results](guide/Highlighting_results.html) guide.
* @name Snippet
* @kind wi... |
public/src/components/feed-content_es6.js | alannesta/redux-rss | import React from 'react';
class FeedContent extends React.Component{
constructor(props) {
super(props);
}
render () {
var content = [];
this.props.content.forEach(function(item) {
content.push(<section><h2>{item.title}</h2><div>{item.contentSnippet}</div></section>);
});
return (
<section clas... |
src/svg-icons/notification/airline-seat-recline-extra.js | pancho111203/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let NotificationAirlineSeatReclineExtra = (props) => (
<SvgIcon {...props}>
<path d="M5.35 5.64c-.9-.64-1.12-1.88-.49-2.79.63-.9 1.88-1.12 2.79-.49.9.64 1.12 1.88.49 2.79-.64.9-1.88 1.12-2.79.49zM16 19H8.93c-1.48 0... |
src/examples/components/SocialButtons/index.js | sdarmaputra/react-following-container | import React from 'react';
import './socialButtons.scss';
const SocialButtons = (props) => (
<div className='social-buttons'>
{
props.actions.map((action, index) => {
return (
<a className={`social-buttons__item social-buttons__item--${action.type}`} key={index}>
<i className={action.icon}></i>
</a... |
packages/ringcentral-widgets/components/ActiveCallButton/index.js | ringcentral/ringcentral-js-widget | import React from 'react';
import PropTypes from 'prop-types';
import classnames from 'classnames';
import CircleButton from '../CircleButton';
import styles from './styles.scss';
export default function ActiveCallButton(props) {
const className = classnames(styles.btnSvg, props.className);
const buttonClassName ... |
higher-demo/react-all/react-all-demo/src/router/router.js | CFshuming/react-demo-gather | import React from 'react';
import {BrowserRouter as Router, Route, Switch, Link} from 'react-router-dom';
import Home from 'pages/Home/Home';
import Page1 from 'pages/Page1/Page1';
import Counter from 'pages/Counter/Counter';
import UserInfo from 'pages/UserInfo/UserInfo';
const getRouter = () => (
<Router>
... |
docs/src/app/components/pages/components/Divider/ExampleForm.js | pancho111203/material-ui | import React from 'react';
import Divider from 'material-ui/Divider';
import Paper from 'material-ui/Paper';
import TextField from 'material-ui/TextField';
const style = {
marginLeft: 20,
};
const DividerExampleForm = () => (
<Paper zDepth={2}>
<TextField hintText="First name" style={style} underlineShow={fal... |
src/javascript/wizard/media_resolution.js | apertus-open-source-cinema/elmyra | import Octicon, { Clippy, Info } from '@primer/octicons-react';
import React from 'react';
import CameraType from './camera_type.js';
export default class MediaResolution extends React.Component {
static navigationTitle = 'Resolution';
constructor(props) {
super(props);
this.state = {
height: 640,
... |
app/components/HelpView/RelationshipsHelp.js | trevornelson/wld-frontend | /**
*
* RelationshipsHelp
*
*/
import React from 'react';
class RelationshipsHelp extends React.PureComponent { // eslint-disable-line react/prefer-stateless-function
render() {
return (
<div>
<h2>Key Relationships Help</h2>
<h3>“Success is what you know, raised to the who you know.”</h3>
... |
front_end/src/pages/Approvals/ApprovalsPage.js | mozilla/splice | import React, { Component } from 'react';
import { connect } from 'react-redux';
import { pageVisit } from 'actions/App/AppActions';
class ApprovalsPage extends Component {
componentDidMount() {
}
render() {
return (
<div>
<h1>Approval Queue</h1>
</div>
);
}
}
ApprovalsPage.propT... |
docs/app/Examples/modules/Rating/Types/RatingExampleRating.js | clemensw/stardust | import React from 'react'
import { Rating } from 'semantic-ui-react'
const RatingExampleRating = () => (
<Rating />
)
export default RatingExampleRating
|
src/pages/home/HomePage.js | yang-zhang-syd/React-Wechat-E2E-Test-With-Fake-Api | import React from 'react';
import {Article, Grids} from 'react-weui';
import Page from '../../components/page/page';
import './HomePage.css';
import {persistor} from '../../store';
import * as homeActions from '../../actions/homeActions';
import {connect} from 'react-redux';
import {bindActionCreators} from 'redux';
im... |
app/components/TimeToEnd.js | ufv-js/ru-now | import React, { Component } from 'react';
export default ({}) => {
return (
<div>
<h1>Fila</h1>
</div>
)
}
|
modules/Redirect.js | buddhike/react-router | import React from 'react'
import invariant from 'invariant'
import { createRouteFromReactElement } from './RouteUtils'
import { formatPattern } from './PatternUtils'
import { falsy } from './PropTypes'
const { string, object } = React.PropTypes
/**
* A <Redirect> is used to declare another URL path a client should b... |
node_modules/react-native-vector-icons/lib/icon-button.js | jasonlarue/react-native-flashcards | import isString from 'lodash/isString';
import omit from 'lodash/omit';
import pick from 'lodash/pick';
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { StyleSheet, Text, TouchableHighlight, View } from './react-native';
const styles = StyleSheet.create({
container: {
flexDi... |
src/components/AboutPage.js | ArcanisCz/reduxPokus | import React from 'react';
import {Link} from 'react-router';
// Since this component is simple and static, there's no parent container for it.
const AboutPage = ({params}) => {
return (
<div>
<h2 className="alt-header">About ({params.userId})</h2>
<p>
This example app is part of the <a href=... |
src/components/Main/stories.js | saitodisse/scrap-cerebral-2 | import React from 'react';
import { storiesOf } from '@kadira/storybook';
import Main from './index';
storiesOf('Main', module)
.add('currentPage="jobs"', () => (
<Main currentPage=""/>
))
;
|
src/mobile/FillCircle/FillCircle.js | Krizzu/react-progressor | import React from 'react';
import propTypes from 'prop-types';
import Morph from 'art/morph/path';
import { View, ART } from 'react-native';
import { arc } from 'd3-shape';
import { scaleProgressToRadius } from './helpers/helperFunctions';
const { Surface, Shape, Group, Transform } = ART;
class FillCircle extends Re... |
interface/client/templates/index.js | ethereum/mist | /**
Template Controllers
@module Templates
*/
/**
The body template
@class [template] body
@constructor
*/
import React from 'react';
import { render } from 'react-dom';
import { Provider } from 'react-redux';
import About from '../../components/About';
import RequestAccount from '../../components/RequestAccount';
... |
src/containers/foiRequests/FoiRequestsDetailsScreen.js | jfilter/frag-den-staat-app | import { NavigationActions } from 'react-navigation';
import { connect } from 'react-redux';
import React from 'react';
import { fetchSingleFoiRequest } from '../../actions/singleFoiRequest';
import FoiRequestDetails from '../../components/screens/FoiRequestDetails';
// eslint-disable-next-line react/prop-types
const... |
app/javascript/mastodon/components/modal_root.js | NS-Kazuki/mastodon | import React from 'react';
import PropTypes from 'prop-types';
export default class ModalRoot extends React.PureComponent {
static propTypes = {
children: PropTypes.node,
onClose: PropTypes.func.isRequired,
};
state = {
revealed: !!this.props.children,
};
activeElement = this.state.revealed ? ... |
src/admin/client/modules/apps/account/components/account.js | cezerin/cezerin | import React from 'react';
import { Field, reduxForm } from 'redux-form';
import { Link } from 'react-router-dom';
import { TextField } from 'redux-form-material-ui';
import { CustomToggle } from 'modules/shared/form';
import messages from 'lib/text';
import style from './style.css';
import Paper from 'material-ui/Pa... |
webpack/hotReload.js | VasilyShelkov/React-Hot-Dev-Starter-Kit | import React from 'react';
import ReactDOM from 'react-dom';
import { AppContainer as Hot } from 'react-hot-loader';
import { Root } from '../src';
const render = () => {
ReactDOM.render(
<Hot><Root /></Hot>,
document.querySelector('react')
);
};
render();
module.hot.accept('../src', render);
|
src/parser/warlock/demonology/modules/talents/FromTheShadows.js | sMteX/WoWAnalyzer | import React from 'react';
import Analyzer, { SELECTED_PLAYER } from 'parser/core/Analyzer';
import Enemies from 'parser/shared/modules/Enemies';
import Events from 'parser/core/Events';
import calculateEffectiveDamage from 'parser/core/calculateEffectiveDamage';
import SPELLS from 'common/SPELLS';
import { formatTho... |
src/Project.js | ml7757/To-Do-React | import './stylesheets/components.scss';
import React from 'react';
import jQuery from 'jquery';
import TaskList from './TaskList';
class Project extends React.Component{
constructor(){
super();
this.state ={
project: []
}
}
renderProject(){
// we want to set the state to ... |
app/src/components/numericInput.js | bhayden1/savageReact | import {Component} from 'react';
import React from 'react';
export class Input extends Component {
render() {
return (
<label className="item-input">
<span className="input-label">{this.props.label}</span>
<input type="number" placeholder={this.props.hint} onChange={this.props.chang... |
client/util/react-intl-test-helper.js | sethkaufee/TherapyApp | /**
* Components using the react-intl module require access to the intl context.
* This is not available when mounting single components in Enzyme.
* These helper functions aim to address that and wrap a valid,
* English-locale intl context around them.
*/
import React from 'react';
import { IntlProvider, intlSha... |
docs/app/Examples/collections/Form/FieldVariations/index.js | jcarbo/stardust | import React from 'react'
import ExampleSection from 'docs/app/Components/ComponentDoc/ExampleSection'
import ComponentExample from 'docs/app/Components/ComponentDoc/ComponentExample'
const FormFieldVariationsExamples = () => (
<ExampleSection title='Field Variations'>
<ComponentExample
title='Inline'
... |
traveller/App/Components/RoundedButton.js | Alabaster-Aardvarks/traveller | // @flow
import React from 'react'
import { TouchableOpacity, Text } from 'react-native'
import styles from './Styles/RoundedButtonStyle'
import ExamplesRegistry from '../Services/ExamplesRegistry'
// Example
ExamplesRegistry.add('Rounded Button', () =>
<RoundedButton
text='harambes have curves'
onPress={()... |
src/index.js | SwordSoul/swordsoul.github.com | import React from 'react';
import ReactDOM from 'react-dom';
import App from './App';
ReactDOM.render(<App />, document.getElementById('root'));
|
app/components/Header/index.js | Princess310/react-chat-exp | import React from 'react';
import { FormattedMessage } from 'react-intl';
import NavBar from './NavBar';
import HeaderLink from './HeaderLink';
import messages from './messages';
class Header extends React.Component { // eslint-disable-line react/prefer-stateless-function
render() {
return (
<div>
... |
docs/src/app/components/pages/components/Stepper/GranularControlStepper.js | andrejunges/material-ui | import React from 'react';
import {
Step,
Stepper,
StepButton,
} from 'material-ui/Stepper';
import RaisedButton from 'material-ui/RaisedButton';
import FlatButton from 'material-ui/FlatButton';
const getStyles = () => {
return {
root: {
width: '100%',
maxWidth: 700,
margin: 'auto',
}... |
packages/netlify-cms-core/src/components/UI/Modal.js | netlify/netlify-cms | import React from 'react';
import PropTypes from 'prop-types';
import { css, Global, ClassNames } from '@emotion/core';
import ReactModal from 'react-modal';
import { transitions, shadows, lengths, zIndex } from 'netlify-cms-ui-default';
function ReactModalGlobalStyles() {
return (
<Global
styles={css`
... |
1m_Redux_Lynda/Ex_Files_Learning_Redux/Exercise Files/Ch05/05_03/finished/src/routes.js | yevheniyc/Autodidact | import React from 'react'
import { Router, Route, IndexRoute, hashHistory } from 'react-router'
import { App, Whoops404 } from './components'
import SkiDayCount from './components/containers/SkiDayCount'
import AddDayForm from './components/containers/AddDayForm'
import SkiDayList from './components/containers/SkiDayLi... |
src/components/Breadcrumb/Breadcrumb.js | wfp/ui | import PropTypes from 'prop-types';
import React from 'react';
import classnames from 'classnames';
import settings from '../../globals/js/settings';
const { prefix } = settings;
/**
* The breadcrumb is a secondary navigation pattern that helps a user understand the hierarchy among levels and navigate back through t... |
screens/Home.js | tendotosystems/lunchblast-client | import React from 'react';
import { connect } from 'react-redux'
import { StyleSheet, Text, View, ActivityIndicator, StatusBar, Button } from 'react-native';
import { authorizeUser, fetchDestination, clearError, makeSelection } from '../store/actions'
import Logo from '../components/Logo'
import ErrorMessage from '../c... |
cra-hardware-concurrency-considerate-loading/src/index.js | GoogleChromeLabs/adaptive-loading | /*
* Copyright 2019 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the 'License');
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to ... |
app/javascript/mastodon/features/ui/components/column_link.js | 3846masa/mastodon | import React from 'react';
import PropTypes from 'prop-types';
import Link from 'react-router/lib/Link';
const ColumnLink = ({ icon, text, to, href, method, hideOnMobile }) => {
if (href) {
return (
<a href={href} className={`column-link ${hideOnMobile ? 'hidden-on-mobile' : ''}`} data-method={method}>
... |
app/helpers/create_login/ApiLoginManagerMedium.js | simongfxu/violet | import React from 'react'
import ApiLoginManager from './ApiLoginManager'
import * as DataUtils from '../client_data'
import {SUPPORT_PLATFORM_MAP} from '../../helpers/const'
const PLATFORM_NAME = SUPPORT_PLATFORM_MAP.medium.name
const PLATFORM_LABEL = SUPPORT_PLATFORM_MAP.medium.label
function onLoggedIn(clientData,... |
client/modules/Solution/components/Items/Solutions.js | b3j0f/lechangement | import './Solutions.css';
import React, { Component } from 'react';
import {Card, CardActions, CardHeader, CardMedia, CardTitle, CardText} from 'material-ui/Card';
import FlatButton from 'material-ui/FlatButton';
import { NavLink } from 'react-router-dom';
class Solution extends Component {
render() {
c... |
src/LightbookApp.js | ishgroup/lightbook | import React, { Component } from 'react';
import ReactDOM from 'react-dom';
import People from './views/people/People';
import Company from './views/company/Company';
import EditPeople from './views/people/EditPeople';
import SearchModel from './model/SearchModel';
import PeopleModel from './model/PeopleModel';
import ... |
src/components/App.js | sachinisilva/ganu-denu | import React from 'react'
import {browserHistory, Router} from 'react-router'
import {Provider} from 'react-redux'
import PropTypes from 'prop-types'
import MuiThemeProvider from 'material-ui/styles/MuiThemeProvider';
class App extends React.Component {
static propTypes = {
store: PropTypes.object.isRequired,
... |
app/javascript/mastodon/components/dropdown_menu.js | cobodo/mastodon | import React from 'react';
import PropTypes from 'prop-types';
import ImmutablePropTypes from 'react-immutable-proptypes';
import IconButton from './icon_button';
import Overlay from 'react-overlays/lib/Overlay';
import Motion from '../features/ui/util/optional_motion';
import spring from 'react-motion/lib/spring';
imp... |
src/reactUtils.js | phola/react-xlsx | import React from 'react';
export const recursiveCloneChildrenAddPropstoType = (children, type, addProp) => {
return React.Children.map(children, child => {
var childProps = {}
if (React.isValidElement(child) && child.props && child.type && (child.type.name === type)) {
... |
app/javascript/mastodon/components/display_name.js | maa123/mastodon | import React from 'react';
import ImmutablePropTypes from 'react-immutable-proptypes';
import PropTypes from 'prop-types';
import { autoPlayGif } from 'mastodon/initial_state';
export default class DisplayName extends React.PureComponent {
static propTypes = {
account: ImmutablePropTypes.map.isRequired,
oth... |
vendor/htmlburger/carbon-fields/assets/js/fields/components/oembed/preview.js | FolsomCreative/storynav | /**
* The external dependencies.
*/
import $ from 'jquery';
import React from 'react';
import { renderToStaticMarkup } from 'react-dom/server';
import PropTypes from 'prop-types';
import { forEach } from 'lodash';
import { compose, withHandlers, setStatic, withProps, withState } from 'recompose';
/**
* The internal... |
src/routes/App/index.js | pl12133/pl12133.github.io | /* eslint-disable no-unused-vars*/
import React, { Component } from 'react';
/* eslint-enable no-unused-vars*/
const App = ({children}) => (
<div>
{children}
</div>
);
export default App;
|
src/shared/types/react.js | igorsvee/react-ssr | /* @flow */
// Note: we already have the definitions from
// https://github.com/facebook/flow/blob/master/lib/react.js
// so the below are merely helpful extensions.
import React from 'react';
export type ReactElement = React.Element<any>;
export type ReactNode = string | number | ReactElement | Array<ReactElement>... |
src/components/message-center/index.js | KleeGroup/focus-components | import PropTypes from 'prop-types';
import React, { Component } from 'react';
import capitalize from 'lodash/string/capitalize';
import messageStore from 'focus-core/message/built-in-store';
import { translate } from 'focus-core/translation';
const defaultProps = {
ttlError: 8000,
ttlInfo: 3000,
ttlSuccess... |
app/containers/FeaturePage/index.js | anhldbk/react-boilerplate | /*
* FeaturePage
*
* List all the features
*/
import React from 'react';
import Helmet from 'react-helmet';
import { FormattedMessage } from 'react-intl';
import H1 from 'components/H1';
import messages from './messages';
import List from './List';
import ListItem from './ListItem';
import ListItemTitle from './Li... |
src/Editor.js | mbarton/sonic-quiche | import React from 'react';
import AceEditor from 'react-ace';
import 'brace/mode/ruby';
import 'brace/theme/monokai';
export function Editor({ code, setCode, execCode, setPlayback }) {
const editorId = "sonic-quiche-editor";
const execCommand = {
name: "executeCode",
bindKey: "Shift+Enter... |
web-ui/src/common/back_link/back_link.js | pixelated/pixelated-user-agent | /*
* Copyright (c) 2017 ThoughtWorks, Inc.
*
* Pixelated 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, either version 3 of the License, or
* (at your option) any later version.
*
* Pixelated i... |
blueprints/form/files/__root__/forms/__name__Form/__name__Form.js | allanesquina/react-pomodoro | import React from 'react'
import { reduxForm } from 'redux-form'
export const fields = []
const validate = (values) => {
const errors = {}
return errors
}
type Props = {
handleSubmit: Function,
fields: Object,
}
export class <%= pascalEntityName %> extends React.Component {
props: Props;
defaultProps = ... |
client/src/components/ElementEditor/ElementActions.js | dnadesign/silverstripe-elemental | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import { compose } from 'redux';
import { DropdownItem } from 'reactstrap';
import { inject } from 'lib/Injector';
import { elementType } from 'types/elementType';
import { elementTypeType } from 'types/elementTypeType';
import AbstractAction... |
demo/examples/List.js | OnsenUI/react-onsenui | import React from 'react';
import MyToolbar from './MyToolbar';
import {
Page,
List,
ListItem,
ListHeader,
Toolbar,
ToolbarButton,
BackButton,
Button
} from '../../src/index.js';
export default class extends React.Component {
constructor(props) {
super(props);
this.state = {
data: [1,... |
src/svg-icons/places/golf-course.js | ArcanisCz/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let PlacesGolfCourse = (props) => (
<SvgIcon {...props}>
<circle cx="19.5" cy="19.5" r="1.5"/><path d="M17 5.92L9 2v18H7v-1.73c-1.79.35-3 .99-3 1.73 0 1.1 2.69 2 6 2s6-.9 6-2c0-.99-2.16-1.81-5-1.97V8.98l6-3.06z"/>
... |
client/components/Navigation/NavigationContainer.js | marcocom/portfolio-react-webpack2 | import React, { Component } from 'react';
import Navigation from './Navigation';
export default class NavigationContainer extends Component {
constructor(props) {
super(props);
this.props = props;
}
state = {
active: false,
}
componentDidMount() {
window.addEventListener('resize', this.deac... |
docs/app/Examples/views/Statistic/Types/index.js | aabustamante/Semantic-UI-React | import React from 'react'
import ComponentExample from 'docs/app/Components/ComponentDoc/ComponentExample'
import ExampleSection from 'docs/app/Components/ComponentDoc/ExampleSection'
const Types = () => (
<ExampleSection title='Types'>
<ComponentExample
title='Statistic'
description='A statistic ca... |
src/stories/layout/fundamental-layout.js | kemuridama/rectangle | import React from 'react';
export default class FundamentalLayout extends React.Component {
render() {
return (
<div className="con">
<div className="row">
<div className="c-md-6">
<div className="p">
<h3 className="p__header p__header--without-bottom-padding">1... |
app/containers/LocaleToggle/index.js | PokerGuy/react-boilerplate | /*
*
* LanguageToggle
*
*/
import React from 'react';
import { connect } from 'react-redux';
import { createSelector } from 'reselect';
import Toggle from 'components/Toggle';
import Wrapper from './Wrapper';
import messages from './messages';
import { appLocales } from '../../i18n';
import { changeLocale } from ... |
src/index.js | mariusz-zawadzki/kuznia-dusz | import React from 'react';
import ReactDOM from 'react-dom';
import { Provider } from 'react-redux';
import { createStore, applyMiddleware } from 'redux';
import './index.css';
import App from './App';
import * as types from './actions/types'
import registerServiceWorker from './registerServiceWorker';
import reducers ... |
wegas-app/src/main/node/wegas-react-form/src/Script/condition.js | Heigvd/Wegas | import PropTypes from 'prop-types';
import React from 'react';
import { types, visit } from 'recast';
const AND = '&&';
/**
* Join multiple statements into AND condition 2 by 2
* @param {Object[]} statements Array of statements
*/
function join(statements) {
const ast = statements.filter(
exp => !types.... |
src/components/event_page/chat/cant_see_chat_component.js | decaster3/hikester_redux | import React from 'react';
export default class CantSeeChatComponent extends React.Component {
constructor(props) {
super(props);
}
render() {
return (
<div >
</div>
)
}
}
|
lavalab/html/node_modules/react-bootstrap/es/MediaLeft.js | LavaLabUSC/usclavalab.org | 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 ... |
fields/types/email/EmailColumn.js | webteckie/keystone | import React from 'react';
import ItemsTableCell from '../../components/ItemsTableCell';
import ItemsTableValue from '../../components/ItemsTableValue';
var EmailColumn = React.createClass({
displayName: 'EmailColumn',
propTypes: {
col: React.PropTypes.object,
data: React.PropTypes.object,
},
renderValue () {
... |
public/index.js | datpham23/datndiana | import React from 'react';
import { render } from 'react-dom';
import {createStore,
combineReducers,
applyMiddleware,
compose} from 'redux';
import {Provider} from 'react-redux';
import thunk from 'redux-thunk';
import {Router,
Route,
... |
src/Select.js | yonaichin/react-select | import React from 'react';
import ReactDOM from 'react-dom';
import Input from 'react-input-autosize';
import classNames from 'classnames';
import stripDiacritics from './utils/stripDiacritics';
import Async from './Async';
import Option from './Option';
import Value from './Value';
function stringifyValue (value) {... |
blueocean-material-icons/src/js/components/svg-icons/content/drafts.js | jenkinsci/blueocean-plugin | import React from 'react';
import SvgIcon from '../../SvgIcon';
const ContentDrafts = (props) => (
<SvgIcon {...props}>
<path d="M21.99 8c0-.72-.37-1.35-.94-1.7L12 1 2.95 6.3C2.38 6.65 2 7.28 2 8v10c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2l-.01-10zM12 13L3.74 7.84 12 3l8.26 4.84L12 13z"/>
</SvgIcon>
);
ContentDrafts.di... |
blueocean-material-icons/src/js/components/svg-icons/action/dashboard.js | kzantow/blueocean-plugin | import React from 'react';
import SvgIcon from '../../SvgIcon';
const ActionDashboard = (props) => (
<SvgIcon {...props}>
<path d="M3 13h8V3H3v10zm0 8h8v-6H3v6zm10 0h8V11h-8v10zm0-18v6h8V3h-8z"/>
</SvgIcon>
);
ActionDashboard.displayName = 'ActionDashboard';
ActionDashboard.muiName = 'SvgIcon';
export default... |
node_modules/react-bootstrap/src/MenuItem.js | gitoneman/react-home | import React from 'react';
import classSet from 'classnames';
const MenuItem = React.createClass({
propTypes: {
header: React.PropTypes.bool,
divider: React.PropTypes.bool,
href: React.PropTypes.string,
title: React.PropTypes.string,
target: React.PropTypes.string,
onSelect: ... |
src/svg-icons/social/person-outline.js | pradel/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let SocialPersonOutline = (props) => (
<SvgIcon {...props}>
<path d="M12 5.9c1.16 0 2.1.94 2.1 2.1s-.94 2.1-2.1 2.1S9.9 9.16 9.9 8s.94-2.1 2.1-2.1m0 9c2.97 0 6.1 1.46 6.1 2.1v1.1H5.9V17c0-.64 3.13-2.1 6.1-2.1M12 4C... |
app/javascript/mastodon/components/avatar.js | pfm-eyesightjp/mastodon | import React from 'react';
import PropTypes from 'prop-types';
import ImmutablePropTypes from 'react-immutable-proptypes';
export default class Avatar extends React.PureComponent {
static propTypes = {
account: ImmutablePropTypes.map.isRequired,
size: PropTypes.number.isRequired,
style: PropTypes.object... |
app/components/TypeMenu/index.js | rapicastillo/beautifulrising-client | /**
*
* TypeMenu
*
*/
import React from 'react';
import styled from 'styled-components';
import Link from 'components/Link';
// import MenuTitle from 'components/MenuTitle';
import { FormattedMessage } from 'react-intl';
import messages from './messages';
const TypeMenuBlock = styled.div``;
const TypeMenuList = sty... |
src/components/DropdownItem/DropdownItem.js | jzhang300/carbon-components-react | import PropTypes from 'prop-types';
import React from 'react';
import classNames from 'classnames';
const DropdownItem = ({
className,
value,
itemText,
onClick,
onKeyPress,
href,
...other
}) => {
const dropdownItemClasses = classNames({
'bx--dropdown-item': true,
[className]: className,
});
... |
site/IndexPage.js | wagonhq/react-dnd | import './base.less';
import Constants, { APIPages, ExamplePages, Pages } from './Constants';
import HomePage from './pages/HomePage';
import APIPage from './pages/APIPage';
import ExamplePage from './pages/ExamplePage';
import React, { Component } from 'react';
const APIDocs = {
OVERVIEW: require('../docs/00 Quick ... |
src/views/App.js | orbitdb/orbit-web | 'use strict'
import React from 'react'
import { HashRouter as Router, Route, Switch, Redirect, useLocation } from 'react-router-dom'
import { useObserver } from 'mobx-react'
import i18n from '../config/i18n.config'
import RootStore from '../stores/RootStore'
import { addDebug } from '../utils/debug'
import { askPer... |
src/app/core/atoms/icon/icons/plus-users.js | blowsys/reservo | import React from 'react'; const PlusUsers = (props) => <svg {...props} viewBox="0 0 15 15"><g><g transform="translate(-495.000000, -473.000000)"><g transform="translate(495.000000, 473.000000)"><rect width="1" height="15" x="7"/><path d="M15,7 L15,8 L0,8 L0,7 L15,7 L15,7 Z"/></g></g></g></svg>; export default PlusUser... |
client/views/admin/settings/GroupSelector.stories.js | VoiSmart/Rocket.Chat | import React from 'react';
import GroupSelector from './GroupSelector';
export default {
title: 'admin/settings/GroupSelector',
component: GroupSelector,
};
export const _default = () => <GroupSelector />;
|
packages/ringcentral-widgets-docs/src/app/pages/Components/SlideMenu/index.js | ringcentral/ringcentral-js-widget | import React from 'react';
import { parse } from 'react-docgen';
import CodeExample from '../../../components/CodeExample';
import ComponentHeader from '../../../components/ComponentHeader';
import PropTypeDescription from '../../../components/PropTypeDescription';
import Demo from './Demo';
// eslint-disable-next-lin... |
src/components/TellUserErrorOccurredCNPJ.js | vitorbarbosa19/ziro-online | import React from 'react'
import { Image } from 'cloudinary-react'
import WhatsappIcon from './WhatsappIcon'
import { buttonStyleDark } from '../styles/styles'
export default (props) => (
<div
style={{
display: 'flex',
flexDirection: 'column',
alignItems: 'center',
fontFamily: 'karla',
... |
app/data/AboutData.js | hsin421/tacec-2017 | import React from 'react';
import styles from '../styles.css';
import aboutImg from '../images/02_about_03.png';
import tacecLogo from '../images/tacec_logo.png';
import tangLogo from '../images/tang_logo.png';
import otdLogo from '../images/otd_logo.png';
const textStyle = styles.bodyTextAbout
function Paragraph (... |
app/components/ListItem/index.js | seanng/jobmaster-web | import React from 'react';
import Item from './Item';
import Wrapper from './Wrapper';
function ListItem(props) {
return (
<Wrapper>
<Item>
{props.item}
</Item>
</Wrapper>
);
}
ListItem.propTypes = {
item: React.PropTypes.any,
};
export default ListItem;
|
pnpm-offline/.pnpm-store-offline/1/registry.npmjs.org/react-router-dom/4.1.1/es/Link.js | JamieMason/npm-cache-benchmark | var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
function _objectWithoutProperties(obj, keys) { var target = {... |
examples/huge-apps/routes/Course/routes/Assignments/routes/Assignment/components/Assignment.js | mozillo/react-router | /*globals COURSES:true */
import React from 'react'
class Assignment extends React.Component {
render() {
let { courseId, assignmentId } = this.props.params
let { title, body } = COURSES[courseId].assignments[assignmentId]
return (
<div>
<h4>{title}</h4>
<p>{body}</p>
</div>
... |
js/jqwidgets/demos/react/app/grid/addnewrow/app.js | luissancheza/sice | import React from 'react';
import ReactDOM from 'react-dom';
import JqxGrid from '../../../jqwidgets-react/react_jqxgrid.js';
import JqxRadioButton from '../../../jqwidgets-react/react_jqxradiobutton.js';
class App extends React.Component {
componentDidMount() {
this.refs.top.on('checked', () => {
... |
pages/components/note_card.js | GallenHu/Hinote | import React from 'react';
import autoBind from 'react-autobind';
import moment from 'moment';
import xss from 'xss';
export default class extends React.Component {
constructor(props) {
super(props);
this.state = {
expand: false,
};
autoBind(this);
}
handleClick(id) {
window.location.h... |
app/javascript/mastodon/features/compose/components/poll_button.js | Ryanaka/mastodon | import React from 'react';
import IconButton from '../../../components/icon_button';
import PropTypes from 'prop-types';
import { defineMessages, injectIntl } from 'react-intl';
const messages = defineMessages({
add_poll: { id: 'poll_button.add_poll', defaultMessage: 'Add a poll' },
remove_poll: { id: 'poll_button... |
src/components/autocomplete/Suggestions.js | SpicyZinc/SpicyContents | import React from 'react'
const Suggestions = (props) => {
const {
onClick,
activeSuggestion,
filteredOptions,
showSuggestions,
query
} = props;
let optionsListComponent = null;
if (showSuggestions && query) {
if (filteredOptions.length) {
optionsListComponent = (
<ul className="suggestion... |
docs/app/Examples/elements/Button/index.js | mohammed88/Semantic-UI-React | import React from 'react'
import Types from './Types'
import Groups from './Groups'
import Content from './Content'
import States from './States'
import Variations from './Variations'
import GroupVariations from './GroupVariations'
const ButtonExamples = () => (
<div>
<Types />
<Groups />
<Content />
... |
site/pages/ExamplePage.js | nagaozen/react-dnd | import React from 'react';
import Header from '../components/Header';
import PageBody from '../components/PageBody';
import SideBar from '../components/SideBar';
import { ExamplePages } from '../Constants';
export default class ExamplesPage {
render() {
return (
<div>
<Header/>
<PageBody ha... |
app/javascript/mastodon/components/collapsable.js | imomix/mastodon | import React from 'react';
import Motion from 'react-motion/lib/Motion';
import spring from 'react-motion/lib/spring';
import PropTypes from 'prop-types';
const Collapsable = ({ fullHeight, isVisible, children }) => (
<Motion defaultStyle={{ opacity: !isVisible ? 0 : 100, height: isVisible ? fullHeight : 0 }} style=... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.