{"push_id":865687956,"size":426,"distinct_size":1,"ref":"refs/heads/master","head":"ee9465eb0ea626990f73d7b55f3f0c3011375a32","before":"99f79102ce3f93a79533321a7b7f3d549784bc98","commits":[{"sha":"a3cb61bf81e1ee8b382d7d910abd0bceb6dff3eb","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Improve marker generation. Fix #325.\n\n- Elements covered by other elements do no longer get hints. This makes\n  it easier to use drop-down menus when there are lots of links behind\n  it.\n\n- Elements partly outside the screen now get hints, too.\n\n- Partly covered elements get hints, too. The hint is placed in the\n  first non-covered point of the element.\n\n- Line-wrapped links now get their hint in a better place. This is\n  easiest to explain with a picture. # = old hint location, * = new hint\n  location (approximately)\n\n  #---------+\n  |   *Line-|\n  |wrapped  |\n  +---------+\n\n  Such links also used to count the whole of that box as its area. Now\n  only the actual text is counted, giving the marker a more fair weight.\n\n- We used to take care of the case where markable elements have no area\n  since all of the children are floated and/or absolutely positioned.\n  For performance I’ve removed that. Let’s re-add it if we find some\n  website that needs it. The old implementation used the computed style\n  for this, which has turned out to be really slow.\n\n- We used to check if elements were hidden with CSS (if `opacity: 0;` or\n  `visibility: hidden;`), but we don’t anymore, since it noticeably\n  slows down the marker creation (checking computed styles is slow). It\n  does not appear to be necessary anymore. It was added to fix #164, but\n  the problems there now seem fixed even without this check.\n\n- The code should be more documented now than before.\n\n- The performance is better than before. It does not seem like the new\n  algorithms are slower. And since I’ve removed two slow areas, it might\n  be a little faster.","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/a3cb61bf81e1ee8b382d7d910abd0bceb6dff3eb"},{"sha":"b5fb8c9940d15d37a8949fb56efd7899cc257964","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Add hints to elements with only floated/absolute children\n\nCommit a3cb61bf:\n\n> - We used to take care of the case where markable elements have no area\n>   since all of the children are floated and/or absolutely positioned.\n>   For performance I’ve removed that. Let’s re-add it if we find some\n>   website that needs it. The old implementation used the computed style\n>   for this, which has turned out to be really slow.\n\nSince then I _have_ found such cases. A link in a menu could contain a\nspan of text floated to the left and an icon floated to the right.\n\nSo I’ve re-added support. Best of all, with better performance than the\nold implementation; computed style is _not_ used.\n\nIt turns out that if the width _and_ the height of an element is 0 (thus\nmaking the area 0, too) it is really hidden. But if only one of the\nwidth and height is 0 (also making the area 0), then it is because\neverything inside it is floated and/or absolutely positioned (and that\n`element` hasn’t been made to “contain” the floats). Then there’s no\nneed to check any computed style. Just recursively test each child until\na visible one is found and return its shape instead of the parent.\n\nThe reasoning behind choosing the first visible child is as follows:\n\n- It’s the best bet for the cases with menu items I found. We want the\n  marker at the beginning of the menu item. The text spans, floated to\n  the left, are likely the first children.\n\n- We _could_ add the same hint to _all_ the visible children. But that’s\n  a bad idea for a couple of reasons:\n\n  - It would be inconsistent with all other elements. Even elements with\n    an area can contain floated elements, which are also clickable. But\n    those do not get any hints. (It would be too expensive\n    performance-wise to give them hints, for no real benefit.) Therefore\n    we shouldn’t do it in this case either.\n  - In the found cases with menu items we only want _one_ hint, for the\n    whole menu item. We should optimize for the likely cases.\n  - It would be unnecessarily complex and slow.","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/b5fb8c9940d15d37a8949fb56efd7899cc257964"},{"sha":"e1b3d02f77dbdd1741067ffff04824cadd3c2b0d","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Improve code readability","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/e1b3d02f77dbdd1741067ffff04824cadd3c2b0d"},{"sha":"f0c862d489c45c0f6c65ba91bd2504ce9b82177c","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Better handling of pseudo-elements","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/f0c862d489c45c0f6c65ba91bd2504ce9b82177c"},{"sha":"5778a7476aa5786076038b651b4305fb3f867d8f","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Handle a `line-height` special case\n\nConsider the following HTML:\n\n    <p><a href=#>Link text</a></p>\n\nAnd the following CSS:\n\n    p {\n      line-height: 20px;\n      font-size: 20px;\n      overflow: hidden;\n    }\n    a {\n      font-size: 80px;\n    }\n\nResult, with the rectangles of the elements drawn:\n\n    +---------+\n    |         |\n    |---------+-----------+\n    |Link text|           |\n    |---------------------+\n    |         |\n    +---------+\n\nThe wide rectangle belongs to the `<p>` while the other belongs to the\n`<a>`. The top and bottom part of the `<a>` rectangle, outside of the\n`<p>` rectangle (because the `font-size` of `<a>` is larger than the\n`line-height`), are hidden due to `overflow: hidden;`.\n`document.elementFromPoint()` will only return `<a>` in the area covered\nby both rectangles. That is a problem since we start looking at the\ntop-left corner of the `<a>` rectangle, which will return whatever is\nbehind.\n\nThe solution is to add `line-height: normal;` temporarily to `<a>`,\ncausing the following (with a comparison to the right):\n\n                               /    +---------+\n                               /    |         |\n    +---------------------+    /    |---------+-----------+\n    |Link text            |    /    |Link text|           |\n    |                     |    /    |---------------------+\n    |                     |    /    |         |\n    |                     |    /    +---------+\n    |                     |    /\n    +---------------------+    /\n\nThis way we can get the correct coordinates, but we only do it as a last\nresort, since it is a performance expensive operation.","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/5778a7476aa5786076038b651b4305fb3f867d8f"},{"sha":"89e1bc43d5387da6c3bac489df50d4fd848595be","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Improve marker generation performance\n\n`getFirstNonCoveredPoint` used to recursively search the rect of an\nelement until it found a non-covered point. This works well most of the\ntime, but on some sites (such as prisjakt.se) it took way too much time.\n\nMoreover, this technique required some CSS to be reset in a few special\ncases, which is very costly performance-wise. It is also brittle and\nmakes the code unnecessarily complex.\n\nLastly, there was a bug in the algorithm that caused uncaught exceptions\nsometimes (such as on youtube.com).\n\nNow we use a much simpler approach instead.\n\n`getFirstNonCoveredPoint` tries 6 different points of the element:\n\n    +-------------------------------+\n    |1 left-top          right-top 4|\n    |                               |\n    |2 left-middle    right-middle 5|\n    |                               |\n    |3 left-bottom    right-bottom 6|\n    +-------------------------------+\n\nIf all of those are covered (or are reported as covered because of one\nof the CSS special cases we used to reset) then the whole element is\nsimply considered to be covered. This seems to work really well.\n\nThe above means that the markers can now be placed at any of the points\nin the above figure.\n\nThe result is much faster, simpler and more robust.","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/89e1bc43d5387da6c3bac489df50d4fd848595be"},{"sha":"08fcf959e5c25a52f0bc2cc6a78edf2d25a2f323","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Enhance marker frame handling\n\nPreviously the frame elements themselves were required to get a marker\nin order to make markers for any elements inside the frame, which was\npretty confusing. Now all frames visible in the viewport are gone\nthrough to add markers their elements.","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/08fcf959e5c25a52f0bc2cc6a78edf2d25a2f323"},{"sha":"d6eced3325ee0e75f6ee918ab00e484f7b517cf0","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Merge branch 'develop' into better-hintmarkers","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/d6eced3325ee0e75f6ee918ab00e484f7b517cf0"},{"sha":"b701a0559ab62a5bafc9f4fe27cab8cda01cefa7","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Improve code style\n\n- Wrap at 80 chars.\n- Comments are whole sentences.","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/b701a0559ab62a5bafc9f4fe27cab8cda01cefa7"},{"sha":"0e6da9fe7b873f8a3d576cd597498c451de36f62","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Improve marker placement and fix related bug\n\nBefore commit 89e1bc4 we used to recursively search the rect of an\nelement until it found a non-covered point; after that commit we changed\ninto only checking 6 simple locations of the element, for performance\nreasons. However, this meant two problems:\n\n- It was very confusing when markers ended up to the far right of\n  elements. Sometimes it was difficult to understand which element the\n  marker actually belonged to. Sometimes a tiny bit of the left side of\n  an element was covered (possible by a _transparent_ element!) causing\n  the marker to end up on the right instead, seemingly for no reason.\n- Some elements are overlapped by one pixel both on the left and right\n  side (such as the github pagination links), causing no marker at all\n  to appear.\n\nThe solution is to use the best of both before the referenced commit and\nafter it. Now we check 3 (instead of 6) simple places: Only the 3 on the\nleft side. If the place is covered by another element, we try once to\nthe right of that element. So in total there may be 6 attempts, just as\nbefore.\nAuthor: Simon Lydell <simon.lydell@gmail.com>\nDate:   Sat Aug 2 16:01:36 2014 +0200\n\n    Improve marker generation performance\n\n    `getFirstNonCoveredPoint` used to recursively search the rect of an\n    element until it found a non-covered point. This works well most of the\n    time, but on some sites (such as prisjakt.se) it took way too much time.\n\n    Moreover, this technique required some CSS to be reset in a few special\n    cases, which is very costly performance-wise. It is also brittle and\n    makes the code unnecessarily complex.\n\n    Lastly, there was a bug in the algorithm that caused uncaught exceptions\n    sometimes (such as on youtube.com).\n\n    Now we use a much simpler approach instead.\n\n    `getFirstNonCoveredPoint` tries 6 different points of the element:\n\n        +-------------------------------+\n        |1 left-top          right-top 4|\n        |                               |\n        |2 left-middle    right-middle 5|\n        |                               |\n        |3 left-bottom    right-bottom 6|\n        +-------------------------------+\n\n    If all of those are covered (or are reported as covered because of one\n    of the CSS special cases we used to reset) then the whole element is\n    simply considered to be covered. This seems to work really well.\n\n    The above means that the markers can now be placed at any of the points\n    in the above figure.\n\n    The result is much faster, simpler and more robust.","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/0e6da9fe7b873f8a3d576cd597498c451de36f62"},{"sha":"51a876e4c43ba00d50938e9e72b820052c534d1f","author":{"email":"231e85e0e035e69563ade6c72123be447168b3fa@gmail.com","name":"Wang Zhuochun"},"message":"add command_tab_first_non_pinned","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/51a876e4c43ba00d50938e9e72b820052c534d1f"},{"sha":"338a2d70baf1cc87a7bf4c265241e05bc6092314","author":{"email":"231e85e0e035e69563ade6c72123be447168b3fa@gmail.com","name":"Wang Zhuochun"},"message":"swap default shortcuts to match with vim","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/338a2d70baf1cc87a7bf4c265241e05bc6092314"},{"sha":"89a82f5518664312f9944baf7a29bf7a578a8a0a","author":{"email":"231e85e0e035e69563ade6c72123be447168b3fa@gmail.com","name":"Wang Zhuochun"},"message":"propose new tab commands","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/89a82f5518664312f9944baf7a29bf7a578a8a0a"},{"sha":"fd6621cbf5b03618f6bf61200a92d9622c79db19","author":{"email":"231e85e0e035e69563ade6c72123be447168b3fa@gmail.com","name":"Wang Zhuochun"},"message":"add toggle pin tab command","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/fd6621cbf5b03618f6bf61200a92d9622c79db19"},{"sha":"9917123a6a87dff2abffef4445ccde0df7b56719","author":{"email":"231e85e0e035e69563ade6c72123be447168b3fa@gmail.com","name":"Wang Zhuochun"},"message":"update all locales","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/9917123a6a87dff2abffef4445ccde0df7b56719"},{"sha":"4d695e79b2165d2f0472c57665582e50d1264d0b","author":{"email":"231e85e0e035e69563ade6c72123be447168b3fa@gmail.com","name":"Wang Zhuochun"},"message":"fix typos and console.log","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/4d695e79b2165d2f0472c57665582e50d1264d0b"},{"sha":"c0cd2182427361609df57b8622f97c0549c4244e","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Improve markers for inline line-wrapped elements\n\nIf an inline line-wrapped element starts with a line break, its first\nrect will have an area of almost zero. The marker used to end up on that\nrect, seemingly on the line before the actual link, which was very\nconfusing. Now, such small areas are rounded to zero, and all\n`visibleRects` that have a zero area are discarded, solving the problem.\n\nAn example can be found at the bottom of this page:\nhttp://swrevisited.wordpress.com/esbr-facts/","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/c0cd2182427361609df57b8622f97c0549c4244e"},{"sha":"6919c1d6c6ef6a2a70734c13cfaac54b983fd968","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Try points one pixel into the elements from the edges\n\nOn newyorker.com, `transform: translate3d(0, 0, 0)` is applied on the\ncontent container, to force hardware acceleration. It seems to move\neverything a pixel, causing `document.elementFromPoint` to fail at the\nedges of elements. This commit no longer looks exactly at the edges of\nelements, but one pixel in, which seems to be a safer strategy. (The\nmarker is still nicely placed exactly on the edge, though.)\n\nExample page:\nhttp://www.newyorker.com/currency-tag/the-virtual-moleskine","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/6919c1d6c6ef6a2a70734c13cfaac54b983fd968"},{"sha":"d0502fe4e68072af9d8213b6dc39f67224adba1d","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Refactor commit 6919c1d6c slightly","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/d0502fe4e68072af9d8213b6dc39f67224adba1d"},{"sha":"0e50ba804134b59ffb3f1b6eb3e3fb4f3bc12e85","author":{"email":"bfdf7edfade8c5f44037ffe1d6f03c3967da1c81@gmail.com","name":"Simon Lydell"},"message":"Merge pull request #387 from zhuochun/issue-317-support-first-non-pinned-tab\n\nadd command_tab_first_non_pinned","distinct":false,"url":"https://api.github.com/repos/comepradz/VimFx/commits/0e50ba804134b59ffb3f1b6eb3e3fb4f3bc12e85"}]}