-
Notifications
You must be signed in to change notification settings - Fork 5
/
header.twig
209 lines (197 loc) · 5.83 KB
/
header.twig
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
<header section-id="{{ sectionId }}" class='d-flex flex-column'>
{% include 'template_for_store_messages' %}
{% include 'header-announcement-bar.twig' with { 'ab_settings' : settings } %}
{% include 'header-account-lang-currency.twig' with { 'header_settings' : settings } %}
<div id="fixed-header" style="z-index: 3">
<!-- input search for mobile view -->
<div style="z-index: 3">
{% include 'header-search-header.twig' with { 'header_settings' : settings } %}
</div>
<div style="position: relative; z-index: -1">
<div class="sm-search-div">
<div class="autocomplete" style="position: relative">
<input type="text"
data-cat-id="{{ category.id }}"
class="form-control search-input-input"
placeholder="{% if header_settings.search_placeholder %}{{ header_settings.search_placeholder }}{% else %}{{ locals.search_placeholder }}{% endif %}"
>
<div class="autocomplete-items"></div>
</div>
</div>
</div>
</div>
{% include 'header-sliding-menu.twig' with { 'menu_settings' : settings } %}
{% include 'header-mega-menu.twig' with { 'menu_settings' : settings } %}
{% if not ('hide_country' in settings.header_options) or not ('hide_language' in settings.header_options)%}
<div class="modal" id="langCurrecyModal" tabindex="-1" role="dialog">
<div class="modal-dialog modal-dialog-centered" role="document">
<div class="modal-content">
<div class="modal-body" style="padding: 10px">
{% include 'template_for_shipping_destination_currency_lang' with { 'hideDestination' : ('hide_country' in settings.header_options), 'hideLanguage' : ('hide_language' in settings.header_options) , 'hideCurrency' : ('hide_country' in settings.header_options) } %}
</div>
</div>
</div>
</div>
{% endif %}
</header>
{% schema %}
{
"name": {
"ar": "اعلى الصفحة",
"en": "Header"
},
"icon": "fa fa-square",
"display": true,
"settings": {
"announcement_bar": {
"type": "fieldset",
"label": {
"ar": "شريط التنبيهات",
"en": "Announcement bar"
},
"icon": "font_awesome",
"expandable": true,
"settings": {
"display": {
"type": "checkbox",
"label": {
"ar": " ",
"en": " "
},
"option": {
"ar": "إظهار",
"en": "Display menu"
},
"noLabel": true
},
"text": {
"type": "text",
"label": {
"ar": "النص",
"en": "Text"
}
},
"url": {
"type": "url",
"label": {
"ar": "الرابط",
"en": "Link"
},
"info": {
"ar": "في حال كان الحقل فارغا لن يتم الانتقال للرابط عند الضغط",
"en": "This is an info text sample here"
}
},
"page_display": {
"type": "select",
"label": {
"ar": "عرض شريط التنبيهات في",
"en": "Display announcement bar in"
},
"options": [
{
"value": "all",
"label": {
"ar": "جميع الصفحات",
"en": "all pages"
}
},
{
"value": "home",
"label": {
"ar": "الصفحة الرئيسية ففط",
"en": "home page only"
}
}
],
"default": "all"
},
"background_color": {
"type": "color",
"label": {
"ar": "لون الخلفية",
"en": "Text color"
}
},
"text_color": {
"type": "color",
"label": {
"ar": "لون النص",
"en": "Text color"
}
}
}
},
"header": {
"type": "fieldset",
"label": {
"ar": "رأس الصفحة",
"en": "Header"
},
"icon": "font_awesome",
"expandable": true,
"settings": {
"logo": {
"type": "image",
"label": {
"ar": "الشعار",
"en": "Logo"
},
"info": {
"ar": "ارفع صورة بحجم 750 * 750 ",
"en": "This is an info text sample here"
}
},
"logo_mobile": {
"type": "image",
"label": {
"ar": " الشعار للجوال (اختياري)",
"en": "Logo mobile (optional)"
},
"info": {
"ar": "ارفع صورة بحجم 322 * 750 ",
"en": "This is an info text sample here"
}
},
"options": {
"type": "checkboxes",
"label": {
"ar": "الخيارات",
"en": "Options"
},
"options": [
{
"value": "hide_search_bar",
"label": {
"ar": "إخفاء شريط البحث",
"en": "Hide search bar"
}
},
{
"value": "hide_language",
"label": {
"ar": "إخفاء اللغة",
"en": "Hide language"
}
},
{
"value": "hide_country",
"label": {
"ar": "إخفاء اسم الدولة",
"en": "Hide country"
}
}
]
},
"search_placeholder": {
"type": "text",
"label": {
"ar": "تلميح شريط البحث",
"en": "Search placeholder"
}
}
}
}
}
}
{% endschema %}