Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chrome M121 breaks <ruby> unittest #476

Closed
tushuhei opened this issue Jan 31, 2024 · 4 comments · Fixed by #483
Closed

Chrome M121 breaks <ruby> unittest #476

tushuhei opened this issue Jan 31, 2024 · 4 comments · Fixed by #483
Assignees

Comments

@tushuhei
Copy link
Member

A JavaScript unit test case is failing at https://github.com/google/budoux/actions/runs/7726982481/job/21064428934

 HTMLProcessor.getBlocks should skip <rt> and <rp> elements for <ruby> FAILED

Since the same test case passes on Chrome Headless M120, but not on M121, I believe the change is brought by the Chrome update.

@tushuhei
Copy link
Member Author

tushuhei commented Feb 1, 2024

@kojiishi Could you take a look at this? It seems the <ruby> tag is treated differently between Chrome M120 and 121.

@kojiishi
Copy link
Collaborator

kojiishi commented Feb 1, 2024

Thanks, I'll take a look. /cc @tkent-google

@kojiishi
Copy link
Collaborator

kojiishi commented Feb 7, 2024

So there was a spec change. The current BudouX has a logic to determine if an element is inline or block:

      return display === 'inline' ? DomAction.Inline : DomAction.Block;

This no longer works since crbug.com/880802, as getComputedStyle(<ruby>).display returns ruby.

The CSS Display multi-keyword syntax also shipped at crbug.com/995106. Looking at this, ruby is probably the only case where we want it to be in-flow.

@tushuhei
Copy link
Member Author

tushuhei commented Feb 7, 2024

That’s interesting! Thanks for investigating.
Does it make sense to map display==='ruby' to DomAction.Inline, then?

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 a pull request may close this issue.

2 participants