pdf.js/external
Jonas Jenwald d1f13a6af3 Use the regular preprocess-function for the CSS files as well
An old shortcoming of the `preprocessCSS`-function is its complete lack of support for our "normal" defines, which makes it very difficult to have build-specific CSS rules. Recently we've started using specially crafted comments to remove CSS rules from the MOZCENTRAL build, but (ab)using the `preprocessCSS`-function in this way really doesn't feel great.
However, it turns out to be surprisingly simple to instead use the "regular" `preprocess`-function for the CSS files as well. The only special-handling that's still necessary is the helper-function for dealing with CSS-imports, but apart from that everything seems to just work.

One reason, as far as I can tell, for having a separate `preprocessCSS`-function was likely that we originally used *lots* of vendor-prefixed CSS rules in our CSS files. With improvements over the years, especially thanks to Autoprefixer and PostCSS, we've been able to remove *almost* all non-standard CSS rules and the need for special-casing the CSS parsing has mostly vanished.

*Please note:* As part of testing this patch I've diffed the output of `gulp generic`, `gulp mozcentral`, and `gulp chromium` against the `master`-branch to check that there was no obvious breakage.
2022-05-07 22:45:52 +02:00
..
bcmaps Removes external/cmaps; adds binary cmaps to the repo 2014-03-17 13:30:27 -05:00
builder Use the regular preprocess-function for the CSS files as well 2022-05-07 22:45:52 +02:00
cmapscompress Fix inefficient regular expressions in external/cmapscompress/parse.js 2021-08-01 12:12:42 +02:00
dist [api-minor] Remove the, in legacy builds, bundled ReadableStream polyfill 2022-02-13 10:15:58 +01:00
importL10n Enable the ESLint no-var rule in the external/ folder 2021-03-14 11:43:25 +01:00
quickjs Update quickjs to revision 2788d71e823b522b178db3b3660ce93689534e6d 2022-05-01 15:53:50 +02:00
standard_fonts Bundle the license-file for the Liberation fonts in the builds (PR 13517 follow-up) 2021-06-10 00:11:47 +02:00
systemjs Cache babel source map. 2021-04-09 10:34:54 -07:00
webL10n Stop dispatching a "localized" event from the webL10n library, since it's unused and may clash with the default viewer 2019-09-13 12:38:36 +02:00
webpack Enable the ESLint no-var rule in the external/ folder 2021-03-14 11:43:25 +01:00
.eslintrc Enable the ESLint no-var rule in the external/ folder 2021-03-14 11:43:25 +01:00
.gitignore Removes external/cmaps; adds binary cmaps to the repo 2014-03-17 13:30:27 -05:00