Project

General

Profile

Actions

Feature #28603

closed

css-styled-content: suggestion to avoid spaghetti code "style" while taking another header-alignment than "standard"

Added by Kurt Kunig almost 13 years ago. Updated over 6 years ago.

Status:
Closed
Priority:
Could have
Category:
Content Rendering
Target version:
Start date:
2011-07-31
Due date:
% Done:

0%

Estimated time:
PHP Version:
Tags:
Complexity:
medium
Sprint Focus:

Description

Hi all,
to avoid the style="text-align:align-center;" (= Spaghetti code) in the header-rendering:

e.g. lib.stdheader.10.1.dataWrap = <h1{register:headerStyle}{register:headerClass}>|</h1> I modified this part of code like this:

lib.stdheader {
// style= eliminate Spaghetti-Code!
// 1 = new register for csc-firstHeader
1 = LOAD_REGISTER
1.cscFirst = csc-firstHeader
1.cscFirst.if.value=1
1.cscFirst.if.equals.data = cObj:parentRecordNumber
1.cscFirst.wrap = |

// read the position of the data-record-title (header):
2 >
2 = LOAD_REGISTER
2.headerStyle.field = header_position
2.headerStyle.required = 1
2.headerStyle.noTrimWrap = |align-||

  1. Create class="csc-firstHeader align-right/-center/-left" attribute for <Hx> tags
    3 >
    3 = LOAD_REGISTER
    3.headerClass.stdWrap.dataWrap = {register:cscFirst} {register:headerStyle}
    3.headerClass.required = 1
    3.headerClass.noTrimWrap = | class="|"|

// elimination of {register:headerStyle}:
10.1.dataWrap = <h1{register:headerClass}>|</h1>
10.2.dataWrap = <h2{register:headerClass}>|</h2>
10.3.dataWrap = <h3{register:headerClass}>|</h3>
10.4.dataWrap = <h4{register:headerClass}>|</h4>
10.5.dataWrap = <h5{register:headerClass}>|</h5>
}

In addition you have to put standard classes into the CSS like:
.align-left
.align-right
.align-center

Perhaps you'll put it into the new code for one of the next TYPO3 versions!?

Kind regards from Jülich
Kurt Kunig
kupix webdesign

Actions #1

Updated by Steffen Gebert almost 13 years ago

  • Target version deleted (4.5.5)

Thanks for the report, Kurt.

Could you provide a patch for that?

Actions #2

Updated by Kurt Kunig almost 13 years ago

  • Assignee set to Steffen Gebert

Hi Steffen,
to be honest, I don't know how to set up a patch!? :'-(

Actions #3

Updated by Steffen Gebert almost 13 years ago

  • Assignee deleted (Steffen Gebert)
Actions #4

Updated by Patrick Broens almost 13 years ago

  • Assignee set to Patrick Broens
  • TYPO3 Version changed from 4.5 to 4.7
  • Complexity set to medium

This has already been solved for the BLE project, issue #28467, and is targeted for version 4.7

Actions #5

Updated by Thorsten Kahler almost 13 years ago

  • Status changed from New to Accepted
  • Target version set to 4.7.0
  • TYPO3 Version changed from 4.7 to 4.6
Actions #6

Updated by Steffen Ritter over 12 years ago

  • Status changed from Accepted to Resolved

resolved in Incubator branch

Actions #7

Updated by Riccardo De Contardi over 6 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF