Page 1 of 1

MATC alignment

Posted: Sun Feb 25, 2024 6:52 pm
by tessthepup
Hi guys,

This particular problem has been bugging me for quite a while and I am stumped now how to resove it.

The issue is the alignment of the MATC (see image). This is the closest I can get it to center align on the page.

No matter how many columns I set the width to and it is driving me nuts lol

A little help will save my sanity and my ocd :o

Code: Select all

<div class="col-5 mx-auto">
   <div class="form-group row align-items-center d-flex justify-content-center">
    <div class="col-form-label text-left text-sm-right"><?= ENTRY_MATC ?></div>
    <div class="pl-5 custom-control custom-switch">
      <?= $input->set('id', 'inputMATC') ?>
      <label for="inputMATC" class="custom-control-label text-muted"><small><?= ENTRY_MATC_TEXT ?></small></label>
    </div>
  </div>
</div>

Re: MATC alignment

Posted: Mon Feb 26, 2024 8:26 am
by heatherbell
A quick look at your site with Dev Tools shows the MATC is centred in the div class row (that wraps the div class col-sm-10 mt-4).
That needs justify-content-center adding to class.
Then there are all the unused labels for each row that are col-sm-3 that throw the alignment to the right.
Remove them and everything should then centre.
You might want to then adjust the width of the div class col-sm-10 mt-4 and all the div class col-sm-9 (that wrap the inputs) as required.

Re: MATC alignment

Posted: Mon Feb 26, 2024 7:40 pm
by tessthepup
heatherbell wrote: Mon Feb 26, 2024 8:26 am A quick look at your site with Dev Tools shows the MATC is centred in the div class row (that wraps the div class col-sm-10 mt-4).
That needs justify-content-center adding to class.
Then there are all the unused labels for each row that are col-sm-3 that throw the alignment to the right.
Remove them and everything should then centre.
You might want to then adjust the width of the div class col-sm-10 mt-4 and all the div class col-sm-9 (that wrap the inputs) as required.
@heatherbell

Thank you very much for the help. After quite a bit of fiddling I managed to get it centered.

Re: MATC alignment

Posted: Mon Jul 15, 2024 8:39 pm
by LeeFoster
@tessthepup any chance you can help me? I'm currently setting up a 1.0.9.4 store and can't find any MATC for the registration page. Is it a hook like it used to be or a module now?

Re: MATC alignment

Posted: Tue Jul 16, 2024 4:13 am
by heatherbell
LeeFoster wrote: Mon Jul 15, 2024 8:39 pmMATC for the registration page.
Admin>Modules>Customer Data

Re: MATC alignment

Posted: Tue Jul 16, 2024 8:21 am
by tessthepup
LeeFoster wrote: Mon Jul 15, 2024 8:39 pm @tessthepup any chance you can help me? I'm currently setting up a 1.0.9.4 store and can't find any MATC for the registration page. Is it a hook like it used to be or a module now?
Hi Lee, did you get sorted using @heatherbell suggestion?

Re: MATC alignment

Posted: Tue Jul 16, 2024 10:28 am
by LeeFoster
tessthepup wrote: Tue Jul 16, 2024 8:21 am
LeeFoster wrote: Mon Jul 15, 2024 8:39 pm @tessthepup any chance you can help me? I'm currently setting up a 1.0.9.4 store and can't find any MATC for the registration page. Is it a hook like it used to be or a module now?
Hi Lee, did you get sorted using @heatherbell suggestion?
Yes I did, thank you both