adopted-ember-addons / ember-cli-sass

Use node-sass to preprocess your ember-cli app's files, with support for sourceMaps and include paths
MIT License
274 stars 91 forks source link

Problem parsing Base64 embedded fonts #41

Closed kylecoberly closed 9 years ago

kylecoberly commented 9 years ago

In the last CLI update, the sass compiler started tripping over embedded fonts:

@font-face
{
    font-family: OpenSansBold;
    font-weight: normal;
    font-style: normal;
    src: url(data:font/ttf;base64,AAEAAAATAQAABAAwRFNJR5IYdDoAA1fcAAAVdEdERUYAJgOvAANTvAAAAB5HUE9TCzcPNwADU9wAAAA4R1NVQg4rPbcAA1QUAAADxk9TLzKidaEYAAABuAAAAGBjbWFwKasvaAAAELQAAAQaY3Z0IBMtGpQAAB2oAAAAqmZwZ227c6R1AAAU0AAAB+BnYXNwAAgAGwADU7AAAAAMZ2x5Zh1/yvQAACWsAAFLxGhlYWT34ccOAAABPAAAADZoaGVhDikKUgAAAXQAAAAkaG10eCTSBgAAAAIYAAAOmmtlcm5UKwl+AAFxcAABtjZsb2NhsttgKwAAHlQAAAdWbWF4cAU1Ah8AAAGYAAAAIG5hbWW8ZnsiAAMnqAAABdxwb3N0AkPvbAADLYQAACYrcHJlcMgJ/GsAABywAAAA+AABAAAAARmaOqk5s18PPPUACQgAAAAAAMlCF6AAAAAAyehKofsM/agKjQiNAAEACQACAAAAAAAAAAEAAAiN/agAAAqN+wz+eQqNAAEAAAAAAAAAAAAAAAAAAAOjAAEAAAOqAIoAFgBYAAUAAgAQAC8AXAAAAQABCwADAAEAAwUPArwABQAIBZoFMwAAAR8FmgUzAAAD0QBmAfwIAgILCAYDBQQCAgTgAALvQAAgWwAAACgAAAAAMUFTQwAgACD//QYf/hQAhAiNAlggAAGfAAAAAAReBbYAAAAgAAMEzQDBAAAAAAQUAAACFAAAAkoAdQPHAIUFKwAtBJEAWAc1AD8GAABSAiEAhQK2AFICtgA9BFwAPwSRAFgCUgA/ApMAPQJIAHUDTgAOBJEASgSRAHkEkQBOBJEATgSRACMEkQBkBJEASASRADcEkQBIBJE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gBQ4AKQRxAB8HAgBtBrIAjwZeAHcE9ABcBbwAAATXAAAFvAAABNcAAAqNAHcJKQBcBrAAdwVvAFwItAB3Bx8AXAi0AHcHFAAGBWoAdwQxAFwE3wBoBHUAtASeAPQEngHNBJ4BywfpACkHpgApB1QAuAZqAKAE7gAvBOkABAUGALgFEACgBHkALwPuAAQF3wC4BNEAoAg7AAAHiQAABS8AXgRxAE4GDAC4BVIAoAVQALgEywCgBSUABAT2AAQF3QAABY8AAAa6ALgF8gCgBqwAuAYQAKAJAAC4Bx0AoAY3AHcFPwBcBRkAdwQdAFwEogApBGYALwT+AAAEmAAABP4AAASYAAAF8gAABR8ACgdxACkGVAAvBm8AbQXPAHsF0wBtBT8AewXTALgFVACgB5YAAAW4AAAHlgAABbgAAAMdAEIHiwAABvwAAAYUALgFSgCgBrQAEAXRAAAGHwC4BUwAoAbdALgF9ACgBdMAbQU/AHsISgC4B2gAoAMdAEIFhQAABNUAVgWFAAAE1QBWB54AAAdWAFYEewB2BLoAXAaJAKQEzwBcBokApATPAFwHiwAABvwAAAUvAF4EcQBOBLoAOQSmADkGlgC4BcMAoAaWALgFwwCgBl4AdwT0AFwGXgB3BPQAXAZeAHcE9ABcBU4ASAQZAEoFOQAABI0AAAU5AAAEjQAABTkAAASNAAAF0wBtBT8AewR9ALgD0wCgBz8AuAbNAKAEeQAvA+4ABAXbAAAFKQAKBVYAAASgAAoFGwBcBRAAXAdoAFwHYgBcB04AGQb2ADkFnAAZBUoATghEABAHewAACFgAuAeeAKAGZgB3BU4AXAYQACkF3wAvBS8AWARzAE4GiwAQBcsAAA
}

If I comment out the URL, it works. Otherwise it throws "expected a variable name (e.g. $x) or ')' for the parameter list for url"

stefanpenner commented 9 years ago

dupe: https://github.com/aexmachina/ember-cli-sass/issues/40

work around: quote the contents of url

kylecoberly commented 9 years ago

That's it!