Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions ts/a11y/complexity/collapse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ import {
AbstractMmlTokenNode,
TextNode,
} from '../../core/MmlTree/MmlNode.js';
import { PropertyList } from '../../core/Tree/Node.js';
import { ComplexityVisitor } from './visitor.js';

/*==========================================================================*/
Expand Down Expand Up @@ -584,9 +585,10 @@ export class Collapse {
const factory = this.complexity.factory;
const marker = node.getProperty('collapse-marker') as string;
const parent = node.parent;
const variant = node.getProperty('collapse-variant')
? { mathvariant: '-tex-variant' }
: {};
const variant = { 'data-mjx-collapsed': true } as PropertyList;
if (node.getProperty('collapse-variant')) {
variant.mathvariant = '-tex-variant';
}
const maction = factory.create(
'maction',
{
Expand Down
2 changes: 1 addition & 1 deletion ts/a11y/explorer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -413,7 +413,7 @@ export function ExplorerMathDocumentMixin<
fill: 'white',
},
'mjx-help > svg > circle:nth-child(2)': {
fill: 'rgba(0, 0, 255, 0.2)',
fill: 'var(--mjx-bg1-color)',
r: '7px',
},
'mjx-help > svg > line': {
Expand Down
3 changes: 2 additions & 1 deletion ts/a11y/explorer/ExplorerPool.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@ import * as me from './MouseExplorer.js';
import { TreeColorer, FlameColorer } from './TreeExplorer.js';

import { Highlighter, getHighlighter } from './Highlighter.js';
// import * as Sre from '../sre.js';

/**
* The regions objects needed for the explorers.
Expand Down Expand Up @@ -360,6 +359,7 @@ export class ExplorerPool {
protected setPrimaryHighlighter() {
const [foreground, background] = this.colorOptions();
this._highlighter = getHighlighter(
LiveRegion.priority.primary,
background,
foreground,
this.document.outputJax.name
Expand All @@ -371,6 +371,7 @@ export class ExplorerPool {
*/
protected setSecondaryHighlighter() {
this.secondaryHighlighter = getHighlighter(
LiveRegion.priority.secondary,
{ color: 'red' },
{ color: 'black' },
this.document.outputJax.name
Expand Down
Loading