templates/website/page/index.html.twig line 1

  1. {% extends '@web/base.html.twig' %}
  2. {% set metaParams = {
  3.     'title': "The Infinite Moment Gazette",
  4.     'description': "One capture = Endless memory = Positive Emotion = Infinite Moment",
  5.     'keywords': "photo, photo booth, gazette, memory, picture, foto, event, photo zone",
  6.     'ogImage': "/images/infinite-moment.png"
  7. } %}
  8. {% block meta %}
  9.     {% include '@web/parts/meta.html.twig' with metaParams %}
  10. {% endblock meta %}
  11. {% block title %}The Infinite Moment Gazette{% endblock title %}
  12. {% block body %}
  13.     {% set locale = app.request.locale %}
  14.     {% set cisLocales = ['ru', 'ua', 'ka'] %}
  15.     {% for label, messages in app.flashes %}
  16.         {% for message in messages %}
  17.             <div id="christmasSuccessModal" class="christmas-modal">
  18.                 <div class="christmas-modal-content">
  19.                     <h2>🎅 {{ 'modal.success_title'|trans }}</h2>
  20.                     <p>{{ 'modal.success_message' | trans }}</p>
  21.                     <button id="closeChristmasModal" class="main-button">✨ {{ 'modal.close_button'|trans }}</button>
  22.                 </div>
  23.             </div>
  24.         {% endfor %}
  25.     {% endfor %}
  26.     <div id="cropModal" class="crop-modal">
  27.         <div class="crop-modal-content">
  28.             <h3>{{ 'Adjust your image'|trans }}</h3>
  29.             <div class="crop-info">
  30.                 <p>Drag to move image • Scroll to zoom • Crop area: 4:5 ratio (500×625px)</p>
  31.             </div>
  32.             <div class="crop-container">
  33.                 <img id="cropImage" style="display:block; max-width:100%; max-height:100%;">
  34.             </div>
  35.             <div class="crop-actions">
  36.                 <button type="button" id="cropCancel">{{ 'Cancel'|trans }}</button>
  37.                 <button type="button" id="cropConfirm" class="main-button">{{ 'Use this image'|trans }}</button>
  38.             </div>
  39.         </div>
  40.     </div>
  41.     <section class="section-home">
  42.         <div class="custom-container">
  43. {#            <section class="section-services wrapper-home-santa-section">#}
  44. {#                <div class="custom-container">#}
  45. {#                    <div class="wrapper-navigation">#}
  46. {#                        <h1>🎅 {{ 'Message to Santa'|trans }} 🎄</h1>#}
  47. {#                        <div class="music-control">#}
  48. {#                            <button id="musicToggle" class="main-button">⏸️ Pause Music</button>#}
  49. {#                        </div>#}
  50. {#                        <ul>#}
  51. {#                            <li><a href="{{ path('page_index') }}">{{ 'Home'|trans }}</a></li>#}
  52. {#                            <li><span>{{ 'Message to Santa'|trans }}</span></li>#}
  53. {#                        </ul>#}
  54. {#                    </div>#}
  55. {#                    <ul class="wrapper-santa-languages">#}
  56. {#                        {% set currentLocale = app.request.get('_locale') %}#}
  57. {#                        <li class="{{ currentLocale == 'en' ? 'active' : '' }}">#}
  58. {#                            <a href="{{ path(app.request.attributes.get('_route'),#}
  59. {#                                app.request.attributes.get('_route_params')|merge({'_locale': 'en'})) }}">#}
  60. {#                                <img src="{{ asset('images/flag/en.png') }}" alt="">#}
  61. {#                            </a>#}
  62. {#                        </li>#}
  63. {#                        <li class="{{ currentLocale == 'hy' ? 'active' : '' }}">#}
  64. {#                            <a href="{{ path(app.request.attributes.get('_route'),#}
  65. {#                                app.request.attributes.get('_route_params')|merge({'_locale': 'hy'})) }}">#}
  66. {#                                <img src="{{ asset('images/flag/am.jpg') }}" alt="">#}
  67. {#                            </a>#}
  68. {#                        </li>#}
  69. {#                        <li class="{{ currentLocale == 'ru' ? 'active' : '' }}">#}
  70. {#                            <a href="{{ path(app.request.attributes.get('_route'),#}
  71. {#                                app.request.attributes.get('_route_params')|merge({'_locale': 'ru'})) }}">#}
  72. {#                                <img src="{{ asset('images/flag/ru.png') }}" alt="">#}
  73. {#                            </a>#}
  74. {#                        </li>#}
  75. {#                        <li class="{{ currentLocale == 'ka' ? 'active' : '' }}">#}
  76. {#                            <a href="{{ path(app.request.attributes.get('_route'),#}
  77. {#                                app.request.attributes.get('_route_params')|merge({'_locale': 'ka'})) }}">#}
  78. {#                                <img src="{{ asset('images/flag/ge.jpg') }}" alt="">#}
  79. {#                            </a>#}
  80. {#                        </li>#}
  81. {#                        <li class="{{ currentLocale == 'de' ? 'active' : '' }}">#}
  82. {#                            <a href="{{ path(app.request.attributes.get('_route'),#}
  83. {#                                app.request.attributes.get('_route_params')|merge({'_locale': 'de'})) }}">#}
  84. {#                                <img src="{{ asset('images/flag/de.png') }}" alt="">#}
  85. {#                            </a>#}
  86. {#                        </li>#}
  87. {#                        <li class="{{ currentLocale == 'es' ? 'active' : '' }}">#}
  88. {#                            <a href="{{ path(app.request.attributes.get('_route'),#}
  89. {#                                app.request.attributes.get('_route_params')|merge({'_locale': 'es'})) }}">#}
  90. {#                                <img src="{{ asset('images/flag/es.png') }}" alt="">#}
  91. {#                            </a>#}
  92. {#                        </li>#}
  93. {#                        <li class="{{ currentLocale == 'fr' ? 'active' : '' }}">#}
  94. {#                            <a href="{{ path(app.request.attributes.get('_route'),#}
  95. {#                                app.request.attributes.get('_route_params')|merge({'_locale': 'fr'})) }}">#}
  96. {#                                <img src="{{ asset('images/flag/fr.png') }}" alt="">#}
  97. {#                            </a>#}
  98. {#                        </li>#}
  99. {#                        <li class="{{ currentLocale == 'ua' ? 'active' : '' }}">#}
  100. {#                            <a href="{{ path(app.request.attributes.get('_route'),#}
  101. {#                                app.request.attributes.get('_route_params')|merge({'_locale': 'ua'})) }}">#}
  102. {#                                <img src="{{ asset('images/flag/uk.png') }}" alt="">#}
  103. {#                            </a>#}
  104. {#                        </li>#}
  105. {#                        <li class="{{ currentLocale == 'it' ? 'active' : '' }}">#}
  106. {#                            <a href="{{ path(app.request.attributes.get('_route'),#}
  107. {#                                app.request.attributes.get('_route_params')|merge({'_locale': 'it'})) }}">#}
  108. {#                                <img src="{{ asset('images/flag/it.png') }}" alt="">#}
  109. {#                            </a>#}
  110. {#                        </li>#}
  111. {#                        <li class="{{ currentLocale == 'el' ? 'active' : '' }}">#}
  112. {#                            <a href="{{ path(app.request.attributes.get('_route'),#}
  113. {#                                app.request.attributes.get('_route_params')|merge({'_locale': 'el'})) }}">#}
  114. {#                                <img src="{{ asset('images/flag/gr.png') }}" alt="">#}
  115. {#                            </a>#}
  116. {#                        </li>#}
  117. {#                    </ul>#}
  118. {#                    <div class="wrapper-items">#}
  119. {#                        <div class="wrapper-video">#}
  120. {#                            {% set videoUrls = {#}
  121. {#                                'en': {'src': 'video_template/en.mp4'},#}
  122. {#                                'ru': {'src': 'video_template/ru.mp4'},#}
  123. {#                                'hy': {'src': 'video_template/hy.mp4'},#}
  124. {#                                'es': {'src': 'video_template/es.mp4'},#}
  125. {#                                'it': {'src': 'video_template/it.mp4'},#}
  126. {#                                'fr': {'src': 'video_template/fr.mp4'},#}
  127. {#                                'el': {'src': 'video_template/el.mp4'},#}
  128. {#                                'ua': {'src': 'video_template/ua.mp4'},#}
  129. {#                                'ka': {'src': 'video_template/ka.mp4'},#}
  130. {#                                'de': {'src': 'video_template/de.mp4'}#}
  131. {#                            } %}#}
  132. {#                            #}{# If locale not found, default to English #}
  133. {#                            {% set videoUrl = videoUrls[app.request.locale] ?? videoUrls['en'] %}#}
  134. {#                            <video width="455" controls poster="{{ asset('images/santa-poster.jpg') }}">#}
  135. {#                                <source src="{{ asset(videoUrl.src) }}" type="video/mp4">#}
  136. {#                                {{ 'Your browser does not support the video tag.'|trans }}#}
  137. {#                            </video>#}
  138. {#                            <div class="santa-pricing-info">#}
  139. {#                                <p class="pricing-title">#}
  140. {#                                    🎅 {{ 'Santa Video Options'|trans }}#}
  141. {#                                </p>#}
  142. {#                                <ul class="pricing-list">#}
  143. {#                                    <li>#}
  144. {#                                        <strong>🎄 {{ 'Default Santa greeting'|trans }}</strong><br>#}
  145. {#                                        {% if locale == 'hy' %}#}
  146. {#                                            2000 ֏#}
  147. {#                                        {% elseif locale in cisLocales %}#}
  148. {#                                            10 $#}
  149. {#                                        {% else %}#}
  150. {#                                            10 €#}
  151. {#                                        {% endif %}#}
  152. {#                                    </li>#}
  153. {#                                    <li>#}
  154. {#                                        <strong>🎥 {{ 'Personalized message'|trans }}</strong><br>#}
  155. {#                                        {% if locale == 'hy' %}#}
  156. {#                                            3000 ֏#}
  157. {#                                        {% elseif locale in cisLocales %}#}
  158. {#                                            15 $#}
  159. {#                                        {% else %}#}
  160. {#                                            15 €#}
  161. {#                                        {% endif %}#}
  162. {#                                    </li>#}
  163. {#                                </ul>#}
  164. {#                                <p class="pricing-note">#}
  165. {#                                    {{ 'If you write a personal message, Santa will read it in the video.'|trans }}#}
  166. {#                                </p>#}
  167. {#                            </div>#}
  168. {#                        </div>#}
  169. {#                        <div class="wrapper-form wrapper-santa-form section-services wrapper-home-santa">#}
  170. {#                            <form  id="santaForm" action="{{ path('page_santa') }}" method="post" enctype="multipart/form-data">#}
  171. {#                                <div class="wrapper-input">#}
  172. {#                                    <input required type="text"#}
  173. {#                                           placeholder="{{ 'form.from_name_placeholder'|trans }}*"#}
  174. {#                                           name="fromName">#}
  175. {#                                    <input required type="text"#}
  176. {#                                           placeholder="{{ 'form.recipient_name_placeholder'|trans }}*"#}
  177. {#                                           name="name">#}
  178. {#                                    <input type="email"#}
  179. {#                                           placeholder="{{ 'form.from_email_placeholder'|trans }}"#}
  180. {#                                           name="fromEmail">#}
  181. {#                                    <input required type="email"#}
  182. {#                                           placeholder="{{ 'form.recipient_email_placeholder'|trans }}*"#}
  183. {#                                           name="email">#}
  184. {#                                </div>#}
  185. {#                                <div class="wrapper-input">#}
  186. {#                                    <input required type="text"#}
  187. {#                                           placeholder="{{ 'form.gift_placeholder'|trans }}*"#}
  188. {#                                           name="gift">#}
  189. {#                                    <input type="tel" required#}
  190. {#                                           placeholder="{{ 'form.phone_placeholder'|trans }}*"#}
  191. {#                                           name="phone">#}
  192. {#                                </div>#}
  193. {#                                <div class="wrapper-input">#}
  194. {#            <textarea#}
  195. {#                    placeholder="{{ 'form.comment_placeholder'|trans }}"#}
  196. {#                    name="comment"></textarea>#}
  197. {#                                </div>#}
  198. {#                                <div class="wrapper-input">#}
  199. {#                                    <label class="file-label">#}
  200. {#                                        {{ 'form.image_placeholder'|trans }}#}
  201. {#                                        <input required type="file" name="image" accept="image/*">#}
  202. {#                                    </label>#}
  203. {#                                </div>#}
  204. {#                                <div class="wrapper-button two-buttons">#}
  205. {#                                    <button type="submit"#}
  206. {#                                            name="action"#}
  207. {#                                            value="pay_now"#}
  208. {#                                            class="main-button">#}
  209. {#                                        💳 {{ 'form.pay_now'|trans }}#}
  210. {#                                    </button>#}
  211. {#                                    <button type="submit"#}
  212. {#                                            name="action"#}
  213. {#                                            value="request"#}
  214. {#                                            class="secondary-button">#}
  215. {#                                        ✉️ {{ 'form.leave_request'|trans }}#}
  216. {#                                    </button>#}
  217. {#                                </div>#}
  218. {#                            </form>#}
  219. {#                        </div>#}
  220. {#                    </div>#}
  221. {#                </div>#}
  222. {#            </section>#}
  223.             <div class="wrapper-home-slider">
  224.                 <div class="wrapper-banner-image" style="background-image: url({{ banner.image }})">
  225.                     <div class="wrapper-text">
  226.                                 <span>
  227.                                     {{ "now"|date('M')|trans }}
  228.                                     {{ "now"|date('d,') }}
  229.                                     {{ "now"|date(' Y') }}
  230.                                 </span>
  231.                         <h2>
  232.                             {{ banner.title }}
  233.                         </h2>
  234.                         <p>
  235.                             {{ banner.shortDescription }}
  236.                         </p>
  237.                         <a href="#">
  238.                             {{ 'READ MORE'|trans }}…
  239.                         </a>
  240.                     </div>
  241.                 </div>
  242.                 <div class="wrapper-slider">
  243.                     <h3>
  244.                         Daily Feed
  245.                     </h3>
  246.                     <div class="slider">
  247.                         {% for item in news %}
  248.                             <div>
  249.                                 <div class="wrapper-item">
  250.                                     <h2>
  251.                                         {{ item.title }}
  252.                                     </h2>
  253.                                     <a href="#">
  254.                                         {{ item.shortDescription }}
  255.                                     </a>
  256.                                 </div>
  257.                             </div>
  258.                         {% endfor %}
  259.                     </div>
  260.                 </div>
  261.             </div>
  262.             <div class="wrapper-news">
  263.                 <h2 class="main-title">
  264.                     Featured News
  265.                 </h2>
  266.                 <div class="wrapper-items">
  267.                     <div class="wrapper-item wrapper-left-item">
  268.                         <div class="wrapper-image">
  269.                             <img src="{{ services[0].image }}" alt="">
  270.                         </div>
  271.                         <h3>
  272.                             {{ services[1].title }}
  273.                         </h3>
  274.                         <div class="wrapper-image">
  275.                             <img src="{{ services[1].image }}" alt="">
  276.                         </div>
  277.                     </div>
  278.                     <div class="wrapper-item wrapper-middle-item">
  279.                         <div class="wrapper-text">
  280.                             <h3>
  281.                                 {{ services[0].title }}
  282.                             </h3>
  283.                             <p>
  284.                                 {{ services[0].shortDescription }}
  285.                             </p>
  286.                             <a href="{{ path('page_service',{'id':services[0].id}) }}">READ MORE</a>
  287.                         </div>
  288.                         <div class="wrapper-text">
  289.                             <p>
  290.                                 {{ services[1].shortDescription }}
  291.                             </p>
  292.                             <a href="{{ path('page_service',{'id':services[1].id}) }}">READ MORE</a>
  293.                         </div>
  294.                     </div>
  295.                     <div class="wrapper-item wrapper-right-item">
  296.                         <div class="wrapper-image">
  297.                             <img src="{{ services[2].image }}" alt="">
  298.                         </div>
  299.                         <div class="wrapper-text">
  300.                             <h3>
  301.                                 {{ services[2].title }}
  302.                             </h3>
  303.                             <p>
  304.                                 {{ services[2].shortDescription }}
  305.                             </p>
  306.                             <a href="{{ path('page_service',{'id':services[2].id}) }}">READ MORE</a>
  307.                         </div>
  308.                     </div>
  309.                 </div>
  310.             </div>
  311.             <div class="wrapper-subscribe">
  312.                 <h5>
  313.                     Request my picture
  314.                 </h5>
  315.                 <form action="{{ path('page_view_image') }}" class="wrapper-input">
  316.                     <input name="code" type="text" placeholder="Your private code">
  317.                     <button>
  318.                         Send
  319.                     </button>
  320.                 </form>
  321.             </div>
  322.         </div>
  323.     </section>
  324.     <audio id="jingle" src="{{ asset('sounds/jingle-bells.mp3') }}"></audio>
  325.     <audio id="hoho" src="{{ asset('sounds/ho-ho-ho.mp3') }}"></audio>
  326.     <audio id="music"
  327.            src="{{ asset('sounds/kids-happy-background-music.mp3') }}"
  328.            loop muted autoplay playsinline></audio>
  329. {% endblock %}
  330. {% block javascripts %}
  331.     {{ parent() }}
  332.     <script>
  333.         fbq('track', 'ViewContent', {
  334.             content_name: 'Home Page'
  335.         });
  336.         const santaForm = document.getElementById('santaForm');
  337.         if (santaForm) {
  338.             santaForm.addEventListener('submit', function () {
  339.                 if (!santaForm.checkValidity()) {
  340.                     return;
  341.                 }
  342.                 const eventId = crypto.randomUUID();
  343.                 fbq('track', 'AddToCart', {
  344.                     content_name: 'Santa Message'
  345.                 }, { eventID: eventId });
  346.             });
  347.         }
  348.     </script>
  349. {% endblock %}