Closed Bug 658431 Opened 14 years ago Closed 14 years ago

Move generic page styling into separate stylesheet for reuse in other in-content UIs

Categories

(Toolkit :: Themes, defect)

defect
Not set
normal

Tracking

()

VERIFIED FIXED
mozilla7

People

(Reporter: Unfocused, Assigned: Unfocused)

References

()

Details

(Whiteboard: [qa!])

Attachments

(1 file, 1 obsolete file)

Existing and new in-content UI wants to use the styling that the addons manager has. To help facilitate that, the generic styling in the addons manager needs to be moved into a stylesheet that can be shared by all in-content UI pages.
Blocks: 658530
Assignee: nobody → bmcbride
Status: NEW → ASSIGNED
Component: Add-ons Manager → Themes
QA Contact: add-ons.manager → themes
Attached patch Patch v1 (obsolete) — Splinter Review
I used about:permissions as a guinea pig (see bug 658530), but I suspect we'll find other things that should be shared as more UI is moved to be in-content.
Attachment #536207 - Flags: review?(dao)
Attachment #536207 - Flags: review?(dtownsend)
Comment on attachment 536207 [details] [diff] [review] Patch v1 Review of attachment 536207 [details] [diff] [review]: ----------------------------------------------------------------- Couple of things I'd like to see here but this is basically there. Most of my comments to the gnomestripe css apply everywhere. Can we use in-content instead of incontent? I keep reading it wrong. ::: toolkit/mozapps/extensions/content/extensions.xml @@ +900,5 @@ > label="&cmd.showPreferencesUnix.label;" > tooltiptext="&cmd.showPreferencesUnix.tooltip;" > #endif > oncommand="document.getBindingParent(this).showPreferences();"/> > + <xul:button anonid="enable-btn" class="incontent-button enable" should just get rid of the extra space here, seems unnecessary ::: toolkit/themes/gnomestripe/global/incontent-ui.css @@ +1,1 @@ > +/* ***** BEGIN LICENSE BLOCK ***** I think the naming of this should match the naming of the dtd. @@ +38,5 @@ > +@namespace url("http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"); > + > + > +/* Page background */ > +page { I think you can use :root as a selector to match the document root, might be better than requiring a fixed element. @@ +107,5 @@ > +} > + > + > +/* Inner content */ > +.inner-content { This doesn't seem to be used anywhere, what's it for? @@ +122,5 @@ > +} > + > + > +/* Buttons */ > +.incontent-button[disabled="true"] { I don't think a general rule of hiding disabled buttons is right. It makes sense for the add-ons manager but probably not in a lot of other cases. Arguably we should be using hidden there too tbh.
Attachment #536207 - Flags: review?(dtownsend) → review-
Comment on attachment 536207 [details] [diff] [review] Patch v1 I see some about:addons centric stuff here that I'm not sure should be shared like this. For now I'd like to see the search, inconent-button and header-related classes go. We can let the stylesheet grow as we add more consumers. > <?xml-stylesheet href="chrome://global/skin/" type="text/css"?> > <?xml-stylesheet href="chrome://mozapps/content/extensions/extensions.css"?> >+<?xml-stylesheet href="chrome://global/skin/incontent-ui.css"?> > <?xml-stylesheet href="chrome://mozapps/skin/extensions/extensions.css"?> Can chrome://mozapps/skin/extensions/extensions.css @include chrome://global/skin/incontent-ui.css? >+page { Use :root here
Attachment #536207 - Flags: review?(dao) → review-
(In reply to comment #3) > Can chrome://mozapps/skin/extensions/extensions.css @include > chrome://global/skin/incontent-ui.css? Do you mean @import? Or %include via the preprocessor? I considered %include, but I want this to be usable by extensions that provide in-content UI. I hadn't considered @import - out of curiosity, what benefits would that have over using xml-stylesheet?
(In reply to comment #2) > Can we use in-content instead of incontent? I keep reading it wrong. Heh... > > +/* Inner content */ > > +.inner-content { > > This doesn't seem to be used anywhere, what's it for? Used in about:permissions (bug 658530) - I'll move it there, since it's a new addition.
I meant @import, sorry. The idea is that extensions.css can pull whatever styles it wants, extensions.xul doesn't need to know about them.
Attached patch Patch v2Splinter Review
Attachment #536207 - Attachment is obsolete: true
Attachment #537960 - Flags: review?(dtownsend)
Attachment #537960 - Flags: review?(dao)
Comment on attachment 537960 [details] [diff] [review] Patch v2 nit: I'd prefer in-content_UI...
Attachment #537960 - Flags: review?(dao) → review+
or just inContentUI
As a note, I still think that "in-content UI" is a misnomer, as it's chrome, including chrome privileges, and doesn't even run in content processes when we turn them on. "In-tab UI" would be so much clearer about what it is... ;-)
It's the content area. in-tab doesn't really make much sense... it's attached to and represented by a tab, not in it.
It's also not inside content, but shown instead of content. And we actually refer to what panorama manages as "tabs" and what Fennec has as "tabs", so we clearly refer to the content area as "tab" even if the correct definition might be different. Not sure if that discussion in the end belong into this bug, though ;-)
Comment on attachment 537960 [details] [diff] [review] Patch v2 These parts look ok, what happened to the button stylings though?
Attachment #537960 - Flags: review?(dtownsend) → review+
(In reply to comment #13) > These parts look ok, what happened to the button stylings though? Moved them into bug 658530, as per comment 3. Whats your take on the naming, Dave? in-contentUI, in-content_UI, or inContentUI? (This type of UI has always been referred to as "in-content", so I don't like changing it to "in-tab".)
I concur with inContentUI.css, we don't use underscores anywhere else in the theme files that I can see.
Whiteboard: [inbound]
Target Milestone: --- → mozilla7
Flags: in-testsuite-
Flags: in-litmus-
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Whiteboard: [inbound]
How can i verify this? Thanks
Go to the AOM and view source (ctrl+U).
Verified with Addons Manager and about:permissions on Firefox 8.0 Beta 6, Firefox 9.0 Aurora and Firefox 10.0 Central.
Status: RESOLVED → VERIFIED
Whiteboard: [qa!]
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: