Skip to content

Fix a typo in mqeditor.js.#1453

Open
drgrice1 wants to merge 1 commit into
openwebwork:PG-2.21from
drgrice1:bugfix/add-toolbar-buttons-type
Open

Fix a typo in mqeditor.js.#1453
drgrice1 wants to merge 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();
```
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.

2 participants