=== BW Pretty Post Link === Contributors: bowdenworks Author URI: https://bowdenworks.com Tags: block, gutenberg, links, post list, thumbnail Requires at least: 6.3 Tested up to: 6.7 Requires PHP: 7.4 Stable tag: 1.0.0 License: GPLv2 or later License URI: https://www.gnu.org/licenses/gpl-2.0.html A Gutenberg block for outputting a clean list of post links — internal (any post type) or external — with optional thumbnails. == Description == BW Pretty Post Link adds a container block ("Pretty Post Link List") that holds one or more link items. Each item can be: * **Internal** — pick any public post type, search for the post, and optionally override the title and thumbnail. Defaults come from the post title and featured image. * **External** — enter a title, URL (opens in a new tab), and select/upload a thumbnail from the Media Library. Two display layouts are included: * **Simple** — plain bulleted list of text links. No thumbnails. * **Thumbnail** — stacked rows, each with a 16:9 thumbnail on the left and the title on the right. The thumbnail width is adjustable (10–60%, default 20%). == Installation == 1. Upload the `bw-pretty-post-link` folder to `/wp-content/plugins/`. 2. Activate through the 'Plugins' menu in WordPress. 3. In any page or post, add the **Pretty Post Link List** block, choose a layout, then add items inside it. == Usage == 1. Insert the **Pretty Post Link List** block. 2. In the block sidebar, choose the display style (Simple or Thumbnail). If Thumbnail, adjust the thumbnail width percentage. 3. Use the "+" button inside the list to add items. 4. For each item, open the sidebar and set: - **Link Type**: Internal or External. - If Internal: select a Post Type, search for and choose the post. Optionally set a Custom Title and Custom Thumbnail (both fall back to the post's defaults). - If External: enter Title, Link URL, and pick a Thumbnail. == Frequently Asked Questions == = Does it support custom post types? = Yes. The Internal link type lets you pick any public post type (anything registered with `public => true` and not a built-in blocks/templates type). = What happens if an internal post is unpublished? = The item is silently omitted from the frontend list. No broken links. = Where do external thumbnails come from? = The WordPress Media Library. The thumbnail picker lets you select an existing attachment or upload a new one on the spot. = Can I change the thumbnail aspect ratio? = Not through the UI — it's fixed at 16:9 by design. You can override in your theme CSS by targeting `.bw-ppl--thumbnail .bw-ppl__thumb-wrap { aspect-ratio: 4 / 3; }` (or any ratio you prefer). = Can I use this in the Site Editor / FSE templates? = Yes. The block is registered in the Widgets category and can be inserted anywhere blocks are allowed, including template parts. == Changelog == = 1.0.0 = * Initial release. * Two blocks: `bw/pretty-post-link-list` (parent) and `bw/pretty-post-link-item` (child). * Internal and External link types. * Simple and Thumbnail layouts with adjustable thumb width. * Server-rendered (dynamic) blocks — post titles, URLs, and featured images stay in sync if they change on the source post.