Bug 775618 - Introduce break-inside, and alias page-break-inside to it. r=heycam
authorEmilio Cobos Álvarez <emilio@crisal.io>
Tue, 20 Nov 2018 05:07:52 +0000
changeset 508147 c228095e647e155d3638a667341f867774c07a81
parent 508146 8c4e43e477e5bd528f07f67d2d404bda38529aec
child 508148 f97f45821194fd28be1282d3a854ed129498d187
push id1905
push userffxbld-merge
push dateMon, 21 Jan 2019 12:33:13 +0000
treeherdermozilla-release@c2fca1944d8c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersheycam
bugs775618
milestone65.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 775618 - Introduce break-inside, and alias page-break-inside to it. r=heycam This property has no weird value mapping, so we can just do this. Differential Revision: https://phabricator.services.mozilla.com/D12212
layout/style/test/property_database.js
servo/components/style/properties/longhands/box.mako.rs
--- a/layout/style/test/property_database.js
+++ b/layout/style/test/property_database.js
@@ -4307,23 +4307,30 @@ var gCSSProperties = {
   "page-break-before": {
     domProp: "pageBreakBefore",
     inherited: false,
     type: CSS_TYPE_LONGHAND,
     initial_values: [ "auto" ],
     other_values: [ "always", "avoid", "left", "right" ],
     invalid_values: []
   },
-  "page-break-inside": {
-    domProp: "pageBreakInside",
+  "break-inside": {
+    domProp: "breakInside",
     inherited: false,
     type: CSS_TYPE_LONGHAND,
     initial_values: [ "auto" ],
     other_values: [ "avoid" ],
-    invalid_values: [ "left", "right" ]
+    invalid_values: [ "left", "right", "always" ]
+  },
+  "page-break-inside": {
+    domProp: "pageBreakInside",
+    inherited: false,
+    type: CSS_TYPE_SHORTHAND_AND_LONGHAND,
+    alias_for: "break-inside",
+    subproperties: [ "break-inside" ],
   },
   "paint-order": {
     domProp: "paintOrder",
     inherited: true,
     type: CSS_TYPE_LONGHAND,
     initial_values: [ "normal" ],
     other_values: [ "fill", "fill stroke", "fill stroke markers", "stroke markers fill" ],
     invalid_values: [ "fill stroke markers fill", "fill normal" ]
--- a/servo/components/style/properties/longhands/box.mako.rs
+++ b/servo/components/style/properties/longhands/box.mako.rs
@@ -453,23 +453,23 @@
     "computed::BreakBetween::Auto",
     needs_context=False,
     products="gecko",
     spec="https://drafts.csswg.org/css2/page.html#propdef-page-break-before",
     animation_value_type="discrete",
 )}
 
 ${helpers.predefined_type(
-    "page-break-inside",
+    "break-inside",
     "BreakWithin",
     "computed::BreakWithin::Auto",
-    gecko_ffi_name="mBreakInside",
     needs_context=False,
     products="gecko",
-    spec="https://drafts.csswg.org/css2/page.html#propdef-page-break-inside",
+    alias="page-break-inside",
+    spec="https://drafts.csswg.org/css-break/#propdef-break-inside",
     animation_value_type="discrete",
 )}
 
 // CSS Basic User Interface Module Level 3
 // http://dev.w3.org/csswg/css-ui
 //
 // This is APPLIES_TO_PLACEHOLDER so we can override, in the UA sheet, the
 // 'resize' property we'd inherit from textarea otherwise.  Basically, just