I have just become familiar with the repeater items in hubspot and set up a page with some custom modules using this functionality. My issue is that how can i ensure it is responsive. I would like to have 2 modules side by side when viewing on a desktop and then reduce to 1 module across when viewing on smaller screen. I have provided a link to the page below.
Thanks for your reply. I understand that I can change the width 100%, 50%, 33% and 25% to change the number of modules across to respectively 1,2,3 and 4. I was using this technique with media queries to control responsiveness before. However this fixes the custom module to a certain number across. So I will then need to create different custom modules for 1,2,3 or 4 across. I thought the purpose of the repeater functionality was to create more flexible. E.g I can create one custom module that can be 1,2,3 or 4 across, but if I specify the width (e.g 50%) I then I lose this flexibility as it will need a module with a maximum of 2 across.
Am I missing something. Can I create a custom module which uses the repeater functionality to create flexible but also allows for responsiveness with media queries?
If i am understanding your question correctly, you are saying that sometime you will want to have two across, sometime four etc.
so
row 1 has 2 items
row 2 has has 4 items
you could add a choice field in the module with the possible numbers and have the value be added as a class to member-repeater-wrapper. then add styles for each if the classes.
Is there a way to create a min-width to the custom module. So when the custom modules get to a certain width (regardless if they are 1, 2, 3, or 4 across) they are then pushed down to the next level. I have tried doing this without success.
Sorry for all my questions, i just feel that this is really important to grasp. I will probably be using his techique quite a lot across the website.
i'll try explaining with an example. say i set the custom module with a min-width to 400px and i add 3 repeater modules, so 3 modules will be side by. If the screen width is larger than 1200px, there will still be 3 in a row. between 1200px and 800px there will be 2 and below 800px there will be 1 in a row.
If you think this wont work, then could you explain in a bit more detail how i would achieve this with your first suggestion above. Apologises and i thank you for your time. it is apreciated!
you had a contradiction in that last message. you say at 400px you want 3, but you also say below 800px you want 1. if the 400px was a mistake, this would be the css
400px is the width of the module, not the screen. So if the screen width is between 400-799px there will only be enough room for 1 module. If the screen size is between 800-1199 then there will only be enough room for 2 modules in a row. If the screen size is larger 1200px, then at least 3 modules can fit in a row.
so can I use min width in this way to make the module responsive?