Skip to content

Commit 1d975b7

Browse files
Marc BOUSSOULADEMarc BOUSSOULADE
Marc BOUSSOULADE
authored and
Marc BOUSSOULADE
committed
Add all files of module
1 parent 6494860 commit 1d975b7

File tree

9 files changed

+515
-0
lines changed

9 files changed

+515
-0
lines changed

config_fr.xml

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?xml version="1.0" encoding="UTF-8" ?>
2+
<module>
3+
<name>multishopselector</name>
4+
<displayName><![CDATA[Multishop Selector]]></displayName>
5+
<version><![CDATA[0.0.5]]></version>
6+
<description><![CDATA[Display a select on home page for choosing the desired store.]]></description>
7+
<author><![CDATA[Marc Boussoulade - Virtuoworks.com]]></author>
8+
<tab><![CDATA[front_office_features]]></tab>
9+
<confirmUninstall><![CDATA[Are you sure you want to uninstall?]]></confirmUninstall>
10+
<is_configurable>0</is_configurable>
11+
<need_instance>0</need_instance>
12+
<limited_countries></limited_countries>
13+
</module>

css/style.css

+246
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,246 @@
1+
/**********************************************/
2+
/*********************Page*********************/
3+
/**********************************************/
4+
5+
body{
6+
background-color: #fff !important;
7+
}
8+
9+
#wrapper{
10+
background: none;
11+
box-shadow: none;
12+
}
13+
14+
.homeShopSelector{
15+
background: #fff;
16+
background-size: cover;
17+
background-repeat: no-repeat;
18+
margin: 0;
19+
}
20+
#block_top_menu{
21+
display: none;
22+
}
23+
.pictos_top{
24+
display:none;
25+
}
26+
.homeShopSelector .header-container{
27+
height: 0;
28+
}
29+
30+
.blockCenterHome{
31+
margin-top: 35%;
32+
margin-bottom: 2%;
33+
}
34+
.homeShopSelector .columns-container{
35+
min-height: 0;
36+
}
37+
#footer, .homeShopSelector .footer-container{
38+
display:none;
39+
}
40+
41+
@media screen and (max-height: 460px){
42+
.blockCenterHome{
43+
margin-top: 6%;
44+
}
45+
}
46+
@media screen and (max-height: 800px) and (min-width: 992px){
47+
.blockCenterHome{
48+
margin-top: 10%;
49+
}
50+
}
51+
52+
/*********************************************/
53+
/***************Haut de la page***************/
54+
/*********************************************/
55+
.homeShopSelector .header-container, .homeShopSelector #header, .homeShopSelector .slogan_langues{
56+
background: transparent;
57+
}
58+
.homeShopSelector #header .menu__button{
59+
position: fixed;
60+
right: 0.8%;
61+
top: 2%;
62+
margin-left: 0;
63+
font-weight: bold;
64+
}
65+
66+
/**********************************************/
67+
/*********************Logo*********************/
68+
/**********************************************/
69+
@media screen and (max-height: 460px){
70+
.homeShopSelector .logoHome img{
71+
max-width: 75%;
72+
}
73+
}
74+
75+
/**********************************************/
76+
/***********Bloc - choix du magasin************/
77+
/**********************************************/
78+
#multishopselector_block_home .menu__button{
79+
color: #4E82BB;
80+
background-color:#FFF;
81+
text-transform:uppercase;
82+
border-radius:0px;
83+
width: 100%;
84+
}
85+
#multishopselector_block_home{
86+
background-color: #4E82BB;
87+
padding-top : 3%;
88+
padding-bottom: 3%;
89+
margin-top: 5px;
90+
}
91+
#multishopselector_block_home form .hideNoScript{
92+
display:none;
93+
}
94+
#multishopselector_block_home h2{
95+
color: #fff;
96+
margin: 0;
97+
font-size: 1.5em;
98+
position: relative;
99+
}
100+
#multishopselector_block_home h2 span{
101+
font-size: 0.8em;
102+
position: absolute;
103+
left: 0; bottom: -18px;
104+
}
105+
106+
.homeRadio + h2, .homeRadio + div h2{
107+
line-height: 1.2em;
108+
}
109+
110+
@media screen and (min-width: 768px){
111+
#multishopselector_block_home h2{
112+
font-size: 2em;
113+
}
114+
#multishopselector_block_home h2 span{
115+
font-size: 0.65em;
116+
bottom: -26px;
117+
}
118+
#multishopselector_block_home form select{
119+
font-size: 120%;
120+
}
121+
#multishopselector_block_home #priceCarrier span{
122+
font-size: 1em;
123+
}
124+
}
125+
126+
@media screen and (min-width: 992px){
127+
#multishopselector_block_home h2{
128+
font-size: 2.5em;
129+
}
130+
#multishopselector_block_home h2 span{
131+
font-size: 0.6em;
132+
bottom: -26px;
133+
}
134+
#multishopselector_block_home form select{
135+
font-size: 130%;
136+
}
137+
#multishopselector_block_home #priceCarrier span{
138+
font-size: 1.2em;
139+
}
140+
}
141+
142+
143+
/***************Select***************/
144+
#multishopselector_block_home form select{
145+
cursor: pointer;
146+
padding: 5px 2em 5px 10px;
147+
font-weight: bold;
148+
}
149+
.custom-dropdown--large {
150+
font-size: 1.5em;
151+
}
152+
.custom-dropdown--small {
153+
font-size: .7em;
154+
}
155+
.custom-dropdown__select{
156+
font-size: inherit; /* inherit size from .custom-dropdown*/
157+
padding: .5em; /* add some space*/
158+
margin: 0; /* remove default margins */
159+
}
160+
.custom-dropdown__select--white {
161+
background-color: #fff;
162+
color: #444;
163+
}
164+
165+
166+
167+
@supports (pointer-events: none) and
168+
((-webkit-appearance: none) or
169+
(-moz-appearance: none) or
170+
(appearance: none)) {
171+
172+
.custom-dropdown {
173+
position: relative;
174+
display: inline-block;
175+
vertical-align: middle;
176+
}
177+
178+
.custom-dropdown__select {
179+
padding-right: 2.5em; /* accommodate with the pseudo elements for the dropdown arrow */
180+
border: 0;
181+
-webkit-appearance: none;
182+
-moz-appearance: none;
183+
appearance: none;
184+
}
185+
186+
.custom-dropdown::before,
187+
.custom-dropdown::after {
188+
content: "";
189+
position: absolute;
190+
pointer-events: none;
191+
}
192+
193+
.custom-dropdown::after { /* Custom dropdown arrow */
194+
content: "\25BC";
195+
height: 1em;
196+
font-size: 1.5em;
197+
line-height: 1;
198+
right: 0.2em;
199+
top: 50%; margin-top: -.5em;
200+
}
201+
202+
.custom-dropdown::before { /* Custom dropdown arrow cover */
203+
width: 2em;
204+
right: 0; top: 0; bottom: 0;
205+
border-radius: 0 3px 3px 0;
206+
}
207+
208+
.custom-dropdown__select[disabled] {
209+
color: rgba(0,0,0,.3);
210+
}
211+
212+
.custom-dropdown.custom-dropdown--disabled::after {
213+
color: rgba(0,0,0,.1);
214+
}
215+
216+
/* White dropdown style */
217+
.custom-dropdown--white::before {
218+
top: .5em; bottom: .5em;
219+
background-color: #fff;
220+
}
221+
222+
.custom-dropdown--white::after {
223+
color: #4E82BB;
224+
}
225+
226+
/* FF only temp fix */
227+
@-moz-document url-prefix() {
228+
.custom-dropdown__select { padding-right: 2em }
229+
.custom-dropdown--large .custom-dropdown__select { padding-right: 3em }
230+
.custom-dropdown--small .custom-dropdown__select { padding-right: 1em }
231+
}
232+
}
233+
234+
#multishopselector_block_home form input{
235+
float: none;
236+
}
237+
238+
#multishopselector_block_home .separate-choose{
239+
font-size: 20px;
240+
241+
}
242+
243+
#multishopselector_block_home input[type=submit]{
244+
font-size: 1.2em;
245+
margin-top: 10%;
246+
}

