Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The message pane (#messagepane) should be moved out of .txp-header #237

Closed
ghost opened this issue Oct 4, 2014 · 9 comments
Closed

The message pane (#messagepane) should be moved out of .txp-header #237

ghost opened this issue Oct 4, 2014 · 9 comments

Comments

@ghost
Copy link

ghost commented Oct 4, 2014

From ph.witte...@gmail.com on July 25, 2012 09:01:48

The #messagepane is in no way related to the semantics of 'header' (masthead) of the Textpattern CMS UI. Assuming we move, txp 4.6 ?, towards html5 markup, .txp-head would become a <header> instead of a <div> in the present markup. #messagepane would then be more out of place (according to the semantics of the <header> element).

messagepane should become either

[1] a direct child of body
[2] a first- or last-child of .txp-body

(I prefer option the second option; after all that element is directly related to actions performed on elements contained inside .txp-body)

Having #messagepane as a child of .txp-head does impose some (serious) limits on what can be done with the 'header'. For example in my Sandspaces theme (*) I position the 'header' as a side-column using position: absolute. If I were to use .txp-header for this, #messagepane would forever be trapped inside that block. At present I work around this by adding a div (#masthead in my case), child of .txp-header and position that. I'd like to get rid of that additional div.

I think the Hive theme would face similar constrains.

An additional benefit: a theme author doesn't need to add #messagepane inside his or her themename.php file…

(*) http://forum.textpattern.com/viewtopic.php?id=38139 ---
(this is certainly not urgent for Txp 4.5, more like something for Textpattern.next

Original issue: http://code.google.com/p/textpattern/issues/detail?id=233

@ghost ghost added imported labels Oct 4, 2014
@ghost
Copy link
Author

ghost commented Oct 4, 2014

From p...@designhive.com on July 25, 2012 03:26:20

This is being changed at v4.6, when we will indeed be going to HTML5 markup. The message pane will be in the role='main' section/div (whichever tag we settle on) after the initial h1.txp-heading tag. You can then position it wherever you like via CSS of course.

@ghost
Copy link
Author

ghost commented Oct 4, 2014

From ph.witte...@gmail.com on July 25, 2012 04:49:58

Assuming your [role="main"] block corresponds to the current .txp-body block, that sounds OK. One might argue that it could make more sense to have that element as last child of the [role="main"] block, but that's more on the nitpicking level.

@ghost
Copy link
Author

ghost commented Oct 4, 2014

From stefdawson on August 20, 2012 08:38:27

Labels: Milestone-4.6

@philwareham philwareham added this to the v4.6 milestone Oct 4, 2014
@philwareham philwareham self-assigned this Oct 7, 2014
@Bloke
Copy link
Member

Bloke commented Jul 8, 2015

@philwareham Is this done in either master or admin-layout-update? If so, can it be closed?

@phiw13
Copy link

phiw13 commented Jul 8, 2015

Nope, it is not yet done on either branch.
If I understand things correctly, it should go in either txplib_head.php or txplib_html.php (depending on where it is added to the main.txp-body element).

@philwareham
Copy link
Member

Will be done soon - it's a 4.6 blocker for me.

@philwareham
Copy link
Member

Done. Can be closed when we merge admin-layout-update branch into master.

@philwareham
Copy link
Member

@phiw13 Also: maybe the HTML of these can probably be improved, since the role and alert state (success, error, etc.) classes could go on the div in core itself rather than a child span in my Hive theme?

@phiw13
Copy link

phiw13 commented Nov 3, 2015

@philwareham
Oh sure. If it is not complicated to do, go for it. The less code a theme needs to maintain in the theme.php file, the better!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants