{"action":"closed","issue":{"url":"https://api.github.com/repos/pagespeed/ngx_pagespeed/issues/1222","repository_url":"https://api.github.com/repos/pagespeed/ngx_pagespeed","labels_url":"https://api.github.com/repos/pagespeed/ngx_pagespeed/issues/1222/labels{/name}","comments_url":"https://api.github.com/repos/pagespeed/ngx_pagespeed/issues/1222/comments","events_url":"https://api.github.com/repos/pagespeed/ngx_pagespeed/issues/1222/events","html_url":"https://github.com/pagespeed/ngx_pagespeed/issues/1222","id":164886721,"number":1222,"title":"Pagespeed eats CSS font-face declarations when defined in imported files","user":{"login":"rbu","id":65913,"avatar_url":"https://avatars.githubusercontent.com/u/65913?v=3","gravatar_id":"","url":"https://api.github.com/users/rbu","html_url":"https://github.com/rbu","followers_url":"https://api.github.com/users/rbu/followers","following_url":"https://api.github.com/users/rbu/following{/other_user}","gists_url":"https://api.github.com/users/rbu/gists{/gist_id}","starred_url":"https://api.github.com/users/rbu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rbu/subscriptions","organizations_url":"https://api.github.com/users/rbu/orgs","repos_url":"https://api.github.com/users/rbu/repos","events_url":"https://api.github.com/users/rbu/events{/privacy}","received_events_url":"https://api.github.com/users/rbu/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":{"login":"morlovich","id":3765572,"avatar_url":"https://avatars.githubusercontent.com/u/3765572?v=3","gravatar_id":"","url":"https://api.github.com/users/morlovich","html_url":"https://github.com/morlovich","followers_url":"https://api.github.com/users/morlovich/followers","following_url":"https://api.github.com/users/morlovich/following{/other_user}","gists_url":"https://api.github.com/users/morlovich/gists{/gist_id}","starred_url":"https://api.github.com/users/morlovich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/morlovich/subscriptions","organizations_url":"https://api.github.com/users/morlovich/orgs","repos_url":"https://api.github.com/users/morlovich/repos","events_url":"https://api.github.com/users/morlovich/events{/privacy}","received_events_url":"https://api.github.com/users/morlovich/received_events","type":"User","site_admin":false},"assignees":[{"login":"morlovich","id":3765572,"avatar_url":"https://avatars.githubusercontent.com/u/3765572?v=3","gravatar_id":"","url":"https://api.github.com/users/morlovich","html_url":"https://github.com/morlovich","followers_url":"https://api.github.com/users/morlovich/followers","following_url":"https://api.github.com/users/morlovich/following{/other_user}","gists_url":"https://api.github.com/users/morlovich/gists{/gist_id}","starred_url":"https://api.github.com/users/morlovich/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/morlovich/subscriptions","organizations_url":"https://api.github.com/users/morlovich/orgs","repos_url":"https://api.github.com/users/morlovich/repos","events_url":"https://api.github.com/users/morlovich/events{/privacy}","received_events_url":"https://api.github.com/users/morlovich/received_events","type":"User","site_admin":false}],"milestone":null,"comments":2,"created_at":"2016-07-11T17:06:08Z","updated_at":"2016-07-12T20:07:36Z","closed_at":"2016-07-12T20:07:36Z","body":"Given the following configuration:\r\n```\r\n    pagespeed RewriteLevel CoreFilters;\r\n    pagespeed EnableFilters combine_css,combine_javascript;\r\n    pagespeed EnableFilters rewrite_javascript,rewrite_css,fallback_rewrite_css_urls;\r\n    pagespeed EnableFilters move_css_above_scripts,move_css_to_head,collapse_whitespace;\r\n```\r\n\r\nAnd the following files:\r\ntest.html:\r\n```html\r\n<html>\r\n    <head>\r\n        <meta charset=\"utf-8\" />\r\n        <link rel=\"stylesheet\" href=\"main.css\">\r\n    </head>\r\n    <body>\r\n        content\r\n    </body>\r\n</html>\r\n```\r\n\r\nmain.css:\r\n```css\r\n@import url('sub.css');\r\n.after-import {\r\n    font-family: \"myfont\";\r\n    display: none;\r\n}\r\n```\r\n\r\nsub.css:\r\n```css\r\n.before-font {\r\n    display: none;\r\n}\r\n@font-face {\r\n\tfont-family: 'myfont';\r\n}\r\n.after-font {\r\n    display: none;\r\n}\r\n```\r\n\r\nnginx pagespeed yields:\r\n\r\n```html\r\n<html>\r\n<head>\r\n<meta charset=\"utf-8\"/>\r\n<style>.before-font{display:none}.after-font{display:none}.after-import{font-family:\"myfont\";display:none}</style>\r\n</head>\r\n<body>\r\ncontent\r\n</body>\r\n</html>\r\n```\r\n\r\nNote that this is missing the @font-face declaration. This example is minified. The @font-face actually contains source identifiers and the like. The main css file is longer (so it is not inlined), however the same issue happens. The URLs are retrievable, it works on the first load after a cache flush (before minification) and when pagespeed is disabled via the URL."}}
{"actor":{"display_login":"morlovich"}}