Commit Graph

16 Commits

Author SHA1 Message Date
jmiller b77054b769 fix: harden input handling and output safety (#79)
Universal: PR Check / Branch Policy (pull_request) Successful in 2s
Joomla: Extension CI / Release Readiness Check (pull_request) Failing after 4s
Generic: Repo Health / Access control (pull_request) Successful in 1s
Generic: Repo Health / Site Health (pull_request) Has been skipped
Universal: PR Check / Validate PR (pull_request) Failing after 4s
Universal: PR Check / Secret Scan (pull_request) Successful in 6s
Universal: Auto Version Bump / Version Bump (push) Successful in 11s
Joomla: Extension CI / Lint & Validate (pull_request) Failing after 11s
Joomla: Metadata Validation / Validate Joomla Metadata (pull_request) Failing after 9s
Universal: Pre-Release / Build Pre-Release (${{ inputs.stability || github.ref_name }}) (push) Successful in 13s
Joomla: Extension CI / Tests (PHP 8.2) (pull_request) Has been cancelled
Joomla: Extension CI / Tests (PHP 8.3) (pull_request) Has been cancelled
Joomla: Extension CI / PHPStan Analysis (pull_request) Has been cancelled
Joomla: Extension CI / Build RC Pre-Release (pull_request) Has been cancelled
Universal: PR Check / Build RC Package (pull_request) Has been cancelled
Universal: PR Check / Report Issues (pull_request) Has been cancelled
Generic: Repo Health / Scripts governance (pull_request) Has been cancelled
Generic: Repo Health / Repository health (pull_request) Has been cancelled
Generic: Repo Health / Report Issues (pull_request) Has been cancelled
- canonical_url: sanitize via sanitizeUrl() (scheme allowlist) instead of
  bare trim() — closes stored-XSS via addHeadLink() on the public frontend
- AI endpoint: replace die('Invalid Token') with a clean event result,
  and strip_tags + truncate article_title to 200 chars before use
- SitemapBuilder: whitelist changefreq against the sitemap spec enum,
  intval() noindex IDs, strict in_array comparison
- MokoOG: log a WARNING when sitemap.xml write fails instead of ignoring it
2026-06-28 13:55:14 -05:00
Jonathan Miller 49d644566a feat: add custom schema, AI generation, XML sitemap, platform images
Universal: Auto Version Bump / Version Bump (push) Successful in 14s
Universal: Pre-Release / Build Pre-Release (${{ inputs.stability || github.ref_name }}) (push) Successful in 11s
- Custom JSON-LD schema builder: per-article textarea for arbitrary
  structured data with JSON validation. Closes #70
- AI-powered meta generation: Generate with AI buttons for OG title
  and description, supports Claude and OpenAI APIs. Closes #71
- XML sitemap: auto-generates sitemap.xml on article save, respects
  noindex directives. Closes #72
- Per-platform image resizing: Twitter 1200x600, Pinterest 1000x1500,
  WhatsApp 400x400 alongside default Facebook 1200x630. Closes #74
- DB migration 01.05.00: adds custom_schema column
2026-06-23 12:54:01 -05:00
Jonathan Miller 872074cd5b feat: add FAQ, HowTo, Event, and Recipe JSON-LD schema types
Universal: Auto Version Bump / Version Bump (push) Successful in 10s
Universal: Pre-Release / Build Pre-Release (${{ inputs.stability || github.ref_name }}) (push) Successful in 23s
- FAQ: auto-detects h3/h4 + paragraph patterns, outputs FAQPage (#62)
- HowTo: auto-detects ordered lists, outputs HowTo with steps (#63)
- Event: per-article fields (dates, venue, tickets), event_data JSON
  column, outputs Event schema (#64)
- Recipe: per-article fields (times, ingredients, nutrition),
  recipe_data JSON column, outputs Recipe schema (#66)
- DB migration 01.04.00: adds event_data and recipe_data columns

Closes #62, closes #63, closes #64, closes #66
2026-06-23 12:19:37 -05:00
Jonathan Miller 44d9daf3bc feat: add LocalBusiness JSON-LD schema type
Universal: Auto Version Bump / Version Bump (push) Successful in 12s
Universal: Pre-Release / Build Pre-Release (${{ inputs.stability || github.ref_name }}) (push) Successful in 11s
Adds configurable LocalBusiness structured data with address,
contact, geo coordinates, and opening hours. Enabled via plugin
parameters. Closes #65
2026-06-23 11:30:45 -05:00
Jonathan Miller aeea65423c feat: add VideoObject JSON-LD schema for video content
Outputs VideoObject structured data when an article has a video URL
set, enabling Google video rich results. Closes #67
2026-06-23 11:28:37 -05:00
Jonathan Miller fcfa6838e5 fix: address PR #82 review findings
Joomla: Extension CI / Release Readiness Check (pull_request) Failing after 5s
Universal: PR Check / Branch Policy (pull_request) Successful in 2s
Generic: Repo Health / Site Health (pull_request) Has been skipped
Generic: Repo Health / Access control (pull_request) Successful in 2s
Universal: PR Check / Validate PR (pull_request) Failing after 7s
Universal: PR Check / Secret Scan (pull_request) Successful in 8s
Joomla: Extension CI / Lint & Validate (pull_request) Failing after 14s
Universal: Auto Version Bump / Version Bump (push) Successful in 16s
Universal: Pre-Release / Build Pre-Release (${{ inputs.stability || github.ref_name }}) (push) Successful in 15s
Joomla: Metadata Validation / Validate Joomla Metadata (pull_request) Failing after 54s
Joomla: Extension CI / Tests (PHP 8.2) (pull_request) Has been cancelled
Joomla: Extension CI / Tests (PHP 8.3) (pull_request) Has been cancelled
Joomla: Extension CI / PHPStan Analysis (pull_request) Has been cancelled
Joomla: Extension CI / Build RC Pre-Release (pull_request) Has been cancelled
Universal: PR Check / Build RC Package (pull_request) Has been cancelled
Universal: PR Check / Report Issues (pull_request) Has been cancelled
Generic: Repo Health / Scripts governance (pull_request) Has been cancelled
Generic: Repo Health / Repository health (pull_request) Has been cancelled
Generic: Repo Health / Report Issues (pull_request) Has been cancelled
- Only emit og:video:secure_url for HTTPS URLs (review #1)
- Only emit og:video:width/height for direct files, not embeds (review #2)
- Add server-side http/https scheme validation on og_video save (review #3)
- Consolidate duplicate com_mokoshop product blocks into one (review #4)
- Fix stale com_virtuemart reference in SQL comment (review #5)
- Use COM_MOKOOG_* language keys in tag.xml instead of plugin keys (review #6)
2026-06-23 10:46:58 -05:00
Jonathan Miller 5b29690d34 feat: add og:video support and Pinterest rich pin tags
Universal: Auto Version Bump / Version Bump (push) Successful in 16s
Universal: Pre-Release / Build Pre-Release (${{ inputs.stability || github.ref_name }}) (push) Successful in 12s
- Add og:video meta tags with per-article video URL field and auto
  MIME type detection for YouTube/Vimeo/direct files. Includes DB
  migration for og_video column. (closes #59)
- Add Pinterest rich pin tags: article:tag from Joomla content tags
  on article pages, product:availability from MokoSuiteShop stock
  quantity on product pages. (closes #60)
2026-06-23 10:36:04 -05:00
Jonathan Miller 881bb0a2ae feat: add fediverse:creator tag, character counters, LinkedIn preview
- Add fediverse:creator meta tag for Mastodon/Fediverse author
  attribution — first extension on any CMS to support this (closes #57)
- Add live character count indicators with green/yellow/red color
  coding on OG title, description, SEO title, and meta description
  fields in the article/menu editor (closes #58)
- Add LinkedIn social preview card alongside existing Facebook and
  Twitter/X previews in the editor (closes #61)
2026-06-23 10:36:04 -05:00
Jonathan Miller 77da0c5517 fix: remove remaining @ suppression, check Folder::create() returns
- Remove @getimagesize() suppression in ImageHelper, ImageGenerator,
  MokoOG — let PHP report warnings for corrupt/unreadable images
- Add Log::add() when ImageHelper::resize() cannot read image dimensions
- Check Folder::create() return value in ImageGenerator and ImageHelper,
  return graceful fallback if directory creation fails
2026-06-21 16:42:54 -05:00
Jonathan Miller 46e30c950b fix: address PR review findings — error handling and data integrity
- Add missing language field to batch-generated records
- Wrap batch insert in try-catch to handle duplicate key races
- Add logging to all empty catch blocks (script.php, MokoOG license check)
- Guard loadShopProduct() with try-catch for missing MokoSuiteShop tables
- Guard reviews query in JsonLdBuilder for missing #__mokoshop_reviews
2026-06-21 16:26:13 -05:00
Jonathan Miller 28d44d6884 fix: undefined $db in findImage(), pass cached product to buildProduct()
- Add missing Factory::getDbo() in findImage() category fallback — would
  cause fatal error on article pages with no images (found in PR review)
- Pass cached product to JsonLdBuilder::buildProduct() to avoid duplicate
  DB query (same pattern as buildArticle with cachedArticle)
- Fix orphaned PHPDoc block for getImageDimensions()
2026-06-21 15:40:01 -05:00
Jonathan Miller ca06c86328 perf: consolidate article DB queries into single cached lookup (#38)
- Add loadArticle() with static per-request cache for article data
- Refactor getArticleDate(), getArticleAuthor() to use cached article
- Refactor findImage() for com_content to use cached article
- Pass cached article to JsonLdBuilder::buildArticle() to skip its query
- Reduces article page DB queries from 5 to 1 for OG tag generation
2026-06-21 11:09:52 -05:00
Jonathan Miller 8793e6b3f4 feat: add MokoSuiteShop product OG tag support (#53)
- Detect com_mokoshop product views and set og:type to 'product'
- Auto-generate OG tags from CRM product data (name, description, image)
- Add product:price:amount and product:price:currency meta tags
- Add JSON-LD Product schema with offers, SKU, and aggregate ratings
- Load product images from linked #__content article images
- Cache product DB lookups to avoid duplicate queries per request
2026-06-21 10:20:38 -05:00
Jonathan Miller 0afc8b135a fix: replace GD error suppression with logging, remove dead adapters (#49, #36)
- Replace @ error suppression in ImageGenerator with Log::add() warnings
  for missing GD, missing font, corrupt images (#49)
- Add GD extension pre-check before attempting image generation
- Add WebP function_exists() guard for servers without WebP support
- Remove @ suppression from ImageHelper::loadImage() with logging
- Remove unused ContentType adapters (HikaShop, K2, VirtueMart) and
  ContentTypeInterface — not targeting these platforms (#36)
2026-06-21 10:12:00 -05:00
Jonathan Miller 433ecfea71 fix: resolve 3 v1.0 release blockers (#47, #48, #39)
- Add TagsController extending AdminController for admin list
  delete/publish/unpublish operations (#48)
- Add language filter to loadOgDataByType() and loadOgDataByMenu()
  matching the pattern already used in loadOgData() (#47)
- Replace direct $doc->_links access with getHeadData()/setHeadData()
  public API for Joomla forward compatibility (#39)
- Update ISSUES.md with full 2026-06-21 assessment
2026-06-21 10:02:03 -05:00
Jonathan Miller 05b2a44209 refactor: rename src/ to source/ and update all CI references
- Rename project source directory from src/ to source/
- Update CI workflows (ci-joomla, pr-check, repo-health) to check
  source/ first, falling back to src/ and htdocs/ for compat
- Update .gitignore vendor exception path
- manifest.xml entry-point already updated

Authored-by: Moko Consulting
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-06-06 08:24:35 -05:00