img/home_logo.jpg

46.4 KB
Loading

js/scripts.js

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
(function($, window){
2+
$(document).ready(function(){
3+
//Add Class for background image
4+
$('body').addClass('homeShopSelector');
5+
//Show hidden blocks if JavaScript is activated
6+
$('#multishopselector_block_home .hideNoScript').show();
7+
//Choose the right value on the submit action.
8+
var selectChoose = $('select');
9+
$('#multishopselector_block_home form').submit(function(){
10+
if (selectChoose.length) {
11+
$(this).attr('action',$(this).find('select').val());
12+
} else {
13+
$(this).attr('action',link);
14+
}
15+
});
16+
//Place connexion block in the middle of the page
17+
function blockSelectShopCenter(){
18+
var height = $('body').innerHeight();
19+
if ( height >= 600) {
20+
height = (height - ($('.homeShopSelector .logoHome').innerHeight() + $('#multishopselector_block_home').innerHeight())) * 0.1;
21+
$('.homeShopSelector .blockCenterHome').css('marginTop',height);
22+
}
23+
};
24+
blockSelectShopCenter();
25+
$(window).resize(function(){
26+
blockSelectShopCenter();
27+
});
28+
$('.slogan_langues .menu__button').html('Connexion');
29+
});
30+
})(jQuery, window);

0 commit comments

Comments
 (0)