Tagged: column radius round
-
AuthorPosts
-
January 23, 2023 at 10:31 am #1394752
Hy Team
Can I set the column so that the frame is always displayed as a circle (not as an oval)?Thanks for feedback
January 23, 2023 at 5:40 pm #1394817Hey zpl-limmattal,
Please try the following in Quick CSS under Enfold->General Styling:
.home #av_section_1 .sc-av_one_third { height: 360px; }
Best regards,
RikardJanuary 23, 2023 at 8:38 pm #1394845Hi, Rikard.
Thanks for the css code.
However, the circles warp as the screen gets smaller and also overlap.
The result is not satisfactory.
Is there another solution?January 24, 2023 at 6:51 am #1394868Hi,
Thank you for the update.
Please remove the previous css, then add the following code in the functions.php file. This should dynamically adjust the height of the columns based on their width.
//-------------------------------------------------------------- // adjust the height of the columns //-------------------------------------------------------------- add_action('wp_footer', 'ava_custom_script'); function ava_custom_script(){ ?> <script type="text/javascript"> (function($) { $(window).on("debouncedresize", function() { $(".sc-av_one_third").each(function() { var column = $(this).find(".av_one_third"); var width = column.width(); column.height(width); }); }); })(jQuery); </script> <?php }
Best regards,
IsmaelJanuary 25, 2023 at 9:13 am #1395091thank you, but the column is no longer visible as a circle but only as an oval.
Kind regards
January 25, 2023 at 12:20 pm #1395130Hi,
Please try this function instead:function make_column_height_equal_to_width() { ?> <script> window.addEventListener('DOMContentLoaded', function() { (function($) { $(window).on("debouncedresize", function() { $(".sc-av_one_third").each(function() { var column = $(this).find(".av_one_third"); var width = column.width(); column.height(width); }); }); })(jQuery); }); </script> <?php } add_action('wp_footer', 'make_column_height_equal_to_width');
Please ensure to copy the code from the forum and not an email notification so the symbols are not converted.
If this doesn’t help please include an admin login in the Private Content area so we can be of more assistance.Best regards,
MikeJanuary 26, 2023 at 11:49 am #1395356Hi Mike,
thank you very much, that works now.
Only in the smartphone display the circles are too big and the text is not in the middle but at the top.
Can this still be solved?
Thanks, happy Day
BonnieLogin Admin: Access to the stating page in the private area
January 26, 2023 at 6:29 pm #1395432Hi,
To center the content in the 1/3 columns on mobile try this css:@media only screen and (max-width: 767px) { .responsive #top .sc-av_one_third .flex_column_table_cell.av_one_third{ display: flex; justify-content: center; flex-direction: column; } }
After applying the css, please clear your browser cache and check.
Also please check the other pages on your site to ensure that this css and the custom script to make the columns have equal height and width is not causing any issues elsewhere, if so I recommend adding a custom class to these round elements on your homepage. Is this the only place you are going to use them or do you plan on using them also on other pages?
As for their size, on mobile columns are set to be full-width, if you want them smaller we can assist but how much smaller do you want them to be?Best regards,
MikeJanuary 26, 2023 at 8:24 pm #1395449Hi Mike,
I have applied the CSS, deleted the browser’s cache.
I have language versions and for FR and IT the text in the circle is not centred on the smartphone.
Can you add me a custom class for the round elements?.
For now this is the only place for the round columns.
Reduce size on mobile by 1/3, is that possible?
Thank you very much.January 27, 2023 at 12:19 am #1395475Hi,
I added the custom class onethirdcircle to the three circles in all three languages and then adjusted the script to look for this class.
I then added this css in the Enfold Theme Options ▸ General Styling ▸ Quick CSS field for all three languages to center the text on mobile and cleared your cache for each language:@media only screen and (max-width: 767px) { .responsive #top .sc-av_one_third .flex_column_table_cell.onethirdcircle { display: flex; justify-content: center; flex-direction: column; } }
Then to reduce the size of the circles and center them horizontally for mobile I added this css in the Enfold Theme Options ▸ General Styling ▸ Quick CSS field for all three languages to center the text on mobile and cleared your cache for each language:
@media only screen and (max-width: 767px) { .responsive #top .sc-av_one_third .flex_column_table_cell.onethirdcircle { max-width: 300px; margin: auto !important; } }
In my tests this is the smallest that you can use in all three languages and still have it look good based on the words, is some languages the words are too long without a break so it doesn’t fit in the circle well. Perhaps if you made the font smaller you could have a smaller circle but then would the text easily be readable?
You can test further if you like, please clear your mobile browser cache and check.
Please see the screenshot in the Private Content area of the mobile results.Best regards,
MikeJanuary 27, 2023 at 7:32 am #1395526Hi Mike,
Thank you very much.
I find the solution very suitable.
and will be happy to implement it in the live version.Our chat is now closed.
Happy Friday,
Kind regards, BonnieJanuary 27, 2023 at 7:53 am #1395529 -
AuthorPosts
- The topic ‘frame as circle’ is closed to new replies.