| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576 |
- <f:comment><!-- Widget flux par Opentalent: Carousel --></f:comment>
- <f:comment><!-- Require: https://kenwheeler.github.io/slick/ --></f:comment>
- {namespace v=FluidTYPO3\Vhs\ViewHelpers}
- {namespace flux=FluidTYPO3\Flux\ViewHelpers}
- <div xmlns="http://www.w3.org/1999/xhtml"
- xmlns:flux="http://fedext.net/ns/flux/ViewHelpers"
- xmlns:v="http://fedext.net/ns/vhs/ViewHelpers"
- xmlns:f="http://typo3.org/ns/fluid/ViewHelpers">
- <f:layout name="{settings.template}/CustomContent"/>
- <f:section name="Configuration">
- <flux:form id="Carousel"
- label="{f:translate(key: 'insert_carousel')}"
- description="{f:translate(key: 'insert_carousel')}"
- extensionName="OtTemplating"
- >
- <flux:form.option.group value="ot_widgets" />
- <flux:form.option.icon value="EXT:ot_templating/Resources/Public/Icons/opentalent-144x144.png" />
- <flux:field.input name="width" eval="trim" default="600" label="{f:translate(key: 'width_in_pixels')}"/>
- <flux:field.input name="height" eval="trim" default="400" label="{f:translate(key: 'height_in_pixels')}"/>
- <flux:field.checkbox name="crop" label="{f:translate(key: 'crop_large_images')} ?" default="0"/>
- <flux:field.inline.fal name="images" minItems="2" maxItems="24"/>
- </flux:form>
- </f:section>
- <f:section name="Preview">
- <p>Carrousel</p>
- <div class="be-carousel-preview">
- <f:for each="{v:content.resources.fal(field: 'images', record: '{record}')}"
- as="image"
- iteration="iterator">
- <f:if condition="{v:variable.pregMatch(pattern: '/.*(?:jpe?g|gif|png)$/', subject: image.url)}">
- <f:image treatIdAsReference="1"
- src="{image.id}"
- title="{image.title}"
- alt="{image.alternative}"
- class="be-carousel-img-preview"
- maxWidth="128"
- maxHeight="128"
- />
- </f:if>
- </f:for>
- </div>
- </f:section>
- <f:section name="Main">
- <div class="center-carousel">
- <div class="carousel" style="max-width:{width}px; max-height:{height}px">
- <f:for each="{v:content.resources.fal(field: 'images', record: '{record}')}"
- as="image"
- iteration="iterator">
- <div style="height: {height}px">
- <f:image treatIdAsReference="1"
- src="{image.id}"
- title="{image.title}"
- alt="{image.alternative}"
- class="carousel-img"
- width="{width}"
- maxHeight="{height}{f:if(condition: crop, then: 'c')}"
- />
- </div>
- </f:for>
- </div>
- </div>
- </f:section>
- </div>
|