Remove all inline css usage of certified apps

RESOLVED WONTFIX

Status

P2
normal
RESOLVED WONTFIX
5 years ago
2 years ago

People

(Reporter: ochameau, Assigned: gerard-majax)

Tracking

(Depends on: 1 bug)

unspecified
Dependency tree / graph

Firefox Tracking Flags

(tracking-b2g:backlog)

Details

(Whiteboard: [systemsfe])

Attachments

(1 attachment)

(Reporter)

Description

5 years ago
Due to bug 968906, Firefox mulet is more strict than b2g.
We should either make it as strict as b2g or remove all inlined css from all certified apps.

For example devtools layers are currently broken due to usage of inlined css:
https://github.com/mozilla-b2g/gaia/blob/master/apps/system/js/devtools_layers.js#L65-L66
(Reporter)

Comment 1

5 years ago
Created attachment 8371618 [details] [diff] [review]
disable certified csp

In the meantime...
(Assignee)

Updated

5 years ago
Assignee: nobody → lissyx+mozillians
Target Milestone: --- → 2.0 S1 (9may)
Blocks: 968906
No longer depends on: 968906
Whiteboard: [systemsfe]
(Assignee)

Comment 2

5 years ago
$ file $(git grep 'style=' | cut -d':' -f1 | sort | uniq) | egrep -v 'SVG Scalable|test/unit|\.properties'
apps/communications/contacts/elements/form.html:                              HTML document, ASCII text
apps/email/index.html:                                                        HTML document, ASCII text
apps/fm/js/fm.js:                                                             ASCII text
apps/homescreen/everything.me/modules/BackgroundImage/BackgroundImage.js:     ASCII text
apps/keyboard/js/imes/jskanji/docs/jskanji.html:                              HTML document, UTF-8 Unicode text, with very long lines
apps/pdfjs/content/web/viewer.html:                                           HTML document, ASCII text
apps/settings/elements/app_permissions.html:                                  HTML document, ASCII text
apps/sms/index.html:                                                          HTML document, ASCII text
apps/system/js/devtools_view.js:                                              ASCII text
dev_apps/cubevid/glUtils.js:                                                  ASCII text
dev_apps/image-uploader/style/bb/index.html:                                  HTML document, UTF-8 Unicode text, with very long lines
dev_apps/image-uploader/style/bb/menus-dialogs/valueselector/time/index.html: HTML document, ASCII text
dev_apps/image-uploader/style/bb/other/lists/index.html:                      HTML document, ASCII text
dev_apps/image-uploader/style/bb/other/seekbars/index.html:                   HTML document, ASCII text
dev_apps/test-agent/common/vendor/blanket/blanket.js:                         ASCII text, with very long lines
dev_apps/test-iac-publisher/index.html:                                       HTML document, ASCII text
dev_apps/test-ime/ime_test.html:                                              HTML document, ASCII text
dev_apps/test-wappush/index.html:                                             HTML document, ASCII text
dev_apps/uitest/tests_html/UI/canvas.html:                                    HTML document, ASCII text
shared/style/date_selector/index.html:                                        HTML document, ASCII text
shared/style/progress_activity/index.html:                                    HTML document, ASCII text, with very long lines
shared/style/time_selector/index.html:                                        HTML document, ASCII text
tools/extensions/httpd/content/httpd.js:                                      ASCII text
(Assignee)

Comment 3

5 years ago
At least we have the following apps impacted:

> $ grep certified apps/communications/manifest.webapp 
>   "type": "certified",
> $ grep certified apps/email/manifest.webapp 
>   "type": "certified",
> $ grep certified apps/fm/manifest.webapp 
>   "type": "certified",
> $ grep certified apps/homescreen/manifest.webapp 
>   "type": "certified",
> $ grep certified apps/pdfjs/manifest.webapp 
>   "type": "certified",
> $ grep certified apps/settings/manifest.webapp 
>   "type": "certified",
> $ grep certified apps/sms/manifest.webapp 
>   "type": "certified",
> $ grep certified apps/system/manifest.webapp 
>   "type": "certified",
(Assignee)

Updated

5 years ago
Depends on: 1012650
(Assignee)

Updated

5 years ago
Depends on: 1012651
(Assignee)

Updated

5 years ago
Depends on: 1012652
(Assignee)

Updated

5 years ago
Depends on: 1012653
(Assignee)

Updated

5 years ago
Depends on: 1012654
(Assignee)

Updated

5 years ago
Depends on: 817674
(Assignee)

Updated

5 years ago
Depends on: 1012656
(Assignee)

Updated

5 years ago
Depends on: 1012659
(Assignee)

Updated

5 years ago
Depends on: 1012663
(Assignee)

Updated

5 years ago
Depends on: 1012665
Target Milestone: 2.0 S1 (9may) → 2.0 S2 (23may)
Target Milestone: 2.0 S2 (23may) → 2.0 S3 (6june)
Depends on: 1018969
Depends on: 1021724
Depends on: 1021730
No longer blocks: 858787
Depends on: 1006890
Target Milestone: 2.0 S3 (6june) → 2.0 S4 (20june)
Depends on: 1022996
Target Milestone: 2.0 S4 (20june) → 2.0 S5 (4july)
Target Milestone: 2.0 S5 (4july) → 2.0 S6 (18july)
Target Milestone: 2.0 S6 (18july) → 2.1 S1 (1aug)
Is there guidance for how this will work with HTML Imports, or scoped styles for custom elements?

Are <style>(styles in here)</style> still allowed?

There is a push to start using Custom Elements for Gaia, and one of the intermediate steps is constructing the element definition in JS, and appending a <style scoped> tag to the element's template, then putting the applied template into the DOM.

Maybe scoped <style> tags or styles scoped to an HTML Import will be allowed, and this is just about the "style" attribute on HTML tags?
Target Milestone: 2.1 S1 (1aug) → 2.1 S2 (15aug)
Target Milestone: 2.1 S2 (15aug) → 2.1 S3 (29aug)
Target Milestone: 2.1 S3 (29aug) → 2.1 S4 (12sep)
blocking-b2g: --- → backlog
Priority: -- → P2
Target Milestone: 2.1 S4 (12sep) → ---

Updated

4 years ago
Depends on: 1141123

Updated

4 years ago
Depends on: 1141977
blocking-b2g: backlog → ---
tracking-b2g: --- → backlog
(Assignee)

Updated

2 years ago
Status: NEW → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.