WP Manifestindependent plugin directory
manifest / themes / tt4-tweaks

TT4 Tweaks

This plugin tweaks various things in the Twenty Twenty-Four theme. Mainly the way the theme displays images on mobile.

★ 0stars

Install

Download source zip No release zip yet

This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.

Install straight from GitHub with WP-CLI:

wp plugin install https://github.com/carlosinho/tt4-tweaks/archive/refs/heads/main.zip
No built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.

A WordPress plugin designed to tweak aspects of the Twenty Twenty-Four theme. Currently, it improves the display of images aligned "left" or "right" in post and page content on narrow screens.

Features

  • Mobile image alignment fix:
    • At viewport widths of 600px or less, images aligned "left" or "right" are changed from floated images to full-width, block-level images.
    • Supports Gutenberg image blocks and classic editor images inside .wp-block-post-content and .entry-content containers.
    • Has no effect at viewport widths greater than 600px.

Why?

By default, images aligned left or right can appear awkwardly on narrow screens, often floating with text wrapping beside them. This plugin removes the float, expands the image to the width of its content container, and places surrounding text below it.

Installation

  1. Download or clone this repository into your WordPress plugins directory:
    git clone https://github.com/carlosinho/tt4-tweaks.git wp-content/plugins/tt4-tweaks
  2. Activate the plugin from the WordPress admin panel.

Usage

  • No configuration is needed. Once activated, the plugin automatically applies the image alignment rules on the WordPress front end.
  • To customize the mobile breakpoint or tweak the CSS, edit css/tt4-tweaks.css.

Compatibility

  • Designed for the Twenty Twenty-Four theme, but the plugin does not check which theme is active.
  • The CSS and a currently empty JavaScript file are enqueued on every front-end page. The CSS can therefore affect other themes that use the targeted WordPress classes.
  • Classic editor images are supported when the alignment class is applied directly to the image. Caption markup that applies alignment only to a surrounding .wp-caption element is not explicitly handled.

License

GPL-2.0

Author

Karol K