Skip to content

Conversation

@anandthakker
Copy link

Fixes a prayer failure when selecting over a separate, embedded MathQuill instance

@anandthakker anandthakker force-pushed the anand/fix-select-over-embedded branch from 4ec8ca0 to 697c3ae Compare October 1, 2025 11:15
if (node) {
// Special case: if we found a node that belongs to a different root than ours, that means we're in a separate,
// embedded MathQuill instance. In that case, skip to that root's parent and continue.
const root = findControllerRoot(node);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

are you worried about run time complexity here? Seems like this itself will do an entire scan up the tree while we are already in a scan up the tree.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's okay because it will either break the loop or jump up to the container of the embedded MQ instance

@@ -0,0 +1,77 @@
suite.only('mouse', function () {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If I remember what this means I think we don't want this .only() left in.

Copy link
Author

@anandthakker anandthakker Oct 1, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh shoot, yes good catch

Specifically: fixed position for the #mock element, and use measurements to choose our target mouse positions so we know exactly what to expect
@anandthakker anandthakker merged commit fcafcee into main Oct 1, 2025
3 checks passed
@anandthakker anandthakker deleted the anand/fix-select-over-embedded branch October 1, 2025 16:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants