path stringlengths 5 195 | repo_name stringlengths 5 79 | content stringlengths 25 1.01M |
|---|---|---|
app/clients/next/components/form/input.js | koapi/koapp | import React from 'react'
import { FormGroup, Label, Input, FormFeedback } from 'reactstrap'
import Select, { Creatable } from 'react-select'
import VirtualizedSelect from 'react-virtualized-select'
import Toggle from 'react-toggle'
import TagsInput from 'react-tagsinput'
import classnames from 'classnames'
export def... |
examples/animated-framer-motion/src/index.js | react-tools/react-table | import React from 'react'
import ReactDOM from 'react-dom'
import './index.css'
import App from './App'
ReactDOM.render(<App />, document.getElementById('root'))
|
src/components/common/FileTypeIcon.js | olavoholanda/nocdo | import React from 'react'
import SvgIcon from 'material-ui/SvgIcon';
const PDFIcon = () => (
<SvgIcon viewBox="0 0 56 56">
<g>
<path style={{fill: "#E9E9E0"}} d="M36.985,0H7.963C7.155,0,6.5,0.655,6.5,1.926V55c0,0.345,0.655,1,1.463,1h40.074
c0.808,0,1.463-0.655,1.463-1V12.978c0-0.696-0.093-0.9... |
app/app/components/Dashboard/HomeDashboard.js | lycha/masters-thesis | import React from 'react';
import ProgramLogo from './ProgramLogo';
import NumberStatistics from './NumberStatistics';
import Conversion from './Conversion';
import LeadsStatisticsChart from './LeadsStatisticsChart';
import RegisterationsStatisticsChart from './RegisterationsStatisticsChart';
import AnalysisParameters ... |
src/js/components/icons/base/Diamond.js | odedre/grommet-final | /**
* @description Diamond SVG Icon.
* @property {string} a11yTitle - Accessibility Title. If not set uses the default title of the status icon.
* @property {string} colorIndex - The color identifier to use for the stroke color.
* If not specified, this component will default to muiTheme.palette.textColor.
* @pr... |
bayty/src/components/common/Header.js | Asmaklf/bayty | // Import libraries for making a component
import React from 'react';
import { Text, View } from 'react-native';
// Make a component
const Header = (props) => {
const { textStyle, viewStyle } = styles;
return (
<View style={viewStyle}>
<Text style={textStyle}>{props.headerText}</Text>
</View>
);
}... |
src/Grid/components/Grid.js | ambitioninc/react-ui | import React from 'react';
import Header from './Header';
import Row from './Row';
import {getClassName, noop} from '../../utils';
class Grid extends React.Component {
constructor(...args) {
super(...args);
this.state = {
activeCell: [-1, -1],
activeHeader: -1,
... |
components/ButtonDropdown/index.js | SaraVieira/30-30 | // @flow
import React, { Component } from 'react';
import Button from '../Button';
import style from './style.css';
type Props = {
buttonContent: string,
children: Element
}
type State = {
opened: boolean
}
class ButtonDropdown extends Component {
props: Props;
constructor(props: Props) {
super(props)... |
src/components/ApplyToHostBtn.js | OpenCollective/frontend | import React from 'react';
import PropTypes from 'prop-types';
import { FormattedMessage } from 'react-intl';
import withIntl from '../lib/withIntl';
import Button from './Button';
import ApplyToHostBtnLoggedIn from './ApplyToHostBtnLoggedIn';
import { get } from 'lodash';
import HelpTooltip from './HelpTooltip';
cla... |
components/BodyTypePicker.js | request-factory/request-factory | import React from 'react';
import { Picker } from 'native-base';
import { View } from 'react-native';
export class BodyTypePicker extends React.Component {
constructor(props) {
super(props);
this.state = {
};
}
render() {
return (
<View style={{ borderWidth: 0.5, borderColor: '#d6d7da', ..... |
cm19/ReactJS/your-first-react-app-exercises-master/exercise-16-hooks/theme/Provider.js | Brandon-J-Campbell/codemash | import React from 'react';
import ThemeContext from './context';
export default class ThemeProvider extends React.Component {
state = {
theme: 'purple',
};
handleThemeChange = () => {
this.setState(prevState => ({
theme: prevState.theme === 'green' ? 'purple' : 'green',
}));
};
render() ... |
examples/todos/src/index.js | pavelivanov/redaction | import React from 'react'
import { render } from 'react-dom'
import { Provider } from 'react-redux'
import App from './components/App'
import store from './core/store'
render(
<Provider store={store}>
<App />
</Provider>,
document.getElementById('root')
)
|
src/components/Nodebar/Nodebar.js | okoala/react-redux-antd | import React from 'react'
import { bindActionCreators } from 'redux'
import { connect } from 'react-redux'
import Action from '../../store/actions'
import { Link } from 'react-router'
import './Nodebar.less'
@connect(
state => ({...state}),
dispatch => bindActionCreators(Action, dispatch)
)
export default class N... |
src/Parser/Monk/Mistweaver/Modules/Items/T20_4set.js | enragednuke/WoWAnalyzer | import React from 'react';
import SPELLS from 'common/SPELLS';
import SpellLink from 'common/SpellLink';
import SpellIcon from 'common/SpellIcon';
import Combatants from 'Parser/Core/Modules/Combatants';
import Analyzer from 'Parser/Core/Analyzer';
import calculateEffectiveHealing from 'Parser/Core/calculateEffectiveH... |
blueprint/Shared.js | mutualmobile/Brazos | import React, { Component } from 'react';
import { inject, observer } from 'mobx-react';
import platformCode from './/* @echo CLASSNAME */Ext';
//@inject("store")
@observer
export default class /* @echo CLASSNAME */ extends Component {
constructor(props) {
super(props);
this.store = this.props.store;
navigation... |
website/core/WebPlayer.js | foghina/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/Tabs/Page.js | JohnCrash/react-tiku | import React from 'react';
import Title from 'react-title-component';
import CodeExample from '../CodeExample';
import PropTypeDescription from '../Util/PropTypeDescription';
import MarkdownElement from '../Util/MarkdownElement';
import tabsReadmeText from './README.md';
import tabsExampleSimpleCode from './E... |
App/Containers/AddMessage.js | arthur31416/latte | import React from 'react'
import {
ScrollView,
View,
Text,
KeyboardAvoidingView,
TouchableOpacity
} from 'react-native'
import { connect } from 'react-redux'
import Actions from '../Actions/Creators'
import { Actions as NavigationActions } from 'react-native-router-flux'
// import { Metrics } from '../Themes'... |
new-lamassu-admin/src/index.js | lamassu/lamassu-server | import React from 'react'
import ReactDOM from 'react-dom'
import App from './App'
import * as serviceWorker from './serviceWorker'
function checkBuildTarget() {
const buildTarget = process.env.REACT_APP_BUILD_TARGET
if (buildTarget !== 'LAMASSU' && buildTarget !== 'PAZUZ') {
return Promise.reject(
new... |
App/Components/Tile.js | FAC7/anna-freud-hub | import React from 'react'
import {
View,
Text,
Image,
StyleSheet,
TouchableWithoutFeedback,
TouchableHighlight
} from 'react-native'
const icon = require('../Assets/Icons/attending.png')
export default (props) => {
return (
<TouchableWithoutFeedback
onPress={props.linkRoute}
>
<View ... |
renderer/components/Onboarding/Steps/components/ErrorDialog.js | LN-Zap/zap-desktop | import React from 'react'
import PropTypes from 'prop-types'
import { Flex, Box } from 'rebass/styled-components'
import { FormattedMessage } from 'react-intl'
import Delete from 'components/Icon/Delete'
import { Dialog, Heading, DialogOverlay, Text, Button } from 'components/UI'
import messages from './messages'
cons... |
src/svg-icons/content/add-box.js | pancho111203/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ContentAddBox = (props) => (
<SvgIcon {...props}>
<path d="M19 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-2 10h-4v4h-2v-4H7v-2h4V7h2v4h4v2z"/>
</SvgIcon>
);
ContentAddBox = pu... |
internals/templates/languageProvider/languageProvider.js | sedubois/belong | /*
*
* LanguageProvider
*
* this component connects the redux state language locale to the
* IntlProvider component and i18n messages (loaded from `app/translations`)
*/
import React from 'react';
import { connect } from 'react-redux';
import { createSelector } from 'reselect';
import { IntlProvider } from 'reac... |
src/components/Header/index.js | leafydream/react-redux-starter | import React from 'react';
import { NavLink } from 'react-router-dom';
import styles from './style.scss';
const Header = () => {
return (
<div className={styles.header}>
<h1>React Redux Starter</h1>
<NavLink to="/" activeClassName={styles.active}>Home</NavLink>
{' · '}
... |
test/components/Timestamp-test.js | davrodpin/grommet | // (C) Copyright 2014-2016 Hewlett Packard Enterprise Development LP
import {test} from 'tape';
import React from 'react';
import TestUtils from 'react-addons-test-utils';
import Timestamp from '../../src/js/components/Timestamp';
import CSSClassnames from '../../src/js/utils/CSSClassnames';
const CLASS_ROOT = CSSCl... |
docs/app/Examples/elements/Header/Variations/HeaderInvertedExample.js | jamiehill/stardust | import React from 'react'
import { Header, Segment } from 'stardust'
const HeaderInvertedExample = () => (
<Segment className='inverted'>
<Header as='h4' inverted color='red'>Red</Header>
<Header as='h4' inverted color='orange'>Orange</Header>
<Header as='h4' inverted color='yellow'>Yellow</Header>
<... |
docs/app/Examples/views/Item/Types/Items.js | jcarbo/stardust | import React from 'react'
import { Image, Item } from 'stardust'
const Items = () => (
<Item.Group>
<Item>
<Item.Image size='tiny' src='http://semantic-ui.com/images/wireframe/image.png' />
<Item.Content>
<Item.Header as='a'>Header</Item.Header>
<Item.Meta>Description</Item.Meta>
... |
docs/app/Examples/views/Statistic/Variations/StatisticExampleEvenlyDivided.js | Rohanhacker/Semantic-UI-React | import React from 'react'
import { Icon, Image, Statistic } from 'semantic-ui-react'
const StatisticExampleEvenlyDivided = () => (
<Statistic.Group widths='four'>
<Statistic>
<Statistic.Value>22</Statistic.Value>
<Statistic.Label>Saves</Statistic.Label>
</Statistic>
<Statistic>
<Statis... |
src/icons/WifiIcon.js | kiloe/ui | import React from 'react';
import Icon from '../Icon';
export default class WifiIcon extends Icon {
getSVG(){return <svg xmlns="http://www.w3.org/2000/svg" width="48" height="48" viewBox="0 0 48 48"><path d="M2 18l4 4c9.94-9.94 26.06-9.94 36 0l4-4C33.85 5.85 14.15 5.85 2 18zm16 16l6 6 6-6c-3.31-3.31-8.69-3.31-12 0zm... |
vertex_ui/src/components/ColorPicker/Chrome/ChromeFields.js | zapcoop/vertex | /* eslint-disable react/no-did-mount-set-state, no-param-reassign */
import React from 'react';
import reactCSS from 'reactcss';
import color from 'react-color/lib/helpers/color';
import { EditableInput } from 'react-color/lib/components/common';
export class ChromeFields extends React.Component {
state = {
vi... |
src/svg-icons/image/brightness-2.js | frnk94/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageBrightness2 = (props) => (
<SvgIcon {...props}>
<path d="M10 2c-1.82 0-3.53.5-5 1.35C7.99 5.08 10 8.3 10 12s-2.01 6.92-5 8.65C6.47 21.5 8.18 22 10 22c5.52 0 10-4.48 10-10S15.52 2 10 2z"/>
</SvgIcon>
);
I... |
docs/app/Examples/collections/Table/Types/index.js | Rohanhacker/Semantic-UI-React | import React from 'react'
import ExampleSection from 'docs/app/Components/ComponentDoc/ExampleSection'
import ComponentExample from 'docs/app/Components/ComponentDoc/ComponentExample'
const Types = () => {
return (
<ExampleSection title='Types'>
<ComponentExample
title='Types'
description=... |
services/ui/src/components/Footer/index.stories.js | amazeeio/lagoon | import React from 'react';
import Footer from './index';
export default {
component: Footer,
title: 'Components/Footer',
};
export const Default = () => <Footer />;
|
app/components/VideoPlayer.js | cdiezmoran/AlphaStage-2.0 | import React from 'react';
import { string } from 'prop-types';
import VideoJS from '../libs/VideoJS';
const VideoPlayer = ({ src, id }) => {
const videoJsOptions = {
autoplay: false,
controls: true,
className: 'video-js vjs-default-skin',
poster: 'https://image.ibb.co/jh0EYH/placeholder_black.png',
... |
information/blendle-frontend-react-source/app/containers/overlays/PremiumVerifiedOverlayContainer.js | BramscoChill/BlendleParser | import React, { Component } from 'react';
import PropTypes from 'prop-types';
import AltContainer from 'alt-container';
import PremiumSubscriptionActions from 'actions/PremiumSubscriptionActions';
import AuthStore from 'stores/AuthStore';
import Twitter from 'instances/twitter';
import VerifiedOverlay from 'components/... |
frontend/src/pages/sys-admin/orgs/org-nav.js | miurahr/seahub | import React from 'react';
import PropTypes from 'prop-types';
import { Link } from '@reach/router';
import { siteRoot, gettext } from '../../../utils/constants';
const propTypes = {
currentItem: PropTypes.string.isRequired
};
class Nav extends React.Component {
constructor(props) {
super(props);
this.na... |
src/components/common/Hue.js | JunisphereSystemsAG/react-color | 'use strict' /* @flow */
import React from 'react'
import ReactCSS from 'reactcss'
import shallowCompare from 'react-addons-shallow-compare'
export class Hue extends ReactCSS.Component {
shouldComponentUpdate = shallowCompare.bind(this, this, arguments[0], arguments[1])
classes(): any {
return {
'defau... |
src/components/MessageMedia/MessageMedia.js | nolawi/champs-dialog-sg | /**
* Copyright 2017 dialog LLC <info@dlg.im>
* @flow
*/
import type { MessageMedia as MessageMediaType } from '@dlghq/dialog-types';
import React from 'react';
import MessageMediaWebpage from './MessageMediaWebpage';
import MessageMediaVoice from './MessageMediaVoice';
import MessageMediaImage from './MessageMedia... |
src/js/components/icons/base/Subtract.js | kylebyerly-hp/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... |
app/assets/javascripts/components/story/ExpandedStory/ExpandedStoryEstimate.js | Codeminer42/cm42-central | import React from 'react';
import PropTypes from 'prop-types';
import { isFeature, editingStoryPropTypesShape } from '../../../models/beta/story';
import ProjectPropTypes from '../../shapes/project';
import ExpandedStorySection from './ExpandedStorySection';
const extractValue = (event) => {
const parsedValue = pars... |
node_modules/react-bootstrap/es/FormControlFeedback.js | firdiansyah/crud-req | import _objectWithoutProperties from 'babel-runtime/helpers/objectWithoutProperties';
import _extends from 'babel-runtime/helpers/extends';
import _classCallCheck from 'babel-runtime/helpers/classCallCheck';
import _possibleConstructorReturn from 'babel-runtime/helpers/possibleConstructorReturn';
import _inherits from ... |
packages/lore-hook-forms-bootstrap/src/config.js | lore/lore-forms | /* eslint no-param-reassign: "off" */
import React from 'react';
import CreateOptimisticBlueprint from './blueprints/create/Optimistic';
import CreateOverlayBlueprint from './blueprints/create/Overlay';
import CreateWizardBlueprint from './blueprints/create/Wizard';
import UpdateOptimisticBlueprint from './blueprints/... |
examples/react-and-react-router/src/javascripts/global.js | pandoraui/backbone-react-component | // Init Backbone jquery object
import $ from 'jquery';
import Backbone from 'backbone';
Backbone.$ = $;
import React from 'react';
import Router from 'react-router';
import BackboneReactMixin from 'backbone-react-component';
let {Route, RouteHandler, Link, State, Navigation} = Router;
class Person extends Backbone.M... |
src/containers/VehicleRoute.js | mick842/rental-cars-client | import React from 'react';
import { Redirect } from 'react-router-dom';
import VehiclePage from '../components/VehiclePage';
import { CircularProgress, Dialog, FlatButton } from 'material-ui';
import VehiclesAPI from '../services/api/VehiclesAPI';
class VehicleRoute extends React.Component {
constructor(props) {
... |
shared/components/SubComponents/Question/Textfield.js | KCPSoftware/KCPS-React-Starterkit | import React, { Component } from 'react';
import { connect } from 'react-redux';
import { saveQuestion } from '../../../actions/questionActions';
import Validation from '../../../utils/validation/Validation';
import InputValidation from '../../../utils/validation/InputValidation';
import { TooltipTrigger } from 'pui-re... |
P/lixil/src/pages/App.js | imuntil/React | import React from 'react'
import {
BrowserRouter as Router,
Route,
Switch
} from 'react-router-dom'
import createHistory from 'history/createBrowserHistory'
import AboutPage from './About'
import HomePage from './Home'
import NewsPage from './News'
import ContactPage from './Contact'
import EcoPage from './Produ... |
app/containers/NotFoundPage/index.js | lizhaogai/lyda-dada-v | /**
* NotFoundPage
*
* This is the page we show when the user visits a url that doesn't have a route
*/
import React from 'react';
import messages from './messages';
import { FormattedMessage } from 'react-intl';
import H1 from 'components/H1';
export default function NotFound() {
return (
<article>
... |
app/javascript/flavours/glitch/features/list_editor/components/search.js | Kirishima21/mastodon | import React from 'react';
import PropTypes from 'prop-types';
import { defineMessages } from 'react-intl';
import classNames from 'classnames';
import Icon from 'flavours/glitch/components/icon';
const messages = defineMessages({
search: { id: 'lists.search', defaultMessage: 'Search among people you follow' },
});
... |
node_modules/react-bootstrap/es/ModalHeader.js | vietvd88/developer-crawler | 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 ... |
ui/src/main/js/components/TaskConfigSummary.js | apache/aurora | import moment from 'moment';
import React from 'react';
import { RelativeTime } from 'components/Time';
import { isNully } from 'utils/Common';
import { formatMb } from 'utils/Quota';
import { constraintToString, getResource, getResources, instanceRangeToString } from 'utils/Task';
import { COLLISION_POLICY } from 'u... |
web-app/src/components/OnBoard/Fase1/Slides/Slide2.js | oSoc17/code9000 | import React from 'react';
import Polaroid from '../../../Polaroid';
import { Slide } from '../components/Slider';
import commonTern1 from '../pictures/common_tern_1.jpeg';
import commonTern2 from '../pictures/common_tern_2.jpeg';
import commonTern3 from '../pictures/common_tern_3.jpeg';
const Slide2 = () => (
<Sl... |
src/svg-icons/alert/add-alert.js | mmrtnz/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let AlertAddAlert = (props) => (
<SvgIcon {...props}>
<path d="M10.01 21.01c0 1.1.89 1.99 1.99 1.99s1.99-.89 1.99-1.99h-3.98zm8.87-4.19V11c0-3.25-2.25-5.97-5.29-6.69v-.72C13.59 2.71 12.88 2 12 2s-1.59.71-1.59 1.59v... |
app/features/dashboard/SrsChart/renderActiveShape.js | Kaniwani/KW-Frontend | import React from 'react';
import PropTypes from 'prop-types';
import { Sector } from 'recharts';
import { grey, black } from 'common/styles/colors';
renderActiveShape.propTypes = {
cx: PropTypes.number.isRequired,
cy: PropTypes.number.isRequired,
innerRadius: PropTypes.number.isRequired,
outerRadius: PropType... |
src/components/ThemeToggle.js | cadejscroggins/cadejs.com | import React from 'react';
import styled, { createGlobalStyle } from 'styled-components';
import padding from '../utilities/padding';
import { transitionSpeed } from '../utilities/animations';
const ThemeToggleStyled = styled.button`
position: absolute;
top: 0;
right: 0;
padding: ${padding.xs};
border: none;... |
src/svg-icons/alert/warning.js | pradel/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let AlertWarning = (props) => (
<SvgIcon {...props}>
<path d="M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"/>
</SvgIcon>
);
AlertWarning = pure(AlertWarning);
AlertWarning.displayName = 'AlertWarning';
exp... |
index.ios.js | TimoSta/laps | /**
* Sample React Native App
* https://github.com/facebook/react-native
* @flow
*/
import React, { Component } from 'react';
import {
AppRegistry,
StyleSheet,
Text,
View
} from 'react-native';
class laps extends Component {
render() {
return (
<View style={styles.container}>
<Text sty... |
packages/ui-toolkit/src/divider/index.js | yldio/joyent-portal | import React from 'react';
import styled from 'styled-components';
import { Row } from 'joyent-react-styled-flexboxgrid';
import is from 'styled-is';
import remcalc from 'remcalc';
const HorizontalDivider = styled(Row)`
height: 1px;
background-color: ${props => props.theme.grey};
height: ${props => props.height}... |
example/src/reduxUsageApp.js | lapanoid/redux-cropper | import React from 'react';
import PureComponent from 'react-pure-render/component';
import { getBlob, reduxApp as Cropper, CropperPreview, imageUtils } from 'redux-cropper';
const imgPath = require("../img/watson.jpg");
const { getBlobFromUrl } = imageUtils;
const options = {
viewMode: 1,
wheelZoomRatio: 0.5,
aspe... |
app/javascript/mastodon/features/search/index.js | Kirishima21/mastodon | import React from 'react';
import SearchContainer from 'mastodon/features/compose/containers/search_container';
import SearchResultsContainer from 'mastodon/features/compose/containers/search_results_container';
const Search = () => (
<div className='column search-page'>
<SearchContainer />
<div className='... |
examples/todomvc/index.js | idolize/redux | import 'babel/polyfill';
import React from 'react';
import Root from './containers/Root';
import 'todomvc-app-css/index.css';
React.render(
<Root />,
document.getElementById('root')
);
|
blueprints/view/files/__root__/views/__name__View/__name__View.js | NTU-ArtFest22/Monitor-web | import React from 'react'
type Props = {
};
export class <%= pascalEntityName %> extends React.Component {
props: Props;
render () {
return (
<div></div>
)
}
}
export default <%= pascalEntityName %>
|
examples/src/app.js | submittable/react-select | /* eslint react/prop-types: 0 */
import React from 'react';
import ReactDOM from 'react-dom';
import Select from 'react-select';
import './example.less';
import Creatable from './components/Creatable';
import Contributors from './components/Contributors';
import GithubUsers from './components/GithubUsers';
import Cus... |
src/components/app-wrapper.js | translatium/translatium | /* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
import React from 'react';
import PropTypes from 'prop-types';
import { ThemeProvider as MuiThemeProvider, create... |
web/src/js/components/Settings/Profile/ProfileStatsComponent.js | gladly-team/tab | import React from 'react'
import PropTypes from 'prop-types'
import moment from 'moment'
import { Helmet } from 'react-helmet'
import { withStyles } from '@material-ui/core/styles'
import Paper from '@material-ui/core/Paper'
import Button from '@material-ui/core/Button'
import ChartIcon from '@material-ui/icons/InsertC... |
index.js | corbt/react-native-keep-awake | // @flow
import React, { Component } from 'react';
import { NativeModules } from 'react-native';
let mounted = 0;
export default class KeepAwake extends Component<{}> {
static activate() {
NativeModules.KCKeepAwake.activate();
}
static deactivate() {
NativeModules.KCKeepAwake.deactivate();
}
comp... |
actor-apps/app-web/src/app/components/sidebar/ContactsSectionItem.react.js | boyley/actor-platform | import React from 'react';
import ReactMixin from 'react-mixin';
import addons from 'react/addons';
import DialogActionCreators from 'actions/DialogActionCreators';
import AvatarItem from 'components/common/AvatarItem.react';
const {addons: { PureRenderMixin }} = addons;
@ReactMixin.decorate(PureRenderMixin)
class ... |
local-cli/templates/HelloNavigation/views/welcome/WelcomeScreen.js | skevy/react-native | 'use strict';
import React, { Component } from 'react';
import {
Image,
Platform,
StyleSheet,
} from 'react-native';
import ListItem from '../../components/ListItem';
import WelcomeText from './WelcomeText';
export default class WelcomeScreen extends Component {
static navigationOptions = {
title: 'Welc... |
src/controllers/_entry.js | fightingm/blog |
import React from 'react';
import { render } from 'react-dom';
import { Router,Route,Link,IndexRoute,hashHistory } from 'react-router';
import Default from '../views/Default';
import Hello from '../views/Hello';
import About from '../views/About';
import Portfolio from '../views/Portfolio';
import Photos from '../vi... |
src/components/icons/Jekyll.js | dtjv/dtjv.github.io | import React from 'react'
export const JekyllIcon = ({ className, ...props }) => (
<svg
{...props}
className={`text-jekyll ${className}`}
role="img"
fill="currentColor"
viewBox="0 0 24 24"
xmlns="http://www.w3.org/2000/svg"
>
<title>Jekyll</title>
<path d="M8.073 24c-.348 0-.689-.06... |
docs/src/app/components/pages/components/Paper/ExampleSimple.js | pomerantsev/material-ui | import React from 'react';
import Paper from 'material-ui/Paper';
const style = {
height: 100,
width: 100,
margin: 20,
textAlign: 'center',
display: 'inline-block',
};
const PaperExampleSimple = () => (
<div>
<Paper style={style} zDepth={1} />
<Paper style={style} zDepth={2} />
<Paper style={s... |
src/components/Navbar/Navbar.js | hahoocn/hahoo-admin | import React from 'react';
import IndexLink from 'react-router/lib/IndexLink';
import { IndexLinkContainer, LinkContainer } from 'react-router-bootstrap';
import Navbar from 'react-bootstrap/lib/Navbar';
import Nav from 'react-bootstrap/lib/Nav';
import NavItem from 'react-bootstrap/lib/NavItem';
import NavDropdown fro... |
analysis/druidferal/src/modules/spells/SwipeHitCount.js | yajinni/WoWAnalyzer | import React from 'react';
import SPELLS from 'common/SPELLS';
import { SpellLink } from 'interface';
import { STATISTIC_ORDER } from 'parser/ui/StatisticBox';
import { t } from '@lingui/macro';
import HitCountAoE from '../core/HitCountAoE';
/**
* Swipe shouldn't be used against a single target, the player's resourc... |
src/svg-icons/notification/live-tv.js | manchesergit/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let NotificationLiveTv = (props) => (
<SvgIcon {...props}>
<path d="M21 6h-7.59l3.29-3.29L16 2l-4 4-4-4-.71.71L10.59 6H3c-1.1 0-2 .89-2 2v12c0 1.1.9 2 2 2h18c1.1 0 2-.9 2-2V8c0-1.11-.9-2-2-2zm0 14H3V8h18v12zM9 10v8... |
src/components/ModalUnitEdit/ModalUnitEdit.js | fkn/ndo | import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import {
FormControl,
Checkbox,
ControlLabel,
FormGroup,
HelpBlock,
Tabs,
Tab,
} from 'react-bootstrap';
import Modal from '../../components/Modal';
import TextEditor from '../../components/TextEditor';
i... |
packages/ui-toolkit/src/footer/index.js | geek/joyent-portal | import React from 'react';
import styled from 'styled-components';
import remcalc from 'remcalc';
const List = styled.ul`
background: ${props => props.theme.background};
display: flex;
list-style: none;
padding: ${remcalc(12)} ${remcalc(18)};
border-top: ${remcalc(1)} solid ${props => props.theme.grey};
wi... |
frontend/src/Artist/ArtistImage.js | lidarr/Lidarr | import PropTypes from 'prop-types';
import React, { Component } from 'react';
import LazyLoad from 'react-lazyload';
function findImage(images, coverType) {
return images.find((image) => image.coverType === coverType);
}
function getUrl(image, coverType, size) {
if (image) {
// Remove protocol
let url = i... |
components/ContactForm.js | grraft/next-boilerplate | import React from 'react'
import { Field, reduxForm } from 'redux-form'
import { fetchRandomImage } from '../redux/actions'
const SimpleForm = (props) => {
const { handleSubmit, pristine, reset, submitting } = props
return (
<form onSubmit={handleSubmit}>
<div className='form-group'>
<label htmlF... |
src/components/common/inputLabel/inputLabel.js | lleohao/meow-ui | import './inputLabel.css';
import React, { Component } from 'react';
import { Button, Input } from 'antd';
export class InputLabel extends Component {
constructor(props) {
super(props);
this.state = {
inEdit: false
};
}
toggleEdit = status => {
this.setState({... |
src/icons/VolumeMute.js | fbfeix/react-icons | import React from 'react';
import IconBase from './../components/IconBase/IconBase';
export default class VolumeMute extends React.Component {
render() {
if(this.props.bare) {
return <g>
<g>
<polygon points="255.9,217 191,217 191,295 255.9,295 303,346.3 303,165.7 "></polygon>
<path d="M364.5,60.1c-0.4-0.2-0.7-... |
public/js/cat_source/es6/components/quality_report/FileDetails.js | matecat/MateCat | import React from 'react'
import SegmentQR from './SegmentQR'
class FileDetails extends React.Component {
getSegments() {
let segments = []
this.props.segments.forEach((item) => {
let segment = (
<SegmentQR
key={item.get('id')}
segment={item}
urls={this.props.urls... |
src/containers/Interfaces/NameGeneratorList.js | codaco/Network-Canvas | import React, { Component } from 'react';
import { bindActionCreators, compose } from 'redux';
import { connect } from 'react-redux';
import PropTypes from 'prop-types';
import { differenceBy, omit, get } from 'lodash';
import withPrompt from '../../behaviours/withPrompt';
import { actionCreators as sessionsActions } f... |
ZWRNProject/index.ios.js | MisterZhouZhou/ReactNativeLearing | /**
* Sample React Native App
* https://github.com/facebook/react-native
* @flow
*/
import React from 'react';
import {
AppRegistry,
} from 'react-native';
import Start from './app/src/views/StartView'
if (!__DEV__) {
global.console = {
info: () => {},
log: () => {},
warn: () => {},
error: (... |
app/javascript/mastodon/components/status_content.js | ashfurrow/mastodon | import React from 'react';
import ImmutablePropTypes from 'react-immutable-proptypes';
import PropTypes from 'prop-types';
import { FormattedMessage } from 'react-intl';
import Permalink from './permalink';
import classnames from 'classnames';
import PollContainer from 'mastodon/containers/poll_container';
import Icon ... |
docs/app/Examples/elements/Image/Variations/ImageExampleCircular.js | clemensw/stardust | import React from 'react'
import { Image } from 'semantic-ui-react'
const ImageExampleCircular = () => (
<Image src='/assets/images/wireframe/square-image.png' size='medium' shape='circular' />
)
export default ImageExampleCircular
|
src/svg-icons/image/exposure-plus-2.js | kasra-co/material-ui | import React from 'react';
import pure from 'recompose/pure';
import SvgIcon from '../../SvgIcon';
let ImageExposurePlus2 = (props) => (
<SvgIcon {...props}>
<path d="M16.05 16.29l2.86-3.07c.38-.39.72-.79 1.04-1.18.32-.39.59-.78.82-1.17.23-.39.41-.78.54-1.17.13-.39.19-.79.19-1.18 0-.53-.09-1.02-.27-1.46-.18-.44-... |
assets/jqwidgets/demos/react/app/notification/fluidsize/app.js | juannelisalde/holter | import React from 'react';
import ReactDOM from 'react-dom';
import JqxNotification from '../../../jqwidgets-react/react_jqxnotification.js';
class App extends React.Component {
render () {
return (
<JqxNotification ref='jqxNotification' style={{ marginTop: 40 }}
width={'80%'} ... |
app/javascript/mastodon/features/compose/components/text_icon_button.js | h-izumi/mastodon | import React from 'react';
import PropTypes from 'prop-types';
class TextIconButton extends React.PureComponent {
static propTypes = {
label: PropTypes.string.isRequired,
title: PropTypes.string,
active: PropTypes.bool,
onClick: PropTypes.func.isRequired,
ariaControls: PropTypes.string,
};
... |
react/private/FieldLabel/FieldLabel.js | seekinternational/seek-asia-style-guide | import styles from './FieldLabel.less';
import React, { Component } from 'react';
import PropTypes from 'prop-types';
import classnames from 'classnames';
import Text from '../../Text/Text';
import Strong from '../../Strong/Strong';
import Secondary from '../../Secondary/Secondary';
function combineClassNames(props ... |
src/components/markdown/code.js | mbeaudru-mrkl/addon-info-meta | import React from 'react';
import PropTypes from 'prop-types';
export class Code extends React.Component {
render() {
const codeStyle = {
fontFamily: 'Menlo, Monaco, "Courier New", monospace',
backgroundColor: '#fafafa',
marginBottom: 15,
fontSize: 14
};
const preStyle = {
... |
src/client/utils/hocs.js | AlexanderKapelyukhovskiy/rcn.io | import React from 'react'
//logs component's rendering time in MS
const logRenderPerf = function(WrappedComp, name = '<Unknown Component Name>') {
return class RenderPerf extends React.Component {
constructor(props) {
super(props)
this.whenRenderStarted = 0
}
componentDidMount() {
cons... |
chat/chat/Day.js | wph1129/react-native-chat | import React from 'react';
import {
StyleSheet,
Text,
View,
} from 'react-native';
import moment from 'moment';
export default class Day extends React.Component {
render() {
if (!this.props.isSameDay(this.props.currentMessage, this.props.previousMessage)) {
return (
<View style={[styles.cont... |
src/components/Header.js | knod/cliff-effects-1 | import React from 'react';
import { Segment } from 'semantic-ui-react';
import { MainMenu } from './MainMenu';
import { BetaWarning } from './BetaWarning';
class Header extends React.Component {
render() {
return (
<Segment
id = { `appHeader` }
className = { `header-segment` }
... |
ui/src/shared/components/DeleteConfirmTableCell.js | brianbaker/chronograf | import React from 'react'
import DeleteConfirmButtons from 'shared/components/DeleteConfirmButtons'
const DeleteConfirmTableCell = props => (
<td className="text-right" style={{width: '85px'}}>
<DeleteConfirmButtons {...props} />
</td>
)
export default DeleteConfirmTableCell
|
site/components/not-found.js | JamesHageman/redux-datagrid | import React from 'react';
const NotFound = () => <div>
<h2>Page Not Found</h2>
<p>Sorry, the page you're looking for can't be found.</p>
</div>;
export default NotFound;
|
Learn_Redux_NoteApp/app/components/Note.js | canhphong/canhphong.github.io | import React from 'react';
class Note extends React.Component{
removeNote() {
var {index, handleRemove} = this.props;
handleRemove(index);
}
render(){
return (
<div>
<p>{this.props.children}</p>
<button onClick={this.removeNote.bind(this)}>Delete</button>
</div>
);
}
}
modul... |
src/client/assets/js/features/examples/components/ExampleManager/ExampleManager.js | me-box/platform-sdk | import React, { Component } from 'react';
import {connect} from 'react-redux';
import { bindActionCreators } from 'redux';
import Drawer from 'react-md/lib/Drawers';
import Toolbar from 'react-md/lib/Toolbars';
import Button from 'react-md/lib/Buttons';
import Avatar from 'react-md/lib/Avatars';
import ListItem from ... |
packages/cf-component-header/src/Hamburger.js | jroyal/cf-ui | import React from 'react';
import PropTypes from 'prop-types';
import { Icon } from 'cf-component-icon';
import { createComponent } from 'cf-style-container';
const Wrapper = createComponent(
({ theme }) => ({
borderRight: `1px solid ${theme.color.smoke}`,
padding: '0.9em 1em 1em 1em',
userSelect: 'none'... |
internals/templates/containers/HomePage/index.js | ParAnton/ngps-gui-core | /*
* HomePage
*
* This is the first thing users see of our App, at the '/' 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 and remove
* the l... |
src/index.js | csc-huxiaowei/react-template | const reducers = require('./reducers');
import React from 'react';
import { render } from 'react-dom';
import { Provider } from 'react-redux';
import configureStore from './stores';
import {Header} from './containers';
import App from './containers/App';
import { combineReducers, applyMiddleware } from 'redux'
import {... |
definitions/npm/react-css-modules_v3.x.x/flow_v0.53.x-/react-css-modules_v3.x.x.js | hansonw/flow-typed | // @flow
import React from 'react';
declare module 'react-css-modules' {
declare function exports<P, S, C: React$Component<P, S>, X>(
component: Class<C>,
styles: X,
options?: {|
allowMultiple?: boolean,
errorWhenNotFound?: boolean,
|}
): Class<React$Component<$Diff<P, { styles: X }>, S... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.