• Resolved netzgestaltung

    (@netzgestaltung)


    Hi there,

    i can somehow reproduce the others problems with css calc().

    My experience to share, maybe this helps debugging:

    .form-select-hint::before{
      left:calc(50%  +  1.5em);
    }
    .form-select-hint::after{
      right:calc(50% + 1.5em);
    }

    leads to
    .form-select-hint::before{left:calc(50%+1.5em)}.form-select-hint::after{right:calc(50% + 1.5em)}
    the first calc() gets wrong

    .form-select-hint::before { left:calc(50% + 1.5em) }
    .form-select-hint::after { right:calc(50% + 1.5em) }

    has the same result

    switching the rules position does the same switch.

    current workaround making a newline:

    .form-select-hint::before{left:calc(50%  +  1.5em)}
    /*!
     * this comment prevents the minify compressor to destroy the first calc()
     */
    .form-select-hint::after{right:calc(50% + 1.5em)}

    i counted 41 calc() method calls in my CSS and that was the only one which got corrupted. So maybe its because its the first occurance in the file or because two following selectors has it.

    used compressor: minify (default)

    btw:
    selecting CSS Tidy does not have this issue but generates a php message inside the minified CSS:

    <b>Deprecated</b>: The each() function is deprecated. This message will be suppressed on further calls in <b>/wp-content/plugins/w3-total-cache/lib/CSSTidy/class.csstidy.php</b> on line <b>1122</b>

    selecting YUI Compressor (PHP) leads to an empty minified CSS file.

    Br,
    tom

Viewing 1 replies (of 1 total)
  • Plugin Contributor Marko Vasiljevic

    (@vmarko)

    Hello @netzgestaltung

    I am sorry about the issue you are experiencing and I am happy to assist you with this.
    I’ve opened a GitHub issue on your behalf our Github repository.
    Please make sure to track the progress of the issue regularly.
    As for the CSS tidy deprecated issue, we also have an issue opened to update the external library.
    Thanks!

Viewing 1 replies (of 1 total)
  • The topic ‘minify css and calc function broken’ is closed to new replies.