{"action":"created","comment":{"url":"https://api.github.com/repos/CSSLint/parser-lib/pulls/comments/34681548","id":34681548,"diff_hunk":"@@ -749,6 +755,92 @@ Parser.prototype = function(){\n \n             },\n \n+            _document: function(){\n+                /*\n+                 * document\n+                 *   : DOCUMENT_SYM S*\n+                 *     _document_function [ ',' S* _document_function ]* S*\n+                 *     '{' S* ruleset* '}'\n+                 *   ;\n+                 */\n+\n+                var tokenStream = this._tokenStream,\n+                    token,\n+                    tt,\n+                    functions = [],\n+                    prefix = \"\";\n+\n+                tokenStream.mustMatch(Tokens.DOCUMENT_SYM);\n+                token = tokenStream.token();\n+                if (/^@\\-([^\\-]+)\\-/.test(token.value)) {\n+                    prefix = RegExp.$1;\n+                }\n+\n+                this._readWhitespace();\n+                functions.push(this._document_function());\n+\n+                while(tokenStream.match(Tokens.COMMA)) {\n+                    this._readWhitespace();\n+                    functions.push(this._document_function());\n+                }\n+\n+                tokenStream.mustMatch(Tokens.LBRACE);\n+                this._readWhitespace();\n+\n+                this.fire({\n+                    type:      \"startdocument\",\n+                    functions: functions,\n+                    prefix:    prefix,\n+                    line:      token.startLine,\n+                    col:       token.startCol\n+                });\n+\n+                while(true) {\n+                    if (tokenStream.peek() == Tokens.PAGE_SYM){\n+                        this._page();\n+                    } else if (tokenStream.peek() == Tokens.FONT_FACE_SYM){\n+                        this._font_face();\n+                    } else if (tokenStream.peek() == Tokens.VIEWPORT_SYM){\n+                        this._viewport();\n+                    } else if (tokenStream.peek() == Tokens.MEDIA_SYM){\n+                        this._media();\n+                    } else if (!this._ruleset()){","path":"src/css/Parser.js","position":73,"original_position":73,"commit_id":"12b1af3d77c0a2fb10545321ae54388799b9ff96","original_commit_id":"12b1af3d77c0a2fb10545321ae54388799b9ff96","user":{"login":"jawshooah","id":4551271,"avatar_url":"https://avatars.githubusercontent.com/u/4551271?v=3","gravatar_id":"","url":"https://api.github.com/users/jawshooah","html_url":"https://github.com/jawshooah","followers_url":"https://api.github.com/users/jawshooah/followers","following_url":"https://api.github.com/users/jawshooah/following{/other_user}","gists_url":"https://api.github.com/users/jawshooah/gists{/gist_id}","starred_url":"https://api.github.com/users/jawshooah/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jawshooah/subscriptions","organizations_url":"https://api.github.com/users/jawshooah/orgs","repos_url":"https://api.github.com/users/jawshooah/repos","events_url":"https://api.github.com/users/jawshooah/events{/privacy}","received_events_url":"https://api.github.com/users/jawshooah/received_events","type":"User","site_admin":false},"body":"Go ahead! Thanks for the review :smiley_cat: ","created_at":"2015-07-15T14:09:41Z","updated_at":"2015-07-15T14:09:41Z","html_url":"https://github.com/CSSLint/parser-lib/pull/137#discussion_r34681548","pull_request_url":"https://api.github.com/repos/CSSLint/parser-lib/pulls/137","_links":{"self":{"href":"https://api.github.com/repos/CSSLint/parser-lib/pulls/comments/34681548"},"html":{"href":"https://github.com/CSSLint/parser-lib/pull/137#discussion_r34681548"},"pull_request":{"href":"https://api.github.com/repos/CSSLint/parser-lib/pulls/137"}}},"pull_request":{"url":"https://api.github.com/repos/CSSLint/parser-lib/pulls/137","id":29148237,"html_url":"https://github.com/CSSLint/parser-lib/pull/137","diff_url":"https://github.com/CSSLint/parser-lib/pull/137.diff","patch_url":"https://github.com/CSSLint/parser-lib/pull/137.patch","issue_url":"https://api.github.com/repos/CSSLint/parser-lib/issues/137","number":137,"state":"closed","locked":false,"title":"Add support for @document, @-moz-document","user":{"login":"jawshooah","id":4551271,"avatar_url":"https://avatars.githubusercontent.com/u/4551271?v=3","gravatar_id":"","url":"https://api.github.com/users/jawshooah","html_url":"https://github.com/jawshooah","followers_url":"https://api.github.com/users/jawshooah/followers","following_url":"https://api.github.com/users/jawshooah/following{/other_user}","gists_url":"https://api.github.com/users/jawshooah/gists{/gist_id}","starred_url":"https://api.github.com/users/jawshooah/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jawshooah/subscriptions","organizations_url":"https://api.github.com/users/jawshooah/orgs","repos_url":"https://api.github.com/users/jawshooah/repos","events_url":"https://api.github.com/users/jawshooah/events{/privacy}","received_events_url":"https://api.github.com/users/jawshooah/received_events","type":"User","site_admin":false},"body":"Closes #53.","created_at":"2015-02-12T02:32:00Z","updated_at":"2015-07-15T14:09:41Z","closed_at":"2015-03-02T18:21:04Z","merged_at":"2015-03-02T18:21:04Z","merge_commit_sha":"dfef19c912336a8b8b92be7fc4d985ba6c51fd46","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/CSSLint/parser-lib/pulls/137/commits","review_comments_url":"https://api.github.com/repos/CSSLint/parser-lib/pulls/137/comments","review_comment_url":"https://api.github.com/repos/CSSLint/parser-lib/pulls/comments{/number}","comments_url":"https://api.github.com/repos/CSSLint/parser-lib/issues/137/comments","statuses_url":"https://api.github.com/repos/CSSLint/parser-lib/statuses/12b1af3d77c0a2fb10545321ae54388799b9ff96","head":{"label":"jawshooah:at-document","ref":"at-document","sha":"12b1af3d77c0a2fb10545321ae54388799b9ff96","user":{"login":"jawshooah","id":4551271,"avatar_url":"https://avatars.githubusercontent.com/u/4551271?v=3","gravatar_id":"","url":"https://api.github.com/users/jawshooah","html_url":"https://github.com/jawshooah","followers_url":"https://api.github.com/users/jawshooah/followers","following_url":"https://api.github.com/users/jawshooah/following{/other_user}","gists_url":"https://api.github.com/users/jawshooah/gists{/gist_id}","starred_url":"https://api.github.com/users/jawshooah/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jawshooah/subscriptions","organizations_url":"https://api.github.com/users/jawshooah/orgs","repos_url":"https://api.github.com/users/jawshooah/repos","events_url":"https://api.github.com/users/jawshooah/events{/privacy}","received_events_url":"https://api.github.com/users/jawshooah/received_events","type":"User","site_admin":false},"repo":{"id":30681432,"name":"parser-lib","full_name":"jawshooah/parser-lib","owner":{"login":"jawshooah","id":4551271,"avatar_url":"https://avatars.githubusercontent.com/u/4551271?v=3","gravatar_id":"","url":"https://api.github.com/users/jawshooah","html_url":"https://github.com/jawshooah","followers_url":"https://api.github.com/users/jawshooah/followers","following_url":"https://api.github.com/users/jawshooah/following{/other_user}","gists_url":"https://api.github.com/users/jawshooah/gists{/gist_id}","starred_url":"https://api.github.com/users/jawshooah/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jawshooah/subscriptions","organizations_url":"https://api.github.com/users/jawshooah/orgs","repos_url":"https://api.github.com/users/jawshooah/repos","events_url":"https://api.github.com/users/jawshooah/events{/privacy}","received_events_url":"https://api.github.com/users/jawshooah/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jawshooah/parser-lib","description":"Collection of parsers written in JavaScript","fork":true,"url":"https://api.github.com/repos/jawshooah/parser-lib","forks_url":"https://api.github.com/repos/jawshooah/parser-lib/forks","keys_url":"https://api.github.com/repos/jawshooah/parser-lib/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jawshooah/parser-lib/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jawshooah/parser-lib/teams","hooks_url":"https://api.github.com/repos/jawshooah/parser-lib/hooks","issue_events_url":"https://api.github.com/repos/jawshooah/parser-lib/issues/events{/number}","events_url":"https://api.github.com/repos/jawshooah/parser-lib/events","assignees_url":"https://api.github.com/repos/jawshooah/parser-lib/assignees{/user}","branches_url":"https://api.github.com/repos/jawshooah/parser-lib/branches{/branch}","tags_url":"https://api.github.com/repos/jawshooah/parser-lib/tags","blobs_url":"https://api.github.com/repos/jawshooah/parser-lib/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jawshooah/parser-lib/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jawshooah/parser-lib/git/refs{/sha}","trees_url":"https://api.github.com/repos/jawshooah/parser-lib/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jawshooah/parser-lib/statuses/{sha}","languages_url":"https://api.github.com/repos/jawshooah/parser-lib/languages","stargazers_url":"https://api.github.com/repos/jawshooah/parser-lib/stargazers","contributors_url":"https://api.github.com/repos/jawshooah/parser-lib/contributors","subscribers_url":"https://api.github.com/repos/jawshooah/parser-lib/subscribers","subscription_url":"https://api.github.com/repos/jawshooah/parser-lib/subscription","commits_url":"https://api.github.com/repos/jawshooah/parser-lib/commits{/sha}","git_commits_url":"https://api.github.com/repos/jawshooah/parser-lib/git/commits{/sha}","comments_url":"https://api.github.com/repos/jawshooah/parser-lib/comments{/number}","issue_comment_url":"https://api.github.com/repos/jawshooah/parser-lib/issues/comments{/number}","contents_url":"https://api.github.com/repos/jawshooah/parser-lib/contents/{+path}","compare_url":"https://api.github.com/repos/jawshooah/parser-lib/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jawshooah/parser-lib/merges","archive_url":"https://api.github.com/repos/jawshooah/parser-lib/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jawshooah/parser-lib/downloads","issues_url":"https://api.github.com/repos/jawshooah/parser-lib/issues{/number}","pulls_url":"https://api.github.com/repos/jawshooah/parser-lib/pulls{/number}","milestones_url":"https://api.github.com/repos/jawshooah/parser-lib/milestones{/number}","notifications_url":"https://api.github.com/repos/jawshooah/parser-lib/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jawshooah/parser-lib/labels{/name}","releases_url":"https://api.github.com/repos/jawshooah/parser-lib/releases{/id}","created_at":"2015-02-12T02:31:06Z","updated_at":"2015-02-12T02:31:07Z","pushed_at":"2015-03-02T19:10:12Z","git_url":"git://github.com/jawshooah/parser-lib.git","ssh_url":"git@github.com:jawshooah/parser-lib.git","clone_url":"https://github.com/jawshooah/parser-lib.git","svn_url":"https://github.com/jawshooah/parser-lib","homepage":"http://www.nczonline.net/","size":2616,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"CSSLint:master","ref":"master","sha":"f30a827d1b54bf6be823adb2a341a56ded07ffe1","user":{"login":"CSSLint","id":7219403,"avatar_url":"https://avatars.githubusercontent.com/u/7219403?v=3","gravatar_id":"","url":"https://api.github.com/users/CSSLint","html_url":"https://github.com/CSSLint","followers_url":"https://api.github.com/users/CSSLint/followers","following_url":"https://api.github.com/users/CSSLint/following{/other_user}","gists_url":"https://api.github.com/users/CSSLint/gists{/gist_id}","starred_url":"https://api.github.com/users/CSSLint/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CSSLint/subscriptions","organizations_url":"https://api.github.com/users/CSSLint/orgs","repos_url":"https://api.github.com/users/CSSLint/repos","events_url":"https://api.github.com/users/CSSLint/events{/privacy}","received_events_url":"https://api.github.com/users/CSSLint/received_events","type":"Organization","site_admin":false},"repo":{"id":292509,"name":"parser-lib","full_name":"CSSLint/parser-lib","owner":{"login":"CSSLint","id":7219403,"avatar_url":"https://avatars.githubusercontent.com/u/7219403?v=3","gravatar_id":"","url":"https://api.github.com/users/CSSLint","html_url":"https://github.com/CSSLint","followers_url":"https://api.github.com/users/CSSLint/followers","following_url":"https://api.github.com/users/CSSLint/following{/other_user}","gists_url":"https://api.github.com/users/CSSLint/gists{/gist_id}","starred_url":"https://api.github.com/users/CSSLint/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/CSSLint/subscriptions","organizations_url":"https://api.github.com/users/CSSLint/orgs","repos_url":"https://api.github.com/users/CSSLint/repos","events_url":"https://api.github.com/users/CSSLint/events{/privacy}","received_events_url":"https://api.github.com/users/CSSLint/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/CSSLint/parser-lib","description":"Collection of parsers written in JavaScript","fork":false,"url":"https://api.github.com/repos/CSSLint/parser-lib","forks_url":"https://api.github.com/repos/CSSLint/parser-lib/forks","keys_url":"https://api.github.com/repos/CSSLint/parser-lib/keys{/key_id}","collaborators_url":"https://api.github.com/repos/CSSLint/parser-lib/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/CSSLint/parser-lib/teams","hooks_url":"https://api.github.com/repos/CSSLint/parser-lib/hooks","issue_events_url":"https://api.github.com/repos/CSSLint/parser-lib/issues/events{/number}","events_url":"https://api.github.com/repos/CSSLint/parser-lib/events","assignees_url":"https://api.github.com/repos/CSSLint/parser-lib/assignees{/user}","branches_url":"https://api.github.com/repos/CSSLint/parser-lib/branches{/branch}","tags_url":"https://api.github.com/repos/CSSLint/parser-lib/tags","blobs_url":"https://api.github.com/repos/CSSLint/parser-lib/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/CSSLint/parser-lib/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/CSSLint/parser-lib/git/refs{/sha}","trees_url":"https://api.github.com/repos/CSSLint/parser-lib/git/trees{/sha}","statuses_url":"https://api.github.com/repos/CSSLint/parser-lib/statuses/{sha}","languages_url":"https://api.github.com/repos/CSSLint/parser-lib/languages","stargazers_url":"https://api.github.com/repos/CSSLint/parser-lib/stargazers","contributors_url":"https://api.github.com/repos/CSSLint/parser-lib/contributors","subscribers_url":"https://api.github.com/repos/CSSLint/parser-lib/subscribers","subscription_url":"https://api.github.com/repos/CSSLint/parser-lib/subscription","commits_url":"https://api.github.com/repos/CSSLint/parser-lib/commits{/sha}","git_commits_url":"https://api.github.com/repos/CSSLint/parser-lib/git/commits{/sha}","comments_url":"https://api.github.com/repos/CSSLint/parser-lib/comments{/number}","issue_comment_url":"https://api.github.com/repos/CSSLint/parser-lib/issues/comments{/number}","contents_url":"https://api.github.com/repos/CSSLint/parser-lib/contents/{+path}","compare_url":"https://api.github.com/repos/CSSLint/parser-lib/compare/{base}...{head}","merges_url":"https://api.github.com/repos/CSSLint/parser-lib/merges","archive_url":"https://api.github.com/repos/CSSLint/parser-lib/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/CSSLint/parser-lib/downloads","issues_url":"https://api.github.com/repos/CSSLint/parser-lib/issues{/number}","pulls_url":"https://api.github.com/repos/CSSLint/parser-lib/pulls{/number}","milestones_url":"https://api.github.com/repos/CSSLint/parser-lib/milestones{/number}","notifications_url":"https://api.github.com/repos/CSSLint/parser-lib/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/CSSLint/parser-lib/labels{/name}","releases_url":"https://api.github.com/repos/CSSLint/parser-lib/releases{/id}","created_at":"2009-08-30T16:31:03Z","updated_at":"2015-07-09T13:13:24Z","pushed_at":"2015-05-04T00:16:40Z","git_url":"git://github.com/CSSLint/parser-lib.git","ssh_url":"git@github.com:CSSLint/parser-lib.git","clone_url":"https://github.com/CSSLint/parser-lib.git","svn_url":"https://github.com/CSSLint/parser-lib","homepage":"http://www.nczonline.net/","size":3458,"stargazers_count":233,"watchers_count":233,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":71,"mirror_url":null,"open_issues_count":32,"forks":71,"open_issues":32,"watchers":233,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/CSSLint/parser-lib/pulls/137"},"html":{"href":"https://github.com/CSSLint/parser-lib/pull/137"},"issue":{"href":"https://api.github.com/repos/CSSLint/parser-lib/issues/137"},"comments":{"href":"https://api.github.com/repos/CSSLint/parser-lib/issues/137/comments"},"review_comments":{"href":"https://api.github.com/repos/CSSLint/parser-lib/pulls/137/comments"},"review_comment":{"href":"https://api.github.com/repos/CSSLint/parser-lib/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/CSSLint/parser-lib/pulls/137/commits"},"statuses":{"href":"https://api.github.com/repos/CSSLint/parser-lib/statuses/12b1af3d77c0a2fb10545321ae54388799b9ff96"}}}}