templates/areas/apk-faq/view.html.twig line 1

Open in your IDE?
  1. {% if editmode %}
  2. <div class="uk-container apk-container-1400 uk-margin-medium">
  3.     <h2 class="uk-h2">Section FAQ</h2>
  4.     <ul uk-tab>
  5.         <li><a href="#">Configurations</a></li>
  6.         <li class="uk-active"><a href="#">Content Edit</a></li>
  7.     </ul>
  8.     <ul class="uk-switcher uk-margin">
  9.         <li>
  10.             <div>Type de heading pour le titre ?</div>
  11.             {{ pimcore_select("content-heading", {
  12.                 "store" : [
  13.                     ['span', 'span'],
  14.                     ['h1', 'Heading 1'],
  15.                     ['h2', 'Heading 2'],
  16.                     ['h3', 'Heading 3'],
  17.                     ['h4', 'Heading 4'],
  18.                     ['h5', 'Heading 5'],
  19.                     ['h6', 'Heading 6']
  20.                 ],
  21.                 "defaultValue" : "h2"
  22.             }) }}
  23.             <div><strong>Style</strong> du heading pour le titre ?</div>
  24.             {{ pimcore_select("content-heading-style", {
  25.                 "store" : [
  26.                     ['h1', 'Heading 1'],
  27.                     ['h2', 'Heading 2'],
  28.                     ['h3', 'Heading 3'],
  29.                     ['h4', 'Heading 4'],
  30.                     ['h5', 'Heading 5'],
  31.                     ['h6', 'Heading 6']
  32.                 ],
  33.                 "defaultValue" : "h2"
  34.             }) }}
  35.             
  36.             <div><strong>Alignement</strong> du titre</div>
  37.             {{ pimcore_select("text-align", {
  38.                 "store" : [
  39.                     ['uk-text-center', 'Centré'],
  40.                     ['uk-text-left', 'Gauche'],
  41.                     ['uk-text-right', 'Droite']
  42.                 ],
  43.                 "defaultValue" : "uk-text-center"
  44.             }) }}
  45.             <div>Taille du container</div>
  46.             {{ pimcore_select("container-width", {
  47.                 "store" : [
  48.                     ['apk-container-1400', '1400px (default)'],
  49.                     ['apk-container-1300', '1300px'],
  50.                     ['apk-container-1200', '1200px'],
  51.                     ['apk-container-1100', '1100px'],
  52.                     ['apk-container-1000', '1000px'],
  53.                     ['apk-container-900', '900px'],
  54.                     ['apk-container-800', '800px'],
  55.                 ],
  56.                 "defaultValue" : "apk-container-1400"
  57.             }) }}
  58.             <div>Espacement en haut du block</div>
  59.             {{ pimcore_select("margin-top", {
  60.                 "store" : [
  61.                     ['uk-padding-remove-top', 'Suppression du padding'],
  62.                     ['', 'Aucun'],
  63.                     ['uk-margin-small-top', 'Petit'],
  64.                     ['uk-margin-medium-top', 'Moyen'],
  65.                     ['uk-margin-large-top', 'Grand'],
  66.                     ['uk-margin-xlarge-top', 'Très grand'],
  67.                 ],
  68.                 "defaultValue" : ""
  69.             }) }}
  70.             <div>Espacement en bas du block</div>
  71.             {{ pimcore_select("margin-bottom", {
  72.                 "store" : [
  73.                     ['uk-padding-remove-bottom', 'Suppression du padding'],
  74.                     ['', 'Aucun'],
  75.                     ['uk-margin-small-bottom', 'Petit'],
  76.                     ['uk-margin-medium-bottom', 'Moyen'],
  77.                     ['uk-margin-large-bottom', 'Grand'],
  78.                     ['uk-margin-xlarge-bottom', 'Très grand'],
  79.                 ],
  80.                 "defaultValue" : ""
  81.             }) }}
  82.         </li>
  83.     
  84.         <li class="uk-active">
  85.             <div class="uk-margin-large-bottom">
  86.                 <div class="apk-content">
  87.                     <h2 class="uk-h2">
  88.                         {{ pimcore_textarea("content-title",{
  89.                             "nl2br" : true,
  90.                             "placeholder" : "Titre (optionnel)"
  91.                         }) }}
  92.                     </h2>
  93.                     <div><span class="uk-h4">Contenu (optionnel)</span></div>
  94.                     {{ pimcore_wysiwyg("content") }}
  95.                     <h3>Ensemble des FAQ</h3>
  96.                     <div class="uk-dark" uk-alert>
  97.                       {% for faq in pimcore_block('faqBlock').iterator %}
  98.                         <div class="uk-card">
  99.                           <div>
  100.                             <div><h4 class="uk-h4 uk-margin-remove-bottom">Titre</h4></div>
  101.                             <h3 class="uk-h3 uk-margin-small-top">{{ pimcore_textarea('faqTitle', {'nl2br' : true}) }}</h3>
  102.                           </div>
  103.                           <div>
  104.                             <div><h4 class="uk-h4 uk-margin-remove-bottom">contenu</h4></div>
  105.                             {{ pimcore_wysiwyg('faqContent') }}
  106.                           </div>
  107.                         </div>
  108.                       {% endfor %}
  109.                     </div>
  110.                     <div class="actions uk-margin-top">
  111.                         <span class="uk-h4">Lien (optionnel)</span>
  112.                         <div>
  113.                             {{ pimcore_link("content-btn", {
  114.                                 "class" : "uk-button"
  115.                             }) }}
  116.                         </div>
  117.                     </div>
  118.                 </div>
  119.             </div>
  120.         </li>
  121.     </ul>
  122. </div>
  123. {% endif %}
  124. {% if not editmode %}
  125. <div class="apk-areabrick-container {{ pimcore_select("margin-top") }} {{ pimcore_select("margin-bottom") }}">
  126.     <div class="uk-container {{ pimcore_select("container-width") }}">
  127.         <div class="{{ pimcore_select("text-align") }}">
  128.             {% if not pimcore_textarea("content-title").isEmpty %}
  129.                 {% if pimcore_select("content-heading").getData() == 'span' %}
  130.                     <span class="uk-h2">
  131.                         {{ pimcore_textarea("content-title", {
  132.                         "nl2br" : true})|raw }}
  133.                     </span>
  134.                 {% else %}
  135.                     {% set content_heading = pimcore_select("content-heading").getData() %}
  136.                     <{{ content_heading }} class="uk-{{ pimcore_select("content-heading-style").getData() }}">
  137.                         {{ pimcore_textarea("content-title", {
  138.                         "nl2br" : true})|raw }}
  139.                     </{{ content_heading }}>
  140.                 {% endif %}
  141.             {% endif %}
  142.         </div>
  143.         <div class="uk-text-center">
  144.           {% if not pimcore_wysiwyg("content").isEmpty %}
  145.           <div class="apk-content">
  146.               {{ pimcore_wysiwyg("content") }}
  147.           </div>
  148.         {% endif %}
  149.         </div>
  150.         <div class="apk-faq-container">
  151.             <ul uk-accordion="multiple: true">
  152.               {% set n = 1 %}
  153.               {% set count = pimcore_block('faqBlock').getData()|length %}
  154.               {% for faq in pimcore_block('faqBlock').iterator %}
  155.                 <li>
  156.                   <a class="uk-accordion-title" href="#">
  157.                     <h4 class="uk-margin-remove-bottom uk-text-bold">{{ pimcore_textarea('faqTitle', {'nl2br' : true}) }}</h4>
  158.                   </a>
  159.                   <div class="uk-accordion-content">
  160.                     {{ pimcore_wysiwyg('faqContent') }}
  161.                   </div>
  162.                 </li>
  163.                 {% set n = n + 1 %}
  164.               {% endfor %}
  165.               
  166.               </ul>
  167.               
  168.               {% if not pimcore_link("content-btn").isEmpty() %}
  169.               <div class="apk-actions uk-text-center uk-margin-large-top">
  170.                   {{ pimcore_link("content-btn", {
  171.                       "class" : "uk-button uk-button-large "
  172.                   }) }}
  173.               </div>
  174.             {% endif %}
  175.         </div>
  176.     </div>
  177.     
  178. </div>
  179. {% endif %}