{"action":"created","comment":{"url":"https://api.github.com/repos/zanata/zanata-server/pulls/comments/42083528","id":42083528,"diff_hunk":"@@ -0,0 +1,485 @@\n+import React, {PureRenderMixin} from 'react/addons';\n+import Actions from '../../actions/GlossaryActions';\n+import {Table, Column} from 'fixed-data-table';\n+import StringUtils from '../../utils/StringUtils'\n+import InputCell from './InputCell';\n+import LoadingCell from './LoadingCell'\n+import ActionCell from './ActionCell'\n+import SourceActionCell from './SourceActionCell'\n+import ColumnHeader from './ColumnHeader'\n+import _ from 'lodash';\n+\n+var DataTable = React.createClass({\n+  TIMEOUT: 400,\n+\n+  NO_ROW: -1,\n+\n+  resIdIndex: 0,\n+\n+  ENTRY: {\n+    SRC: {\n+      col: 1,\n+      field: 'srcTerm.content',\n+      sort_field: 'src_content'\n+    },\n+    TRANS: {\n+      col: 2,\n+      field: 'transTerm.content',\n+      sort_field: 'trans_content'\n+    },\n+    POS: {\n+      col: 3,\n+      field: 'pos',\n+      sort_field: 'part_of_speech'\n+    },\n+    DESC: {\n+      col: 4,\n+      field: 'description',\n+      sort_field: 'desc'\n+    },\n+    TRANS_COUNT: {\n+      col: 5,\n+      field: 'termsCount',\n+      sort_field: 'trans_count'\n+    }\n+  },\n+  CELL_HEIGHT: 48,\n+\n+  propTypes: {\n+    glossaryData: React.PropTypes.object.isRequired,\n+    glossaryResId: React.PropTypes.arrayOf(\n+      React.PropTypes.arrayOf(React.PropTypes.string)\n+    ),\n+    canAddNewEntry: React.PropTypes.bool.isRequired,\n+    canUpdateEntry: React.PropTypes.bool.isRequired,\n+    user: React.PropTypes.shape({\n+      username: React.PropTypes.string,\n+      email: React.PropTypes.string,\n+      name: React.PropTypes.string,\n+      imageUrl: React.PropTypes.string,\n+      languageTeams: React.PropTypes.string\n+    }),\n+    srcLocale: React.PropTypes.shape({\n+      locale: React.PropTypes.shape({\n+        localeId: React.PropTypes.string.isRequired,\n+        displayName: React.PropTypes.string.isRequired,\n+        alias: React.PropTypes.string.isRequired\n+      }).isRequired,\n+      numberOfTerms: React.PropTypes.number.isRequired\n+    }),\n+    selectedTransLocale: React.PropTypes.string,\n+    totalCount: React.PropTypes.number.isRequired,\n+    focusedRow: React.PropTypes.shape({\n+      resId: React.PropTypes.string,\n+      rowIndex: React.PropTypes.number\n+    })\n+  },\n+\n+  getInitialState: function () {\n+    var top = 246; //top height for banner if can't get height from dom\n+    return {\n+      tbl_width: this._getWidth(),\n+      tbl_height: this._getHeight(top),\n+      row_height: this.CELL_HEIGHT,\n+      header_height: this.CELL_HEIGHT,\n+      hoveredRow: -1\n+    }\n+  },\n+\n+  /**\n+   *\n+   * @param fixedTop - top height for banner if can't get height from dom","path":"frontend/src/main/web/lib/components/glossary/DataTable.jsx","position":91,"original_position":91,"commit_id":"31375a05216e023fe19425048a0e2a4e0c14d2fb","original_commit_id":"31375a05216e023fe19425048a0e2a4e0c14d2fb","user":{"login":"davidmason","id":482026,"avatar_url":"https://avatars.githubusercontent.com/u/482026?v=3","gravatar_id":"","url":"https://api.github.com/users/davidmason","html_url":"https://github.com/davidmason","followers_url":"https://api.github.com/users/davidmason/followers","following_url":"https://api.github.com/users/davidmason/following{/other_user}","gists_url":"https://api.github.com/users/davidmason/gists{/gist_id}","starred_url":"https://api.github.com/users/davidmason/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidmason/subscriptions","organizations_url":"https://api.github.com/users/davidmason/orgs","repos_url":"https://api.github.com/users/davidmason/repos","events_url":"https://api.github.com/users/davidmason/events{/privacy}","received_events_url":"https://api.github.com/users/davidmason/received_events","type":"User","site_admin":false},"body":"The code does the opposite of what this says - gets the height from the DOM if this is not specified. Better change the code or the comment (depending which it is supposed to be).\r\n\r\nIs fixedTop supposed to be a `number` or a `string` with units (like % or px)?","created_at":"2015-10-15T04:55:30Z","updated_at":"2015-10-15T04:55:30Z","html_url":"https://github.com/zanata/zanata-server/pull/986#discussion_r42083528","pull_request_url":"https://api.github.com/repos/zanata/zanata-server/pulls/986","_links":{"self":{"href":"https://api.github.com/repos/zanata/zanata-server/pulls/comments/42083528"},"html":{"href":"https://github.com/zanata/zanata-server/pull/986#discussion_r42083528"},"pull_request":{"href":"https://api.github.com/repos/zanata/zanata-server/pulls/986"}}},"pull_request":{"url":"https://api.github.com/repos/zanata/zanata-server/pulls/986","id":46124113,"html_url":"https://github.com/zanata/zanata-server/pull/986","diff_url":"https://github.com/zanata/zanata-server/pull/986.diff","patch_url":"https://github.com/zanata/zanata-server/pull/986.patch","issue_url":"https://api.github.com/repos/zanata/zanata-server/issues/986","number":986,"state":"open","locked":false,"title":"Rhbz1245433 glossary","user":{"login":"aeng","id":766762,"avatar_url":"https://avatars.githubusercontent.com/u/766762?v=3","gravatar_id":"","url":"https://api.github.com/users/aeng","html_url":"https://github.com/aeng","followers_url":"https://api.github.com/users/aeng/followers","following_url":"https://api.github.com/users/aeng/following{/other_user}","gists_url":"https://api.github.com/users/aeng/gists{/gist_id}","starred_url":"https://api.github.com/users/aeng/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aeng/subscriptions","organizations_url":"https://api.github.com/users/aeng/orgs","repos_url":"https://api.github.com/users/aeng/repos","events_url":"https://api.github.com/users/aeng/events{/privacy}","received_events_url":"https://api.github.com/users/aeng/received_events","type":"User","site_admin":false},"body":"https://zanata.atlassian.net/browse/ZNTA-108","created_at":"2015-09-28T06:36:34Z","updated_at":"2015-10-15T04:55:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4e4ff36c0c934c7cd88930403a9183d6208ca0d4","assignee":{"login":"huangp","id":1005842,"avatar_url":"https://avatars.githubusercontent.com/u/1005842?v=3","gravatar_id":"","url":"https://api.github.com/users/huangp","html_url":"https://github.com/huangp","followers_url":"https://api.github.com/users/huangp/followers","following_url":"https://api.github.com/users/huangp/following{/other_user}","gists_url":"https://api.github.com/users/huangp/gists{/gist_id}","starred_url":"https://api.github.com/users/huangp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/huangp/subscriptions","organizations_url":"https://api.github.com/users/huangp/orgs","repos_url":"https://api.github.com/users/huangp/repos","events_url":"https://api.github.com/users/huangp/events{/privacy}","received_events_url":"https://api.github.com/users/huangp/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/zanata/zanata-server/pulls/986/commits","review_comments_url":"https://api.github.com/repos/zanata/zanata-server/pulls/986/comments","review_comment_url":"https://api.github.com/repos/zanata/zanata-server/pulls/comments{/number}","comments_url":"https://api.github.com/repos/zanata/zanata-server/issues/986/comments","statuses_url":"https://api.github.com/repos/zanata/zanata-server/statuses/31375a05216e023fe19425048a0e2a4e0c14d2fb","head":{"label":"zanata:rhbz1245433-glossary","ref":"rhbz1245433-glossary","sha":"31375a05216e023fe19425048a0e2a4e0c14d2fb","user":{"login":"zanata","id":637455,"avatar_url":"https://avatars.githubusercontent.com/u/637455?v=3","gravatar_id":"","url":"https://api.github.com/users/zanata","html_url":"https://github.com/zanata","followers_url":"https://api.github.com/users/zanata/followers","following_url":"https://api.github.com/users/zanata/following{/other_user}","gists_url":"https://api.github.com/users/zanata/gists{/gist_id}","starred_url":"https://api.github.com/users/zanata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zanata/subscriptions","organizations_url":"https://api.github.com/users/zanata/orgs","repos_url":"https://api.github.com/users/zanata/repos","events_url":"https://api.github.com/users/zanata/events{/privacy}","received_events_url":"https://api.github.com/users/zanata/received_events","type":"Organization","site_admin":false},"repo":{"id":1461609,"name":"zanata-server","full_name":"zanata/zanata-server","owner":{"login":"zanata","id":637455,"avatar_url":"https://avatars.githubusercontent.com/u/637455?v=3","gravatar_id":"","url":"https://api.github.com/users/zanata","html_url":"https://github.com/zanata","followers_url":"https://api.github.com/users/zanata/followers","following_url":"https://api.github.com/users/zanata/following{/other_user}","gists_url":"https://api.github.com/users/zanata/gists{/gist_id}","starred_url":"https://api.github.com/users/zanata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zanata/subscriptions","organizations_url":"https://api.github.com/users/zanata/orgs","repos_url":"https://api.github.com/users/zanata/repos","events_url":"https://api.github.com/users/zanata/events{/privacy}","received_events_url":"https://api.github.com/users/zanata/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/zanata/zanata-server","description":"Zanata is a web-based system for translators to translate documentation and software online using a web browser.","fork":false,"url":"https://api.github.com/repos/zanata/zanata-server","forks_url":"https://api.github.com/repos/zanata/zanata-server/forks","keys_url":"https://api.github.com/repos/zanata/zanata-server/keys{/key_id}","collaborators_url":"https://api.github.com/repos/zanata/zanata-server/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/zanata/zanata-server/teams","hooks_url":"https://api.github.com/repos/zanata/zanata-server/hooks","issue_events_url":"https://api.github.com/repos/zanata/zanata-server/issues/events{/number}","events_url":"https://api.github.com/repos/zanata/zanata-server/events","assignees_url":"https://api.github.com/repos/zanata/zanata-server/assignees{/user}","branches_url":"https://api.github.com/repos/zanata/zanata-server/branches{/branch}","tags_url":"https://api.github.com/repos/zanata/zanata-server/tags","blobs_url":"https://api.github.com/repos/zanata/zanata-server/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/zanata/zanata-server/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/zanata/zanata-server/git/refs{/sha}","trees_url":"https://api.github.com/repos/zanata/zanata-server/git/trees{/sha}","statuses_url":"https://api.github.com/repos/zanata/zanata-server/statuses/{sha}","languages_url":"https://api.github.com/repos/zanata/zanata-server/languages","stargazers_url":"https://api.github.com/repos/zanata/zanata-server/stargazers","contributors_url":"https://api.github.com/repos/zanata/zanata-server/contributors","subscribers_url":"https://api.github.com/repos/zanata/zanata-server/subscribers","subscription_url":"https://api.github.com/repos/zanata/zanata-server/subscription","commits_url":"https://api.github.com/repos/zanata/zanata-server/commits{/sha}","git_commits_url":"https://api.github.com/repos/zanata/zanata-server/git/commits{/sha}","comments_url":"https://api.github.com/repos/zanata/zanata-server/comments{/number}","issue_comment_url":"https://api.github.com/repos/zanata/zanata-server/issues/comments{/number}","contents_url":"https://api.github.com/repos/zanata/zanata-server/contents/{+path}","compare_url":"https://api.github.com/repos/zanata/zanata-server/compare/{base}...{head}","merges_url":"https://api.github.com/repos/zanata/zanata-server/merges","archive_url":"https://api.github.com/repos/zanata/zanata-server/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/zanata/zanata-server/downloads","issues_url":"https://api.github.com/repos/zanata/zanata-server/issues{/number}","pulls_url":"https://api.github.com/repos/zanata/zanata-server/pulls{/number}","milestones_url":"https://api.github.com/repos/zanata/zanata-server/milestones{/number}","notifications_url":"https://api.github.com/repos/zanata/zanata-server/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/zanata/zanata-server/labels{/name}","releases_url":"https://api.github.com/repos/zanata/zanata-server/releases{/id}","created_at":"2011-03-10T00:24:47Z","updated_at":"2015-10-15T03:10:30Z","pushed_at":"2015-10-15T04:28:52Z","git_url":"git://github.com/zanata/zanata-server.git","ssh_url":"git@github.com:zanata/zanata-server.git","clone_url":"https://github.com/zanata/zanata-server.git","svn_url":"https://github.com/zanata/zanata-server","homepage":"http://zanata.org","size":244877,"stargazers_count":124,"watchers_count":124,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":35,"mirror_url":null,"open_issues_count":31,"forks":35,"open_issues":31,"watchers":124,"default_branch":"master"}},"base":{"label":"zanata:integration/master","ref":"integration/master","sha":"b6819e775ff18c7deba08acdf8725f01bff7df18","user":{"login":"zanata","id":637455,"avatar_url":"https://avatars.githubusercontent.com/u/637455?v=3","gravatar_id":"","url":"https://api.github.com/users/zanata","html_url":"https://github.com/zanata","followers_url":"https://api.github.com/users/zanata/followers","following_url":"https://api.github.com/users/zanata/following{/other_user}","gists_url":"https://api.github.com/users/zanata/gists{/gist_id}","starred_url":"https://api.github.com/users/zanata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zanata/subscriptions","organizations_url":"https://api.github.com/users/zanata/orgs","repos_url":"https://api.github.com/users/zanata/repos","events_url":"https://api.github.com/users/zanata/events{/privacy}","received_events_url":"https://api.github.com/users/zanata/received_events","type":"Organization","site_admin":false},"repo":{"id":1461609,"name":"zanata-server","full_name":"zanata/zanata-server","owner":{"login":"zanata","id":637455,"avatar_url":"https://avatars.githubusercontent.com/u/637455?v=3","gravatar_id":"","url":"https://api.github.com/users/zanata","html_url":"https://github.com/zanata","followers_url":"https://api.github.com/users/zanata/followers","following_url":"https://api.github.com/users/zanata/following{/other_user}","gists_url":"https://api.github.com/users/zanata/gists{/gist_id}","starred_url":"https://api.github.com/users/zanata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zanata/subscriptions","organizations_url":"https://api.github.com/users/zanata/orgs","repos_url":"https://api.github.com/users/zanata/repos","events_url":"https://api.github.com/users/zanata/events{/privacy}","received_events_url":"https://api.github.com/users/zanata/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/zanata/zanata-server","description":"Zanata is a web-based system for translators to translate documentation and software online using a web browser.","fork":false,"url":"https://api.github.com/repos/zanata/zanata-server","forks_url":"https://api.github.com/repos/zanata/zanata-server/forks","keys_url":"https://api.github.com/repos/zanata/zanata-server/keys{/key_id}","collaborators_url":"https://api.github.com/repos/zanata/zanata-server/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/zanata/zanata-server/teams","hooks_url":"https://api.github.com/repos/zanata/zanata-server/hooks","issue_events_url":"https://api.github.com/repos/zanata/zanata-server/issues/events{/number}","events_url":"https://api.github.com/repos/zanata/zanata-server/events","assignees_url":"https://api.github.com/repos/zanata/zanata-server/assignees{/user}","branches_url":"https://api.github.com/repos/zanata/zanata-server/branches{/branch}","tags_url":"https://api.github.com/repos/zanata/zanata-server/tags","blobs_url":"https://api.github.com/repos/zanata/zanata-server/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/zanata/zanata-server/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/zanata/zanata-server/git/refs{/sha}","trees_url":"https://api.github.com/repos/zanata/zanata-server/git/trees{/sha}","statuses_url":"https://api.github.com/repos/zanata/zanata-server/statuses/{sha}","languages_url":"https://api.github.com/repos/zanata/zanata-server/languages","stargazers_url":"https://api.github.com/repos/zanata/zanata-server/stargazers","contributors_url":"https://api.github.com/repos/zanata/zanata-server/contributors","subscribers_url":"https://api.github.com/repos/zanata/zanata-server/subscribers","subscription_url":"https://api.github.com/repos/zanata/zanata-server/subscription","commits_url":"https://api.github.com/repos/zanata/zanata-server/commits{/sha}","git_commits_url":"https://api.github.com/repos/zanata/zanata-server/git/commits{/sha}","comments_url":"https://api.github.com/repos/zanata/zanata-server/comments{/number}","issue_comment_url":"https://api.github.com/repos/zanata/zanata-server/issues/comments{/number}","contents_url":"https://api.github.com/repos/zanata/zanata-server/contents/{+path}","compare_url":"https://api.github.com/repos/zanata/zanata-server/compare/{base}...{head}","merges_url":"https://api.github.com/repos/zanata/zanata-server/merges","archive_url":"https://api.github.com/repos/zanata/zanata-server/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/zanata/zanata-server/downloads","issues_url":"https://api.github.com/repos/zanata/zanata-server/issues{/number}","pulls_url":"https://api.github.com/repos/zanata/zanata-server/pulls{/number}","milestones_url":"https://api.github.com/repos/zanata/zanata-server/milestones{/number}","notifications_url":"https://api.github.com/repos/zanata/zanata-server/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/zanata/zanata-server/labels{/name}","releases_url":"https://api.github.com/repos/zanata/zanata-server/releases{/id}","created_at":"2011-03-10T00:24:47Z","updated_at":"2015-10-15T03:10:30Z","pushed_at":"2015-10-15T04:28:52Z","git_url":"git://github.com/zanata/zanata-server.git","ssh_url":"git@github.com:zanata/zanata-server.git","clone_url":"https://github.com/zanata/zanata-server.git","svn_url":"https://github.com/zanata/zanata-server","homepage":"http://zanata.org","size":244877,"stargazers_count":124,"watchers_count":124,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":35,"mirror_url":null,"open_issues_count":31,"forks":35,"open_issues":31,"watchers":124,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/zanata/zanata-server/pulls/986"},"html":{"href":"https://github.com/zanata/zanata-server/pull/986"},"issue":{"href":"https://api.github.com/repos/zanata/zanata-server/issues/986"},"comments":{"href":"https://api.github.com/repos/zanata/zanata-server/issues/986/comments"},"review_comments":{"href":"https://api.github.com/repos/zanata/zanata-server/pulls/986/comments"},"review_comment":{"href":"https://api.github.com/repos/zanata/zanata-server/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/zanata/zanata-server/pulls/986/commits"},"statuses":{"href":"https://api.github.com/repos/zanata/zanata-server/statuses/31375a05216e023fe19425048a0e2a4e0c14d2fb"}}}}