Bonjour,
Alors oui, mais là, c'est parce que vous avez du CSS personnalisé dans tous les sens entre le template, un plugin système et vos personnalisations pour passer les champs en 2 colonnes.
Donc je ne pense pas que nous pouvons faire grand chose dans HikaShop pour éviter cela.
Là, il va falloir rajouter du CSS custom pour gérer tout cela comme il faut avec le nouveau système d'HikaShop, en tenant en compte le résultat que vous voulez, et le CSS custom déjà présent.
Par exemple, quelque chose comme cela:
/* Fix HikaShop Layout - Side-by-Side */
.hkform-group {
display: flex !important;
flex-wrap: nowrap !important; /* Keep on same line */
align-items: center !important;
}
.hkform-group > label,
.hkform-group .control-label {
flex: 0 0 120px !important; /* Fixed width */
width: 120px !important;
min-width: 120px !important;
white-space: normal !important;
margin-right: 15px !important;
}
/* Allow input to shrink/grow */
.hkform-group .controls,
.hkform-group input,
.hkform-group select {
flex: 1 1 auto !important;
width: auto !important;
min-width: 0 !important; /* Allow shrinking */
}
.hkform-group {
display: flex !important;
flex-wrap: nowrap !important;
align-items: center !important;
/* Handle spacing and width correctly */
box-sizing: border-box !important;
padding-right: 20px !important; /* Creates space between Col 1 Input and Col 2 Label */
}
/* Ensure absolute safety for inputs */
.hkform-group input,
.hkform-group select,
.hkform-group .controls {
max-width: 100% !important;
box-sizing: border-box !important;
}
/* --- Fix 1: Country Selector (Chosen) --- */
/* Force Chosen container to be responsive within the flex item */
.hkform-group .chzn-container {
width: 100% !important;
max-width: 100% !important;
min-width: 0 !important; /* Allow shrinking if needed */
}
.hkform-group .chzn-drop {
width: 100% !important; /* Ensure dropdown matches container width */
box-sizing: border-box !important;
}
/* --- Fix 2: "Same Address" Checkbox --- */
/* Reset flex behavior specifically for the checkbox line */
.hikashop_registration_same_address_line {
display: block !important; /* Stop trying to be a flex row with restricted columns */
width: 100% !important;
clear: both !important;
margin-top: 10px !important;
}
/* Hide the empty label column if it's taking up space */
.hikashop_registration_same_address_line .hkcontrol-label {
display: none !important;
}
/* Ensure the checkbox container takes full width */
.hikashop_registration_same_address_line > div:not(.hkcontrol-label) {
width: 100% !important;
display: block !important;
padding-left: 0 !important;
}
/* Style the checkbox and label to sit nicely together */
.hikashop_registration_same_address_line input[type="checkbox"] {
display: inline-block !important;
width: auto !important;
margin-right: 8px !important;
float: none !important; /* Remove any float interference */
vertical-align: middle !important;
}
.hikashop_registration_same_address_line label {
display: inline-block !important;
width: auto !important;
max-width: none !important; /* Prevent squashing */
float: none !important;
min-width: 0 !important; /* Override the 160px from previous rule */
vertical-align: middle !important;
margin: 0 !important;
}