mathquill / mathquill

Easily type math in your webapp
http://mathquill.com
Mozilla Public License 2.0
2.61k stars 687 forks source link

Various fixes from Desmos - Scope ARIA element to mathquill instance, auto op in subscript expansion option, selection benchmark #968

Closed jaltekruse closed 9 months ago

jaltekruse commented 2 years ago

Note this is part of a chain of PRs that are concurrently under review to incorporate extensive work done by the Desmos team. The PRs all target one another in series. There is one big changeset that starts everything and two reformatting/restructuring changesets later in the series, so this is being done to have cleaner diffs, but without creating tons of individual PRs.

We are intending to merge all of these PRs at the same time when we are done reviewing all of them. The largest bulk of the changes have been posted for a few months in #947.

There a small inconvenience looking through the branches, you will see a number of "merge in branch feature-name-xyz resolves #YYYY" These will link you to issues or PRs in the mathquill org, but they are actually referencing PR numbers in the desmos fork, to see the conversations on these issues, you can click the links and then just replace the org part of the url to be desmosinc instead of mathquill, i.e change https://github.com/mathquill/mathquill/issues/168 to https://github.com/desmosinc/mathquill/issues/168.

The chain of PRs:

  1. Incorporate the Demsos fork, changes from the past couple of years, adds screen reader support and many fixes and smaller features - https://github.com/mathquill/mathquill/pull/947

  2. Convert the codebase to typescript https://github.com/mathquill/mathquill/pull/967

  3. A few various fixes after the typescript conversion https://github.com/mathquill/mathquill/pull/968

  4. Add Prettier to atuo-format the code https://github.com/mathquill/mathquill/pull/969

  5. Fix selection performance https://github.com/mathquill/mathquill/pull/970


This PR is focused on making behavior changes that Desmos made on our fork be configurable and opt-in so that we can contribute them upstream without them being breaking changes.

In addition to the new options added in https://github.com/mathquill/mathquill/pull/947/, this PR adds two new config options.

This PR also updates the screen reader support to add aria-live DOM to the same container as MQ's other dom (such as its hidden text area), instead of appending a single aria-live element to body. The idea here is to avoid messing with parts of the page that MQ doesn't "own."

jwmerrill commented 9 months ago

Closed by https://github.com/mathquill/mathquill/pull/1025