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

Remove uses of html imports from WebUI #6736

Merged
merged 1 commit into from
Sep 30, 2020

Conversation

petemill
Copy link
Member

@petemill petemill commented Sep 30, 2020

Chromium 86 no longer supports html imports, even for WebUI. We were only using it to:

  1. Import a polymer component, br-toolbar. This has already been converted to an es module, so we simply include that.
  2. Import cr.html which was never neccessary because we also include cr.js already. cr.html only additionally adds the import for PromiseResolver, which no brave code uses.
    TODO: remove calls to cr.js and just import * as cr from cr.m.js directly wherever cr.* is used.

Fix brave/brave-browser#11937

Submitter Checklist:

Test Plan:

Ensure brave/brave-browser#11937 is resolved. Additionally ensure the following WebUI pages still work correctly:

  • Rewards Tip
  • Rewards Internal
  • Ad Block
  • IPFS
  • Webcompat Reporter

Reviewer Checklist:

  • New files have MPL-2.0 license header.
  • Request a security/privacy review as needed.
  • Adequate test coverage exists to prevent regressions
  • Verify test plan is specified in PR before merging to source

After-merge Checklist:

  • The associated issue milestone is set to the smallest version that the
    changes has landed on.
  • All relevant documentation has been updated.

Chromium 86 no longer supports html imports, even for WebUI. We were only using it to:
1. Import a polymer component, br-toolbar. This has already been converted to an es module, so we simply include that.
2. Import cr.html which was never neccessary because we also include cr.js already. cr.html only additionally adds the import for PromiseResolver, which no brave code uses.
  TODO: remove calls to cr.js and just `import * as cr from cr.m.js` directly wherever cr.* is used.
Copy link
Contributor

@emerick emerick left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Member

@bsclifton bsclifton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM too - compiling so I can give it a go (can report back; don't hold up the merge for me)

@bsclifton
Copy link
Member

Confirmed- works great! 😄 🎉

@petemill petemill merged commit 518ef0f into master Sep 30, 2020
@petemill petemill deleted the remove-html-imports-from-webui branch September 30, 2020 23:27
@kjozwiak kjozwiak added this to the 1.17.x - Nightly milestone Oct 1, 2020
kjozwiak added a commit that referenced this pull request Oct 1, 2020
kjozwiak added a commit that referenced this pull request Oct 1, 2020
This was referenced Oct 1, 2020
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.

[Desktop] some brave:// pages are missing the navigation bar - C86 regression
7 participants