Install
openclaw skills install @j3ffyang/resize-for-bannerRescale an image into social banner versions using ImageMagick. The image is resized to fit and the leftover space is padded black — never cropped. Use when the user wants a banner, cover photo, or resized version for a social profile or article header. Never overwrites the original — creates new files beside it. Defaults to Twitter/X (5:2, 1500x600); other platforms available on request.
openclaw skills install @j3ffyang/resize-for-bannerTurn one image into social banner variants with ImageMagick, keeping the original file untouched and writing new files beside it. The image is rescaled to fit and black-padded, never cropped, so no content is lost.
| Platform | Ratio | Dimensions | Notes |
|---|---|---|---|
| Twitter / X | 5:2 | 1500x600 | Header photo. Default. |
| LinkedIn article | 16:9 | 1200x675 | Article header. Usually unnecessary — generated infographics are already 16:9. |
| YouTube channel | 16:9 | 2560x1440 | Channel art; safe area is 1546x423 center. |
| Blog / generic | any | any WxH | Custom dimensions on request. |
If the user does not specify a platform, default to Twitter (1500x600).
source — Path to the original image, e.g. ai-thoughts/imgs/260806-1656.png. Required.sizes — Which banners to produce. Default: Twitter 1500x600. User may request any platform from the specs table or custom dimensions.imgs/<base>-banner-<platform>.png — e.g. 260806-1656-banner-twitter.png.<base> keeps the original filename exactly. The original file is never modified.Confirm the plan with the user: source image, target size(s), output filename(s). Get a go-ahead before writing files.
Check the original dimensions with magick identify "<source>" so you can predict which axis will be padded.
Resize to fit, then pad with black with ImageMagick 7 magick:
magick <source> -resize "<W>x<H>" -background black -gravity center \
-extent <W>x<H> imgs/<base>-banner-<platform>.png
-resize "WxH" (no bang) scales to fit inside the box, preserving the
aspect ratio — the image is never distorted or cropped.-extent WxH then pads the leftover space; -background black makes the
padding dark and -gravity center centers the image.Verify every output with identify — dimensions must match the target size exactly.
Report the output paths and confirm the original is untouched (git status shows the new files as untracked, the original unmodified).
identify reports exactly the target dimensions for each output.identify output / git status).imgs/ and ask which to use.magick is always installed on the user's machines — skip checking for it and run the commands directly.