How can I center-align a table in the Narrative theme?

Hi, I am using Narrative theme and creating a table on an added page.

I’m having trouble with center-aligning the whole table though. If I select the table and click on center-align, it just aligns all the text within the table.
Page link: https://www.tyyli.vip/pages/interest-free-instalments

Can someone help me with this? Thanks so much!

Hi @Tyyli

  1. Go to Online Store->Themes->Edit code
  2. Asset->/theme.scss.liquid->paste below code at the bottom of the file.
.rte__table-wrapper table {
    display: table;
    margin: 0 auto;
}
1 Like

Thanks so much @Vikas_Chovatiya ! Works perfectly :slightly_smiling_face:

1 Like

Hi Vikas,

Trying to solve the same problem, appreciate you posting a solution.

Below code at the bottom of the file? Like this?

.rte__table-wrapper table {
display: table;
margin: 0 auto;
}

That did not work. Where exactly do we inset this code in the liquid file?

-Adam