Skip to content

Fix a typo in mqeditor.js.#1453

Merged
Alex-Jordan merged 1 commit into
openwebwork:PG-2.21from
drgrice1:bugfix/add-toolbar-buttons-type
Jul 7, 2026
Merged

Fix a typo in mqeditor.js.#1453
Alex-Jordan merged 1 commit into
openwebwork:PG-2.21from
drgrice1:bugfix/add-toolbar-buttons-type

Conversation

@drgrice1

@drgrice1 drgrice1 commented Jul 5, 2026

Copy link
Copy Markdown
Member

There is no addToolbarButton method. It is addToolbarButtons. This was caused when I changed the MathQuill api, but forgot to change this.

As a result, if an answer uses parserLogb.pl the subscript button is not added to the toolbar, and a console log error occurs when this non-existent method is called.

For a problem to test this with you could use:

DOCUMENT();

loadMacros(qw(PGstandard.pl PGML.pl parserLogb.pl));

Parser::Logb->Enable;
$n = logb(3, 5);

BEGIN_PGML
Enter [`\log_3(5)`]: [_]{$n}{5}
END_PGML

ENDDOCUMENT();

There is no `addToolbarButton` method.  It is `addToolbarButtons`. This
was caused when I changed the MathQuill api, but forgot to change this.

As a result, if an answer uses `parserLogb.pl` the `subscript` button is
not added to the toolbar, and a console log error occurs when this
non-existent method is called.

For a problem to test this with you could use:

```PG
DOCUMENT();

loadMacros(qw(PGstandard.pl PGML.pl parserLogb.pl));

Parser::Logb->Enable;
$n = logb(3, 5);

BEGIN_PGML
Enter [`\log_3(5)`]: [_]{$n}{5}
END_PGML

ENDDOCUMENT();
```
@Alex-Jordan Alex-Jordan merged commit 4e755e2 into openwebwork:PG-2.21 Jul 7, 2026
3 checks passed
@drgrice1 drgrice1 deleted the bugfix/add-toolbar-buttons-type branch July 7, 2026 22:05
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