{"shas":[["105af00448c1849ceffbd4dc65bc4006dee393b2","5fca4eefe9085cdadcf8dc21e94603b679c33eb2@fb.com","RFC: Order DOM event handlers by shortest matching sigil distance from target\nnode.\n\nSummary:\nA suggested change to the order in which matching event handlers are called.\nCurrently javelin claims no guarantee for any kind of order, but in practice the\norder is the order in which the event handlers were defined. This keeps order of\ndefinition as the secondary sort, but makes primary sort the distance of the\nmatching sigil node from the event target node.\n\nThis means if you have markup:\n\n  <div data-sigil=\"one\">\n    <div data-sigil=\"two\">\n      <div data-sigil=\"three\">\n        Click me\n      </div>\n    </div>\n  </div>\n\nThat a handler listening to the sigil path ['three'] would execute before a\nhandler listening to the sigil path ['two'].\n\nFor sigil paths with more than one sigil, it will take the shortest distance to\nmatch, so sigil path ['one', 'three'] would execute before ['two'].\n\nFor handlers which listen to all events, the distance is assumed to be \"0\" in\neffect pointing to the target node, so listening to null would execute before\n['two'] but with the same priority (in this case) as ['three'], falling back on\nthe order in which they were assigned.\n\nThis has the benefit of mirroring the behavior of the DOM event API's bubbling\nmechanism so that a more specific region of the DOM recieves events before ta\nmore general region.\n\nTest Plan: Tested against the fb m-site and tested in the console with the cases\nlisted in the summary.\n\nReviewers: epriestley, mroch, yungsters\n\nReviewed By: epriestley\n\nCC: aran, epriestley, jg, hedger, mroch, leebyron, akrieger\n\nDifferential Revision: 925","Lee Byron"],["bea9e6b877b3ffd7b5f54eda35cc986e1499d3bc","ed0ea3b109c58f4bd630fb7b754877167dd611c2@fb.com"," JX.DOM.find() exceptions should indicate which id failed\n\nSummary:\nRight not when you get a JX.$ exception, it says 'Error: JX.$() or JX.DOM.find()\ncall matched no nodes.\" .\n\nIt should indicate the exact DOM id with the issue so it's easier to debug.\n\nThis changes JX.$.NotFound to be more descriptive.  To filter out JX.$.NotFound\nexceptions, use\n\ne instanceof JX.$.NotFound\n\ne.g.\n\ntry { throw new JX.$.NotFound('someid'); somethingelse(); }\ncatch (e) {\nif (!(e instanceof JX.$.NotFound)) {\nthrow e;\n}\n}\n\nTest Plan:\nsaw exception:\n\nAFTER:\n\n\"JX.$(\\\"errorBox\\\" ) call matched no nodes.\"\n\nBEFORE\n\nJX.$ or JX.DOM.find() call matched no nodes.\"\n\nReviewers: epriestley, mroch, aran, jg\n\nReviewed By: epriestley\n\nCC: aran, cpojer, tomo, epriestley, phil, jg\n\nDifferential Revision: 939","Philip Fung"],["c54216742a1319d4e740224e2cffddb1ca533988","ed0ea3b109c58f4bd630fb7b754877167dd611c2@fb.com","Merge branch 'master' of https://github.com/facebook/javelin","Philip Fung"]],"ref":"refs/heads/master","size":3,"head":"c54216742a1319d4e740224e2cffddb1ca533988","push_id":42968944}