{"action":"created","comment":{"url":"https://api.github.com/repos/jsundt/fenrir_view/pulls/comments/198772746","pull_request_review_id":132760462,"id":198772746,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDE5ODc3Mjc0Ng==","diff_hunk":"@@ -0,0 +1,88 @@\n+# frozen_string_literal: true\n+\n+module FenrirView\n+  class PropertyTypes\n+    def initialize(component_class:, component_properties:, instance_properties:)\n+      @component_class = component_class\n+      @component_properties = component_properties\n+      @instance_properties = instance_properties\n+    end\n+\n+    ALL_TYPES = [:default, :required, :one_of_type, :one_of, :note]\n+    VALIDATION_TYPES = [:required, :one_of_type, :one_of]\n+\n+    def validate_properties\n+      return if @instance_properties == false # Rendering of this instance has been blocked by a guard clause\n+      raise invalid_component_properties unless @instance_properties.is_a?(Hash)\n+      raise unknown_keys if instance_has_unknown_keys?\n+\n+      @instance_properties.each do |property, value|\n+        property_validations = @component_properties[property].except(:default, :note)","path":"lib/fenrir_view/property_types.rb","position":20,"original_position":20,"commit_id":"8857ebca81ef2297b46463971e238b518111de72","original_commit_id":"8857ebca81ef2297b46463971e238b518111de72","user":{"login":"jsundt","id":559801,"node_id":"MDQ6VXNlcjU1OTgwMQ==","avatar_url":"https://avatars0.githubusercontent.com/u/559801?v=4","gravatar_id":"","url":"https://api.github.com/users/jsundt","html_url":"https://github.com/jsundt","followers_url":"https://api.github.com/users/jsundt/followers","following_url":"https://api.github.com/users/jsundt/following{/other_user}","gists_url":"https://api.github.com/users/jsundt/gists{/gist_id}","starred_url":"https://api.github.com/users/jsundt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsundt/subscriptions","organizations_url":"https://api.github.com/users/jsundt/orgs","repos_url":"https://api.github.com/users/jsundt/repos","events_url":"https://api.github.com/users/jsundt/events{/privacy}","received_events_url":"https://api.github.com/users/jsundt/received_events","type":"User","site_admin":false},"body":"Ah yes, forgot to update this will do 👍 ","created_at":"2018-06-28T09:23:35Z","updated_at":"2018-06-28T09:23:35Z","html_url":"https://github.com/jsundt/fenrir_view/pull/4#discussion_r198772746","pull_request_url":"https://api.github.com/repos/jsundt/fenrir_view/pulls/4","author_association":"OWNER","_links":{"self":{"href":"https://api.github.com/repos/jsundt/fenrir_view/pulls/comments/198772746"},"html":{"href":"https://github.com/jsundt/fenrir_view/pull/4#discussion_r198772746"},"pull_request":{"href":"https://api.github.com/repos/jsundt/fenrir_view/pulls/4"}},"in_reply_to_id":198759048},"pull_request":{"url":"https://api.github.com/repos/jsundt/fenrir_view/pulls/4","id":194340213,"node_id":"MDExOlB1bGxSZXF1ZXN0MTk0MzQwMjEz","html_url":"https://github.com/jsundt/fenrir_view/pull/4","diff_url":"https://github.com/jsundt/fenrir_view/pull/4.diff","patch_url":"https://github.com/jsundt/fenrir_view/pull/4.patch","issue_url":"https://api.github.com/repos/jsundt/fenrir_view/issues/4","number":4,"state":"open","locked":false,"title":"Validation of properties for each design system component","user":{"login":"jsundt","id":559801,"node_id":"MDQ6VXNlcjU1OTgwMQ==","avatar_url":"https://avatars0.githubusercontent.com/u/559801?v=4","gravatar_id":"","url":"https://api.github.com/users/jsundt","html_url":"https://github.com/jsundt","followers_url":"https://api.github.com/users/jsundt/followers","following_url":"https://api.github.com/users/jsundt/following{/other_user}","gists_url":"https://api.github.com/users/jsundt/gists{/gist_id}","starred_url":"https://api.github.com/users/jsundt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsundt/subscriptions","organizations_url":"https://api.github.com/users/jsundt/orgs","repos_url":"https://api.github.com/users/jsundt/repos","events_url":"https://api.github.com/users/jsundt/events{/privacy}","received_events_url":"https://api.github.com/users/jsundt/received_events","type":"User","site_admin":false},"body":"This enables validation of all design system properties in development and test environments.\r\n\r\n- [x] Initial implementation of property validation\r\n- [x] Update generator templates\r\n- [x] Show validation rules in styleguide\r\n- [ ] Version bump","created_at":"2018-06-12T16:35:10Z","updated_at":"2018-06-28T09:23:35Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1ce3b7c5e143937f5e5a56faf6d5272cdb8e2256","assignee":{"login":"jsundt","id":559801,"node_id":"MDQ6VXNlcjU1OTgwMQ==","avatar_url":"https://avatars0.githubusercontent.com/u/559801?v=4","gravatar_id":"","url":"https://api.github.com/users/jsundt","html_url":"https://github.com/jsundt","followers_url":"https://api.github.com/users/jsundt/followers","following_url":"https://api.github.com/users/jsundt/following{/other_user}","gists_url":"https://api.github.com/users/jsundt/gists{/gist_id}","starred_url":"https://api.github.com/users/jsundt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsundt/subscriptions","organizations_url":"https://api.github.com/users/jsundt/orgs","repos_url":"https://api.github.com/users/jsundt/repos","events_url":"https://api.github.com/users/jsundt/events{/privacy}","received_events_url":"https://api.github.com/users/jsundt/received_events","type":"User","site_admin":false},"assignees":[{"login":"jsundt","id":559801,"node_id":"MDQ6VXNlcjU1OTgwMQ==","avatar_url":"https://avatars0.githubusercontent.com/u/559801?v=4","gravatar_id":"","url":"https://api.github.com/users/jsundt","html_url":"https://github.com/jsundt","followers_url":"https://api.github.com/users/jsundt/followers","following_url":"https://api.github.com/users/jsundt/following{/other_user}","gists_url":"https://api.github.com/users/jsundt/gists{/gist_id}","starred_url":"https://api.github.com/users/jsundt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsundt/subscriptions","organizations_url":"https://api.github.com/users/jsundt/orgs","repos_url":"https://api.github.com/users/jsundt/repos","events_url":"https://api.github.com/users/jsundt/events{/privacy}","received_events_url":"https://api.github.com/users/jsundt/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/jsundt/fenrir_view/pulls/4/commits","review_comments_url":"https://api.github.com/repos/jsundt/fenrir_view/pulls/4/comments","review_comment_url":"https://api.github.com/repos/jsundt/fenrir_view/pulls/comments{/number}","comments_url":"https://api.github.com/repos/jsundt/fenrir_view/issues/4/comments","statuses_url":"https://api.github.com/repos/jsundt/fenrir_view/statuses/8857ebca81ef2297b46463971e238b518111de72","head":{"label":"jsundt:prop-type-validation","ref":"prop-type-validation","sha":"8857ebca81ef2297b46463971e238b518111de72","user":{"login":"jsundt","id":559801,"node_id":"MDQ6VXNlcjU1OTgwMQ==","avatar_url":"https://avatars0.githubusercontent.com/u/559801?v=4","gravatar_id":"","url":"https://api.github.com/users/jsundt","html_url":"https://github.com/jsundt","followers_url":"https://api.github.com/users/jsundt/followers","following_url":"https://api.github.com/users/jsundt/following{/other_user}","gists_url":"https://api.github.com/users/jsundt/gists{/gist_id}","starred_url":"https://api.github.com/users/jsundt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsundt/subscriptions","organizations_url":"https://api.github.com/users/jsundt/orgs","repos_url":"https://api.github.com/users/jsundt/repos","events_url":"https://api.github.com/users/jsundt/events{/privacy}","received_events_url":"https://api.github.com/users/jsundt/received_events","type":"User","site_admin":false},"repo":{"id":90684996,"node_id":"MDEwOlJlcG9zaXRvcnk5MDY4NDk5Ng==","name":"fenrir_view","full_name":"jsundt/fenrir_view","owner":{"login":"jsundt","id":559801,"node_id":"MDQ6VXNlcjU1OTgwMQ==","avatar_url":"https://avatars0.githubusercontent.com/u/559801?v=4","gravatar_id":"","url":"https://api.github.com/users/jsundt","html_url":"https://github.com/jsundt","followers_url":"https://api.github.com/users/jsundt/followers","following_url":"https://api.github.com/users/jsundt/following{/other_user}","gists_url":"https://api.github.com/users/jsundt/gists{/gist_id}","starred_url":"https://api.github.com/users/jsundt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsundt/subscriptions","organizations_url":"https://api.github.com/users/jsundt/orgs","repos_url":"https://api.github.com/users/jsundt/repos","events_url":"https://api.github.com/users/jsundt/events{/privacy}","received_events_url":"https://api.github.com/users/jsundt/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jsundt/fenrir_view","description":null,"fork":false,"url":"https://api.github.com/repos/jsundt/fenrir_view","forks_url":"https://api.github.com/repos/jsundt/fenrir_view/forks","keys_url":"https://api.github.com/repos/jsundt/fenrir_view/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jsundt/fenrir_view/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jsundt/fenrir_view/teams","hooks_url":"https://api.github.com/repos/jsundt/fenrir_view/hooks","issue_events_url":"https://api.github.com/repos/jsundt/fenrir_view/issues/events{/number}","events_url":"https://api.github.com/repos/jsundt/fenrir_view/events","assignees_url":"https://api.github.com/repos/jsundt/fenrir_view/assignees{/user}","branches_url":"https://api.github.com/repos/jsundt/fenrir_view/branches{/branch}","tags_url":"https://api.github.com/repos/jsundt/fenrir_view/tags","blobs_url":"https://api.github.com/repos/jsundt/fenrir_view/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jsundt/fenrir_view/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jsundt/fenrir_view/git/refs{/sha}","trees_url":"https://api.github.com/repos/jsundt/fenrir_view/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jsundt/fenrir_view/statuses/{sha}","languages_url":"https://api.github.com/repos/jsundt/fenrir_view/languages","stargazers_url":"https://api.github.com/repos/jsundt/fenrir_view/stargazers","contributors_url":"https://api.github.com/repos/jsundt/fenrir_view/contributors","subscribers_url":"https://api.github.com/repos/jsundt/fenrir_view/subscribers","subscription_url":"https://api.github.com/repos/jsundt/fenrir_view/subscription","commits_url":"https://api.github.com/repos/jsundt/fenrir_view/commits{/sha}","git_commits_url":"https://api.github.com/repos/jsundt/fenrir_view/git/commits{/sha}","comments_url":"https://api.github.com/repos/jsundt/fenrir_view/comments{/number}","issue_comment_url":"https://api.github.com/repos/jsundt/fenrir_view/issues/comments{/number}","contents_url":"https://api.github.com/repos/jsundt/fenrir_view/contents/{+path}","compare_url":"https://api.github.com/repos/jsundt/fenrir_view/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jsundt/fenrir_view/merges","archive_url":"https://api.github.com/repos/jsundt/fenrir_view/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jsundt/fenrir_view/downloads","issues_url":"https://api.github.com/repos/jsundt/fenrir_view/issues{/number}","pulls_url":"https://api.github.com/repos/jsundt/fenrir_view/pulls{/number}","milestones_url":"https://api.github.com/repos/jsundt/fenrir_view/milestones{/number}","notifications_url":"https://api.github.com/repos/jsundt/fenrir_view/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jsundt/fenrir_view/labels{/name}","releases_url":"https://api.github.com/repos/jsundt/fenrir_view/releases{/id}","deployments_url":"https://api.github.com/repos/jsundt/fenrir_view/deployments","created_at":"2017-05-09T00:34:33Z","updated_at":"2018-06-12T17:00:48Z","pushed_at":"2018-06-27T17:18:06Z","git_url":"git://github.com/jsundt/fenrir_view.git","ssh_url":"git@github.com:jsundt/fenrir_view.git","clone_url":"https://github.com/jsundt/fenrir_view.git","svn_url":"https://github.com/jsundt/fenrir_view","homepage":null,"size":121,"stargazers_count":2,"watchers_count":2,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":0,"open_issues":1,"watchers":2,"default_branch":"master"}},"base":{"label":"jsundt:master","ref":"master","sha":"9565d715579bc809cf93964d9b9c492c130f9b57","user":{"login":"jsundt","id":559801,"node_id":"MDQ6VXNlcjU1OTgwMQ==","avatar_url":"https://avatars0.githubusercontent.com/u/559801?v=4","gravatar_id":"","url":"https://api.github.com/users/jsundt","html_url":"https://github.com/jsundt","followers_url":"https://api.github.com/users/jsundt/followers","following_url":"https://api.github.com/users/jsundt/following{/other_user}","gists_url":"https://api.github.com/users/jsundt/gists{/gist_id}","starred_url":"https://api.github.com/users/jsundt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsundt/subscriptions","organizations_url":"https://api.github.com/users/jsundt/orgs","repos_url":"https://api.github.com/users/jsundt/repos","events_url":"https://api.github.com/users/jsundt/events{/privacy}","received_events_url":"https://api.github.com/users/jsundt/received_events","type":"User","site_admin":false},"repo":{"id":90684996,"node_id":"MDEwOlJlcG9zaXRvcnk5MDY4NDk5Ng==","name":"fenrir_view","full_name":"jsundt/fenrir_view","owner":{"login":"jsundt","id":559801,"node_id":"MDQ6VXNlcjU1OTgwMQ==","avatar_url":"https://avatars0.githubusercontent.com/u/559801?v=4","gravatar_id":"","url":"https://api.github.com/users/jsundt","html_url":"https://github.com/jsundt","followers_url":"https://api.github.com/users/jsundt/followers","following_url":"https://api.github.com/users/jsundt/following{/other_user}","gists_url":"https://api.github.com/users/jsundt/gists{/gist_id}","starred_url":"https://api.github.com/users/jsundt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jsundt/subscriptions","organizations_url":"https://api.github.com/users/jsundt/orgs","repos_url":"https://api.github.com/users/jsundt/repos","events_url":"https://api.github.com/users/jsundt/events{/privacy}","received_events_url":"https://api.github.com/users/jsundt/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jsundt/fenrir_view","description":null,"fork":false,"url":"https://api.github.com/repos/jsundt/fenrir_view","forks_url":"https://api.github.com/repos/jsundt/fenrir_view/forks","keys_url":"https://api.github.com/repos/jsundt/fenrir_view/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jsundt/fenrir_view/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jsundt/fenrir_view/teams","hooks_url":"https://api.github.com/repos/jsundt/fenrir_view/hooks","issue_events_url":"https://api.github.com/repos/jsundt/fenrir_view/issues/events{/number}","events_url":"https://api.github.com/repos/jsundt/fenrir_view/events","assignees_url":"https://api.github.com/repos/jsundt/fenrir_view/assignees{/user}","branches_url":"https://api.github.com/repos/jsundt/fenrir_view/branches{/branch}","tags_url":"https://api.github.com/repos/jsundt/fenrir_view/tags","blobs_url":"https://api.github.com/repos/jsundt/fenrir_view/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jsundt/fenrir_view/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jsundt/fenrir_view/git/refs{/sha}","trees_url":"https://api.github.com/repos/jsundt/fenrir_view/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jsundt/fenrir_view/statuses/{sha}","languages_url":"https://api.github.com/repos/jsundt/fenrir_view/languages","stargazers_url":"https://api.github.com/repos/jsundt/fenrir_view/stargazers","contributors_url":"https://api.github.com/repos/jsundt/fenrir_view/contributors","subscribers_url":"https://api.github.com/repos/jsundt/fenrir_view/subscribers","subscription_url":"https://api.github.com/repos/jsundt/fenrir_view/subscription","commits_url":"https://api.github.com/repos/jsundt/fenrir_view/commits{/sha}","git_commits_url":"https://api.github.com/repos/jsundt/fenrir_view/git/commits{/sha}","comments_url":"https://api.github.com/repos/jsundt/fenrir_view/comments{/number}","issue_comment_url":"https://api.github.com/repos/jsundt/fenrir_view/issues/comments{/number}","contents_url":"https://api.github.com/repos/jsundt/fenrir_view/contents/{+path}","compare_url":"https://api.github.com/repos/jsundt/fenrir_view/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jsundt/fenrir_view/merges","archive_url":"https://api.github.com/repos/jsundt/fenrir_view/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jsundt/fenrir_view/downloads","issues_url":"https://api.github.com/repos/jsundt/fenrir_view/issues{/number}","pulls_url":"https://api.github.com/repos/jsundt/fenrir_view/pulls{/number}","milestones_url":"https://api.github.com/repos/jsundt/fenrir_view/milestones{/number}","notifications_url":"https://api.github.com/repos/jsundt/fenrir_view/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jsundt/fenrir_view/labels{/name}","releases_url":"https://api.github.com/repos/jsundt/fenrir_view/releases{/id}","deployments_url":"https://api.github.com/repos/jsundt/fenrir_view/deployments","created_at":"2017-05-09T00:34:33Z","updated_at":"2018-06-12T17:00:48Z","pushed_at":"2018-06-27T17:18:06Z","git_url":"git://github.com/jsundt/fenrir_view.git","ssh_url":"git@github.com:jsundt/fenrir_view.git","clone_url":"https://github.com/jsundt/fenrir_view.git","svn_url":"https://github.com/jsundt/fenrir_view","homepage":null,"size":121,"stargazers_count":2,"watchers_count":2,"language":"Ruby","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":1,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":0,"open_issues":1,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/jsundt/fenrir_view/pulls/4"},"html":{"href":"https://github.com/jsundt/fenrir_view/pull/4"},"issue":{"href":"https://api.github.com/repos/jsundt/fenrir_view/issues/4"},"comments":{"href":"https://api.github.com/repos/jsundt/fenrir_view/issues/4/comments"},"review_comments":{"href":"https://api.github.com/repos/jsundt/fenrir_view/pulls/4/comments"},"review_comment":{"href":"https://api.github.com/repos/jsundt/fenrir_view/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/jsundt/fenrir_view/pulls/4/commits"},"statuses":{"href":"https://api.github.com/repos/jsundt/fenrir_view/statuses/8857ebca81ef2297b46463971e238b518111de72"}},"author_association":"OWNER"}}
{"actor":{"display_login":"jsundt"}}