{"action":"created","comment":{"url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/comments/169769067","pull_request_review_id":98350009,"id":169769067,"diff_hunk":"@@ -18,34 +53,40 @@ const ActionStepsWrapper = (props) => {\n   const stepComponents = actionSteps.map((step) => {\n     const type = get(step, 'fields.customType', false) || get(step, 'type.sys.id', false) || 'default';\n \n-    switch (type) {\n-      case 'competition':\n-        return renderCompetitionStep(step);\n-\n-      case 'photoUploaderAction':\n-      case 'photo-uploader':\n-        return renderPhotoUploader(step, isSignedUp);\n-\n-      case 'submission-gallery':\n-        return renderSubmissionGallery(isSignedUp);\n-\n-      case 'third-party-action':\n-        stepIndex += 1;\n-        return renderThirdPartyAction(step, stepIndex);\n-\n-      case 'voterRegistrationAction':\n-        return renderVoterRegistrationAction(step, stepIndex);\n-\n-      case 'shareAction':\n-        return renderShareAction(step);\n+    // Is this a \"numbered\" step? If so, increment our step index.\n+    if (['third-party-action', 'campaignActionStep', 'default'].includes(type)) {\n+      stepIndex += 1;\n+    }\n \n-      case 'linkAction':\n-        return renderLinkAction(step);\n+    // Some components have built-in section headers. For those, append it.\n+    // @TODO: These should be split out into separate \"content\" blocks.","path":"resources/assets/components/ActionPage/ActionStepsWrapper.js","position":84,"original_position":84,"commit_id":"967bb8eb74ec01e820676ca2b03b3a02d7bc1388","original_commit_id":"967bb8eb74ec01e820676ca2b03b3a02d7bc1388","user":{"login":"weerd","id":105849,"avatar_url":"https://avatars1.githubusercontent.com/u/105849?v=4","gravatar_id":"","url":"https://api.github.com/users/weerd","html_url":"https://github.com/weerd","followers_url":"https://api.github.com/users/weerd/followers","following_url":"https://api.github.com/users/weerd/following{/other_user}","gists_url":"https://api.github.com/users/weerd/gists{/gist_id}","starred_url":"https://api.github.com/users/weerd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/weerd/subscriptions","organizations_url":"https://api.github.com/users/weerd/orgs","repos_url":"https://api.github.com/users/weerd/repos","events_url":"https://api.github.com/users/weerd/events{/privacy}","received_events_url":"https://api.github.com/users/weerd/received_events","type":"User","site_admin":false},"body":"👏 ok, I hadn't gotten to this point in the changes, but this addresses my earlier comment.","created_at":"2018-02-21T20:33:55Z","updated_at":"2018-02-21T20:33:55Z","html_url":"https://github.com/DoSomething/phoenix-next/pull/693#discussion_r169769067","pull_request_url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/693","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/comments/169769067"},"html":{"href":"https://github.com/DoSomething/phoenix-next/pull/693#discussion_r169769067"},"pull_request":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/693"}}},"pull_request":{"url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/693","id":170282726,"html_url":"https://github.com/DoSomething/phoenix-next/pull/693","diff_url":"https://github.com/DoSomething/phoenix-next/pull/693.diff","patch_url":"https://github.com/DoSomething/phoenix-next/pull/693.patch","issue_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues/693","number":693,"state":"open","locked":false,"title":"Display \"action step\" blocks (like voter reg.) in affirmation modal.","user":{"login":"DFurnes","id":583202,"avatar_url":"https://avatars1.githubusercontent.com/u/583202?v=4","gravatar_id":"","url":"https://api.github.com/users/DFurnes","html_url":"https://github.com/DFurnes","followers_url":"https://api.github.com/users/DFurnes/followers","following_url":"https://api.github.com/users/DFurnes/following{/other_user}","gists_url":"https://api.github.com/users/DFurnes/gists{/gist_id}","starred_url":"https://api.github.com/users/DFurnes/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DFurnes/subscriptions","organizations_url":"https://api.github.com/users/DFurnes/orgs","repos_url":"https://api.github.com/users/DFurnes/repos","events_url":"https://api.github.com/users/DFurnes/events{/privacy}","received_events_url":"https://api.github.com/users/DFurnes/received_events","type":"User","site_admin":false},"body":"### What does this PR do?\r\nThis PR allows editors to place \"action step\" blocks into the affirmation modal. This allows us to push other actions than sharing the campaign, like registering to vote.\r\n\r\n![screen shot 2018-02-20 at 3 39 14 pm](https://user-images.githubusercontent.com/583202/36448036-41dd017c-1654-11e8-8b35-633d469daafd.png)\r\n\r\nAnd here's the same page [on tablet](https://user-images.githubusercontent.com/583202/36450824-36ef18f0-165d-11e8-9d1d-573d914a9ccb.png) & [on mobile](https://user-images.githubusercontent.com/583202/36450795-11a279c0-165d-11e8-8e65-43fbe152aa0c.png)!\r\n\r\n### Any background context you want to provide?\r\nThis involved more refactoring than I originally estimated. In particular:\r\n\r\n🌵 Extract a single generalized `ActionStepBlock` component out of the `ActionStepWrapper` (which is used to render the entire action page). 2172965\r\n\r\n📳 Add `Affirmation` as a possible \"action step\" block, and then use the `ActionStepBlock` in the affirmation modal! This should keep existing behavior for current campaigns, but allows us to start to introduce all the fun new stuff here over time. 3ccc211\r\n\r\n🏭 Pull \"page-specific\" elements (like built-in section headers & column layout wrappers) into the `ActionStepWrapper` component, so `ActionStepBlock`is _just_ the step itself. b76858e\r\n\r\n💱 Creates a `ModalControls` component that overlays the \"close card\" button, so that we don't have to muddy the rest of our components by passing this down through the hierarchy. e7a0390\r\n\r\n🆔 Finally, this makes _all_ steps on the action page linkable! (Not just section headers.) 967bb8e\r\n\r\n### What are the relevant tickets/cards?\r\n[#154732073](https://www.pivotaltracker.com/story/show/154732073)\r\n\r\n### Checklist\r\n- [ ] Documentation added for new features/changed endpoints.\r\n- [ ] Added appropriate feature/unit tests.\r\n- [x] Added screenshot to PR description of related front-end updates on **small** screens.\r\n- [x] Added screenshot to PR description of related front-end updates on **medium** screens.\r\n- [x] Added screenshot to PR description of related front-end updates on **large** screens.","created_at":"2018-02-20T19:13:56Z","updated_at":"2018-02-21T20:33:55Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ae70ee0372fdb08a8e38fd604f2ce66910dab30b","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/693/commits","review_comments_url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/693/comments","review_comment_url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/comments{/number}","comments_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues/693/comments","statuses_url":"https://api.github.com/repos/DoSomething/phoenix-next/statuses/967bb8eb74ec01e820676ca2b03b3a02d7bc1388","head":{"label":"DoSomething:voter-reg-modal","ref":"voter-reg-modal","sha":"967bb8eb74ec01e820676ca2b03b3a02d7bc1388","user":{"login":"DoSomething","id":731685,"avatar_url":"https://avatars2.githubusercontent.com/u/731685?v=4","gravatar_id":"","url":"https://api.github.com/users/DoSomething","html_url":"https://github.com/DoSomething","followers_url":"https://api.github.com/users/DoSomething/followers","following_url":"https://api.github.com/users/DoSomething/following{/other_user}","gists_url":"https://api.github.com/users/DoSomething/gists{/gist_id}","starred_url":"https://api.github.com/users/DoSomething/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DoSomething/subscriptions","organizations_url":"https://api.github.com/users/DoSomething/orgs","repos_url":"https://api.github.com/users/DoSomething/repos","events_url":"https://api.github.com/users/DoSomething/events{/privacy}","received_events_url":"https://api.github.com/users/DoSomething/received_events","type":"Organization","site_admin":false},"repo":{"id":75642790,"name":"phoenix-next","full_name":"DoSomething/phoenix-next","owner":{"login":"DoSomething","id":731685,"avatar_url":"https://avatars2.githubusercontent.com/u/731685?v=4","gravatar_id":"","url":"https://api.github.com/users/DoSomething","html_url":"https://github.com/DoSomething","followers_url":"https://api.github.com/users/DoSomething/followers","following_url":"https://api.github.com/users/DoSomething/following{/other_user}","gists_url":"https://api.github.com/users/DoSomething/gists{/gist_id}","starred_url":"https://api.github.com/users/DoSomething/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DoSomething/subscriptions","organizations_url":"https://api.github.com/users/DoSomething/orgs","repos_url":"https://api.github.com/users/DoSomething/repos","events_url":"https://api.github.com/users/DoSomething/events{/privacy}","received_events_url":"https://api.github.com/users/DoSomething/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/DoSomething/phoenix-next","description":"🔥 The new DoSomething.org campaign template.","fork":false,"url":"https://api.github.com/repos/DoSomething/phoenix-next","forks_url":"https://api.github.com/repos/DoSomething/phoenix-next/forks","keys_url":"https://api.github.com/repos/DoSomething/phoenix-next/keys{/key_id}","collaborators_url":"https://api.github.com/repos/DoSomething/phoenix-next/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/DoSomething/phoenix-next/teams","hooks_url":"https://api.github.com/repos/DoSomething/phoenix-next/hooks","issue_events_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues/events{/number}","events_url":"https://api.github.com/repos/DoSomething/phoenix-next/events","assignees_url":"https://api.github.com/repos/DoSomething/phoenix-next/assignees{/user}","branches_url":"https://api.github.com/repos/DoSomething/phoenix-next/branches{/branch}","tags_url":"https://api.github.com/repos/DoSomething/phoenix-next/tags","blobs_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/refs{/sha}","trees_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/trees{/sha}","statuses_url":"https://api.github.com/repos/DoSomething/phoenix-next/statuses/{sha}","languages_url":"https://api.github.com/repos/DoSomething/phoenix-next/languages","stargazers_url":"https://api.github.com/repos/DoSomething/phoenix-next/stargazers","contributors_url":"https://api.github.com/repos/DoSomething/phoenix-next/contributors","subscribers_url":"https://api.github.com/repos/DoSomething/phoenix-next/subscribers","subscription_url":"https://api.github.com/repos/DoSomething/phoenix-next/subscription","commits_url":"https://api.github.com/repos/DoSomething/phoenix-next/commits{/sha}","git_commits_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/commits{/sha}","comments_url":"https://api.github.com/repos/DoSomething/phoenix-next/comments{/number}","issue_comment_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues/comments{/number}","contents_url":"https://api.github.com/repos/DoSomething/phoenix-next/contents/{+path}","compare_url":"https://api.github.com/repos/DoSomething/phoenix-next/compare/{base}...{head}","merges_url":"https://api.github.com/repos/DoSomething/phoenix-next/merges","archive_url":"https://api.github.com/repos/DoSomething/phoenix-next/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/DoSomething/phoenix-next/downloads","issues_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues{/number}","pulls_url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls{/number}","milestones_url":"https://api.github.com/repos/DoSomething/phoenix-next/milestones{/number}","notifications_url":"https://api.github.com/repos/DoSomething/phoenix-next/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/DoSomething/phoenix-next/labels{/name}","releases_url":"https://api.github.com/repos/DoSomething/phoenix-next/releases{/id}","deployments_url":"https://api.github.com/repos/DoSomething/phoenix-next/deployments","created_at":"2016-12-05T16:08:36Z","updated_at":"2018-02-02T21:57:23Z","pushed_at":"2018-02-20T21:05:27Z","git_url":"git://github.com/DoSomething/phoenix-next.git","ssh_url":"git@github.com:DoSomething/phoenix-next.git","clone_url":"https://github.com/DoSomething/phoenix-next.git","svn_url":"https://github.com/DoSomething/phoenix-next","homepage":"https://next.dosomething.org","size":7148,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"archived":false,"open_issues_count":22,"license":null,"forks":7,"open_issues":22,"watchers":0,"default_branch":"master"}},"base":{"label":"DoSomething:master","ref":"master","sha":"60d30e458d9b6f263dc87230ec330f15642a0b23","user":{"login":"DoSomething","id":731685,"avatar_url":"https://avatars2.githubusercontent.com/u/731685?v=4","gravatar_id":"","url":"https://api.github.com/users/DoSomething","html_url":"https://github.com/DoSomething","followers_url":"https://api.github.com/users/DoSomething/followers","following_url":"https://api.github.com/users/DoSomething/following{/other_user}","gists_url":"https://api.github.com/users/DoSomething/gists{/gist_id}","starred_url":"https://api.github.com/users/DoSomething/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DoSomething/subscriptions","organizations_url":"https://api.github.com/users/DoSomething/orgs","repos_url":"https://api.github.com/users/DoSomething/repos","events_url":"https://api.github.com/users/DoSomething/events{/privacy}","received_events_url":"https://api.github.com/users/DoSomething/received_events","type":"Organization","site_admin":false},"repo":{"id":75642790,"name":"phoenix-next","full_name":"DoSomething/phoenix-next","owner":{"login":"DoSomething","id":731685,"avatar_url":"https://avatars2.githubusercontent.com/u/731685?v=4","gravatar_id":"","url":"https://api.github.com/users/DoSomething","html_url":"https://github.com/DoSomething","followers_url":"https://api.github.com/users/DoSomething/followers","following_url":"https://api.github.com/users/DoSomething/following{/other_user}","gists_url":"https://api.github.com/users/DoSomething/gists{/gist_id}","starred_url":"https://api.github.com/users/DoSomething/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DoSomething/subscriptions","organizations_url":"https://api.github.com/users/DoSomething/orgs","repos_url":"https://api.github.com/users/DoSomething/repos","events_url":"https://api.github.com/users/DoSomething/events{/privacy}","received_events_url":"https://api.github.com/users/DoSomething/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/DoSomething/phoenix-next","description":"🔥 The new DoSomething.org campaign template.","fork":false,"url":"https://api.github.com/repos/DoSomething/phoenix-next","forks_url":"https://api.github.com/repos/DoSomething/phoenix-next/forks","keys_url":"https://api.github.com/repos/DoSomething/phoenix-next/keys{/key_id}","collaborators_url":"https://api.github.com/repos/DoSomething/phoenix-next/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/DoSomething/phoenix-next/teams","hooks_url":"https://api.github.com/repos/DoSomething/phoenix-next/hooks","issue_events_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues/events{/number}","events_url":"https://api.github.com/repos/DoSomething/phoenix-next/events","assignees_url":"https://api.github.com/repos/DoSomething/phoenix-next/assignees{/user}","branches_url":"https://api.github.com/repos/DoSomething/phoenix-next/branches{/branch}","tags_url":"https://api.github.com/repos/DoSomething/phoenix-next/tags","blobs_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/refs{/sha}","trees_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/trees{/sha}","statuses_url":"https://api.github.com/repos/DoSomething/phoenix-next/statuses/{sha}","languages_url":"https://api.github.com/repos/DoSomething/phoenix-next/languages","stargazers_url":"https://api.github.com/repos/DoSomething/phoenix-next/stargazers","contributors_url":"https://api.github.com/repos/DoSomething/phoenix-next/contributors","subscribers_url":"https://api.github.com/repos/DoSomething/phoenix-next/subscribers","subscription_url":"https://api.github.com/repos/DoSomething/phoenix-next/subscription","commits_url":"https://api.github.com/repos/DoSomething/phoenix-next/commits{/sha}","git_commits_url":"https://api.github.com/repos/DoSomething/phoenix-next/git/commits{/sha}","comments_url":"https://api.github.com/repos/DoSomething/phoenix-next/comments{/number}","issue_comment_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues/comments{/number}","contents_url":"https://api.github.com/repos/DoSomething/phoenix-next/contents/{+path}","compare_url":"https://api.github.com/repos/DoSomething/phoenix-next/compare/{base}...{head}","merges_url":"https://api.github.com/repos/DoSomething/phoenix-next/merges","archive_url":"https://api.github.com/repos/DoSomething/phoenix-next/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/DoSomething/phoenix-next/downloads","issues_url":"https://api.github.com/repos/DoSomething/phoenix-next/issues{/number}","pulls_url":"https://api.github.com/repos/DoSomething/phoenix-next/pulls{/number}","milestones_url":"https://api.github.com/repos/DoSomething/phoenix-next/milestones{/number}","notifications_url":"https://api.github.com/repos/DoSomething/phoenix-next/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/DoSomething/phoenix-next/labels{/name}","releases_url":"https://api.github.com/repos/DoSomething/phoenix-next/releases{/id}","deployments_url":"https://api.github.com/repos/DoSomething/phoenix-next/deployments","created_at":"2016-12-05T16:08:36Z","updated_at":"2018-02-02T21:57:23Z","pushed_at":"2018-02-20T21:05:27Z","git_url":"git://github.com/DoSomething/phoenix-next.git","ssh_url":"git@github.com:DoSomething/phoenix-next.git","clone_url":"https://github.com/DoSomething/phoenix-next.git","svn_url":"https://github.com/DoSomething/phoenix-next","homepage":"https://next.dosomething.org","size":7148,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"archived":false,"open_issues_count":22,"license":null,"forks":7,"open_issues":22,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/693"},"html":{"href":"https://github.com/DoSomething/phoenix-next/pull/693"},"issue":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/issues/693"},"comments":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/issues/693/comments"},"review_comments":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/693/comments"},"review_comment":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/pulls/693/commits"},"statuses":{"href":"https://api.github.com/repos/DoSomething/phoenix-next/statuses/967bb8eb74ec01e820676ca2b03b3a02d7bc1388"}},"author_association":"OWNER"}}
{"actor":{"display_login":"weerd"}}