Repository navigation
docs(rules): search-first rewrite, security, integrity, crawl, url, links, images, content, eeat, seo, mobile, social, video, legal, i18n, analytics, adblock, gaps - #315
Merged
Conversation
3 of 4 tasks
added 15 commits
September 10, 2026 12:28
Rewrite all 16 security rule pages and the category index to the template in docs/rules/a11y/aria-labels.mdx: searchable title, what the term is, the exact checks and report messages read from packages/rules/src/security, the fix, related rules, verified references and the audit CTA. Source corrections where the generated page was wrong: - http-to-https: the options table listed sampleLimit as type "unknown" with default "undefined". The zod schema is an integer 1..100 defaulting to 20. - http-to-https: the config example used [rules."security/http-to-https"]. The config key is [rule_options."<rule id>"], per docs/configuration. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
Corrections against the rule source and the specs: - sri: empty integrity="" is flagged too; crossorigin is required for a cross-origin classic script, not universally. - cookie-flags: SameSite= with an empty value counts as undeclared; the rule only reads Set-Cookie response headers, never JS-written cookies. - csp: script-src falls back to default-src when empty, not only when absent; 'unsafe-inline' is ignored when a nonce or hash is present. - form-captcha: reCAPTCHA v3 never interrupts; FormShield detection is host- and path-anchored. - form-https: pass needs a collected action/formaction; a relative action resolves against the document base URL, which <base href> can change. - hsts: the preload token is consent, not enrolment. - http-to-https: the 20s budget stops new probes; in-flight ones still finish. - mixed-content: srcset/picture and IP-literal hosts are blocked, not upgraded. - permissions-policy: cross-origin frames need iframe allow delegation. - referrer-policy: same-origin also drops the cross-origin referrer. - third-party-cookies: unknown pixel hosts warn too, hostname comparison is a substring test, relative URLs are skipped, and browser/consent claims corrected. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
Rewrite all 9 integrity rule pages and the category index to the template in docs/rules/a11y/aria-labels.mdx. Checks, messages, thresholds and the two-signal correlation gate read from packages/rules/src/integrity. Source corrections where the generated page was wrong: - orphan-page, template-discontinuity: the option tables and config examples are now the real zod defaults (minPages 3 and 4, similarityThreshold 0.2) under [rule_options."<rule id>"], not [rules."<rule id>"]. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
Rewrite all 20 crawl rule pages and the category index to the template in docs/rules/a11y/aria-labels.mdx. Checks, messages, thresholds and skip wording read from packages/rules/src/crawl. Also applies the codex findings on the integrity pages: obfuscated-script measures UTF-16 code units not bytes and accepts an empty src; the fake-auth src pattern omits "credential"; seo-doorway prints density only when stuffed; kit-signature reports pattern identifiers, and the bundled signature is "Calendly phishing kit" with strings calendly_brand and google_auth_overlay; URLhaus and ThreatFox take an abuse.ch Auth-Key rather than being keyless; template-discontinuity tallies markers at max(2, ceil(n/2)) rather than clustering, and chrome similarity is a boolean average. Source corrections where the generated page was wrong: - crawl/pdf-size: the index card said a 64MB Googlebot limit. The rule's default error threshold is 60MB. - crawl/html-size and crawl/pdf-size: the messages name 2MB and 60MB "Googlebot limits". Google documents a 15MB fetch limit for HTML and text-based files and publishes no PDF figure, so the pages present both numbers as squirrel's own configurable defaults. - Option tables and config examples now carry the real zod defaults under [rule_options."<rule id>"], not [rules."<rule id>"] with undefined values. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
Rewrite all 9 url rule pages and the category index to the template in docs/rules/a11y/aria-labels.mdx, from packages/rules/src/url. Also applies the codex findings on the crawl pages. The important one corrects my own previous commit: Google does not document a 15MB limit for HTML any more. Since March 2026 Googlebot fetches at most 2MB from any individual non-PDF URL, headers included, and 64MB for a PDF, with referenced resources on their own per-URL counters. So crawl/html-size's 2MB default matches Google exactly, and crawl/pdf-size's 60MB default sits just under Google's 64MB. Both pages now cite the March 2026 crawler post. Other crawl corrections: - indexability-conflicts described the wrong second bucket. It detects blocked-without-noindex, not blocked-with-noindex, and allow + noindex is the combination that works rather than a redundancy. - schema-noindex-conflict counts a fixed 16-type list that includes Organization and HowTo and excludes WebPage. - redirect-chain counts chain entries including the final response, so two redirects report as three hops; the nginx example does not normalise slashes. - sitemap-domain: cross-submission is allowed with verified ownership or a robots.txt reference, so the host comparison can flag a legitimate setup. - sitemap-valid and sitemap-exists: the no-sitemap branches are gated on there being no reportable robots.txt fetch failure. - indexability: the "via unknown" wording is unreachable. - html-size: a script[type=application/json] cannot load an external file. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
Rewrite all 15 links rule pages and the category index to the template in docs/rules/a11y/aria-labels.mdx, from packages/rules/src/links. The cloud Note and the non-standard enable/disable block on links/dead-links are preserved verbatim. Also applies the codex findings on the url pages: - trailing-slash: the "File URL has trailing slash" warn branch is unreachable, because the extension test anchors to the end of the path. - slug-convention: suppression is unconditional and reads the URL characters, not whether the owning rule ran; the deferral tail is "(deferred to separator -> url/hyphens)"; a snake_case deviation is always suppressed so it cannot appear as an item; there is a separate "No pages available for analysis" skip. - slug-keywords: the short-ID test rejects any two consecutive vowels. - lowercase: an nginx rewrite that re-emits the captured path preserves case and loops; the destination has to be lowercased first. - parameters: a tracking variant canonicalizes to the clean URL, not to itself, and page=2 keeps its own canonical. - hyphens, special-chars: softened claims about lost link equity and about percent-encoding being mangled. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
Rewrite all 15 images rule pages and the category index to the template in docs/rules/a11y/aria-labels.mdx, from packages/rules/src/images. Also applies the codex findings on the links pages: - anchor-text: isGeneric reads textContent only, so a Read more link with a descriptive aria-label is still reported; grouping by destination is squirrel's heuristic, not how assistive technology names links. - invalid-links: empty hrefs and non-HTTP schemes are skipped by the extractor, so javascript:void(0) is not what this rule counts, and the "Invalid format" fallback label is unreachable. - tel-mailto: RFC 3966 permits visual separators; the mismatch trigger needs three consecutive digits; only an empty recipient followed by ? skips validation; the trunk-prefix match needs a 5-digit shared suffix and a 2 or 3 digit calling code. - redirect-chains: didRedirect also compares request targets; single-hop labels carry no status codes. - no-contextual-inbound: chrome is an ancestor-element test, not a repetition test. - dead-links: the checker does HEAD then GET and follows redirects; dead-link checking is in the base charge and raises no separate spend prompt. - broken-external-links, https-downgrade, weak-internal-links: softened claims about WAF 403s, 503 Retry-After, downgrade inevitability and guaranteed crawling. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
Rewrite all 22 content rule pages and the category index to the template in docs/rules/a11y/aria-labels.mdx, from packages/rules/src/content. The disabled-by-default Note and Default row on content/quality and the option table on content/hidden-text are preserved. Also applies the codex findings on the images pages: the loading attribute tests are exact-value tests so an empty or misspelled value counts as missing; modern-format needs the leading dot so ?format=webp does not match and legacy extensions are only counted on img src; picture sources may carry width and height; srcset also has a density form where sizes does not apply; filename-quality matches leading-prefix patterns rather than exact hashes; figure-figcaption emits at most one check and optimized at most four; and several softened claims about alt requirements, aspect-ratio distortion and object-fit. Note for the reference index: packages/rules/src/content/article-toc.ts (content/article-toc) has no page under docs/rules/content, so it is outside this rewrite. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
Rewrite all 15 eeat rule pages and the category index to the template in docs/rules/a11y/aria-labels.mdx, from packages/rules/src/eeat. Each page that declares meta.appliesWhen now says which site classification turns it on, and that a low-confidence or absent classification runs it anyway. Also applies the codex findings on the content pages: - date-agreement emits at most two checks, compares the closest visible and schema pairing, takes the URL year before the title year, and a recognisable date anywhere in the content root suppresses the missing-date branch. - thin-vs-site-norm: sub-300-word pages still shape the norm and the denominator, the deviation has a 10%-of-median floor, and only 2xx pages with a known page type are sampled. - title-pattern-outlier: the real separator set, the real summary format, groups ordered by size, and the separator norm's own 10-vote and 70% floors. - word-count: the non-overlap with thin-vs-site-norm holds at the default min_words only, since the boundary is the fixed 300 constant. - unrendered-markup: visible <p> is one escape, not two, so the fix is to find the rendering path rather than to drop the escape. - Plus corrections to article-links bands, the author-info selector, broken-html nesting, mojibake ordering, placeholder samples, the Flesch range and the copyright-year semantics, and four references swapped for ones that address the mechanism. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
Rewrite the 6 mobile, 5 social and 3 video rule pages and their category indexes to the template in docs/rules/a11y/aria-labels.mdx, from packages/rules/src. Also applies the codex findings on the eeat pages: ymyl-detection reads the title, description and path rather than the body; every coverage threshold compares a rounded whole-number percentage; the schema type lists are collected from top-level and @graph nodes so a nested PostalAddress or AggregateRating does not satisfy them; the affiliate patterns match the whole URL and the Amazon one needs a path segment before the tag; the disclaimers skip is named `disclaimers`; the authoritative-domain list has 14 entries; and the privacy fix now mentions the CCPA twelve-month refresh. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
…plate Rewrite the 4 legal, 2 i18n, 2 analytics, 3 adblock and 2 gaps rule pages and every remaining category index, including the SEO score-group index, to the template in docs/rules/a11y/aria-labels.mdx. The cloud Notes, the opt-in enable blocks and the Blocking category labels are preserved. Source correction: docs/rules/legal/privacy-policy.mdx listed its Scope as Per-page. The rule's meta.scope is "site", so the table now says Site-wide. Also applies the codex findings on the mobile, social and video pages: every inline-style regex reads integers only and the tap-target patterns are unanchored and case-sensitive, so min-width matches and 20.5px does not; tap-target counts are selector sums with no deduplication; og-image-size falls through to the informational branch for any non-positive dimension; og-url-match normalisation is the URL parser plus a slash strip; share-buttons recognises twitter.com and not x.com; social-profiles compares against the current page's hrefs; asset-divergence only samples 2xx pages; VideoObject requires name, thumbnailUrl and uploadDate with description recommended; and thumbnailUrl is search metadata, not an embed's preview frame. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
- Shorten 31 titles that ran past the 60-character budget and trim two descriptions past 155. - Fix eight related-rule hrefs that pointed at /rules/performance/<slug>. The rule ids are performance/*, but the pages live under /rules/perf/, so the link text keeps the id and the href now resolves. - Replace five uses of "simply" and one "robust" in prose. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
…codex - gaps/keywords and gaps/content: the high-volume warning needs MORE THAN 20 qualifying items, not any one of them. - gaps/keywords: a gap can mean no page or a page that does not rank, and the fix differs. - adblock/blocked-links: the message carries the full hostname and a page count, and the report cap is Math.max(1, maxMatchesToReport). - adblock: first-party or server-side collection may reduce blocking rather than survive it, and a blocked script is not silent to the browser, only to the dashboard. - adblock/element-hiding: cosmetic filters can be domain-specific and can key on ids, attributes and selector structure, not just classes. - legal/cookie-consent: hasInteractiveConsent does read region text and control labels, so the page no longer claims structural signals only. - i18n/lang-attribute: Google ignores code-level language declarations. - analytics/consent-mode: basic mode blocks tags until consent; the consent patterns are regexes while the tag and v2 tests are case-sensitive; a CMP can run on GTM's consent initialization trigger. - analytics/gtm-present: a tag manager deploys tags rather than measuring, and not every listed tool implies a third-party request or consent. - Four references swapped for ones that address the mechanism. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
- Every category index card for a rewritten rule page now carries that page's new title and frontmatter description. 148 cards across 16 indexes, order, icons and hrefs unchanged; the score-group category cards on the security and seo indexes are untouched. - Related-rule link text said performance/<slug>. The rules in packages/rules/src/performance carry ids of perf/<slug>, which is also the docs path, so the text now matches the id. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
A codex pass compared all 592 half-lines in the batch against the target rule's own meta.description and source. 22 misdescribed the target, mostly by claiming a verification the rule does not perform: - analytics/consent-mode searches the HTML for Consent Mode markers; it does not verify that Google tags are wired to a consent signal. - content/freshness inventories the date signals a page declares; it does not establish how old the content is. - images/responsive-size flags thumbnail-sized attributes with no responsive markup; it never compares intrinsic dimensions. - images/optimized recognises CDN hosts and format markers in URLs; it does not verify that anything is resized on request. - eeat/author-expertise detects author pages and Person schema; it does not read a bio. - legal/cookie-consent detects a consent mechanism; it does not check that consent precedes the cookie. - links/weak-internal-links counts dofollow internal inbound links only. - perf/cls-hints checks images and iframes for missing dimensions; perf/js-libraries reports libraries and known vulnerabilities, not bytes; perf/lcp-hints looks at img elements, not video posters; a11y/touch-targets reads inline sizing hints rather than rendered sizes; images/dimensions is about images, not videos. - content/keyword-stuffing is about repetition, not meaningful word count. - security/third-party-cookies detects third-party resources, not storage. Claude-Session: https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA Signed-off-by: Nik Cubrilovic <[email protected]>
nc9
force-pushed
the
docs/rules-batch-c
branch
from
September 10, 2026 02:28
3bd21ce to
05ff506
Compare
3 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Rewrites the rule reference pages for batch C to the search-first template in
docs/rules/a11y/aria-labels.mdx.Every page gets a searchable title and description, a "what the term is" section, one bullet per check the rule actually emits with its exact report message and severity read from
packages/rules/src/, a minimal fix, the existing metadata and enable/disable blocks, related rules, verified references and the audit CTA.Each category was reviewed by a
codex execpass against the rule source before the next was committed, so most commits also carry the corrections to the category before them.Tracking issue: https://github.com/squirrelscan/repo/issues/2050
Categories
security 16, integrity 9, crawl 20, url 9, links 15, images 15, content 22, eeat 15, mobile 6, social 5, video 3, legal 4, i18n 2, analytics 2, adblock 3, gaps 2. 148 rule pages plus 17 index pages, including the SEO score-group index.
Verification
cd docs && make validate(tangly check --strict) passes. All 13 CI checks pass.curl -sIL./rules/<cat>/<slug>link in a Related rules block resolves to a file that exists. Note thattangly check --strictdoes not validate these, so it is checked separately.## Optionstable matches the rule's zod schema. No rule with options lacks a table and no page without options carries one.meta.descriptionand source. 22 misdescribed the target and are fixed.Source corrections worth a second look
crawl/html-sizeandcrawl/pdf-sizequote Googlebot limits in their report messages. Google's March 2026 crawler post documents 2MB per non-PDF URL and 64MB for a PDF. The HTML default of 2MB is exact; the PDF default of 60MB sits 4MB under while the message calls it "the Googlebot 60MB limit". The old index card said 64MB. Worth an issue against the rule if you want the message reworded.legal/privacy-policylisted its Scope as Per-page;meta.scopeis"site". Corrected.unknownwith defaultundefinednow carries the real zod defaults, under[rule_options."<rule id>"]rather than[rules."<rule id>"].robots-conflictwarn incrawl/robots-meta-conflict, the file-with-trailing-slash warn inurl/trailing-slash, thevia unknownwording incrawl/indexability, and theInvalid formatlabel inlinks/invalid-links.packages/rules/src/content/article-toc.ts(content/article-toc) has no page underdocs/rules/content, so it was outside this rewrite.packages/rules/src/performance/declares rule ids ofperf/<slug>, which is also the docs path. Link text and hrefs both useperf.https://claude.ai/code/session_0174D96WamG9ZhJxRudpeniA