Twentig
Forum Replies Created
-
Hi Antoine,
Glad you find our plugin useful.
Twentig doesn’t include an option to change the text color. To change it, you can add the CSS code below inside the Customizer’s Additional CSS panel and change the #000 value at the end of the code with your value:
body, input, textarea, .entry-title a, :root .has-primary-color, .header-footer-group, body:not(.overlay-header) #site-header .toggle, .menu-modal .toggle, .site-description, body:not(.overlay-header) .toggle-inner .toggle-text, .widget .post-date, .widget .rss-date, .widget_archive li, .widget_categories li, .widget cite, .widget_pages li, .widget_meta li, .widget_nav_menu li, .powered-by-wordpress, .to-the-top, .singular .entry-header .post-meta, .singular:not(.overlay-header) .entry-header .post-meta a, cite, figcaption, .wp-caption-text, .post-meta, .entry-content .wp-block-archives li, .entry-content .wp-block-categories li, .entry-content .wp-block-latest-posts li, .wp-block-latest-posts__post-date, .wp-block-embed figcaption, .wp-block-image figcaption, .wp-block-pullquote cite, .comment-metadata, .comment-respond .comment-notes, .pagination .dots { color: #000; }That’s a lot of code, but that’s how Twenty Twenty was coded.
Have a nice day.
If you enjoy Twentig, please leave us a review 🙂Hi @soapwhip,
To use Twentig, you don’t need to install the Gutenberg plugin. You just need to use the latest WordPress version (5.5.3) that includes the block editor (codename Gutenberg) and activate the Twenty Twenty theme. To get you started, you can check https://wordpress.org/plugins/twentig/#installation and the Twentig overview page that you’ll see inside your WordPress dashboard.
I hope the above is useful to you,
Have a nice day.Hi @vvpacc,
Great! Have a nice day.Hi Raul,
Thanks for the suggestion. We’ll see if we can add an option that allows CPT to inherit the blog options. Currently, Twentig doesn’t apply the blog Customizer options to CPT to not interfere with the design of third-party plugins.
To apply the grid layout to all your CPT, you can add the following PHP code in your functions.php file:
function my_custom_body_class( $classes ) { if ( is_post_type_archive() ) { $blog_layout = get_theme_mod( 'twentig_blog_layout' ); $classes[] = 'tw-blog-' . $blog_layout; if ( 'grid-basic' === $blog_layout || 'grid-card' === $blog_layout ) { $classes[] = 'tw-blog-grid'; $classes[] = 'tw-blog-columns-' . get_theme_mod( 'twentig_blog_columns', '3' ); add_filter( 'post_thumbnail_size', function() { return 'large'; } ); } } return $classes; } add_filter( 'body_class', 'my_custom_body_class', 12 );I hope the above is useful to you,
If you enjoy Twentig, please leave us a review 🙂Hi @vvpacc,
Thanks for your message. When the user scrolls down, Twentig applies an “opaque” class to the body (using some JavaScript code) so that the header content can still be visible. To keep the header always transparent, you can add the CSS code below inside the Customizer’s Additional CSS panel:
.overlay-header.has-header-opaque #site-header { background-color: transparent; border-color: transparent; box-shadow: none; } .overlay-header.has-header-opaque #site-header .header-inner, .overlay-header.has-header-opaque #site-header .header-inner * { color: #fff; } .overlay-header.has-header-opaque .logo-primary { visibility: hidden; } .overlay-header.has-header-opaque .logo-primary + .logo-transparent { visibility: visible; opacity: 1; }I hope the above is useful to you,
If you enjoy Twentig, please leave us a review 🙂Hi Léo,
The image’s width is limited to 300px because the sizes attribute was changed to 300px following your previous ticket.
Replace the previous PHP code in your child theme with the code below. It changes the size attribute to 300px only when the image alignment is set to left of right.
function your_custom_change_latest_posts_image_sizes( $block_content, $block ) { if ( 'core/latest-posts' === $block['blockName'] ) { $image = $block['attrs'] && isset( $block['attrs']['displayFeaturedImage'] ) ? $block['attrs']['displayFeaturedImage'] : 0; $image_align = $block['attrs'] && isset( $block['attrs']['featuredImageAlign'] ) ? $block['attrs']['featuredImageAlign'] : ''; if ( $image && ( 'left' == $image_align || 'right' == $image_align ) ) { $sizes = '(max-width: 300px) 100vw, 300px'; return preg_replace( '/sizes="([^>]+?)"/', 'sizes="' . $sizes . '"', $block_content ); } } return $block_content; } add_filter( 'render_block', 'your_custom_change_latest_posts_image_sizes', 20, 2 );I hope the above is useful to you,
Have a nice day.Hi @adamromanowski,
Thanks for your message, it’s greatly appreciated.
We understand that the “no columns stacking” feature could be useful. However, it’s difficult to implement it as the WordPress core style uses
!importantto set the columns width to 100% on mobile.@media (max-width: 599px) { .wp-block-column { flex-basis: 100%!important; } }We’ll see if we can find a solution. It’s only CSS code, so if you have an idea to override it, please share 🙂. Note that the WordPress 5.6 version (to be released in December) will include the user’s possibility to choose the unit (%, px, em, rem, vw) for the column width, so we also need to take that into account.
Concerning Github, thanks for the suggestion. We’ll add it to our roadmap.
Have a nice day.
If you enjoy Twentig, please leave us a review 🙂@thenikos, Great!
If you enjoy Twentig, please leave us a review 🙂Hi @thenikos,
To reduce the height of the header, you can add some custom CSS to modify its padding. Inside the Customizer, open the Additional CSS panel and paste the following code (adjust the 2rem value as you like):
.header-inner { padding: 2rem 0; }I hope the above is useful to you,
Have a nice day.Hi @sarxax,
To fix the issue, you can try to refresh your permalinks:
- login to your WordPress dashboard
- navigate to Settings > Permalinks
- click Save Changes
Please let us know if this works.
Have a nice day.The default body font stack is: “Hoefler Text”, Garamond, “Times New Roman”, serif.
Here’s the link for the review.Thanks 🙂
Have a nice day.Hi,
Glad you like our plugin.
By default, the Twenty Twenty theme uses Inter as the heading font and a Serif font-stack for the body. If you want to reset to the default fonts (Customizer > Twentig > Fonts), you can choose the first preset (Inter/Serif) or select “Default Theme Font” for the Heading Font and Body Font options.I hope the above is useful to you.
If you enjoy Twentig, please leave us a review 🙂Hi,
Thanks for your message.
Assuming that you’ve created your own plugin or child theme (to create your CPT), you can add the following PHP code in one of your PHP files. Replace
'post_type'with your post type name.function my_custom_body_class( $classes ) { if ( is_singular( 'post_type' ) ) { $cover_height = get_theme_mod( 'twentig_cover_post_height' ); if ( $cover_height ) { $classes[] = 'tw-cover-' . $cover_height; } if ( 'center' === get_theme_mod( 'twentig_cover_vertical_align' ) ) { $classes[] = 'tw-cover-center'; } } return $classes; } add_filter( 'body_class', 'my_custom_body_class', 12 );I hope the above is useful to you.
If you enjoy Twentig, please leave us a review 🙂Thanks for the review 🙂
To set a full-width image on top and text below, you need to add the following CSS code inside the Customizer’s Additional CSS panel:
@media(max-width: 599px) { .wp-block-latest-posts .wp-block-latest-posts__featured-image.alignleft { max-width: 100%; margin: 0 0 3rem; } .wp-block-latest-posts .wp-block-latest-posts__featured-image.alignleft ~ * { width: 100%; } }We’ll see if we add this to our plugin’s roadmap.
I hope the above is useful to you,
Have a nice day.Hi @stalkerxxl,
Thanks for your message.
Concerning the Latest Posts block on mobile, how would you like to arrange the layout, a small left-aligned image on top and text below, or a full-width image on top and text below?
If you enjoy Twentig, please leave us a review 🙂