Gitweb links:

...log 
http://git.netsurf-browser.org/libcss.git/shortlog/0074b97d0c08381b97c18fc901ae195bb529233d
...commit 
http://git.netsurf-browser.org/libcss.git/commit/0074b97d0c08381b97c18fc901ae195bb529233d
...tree 
http://git.netsurf-browser.org/libcss.git/tree/0074b97d0c08381b97c18fc901ae195bb529233d

The branch, lcneves/flexbox has been updated
       via  0074b97d0c08381b97c18fc901ae195bb529233d (commit)
      from  54b14acee8d6c45c747c486c2d531fea2b30502e (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commitdiff 
http://git.netsurf-browser.org/libcss.git/commit/?id=0074b97d0c08381b97c18fc901ae195bb529233d
commit 0074b97d0c08381b97c18fc901ae195bb529233d
Author: Lucas Neves <[email protected]>
Commit: Lucas Neves <[email protected]>

    Parse: rewrite flex shorthand parser to conform to standards

diff --git a/src/parse/properties/flex.c b/src/parse/properties/flex.c
index b2fd67e..dfec5bf 100644
--- a/src/parse/properties/flex.c
+++ b/src/parse/properties/flex.c
@@ -88,7 +88,7 @@ css_error css__parse_flex(css_language *c,
                return error;
        }
 
-       /* Handle none = flex: 0 0 auto; */
+       /* Handle none, equivalent of flex: 0 0 auto; */
        if ((token->type == CSS_TOKEN_IDENT) &&
                (lwc_string_caseless_isequal(
                        token->idata, c->strings[NONE],
@@ -117,9 +117,10 @@ css_error css__parse_flex(css_language *c,
                        goto css__parse_flex_cleanup;
 
                grow = shrink = basis = false;
+               parserutils_vector_iterate(vector, ctx);
        }
 
-       /* Handle auto = flex: 1 1 auto; */
+       /* Handle auto, equivalent of flex: 1 1 auto; */
        else if ((token->type == CSS_TOKEN_IDENT) &&
                (lwc_string_caseless_isequal(
                        token->idata, c->strings[AUTO],
@@ -148,6 +149,7 @@ css_error css__parse_flex(css_language *c,
                        goto css__parse_flex_cleanup;
 
                grow = shrink = basis = false;
+               parserutils_vector_iterate(vector, ctx);
        }
 
        /* Attempt to parse the various longhand properties */
diff --git a/test/data/select/tests1.dat b/test/data/select/tests1.dat
index 2d30083..a8b527d 100644
--- a/test/data/select/tests1.dat
+++ b/test/data/select/tests1.dat
@@ -6940,6 +6940,116 @@ word-spacing: normal
 writing-mode: horizontal-tb
 z-index: auto
 #reset
+#
+#tree
+| div*
+#ua
+div { flex: 2 3 10px; }
+#user
+#errors
+#expected:
+align-content: stretch
+align-items: stretch
+align-self: auto
+background-attachment: scroll
+background-color: #00000000
+background-image: none
+background-position: 0% 0%
+background-repeat: repeat
+border-collapse: separate
+border-spacing: 0px 0px
+border-top-color: #ff000000
+border-right-color: #ff000000
+border-bottom-color: #ff000000
+border-left-color: #ff000000
+border-top-style: none
+border-right-style: none
+border-bottom-style: none
+border-left-style: none
+border-top-width: 2px
+border-right-width: 2px
+border-bottom-width: 2px
+border-left-width: 2px
+bottom: auto
+box-sizing: content-box
+break-after: auto
+break-before: auto
+break-inside: auto
+caption-side: top
+clear: none
+clip: auto
+color: #ff000000
+column-count: auto
+column-fill: balance
+column-gap: normal
+column-rule-color: #ff000000
+column-rule-style: none
+column-rule-width: 2px
+column-span: none
+column-width: auto
+content: normal
+counter-increment: none
+counter-reset: none
+cursor: auto
+direction: ltr
+display: inline
+empty-cells: show
+flex-basis: 10px
+flex-direction: row
+flex-grow: 2.000
+flex-shrink: 3.000
+flex-wrap: nowrap
+float: none
+font-family: sans-serif
+font-size: 12pt
+font-style: normal
+font-variant: normal
+font-weight: normal
+height: auto
+justify-content: flex-start
+left: auto
+letter-spacing: normal
+line-height: normal
+list-style-image: none
+list-style-position: outside
+list-style-type: disc
+margin-top: 0px
+margin-right: 0px
+margin-bottom: 0px
+margin-left: 0px
+max-height: none
+max-width: none
+min-height: 0px
+min-width: 0px
+opacity: 1.000
+order: 0
+outline-color: invert
+outline-style: none
+outline-width: 2px
+overflow-x: visible
+overflow-y: visible
+padding-top: 0px
+padding-right: 0px
+padding-bottom: 0px
+padding-left: 0px
+position: static
+quotes: none
+right: auto
+table-layout: auto
+text-align: default
+text-decoration: none
+text-indent: 0px
+text-transform: none
+top: auto
+unicode-bidi: normal
+vertical-align: baseline
+visibility: visible
+white-space: normal
+width: auto
+word-spacing: normal
+writing-mode: horizontal-tb
+z-index: auto
+#reset
 
 #tree
 | div*
@@ -7214,7 +7324,7 @@ cursor: auto
 direction: ltr
 display: inline
 empty-cells: show
-flex-basis: 0px
+flex-basis: auto
 flex-direction: row
 flex-grow: 0.000
 flex-shrink: 1.000
@@ -7495,9 +7605,7 @@ z-index: auto
 #tree
 | div*
 #ua
-div {  }
-#user
-div {  }
+div { flex: 2 3em; }
 #errors
 #expected:
 align-content: stretch
@@ -7546,9 +7654,9 @@ cursor: auto
 direction: ltr
 display: inline
 empty-cells: show
-flex-basis: auto
+flex-basis: 3em
 flex-direction: row
-flex-grow: 0.000
+flex-grow: 2.000
 flex-shrink: 1.000
 flex-wrap: nowrap
 float: none


-----------------------------------------------------------------------

Summary of changes:
 src/parse/properties/flex.c |    6 ++-
 test/data/select/tests1.dat |  120 ++++++++++++++++++++++++++++++++++++++++---
 2 files changed, 118 insertions(+), 8 deletions(-)

diff --git a/src/parse/properties/flex.c b/src/parse/properties/flex.c
index b2fd67e..dfec5bf 100644
--- a/src/parse/properties/flex.c
+++ b/src/parse/properties/flex.c
@@ -88,7 +88,7 @@ css_error css__parse_flex(css_language *c,
                return error;
        }
 
-       /* Handle none = flex: 0 0 auto; */
+       /* Handle none, equivalent of flex: 0 0 auto; */
        if ((token->type == CSS_TOKEN_IDENT) &&
                (lwc_string_caseless_isequal(
                        token->idata, c->strings[NONE],
@@ -117,9 +117,10 @@ css_error css__parse_flex(css_language *c,
                        goto css__parse_flex_cleanup;
 
                grow = shrink = basis = false;
+               parserutils_vector_iterate(vector, ctx);
        }
 
-       /* Handle auto = flex: 1 1 auto; */
+       /* Handle auto, equivalent of flex: 1 1 auto; */
        else if ((token->type == CSS_TOKEN_IDENT) &&
                (lwc_string_caseless_isequal(
                        token->idata, c->strings[AUTO],
@@ -148,6 +149,7 @@ css_error css__parse_flex(css_language *c,
                        goto css__parse_flex_cleanup;
 
                grow = shrink = basis = false;
+               parserutils_vector_iterate(vector, ctx);
        }
 
        /* Attempt to parse the various longhand properties */
diff --git a/test/data/select/tests1.dat b/test/data/select/tests1.dat
index 2d30083..a8b527d 100644
--- a/test/data/select/tests1.dat
+++ b/test/data/select/tests1.dat
@@ -6940,6 +6940,116 @@ word-spacing: normal
 writing-mode: horizontal-tb
 z-index: auto
 #reset
+#
+#tree
+| div*
+#ua
+div { flex: 2 3 10px; }
+#user
+#errors
+#expected:
+align-content: stretch
+align-items: stretch
+align-self: auto
+background-attachment: scroll
+background-color: #00000000
+background-image: none
+background-position: 0% 0%
+background-repeat: repeat
+border-collapse: separate
+border-spacing: 0px 0px
+border-top-color: #ff000000
+border-right-color: #ff000000
+border-bottom-color: #ff000000
+border-left-color: #ff000000
+border-top-style: none
+border-right-style: none
+border-bottom-style: none
+border-left-style: none
+border-top-width: 2px
+border-right-width: 2px
+border-bottom-width: 2px
+border-left-width: 2px
+bottom: auto
+box-sizing: content-box
+break-after: auto
+break-before: auto
+break-inside: auto
+caption-side: top
+clear: none
+clip: auto
+color: #ff000000
+column-count: auto
+column-fill: balance
+column-gap: normal
+column-rule-color: #ff000000
+column-rule-style: none
+column-rule-width: 2px
+column-span: none
+column-width: auto
+content: normal
+counter-increment: none
+counter-reset: none
+cursor: auto
+direction: ltr
+display: inline
+empty-cells: show
+flex-basis: 10px
+flex-direction: row
+flex-grow: 2.000
+flex-shrink: 3.000
+flex-wrap: nowrap
+float: none
+font-family: sans-serif
+font-size: 12pt
+font-style: normal
+font-variant: normal
+font-weight: normal
+height: auto
+justify-content: flex-start
+left: auto
+letter-spacing: normal
+line-height: normal
+list-style-image: none
+list-style-position: outside
+list-style-type: disc
+margin-top: 0px
+margin-right: 0px
+margin-bottom: 0px
+margin-left: 0px
+max-height: none
+max-width: none
+min-height: 0px
+min-width: 0px
+opacity: 1.000
+order: 0
+outline-color: invert
+outline-style: none
+outline-width: 2px
+overflow-x: visible
+overflow-y: visible
+padding-top: 0px
+padding-right: 0px
+padding-bottom: 0px
+padding-left: 0px
+position: static
+quotes: none
+right: auto
+table-layout: auto
+text-align: default
+text-decoration: none
+text-indent: 0px
+text-transform: none
+top: auto
+unicode-bidi: normal
+vertical-align: baseline
+visibility: visible
+white-space: normal
+width: auto
+word-spacing: normal
+writing-mode: horizontal-tb
+z-index: auto
+#reset
 
 #tree
 | div*
@@ -7214,7 +7324,7 @@ cursor: auto
 direction: ltr
 display: inline
 empty-cells: show
-flex-basis: 0px
+flex-basis: auto
 flex-direction: row
 flex-grow: 0.000
 flex-shrink: 1.000
@@ -7495,9 +7605,7 @@ z-index: auto
 #tree
 | div*
 #ua
-div {  }
-#user
-div {  }
+div { flex: 2 3em; }
 #errors
 #expected:
 align-content: stretch
@@ -7546,9 +7654,9 @@ cursor: auto
 direction: ltr
 display: inline
 empty-cells: show
-flex-basis: auto
+flex-basis: 3em
 flex-direction: row
-flex-grow: 0.000
+flex-grow: 2.000
 flex-shrink: 1.000
 flex-wrap: nowrap
 float: none


-- 
Cascading Style Sheets library

_______________________________________________
netsurf-commits mailing list
[email protected]
http://listmaster.pepperfish.net/cgi-bin/mailman/listinfo/netsurf-commits-netsurf-browser.org

Reply via email to