-
Notifications
You must be signed in to change notification settings - Fork 19
Expand file tree
/
Copy pathindex.twig
More file actions
222 lines (172 loc) · 9.79 KB
/
Copy pathindex.twig
File metadata and controls
222 lines (172 loc) · 9.79 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
<!DOCTYPE html>
<html class="{{ get_template_mode(false) }}" dir="{{ get_template_dir() }}" lang="{{ App.getLocale() }}">
<head>
{{ View.fireHook('frontend.head_start') }}
{% set title = block('title') is defined ? block('title') : Lang.get('general.support_portal')|e %}
<title>{{ company }} - {{ title|raw }}</title>
{% block meta %}{% endblock %}
<meta property="og:title" content="{{ title|raw }}" />
<meta property="og:image" content="{{ get_logo() }}" />
{% include 'frontend.' ~ template ~ '.head_common' %}
{% block scripts_header %}{% endblock %}
{% set route = Route.currentRouteName() %}
{{ View.fireHook('frontend.head') }}
{{ View.fireHook('frontend.head_end') }}
</head>
<body class="sp:bg-secondary sp:text-primary sp:print:bg-primary">
{{ View.fireHook('frontend.body_start') }}
<header class="sp:sticky sp:top-0 sp:z-10002 sp:px-6 sp:bg-primary sp:lg:px-8 sp:print:static sp:print:px-0 sp:print:shadow-none
{% if not (route starts with 'core.frontend.home') or not show_search %}sp:shadow{% endif %}">
<div class="sp:container sp:relative sp:py-2 sp:m-auto sp:print:max-w-full">
{{ View.fireHook('frontend.header_start') }}
{% if show_search %}
<div class="sp-search sp:absolute sp:hidden sp:flex sp:items-center sp:h-full sp:w-full sp:-mt-2
sp:bg-primary sp:z-10 sp:print:hidden">
<div class="sp:grow sp:w-full">
<form name="search" action="{{ route('core.frontend.search') }}" method="get">
<input type="search" name="query" placeholder="{{ Lang.get('general.search') }}" />
</form>
</div>
<div class="sp:flex-none">
<div class="sp-search-close sp-button sp:ms-3" title="{{ Lang.get('general.close') }}">
<i class="fa-solid fa-times"></i>
</div>
</div>
</div>
{% endif %}
<div class="sp:flex sp:items-center sp:h-full">
<div class="sp:grow">
<a href="{{ route('core.frontend.home') }}">
<img src="{{ get_logo(false) }}" alt="{{ company }}" class="sp-logo sp:inline sp:dark:hidden sp:print:inline" />
<img src="{{ get_logo(true) }}" alt="{{ company }}" class="sp-logo sp:hidden sp:dark:inline sp:print:hidden" />
</a>
</div>
<div class="sp:flex-none sp:print:hidden">
{% if not (route starts with 'core.frontend.home') and show_search %}
<a class="sp-search-button sp:p-2 sp:me-2">
<i class="fa-solid fa-search"></i>
</a>
{% endif %}
</div>
<div class="sp:flex-none sp:hidden sp:lg:block sp:print:hidden">
{% if Config.get('settings.website_url') is not empty %}
<a href="{{ Config.get('settings.website_url') }}" class="sp:me-4">
{{ Lang.get('core.back_to_website') }}
</a>
{% endif %}
{% if auth_check() %}
<div class="sp-dropdown-container sp:relative sp:ms-1">
<a class="sp-action">
<img class="sp-avatar sp:max-w-8 sp:shadow" src="{{ auth_user().avatar_url }}" />
{{ auth_user().formatted_name }}
<i class="fa-solid fa-chevron-down sp:ms-1 sp:text-xs" aria-hidden="true"></i>
</a>
<div class="sp-dropdown sp:end-0 sp:mt-2">
{% include 'frontend.' ~ template ~ '.navigation' with {'account': true} %}
</div>
</div>
{% else %}
<a href="{{ route('user.login') }}">
{{ Lang.get('user.login') }}
</a>
{% endif %}
</div>
<div class="sp:flex-none sp:leading-0 sp:lg:hidden sp:print:hidden">
<div class="sp-mobile-nav-button sp:inline-block">
<div class="sp:px-1.5 sp:py-1 sp:rounded sp:border sp:cursor-pointer">
<svg focusable="false" viewBox="0 0 24 24">
<path d="M3 18h18v-2H3v2zm0-5h18v-2H3v2zm0-7v2h18V6H3z"></path>
</svg>
</div>
</div>
</div>
</div>
{% block header %}{% endblock %}
{{ View.fireHook('frontend.header_end') }}
</div>
</header>
<nav class="sp-mobile-nav sp:hidden sp:fixed sp:w-full sp:top-0 sp:px-6 sp:bg-primary-800 sp:shadow-inner
sp:text-white sp:overflow-y-auto sp:z-10001 sp:lg:hidden sp:print:hidden">
<div class="sp:container sp:py-6 sp:m-auto">
{% include 'frontend.' ~ template ~ '.navigation' %}
</div>
</nav>
{% block precontent %}{% endblock %}
<div class="sp:relative sp:xs:px-6 sp:lg:static sp:lg:px-8 sp:print:px-0">
<div class="sp:container sp:mx-auto sp:my-4 sp:xs:my-6 sp:lg:my-8 sp:print:max-w-full">
{{ View.fireHook('frontend.wrapper_start') }}
<div class="sp:px-6 sp:mb-4 sp:leading-none sp:xs:px-0 sp:xs:mb-6 sp:lg:mb-8">
<h1 class="sp:hidden sp:md:block sp:mb-3 sp:text-3xl sp:font-normal sp:print:block">
{{ title|raw }}
</h1>
<div class="sp-breadcrumb sp:md:text-sm sp:print:mb-6">
<a href="{{ route('core.frontend.home') }}">{{ Lang.get('general.support_portal') }}</a> »
{% block breadcrumb %}{% endblock %}
</div>
<hr class="sp:hidden sp:mx-0 sp:print:block" />
</div>
<div class="sp:flex sp:flex-wrap-reverse sp:min-w-0 sp:lg:flex-nowrap">
<div class="sp-content sp:grow sp:w-full sp:overflow-hidden sp:lg:w-auto">
{{ View.fireHook('frontend.content_start') }}
<div class="sp-content-inner sp:p-6 sp:bg-primary sp:wrap-break-word sp:xs:rounded sp:print:p-0">
{{ View.fireHook('frontend.content_inner_start') }}
{% block subtitle %}{% endblock %}
<!-- Box to display success/error messages generated by JavaScript -->
<div class="sp-alert sp:hidden" id="js-message-box"></div>
{% if Session.has('success') %}
<div class="sp-alert sp-alert-success">{{ Session.get('success')|raw }}</div>
{% elseif Session.has('error') %}
<div class="sp-alert sp-alert-error">{{ Session.get('error')|raw }}</div>
{% elseif Session.has('warning') %}
<div class="sp-alert sp-alert-warning">{{ Session.get('warning')|raw }}</div>
{% endif %}
{% if errors|default is not empty and errors.count() %}
<div class="sp-alert sp-alert-error">
<strong>{{ Lang.get('messages.please_correct') }}</strong><br />
{% for error in errors.all() %}
{{ error }}<br />
{% endfor %}
</div>
{% endif %}
{% block content %}{% endblock %}
{{ View.fireHook('frontend.content_inner_end') }}
</div>
{{ View.fireHook('frontend.content_end') }}
</div>
{% block sidebar %}{% endblock %}
{{ View.fireHook('frontend.wrapper_end') }}
</div>
</div>
</div>
<div class="sp:px-6 sp:mt-6 sp:border-t sp:border-tertiary sp:print:px-0">
<div class="sp:container sp:py-6 sp:mx-auto sp:print:max-w-full">
<div class="sp:flex sp:flex-wrap sp:items-center">
<div class="sp:grow sp:w-full sp:mb-3 sp:sm:w-auto sp:sm:mb-0">
<span class="sp:text-tertiary">
© {{ company }}
</span>
</div>
{% if Config.get('settings.language_frontend_toggle') == 1 %}
<div class="sp:flex-none sp:w-full sp:sm:w-auto sp:print:hidden">
<i class="fa-solid fa-language" title="{{ Lang.choice('general.language', 1) }}"></i>
<select name="language" class="sp:bg-primary">
{% for code, language in languages %}
<option value="{{ code }}"
{% if code == App.getLocale() %}selected="selected"{% endif %}
{% if attribute(returnTo, code) is defined %}data-return-to="{{ attribute(returnTo, code) }}"{% endif %}>
{{ language }}
</option>
{% endfor %}
</select>
</div>
{% endif %}
</div>
</div>
</div>
{{ View.fireHook('frontend.footer') }}
{% include 'frontend.' ~ template ~ '.footer_common' %}
<script src="{{ asset_rev('resources/assets/frontend/js/main.js')}}"></script>
{% block scripts_footer %}{% endblock %}
{{ View.fireHook('frontend.body_end') }}
</body>
</html>