PolymerElements / font-roboto

Loads the Roboto family of fonts from Google Fonts.
5 stars 35 forks source link

It loads style into imported document, what is deprecated and throw warnings #20

Open tomalec opened 6 years ago

tomalec commented 6 years ago

Description

https://github.com/PolymerElements/font-roboto/blob/master/roboto.html#L10 loads stylesheet directly into imported document. That is deprecated and throws a warning (for every page that uses paper-styles)

See https://github.com/TakayoshiKochi/deprecate-style-in-html-imports https://bugs.chromium.org/p/chromium/issues/detail?id=523952

Expected outcome

Pages that use the latest version of Polymer Elements and Chrome should be free of warnings, or at least of actual cases that would stop working soon (<link>s and <style>s which are not moved by <custom-style>).

Actual outcome

A warning is thrown, <link> element is not copied to the main document.

Live Demo

https://jsbin.com/regiweh/1/edit?html,console,output

Steps to reproduce

  1. Import a paper-item element in the page.
    <link rel="import" href="paper-item/paper-item.html">
  2. Open the page in Chromium.
  3. Watch the console.

Browsers Affected