[BUGFIX] Streamline EXT:fluid_styled_content typoscript
[Packages/TYPO3.CMS.git] / typo3 / sysext / fluid_styled_content / Configuration / TypoScript / Static / setup.txt
1 <INCLUDE_TYPOSCRIPT: source="FILE: EXT:fluid_styled_content/Configuration/TypoScript/Static/Setup/lib.parseFunc.ts">
2 <INCLUDE_TYPOSCRIPT: source="FILE: EXT:fluid_styled_content/Configuration/TypoScript/Static/Setup/lib.fluidContent.ts">
3 <INCLUDE_TYPOSCRIPT: source="FILE: EXT:fluid_styled_content/Configuration/TypoScript/Static/Setup/lib.stdheader.ts">
4 <INCLUDE_TYPOSCRIPT: source="FILE: EXT:fluid_styled_content/Configuration/TypoScript/Static/Setup/styles.content.get.ts">
5
6 tt_content = CASE
7 tt_content {
8         key {
9                 field = CType
10         }
11         stdWrap {
12                 # Setup the edit panel for all content elements
13                 editPanel = 1
14                 editPanel {
15                         allow = move, new, edit, hide, delete
16                         label = %s
17                         onlyCurrentPid = 1
18                         previewBorder = 1
19                         edit.displayRecord = 1
20                 }
21         }
22         bullets =< lib.fluidContent
23         bullets {
24                 templateName = Bullets
25                 dataProcessing {
26                         10 = TYPO3\CMS\Frontend\DataProcessing\SplitProcessor
27                         10 {
28                                 if {
29                                         value = 2
30                                         isLessThan.field = bullets_type
31                                 }
32                                 fieldName = bodytext
33                                 removeEmptyEntries = 1
34                                 as = bullets
35                         }
36                         20 = TYPO3\CMS\Frontend\DataProcessing\CommaSeparatedValueProcessor
37                         20 {
38                                 fieldName = bodytext
39                                 if {
40                                         value = 2
41                                         equals.field = bullets_type
42                                 }
43                                 fieldDelimiter = |
44                                 as = bullets
45                         }
46                 }
47                 stdWrap {
48                         # Setup the edit icon for content element "bullets"
49                         editIcons = tt_content: header [header_layout], bodytext [bullets_type]
50                         editIcons {
51                                 beforeLastTag = 1
52                                 iconTitle.data = LLL:EXT:fluid_styled_content/Resources/Private/Language/FrontendEditing.xlf:editIcon.bullets
53                         }
54                 }
55         }
56         div =< lib.fluidContent
57         div {
58                 templateName = Div
59         }
60         header =< lib.fluidContent
61         header {
62                 templateName = Header
63                 stdWrap {
64                         # Setup the edit icon for content element "header"
65                         editIcons = tt_content: header [header_layout|header_link], subheader, date
66                         editIcons {
67                                 beforeLastTag = 1
68                                 iconTitle.data = LLL:EXT:fluid_styled_content/Resources/Private/Language/FrontendEditing.xlf:editIcon.header
69                         }
70                 }
71         }
72         html =< lib.fluidContent
73         html {
74                 templateName = Html
75                 stdWrap {
76                         # Setup the edit icon for content element "html"
77                         editIcons = tt_content: bodytext
78                         editIcons {
79                                 beforeLastTag = 1
80                                 iconTitle.data = LLL:EXT:fluid_styled_content/Resources/Private/Language/FrontendEditing.xlf:editIcon.html
81                         }
82                 }
83         }
84         list =< lib.fluidContent
85         list {
86                 templateName = List
87                 stdWrap {
88                         # Setup the edit icon for content element "list"
89                         editIcons = tt_content: header [header_layout], list_type, layout, select_key, pages [recursive]
90                         editIcons {
91                                 iconTitle.data = LLL:EXT:fluid_styled_content/Resources/Private/Language/FrontendEditing.xlf:editIcon.list
92                         }
93                 }
94         }
95         menu =< lib.fluidContent
96         menu {
97                 templateName = Menu
98                 dataProcessing {
99                         10 = TYPO3\CMS\Frontend\DataProcessing\SplitProcessor
100                         10 {
101                                 if.isTrue.field = pages
102                                 fieldName = pages
103                                 delimiter = ,
104                                 removeEmptyEntries = 1
105                                 filterIntegers = 1
106                                 filterUnique = 1
107                                 as = pageUids
108                         }
109                         20 < .10
110                         20 {
111                                 if.isTrue.field = selected_categories
112                                 fieldName = selected_categories
113                                 as = categoryUids
114                         }
115                 }
116                 stdWrap {
117                         # Setup the edit icon for content element "menu"
118                         editIcons = tt_content: header [header_layout], menu_type, pages
119                         editIcons {
120                                 iconTitle.data = LLL:EXT:fluid_styled_content/Resources/Private/Language/FrontendEditing.xlf:editIcon.menu
121                         }
122                 }
123         }
124         shortcut =< lib.fluidContent
125         shortcut {
126                 templateName = Shortcut
127
128                 # Keep this, since the "conf" option can be used
129                 variables.shortcuts = RECORDS
130                 variables.shortcuts {
131                         source.field = records
132                         tables = {$styles.content.shortcut.tables}
133                 }
134
135                 stdWrap {
136                         # Setup the edit icon for content element "shortcut"
137                         editIcons = tt_content: header [header_layout], records
138                         editIcons {
139                                 iconTitle.data = LLL:EXT:fluid_styled_content/Resources/Private/Language/FrontendEditing.xlf:editIcon.shortcut
140                         }
141                 }
142         }
143         table =< lib.fluidContent
144         table {
145                 templateName = Table
146                 dataProcessing {
147                         10 = TYPO3\CMS\Frontend\DataProcessing\CommaSeparatedValueProcessor
148                         10 {
149                                 fieldName = bodytext
150                                 fieldDelimiter.char.cObject = TEXT
151                                 fieldDelimiter.char.cObject {
152                                         field = table_delimiter
153                                 }
154                                 fieldEnclosure.char.cObject = TEXT
155                                 fieldEnclosure.char.cObject {
156                                         field = table_enclosure
157                                 }
158                                 maximumColumns.field = cols
159                                 as = table
160                         }
161                 }
162                 stdWrap {
163                         # Setup the edit icon for content element "table"
164                         editIcons = tt_content: header [header_layout], bodytext, [table_caption|cols|table_header_position|table_tfoot]
165                         editIcons {
166                                 beforeLastTag = 1
167                                 iconTitle.data = LLL:EXT:fluid_styled_content/Resources/Private/Language/FrontendEditing.xlf:editIcon.table
168                         }
169                 }
170         }
171         textmedia =< lib.fluidContent
172         textmedia {
173                 templateName = Textmedia
174                 dataProcessing {
175                         10 = TYPO3\CMS\Frontend\DataProcessing\FilesProcessor
176                         10 {
177                                 references.fieldName = media
178                         }
179                         20 = TYPO3\CMS\Frontend\DataProcessing\GalleryProcessor
180                         20 {
181                                 maxGalleryWidth = {$styles.content.textmedia.maxW}
182                                 maxGalleryWidthInText = {$styles.content.textmedia.maxWInText}
183                                 columnSpacing = {$styles.content.textmedia.columnSpacing}
184                                 borderWidth = {$styles.content.textmedia.borderWidth}
185                                 borderPadding = {$styles.content.textmedia.borderPadding}
186                         }
187                 }
188                 stdWrap {
189                         # Setup the edit icon for content element "textmedia"
190                         editIcons = tt_content: header [header_layout], bodytext, media [imageorient|imagewidth|imageheight], [imagecols|imageborder], image_zoom
191                         editIcons {
192                                 iconTitle.data = LLL:EXT:fluid_styled_content/Resources/Private/Language/FrontendEditing.xlf:editIcon.textmedia
193                         }
194                 }
195         }
196         uploads =< lib.fluidContent
197         uploads {
198                 templateName = Uploads
199                 dataProcessing {
200                         10 = TYPO3\CMS\Frontend\DataProcessing\FilesProcessor
201                         10 {
202                                 references.fieldName = media
203                                 collections.field = file_collections
204                                 sorting.field = filelink_sorting
205                         }
206                 }
207                 stdWrap {
208                         # Setup the edit icon for content element "uploads"
209                         editIcons = tt_content: header [header_layout], media, file_collections, filelink_sorting, [filelink_size|uploads_description|uploads_type]
210                         editIcons {
211                                 iconTitle.data = LLL:EXT:fluid_styled_content/Resources/Private/Language/FrontendEditing.xlf:editIcon.uploads
212                         }
213                 }
214         }
215
216         # The "default" content element, which will be called when no rendering definition can be found
217         default =< lib.fluidContent
218 }