Skip to content
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

@kanaabe => Text component / Paragraph updates #1222

Merged
merged 11 commits into from
Aug 18, 2017
Merged

Conversation

eessex
Copy link
Contributor

@eessex eessex commented Aug 14, 2017

  • Adds Reaction Text component to Text Section
  • Change import style for Draft imports
  • Replace 'rich_text2/input_paragraph' with 'rich_text2/paragraph' (will also replace rich_text_caption in a separate PR)
  • Changes sectionContainer to mimic Reaction component naming
  • Kills handleBackspace error

@eessex eessex self-assigned this Aug 15, 2017
@eessex eessex force-pushed the more-text branch 2 times, most recently from 0546c1c to 1045cad Compare August 16, 2017 15:35
@eessex eessex changed the title [WIP] Text component / Paragraph updates @kanaabe => Text component / Paragraph updates Aug 16, 2017
@eessex eessex assigned kanaabe and eessex and unassigned eessex Aug 16, 2017
Embed = React.createFactory require '../../content/sections/embed/index.coffee'
Fullscreen = React.createFactory require '../../content/sections/fullscreen/index.coffee'
ImageCollection = React.createFactory require '../sections/image_collection/index.coffee'
Image = React.createFactory require '../../content/sections/image/index.coffee'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice renaming

Nav = React.createFactory require '../../../../../../components/rich_text2/components/nav.coffee'
InputUrl = React.createFactory require '../../../../../../components/rich_text2/components/input_url.coffee'
Text = React.createFactory components.Text
Utils = require '../../../../../../components/rich_text2/utils/index.coffee'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

margin-right 10px
margin-top .298em
text-transform uppercase

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👏

package.json Outdated
@@ -14,7 +14,7 @@
"deploy": "sh scripts/deploy.sh"
},
"dependencies": {
"@artsy/reaction-force": "^0.1.49",
"@artsy/reaction-force": "^0.3.1",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure if you want to include any of the latest Reaction work here, but I imagine we should be at a 0.4.0 now if you want it.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah cool, yeah definitely want the latest

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm going to go ahead and deploy reaction -- is still on 3.1, do i jump right to v4.0?

@@ -93,7 +93,7 @@ module.exports = React.createClass
selection = Utils.getSelectionDetails(@state.editorState)
# only merge a section if cursor is in first character of first block
if selection.isFirstBlock and selection.anchorOffset is 0 and
@props.sections.models[@props.index - 1].get('type') is 'text'
@props.sections.models[@props.index - 1]?.get('type') is 'text'
Copy link
Contributor

@kanaabe kanaabe Aug 18, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check out .at(@props.index -1)

@kanaabe
Copy link
Contributor

kanaabe commented Aug 18, 2017

I can't merge because of the conflict, but this is ready otherwise. Nice job refactoring the text component to use Reaction! It's a very ideal outcome :)

@eessex eessex merged commit f7232d2 into artsy:master Aug 18, 2017
@eessex eessex deleted the more-text branch November 27, 2017 15:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants