Skip to content

Commit

Permalink
Set up publishing of @webref/idl with Lerna
Browse files Browse the repository at this point in the history
Lerna is a tool for managing monorepos, and while @webref/idl is the
only package here now, the packages/* structure makes sense.

Fixes #63.
  • Loading branch information
foolip committed Feb 10, 2021
1 parent d80034b commit 28ad533
Show file tree
Hide file tree
Showing 23 changed files with 8,113 additions and 201 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Test
on:
pull_request: {}
push:
branches:
- master
jobs:
test:
name: Test
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: 14.x
- run: npm ci
- run: npx lerna bootstrap
- run: npm test
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
node_modules/
packages/idl/*.idl
wpt/
31 changes: 31 additions & 0 deletions ed/idlpatches/SRI.idl.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
From 3476739b49c9fbf76816b735e3a7767a6cb0d395 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Philip=20J=C3=A4genstedt?= <philip@foolip.org>
Date: Thu, 21 Jan 2021 20:58:12 +0100
Subject: [PATCH] Remove SRI.idl (now part of HTML)

---
ed/idl/SRI.idl | 12 ------------
1 file changed, 12 deletions(-)
delete mode 100644 ed/idl/SRI.idl

diff --git a/ed/idl/SRI.idl b/ed/idl/SRI.idl
deleted file mode 100644
index 78f916fe6..000000000
--- a/ed/idl/SRI.idl
+++ /dev/null
@@ -1,12 +0,0 @@
-// GENERATED CONTENT - DO NOT EDIT
-// Content was automatically extracted by Reffy into webref
-// (https://github.com/w3c/webref)
-// Source: Subresource Integrity (https://w3c.github.io/webappsec-subresource-integrity/)
-
-partial interface HTMLLinkElement {
- attribute DOMString integrity;
-};
-
-partial interface HTMLScriptElement {
- attribute DOMString integrity;
-};
--
2.30.0.365.g02bc693789-goog

62 changes: 62 additions & 0 deletions ed/idlpatches/SVG.idl.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
From b613b767652effae7f44680cb08d895658460318 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Philip=20J=C3=A4genstedt?= <philip@foolip.org>
Date: Wed, 10 Feb 2021 13:13:29 +0100
Subject: [PATCH] Remove duplicate SVG definitions

---
ed/idl/SVG.idl | 32 --------------------------------
1 file changed, 32 deletions(-)

diff --git a/ed/idl/SVG.idl b/ed/idl/SVG.idl
index f8d24c9c6..64ad64f8f 100644
--- a/ed/idl/SVG.idl
+++ b/ed/idl/SVG.idl
@@ -417,10 +417,6 @@ interface SVGAnimatedPreserveAspectRatio {
[SameObject] readonly attribute SVGPreserveAspectRatio animVal;
};

-[Exposed=Window]
-interface SVGPathElement : SVGGeometryElement {
-};
-
[Exposed=Window]
interface SVGRectElement : SVGGeometryElement {
[SameObject] readonly attribute SVGAnimatedLength x;
@@ -566,34 +562,6 @@ interface SVGForeignObjectElement : SVGGraphicsElement {
[SameObject] readonly attribute SVGAnimatedLength height;
};

-[Exposed=Window]
-interface SVGMarkerElement : SVGElement {
-
- // Marker Unit Types
- const unsigned short SVG_MARKERUNITS_UNKNOWN = 0;
- const unsigned short SVG_MARKERUNITS_USERSPACEONUSE = 1;
- const unsigned short SVG_MARKERUNITS_STROKEWIDTH = 2;
-
- // Marker Orientation Types
- const unsigned short SVG_MARKER_ORIENT_UNKNOWN = 0;
- const unsigned short SVG_MARKER_ORIENT_AUTO = 1;
- const unsigned short SVG_MARKER_ORIENT_ANGLE = 2;
-
- [SameObject] readonly attribute SVGAnimatedLength refX;
- [SameObject] readonly attribute SVGAnimatedLength refY;
- [SameObject] readonly attribute SVGAnimatedEnumeration markerUnits;
- [SameObject] readonly attribute SVGAnimatedLength markerWidth;
- [SameObject] readonly attribute SVGAnimatedLength markerHeight;
- [SameObject] readonly attribute SVGAnimatedEnumeration orientType;
- [SameObject] readonly attribute SVGAnimatedAngle orientAngle;
- attribute DOMString orient;
-
- void setOrientToAuto();
- void setOrientToAngle(SVGAngle angle);
-};
-
-SVGMarkerElement includes SVGFitToViewBox;
-
[Exposed=Window]
interface SVGGradientElement : SVGElement {

--
2.30.0.365.g02bc693789-goog

43 changes: 43 additions & 0 deletions ed/idlpatches/cssom-view.idl.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
From 68686f764a9943de5ad5ac1372995545a7745a62 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Philip=20J=C3=A4genstedt?= <philip@foolip.org>
Date: Tue, 21 Jul 2020 20:58:26 +0200
Subject: [PATCH] Drop duplicate MouseEvent members

https://github.com/w3c/csswg-drafts/issues/4084
---
ed/idl/cssom-view.idl | 11 -----------
1 file changed, 11 deletions(-)

diff --git a/ed/idl/cssom-view.idl b/ed/idl/cssom-view.idl
index f998758dd..747361527 100644
--- a/ed/idl/cssom-view.idl
+++ b/ed/idl/cssom-view.idl
@@ -139,25 +139,14 @@ partial interface Range {
};

partial interface MouseEvent {
- readonly attribute double screenX;
- readonly attribute double screenY;
readonly attribute double pageX;
readonly attribute double pageY;
- readonly attribute double clientX;
- readonly attribute double clientY;
readonly attribute double x;
readonly attribute double y;
readonly attribute double offsetX;
readonly attribute double offsetY;
};

-partial dictionary MouseEventInit {
- double screenX = 0.0;
- double screenY = 0.0;
- double clientX = 0.0;
- double clientY = 0.0;
-};
-
enum CSSBoxType { "margin", "border", "padding", "content" };
dictionary BoxQuadOptions {
CSSBoxType box = "border";
--
2.30.0.365.g02bc693789-goog

34 changes: 34 additions & 0 deletions ed/idlpatches/keyboard-map.idl.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
From 233474456ee5395ccde82eef47fc0b157798102c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Philip=20J=C3=A4genstedt?= <philip@foolip.org>
Date: Tue, 21 Jul 2020 19:44:55 +0200
Subject: [PATCH] Use partial interface Keyboard

https://github.com/WICG/keyboard-map/issues/25
---
ed/idl/keyboard-map.idl | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/ed/idl/keyboard-map.idl b/ed/idl/keyboard-map.idl
index 8d95d8850..67c40333b 100644
--- a/ed/idl/keyboard-map.idl
+++ b/ed/idl/keyboard-map.idl
@@ -3,15 +3,10 @@
// (https://github.com/w3c/webref)
// Source: Keyboard Map (https://wicg.github.io/keyboard-map/)

-[Exposed=Window]
-partial interface Navigator {
- [SecureContext, SameObject] readonly attribute Keyboard keyboard;
-};
-
interface KeyboardLayoutMap {
readonly maplike<DOMString, DOMString>;
};

-[SecureContext, Exposed=Window] interface Keyboard {
+partial interface Keyboard {
Promise<KeyboardLayoutMap> getLayoutMap();
};
--
2.30.0.365.g02bc693789-goog

26 changes: 26 additions & 0 deletions ed/idlpatches/mathml-core.idl.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
From 8eb951f405d795e58b03b3a1f67a2f629a3ad8b7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Philip=20J=C3=A4genstedt?= <philip@foolip.org>
Date: Fri, 3 Jul 2020 23:04:42 +0200
Subject: [PATCH] Fix mathml-core.idl

https://github.com/mathml-refresh/mathml-core/pull/19
https://github.com/whatwg/html/pull/5248
https://github.com/mathml-refresh/mathml-core/pull/31
---
ed/idl/mathml-core.idl | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/ed/idl/mathml-core.idl b/ed/idl/mathml-core.idl
index a226ff084..7ea134625 100644
--- a/ed/idl/mathml-core.idl
+++ b/ed/idl/mathml-core.idl
@@ -7,5 +7,4 @@
interface MathMLElement : Element { };
MathMLElement includes GlobalEventHandlers;
MathMLElement includes DocumentAndElementEventHandlers;
-MathMLElement includes HTMLOrForeignElement;
-MathMLElement includes ElementCSSInlineStyle;
+MathMLElement includes HTMLOrSVGElement;
--
2.30.0.365.g02bc693789-goog

29 changes: 29 additions & 0 deletions ed/idlpatches/media-source.idl.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
From 185485ef4640ba3bb4380f393a34f2b2e7e9402c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Philip=20J=C3=A4genstedt?= <philip@foolip.org>
Date: Thu, 23 Jul 2020 12:48:05 +0200
Subject: [PATCH] Remove createObjectURL extension

https://github.com/w3c/media-source/pull/229
---
ed/idl/media-source.idl | 5 -----
1 file changed, 5 deletions(-)

diff --git a/ed/idl/media-source.idl b/ed/idl/media-source.idl
index f32df3aae..ba57b1310 100644
--- a/ed/idl/media-source.idl
+++ b/ed/idl/media-source.idl
@@ -66,11 +66,6 @@ interface SourceBufferList : EventTarget {
getter SourceBuffer (unsigned long index);
};

-[Exposed=Window]
-partial interface URL {
- static DOMString createObjectURL (MediaSource mediaSource);
-};
-
partial interface AudioTrack {
readonly attribute SourceBuffer? sourceBuffer;
};
--
2.30.0.365.g02bc693789-goog

29 changes: 29 additions & 0 deletions ed/idlpatches/orientation-event.idl.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
From ea0f23f43b8ffcf2b7118e53e7d990eba59205da Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Philip=20J=C3=A4genstedt?= <philip@foolip.org>
Date: Tue, 21 Jul 2020 19:49:05 +0200
Subject: [PATCH] Drop duplicate PermissionState definition

https://github.com/w3c/deviceorientation/pull/88
---
ed/idl/orientation-event.idl | 5 -----
1 file changed, 5 deletions(-)

diff --git a/ed/idl/orientation-event.idl b/ed/idl/orientation-event.idl
index 4cd4356d2..f6ff96f0e 100644
--- a/ed/idl/orientation-event.idl
+++ b/ed/idl/orientation-event.idl
@@ -25,11 +25,6 @@ dictionary DeviceOrientationEventInit : EventInit {
boolean absolute = false;
};

-enum PermissionState {
- "granted",
- "denied",
-};
-
partial interface Window {
[SecureContext] attribute EventHandler ondeviceorientationabsolute;
};
--
2.30.0.365.g02bc693789-goog

26 changes: 26 additions & 0 deletions ed/idlpatches/portals.idl.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
From f7d204a5a5004b1fc1e8273c3e7b8220dc0a8ff1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Philip=20J=C3=A4genstedt?= <philip@foolip.org>
Date: Tue, 21 Jul 2020 19:56:23 +0200
Subject: [PATCH] Remove duplicate typedef MessageEventSource

https://github.com/WICG/portals/issues/230
---
ed/idl/portals.idl | 2 --
1 file changed, 2 deletions(-)

diff --git a/ed/idl/portals.idl b/ed/idl/portals.idl
index 0957b2a9c..d0b132889 100644
--- a/ed/idl/portals.idl
+++ b/ed/idl/portals.idl
@@ -43,8 +43,6 @@ dictionary PortalActivateEventInit : EventInit {
any data = null;
};

-typedef (WindowProxy or MessagePort or ServiceWorker or HTMLPortalElement or PortalHost) MessageEventSource;
-
partial interface mixin WindowEventHandlers {
attribute EventHandler onportalactivate;
};
--
2.30.0.365.g02bc693789-goog

36 changes: 36 additions & 0 deletions ed/idlpatches/svg-paths.idl.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
From c1893436732e2d22c2c59f1556b52df24c05c718 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Philip=20J=C3=A4genstedt?= <philip@foolip.org>
Date: Fri, 3 Jul 2020 23:00:39 +0200
Subject: [PATCH] Fix svg-paths.idl

https://github.com/w3c/svgwg/pull/802
---
ed/idl/svg-paths.idl | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/ed/idl/svg-paths.idl b/ed/idl/svg-paths.idl
index 84a067491..c3dd8249b 100644
--- a/ed/idl/svg-paths.idl
+++ b/ed/idl/svg-paths.idl
@@ -3,15 +3,14 @@
// (https://github.com/w3c/webref)
// Source: SVG Paths (https://svgwg.org/specs/paths/)

-[NoInterfaceObject]
interface SVGPathSegment {
- DOMString type;
- sequence<float> values;
+ attribute DOMString type;
+ attribute FrozenArray<float> values;
};

dictionary SVGPathDataSettings {
boolean normalize = false;
-}
+};

interface mixin SVGPathData {
sequence<SVGPathSegment> getPathData(optional SVGPathDataSettings settings);
--
2.30.0.365.g02bc693789-goog

Loading

0 comments on commit 28ad533

Please sign in to comment.