{"action":"created","comment":{"url":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls/comments/45405554","id":45405554,"diff_hunk":"@@ -12,121 +12,90 @@ def isRequired(field_name):\n \n class HalfWidthLinkBlob(blocks.StructBlock):\n     heading = blocks.CharBlock(max_length=100, required=True)\n-    content = blocks.RichTextBlock(blank=True)\n-    links = blocks.ListBlock(blocks.StructBlock([\n-        ('text', blocks.CharBlock(required=False)),\n-        ('url', blocks.URLBlock(required=False)),\n-    ], icon='user', required=False)\n-    )\n+    body = blocks.RichTextBlock(blank=True)\n+    links = blocks.ListBlock(atoms.Hyperlink(), required=False)\n \n     class Meta:\n         icon = 'link'\n-        template = 'v1/demo/molecules/half_width_link_blob.html'\n+        template = '_includes/molecules/half-width-link-blob.html'\n \n \n class ImageText5050(blocks.StructBlock):\n-    title = blocks.CharBlock(max_length=100, required=True)\n-    description = blocks.RichTextBlock(blank=True)\n-    image = ImageChooserBlock(required=False)\n-    image_path = blocks.CharBlock(required=False)\n-    image_alt = blocks.CharBlock(required=False)\n+    heading = blocks.CharBlock(max_length=100, required=True)\n+    body = blocks.RichTextBlock(blank=True)\n+    image = atoms.ImageBasic()\n     is_widescreen = blocks.BooleanBlock(required=False)\n     is_button = blocks.BooleanBlock(required=False)\n-    link_url = blocks.URLBlock(required=False)\n-    link_text = blocks.CharBlock(max_length=100, required=False)\n-\n-    def clean(self, data):\n-        error_dict = {}\n-        try:\n-            block_data = super(ImageText5050, self).clean(data)\n-        except ValidationError as e:\n-            error_dict.update(e.params)\n-            block_data = data\n-\n-        if not block_data['image'] and not block_data['image_path'] and not block_data['image_alt']:\n-            img_err = ['Please upload or enter an image path']\n-            error_dict.update({'image': img_err, 'image_path': img_err, 'image_alt': isRequired('Image alt')})\n-\n-        if block_data['image'] and block_data['image_path']:\n-            img_err = ['Please select one method of image rendering']\n-            error_dict.update({\n-                'image': img_err,\n-                'image_path': img_err})\n-\n-        if block_data['image_path'] and not block_data['image_alt']:\n-            error_dict.update({'image_alt': isRequired('Image Alt')})\n-\n-        if error_dict:\n-            raise ValidationError(\"ImageText5050 validation errors\", params=error_dict)\n-        else:\n-            return block_data\n+    link = atoms.Hyperlink()\n \n     class Meta:\n         icon = 'image'\n-        template = 'v1/demo/molecules/image_text_5050.html'\n+        template = '_includes/molecules/image-text-50-50.html'\n \n \n class ImageText2575(blocks.StructBlock):\n     heading = blocks.CharBlock(max_length=100, required=True)\n     body = blocks.RichTextBlock(required=True)\n-    image = ImageChooserBlock(required=False)\n-    image_path = blocks.CharBlock(required=False)\n-    image_alt = blocks.CharBlock(required=False)\n-    link_url = blocks.URLBlock(required=False)\n-    link_text = blocks.CharBlock(max_length=100, required=False)\n+    image = atoms.ImageBasic()\n+    link = atoms.Hyperlink()\n     has_rule = blocks.BooleanBlock(required=False)\n \n-    def clean(self, data):\n-        error_dict = {}\n-        try:\n-            block_data = super(ImageText5050, self).clean(data)\n-        except ValidationError as e:\n-            error_dict.update(e.params)\n-            block_data = data\n-\n-        if not block_data['image'] and not block_data['image_path'] and not block_data['image_alt']:\n-            img_err = ['Please upload or enter an image path']\n-            error_dict.update({'image': img_err, 'image_path': img_err, 'image_alt': isRequired('Image alt')})\n-\n-        if block_data['image'] and block_data['image_path']:\n-            img_err = ['Please select one method of image rendering']\n-            error_dict.update({\n-                'image': img_err,\n-                'image_path': img_err})\n-\n-        if block_data['image_path'] and not block_data['image_alt']:\n-            error_dict.update({'image_alt': isRequired('Image Alt')})\n-\n-        if error_dict:\n-            raise ValidationError(\"ImageText2575 validation errors\", params=error_dict)\n-        else:\n-            return block_data\n-\n     class Meta:\n         icon = 'image'\n-        template = 'v1/wagtail/molecules/image_text_2575.html'\n+        template = '_includes/molecules/image-text-25-75.html'\n \n \n class TextIntroduction(blocks.StructBlock):\n     heading = blocks.CharBlock(max_length=100, required=True)\n     intro = blocks.CharBlock(max_length=100, required=True)\n     body = blocks.RichTextBlock(required=False)\n-    link_url = blocks.URLBlock(required=False)\n-    link_text = blocks.CharBlock(max_length=100, required=False)\n+    link = atoms.Hyperlink()\n     has_rule = blocks.BooleanBlock(required=False)\n \n     class Meta:\n         icon = 'title'\n-        template = 'v1/demo/molecules/text_introduction.html'\n+        template = '_includes/molecules/text-introduction.html'\n+\n+\n+class Hero(blocks.StructBlock):\n+    heading = blocks.CharBlock(max_length=100, required=True)\n+    body = blocks.RichTextBlock(required=False)\n+\n+    image = atoms.ImageBasic()\n+\n+    background_color = blocks.CharBlock(max_length=100, required=False)\n+    link = atoms.Hyperlink()\n+    is_button = blocks.BooleanBlock(required=False)\n+\n+    class Meta:\n+        icon = 'image'\n+        template = '_includes/molecules/hero.html'\n+\n+\n+class FormFieldWithButton(blocks.StructBlock):\n+    btn_text = blocks.CharBlock(max_length=100, required=True)\n+\n+    required = blocks.BooleanBlock(required=False)\n+    id = blocks.CharBlock(max_length=100, required=False)\n+    info = blocks.RichTextBlock(required=False)\n+    label = blocks.CharBlock(max_length=100, required=True)\n+    type = blocks.CharBlock(max_length=100, required=True)\n+    name = blocks.CharBlock(max_length=100, required=False)\n+    placeholder = blocks.CharBlock(max_length=100, required=False)\n+    attributes = blocks.CharBlock(max_length=100, required=False)\n+\n+    class Meta:\n+        icon = 'mail'\n+        template = '_includes/molecules/form-field-with-button.html'\n \n \n class CallToAction(blocks.StructBlock):\n+    heading = blocks.CharBlock(max_length=100, required=True)\n     slug = blocks.CharBlock(required=True)\n-    paragraph = blocks.RichTextBlock()","path":"cfgov/v1/models/molecules.py","position":null,"original_position":160,"commit_id":"0421610669bdf6d10d7c1a83713ae92bd97303ed","original_commit_id":"de55a5401d616264a69207649ddcee13ae1d23ab","user":{"login":"kave","id":254877,"avatar_url":"https://avatars.githubusercontent.com/u/254877?v=3","gravatar_id":"","url":"https://api.github.com/users/kave","html_url":"https://github.com/kave","followers_url":"https://api.github.com/users/kave/followers","following_url":"https://api.github.com/users/kave/following{/other_user}","gists_url":"https://api.github.com/users/kave/gists{/gist_id}","starred_url":"https://api.github.com/users/kave/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kave/subscriptions","organizations_url":"https://api.github.com/users/kave/orgs","repos_url":"https://api.github.com/users/kave/repos","events_url":"https://api.github.com/users/kave/events{/privacy}","received_events_url":"https://api.github.com/users/kave/received_events","type":"User","site_admin":false},"body":"these field names will be resolved in a separate PR https://gist.github.com/sebworks/5586cfa6fe01090804df","created_at":"2015-11-19T21:48:28Z","updated_at":"2015-11-19T21:48:28Z","html_url":"https://github.com/cfpb/cfgov-refresh/pull/1154#discussion_r45405554","pull_request_url":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls/1154","_links":{"self":{"href":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls/comments/45405554"},"html":{"href":"https://github.com/cfpb/cfgov-refresh/pull/1154#discussion_r45405554"},"pull_request":{"href":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls/1154"}}},"pull_request":{"url":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls/1154","id":50824591,"html_url":"https://github.com/cfpb/cfgov-refresh/pull/1154","diff_url":"https://github.com/cfpb/cfgov-refresh/pull/1154.diff","patch_url":"https://github.com/cfpb/cfgov-refresh/pull/1154.patch","issue_url":"https://api.github.com/repos/cfpb/cfgov-refresh/issues/1154","number":1154,"state":"open","locked":false,"title":"Landing Page Type","user":{"login":"kave","id":254877,"avatar_url":"https://avatars.githubusercontent.com/u/254877?v=3","gravatar_id":"","url":"https://api.github.com/users/kave","html_url":"https://github.com/kave","followers_url":"https://api.github.com/users/kave/followers","following_url":"https://api.github.com/users/kave/following{/other_user}","gists_url":"https://api.github.com/users/kave/gists{/gist_id}","starred_url":"https://api.github.com/users/kave/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kave/subscriptions","organizations_url":"https://api.github.com/users/kave/orgs","repos_url":"https://api.github.com/users/kave/repos","events_url":"https://api.github.com/users/kave/events{/privacy}","received_events_url":"https://api.github.com/users/kave/received_events","type":"User","site_admin":false},"body":"## Additions\r\n\r\n- New Landing Page type for wagtail\r\n\r\n## Changes\r\n\r\n- Routed landing page type related molecules and organisms to use `jinja2/v1/_includes/` template locations\r\n\r\n## Testing\r\n\r\n- `pip install -r requirements/base.txt`\r\n- Create landing page type and fill out content.\r\n\r\n## Review\r\n\r\n- @kurtw \r\n- @rosskarchner \r\n- @jimmynotjim \r\n- @anselmbradford \r\n- @KimberlyMunoz \r\n- @sebworks \r\n","created_at":"2015-11-16T15:34:36Z","updated_at":"2015-11-19T21:48:28Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6f504e6c99e1cc490bffd74d006b63d55427afd8","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls/1154/commits","review_comments_url":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls/1154/comments","review_comment_url":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls/comments{/number}","comments_url":"https://api.github.com/repos/cfpb/cfgov-refresh/issues/1154/comments","statuses_url":"https://api.github.com/repos/cfpb/cfgov-refresh/statuses/0421610669bdf6d10d7c1a83713ae92bd97303ed","head":{"label":"cfpb:landing","ref":"landing","sha":"0421610669bdf6d10d7c1a83713ae92bd97303ed","user":{"login":"cfpb","id":1071563,"avatar_url":"https://avatars.githubusercontent.com/u/1071563?v=3","gravatar_id":"","url":"https://api.github.com/users/cfpb","html_url":"https://github.com/cfpb","followers_url":"https://api.github.com/users/cfpb/followers","following_url":"https://api.github.com/users/cfpb/following{/other_user}","gists_url":"https://api.github.com/users/cfpb/gists{/gist_id}","starred_url":"https://api.github.com/users/cfpb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cfpb/subscriptions","organizations_url":"https://api.github.com/users/cfpb/orgs","repos_url":"https://api.github.com/users/cfpb/repos","events_url":"https://api.github.com/users/cfpb/events{/privacy}","received_events_url":"https://api.github.com/users/cfpb/received_events","type":"Organization","site_admin":false},"repo":{"id":18852566,"name":"cfgov-refresh","full_name":"cfpb/cfgov-refresh","owner":{"login":"cfpb","id":1071563,"avatar_url":"https://avatars.githubusercontent.com/u/1071563?v=3","gravatar_id":"","url":"https://api.github.com/users/cfpb","html_url":"https://github.com/cfpb","followers_url":"https://api.github.com/users/cfpb/followers","following_url":"https://api.github.com/users/cfpb/following{/other_user}","gists_url":"https://api.github.com/users/cfpb/gists{/gist_id}","starred_url":"https://api.github.com/users/cfpb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cfpb/subscriptions","organizations_url":"https://api.github.com/users/cfpb/orgs","repos_url":"https://api.github.com/users/cfpb/repos","events_url":"https://api.github.com/users/cfpb/events{/privacy}","received_events_url":"https://api.github.com/users/cfpb/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/cfpb/cfgov-refresh","description":"In-progress redesign of the consumerfinance.gov website.","fork":false,"url":"https://api.github.com/repos/cfpb/cfgov-refresh","forks_url":"https://api.github.com/repos/cfpb/cfgov-refresh/forks","keys_url":"https://api.github.com/repos/cfpb/cfgov-refresh/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cfpb/cfgov-refresh/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cfpb/cfgov-refresh/teams","hooks_url":"https://api.github.com/repos/cfpb/cfgov-refresh/hooks","issue_events_url":"https://api.github.com/repos/cfpb/cfgov-refresh/issues/events{/number}","events_url":"https://api.github.com/repos/cfpb/cfgov-refresh/events","assignees_url":"https://api.github.com/repos/cfpb/cfgov-refresh/assignees{/user}","branches_url":"https://api.github.com/repos/cfpb/cfgov-refresh/branches{/branch}","tags_url":"https://api.github.com/repos/cfpb/cfgov-refresh/tags","blobs_url":"https://api.github.com/repos/cfpb/cfgov-refresh/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cfpb/cfgov-refresh/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cfpb/cfgov-refresh/git/refs{/sha}","trees_url":"https://api.github.com/repos/cfpb/cfgov-refresh/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cfpb/cfgov-refresh/statuses/{sha}","languages_url":"https://api.github.com/repos/cfpb/cfgov-refresh/languages","stargazers_url":"https://api.github.com/repos/cfpb/cfgov-refresh/stargazers","contributors_url":"https://api.github.com/repos/cfpb/cfgov-refresh/contributors","subscribers_url":"https://api.github.com/repos/cfpb/cfgov-refresh/subscribers","subscription_url":"https://api.github.com/repos/cfpb/cfgov-refresh/subscription","commits_url":"https://api.github.com/repos/cfpb/cfgov-refresh/commits{/sha}","git_commits_url":"https://api.github.com/repos/cfpb/cfgov-refresh/git/commits{/sha}","comments_url":"https://api.github.com/repos/cfpb/cfgov-refresh/comments{/number}","issue_comment_url":"https://api.github.com/repos/cfpb/cfgov-refresh/issues/comments{/number}","contents_url":"https://api.github.com/repos/cfpb/cfgov-refresh/contents/{+path}","compare_url":"https://api.github.com/repos/cfpb/cfgov-refresh/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cfpb/cfgov-refresh/merges","archive_url":"https://api.github.com/repos/cfpb/cfgov-refresh/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cfpb/cfgov-refresh/downloads","issues_url":"https://api.github.com/repos/cfpb/cfgov-refresh/issues{/number}","pulls_url":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls{/number}","milestones_url":"https://api.github.com/repos/cfpb/cfgov-refresh/milestones{/number}","notifications_url":"https://api.github.com/repos/cfpb/cfgov-refresh/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cfpb/cfgov-refresh/labels{/name}","releases_url":"https://api.github.com/repos/cfpb/cfgov-refresh/releases{/id}","created_at":"2014-04-16T19:22:03Z","updated_at":"2015-11-04T22:29:54Z","pushed_at":"2015-11-19T21:47:20Z","git_url":"git://github.com/cfpb/cfgov-refresh.git","ssh_url":"git@github.com:cfpb/cfgov-refresh.git","clone_url":"https://github.com/cfpb/cfgov-refresh.git","svn_url":"https://github.com/cfpb/cfgov-refresh","homepage":"","size":95202,"stargazers_count":11,"watchers_count":11,"language":"HTML","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":18,"mirror_url":null,"open_issues_count":95,"forks":18,"open_issues":95,"watchers":11,"default_branch":"flapjack"}},"base":{"label":"cfpb:flapjack","ref":"flapjack","sha":"ea4869ba5c9d5e790113aa53aa163cfe1400f0a3","user":{"login":"cfpb","id":1071563,"avatar_url":"https://avatars.githubusercontent.com/u/1071563?v=3","gravatar_id":"","url":"https://api.github.com/users/cfpb","html_url":"https://github.com/cfpb","followers_url":"https://api.github.com/users/cfpb/followers","following_url":"https://api.github.com/users/cfpb/following{/other_user}","gists_url":"https://api.github.com/users/cfpb/gists{/gist_id}","starred_url":"https://api.github.com/users/cfpb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cfpb/subscriptions","organizations_url":"https://api.github.com/users/cfpb/orgs","repos_url":"https://api.github.com/users/cfpb/repos","events_url":"https://api.github.com/users/cfpb/events{/privacy}","received_events_url":"https://api.github.com/users/cfpb/received_events","type":"Organization","site_admin":false},"repo":{"id":18852566,"name":"cfgov-refresh","full_name":"cfpb/cfgov-refresh","owner":{"login":"cfpb","id":1071563,"avatar_url":"https://avatars.githubusercontent.com/u/1071563?v=3","gravatar_id":"","url":"https://api.github.com/users/cfpb","html_url":"https://github.com/cfpb","followers_url":"https://api.github.com/users/cfpb/followers","following_url":"https://api.github.com/users/cfpb/following{/other_user}","gists_url":"https://api.github.com/users/cfpb/gists{/gist_id}","starred_url":"https://api.github.com/users/cfpb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cfpb/subscriptions","organizations_url":"https://api.github.com/users/cfpb/orgs","repos_url":"https://api.github.com/users/cfpb/repos","events_url":"https://api.github.com/users/cfpb/events{/privacy}","received_events_url":"https://api.github.com/users/cfpb/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/cfpb/cfgov-refresh","description":"In-progress redesign of the consumerfinance.gov website.","fork":false,"url":"https://api.github.com/repos/cfpb/cfgov-refresh","forks_url":"https://api.github.com/repos/cfpb/cfgov-refresh/forks","keys_url":"https://api.github.com/repos/cfpb/cfgov-refresh/keys{/key_id}","collaborators_url":"https://api.github.com/repos/cfpb/cfgov-refresh/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/cfpb/cfgov-refresh/teams","hooks_url":"https://api.github.com/repos/cfpb/cfgov-refresh/hooks","issue_events_url":"https://api.github.com/repos/cfpb/cfgov-refresh/issues/events{/number}","events_url":"https://api.github.com/repos/cfpb/cfgov-refresh/events","assignees_url":"https://api.github.com/repos/cfpb/cfgov-refresh/assignees{/user}","branches_url":"https://api.github.com/repos/cfpb/cfgov-refresh/branches{/branch}","tags_url":"https://api.github.com/repos/cfpb/cfgov-refresh/tags","blobs_url":"https://api.github.com/repos/cfpb/cfgov-refresh/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/cfpb/cfgov-refresh/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/cfpb/cfgov-refresh/git/refs{/sha}","trees_url":"https://api.github.com/repos/cfpb/cfgov-refresh/git/trees{/sha}","statuses_url":"https://api.github.com/repos/cfpb/cfgov-refresh/statuses/{sha}","languages_url":"https://api.github.com/repos/cfpb/cfgov-refresh/languages","stargazers_url":"https://api.github.com/repos/cfpb/cfgov-refresh/stargazers","contributors_url":"https://api.github.com/repos/cfpb/cfgov-refresh/contributors","subscribers_url":"https://api.github.com/repos/cfpb/cfgov-refresh/subscribers","subscription_url":"https://api.github.com/repos/cfpb/cfgov-refresh/subscription","commits_url":"https://api.github.com/repos/cfpb/cfgov-refresh/commits{/sha}","git_commits_url":"https://api.github.com/repos/cfpb/cfgov-refresh/git/commits{/sha}","comments_url":"https://api.github.com/repos/cfpb/cfgov-refresh/comments{/number}","issue_comment_url":"https://api.github.com/repos/cfpb/cfgov-refresh/issues/comments{/number}","contents_url":"https://api.github.com/repos/cfpb/cfgov-refresh/contents/{+path}","compare_url":"https://api.github.com/repos/cfpb/cfgov-refresh/compare/{base}...{head}","merges_url":"https://api.github.com/repos/cfpb/cfgov-refresh/merges","archive_url":"https://api.github.com/repos/cfpb/cfgov-refresh/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/cfpb/cfgov-refresh/downloads","issues_url":"https://api.github.com/repos/cfpb/cfgov-refresh/issues{/number}","pulls_url":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls{/number}","milestones_url":"https://api.github.com/repos/cfpb/cfgov-refresh/milestones{/number}","notifications_url":"https://api.github.com/repos/cfpb/cfgov-refresh/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/cfpb/cfgov-refresh/labels{/name}","releases_url":"https://api.github.com/repos/cfpb/cfgov-refresh/releases{/id}","created_at":"2014-04-16T19:22:03Z","updated_at":"2015-11-04T22:29:54Z","pushed_at":"2015-11-19T21:47:20Z","git_url":"git://github.com/cfpb/cfgov-refresh.git","ssh_url":"git@github.com:cfpb/cfgov-refresh.git","clone_url":"https://github.com/cfpb/cfgov-refresh.git","svn_url":"https://github.com/cfpb/cfgov-refresh","homepage":"","size":95202,"stargazers_count":11,"watchers_count":11,"language":"HTML","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":true,"forks_count":18,"mirror_url":null,"open_issues_count":95,"forks":18,"open_issues":95,"watchers":11,"default_branch":"flapjack"}},"_links":{"self":{"href":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls/1154"},"html":{"href":"https://github.com/cfpb/cfgov-refresh/pull/1154"},"issue":{"href":"https://api.github.com/repos/cfpb/cfgov-refresh/issues/1154"},"comments":{"href":"https://api.github.com/repos/cfpb/cfgov-refresh/issues/1154/comments"},"review_comments":{"href":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls/1154/comments"},"review_comment":{"href":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/cfpb/cfgov-refresh/pulls/1154/commits"},"statuses":{"href":"https://api.github.com/repos/cfpb/cfgov-refresh/statuses/0421610669bdf6d10d7c1a83713ae92bd97303ed"}}}}