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

Update WebIDL definition(s) to use new mixin syntax #3194

Closed
33 tasks
tobie opened this issue Nov 3, 2017 · 1 comment · Fixed by web-platform-tests/wpt#8703
Closed
33 tasks

Update WebIDL definition(s) to use new mixin syntax #3194

tobie opened this issue Nov 3, 2017 · 1 comment · Fixed by web-platform-tests/wpt#8703

Comments

@tobie
Copy link
Contributor

tobie commented Nov 3, 2017

Hi all!

WebIDL recently introduced dedicated syntax for mixins.

This syntax replaces the [NoInterfaceObject] extended attribute and implements statement which have been deprecated (except for a few legacy uses cases explicitely mentioned in the spec).

You can read more about it here.

In most cases, the changes should be relatively straightforward. The now deprecated:

interface Foo { };

[NoInterfaceObject]  // (Mostly) DEPRECATED
interface Bar { };
Foo implementes Bar; // DEPRECATED

should just be rewritten as:

interface Foo { };

interface mixin Bar { };
Foo includes Bar;

Additonaly, a section on when to use partials and mixins has been added to the spec. It's short and might be worth a read.

It seems the following interfaces in this spec are impacted by this change:

  • HTMLHyperlinkElementUtils
  • CanvasState
  • CanvasTransform
  • CanvasCompositing
  • CanvasImageSmoothing
  • CanvasFillStrokeStyles
  • CanvasShadowStyles
  • CanvasFilters
  • CanvasRect
  • CanvasDrawPath
  • CanvasUserInterface
  • CanvasText
  • CanvasDrawImage
  • CanvasImageData
  • CanvasPathDrawingStyles
  • CanvasTextDrawingStyles
  • CanvasPath
  • ElementContentEditable
  • NavigatorOnLine
  • GlobalEventHandlers
  • WindowEventHandlers
  • DocumentAndElementEventHandlers
  • WindowOrWorkerGlobalScope
  • NavigatorID
  • NavigatorLanguage
  • NavigatorContentUtils
  • NavigatorCookies
  • NavigatorPlugins
  • AbstractWorker
  • NavigatorConcurrentHardware
  • WindowSessionStorage
  • WindowLocalStorage
  • External

We're sorry for the inconvenience this causes, but our hope is that this ultimately makes things simpler and clearer for everybody.

As always, please feel free to reach out if you have any questions.

Thanks!


Tracked in: whatwg/webidl#472 | Original pull-request: whatwg/webidl#433

@domenic
Copy link
Member

domenic commented Nov 3, 2017

From #3187, @annevk says:

I think we also need to block this on tooling as the HTML Standard is scraped for IDL. If that tool can no longer recognize our IDL all kinds of cross-references might go dead.

annevk pushed a commit to web-platform-tests/wpt that referenced this issue Dec 18, 2017
@TimothyGu TimothyGu reopened this Dec 18, 2017
alice pushed a commit to alice/html that referenced this issue Jan 8, 2019
WebIDL recently introduced dedicated syntax for mixins [1]. This replaces the
existing [NoInterfaceObject] and "implements" syntax with "interface mixin" and
"includes" in the appropriate places.

Closes whatwg#3194.

[1]: whatwg/webidl@45e8173
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

3 participants