DSS5
August 22, 2023, 10:28am
1
Hi Guys, can someone help me to adjust table size as per the screen (desktop and mobile). I create a page and link it in footer ‘size guide’ for sizing details but In mobile view its wider, and in desktop it’s smaller (refer screen shot below). how can i adjust(align) this table with the text below which works with mobile and desktop perfectly?
URL - https://deshoeshop.com
any help please?
Hi @DSS5
Follow these Steps:
Go to Online Store
Edit Code
Find theme.liquid file
Add the following code in the bottom of the file above tag
Hello @jasa11
Its Artzen Technologies! We will be happy to help you today.
In your Shopify Admin go to online store > themes > actions > edit code
Find Asset > theme.css and paste this at the bottom of the file:
@media screen and (min-width: 990px){
.page-width.page-width--narrow {
max-width: 95.6rem;
}
}
@media screen and (max-width: 500px) {
.rte.scroll-trigger .tg {
table-layout: unset!important;
}
.rte.scroll-trigger .tg td {
padding: 9px 10px;
}
.rte.scroll-trigger .tg .tg-3plc {
font-size: 11px;
}
.rte.scroll-trigger .tg .tg-ua6r {
font-size: 11px;
}
.rte.scroll-trigger .tg .tg-jm7y {
font-size: 11px;
}
}
after that :–
desktop view
mobile view
Let me know if need further assistance
Regards,
Artzen Technologies
DSS5
August 23, 2023, 8:32am
4
Hi after using code above. desktop view is good but not for mobile view. see screenshot please. any advise here. thanks
@DSS5
Please use this css code
@media only screen and (max-width: 600px) {
table.tg {
width: auto;
}
}
Hello @DSS5
Its Artzen Technologies! We will be happy to help you today.
In your Shopify Admin go to online store > themes > actions > edit code
Find Asset > theme.css and paste this at the bottom of the file:
@media screen and (min-width: 990px){
.page-width.page-width--narrow {
max-width: 95.6rem;
}
}
@media screen and (max-width: 500px) {
.rte.scroll-trigger .tg {
table-layout: unset!important;
}
.rte.scroll-trigger .tg td {
padding: 9px 10px;
}
.rte.scroll-trigger .tg .tg-3plc {
font-size: 11px;
}
.rte.scroll-trigger .tg .tg-ua6r {
font-size: 11px;
}
.rte.scroll-trigger .tg .tg-jm7y {
font-size: 11px;
}
}
Copy
after that :–
desktop view
mobile view
Let me know if need further assistance
Regards,
Artzen Technologies
DSS5
August 23, 2023, 10:49am
7
sorry mate, not working. i add this code at the bottom of base.css but not working. thanks
DSS5
August 23, 2023, 10:51am
8
hi mate, thanks for your help but i don’t have theme.css, so tried base.css and it is not working in it. not sure why but not working.