-
Notifications
You must be signed in to change notification settings - Fork 336
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
re-add segment metadata fix #1086 fix #1047 #1088
Changes from all commits
74adbce
656ca84
ad8fdf2
d3886b3
d220d80
ce22715
7a4a4e6
acec67f
4e990cb
4a9287f
7750e93
9c2d5ce
830bafe
1173540
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import PropTypes from 'prop-types'; | ||
import React, {Component} from 'react'; | ||
import Helmet from 'react-helmet'; | ||
|
||
export default class ParabolHelmet extends Component { | ||
static contextTypes = { | ||
analytics: PropTypes.object | ||
}; | ||
|
||
static propTypes = { | ||
title: PropTypes.string | ||
}; | ||
|
||
componentDidMount() { | ||
this.context.analytics.title = this.props.title; | ||
} | ||
|
||
componentWillReceiveProps(nextProps) { | ||
if (nextProps.title !== this.props.title) { | ||
this.context.analytics.title = nextProps.title; | ||
} | ||
} | ||
|
||
render() { | ||
return <Helmet {...this.props} />; | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,6 +11,7 @@ import withKeyboardShortcuts from './withKeyboardShortcuts'; | |
import withLinks from './withLinks'; | ||
import withSuggestions from './withSuggestions'; | ||
import entitizeText from 'universal/utils/draftjs/entitizeText'; | ||
import './Draft.css'; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This css file fails a production build. See: https://circleci.com/gh/ParabolInc/action/2904 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. oh silly me i bet i didn't add it to the prod webpack config |
||
|
||
class ProjectEditor extends Component { | ||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,53 +1,35 @@ | ||
import PropTypes from 'prop-types'; | ||
import React, {Component} from 'react'; | ||
import React from 'react'; | ||
import {DragDropContext as dragDropContext} from 'react-dnd'; | ||
import HTML5Backend from 'react-dnd-html5-backend'; | ||
import {Switch} from 'react-router-dom'; | ||
import {socketClusterReducer} from 'redux-socket-cluster'; | ||
import AsyncRoute from 'universal/components/AsyncRoute/AsyncRoute'; | ||
import socketWithPresence from 'universal/decorators/socketWithPresence/socketWithPresence'; | ||
import withReducer from '../../decorators/withReducer/withReducer'; | ||
import withAsync from 'react-async-hoc'; | ||
|
||
const parentMod = () => System.import('universal/components/DashboardWrapper/DashboardWrapper'); | ||
const meetingMod = () => System.import('universal/modules/meeting/containers/MeetingContainer/MeetingContainer'); | ||
|
||
class SocketRoute extends Component { | ||
shouldComponentUpdate() { | ||
return false; | ||
} | ||
render() { | ||
return ( | ||
<Switch> | ||
<AsyncRoute | ||
path="(/me|/newteam|/team)" | ||
mod={parentMod} | ||
/> | ||
<AsyncRoute | ||
path="/meeting/:teamId/:localPhase?/:localPhaseItem?" | ||
mod={meetingMod} | ||
/> | ||
</Switch> | ||
); | ||
} | ||
} | ||
const dashWrapper = () => System.import('universal/components/DashboardWrapper/DashboardWrapper'); | ||
const meetingContainer = () => System.import('universal/modules/meeting/containers/MeetingContainer/MeetingContainer'); | ||
|
||
const SocketRoute = () => { | ||
return ( | ||
<Switch> | ||
<AsyncRoute isAbstract path="(/me|/newteam|/team)" mod={dashWrapper} /> | ||
<AsyncRoute path="/meeting/:teamId/:localPhase?/:localPhaseItem?" mod={meetingContainer} /> | ||
</Switch> | ||
); | ||
}; | ||
|
||
SocketRoute.propTypes = { | ||
match: PropTypes.object.isRequired | ||
}; | ||
|
||
const fetchStyles = { | ||
'/static/css/Draft.css': () => ({stylesLoaded: true}) | ||
}; | ||
|
||
export default | ||
withAsync(undefined, fetchStyles)( | ||
withReducer({socket: socketClusterReducer})( | ||
dragDropContext(HTML5Backend)( | ||
socketWithPresence( | ||
SocketRoute | ||
) | ||
withReducer({socket: socketClusterReducer})( | ||
dragDropContext(HTML5Backend)( | ||
socketWithPresence( | ||
SocketRoute | ||
) | ||
) | ||
); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