@thierrynakoa/fire-flow 12.2.1 → 13.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CREDITS.md +25 -0
- package/DOMINION-FLOW-OVERVIEW.md +182 -38
- package/README.md +399 -455
- package/TROUBLESHOOTING.md +264 -264
- package/agents/fire-debugger.md +54 -0
- package/agents/fire-executor.md +1610 -1033
- package/agents/fire-fact-checker.md +1 -1
- package/agents/fire-planner.md +85 -17
- package/agents/fire-project-researcher.md +1 -1
- package/agents/fire-researcher.md +4 -22
- package/agents/{fire-phoenix-analyst.md → fire-resurrection-analyst.md} +394 -394
- package/agents/fire-reviewer.md +552 -499
- package/agents/fire-verifier.md +114 -19
- package/bin/cli.js +18 -101
- package/commands/fire-0-orient.md +2 -2
- package/commands/fire-1a-new.md +50 -15
- package/commands/fire-1c-setup.md +33 -5
- package/commands/fire-1d-discuss.md +87 -1
- package/commands/fire-2-plan.md +556 -527
- package/commands/fire-3-execute.md +2046 -1356
- package/commands/fire-4-verify.md +975 -906
- package/commands/fire-5-handoff.md +46 -5
- package/commands/fire-6-resume.md +2 -31
- package/commands/fire-add-new-skill.md +138 -19
- package/commands/fire-autonomous.md +14 -2
- package/commands/fire-complete-milestone.md +1 -1
- package/commands/fire-cost.md +179 -183
- package/commands/fire-debug.md +1 -6
- package/commands/fire-loop-resume.md +2 -2
- package/commands/fire-loop-stop.md +1 -1
- package/commands/fire-loop.md +2 -15
- package/commands/fire-map-codebase.md +1 -1
- package/commands/fire-migrate-database.md +548 -0
- package/commands/fire-new-milestone.md +1 -1
- package/commands/fire-reflect.md +1 -2
- package/commands/fire-research.md +142 -21
- package/commands/{fire-phoenix.md → fire-resurrect.md} +859 -603
- package/commands/fire-scaffold.md +297 -0
- package/commands/fire-search.md +1 -2
- package/commands/fire-security-scan.md +483 -484
- package/commands/fire-setup.md +359 -0
- package/commands/fire-skill.md +770 -0
- package/commands/fire-skills-diff.md +506 -506
- package/commands/fire-skills-history.md +388 -388
- package/commands/fire-skills-rollback.md +7 -7
- package/commands/fire-skills-sync.md +470 -470
- package/commands/fire-test.md +5 -5
- package/commands/fire-todos.md +1 -1
- package/commands/fire-update.md +5 -5
- package/commands/fire-validate-skills.md +282 -0
- package/commands/fire-vuln-scan.md +492 -493
- package/hooks/run-hook.sh +8 -8
- package/hooks/run-session-end.sh +7 -7
- package/hooks/session-end.sh +90 -90
- package/hooks/session-start.sh +1 -1
- package/package.json +4 -24
- package/plugin.json +7 -7
- package/references/autonomy-levels.md +235 -0
- package/references/behavioral-directives.md +95 -3
- package/references/blocker-tracking.md +1 -1
- package/references/circuit-breaker.md +93 -2
- package/references/context-engineering.md +227 -9
- package/references/honesty-protocols.md +70 -1
- package/references/issue-to-pr-pipeline.md +149 -150
- package/references/metrics-and-trends.md +1 -2
- package/references/research-improvements.md +4 -108
- package/references/sdlc-mapping.md +73 -0
- package/references/state-machine.md +151 -0
- package/skills-library/AVAILABLE_TOOLS_REFERENCE.md +333 -0
- package/skills-library/SKILLS-INDEX.md +57 -558
- package/skills-library/SKILLS_LIBRARY_INDEX.md +532 -0
- package/skills-library/_general/api-patterns/api-field-name-mismatch.md +107 -0
- package/skills-library/_general/api-patterns/streaming-command-timeout.md +122 -0
- package/skills-library/_general/api-patterns/streaming-proxy-cors-bypass.md +102 -0
- package/skills-library/_general/automation/settings-gui-generator.md +172 -0
- package/skills-library/_general/database-solutions/data-type-mapping-reference.md +181 -0
- package/skills-library/_general/database-solutions/mysql-limit-offset-string-coercion.md +102 -0
- package/skills-library/_general/database-solutions/mysql-to-pg-migration.md +195 -0
- package/skills-library/_general/database-solutions/orm-schema-portability.md +193 -0
- package/skills-library/_general/database-solutions/persistent-analysis-storage.md +207 -0
- package/skills-library/_general/database-solutions/pg-to-mysql-schema-migration-methodology.md +190 -0
- package/skills-library/_general/database-solutions/sql-dialect-compatibility-matrix.md +306 -0
- package/skills-library/_general/database-solutions/sqlite-to-pg-migration.md +219 -0
- package/skills-library/_general/frontend/canvas-bubble-animation-grouping.md +270 -0
- package/skills-library/_general/frontend/color-token-migration.md +112 -0
- package/skills-library/_general/frontend/framer-motion-layoutid-grouping.md +150 -0
- package/skills-library/_general/frontend/pyqt6-settings-dialog.md +191 -0
- package/skills-library/_general/frontend/react-flow-animated-layout-switching.md +101 -0
- package/skills-library/_general/frontend/react-hooks-order-debugging.md +141 -0
- package/skills-library/_general/frontend/redux-localstorage-auth-desync.md +126 -0
- package/skills-library/_general/frontend/safari-csp-theme-color-debugging.md +124 -0
- package/skills-library/_general/frontend/safari-sw-cache-poisoning.md +138 -0
- package/skills-library/_general/frontend/svg-sparkline-no-charting-library.md +131 -0
- package/skills-library/_general/growth-marketing/oss-daily-growth-intelligence.md +224 -0
- package/skills-library/_general/integrations/claude-code-local-mcp-integration.md +250 -0
- package/skills-library/_general/integrations/mcp-composite-tool-orchestration.md +200 -0
- package/skills-library/_general/methodology/AGENT_SDK_STANDALONE_TOOLING.md +181 -0
- package/skills-library/_general/methodology/AGENT_TEAMS_GUIDE.md +169 -0
- package/skills-library/_general/methodology/ALAS_STATEFUL_EXECUTION.md +207 -0
- package/skills-library/_general/methodology/AUTO_REVIEWER_SUBAGENT.md +211 -0
- package/skills-library/_general/methodology/CONSISTENCY_CHECK_AMBIGUITY_GATE.md +96 -0
- package/skills-library/_general/methodology/DEAD_ENDS_SHELF.md +4 -4
- package/skills-library/_general/methodology/DISTILL_NOT_DUMP.md +108 -0
- package/skills-library/_general/methodology/EXECUTION_PROGRESS_MONITOR.md +157 -0
- package/skills-library/_general/methodology/HIERARCHICAL_REVIEW_MARS.md +122 -0
- package/skills-library/_general/methodology/MCP_INTER_AGENT_BRIDGE.md +207 -0
- package/skills-library/_general/methodology/MERMAID_WIZARD_DIAGRAMS.md +77 -0
- package/skills-library/_general/methodology/MISSING_DIMENSION_DETECTOR.md +89 -0
- package/skills-library/_general/methodology/MULTI_AGENT_COORDINATION.md +397 -0
- package/skills-library/_general/methodology/OBSERVATION_MASKING.md +100 -0
- package/skills-library/_general/methodology/PHOENIX_REBUILD_METHODOLOGY.md +82 -11
- package/skills-library/_general/methodology/REVIEW_BACKTRACK_PANEL.md +140 -0
- package/skills-library/_general/methodology/REVIEW_FIX_LOOP.md +117 -0
- package/skills-library/_general/methodology/VOTING_VERDICT_ARBITRATION.md +155 -0
- package/skills-library/_general/methodology/ZERO_FRICTION_CLI_SETUP.md +2 -2
- package/skills-library/_general/methodology/dead-code-activation.md +123 -0
- package/skills-library/_general/methodology/debug-swarm-researcher-escape-hatch.md +240 -240
- package/skills-library/_general/methodology/shell-autonomous-loop-fixplan.md +1 -1
- package/skills-library/_general/patterns-standards/GOF_DESIGN_PATTERNS_FOR_AI_AGENTS.md +5 -5
- package/skills-library/_general/patterns-standards/cascading-failure-diagnosis.md +119 -0
- package/skills-library/_general/patterns-standards/domain-specific-layout-algorithms.md +209 -0
- package/skills-library/_general/patterns-standards/python-desktop-app-architecture.md +399 -0
- package/skills-library/_general/patterns-standards/realtime-monitoring-dashboard.md +457 -0
- package/skills-library/_general/patterns-standards/togglable-processing-pipeline.md +169 -0
- package/skills-library/_general/performance/liveclock-extraction.md +112 -0
- package/skills-library/_general/performance/ref-based-canvas-animation.md +117 -0
- package/skills-library/_general/performance/use-visible-interval.md +131 -0
- package/skills-library/_general/testing/playwright-firefox-withcredentials-auth-issue.md +104 -0
- package/skills-library/_quarantine/README.md +30 -0
- package/skills-library/api-patterns/BROADCAST_SCHEDULER_SHARED_EXECUTE_FUNCTION.md +150 -0
- package/skills-library/api-patterns/ERROR_RESPONSE_STANDARDS.md +145 -0
- package/skills-library/api-patterns/EXPRESS_ROUTE_ORDERING_MIDDLEWARE_INTERCEPTION.md +326 -0
- package/skills-library/api-patterns/PAGINATION_PATTERNS.md +137 -0
- package/skills-library/api-patterns/PODCAST_PROGRESS_TRACKING_THREE_ROOT_CAUSES.md +277 -0
- package/skills-library/api-patterns/RATE_LIMITING_TOGGLE.md +155 -0
- package/skills-library/api-patterns/graphql-content-queries.md +708 -0
- package/skills-library/appointment-scheduler-design.md +423 -0
- package/skills-library/automation/AUTO_POPULATE_COMPLETE_GUIDE.md +631 -0
- package/skills-library/automation/CC_WORKFLOW_STUDIO.md +83 -0
- package/skills-library/automation/CLAUDE_CODE_SWARM_MODE.md +95 -0
- package/skills-library/automation/DAEMON_TRIGGER_FILE_IPC.md +195 -0
- package/skills-library/automation/scheduled-content-publishing.md +608 -0
- package/skills-library/awesome-workflows/Blogging-Platform-Instructions/view_commands.md +25 -0
- package/skills-library/awesome-workflows/CREDENTIAL-SECURITY-WORKFLOW.md +109 -0
- package/skills-library/awesome-workflows/DEBUGGING-WORKFLOW.md +124 -0
- package/skills-library/awesome-workflows/Design-Review-Workflow/README.md +31 -0
- package/skills-library/awesome-workflows/Design-Review-Workflow/design-principles-example.md +129 -0
- package/skills-library/awesome-workflows/Design-Review-Workflow/design-review-agent.md +107 -0
- package/skills-library/awesome-workflows/Design-Review-Workflow/design-review-claude-md-snippet.md +24 -0
- package/skills-library/awesome-workflows/Design-Review-Workflow/design-review-slash-command.md +38 -0
- package/skills-library/awesome-workflows/PARALLEL-RESEARCH-WORKFLOW.md +89 -0
- package/skills-library/awesome-workflows/PHASE-EXECUTION-WORKFLOW.md +97 -0
- package/skills-library/awesome-workflows/SESSION-HANDOFF-WORKFLOW.md +116 -0
- package/skills-library/cms-patterns/content-branch-preview.md +515 -0
- package/skills-library/cms-patterns/inline-visual-editing.md +666 -0
- package/skills-library/cms-patterns/mdx-component-content.md +649 -0
- package/skills-library/cms-patterns/media-manager-abstraction.md +827 -0
- package/skills-library/cms-patterns/schema-driven-form-generator.md +838 -0
- package/skills-library/complexity-metrics/complexity-divider.md +707 -0
- package/skills-library/complexity-metrics/work-with-complexity.md +193 -0
- package/skills-library/creative-multimedia/animation-stack-guide.md +577 -0
- package/skills-library/creative-multimedia/audio-enhancement-pipeline.md +625 -0
- package/skills-library/creative-multimedia/content-repurposing-pipeline.md +1146 -0
- package/skills-library/creative-multimedia/data-visualization-generator.md +862 -0
- package/skills-library/creative-multimedia/doc-to-podcast-pipeline.md +2184 -0
- package/skills-library/creative-multimedia/ffmpeg-command-generator.md +405 -0
- package/skills-library/creative-multimedia/image-optimization-pipeline.md +605 -0
- package/skills-library/creative-multimedia/multi-format-content-generator.md +1759 -0
- package/skills-library/creative-multimedia/og-image-generator.md +635 -0
- package/skills-library/creative-multimedia/podcast-audio-composition.md +1355 -0
- package/skills-library/creative-multimedia/podcast-quality-evaluation.md +1452 -0
- package/skills-library/creative-multimedia/podcast-script-generation.md +1841 -0
- package/skills-library/creative-multimedia/svg-generation.md +750 -0
- package/skills-library/creative-multimedia/text-to-speech-provider-selector.md +1414 -0
- package/skills-library/creative-multimedia/transcription-pipeline-selector.md +677 -0
- package/skills-library/creative-multimedia/video-streaming-setup.md +559 -0
- package/skills-library/database-solutions/AI_RESPONSE_DATABASE_CACHING.md +520 -0
- package/skills-library/database-solutions/CONDITIONAL_SQL_MIGRATION_PATTERN.md +119 -0
- package/skills-library/database-solutions/DATABASE_COLUMN_NAME_MISMATCH.md +393 -0
- package/skills-library/database-solutions/DATABASE_SCHEMA.md +394 -0
- package/skills-library/database-solutions/DATABASE_SCHEMA_VERIFICATION_GUIDE.md +348 -0
- package/skills-library/database-solutions/DATABASE_STRATEGY.md +71 -0
- package/skills-library/database-solutions/ES_MODULE_SEED_SCRIPT_PATTERN.md +52 -0
- package/skills-library/database-solutions/MIGRATION_GUIDE.md +3 -0
- package/skills-library/database-solutions/PLPGSQL_VARIABLE_CONFLICT_FIX.md +208 -0
- package/skills-library/database-solutions/POSTGRESQL_JSONB_DOUBLE_STRINGIFY_FIX.md +245 -0
- package/skills-library/database-solutions/POSTGRESQL_LICENSE_TABLE_DESIGN.md +393 -0
- package/skills-library/database-solutions/POSTGRESQL_UUID_DOCUMENT_RAG_DUAL_SCOPE.md +732 -0
- package/skills-library/database-solutions/POSTGRES_SQL_TEMPLATE_BINDING_ERROR.md +240 -0
- package/skills-library/database-solutions/PRISMA_DB_PUSH_DATA_LOSS_PREVENTION.md +141 -0
- package/skills-library/database-solutions/PRODUCTION_QUERY_OPTIMIZATION_RESTART_FIX.md +389 -0
- package/skills-library/database-solutions/RLS_SECURITY_GUIDE.md +107 -0
- package/skills-library/database-solutions/SCHEMA_ENHANCEMENTS_GUIDE.md +373 -0
- package/skills-library/database-solutions/SCHEMA_MIGRATION_GUIDE.md +368 -0
- package/skills-library/database-solutions/SCHEMA_VERIFICATION_QUICK_REFERENCE.md +104 -0
- package/skills-library/database-solutions/ai-erd-generator.md +1213 -0
- package/skills-library/database-solutions/content-publishing-states.md +631 -0
- package/skills-library/database-solutions/database-schema-designer.md +522 -0
- package/skills-library/database-solutions/er-diagram-components.md +569 -0
- package/skills-library/database-solutions/er-to-ddl-mapping.md +1405 -0
- package/skills-library/database-solutions/erd-creator-textbook-research.md +433 -0
- package/skills-library/database-solutions/erd-react-flow-architecture.md +1965 -0
- package/skills-library/database-solutions/mariadb-aggregate-function-replacement.md +145 -0
- package/skills-library/database-solutions/normalization-validator.md +778 -0
- package/skills-library/database-solutions/postgres-full-text-search-content.md +494 -0
- package/skills-library/database-solutions/postgresql-to-mysql-runtime-translation.md +286 -0
- package/skills-library/database-solutions/regex-alternation-ordering-sql-types.md +92 -0
- package/skills-library/database-solutions/reserved-word-context-aware-quoting.md +142 -0
- package/skills-library/database-solutions/sql-ddl-generator.md +756 -0
- package/skills-library/database-solutions/supabase-connection-pooler-fix.md +102 -0
- package/skills-library/deployment-security/CPANEL_NODE_DEPLOYMENT.md +166 -0
- package/skills-library/deployment-security/DEPLOYMENT.md +275 -0
- package/skills-library/deployment-security/DEPLOYMENT_CHECKLIST.md +363 -0
- package/skills-library/deployment-security/DEPLOYMENT_PLAN.md +669 -0
- package/skills-library/deployment-security/KNEX_DATABASE_ABSTRACTION.md +444 -0
- package/skills-library/deployment-security/LICENSE_KEY_SYSTEM.md +206 -0
- package/skills-library/deployment-security/NODE18_DEPENDENCY_COMPATIBILITY.md +284 -0
- package/skills-library/deployment-security/PHP_INSTALLER_WIZARD_GUIDE.md +315 -0
- package/skills-library/deployment-security/PM2_ENVIRONMENT_VARIABLE_CACHING.md +256 -0
- package/skills-library/deployment-security/PM2_MEMORY_EXHAUSTION_FIX.md +370 -0
- package/skills-library/deployment-security/PRODUCTION_DEPLOYMENT_GUIDE.md +592 -0
- package/skills-library/deployment-security/PRODUCTION_HARDENING_DOCUMENTATION.md +307 -0
- package/skills-library/deployment-security/PRODUCTION_RECOVERY_CHERRY_PICK_PATTERN.md +202 -0
- package/skills-library/deployment-security/PYINSTALLER_CUDA_WHISPER_BUNDLING.md +236 -0
- package/skills-library/deployment-security/SECURITY.md +41 -0
- package/skills-library/deployment-security/SMTP_SSL_HOSTNAME_MISMATCH_SHARED_HOSTING.md +220 -0
- package/skills-library/deployment-security/SPA_SEO_OPTIMIZATION_CPANEL.md +200 -0
- package/skills-library/deployment-security/SUPABASE_EDGE_FUNCTIONS.md +338 -0
- package/skills-library/deployment-security/VERCEL_GITHUB_DEPLOYMENT_GUIDE.md +858 -0
- package/skills-library/deployment-security/VPS_DEPLOYMENT_READINESS.md +356 -0
- package/skills-library/deployment-security/deployment-changes-not-applying.md +241 -0
- package/skills-library/deployment-security/env-file-management-production-local.md +203 -0
- package/skills-library/deployment-security/express-secure-file-downloads.md +413 -0
- package/skills-library/deployment-security/react-production-deployment-desktop-guide.md +2011 -0
- package/skills-library/deployment-security/self-hosted-supabase-coolify-guide.md +1684 -0
- package/skills-library/deployment-security/unique-features-ai-strategy-plaid-security.md +1613 -0
- package/skills-library/deployment-security/vps-deployment.md +135 -0
- package/skills-library/document-processing/WORD_EXPORT_MARKDOWN_FORMATTING.md +482 -0
- package/skills-library/document-processing/document-ai-landingai-integration.md +677 -0
- package/skills-library/document-processing/express-secure-file-downloads-mern.md +413 -0
- package/skills-library/document-processing/express-secure-file-downloads.md +413 -0
- package/skills-library/document-processing/md-to-word-converter.md +318 -0
- package/skills-library/document-processing/pdf-forms-integration/README.md +101 -0
- package/skills-library/document-processing/pdf-forms-integration/SKILL.md +662 -0
- package/skills-library/ecommerce/ADMIN_PRODUCTS_GUIDE.md +428 -0
- package/skills-library/ecommerce/ECOMMERCE_API_REFERENCE.md +776 -0
- package/skills-library/ecommerce/ECOMMERCE_COMPLETION_SUMMARY.md +673 -0
- package/skills-library/ecommerce/ECOMMERCE_IMPLEMENTATION_GUIDE.md +729 -0
- package/skills-library/ecommerce/ECOMMERCE_QUICK_REFERENCE.md +521 -0
- package/skills-library/ecommerce/ECOMMERCE_TESTING_CHECKLIST.md +565 -0
- package/skills-library/ecommerce/ECOMMERCE_WORKFLOW_GUIDE.md +1059 -0
- package/skills-library/ecommerce/PRODUCT_CREATION_EXPANDED.md +522 -0
- package/skills-library/ecommerce/agentic-commerce-protocol.md +203 -0
- package/skills-library/ecommerce/cart-abandonment-recovery.md +236 -0
- package/skills-library/ecommerce/cart-architecture-patterns.md +300 -0
- package/skills-library/ecommerce/cart-item-count-indicator.md +264 -0
- package/skills-library/ecommerce/checkout-ux-conversion.md +227 -0
- package/skills-library/ecommerce/composable-commerce-selection.md +166 -0
- package/skills-library/ecommerce/ecommerce-analytics-patterns.md +167 -0
- package/skills-library/ecommerce/fraud-detection-patterns.md +179 -0
- package/skills-library/ecommerce/inventory-stock-management.md +270 -0
- package/skills-library/ecommerce/order-saga-state-machine.md +336 -0
- package/skills-library/ecommerce/payment-provider-abstraction.md +245 -0
- package/skills-library/ecommerce/pci-compliance-checklist.md +192 -0
- package/skills-library/ecommerce/refund-chargeback-handling.md +177 -0
- package/skills-library/ecommerce/shipping-carrier-integration.md +218 -0
- package/skills-library/ecommerce/webhook-idempotency-patterns.md +253 -0
- package/skills-library/excalidraw-diagrams/.github/workflows/ci.yml +558 -0
- package/skills-library/excalidraw-diagrams/.github/workflows/prompt-gallery.yml +448 -0
- package/skills-library/excalidraw-diagrams/.github/workflows/release.yml +42 -0
- package/skills-library/excalidraw-diagrams/.github/workflows/test-reusable-ci.yml +25 -0
- package/skills-library/excalidraw-diagrams/CLAUDE.md +57 -0
- package/skills-library/excalidraw-diagrams/LICENSE +21 -0
- package/skills-library/excalidraw-diagrams/README.md +178 -0
- package/skills-library/excalidraw-diagrams/SKILL.md +715 -0
- package/skills-library/form-solutions/BUTTON_TYPE_FORM_SUBMISSION.md +336 -0
- package/skills-library/form-solutions/FILLABLE_PDF_IMPLEMENTATION.md +226 -0
- package/skills-library/form-solutions/SURVEYJS_QUESTIONNAIRE_SYSTEM.md +367 -0
- package/skills-library/form-solutions/tiptap-minimal-setup.md +690 -0
- package/skills-library/frontend/scholarly-classification-bubble-map.md +149 -0
- package/skills-library/infrastructure/ci-cd-pipeline-builder.md +517 -0
- package/skills-library/infrastructure/observability-designer.md +264 -0
- package/skills-library/infrastructure/performance-profiler.md +621 -0
- package/skills-library/installer-wizard-patterns.md +249 -0
- package/skills-library/integrations/CLAUDE_CODE_TOKEN_ANALYTICS.md +160 -0
- package/skills-library/integrations/CONFIGURABLE_AI_PROVIDER_SELECTION.md +728 -0
- package/skills-library/integrations/SOCKET_IO_BROADCAST_ALL_VS_ROOM.md +141 -0
- package/skills-library/integrations/VIRTUAL_MEETINGS_IMPLEMENTATION.md +374 -0
- package/skills-library/integrations/WORDPRESS_LEARNDASH_DATA_RECOVERY.md +53 -0
- package/skills-library/integrations/YOUTUBE_API_SETUP.md +141 -0
- package/skills-library/integrations/YOUTUBE_BOOKMARKING_EXPLANATION.md +252 -0
- package/skills-library/integrations/YOUTUBE_BOOKMARKING_SOLUTION.md +268 -0
- package/skills-library/integrations/YOUTUBE_OAUTH_SETUP_GUIDE.md +200 -0
- package/skills-library/integrations/YOUTUBE_VIDEO_FIX_COMPLETE.md +192 -0
- package/skills-library/integrations/ai-ml/GEMINI_AI_RAG_PIPELINE_COMPLETE_GUIDE.md +195 -0
- package/skills-library/integrations/ai-ml/GEMINI_IMAGE_GENERATION_SETUP.md +64 -0
- package/skills-library/integrations/cloudflare/cloudflare-turnstile-debugging.md +202 -0
- package/skills-library/integrations/cloudflare/cloudflare-turnstile-implementation.md +476 -0
- package/skills-library/integrations/cloudflare-turnstile-debugging.md +202 -0
- package/skills-library/integrations/cloudflare-turnstile-implementation.md +476 -0
- package/skills-library/integrations/ghost-creator-monetization-pattern.md +454 -0
- package/skills-library/integrations/headless-cms-architecture.md +484 -0
- package/skills-library/integrations/headless-cms-stack-selection.md +183 -0
- package/skills-library/integrations/payload-cms-patterns.md +674 -0
- package/skills-library/integrations/realtimestt-openwakeword-cuda-windows.md +229 -0
- package/skills-library/integrations/rss-podcast-integration.md +300 -0
- package/skills-library/integrations/wordpress/WORDPRESS_LEARNDASH_DATA_RECOVERY.md +53 -0
- package/skills-library/integrations/youtube/YOUTUBE_API_SETUP.md +141 -0
- package/skills-library/integrations/youtube/YOUTUBE_BOOKMARKING_EXPLANATION.md +252 -0
- package/skills-library/integrations/youtube/YOUTUBE_BOOKMARKING_SOLUTION.md +268 -0
- package/skills-library/integrations/youtube/YOUTUBE_OAUTH_SETUP_GUIDE.md +200 -0
- package/skills-library/integrations/youtube/YOUTUBE_VIDEO_FIX_COMPLETE.md +192 -0
- package/skills-library/marketing/campaign-analytics.md +97 -0
- package/skills-library/marketing/content-creator.md +105 -0
- package/skills-library/marketing/marketing-strategy-pmm.md +94 -0
- package/skills-library/marketing/social-media-analyzer.md +81 -0
- package/skills-library/methodology/ADVANCED_ORCHESTRATION_PATTERNS.md +401 -0
- package/skills-library/methodology/AGENT_SELF_IMPROVEMENT_LOOP.md +179 -0
- package/skills-library/methodology/BREATH_BASED_PARALLEL_EXECUTION.md +1 -1
- package/skills-library/methodology/CLEANSING_CYCLE.md +358 -0
- package/skills-library/methodology/CONFIDENCE_ANNOTATION_PATTERN.md +143 -0
- package/skills-library/methodology/CRITICAL_PATTERNS_DOCUMENTATION_COMPLETE.md +204 -0
- package/skills-library/methodology/DELIVERABLES_SUMMARY.md +341 -0
- package/skills-library/methodology/DIFFICULTY_AWARE_AGENT_ROUTING.md +252 -0
- package/skills-library/methodology/EVOLUTIONARY_SKILL_SYNTHESIS.md +219 -0
- package/skills-library/methodology/GLOMERULUS_DECISION_GATE.md +223 -0
- package/skills-library/methodology/HIBERNATION_SYSTEM.md +231 -0
- package/skills-library/methodology/INSTRUMENTATION_OVER_RESTRICTION.md +192 -0
- package/skills-library/methodology/MASTER_COMPLETION_SUMMARY.md +444 -0
- package/skills-library/methodology/MASTER_SESSION_COMPLETION.md +743 -0
- package/skills-library/methodology/MERN_QUICK_REFERENCE.md +358 -0
- package/skills-library/methodology/ORGAN_AGENT_MAPPING.md +177 -0
- package/skills-library/methodology/PARALLEL_WAVE_BASED_REFACTORING.md +440 -0
- package/skills-library/methodology/QUICK_REFERENCE.md +358 -0
- package/skills-library/methodology/SDFT_ONPOLICY_SELF_DISTILLATION.md +186 -0
- package/skills-library/methodology/SELF_QUESTIONING_TASK_GENERATION.md +270 -0
- package/skills-library/methodology/SESSION_COMPLETION_SUMMARY.md +304 -0
- package/skills-library/methodology/SESSION_SUMMARY.md +432 -0
- package/skills-library/methodology/WARRIOR_WORKFLOW_DEBUGGING_PROTOCOL.md +252 -0
- package/skills-library/methodology/tech-debt-tracker.md +570 -0
- package/skills-library/parallel-debug/SKILL.md +60 -0
- package/skills-library/patterns-standards/API_PATTERN_FIX_SUMMARY.md +236 -0
- package/skills-library/patterns-standards/BATCH_OPERATIONS_WITH_PROGRESS_MODAL.md +362 -0
- package/skills-library/patterns-standards/CRITICAL_CODING_PATTERNS.md +639 -0
- package/skills-library/patterns-standards/DARK_MODE_MODAL_VISIBILITY.md +258 -0
- package/skills-library/patterns-standards/ERROR_RESILIENCE_IMPLEMENTATION.md +375 -0
- package/skills-library/patterns-standards/ES_MODULE_IMPORT_HOISTING_DOTENV.md +298 -0
- package/skills-library/patterns-standards/NESTED_BACKDROP_FILTER_CSS_ARTIFACT_FIX.md +76 -0
- package/skills-library/patterns-standards/ORDERED_DETECTOR_PIPELINE_GRACEFUL_FALLBACK.md +333 -0
- package/skills-library/patterns-standards/PHASE_IMPORT_ERROR_DEBUGGING.md +271 -0
- package/skills-library/patterns-standards/PYNPUT_GLOBAL_HOTKEY_VK_MATCHING.md +252 -0
- package/skills-library/patterns-standards/REACT_USEEFFECT_CASCADE_RESET_FIX.md +132 -0
- package/skills-library/patterns-standards/SUBMENU_HOVER_DROPDOWN_PATTERN.md +225 -0
- package/skills-library/patterns-standards/TAILWIND_TEXT_VISIBILITY_OVERRIDE.md +322 -0
- package/skills-library/patterns-standards/THEME_AWARE_CSS_VARIABLES_PATTERN.md +209 -0
- package/skills-library/patterns-standards/THEME_USER_OBJECT_PROPERTY_NAMING.md +194 -0
- package/skills-library/patterns-standards/TOOLTIP_BLOCKING_CLICKS_FIX.md +267 -0
- package/skills-library/patterns-standards/claude-code-plugin-structure.md +235 -0
- package/skills-library/patterns-standards/react-i18next-setup.md +429 -0
- package/skills-library/patterns-standards/thesys-c1-generative-ui-integration.md +967 -0
- package/skills-library/plugin-development/CLAUDE_CODE_COMMAND_REGISTRATION_SILENT_FAILURE.md +315 -0
- package/skills-library/plugin-development/plugin-command-namespace-vs-global.md +390 -0
- package/skills-library/plugin-development/plugin-doc-auto-generation.md +172 -0
- package/skills-library/security/GITHUB_REPO_SECURITY_AUDIT.md +115 -0
- package/skills-library/security/admin-deletion-safety.md +396 -0
- package/skills-library/security/application-vuln-patterns.md +477 -0
- package/skills-library/security/env-secrets-manager.md +686 -0
- package/skills-library/security/secure-ai-application-templates.md +347 -0
- package/skills-library/security/sql-injection-prevention-postgresjs.md +151 -0
- package/skills-library/supabase-connection-pooler-fix.md +102 -0
- package/skills-library/system-context/POWERSHELL_BASH_INTEROP.md +82 -0
- package/skills-library/system-context/SERVICE_LIFECYCLE_MANAGEMENT.md +119 -0
- package/skills-library/system-context/SKILL.md +40 -0
- package/skills-library/system-context/WINDOWS_DEV_ENVIRONMENT.md +73 -0
- package/skills-library/testing/E2E_PLAYWRIGHT_PATTERNS.md +99 -0
- package/skills-library/testing/INTEGRATION_TEST_STRATEGY.md +82 -0
- package/skills-library/testing/RED_GREEN_BUGFIX_GATE.md +203 -0
- package/skills-library/testing/TEST_DATA_MANAGEMENT.md +69 -0
- package/skills-library/testing/VITEST_UNIT_TEST_PATTERNS.md +75 -0
- package/skills-library/testing/playwright-api-security-tests.md +202 -0
- package/skills-library/toolbox/SKILL.md +84 -0
- package/skills-library/toolbox/code-graph-and-web-scraping-mcps.md +237 -0
- package/skills-library/ui-ux-pro-max/ACCESSIBILITY_ESSENTIALS.md +115 -0
- package/skills-library/ui-ux-pro-max/DESIGN_SYSTEM_SCAFFOLDING.md +133 -0
- package/skills-library/ui-ux-pro-max/RESPONSIVE_LAYOUT_PATTERNS.md +119 -0
- package/skills-library/ui-ux-pro-max/SKILL.md +386 -0
- package/skills-library/ui-ux-pro-max/data/charts.csv +26 -0
- package/skills-library/ui-ux-pro-max/data/colors.csv +97 -0
- package/skills-library/ui-ux-pro-max/data/icons.csv +101 -0
- package/skills-library/ui-ux-pro-max/data/landing.csv +31 -0
- package/skills-library/ui-ux-pro-max/data/products.csv +97 -0
- package/skills-library/ui-ux-pro-max/data/react-performance.csv +45 -0
- package/skills-library/ui-ux-pro-max/data/stacks/astro.csv +54 -0
- package/skills-library/ui-ux-pro-max/data/stacks/flutter.csv +53 -0
- package/skills-library/ui-ux-pro-max/data/stacks/html-tailwind.csv +56 -0
- package/skills-library/ui-ux-pro-max/data/stacks/jetpack-compose.csv +53 -0
- package/skills-library/ui-ux-pro-max/data/stacks/nextjs.csv +53 -0
- package/skills-library/ui-ux-pro-max/data/stacks/nuxt-ui.csv +51 -0
- package/skills-library/ui-ux-pro-max/data/stacks/nuxtjs.csv +59 -0
- package/skills-library/ui-ux-pro-max/data/stacks/react-native.csv +52 -0
- package/skills-library/ui-ux-pro-max/data/stacks/react.csv +54 -0
- package/skills-library/ui-ux-pro-max/data/stacks/shadcn.csv +61 -0
- package/skills-library/ui-ux-pro-max/data/stacks/svelte.csv +54 -0
- package/skills-library/ui-ux-pro-max/data/stacks/swiftui.csv +51 -0
- package/skills-library/ui-ux-pro-max/data/stacks/vue.csv +50 -0
- package/skills-library/ui-ux-pro-max/data/styles.csv +68 -0
- package/skills-library/ui-ux-pro-max/data/typography.csv +58 -0
- package/skills-library/ui-ux-pro-max/data/ui-reasoning.csv +101 -0
- package/skills-library/ui-ux-pro-max/data/ux-guidelines.csv +100 -0
- package/skills-library/ui-ux-pro-max/data/web-interface.csv +31 -0
- package/skills-library/wordpress-style-theme-components.md +1526 -0
- package/templates/ASSUMPTIONS.md +1 -1
- package/templates/DECISION_LOG.md +0 -1
- package/templates/phase-prompt.md +1 -1
- package/templates/phoenix-comparison.md +6 -6
- package/templates/skill-api-integration.md +106 -0
- package/templates/skill-architecture-pattern.md +92 -0
- package/templates/skill-debug-pattern.md +98 -0
- package/templates/skill-devops-recipe.md +107 -0
- package/templates/skill-general.md +65 -0
- package/templates/skill-ui-component.md +113 -0
- package/tools/uat-runner.py +179 -0
- package/version.json +7 -3
- package/workflows/handoff-session.md +2 -2
- package/workflows/new-project.md +2 -2
- package/workflows/plan-phase.md +1 -1
- package/.claude-plugin/plugin.json +0 -64
- package/skills-library/_general/methodology/LIVE_BREADCRUMB_PROTOCOL.md +0 -242
- package/skills-library/_general/methodology/llm-judge-memory-crud.md +0 -241
- package/skills-library/methodology/REFLEXION_MEMORY_PATTERN.md +0 -183
- package/skills-library/methodology/RESEARCH_BACKED_WORKFLOW_UPGRADE.md +0 -263
- package/skills-library/methodology/SABBATH_REST_PATTERN.md +0 -267
- package/skills-library/methodology/STONE_AND_SCAFFOLD.md +0 -220
- package/skills-library/specialists/api-architecture/api-designer.md +0 -49
- package/skills-library/specialists/api-architecture/graphql-architect.md +0 -49
- package/skills-library/specialists/api-architecture/mcp-developer.md +0 -51
- package/skills-library/specialists/api-architecture/microservices-architect.md +0 -50
- package/skills-library/specialists/api-architecture/websocket-engineer.md +0 -48
- package/skills-library/specialists/backend/django-expert.md +0 -52
- package/skills-library/specialists/backend/fastapi-expert.md +0 -52
- package/skills-library/specialists/backend/laravel-specialist.md +0 -52
- package/skills-library/specialists/backend/nestjs-expert.md +0 -51
- package/skills-library/specialists/backend/rails-expert.md +0 -53
- package/skills-library/specialists/backend/spring-boot-engineer.md +0 -56
- package/skills-library/specialists/data-ml/fine-tuning-expert.md +0 -48
- package/skills-library/specialists/data-ml/ml-pipeline.md +0 -47
- package/skills-library/specialists/data-ml/pandas-pro.md +0 -47
- package/skills-library/specialists/data-ml/rag-architect.md +0 -51
- package/skills-library/specialists/data-ml/spark-engineer.md +0 -47
- package/skills-library/specialists/frontend/angular-architect.md +0 -52
- package/skills-library/specialists/frontend/flutter-expert.md +0 -51
- package/skills-library/specialists/frontend/nextjs-developer.md +0 -54
- package/skills-library/specialists/frontend/react-native-expert.md +0 -50
- package/skills-library/specialists/frontend/vue-expert.md +0 -51
- package/skills-library/specialists/infrastructure/chaos-engineer.md +0 -74
- package/skills-library/specialists/infrastructure/cloud-architect.md +0 -70
- package/skills-library/specialists/infrastructure/database-optimizer.md +0 -64
- package/skills-library/specialists/infrastructure/devops-engineer.md +0 -70
- package/skills-library/specialists/infrastructure/kubernetes-specialist.md +0 -52
- package/skills-library/specialists/infrastructure/monitoring-expert.md +0 -70
- package/skills-library/specialists/infrastructure/sre-engineer.md +0 -70
- package/skills-library/specialists/infrastructure/terraform-engineer.md +0 -51
- package/skills-library/specialists/languages/cpp-pro.md +0 -74
- package/skills-library/specialists/languages/csharp-developer.md +0 -69
- package/skills-library/specialists/languages/dotnet-core-expert.md +0 -54
- package/skills-library/specialists/languages/golang-pro.md +0 -51
- package/skills-library/specialists/languages/java-architect.md +0 -49
- package/skills-library/specialists/languages/javascript-pro.md +0 -68
- package/skills-library/specialists/languages/kotlin-specialist.md +0 -68
- package/skills-library/specialists/languages/php-pro.md +0 -49
- package/skills-library/specialists/languages/python-pro.md +0 -52
- package/skills-library/specialists/languages/react-expert.md +0 -51
- package/skills-library/specialists/languages/rust-engineer.md +0 -50
- package/skills-library/specialists/languages/sql-pro.md +0 -56
- package/skills-library/specialists/languages/swift-expert.md +0 -69
- package/skills-library/specialists/languages/typescript-pro.md +0 -51
- package/skills-library/specialists/platform/atlassian-mcp.md +0 -52
- package/skills-library/specialists/platform/embedded-systems.md +0 -53
- package/skills-library/specialists/platform/game-developer.md +0 -53
- package/skills-library/specialists/platform/salesforce-developer.md +0 -53
- package/skills-library/specialists/platform/shopify-expert.md +0 -49
- package/skills-library/specialists/platform/wordpress-pro.md +0 -49
- package/skills-library/specialists/quality/code-documenter.md +0 -51
- package/skills-library/specialists/quality/code-reviewer.md +0 -67
- package/skills-library/specialists/quality/debugging-wizard.md +0 -51
- package/skills-library/specialists/quality/fullstack-guardian.md +0 -51
- package/skills-library/specialists/quality/legacy-modernizer.md +0 -50
- package/skills-library/specialists/quality/playwright-expert.md +0 -65
- package/skills-library/specialists/quality/spec-miner.md +0 -56
- package/skills-library/specialists/quality/test-master.md +0 -65
- package/skills-library/specialists/security/secure-code-guardian.md +0 -55
- package/skills-library/specialists/security/security-reviewer.md +0 -53
- package/skills-library/specialists/workflow/architecture-designer.md +0 -53
- package/skills-library/specialists/workflow/cli-developer.md +0 -70
- package/skills-library/specialists/workflow/feature-forge.md +0 -65
- package/skills-library/specialists/workflow/prompt-engineer.md +0 -54
- package/skills-library/specialists/workflow/the-fool.md +0 -62
- /package/skills-library/{performance → _general/performance}/cache-augmented-generation.md +0 -0
- /package/skills-library/{debugging → parallel-debug}/FAILURE_TAXONOMY_CLASSIFICATION.md +0 -0
- /package/skills-library/{debugging → parallel-debug}/THREE_AGENT_HYPOTHESIS_DEBUGGING.md +0 -0
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
# Theme-Aware CSS Variables Pattern - Hardcoded Colors to Dynamic Themes
|
|
2
|
+
|
|
3
|
+
## The Problem
|
|
4
|
+
|
|
5
|
+
Components with hardcoded Tailwind color classes (e.g., `bg-white`, `text-slate-600`, `bg-blue-500`) break when the app supports multiple themes. The aurora-borealis dark theme made podcast player text invisible and backgrounds clash because colors were baked into class names.
|
|
6
|
+
|
|
7
|
+
### Why It Was Hard
|
|
8
|
+
|
|
9
|
+
- Tailwind utility classes like `bg-slate-100` compile to fixed hex values — no runtime override
|
|
10
|
+
- `<style jsx>` blocks with hardcoded hex colors (e.g., `color: #1e293b`) also ignore themes
|
|
11
|
+
- Can't use Tailwind's `dark:` variant because themes aren't just light/dark — they're custom palettes
|
|
12
|
+
- Need a pattern that works for BOTH Tailwind classes AND custom CSS (like audio player overrides)
|
|
13
|
+
|
|
14
|
+
### Impact
|
|
15
|
+
|
|
16
|
+
- PodcastPlayer and Podcasts page were unreadable on aurora-borealis theme
|
|
17
|
+
- Any new component using hardcoded colors would have the same problem
|
|
18
|
+
- Fixing one-off is easy; establishing a consistent pattern is the real value
|
|
19
|
+
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
## The Solution
|
|
23
|
+
|
|
24
|
+
### Root Cause
|
|
25
|
+
|
|
26
|
+
Tailwind classes compile to fixed colors at build time. Theme CSS files define CSS custom properties (`--color-primary`, `--color-surface`, etc.) at runtime. Components must reference these variables instead of hardcoded values.
|
|
27
|
+
|
|
28
|
+
### The Pattern: CSS Variables with Fallbacks
|
|
29
|
+
|
|
30
|
+
Replace all hardcoded colors with `var(--color-name, fallback)` where the fallback is the default theme's color.
|
|
31
|
+
|
|
32
|
+
**Three contexts where this applies:**
|
|
33
|
+
|
|
34
|
+
### 1. Inline Styles (for dynamic/theme colors)
|
|
35
|
+
|
|
36
|
+
```jsx
|
|
37
|
+
// ❌ BEFORE - hardcoded, breaks on dark themes
|
|
38
|
+
<div className="bg-white text-slate-600 border-slate-200">
|
|
39
|
+
|
|
40
|
+
// ✅ AFTER - theme-aware with fallbacks
|
|
41
|
+
<div
|
|
42
|
+
className="rounded-xl"
|
|
43
|
+
style={{
|
|
44
|
+
background: 'var(--color-surface, #ffffff)',
|
|
45
|
+
color: 'var(--color-muted, #475569)',
|
|
46
|
+
borderColor: 'var(--color-border, #e2e8f0)',
|
|
47
|
+
}}
|
|
48
|
+
>
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
### 2. CSS-in-JS / Style Blocks (for library overrides)
|
|
52
|
+
|
|
53
|
+
```jsx
|
|
54
|
+
// ❌ BEFORE - audio player hardcoded
|
|
55
|
+
<style jsx global>{`
|
|
56
|
+
.rhap_progress-filled {
|
|
57
|
+
background: linear-gradient(90deg, #3b82f6, #6366f1);
|
|
58
|
+
}
|
|
59
|
+
.rhap_time {
|
|
60
|
+
color: #64748b;
|
|
61
|
+
}
|
|
62
|
+
`}</style>
|
|
63
|
+
|
|
64
|
+
// ✅ AFTER - theme-aware
|
|
65
|
+
<style jsx global>{`
|
|
66
|
+
.rhap_progress-filled {
|
|
67
|
+
background: linear-gradient(90deg, var(--color-primary, #3b82f6), var(--color-accent, #6366f1));
|
|
68
|
+
}
|
|
69
|
+
.rhap_time {
|
|
70
|
+
color: var(--color-muted, #64748b);
|
|
71
|
+
}
|
|
72
|
+
`}</style>
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
### 3. Dynamic Hover/State (JS event handlers)
|
|
76
|
+
|
|
77
|
+
```jsx
|
|
78
|
+
// ❌ BEFORE - hardcoded hover
|
|
79
|
+
onMouseEnter={(e) => e.currentTarget.style.background = '#f3f4f6'}
|
|
80
|
+
|
|
81
|
+
// ✅ AFTER - theme-aware hover
|
|
82
|
+
onMouseEnter={(e) => e.currentTarget.style.background = 'var(--color-surface, #f3f4f6)'}
|
|
83
|
+
onMouseLeave={(e) => e.currentTarget.style.background = 'transparent'}
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
### CSS Variable Reference (Standard Names)
|
|
87
|
+
|
|
88
|
+
| Variable | Purpose | Default Fallback |
|
|
89
|
+
|----------|---------|-----------------|
|
|
90
|
+
| `--color-primary` | Buttons, links, active states | `#2563eb` |
|
|
91
|
+
| `--color-accent` | Secondary highlights, gradients | `#8b5cf6` |
|
|
92
|
+
| `--color-surface` | Card/panel backgrounds | `#ffffff` |
|
|
93
|
+
| `--color-background` | Page background | `#f9fafb` |
|
|
94
|
+
| `--color-text` | Primary text | `#111827` |
|
|
95
|
+
| `--color-muted` | Secondary/subtle text | `#6b7280` |
|
|
96
|
+
| `--color-border` | Borders, dividers | `#e5e7eb` |
|
|
97
|
+
| `--shadow-md` | Box shadow | (theme-defined) |
|
|
98
|
+
|
|
99
|
+
### Advanced: `color-mix()` for Opacity
|
|
100
|
+
|
|
101
|
+
```css
|
|
102
|
+
/* ❌ BEFORE */
|
|
103
|
+
box-shadow: 0 0 6px rgba(59, 130, 246, 0.4);
|
|
104
|
+
|
|
105
|
+
/* ✅ AFTER - works with any theme's primary color */
|
|
106
|
+
box-shadow: 0 0 6px color-mix(in srgb, var(--color-primary, #3b82f6) 40%, transparent);
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
### Advanced: Active/Selected State
|
|
110
|
+
|
|
111
|
+
```jsx
|
|
112
|
+
style={{
|
|
113
|
+
background: isCurrent
|
|
114
|
+
? 'color-mix(in srgb, var(--color-primary, #2563eb) 10%, transparent)'
|
|
115
|
+
: 'transparent',
|
|
116
|
+
}}
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
---
|
|
120
|
+
|
|
121
|
+
## When to Use Each Approach
|
|
122
|
+
|
|
123
|
+
| Scenario | Approach |
|
|
124
|
+
|----------|----------|
|
|
125
|
+
| Simple colors (bg, text, border) | `style={{ color: 'var(--color-text, #111)' }}` |
|
|
126
|
+
| Tailwind utilities that DON'T change per theme | Keep Tailwind classes (`rounded-xl`, `px-4`, `font-medium`) |
|
|
127
|
+
| Third-party library CSS overrides | `<style jsx global>` with CSS variables |
|
|
128
|
+
| Hover/active states | JS event handlers with CSS variables |
|
|
129
|
+
| Gradients | `linear-gradient(var(--color-primary), var(--color-accent))` |
|
|
130
|
+
| Semi-transparent overlays | `color-mix(in srgb, var(--color-primary) 10%, transparent)` |
|
|
131
|
+
|
|
132
|
+
---
|
|
133
|
+
|
|
134
|
+
## Testing the Fix
|
|
135
|
+
|
|
136
|
+
### Visual Test
|
|
137
|
+
1. Switch theme to aurora-borealis (dark)
|
|
138
|
+
2. Switch theme to default (light)
|
|
139
|
+
3. All text should be readable on both
|
|
140
|
+
4. All backgrounds should match theme palette
|
|
141
|
+
5. Interactive states (hover, active) should use theme colors
|
|
142
|
+
|
|
143
|
+
### Quick Grep Check
|
|
144
|
+
```bash
|
|
145
|
+
# Find remaining hardcoded colors in a component
|
|
146
|
+
grep -n "bg-white\|bg-slate\|text-slate\|text-gray\|border-slate" client/src/components/YourComponent.jsx
|
|
147
|
+
# Expected: 0 matches for theme-sensitive elements
|
|
148
|
+
|
|
149
|
+
# Find hardcoded hex in style blocks
|
|
150
|
+
grep -n "#[0-9a-fA-F]\{6\}" client/src/components/YourComponent.jsx
|
|
151
|
+
# Expected: only inside var() fallbacks
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
---
|
|
155
|
+
|
|
156
|
+
## Prevention
|
|
157
|
+
|
|
158
|
+
1. **New components:** Always use `var(--color-name, fallback)` for any color that should change with theme
|
|
159
|
+
2. **Keep Tailwind for layout:** `flex`, `gap-4`, `rounded-xl`, `px-6` — these don't need theming
|
|
160
|
+
3. **Fallbacks are required:** Always provide a fallback value in case CSS variable isn't defined
|
|
161
|
+
4. **Test on aurora-borealis:** It's the dark theme — if it looks good there AND default, you're covered
|
|
162
|
+
|
|
163
|
+
---
|
|
164
|
+
|
|
165
|
+
## Real-World Example: PodcastPlayer.jsx
|
|
166
|
+
|
|
167
|
+
**Files Modified:**
|
|
168
|
+
- `client/src/components/PodcastPlayer.jsx` (35 lines changed)
|
|
169
|
+
- `client/src/pages/Podcasts.jsx` (474 insertions, 273 deletions)
|
|
170
|
+
|
|
171
|
+
**Commit:** `583f978 feat(podcasts): Spotify-inspired layout with theme-aware styling`
|
|
172
|
+
|
|
173
|
+
**What Changed:**
|
|
174
|
+
- All `bg-white`, `bg-slate-*`, `text-slate-*` → CSS variable inline styles
|
|
175
|
+
- All hardcoded hex in `<style jsx>` → CSS variables
|
|
176
|
+
- Gradients use `var(--color-primary)` and `var(--color-accent)`
|
|
177
|
+
- Box shadows use `color-mix()` for theme-aware opacity
|
|
178
|
+
|
|
179
|
+
---
|
|
180
|
+
|
|
181
|
+
## Common Mistakes to Avoid
|
|
182
|
+
|
|
183
|
+
- ❌ **Using Tailwind color classes for themed elements** — `bg-white` compiles to `#fff`, not overridable
|
|
184
|
+
- ❌ **Forgetting fallbacks** — `var(--color-primary)` without fallback breaks if variable missing
|
|
185
|
+
- ❌ **Over-converting** — Layout utilities like `rounded-lg`, `px-4`, `flex` don't need theming
|
|
186
|
+
- ❌ **Using `rgba()` with CSS variables** — Use `color-mix()` instead for opacity
|
|
187
|
+
- ❌ **Mixing approaches** — Pick inline styles for theme colors, keep Tailwind for layout. Be consistent.
|
|
188
|
+
|
|
189
|
+
---
|
|
190
|
+
|
|
191
|
+
## Resources
|
|
192
|
+
|
|
193
|
+
- [CSS Custom Properties (MDN)](https://developer.mozilla.org/en-US/docs/Web/CSS/Using_CSS_custom_properties)
|
|
194
|
+
- [color-mix() (MDN)](https://developer.mozilla.org/en-US/docs/Web/CSS/color_value/color-mix)
|
|
195
|
+
- Project theme files: `themes/aurora-borealis/styles/theme.css`
|
|
196
|
+
- Theme guide: `docs/THEME_COMPLETE_DEVELOPER_GUIDE.md`
|
|
197
|
+
|
|
198
|
+
## Time to Implement
|
|
199
|
+
|
|
200
|
+
**30-60 minutes** per component (find-and-replace hardcoded colors → CSS variables)
|
|
201
|
+
|
|
202
|
+
## Difficulty Level
|
|
203
|
+
|
|
204
|
+
⭐⭐ (2/5) - Simple pattern, just requires discipline and consistency
|
|
205
|
+
|
|
206
|
+
---
|
|
207
|
+
|
|
208
|
+
**Author Notes:**
|
|
209
|
+
The key insight is that Tailwind is great for LAYOUT but terrible for THEMING when you have custom themes beyond light/dark. CSS variables bridge the gap perfectly — you get Tailwind's layout utilities plus runtime color switching. The fallback values mean components still look good even without a theme loaded.
|
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
# Theme User Object Property Naming Mismatch - Solution & Prevention
|
|
2
|
+
|
|
3
|
+
## The Problem
|
|
4
|
+
|
|
5
|
+
Theme components display "User" instead of the actual user's first name (e.g., "FirstName") in the header navigation. The profile avatar initial also shows "U" instead of the first letter of the name.
|
|
6
|
+
|
|
7
|
+
### Error/Symptom
|
|
8
|
+
```
|
|
9
|
+
Expected: [Avatar] FirstName ▼
|
|
10
|
+
Actual: [Avatar] User ▼
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
No console errors thrown - this is a silent data mismatch.
|
|
14
|
+
|
|
15
|
+
### Why It Was Hard
|
|
16
|
+
|
|
17
|
+
- No error messages - the fallback `|| 'User'` silently hides the bug
|
|
18
|
+
- The property naming difference is subtle: `first_name` (snake_case) vs `firstName` (camelCase)
|
|
19
|
+
- Theme components are isolated from the main app (no shared type system)
|
|
20
|
+
- Different themes may use different property names depending on who wrote them
|
|
21
|
+
- The backend auth response and localStorage user object aren't documented in any shared schema
|
|
22
|
+
|
|
23
|
+
### Impact
|
|
24
|
+
|
|
25
|
+
- Users see "User" instead of their name across the entire site header
|
|
26
|
+
- Affects all logged-in users on any theme with the wrong property names
|
|
27
|
+
- Professional appearance degraded
|
|
28
|
+
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
## The Solution
|
|
32
|
+
|
|
33
|
+
### Root Cause
|
|
34
|
+
|
|
35
|
+
The backend `authController.js` login response sends the user object with **camelCase** properties:
|
|
36
|
+
|
|
37
|
+
```javascript
|
|
38
|
+
// server/controllers/authController.js (login response)
|
|
39
|
+
{
|
|
40
|
+
id: user.id,
|
|
41
|
+
name: user.name, // "Userlastname" (full name)
|
|
42
|
+
firstName, // "FirstName" (parsed from name)
|
|
43
|
+
lastName, // "lastname" (parsed from name)
|
|
44
|
+
email: user.email,
|
|
45
|
+
role: user.role,
|
|
46
|
+
avatar_url: user.avatar_url,
|
|
47
|
+
isVerified: user.email_verified,
|
|
48
|
+
email_verified: user.email_verified,
|
|
49
|
+
}
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
But theme components were written using **snake_case** properties:
|
|
53
|
+
|
|
54
|
+
```javascript
|
|
55
|
+
// BAD - Theme Header.jsx
|
|
56
|
+
{user?.first_name || 'User'} // first_name doesn't exist!
|
|
57
|
+
{user?.first_name} {user?.last_name} // Both undefined!
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
### How to Fix
|
|
61
|
+
|
|
62
|
+
Replace snake_case with camelCase, with fallbacks to `name` parsing:
|
|
63
|
+
|
|
64
|
+
```javascript
|
|
65
|
+
// GOOD - Theme Header.jsx
|
|
66
|
+
|
|
67
|
+
// Display first name (with fallback to parsing full name)
|
|
68
|
+
{user?.firstName || user?.name?.split(' ')[0] || 'User'}
|
|
69
|
+
|
|
70
|
+
// Display full name in dropdown
|
|
71
|
+
{user?.firstName || user?.name?.split(' ')[0]} {user?.lastName || user?.name?.split(' ').slice(1).join(' ')}
|
|
72
|
+
|
|
73
|
+
// Avatar initial
|
|
74
|
+
{user?.firstName?.charAt(0) || user?.name?.charAt(0) || user?.email?.charAt(0) || 'U'}
|
|
75
|
+
|
|
76
|
+
// Alt text
|
|
77
|
+
alt={user?.firstName || user?.name || 'User'}
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
### Why the Fallback Pattern
|
|
81
|
+
|
|
82
|
+
The `user?.name?.split(' ')[0]` fallback handles:
|
|
83
|
+
1. Old user objects cached in localStorage before `firstName` was added
|
|
84
|
+
2. Any code path that stores only `name` without parsing
|
|
85
|
+
3. Edge case where user logs in through a different auth flow
|
|
86
|
+
|
|
87
|
+
---
|
|
88
|
+
|
|
89
|
+
## Complete User Object Reference
|
|
90
|
+
|
|
91
|
+
### From `authController.js` Login Response:
|
|
92
|
+
```javascript
|
|
93
|
+
{
|
|
94
|
+
id: "uuid",
|
|
95
|
+
name: "Userlastname", // Full name (always present)
|
|
96
|
+
firstName: "FirstName", // Parsed first name
|
|
97
|
+
lastName: "lastname", // Parsed last name
|
|
98
|
+
email: "FirstName@example.com",
|
|
99
|
+
role: "admin", // admin | manager | moderator | student
|
|
100
|
+
avatar_url: "/uploads/...", // Profile picture URL
|
|
101
|
+
isVerified: true,
|
|
102
|
+
email_verified: true,
|
|
103
|
+
}
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
### Properties NOT Available (common mistakes):
|
|
107
|
+
- `first_name` (snake_case) - DOES NOT EXIST
|
|
108
|
+
- `last_name` (snake_case) - DOES NOT EXIST
|
|
109
|
+
- `avatarUrl` (camelCase) - exists in some contexts but `avatar_url` is primary
|
|
110
|
+
- `username` - not used in this LMS
|
|
111
|
+
- `displayName` - not used
|
|
112
|
+
|
|
113
|
+
---
|
|
114
|
+
|
|
115
|
+
## Testing the Fix
|
|
116
|
+
|
|
117
|
+
### Before
|
|
118
|
+
```
|
|
119
|
+
Header shows: [green circle with "U"] User ▼
|
|
120
|
+
Dropdown shows: "undefined undefined" and "user@email.com"
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
### After
|
|
124
|
+
```
|
|
125
|
+
Header shows: [green circle with "T"] User▼
|
|
126
|
+
Dropdown shows: "Userlastname" and "FirstName@email.com"
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
### Quick Test
|
|
130
|
+
1. Log in as any user
|
|
131
|
+
2. Check header navigation - should show first name
|
|
132
|
+
3. Open dropdown - should show full name and email
|
|
133
|
+
4. Check mobile sidebar - should show first name
|
|
134
|
+
|
|
135
|
+
---
|
|
136
|
+
|
|
137
|
+
## Prevention
|
|
138
|
+
|
|
139
|
+
1. **Always check `authController.js`** for the actual user object shape before using properties in themes
|
|
140
|
+
2. **Use camelCase** for user properties in themes: `firstName`, `lastName`, `avatarUrl`
|
|
141
|
+
3. **Always add fallbacks**: `user?.firstName || user?.name?.split(' ')[0] || 'User'`
|
|
142
|
+
4. **Check ALL themes** when fixing one - there are 8 themes in this project
|
|
143
|
+
5. **Document the user object** in THEME_DEVELOPMENT.md so theme authors know the correct properties
|
|
144
|
+
|
|
145
|
+
### Themes to Check:
|
|
146
|
+
```
|
|
147
|
+
themes/the-mountain/ (FIXED 2026-02-14)
|
|
148
|
+
themes/eden/
|
|
149
|
+
themes/aurora-borealis/
|
|
150
|
+
themes/celestial/
|
|
151
|
+
themes/melchizedek-order/
|
|
152
|
+
themes/prophetic-academy/
|
|
153
|
+
themes/prosperity/
|
|
154
|
+
themes/royal-priesthood/
|
|
155
|
+
```
|
|
156
|
+
|
|
157
|
+
---
|
|
158
|
+
|
|
159
|
+
## Related Patterns
|
|
160
|
+
|
|
161
|
+
- Theme components use `window.__LMS_AUTH__` or `localStorage.getItem('user')` for auth
|
|
162
|
+
- The `useAuth()` hook in themes reads from these sources
|
|
163
|
+
- Main app header (`client/src/components/layout/Header.jsx`) uses Redux store which has different property access
|
|
164
|
+
|
|
165
|
+
---
|
|
166
|
+
|
|
167
|
+
## Common Mistakes to Avoid
|
|
168
|
+
|
|
169
|
+
- Don't use `user?.first_name` (snake_case) - backend sends `firstName` (camelCase)
|
|
170
|
+
- Don't use `user?.last_name` (snake_case) - backend sends `lastName` (camelCase)
|
|
171
|
+
- Don't assume `firstName` always exists - add `name?.split(' ')[0]` fallback
|
|
172
|
+
- Don't forget theme files are in `.gitignore` - use `git add -f themes/...` to stage
|
|
173
|
+
- Don't fix only one theme - check all 8 themes for the same issue
|
|
174
|
+
|
|
175
|
+
---
|
|
176
|
+
|
|
177
|
+
## Resources
|
|
178
|
+
|
|
179
|
+
- `server/controllers/authController.js` lines 103-129 - Login response user object
|
|
180
|
+
- `themes/THEME_DEVELOPMENT.md` - Theme development guide
|
|
181
|
+
- `docs/THEME_COMPLETE_DEVELOPER_GUIDE.md` - Complete theme developer guide
|
|
182
|
+
|
|
183
|
+
## Time to Implement
|
|
184
|
+
|
|
185
|
+
**5 minutes per theme** - Simple find/replace of property names with fallbacks
|
|
186
|
+
|
|
187
|
+
## Difficulty Level
|
|
188
|
+
|
|
189
|
+
Stars: 2/5 - Easy fix once you know the root cause, hard to diagnose initially because of silent fallback to 'User'
|
|
190
|
+
|
|
191
|
+
---
|
|
192
|
+
|
|
193
|
+
**Author Notes:**
|
|
194
|
+
This cost ~30 minutes to diagnose because "User" appearing instead of a name could have many causes (auth not loading, user object empty, wrong hook, etc.). The silent `|| 'User'` fallback made it invisible. The key insight: always verify the actual shape of the user object from the backend before writing theme code. Run `JSON.stringify(JSON.parse(localStorage.getItem('user')))` in the browser console to see exactly what's there.
|
|
@@ -0,0 +1,267 @@
|
|
|
1
|
+
# Tooltip Blocking Clicks - Pointer Events Solution
|
|
2
|
+
|
|
3
|
+
## The Problem
|
|
4
|
+
|
|
5
|
+
Clickable elements (like Strong's numbers, buttons, or links) become unclickable when a tooltip appears over them. The tooltip overlay intercepts click events before they reach the underlying interactive element.
|
|
6
|
+
|
|
7
|
+
### Symptoms
|
|
8
|
+
|
|
9
|
+
- Hover works (tooltip appears correctly)
|
|
10
|
+
- Click does nothing (no event handler fires)
|
|
11
|
+
- Server logs show API calls from hover (tooltip data fetch)
|
|
12
|
+
- Browser console shows NO click logs (event never reaches handler)
|
|
13
|
+
- User clicks multiple times with no response
|
|
14
|
+
|
|
15
|
+
### Why It Was Hard
|
|
16
|
+
|
|
17
|
+
- **Silent failure** - No error messages, clicks just silently fail
|
|
18
|
+
- **Timing-dependent** - Only happens when tooltip is visible (after hover delay)
|
|
19
|
+
- **Z-index confusion** - High z-index tooltip covers clickable area
|
|
20
|
+
- **Event propagation** - Tooltip intercepts events before they bubble down
|
|
21
|
+
|
|
22
|
+
### Impact
|
|
23
|
+
|
|
24
|
+
- Feature appears completely broken to users
|
|
25
|
+
- Users think the button/link doesn't work
|
|
26
|
+
- Frustrating UX - "I'm clicking but nothing happens!"
|
|
27
|
+
- Can affect critical workflows (concordance panels, modals, navigation)
|
|
28
|
+
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
## The Solution
|
|
32
|
+
|
|
33
|
+
### Root Cause
|
|
34
|
+
|
|
35
|
+
The tooltip is absolutely positioned with a high z-index (`z-50`) and appears directly over the clickable element. When the user clicks, the tooltip receives the click event instead of the underlying button/link.
|
|
36
|
+
|
|
37
|
+
**Bad Code (Blocks Clicks):**
|
|
38
|
+
```tsx
|
|
39
|
+
<span className="tooltip-wrapper relative inline-block">
|
|
40
|
+
<button onClick={handleClick}>Click Me</button>
|
|
41
|
+
{showTooltip && (
|
|
42
|
+
<span className="absolute z-50 px-2 py-1 bg-gray-900 rounded">
|
|
43
|
+
Tooltip Text
|
|
44
|
+
</span>
|
|
45
|
+
)}
|
|
46
|
+
</span>
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
### How to Fix
|
|
50
|
+
|
|
51
|
+
Add `pointer-events-none` to the tooltip so mouse events pass through to underlying elements:
|
|
52
|
+
|
|
53
|
+
**Good Code (Allows Clicks):**
|
|
54
|
+
```tsx
|
|
55
|
+
<span className="tooltip-wrapper relative inline-block">
|
|
56
|
+
<button onClick={handleClick}>Click Me</button>
|
|
57
|
+
{showTooltip && (
|
|
58
|
+
<span className="absolute z-50 px-2 py-1 bg-gray-900 rounded pointer-events-none">
|
|
59
|
+
Tooltip Text
|
|
60
|
+
</span>
|
|
61
|
+
)}
|
|
62
|
+
</span>
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
### Complete Working Example
|
|
66
|
+
|
|
67
|
+
```tsx
|
|
68
|
+
import { useState } from 'react';
|
|
69
|
+
|
|
70
|
+
interface TooltipProps {
|
|
71
|
+
children: React.ReactNode;
|
|
72
|
+
content: string;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export function Tooltip({ children, content }: TooltipProps) {
|
|
76
|
+
const [show, setShow] = useState(false);
|
|
77
|
+
const [hoverTimeout, setHoverTimeout] = useState<NodeJS.Timeout | null>(null);
|
|
78
|
+
|
|
79
|
+
const handleMouseEnter = () => {
|
|
80
|
+
// 500ms delay before showing tooltip
|
|
81
|
+
const timeout = setTimeout(() => setShow(true), 500);
|
|
82
|
+
setHoverTimeout(timeout);
|
|
83
|
+
};
|
|
84
|
+
|
|
85
|
+
const handleMouseLeave = () => {
|
|
86
|
+
if (hoverTimeout) {
|
|
87
|
+
clearTimeout(hoverTimeout);
|
|
88
|
+
setHoverTimeout(null);
|
|
89
|
+
}
|
|
90
|
+
setShow(false);
|
|
91
|
+
};
|
|
92
|
+
|
|
93
|
+
return (
|
|
94
|
+
<span
|
|
95
|
+
className="tooltip-wrapper relative inline-block"
|
|
96
|
+
onMouseEnter={handleMouseEnter}
|
|
97
|
+
onMouseLeave={handleMouseLeave}
|
|
98
|
+
>
|
|
99
|
+
{children}
|
|
100
|
+
{show && (
|
|
101
|
+
<span className="absolute z-50 px-2 py-1 text-xs font-medium text-white bg-gray-900 rounded shadow-lg whitespace-nowrap -top-8 left-1/2 transform -translate-x-1/2 pointer-events-none">
|
|
102
|
+
{content}
|
|
103
|
+
{/* Tooltip arrow (also needs pointer-events-none on parent) */}
|
|
104
|
+
<span className="absolute w-2 h-2 bg-gray-900 transform rotate-45 -bottom-1 left-1/2 -translate-x-1/2"></span>
|
|
105
|
+
</span>
|
|
106
|
+
)}
|
|
107
|
+
</span>
|
|
108
|
+
);
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
// Usage
|
|
112
|
+
<Tooltip content="Click to open concordance">
|
|
113
|
+
<button onClick={() => console.log('Clicked!')}>
|
|
114
|
+
Strong's #H7225
|
|
115
|
+
</button>
|
|
116
|
+
</Tooltip>
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
---
|
|
120
|
+
|
|
121
|
+
## Testing the Fix
|
|
122
|
+
|
|
123
|
+
### Debugging Strategy
|
|
124
|
+
|
|
125
|
+
1. **Add console.logs to click handler:**
|
|
126
|
+
```typescript
|
|
127
|
+
const handleClick = () => {
|
|
128
|
+
console.log('Click event fired!'); // Should see this
|
|
129
|
+
// ... rest of handler
|
|
130
|
+
};
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
2. **Test with tooltip hidden:**
|
|
134
|
+
- Click immediately (before tooltip appears)
|
|
135
|
+
- Should work ✅
|
|
136
|
+
|
|
137
|
+
3. **Test with tooltip visible:**
|
|
138
|
+
- Hover until tooltip appears (wait 500ms)
|
|
139
|
+
- Click while tooltip is visible
|
|
140
|
+
- Should work ✅ (after adding pointer-events-none)
|
|
141
|
+
|
|
142
|
+
### Before Fix
|
|
143
|
+
```
|
|
144
|
+
Browser Console: (nothing - click never reaches handler)
|
|
145
|
+
Server Logs: GET /api/tooltip/data (hover working)
|
|
146
|
+
User Action: Click, click, click... (frustrated)
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
### After Fix
|
|
150
|
+
```
|
|
151
|
+
Browser Console: "Click event fired!"
|
|
152
|
+
Server Logs: GET /api/tooltip/data, POST /api/action (both working)
|
|
153
|
+
User Action: Click (success!)
|
|
154
|
+
```
|
|
155
|
+
|
|
156
|
+
---
|
|
157
|
+
|
|
158
|
+
## Prevention
|
|
159
|
+
|
|
160
|
+
### Checklist for Interactive Tooltips
|
|
161
|
+
|
|
162
|
+
- ✅ **Always add `pointer-events-none`** to tooltip overlays
|
|
163
|
+
- ✅ **Test clicks while tooltip is visible** (not just when hidden)
|
|
164
|
+
- ✅ **Add console.log debugging** to verify events fire
|
|
165
|
+
- ✅ **Check z-index values** - high z-index means potential click blocking
|
|
166
|
+
- ✅ **Test on different browsers** - event handling can vary
|
|
167
|
+
|
|
168
|
+
### Code Review Questions
|
|
169
|
+
|
|
170
|
+
When reviewing tooltip implementations:
|
|
171
|
+
1. Does the tooltip have `pointer-events-none`?
|
|
172
|
+
2. Can you click the underlying element while hovering?
|
|
173
|
+
3. Are there console logs to verify click events?
|
|
174
|
+
4. Is the z-index appropriate (not unnecessarily high)?
|
|
175
|
+
|
|
176
|
+
---
|
|
177
|
+
|
|
178
|
+
## Related Patterns
|
|
179
|
+
|
|
180
|
+
- [Modal Dialog Click Outside Detection](./MODAL_CLICK_OUTSIDE_FIX.md)
|
|
181
|
+
- [Dropdown Menu Event Handling](./DROPDOWN_EVENT_HANDLING.md)
|
|
182
|
+
- [Z-Index Stacking Context Guide](./Z_INDEX_STACKING_MEMORY.md)
|
|
183
|
+
|
|
184
|
+
---
|
|
185
|
+
|
|
186
|
+
## Common Mistakes to Avoid
|
|
187
|
+
|
|
188
|
+
- ❌ **Removing z-index** - Tooltip won't appear on top
|
|
189
|
+
- ❌ **Stopping event propagation** - Breaks other handlers
|
|
190
|
+
- ❌ **Using display: none on hover** - Tooltip flickers
|
|
191
|
+
- ❌ **Not testing with tooltip visible** - Only test when hidden
|
|
192
|
+
- ❌ **Assuming clicks work because hover works** - Different events!
|
|
193
|
+
|
|
194
|
+
---
|
|
195
|
+
|
|
196
|
+
## CSS Pointer Events Reference
|
|
197
|
+
|
|
198
|
+
```css
|
|
199
|
+
/* No pointer events - clicks pass through */
|
|
200
|
+
pointer-events: none;
|
|
201
|
+
|
|
202
|
+
/* Default - element receives events */
|
|
203
|
+
pointer-events: auto;
|
|
204
|
+
|
|
205
|
+
/* Only on visible parts (ignores transparent areas) */
|
|
206
|
+
pointer-events: visible;
|
|
207
|
+
|
|
208
|
+
/* Never receives events (even when visible) */
|
|
209
|
+
pointer-events: none;
|
|
210
|
+
```
|
|
211
|
+
|
|
212
|
+
**Key insight:** `pointer-events: none` makes the element "invisible" to the mouse cursor for interaction purposes, while still being visually displayed.
|
|
213
|
+
|
|
214
|
+
---
|
|
215
|
+
|
|
216
|
+
## Resources
|
|
217
|
+
|
|
218
|
+
- [MDN: pointer-events](https://developer.mozilla.org/en-US/docs/Web/CSS/pointer-events)
|
|
219
|
+
- [React Event Handling](https://react.dev/learn/responding-to-events)
|
|
220
|
+
- [CSS Z-Index and Stacking Context](https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_positioned_layout/Understanding_z-index/Stacking_context)
|
|
221
|
+
- [Tooltip Accessibility Best Practices](https://www.w3.org/WAI/ARIA/apg/patterns/tooltip/)
|
|
222
|
+
|
|
223
|
+
---
|
|
224
|
+
|
|
225
|
+
## Time to Implement
|
|
226
|
+
|
|
227
|
+
**2 minutes** - Just add `pointer-events-none` to tooltip className
|
|
228
|
+
|
|
229
|
+
## Difficulty Level
|
|
230
|
+
|
|
231
|
+
⭐ (1/5) - Extremely simple once you know the solution, but hard to diagnose initially
|
|
232
|
+
|
|
233
|
+
---
|
|
234
|
+
|
|
235
|
+
## Real-World Example: Ministry LLM Strong's Numbers
|
|
236
|
+
|
|
237
|
+
**Context:** Bible study app with Strong's numbers (H7225, G430, etc.) that should open a concordance panel when clicked. Hovering shows Hebrew/Greek text in a tooltip.
|
|
238
|
+
|
|
239
|
+
**Problem:** Clicking Strong's numbers did nothing. Users couldn't access concordances.
|
|
240
|
+
|
|
241
|
+
**Diagnosis:**
|
|
242
|
+
- Server logs showed tooltip API calls working (`GET /api/strongs/H7225`)
|
|
243
|
+
- Browser console showed NO click logs (handler never fired)
|
|
244
|
+
- This proved the tooltip was blocking clicks
|
|
245
|
+
|
|
246
|
+
**Solution:** Added `pointer-events-none` to tooltip at line 79 of StrongsTooltip.tsx
|
|
247
|
+
|
|
248
|
+
**Result:** Clicks now pass through tooltip to underlying `<sup>` element, concordance panel opens correctly.
|
|
249
|
+
|
|
250
|
+
---
|
|
251
|
+
|
|
252
|
+
**Author Notes:**
|
|
253
|
+
|
|
254
|
+
This bug is **deceptively simple** - the fix is one CSS class, but the debugging process requires understanding:
|
|
255
|
+
1. Event propagation and capture
|
|
256
|
+
2. Z-index stacking contexts
|
|
257
|
+
3. The difference between hover events (work) and click events (blocked)
|
|
258
|
+
|
|
259
|
+
The key diagnostic insight: **Server logs show hover working, browser console shows no click logs = tooltip blocking clicks.**
|
|
260
|
+
|
|
261
|
+
Always test interactive elements with overlays visible, not just hidden!
|
|
262
|
+
|
|
263
|
+
---
|
|
264
|
+
|
|
265
|
+
**Created:** 2026-02-09
|
|
266
|
+
**Last Updated:** 2026-02-09
|
|
267
|
+
**Tested With:** React 18, Tailwind CSS, TypeScript
|