templates/blocks/category_view/index.html.twig line 1

Open in your IDE?
  1. <style>
  2.             
  3.     /* Estilo del texto con límite de 3 líneas */
  4.     .text-container {
  5.     display: -webkit-box;
  6.     -webkit-line-clamp: 3;
  7.     -webkit-box-orient: vertical;
  8.     overflow: hidden;
  9.     transition: max-height 0.5s ease;
  10.     }
  11.     /* Cuando está expandido, se muestra completo */
  12.     .expanded {
  13.     -webkit-line-clamp: unset;
  14.     }
  15.     /* Estilo del botón */
  16.     .toggle-btn {
  17.     cursor: pointer;
  18.     color: #007bff;
  19.     font-weight: bold;
  20.     text-align: center;
  21.     margin-top: 8px;
  22.     user-select: none;
  23.     display: inline-block;
  24.     }
  25.     /* Aumentar el ancho del tooltip */
  26.     .tooltip-inner {
  27.     max-width: 300px !important; /* Puedes cambiar este valor */
  28.     text-align: left;
  29.     white-space: normal;
  30.     }
  31.     .order-container .title-block{
  32.             top: 30px;
  33.             z-index: 1000;
  34.             background: #f8f9fa;
  35.     }
  36.     
  37. </style>
  38. <div class="row">
  39.     <div class="col-12">
  40.         <div class="row align-items-start">
  41.             {% for category in categories %}
  42.                 <div class="col-6 col-xxl-3 col-xl-3 col-lg-4 col-md-6 d-flex align-items-center mb-3 product-row" >
  43.                     <div class="row">
  44.                         <!-- Imagen -->
  45.                         <div class="col-lg-12 col-12">
  46.                             <img src="/uploads/images/categories/{{ category.getImageName }}" alt="{{ category.name }}" class="img-fluid rounded pointer zoom" onclick="window.location.href='/order?category={{category.id}}'">
  47.                         </div>
  48.                         <!-- Información -->
  49.                         <div class="col-lg-12 col-12">
  50.                             <h6 class="section-title mt-1 pointer" onclick="window.location.href='/order?category={{category.id}}'">{{ category.name }}</h5>
  51.                         </div>
  52.                     </div>
  53.                 </div>
  54.             {% endfor %}
  55.         </div>
  56.     </div>
  57. </div>