check_title_files
Reads tags from local HTML files or directories and checks their rendered pixel width against Google search result limits, flagging titles likely to be truncated or violate boilerplate rules.
Instructions
Read the first element from local .html/.htm files and run the same pixel-width checks as measure_titles across all of them. Each path may be a file (read whatever its extension) or a directory; directories are searched recursively for .html and .htm files, skipping node_modules and names that start with '.', and stop with an error after 20000 files. Only the title in the document head counts; titles in comments, , and similar are ignored. Reads only, never writes. Character references & < > " ' and numeric references are decoded before measuring. Model: Google search results on google.com with the zh-TW (Traditional Chinese, Taiwan) interface, Chrome on Windows, title font Arial 22px, desktop result column 652px, mobile first line 343px, measured 2026-09-18. Full-width characters (East Asian Width W or F: CJK ideographs, kana, Hangul, full-width punctuation, most emoji) count 22px; printable ASCII uses Arial's own advance widths at 22px; other half-width characters count 12.2px; zero-width characters count 0 and each grapheme cluster (such as an emoji ZWJ sequence) counts once. Kerning is not modelled. Tiers: safe <= 572px, long > 572px (warning), edge > 630px (must fix), cut > 648px (must fix). Japanese and Korean use the same full-width assumption but were not separately measured. Google may rewrite title links, so a passing title is not a guarantee of what is displayed. Fails: tier edge or cut; more than 2 separators (、 or ,) in a title over 572px; more than 1 full-width question mark (?); a trailing phrase after the last 、 or , shared by more than 2 titles in the same call (boilerplate; a site name after a colon is not counted, as Google suggests that pattern); empty title; the same 2-4 ideograph run 3 or more times (keyword stuffing). Warnings: tier long; more than 2 separators in a title within 572px; text before the first ?:、,wider than the 343px mobile first line.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| paths | Yes | Absolute paths to HTML files or directories on this machine, e.g. a static site's build output. |