@salesforce/afv-skills 1.54.0 → 1.56.0
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/package.json +1 -1
- package/skills/agentforce-generate/SKILL.md +8 -0
- package/skills/agentforce-generate/references/actions-reference.md +2 -2
- package/skills/agentforce-generate/references/voice-modality-reference.md +51 -15
- package/skills/agentforce-generate/references/voice-telephony-cli.md +193 -0
- package/skills/agentforce-observe/SKILL.md +13 -9
- package/skills/agentforce-observe/references/ahm-alerts.md +193 -14
- package/skills/automation-sandbox-post-copy-config-generate/SKILL.md +24 -15
- package/skills/automation-sandbox-post-copy-config-generate/assets/config_template.json +11 -0
- package/skills/automation-sandbox-post-copy-config-generate/assets/json_schema.json +33 -1
- package/skills/automation-sandbox-post-copy-config-generate/references/configuration_catalog.md +32 -1
- package/skills/automation-sandbox-post-copy-configure/SKILL.md +75 -71
- package/skills/automation-sandbox-post-copy-configure/assets/scheduled_apex_template.apex +13 -0
- package/skills/automation-sandbox-post-copy-configure/examples/sample_scheduled_apex_config.json +13 -0
- package/skills/automation-sandbox-post-copy-configure/references/scheduled_apex_path.md +155 -0
- package/skills/automation-sandbox-post-copy-configure/scripts/build-scheduled-apex.mjs +62 -0
- package/skills/automation-sandbox-post-copy-configure/scripts/soql-escape-job-name.mjs +28 -0
- package/skills/consumer-goods-accruals-datakit-deploy/SKILL.md +383 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/setup.js +324 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/00-check-prerequisites.js +63 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/01-download-static-resource.js +100 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/02-replace-org-id.js +46 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/03-deploy-metadata.js +46 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/04-deploy-engine.js +198 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/05-deploy-tpm-accruals.js +231 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/06-create-dataspace.js +82 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/07-deploy-accruals-reports.js +517 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/08-deploy-ui.js +416 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/09-completion.js +44 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/utils.js +514 -0
- package/skills/consumer-goods-sync-management-configure/SKILL.md +137 -0
- package/skills/consumer-goods-sync-management-configure/examples/scenarios.md +294 -0
- package/skills/consumer-goods-sync-management-configure/references/act1-setup-sync.md +333 -0
- package/skills/consumer-goods-sync-management-configure/references/act2-assign-users.md +324 -0
- package/skills/consumer-goods-sync-management-configure/references/act3-plan-verify.md +113 -0
- package/skills/consumer-goods-sync-management-configure/references/readiness-and-enablement.md +164 -0
- package/skills/consumer-goods-sync-management-configure/references/sync-management-app-install-backbone.md +159 -0
- package/skills/consumer-goods-sync-management-configure/references/transports-and-namespace.md +220 -0
- package/skills/consumer-goods-sync-management-configure/references/verify-and-smoke.md +175 -0
- package/skills/dx-org-analyze/README.md +310 -0
- package/skills/dx-org-analyze/SKILL.md +260 -0
- package/skills/dx-org-analyze/references/collection-details.md +88 -0
- package/skills/dx-org-analyze/references/report-format.md +67 -0
- package/skills/dx-org-analyze/scripts/collect_org_data.py +823 -0
- package/skills/dx-org-analyze/scripts/compute_diff.py +1101 -0
- package/skills/dx-org-analyze/scripts/introspect_org.py +400 -0
- package/skills/dx-org-analyze/tests/README.md +46 -0
- package/skills/dx-org-analyze/tests/fixtures/org_a.json +76 -0
- package/skills/dx-org-analyze/tests/fixtures/org_b.json +70 -0
- package/skills/dx-org-analyze/tests/test_compute_diff.sh +284 -0
- package/skills/dx-org-analyze/tests/test_consistency.sh +428 -0
- package/skills/dx-org-manage/SKILL.md +6 -50
- package/skills/dx-org-manage/examples/README.md +10 -16
- package/skills/dx-org-manage/references/scratch-org-create.md +1 -1
- package/skills/dx-org-manage/references/scratch-org-operations.md +1 -1
- package/skills/dx-org-shape-manage/SKILL.md +4 -3
- package/skills/education-cloud-domain-configure/references/gotchas-extended.md +1 -0
- package/skills/experience-accessibility-validate/SKILL.md +8 -5
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-1-1-non-text-content.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-i-lists.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-ii-tables.md +20 -85
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-iii-form-labels.md +4 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-iv-regions.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-v-groups.md +2 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-5-identify-input.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-4-3-contrast.md +4 -14
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-1-1-keyboard.md +9 -5
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-4-4-link-purpose.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-4-6-headings-labels.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-5-1-pointer-gestures.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-5-2-pointer-cancellation.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-5-3-label-in-name.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-5-7-dragging-movement.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-3-2-1-on-focus.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-3-2-2-on-input.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-3-3-1-error-identification.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-3-3-2-labels-instructions.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-3-3-3-error-suggestion.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-4-1-2-i-name.md +4 -5
- package/skills/experience-accessibility-validate/references/reviewers/sc-4-1-2-ii-role.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-4-1-2-iii-value.md +0 -4
- package/skills/experience-design-validate/SKILL.md +163 -0
- package/skills/experience-design-validate/references/ai.md +54 -0
- package/skills/experience-design-validate/references/components.md +61 -0
- package/skills/experience-design-validate/references/craft.md +158 -0
- package/skills/experience-design-validate/references/data.md +59 -0
- package/skills/experience-design-validate/references/forms-flows.md +57 -0
- package/skills/experience-design-validate/references/interaction.md +53 -0
- package/skills/experience-design-validate/references/navigation.md +51 -0
- package/skills/experience-design-validate/references/performance.md +56 -0
- package/skills/experience-design-validate/references/records.md +60 -0
- package/skills/experience-design-validate/references/responsive.md +48 -0
- package/skills/experience-design-validate/references/scoring-rubric.md +257 -0
- package/skills/experience-design-validate/references/state.md +53 -0
- package/skills/experience-design-validate/references/trust.md +47 -0
- package/skills/experience-design-validate/references/usability.md +35 -0
- package/skills/experience-design-validate/references/visual-system.md +183 -0
- package/skills/experience-lwc-accessibility-jest-run/SKILL.md +104 -25
- package/skills/experience-lwc-accessibility-jest-run/assets/jest.config.js +4 -0
- package/skills/experience-lwc-accessibility-jest-run/assets/sa11y-jest-setup.js +5 -0
- package/skills/experience-ui-bundle-app-coordinate/SKILL.md +5 -5
- package/skills/experience-ui-bundle-features-generate/SKILL.md +65 -36
- package/skills/experience-ui-bundle-features-generate/references/angular/features.md +74 -0
- package/skills/experience-ui-bundle-features-generate/references/react/features.md +59 -0
- package/skills/experience-ui-bundle-features-generate/scripts/detect-framework.sh +73 -0
- package/skills/experience-ui-bundle-frontend-generate/SKILL.md +2 -2
- package/skills/experience-ui-bundle-metadata-generate/SKILL.md +26 -14
- package/skills/experience-ui-bundle-metadata-generate/references/angular-metadata-generate.md +37 -0
- package/skills/experience-ui-bundle-metadata-generate/references/react-metadata-generate.md +32 -0
- package/skills/experience-ui-bundle-metadata-generate/scripts/detect-framework.sh +73 -0
- package/skills/experience-ui-bundle-metadata-generate/scripts/verify-bundle-location.sh +30 -8
- package/skills/field-service-data-capture-migrate/SKILL.md +391 -0
- package/skills/field-service-data-capture-migrate/assets/sample-legacy-flow.flow-meta.xml +163 -0
- package/skills/field-service-data-capture-migrate/references/architecture-notes.md +40 -0
- package/skills/field-service-data-capture-migrate/references/component-mapping.md +278 -0
- package/skills/field-service-data-capture-migrate/references/converter-builder-contract.md +183 -0
- package/skills/field-service-data-capture-migrate/references/dc-platform-rules.md +130 -0
- package/skills/field-service-data-capture-migrate/references/fsm-dc-capability-catalog.md +215 -0
- package/skills/field-service-data-capture-migrate/references/known-deploy-errors.md +36 -0
- package/skills/field-service-data-capture-migrate/references/migration-checklist.md +121 -0
- package/skills/field-service-data-capture-migrate/references/transformer-rules.md +132 -0
- package/skills/field-service-data-capture-migrate/scripts/analyze_flow.py +277 -0
- package/skills/field-service-data-capture-migrate/scripts/convert_to_dc_spec.py +1311 -0
- package/skills/field-service-data-capture-migrate/scripts/cud_analysis.py +402 -0
- package/skills/field-service-data-capture-migrate/scripts/deploy_flow.sh +230 -0
- package/skills/field-service-data-capture-migrate/scripts/discover_subflow_tree.py +230 -0
- package/skills/field-service-data-capture-migrate/scripts/flow_input.py +186 -0
- package/skills/field-service-data-capture-migrate/scripts/flow_xml_utils.py +39 -0
- package/skills/field-service-data-capture-migrate/scripts/fsm_dc_catalog.py +413 -0
- package/skills/field-service-data-capture-migrate/scripts/generate_summary.py +199 -0
- package/skills/field-service-data-capture-migrate/scripts/json_to_flow_xml.py +146 -0
- package/skills/field-service-data-capture-migrate/scripts/manual_review_flags.py +42 -0
- package/skills/field-service-data-capture-migrate/scripts/retrieve_flow_rest.sh +155 -0
- package/skills/field-service-data-capture-migrate/scripts/subflow_names.py +49 -0
- package/skills/field-service-data-capture-migrate/scripts/transform_flow.py +1661 -0
- package/skills/field-service-data-capture-migrate/scripts/validate_flow.sh +147 -0
- package/skills/field-service-data-capture-migrate/scripts/vendor/build_flow.py +1258 -0
- package/skills/life-sciences-fieldsalesrep-coordinate/SKILL.md +1 -1
- package/skills/life-sciences-fieldsalesrep-coordinate/references/orchestration-flow.md +1 -1
- package/skills/life-sciences-kam-coordinate/references/stage-5-data-and-plan-templates-overview.md +14 -1
- package/skills/mobile-apps-create/SKILL.md +1 -1
- package/skills/{platform-agentsetup-categories-fetch → platform-agenticsetup-categories-get}/SKILL.md +7 -7
- package/skills/platform-sandbox-configure/SKILL.md +108 -133
- package/skills/platform-sandbox-configure/references/api-response-shapes.md +39 -0
- package/skills/platform-sandbox-configure/references/definition-file-approach.md +73 -0
- package/skills/platform-widget-generate/SKILL.md +26 -18
- package/skills/platform-widget-generate/examples/formulas.json +191 -0
- package/skills/platform-widget-generate/references/widget-formulas.md +123 -0
- package/skills/platform-widget-generate/references/widget-meta-directives.md +4 -4
- package/skills/sales-call-scoring-configure/SKILL.md +318 -0
- package/skills/sales-call-scoring-configure/assets/best-practice-competencies.json +67 -0
- package/skills/sales-call-scoring-configure/assets/ootb-competencies.json +58 -0
- package/skills/sales-call-scoring-configure/references/admin-communication.md +79 -0
- package/skills/sales-call-scoring-configure/references/competency-crud.md +130 -0
- package/skills/sales-call-scoring-configure/scripts/create-competency.sh +166 -0
- package/skills/sales-call-scoring-configure/scripts/create-custom-competency.sh +166 -0
- package/skills/sales-call-scoring-configure/scripts/edit-competency.sh +185 -0
- package/skills/sales-call-scoring-configure/scripts/edit-custom-competency.sh +190 -0
- package/skills/sales-call-scoring-configure/scripts/enable-call-scoring.sh +436 -0
- package/skills/sales-call-scoring-configure/scripts/get-competency.sh +72 -0
- package/skills/sales-call-scoring-configure/scripts/get-custom-competency.sh +78 -0
- package/skills/sales-call-scoring-configure/scripts/install-best-practice-competencies.sh +223 -0
- package/skills/sales-call-scoring-configure/scripts/install-ootb-competencies.sh +237 -0
- package/skills/sales-call-scoring-configure/scripts/list-competencies.sh +99 -0
- package/skills/sales-call-scoring-configure/scripts/shared/auth.sh +116 -0
- package/skills/sales-call-scoring-configure/scripts/shared/cap.sh +86 -0
- package/skills/sales-call-scoring-configure/scripts/shared/soap.sh +267 -0
- package/skills/sales-call-scoring-configure/scripts/shared/soql.sh +25 -0
- package/skills/sales-call-scoring-configure/scripts/toggle-competency.sh +112 -0
- package/skills/sales-call-scoring-configure/scripts/toggle-custom-competency.sh +125 -0
- package/skills/sales-call-scoring-configure/scripts/verify-ootb-competencies.sh +116 -0
- package/skills/service-concierge-portal-generate/references/portal-deploy-runbook.md +1 -0
- package/skills/service-de-channel-activate/SKILL.md +6 -5
- package/skills/service-de-channel-create/SKILL.md +3 -3
- package/skills/service-de-channel-routing-configure/SKILL.md +3 -3
- package/skills/service-de-channel-settings-configure/SKILL.md +195 -0
- package/skills/service-de-channel-settings-configure/references/channel-settings-facets.md +152 -0
- package/skills/{service-de-channel-consent-configure → service-de-channel-settings-configure}/references/gotchas.md +3 -3
- package/skills/{service-de-channel-consent-configure → service-de-channel-settings-configure}/references/language-keywords.md +4 -4
- package/skills/{service-de-channel-consent-configure → service-de-channel-settings-configure}/references/worked-examples.md +14 -14
- package/skills/service-de-headless-channel-configure/SKILL.md +6 -6
- package/skills/service-de-headless-channel-configure/references/worked-examples.md +1 -1
- package/skills/service-helpagent-coordinate/SKILL.md +3 -2
- package/skills/service-helpagent-coordinate/references/channel-voice.md +15 -4
- package/skills/service-itsm-agentic-setup-agentforce-coordinate/SKILL.md +49 -31
- package/skills/service-itsm-agentic-setup-agentforce-coordinate/examples/output-templates.md +71 -6
- package/skills/service-itsm-agentic-setup-agentforce-coordinate/scripts/verify-child-verdict.mjs +26 -4
- package/skills/service-itsm-agentic-setup-cmdb-access-assign/SKILL.md +35 -10
- package/skills/service-itsm-agentic-setup-cmdb-access-assign/references/mcp-invocation.md +25 -5
- package/skills/service-itsm-agentic-setup-cmdb-bundle-deploy/SKILL.md +1 -1
- package/skills/service-itsm-agentic-setup-cmdb-configure/SKILL.md +5 -5
- package/skills/service-itsm-agentic-setup-cmdb-configure/references/mcp-invocation.md +1 -1
- package/skills/service-itsm-agentic-setup-cmdb-coordinate/SKILL.md +2 -2
- package/skills/service-itsm-agentic-setup-cmdb-coordinate/examples/output-templates.md +1 -1
- package/skills/service-itsm-agentic-setup-cmdb-discovery-configure/SKILL.md +25 -15
- package/skills/service-itsm-agentic-setup-employee-agent-configure/SKILL.md +8 -5
- package/skills/service-itsm-agentic-setup-employee-agent-configure/references/report-format.md +4 -2
- package/skills/service-itsm-agentic-setup-employee-agent-configure/references/workflow-detail.md +1 -1
- package/skills/service-itsm-agentic-setup-employee-agent-configure/scripts/render-report.mjs +29 -16
- package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/SKILL.md +8 -5
- package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/references/report-format.md +4 -2
- package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/references/workflow-detail.md +1 -1
- package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/scripts/render-report.mjs +29 -16
- package/skills/service-itsm-agentic-setup-incident-management/SKILL.md +138 -68
- package/skills/service-itsm-agentic-setup-incident-management/examples/output-templates.md +31 -15
- package/skills/service-itsm-agentic-setup-incident-management/references/incident-persona-psg.md +156 -0
- package/skills/service-itsm-agentic-setup-incident-management/references/incident-preferences.md +148 -0
- package/skills/service-itsm-agentic-setup-incident-management/references/major-incident-management.md +162 -0
- package/skills/service-itsm-agentic-setup-incident-management/references/service-mgmt-privilege.md +149 -0
- package/skills/service-itsm-agentic-setup-incident-sla-configure/SKILL.md +103 -89
- package/skills/service-itsm-agentic-setup-incident-sla-configure/assets/attach-milestone.json +2 -2
- package/skills/service-itsm-agentic-setup-incident-sla-configure/assets/predefined-incident-policy.json +21 -39
- package/skills/service-itsm-agentic-setup-incident-sla-configure/examples/milestone-patterns.md +3 -3
- package/skills/service-itsm-agentic-setup-incident-sla-configure/examples/output-templates.md +18 -1
- package/skills/service-itsm-agentic-setup-incident-sla-configure/references/mcp-invocation.md +63 -37
- package/skills/service-omni-attribute-routing-configure/SKILL.md +53 -0
- package/skills/service-omni-attribute-routing-configure/references/api-notes.md +7 -0
- package/skills/service-omni-attribute-routing-configure/scripts/configure-and-report.sh +224 -0
- package/skills/service-omni-attribute-routing-configure/scripts/tests/test_attribute_routing_contracts.py +137 -0
- package/skills/service-omni-channel-inventory-analyze/SKILL.md +96 -0
- package/skills/service-omni-channel-inventory-analyze/references/api-notes.md +52 -0
- package/skills/service-omni-channel-inventory-analyze/scripts/analyze.sh +185 -0
- package/skills/service-omni-channel-inventory-analyze/scripts/tests/_bootstrap.py +84 -0
- package/skills/service-omni-channel-inventory-analyze/scripts/tests/test_inventory_analyze_contracts.py +141 -0
- package/skills/service-omni-channel-limits-analyze/SKILL.md +70 -0
- package/skills/service-omni-channel-limits-analyze/references/api-notes.md +22 -0
- package/skills/service-omni-channel-limits-analyze/scripts/analyze.sh +159 -0
- package/skills/service-omni-channel-limits-analyze/scripts/tests/_bootstrap.py +87 -0
- package/skills/service-omni-channel-limits-analyze/scripts/tests/test_limits_analyze_contracts.py +99 -0
- package/skills/service-omni-channel-setup-coordinate/SKILL.md +12 -20
- package/skills/service-omni-channel-setup-coordinate/scripts/integration-driver.sh +55 -5
- package/skills/service-omni-channel-setup-coordinate/scripts/tests/test_omni_contracts.py +38 -0
- package/skills/service-omni-command-center-analyze/SKILL.md +2 -2
- package/skills/service-omni-command-center-analyze/scripts/analyze.sh +3 -3
- package/skills/dx-org-manage/examples/snapshots/error_output.json +0 -9
- package/skills/dx-org-manage/examples/snapshots/success_output.json +0 -15
- package/skills/dx-org-manage/references/cli_flags.md +0 -67
- package/skills/dx-org-manage/references/creating-snapshot.md +0 -103
- package/skills/dx-org-manage/references/snapshot_usage.md +0 -74
- package/skills/experience-accessibility-validate/scripts/contrast-ratio.py +0 -153
- package/skills/experience-lwc-accessibility-jest-run/references/running-sa11y-jest-tests.md +0 -205
- package/skills/experience-ui-bundle-features-generate/scripts/verify-react-bundle.sh +0 -14
- /package/skills/experience-ui-bundle-features-generate/references/{conflict-resolution-schema.json → common/conflict-resolution-schema.json} +0 -0
- /package/skills/{platform-agentsetup-categories-fetch → platform-agenticsetup-categories-get}/references/api-response-schema.md +0 -0
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
# State Management UX
|
|
2
|
+
|
|
3
|
+
> **Load this reference for `DYNAMIC_VISUAL` evidence of state transitions. Static captures may support critique of a depicted state's visible treatment, but cannot substantiate state coverage, transition behavior, save behavior, recovery, or timing; mark those areas `INSUFFICIENT_EVIDENCE`.**
|
|
4
|
+
|
|
5
|
+
The craft of state is the craft of in-between moments — the loading shimmer, the empty canvas, the recovered failure. A well-crafted product feels considered in these moments: the skeleton matches the layout, the spinner is sized for its container, the empty state has been designed rather than left as blank space, the error feels like part of the product instead of something escaping from the database.
|
|
6
|
+
|
|
7
|
+
## Why this matters
|
|
8
|
+
|
|
9
|
+
Most products are judged on their happy path, but craft reveals itself in the transitions and edge cases. A loading state that shimmers in the exact shape of what's coming feels like a designed product; a generic full-page spinner feels like an unfinished one. An empty state with a thoughtful illustration and a clear next action feels like a host welcoming you in; a blank screen feels like a dead end. When a design is polished in these moments, the product feels alive and tended to. When it isn't, every wait, error, and empty view chips away at trust.
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## Loading
|
|
14
|
+
|
|
15
|
+
- **The indicator matches the wait.** Instant feedback for micro-operations, an inline spinner for short waits, a skeleton for longer ones, real progress for anything substantial. A spinner that flashes for a fraction of a second is worse than silence.
|
|
16
|
+
- **Skeletons mirror the shape of what's coming.** Same dimensions, same item count, same layout. When the real content arrives, nothing shifts.
|
|
17
|
+
- **Progress is honest.** A determinate bar moves with confidence. Fake or jumpy progress trains users to distrust every indicator the product will ever show them.
|
|
18
|
+
- **The page never goes blank between routes.** Navigation lights up the new destination immediately and uses a skeleton or crossfade for the body.
|
|
19
|
+
|
|
20
|
+
## Errors
|
|
21
|
+
|
|
22
|
+
- **Severity matches visual weight.** Inline notes for fields, banners for sections, page-level treatments for global failures. When everything is the same shade of red, nothing reads as urgent.
|
|
23
|
+
- **Errors speak to the user, not the database.** A message names what went wrong and how to recover — never a stack trace, never an opaque code.
|
|
24
|
+
- **Errors don't delete the user's work.** Submission failure preserves every valid field, scrolls to the first problem, and shows how many remain. Reversible mistakes get undo, not pre-confirmation.
|
|
25
|
+
|
|
26
|
+
## Empty
|
|
27
|
+
|
|
28
|
+
- **Empty is designed, not abandoned.** A short, situational headline; a sentence of context; a way forward. Blank space is a defect.
|
|
29
|
+
- **The flavor of empty is communicated.** "Nothing yet" reads differently from "no matches" reads differently from "you don't have access." Empty tables keep their headers.
|
|
30
|
+
|
|
31
|
+
## Offline and Sync
|
|
32
|
+
|
|
33
|
+
- **Offline is a state, not an error.** It's communicated calmly — visible but not alarming, self-removing the moment connectivity returns. Local interactions still feel alive; pending changes are visible. No silent data loss, ever.
|
|
34
|
+
- **Sync is invisible when it works.** Indicators only appear during active syncing, pending changes, or conflicts. Conflicts surface immediately with both values visible. Stale presence is worse than no presence.
|
|
35
|
+
|
|
36
|
+
## Optimism and Long Jobs
|
|
37
|
+
|
|
38
|
+
- **Optimism is reserved for the safe.** Reversible, rarely-failing changes show instantly. Destructive or financial changes don't. Rollback explains itself rather than reverting silently.
|
|
39
|
+
- **Long work doesn't trap the user.** Operations beyond a handful of seconds become jobs the user can navigate away from. Progress, time, and current activity are visible. Completion finds the user wherever they went. Cancellation is always honest about what happens to partial results.
|
|
40
|
+
|
|
41
|
+
---
|
|
42
|
+
|
|
43
|
+
## Scoring Guide
|
|
44
|
+
|
|
45
|
+
**Contributes to dimensions: Reliable, Usable**
|
|
46
|
+
|
|
47
|
+
| Score | Criteria |
|
|
48
|
+
|-------|----------|
|
|
49
|
+
| 9-10 | The in-between moments are designed. Loading, errors, empty, offline, sync, and long jobs all feel considered. The product feels tended to even when nothing is happening. |
|
|
50
|
+
| 7-8 | State handling is solid for primary flows with minor gaps at edges. |
|
|
51
|
+
| 5-6 | Generic errors, blank empty states, basic save behavior. The polish drops away outside the happy path. |
|
|
52
|
+
| 3-4 | States unmanaged. Silent failures. Blocking spinners. The product feels brittle. |
|
|
53
|
+
| 1-2 | Lost connection loses work. States show nothing. Trust is broken. |
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# Trust & Safety
|
|
2
|
+
|
|
3
|
+
> **Skip this reference if the design shows no auth surfaces, no privacy controls, no permission UI, no destructive settings, and no risk-bearing actions.**
|
|
4
|
+
|
|
5
|
+
Craft in trust surfaces is the visual proof that a product takes consequences seriously. It shows up in the placement of a verification icon, the elevation of a danger zone, the restraint of a sensitive-data mask, the calibrated visual weight of a warning versus a critical confirmation. This reference judges the visual treatment of trust signals, the staging of authentication, and the progressive elevation of risk surfaces.
|
|
6
|
+
|
|
7
|
+
## Why this matters
|
|
8
|
+
|
|
9
|
+
Trust is a felt quality, not a feature — and craft is what makes a user feel safe before they read any copy. When craft is high, sensitive moments feel deliberate: the lock icon sits where the eye expects it, the danger zone is visually quarantined from the rest of the settings, warnings escalate in visual weight as stakes increase, and confirmations carry the right amount of friction without theatrics. When craft is low, trust surfaces feel either gaudy (every action a red banner) or careless (a destructive button styled like a save button). The visual register of risk is something users absorb subconsciously — a misstep here is the difference between confidence and unease.
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## Trust Signals
|
|
14
|
+
|
|
15
|
+
- **Visual polish is itself a trust signal.** Misaligned elements, mismatched typography, and broken layouts read as carelessness with everything else — including the user's data.
|
|
16
|
+
- **Verification indicators sit where the eye expects them.** A single recognizable icon, placed consistently across the product, with a quiet explanation on hover.
|
|
17
|
+
- **Sensitive data is masked by default.** A visibility toggle returns it on demand. Showing a credit card number or a phone number unprompted reads as careless.
|
|
18
|
+
|
|
19
|
+
## Authentication
|
|
20
|
+
|
|
21
|
+
- **Login is staged, not stuffed.** Identity first, credential second. A single mega-form for everything reads as bureaucratic.
|
|
22
|
+
- **Password fields are forgiving.** A show/hide toggle and live validation reduce the anxiety of typing into a black box.
|
|
23
|
+
|
|
24
|
+
## Consent
|
|
25
|
+
|
|
26
|
+
- **Cookie banners don't trap the user.** Dismissing without accepting is as easy as accepting. "Essential only" carries the same visual weight as "Accept all." A banner that blocks content until the user accepts reads as coercive.
|
|
27
|
+
|
|
28
|
+
## Risk Communication
|
|
29
|
+
|
|
30
|
+
- **Severity escalates with consequence.** Informational notes, cautionary highlights, warnings that pause the user, and critical confirmations that demand typing — each carries a distinct visual weight. When everything is the same shade of red, nothing reads as urgent.
|
|
31
|
+
- **Warnings appear before the point of no return.** Not after, not during — before. A warning that arrives after the action committed is theater.
|
|
32
|
+
- **The same severity treatment is never used for unequal risks.** When archiving and deleting wear the same warning, the user stops trusting the warnings.
|
|
33
|
+
- **Destructive settings are visually quarantined.** A "danger zone" set apart from ordinary settings — not interleaved with everyday toggles where a misclick is one row away.
|
|
34
|
+
|
|
35
|
+
---
|
|
36
|
+
|
|
37
|
+
## Scoring Guide
|
|
38
|
+
|
|
39
|
+
**Contributes to dimensions: Reliable, Coherent, Well-Crafted**
|
|
40
|
+
|
|
41
|
+
| Score | Criteria |
|
|
42
|
+
|-------|----------|
|
|
43
|
+
| 9-10 | Trust is earned through every interaction. Sensitive moments feel deliberate. Risk is calibrated. The danger zone is unmistakable. |
|
|
44
|
+
| 7-8 | Trust patterns are mostly consistent with minor gaps in disclosure or symmetry. |
|
|
45
|
+
| 5-6 | Bundled consent. Inconsistent warning severity. A few dark patterns. |
|
|
46
|
+
| 3-4 | Dark patterns. Invasive defaults. The product feels indifferent to consequence. |
|
|
47
|
+
| 1-2 | Trust is actively broken. Hidden data collection. Misleading consent. |
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# Usability
|
|
2
|
+
|
|
3
|
+
> **Skip this reference if the design has no decisions to make, no actions to take, and no flow to navigate — i.e. nothing for craft to make smoother.**
|
|
4
|
+
|
|
5
|
+
Usability craft is the difference between a product that you operate and one that operates with you. It's the visible system status that tells you the save went through, the predictable interaction that lets you trust your muscle memory, the consistent pattern that makes the second use easier than the first. Good usability craft is invisible when it works — you just feel competent. Poor usability craft makes you feel stupid for not knowing where the controls are.
|
|
6
|
+
|
|
7
|
+
## Why this matters
|
|
8
|
+
|
|
9
|
+
Designs win or lose on the small moments of feedback and predictability. When a click produces an immediate visible response, when a state change is announced through motion or color, when consistent patterns mean the user never has to relearn — the product feels responsive and trustworthy. When those moments are missing, every interaction carries doubt: did it work, am I in the right place, is this the same control I used yesterday. Craft here is about respect — respecting the user's time, attention, and prior learning by making the system answer back when spoken to.
|
|
10
|
+
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
## Feedback and Predictability
|
|
14
|
+
|
|
15
|
+
- **The system answers back when spoken to.** Every action produces a visible response — a state change, a confirmation, a transition — within the moment of the click. Silence reads as broken.
|
|
16
|
+
- **Patterns repeat.** The same kind of action looks and behaves the same across the product. When a "save" feels different on two screens, the user has to relearn instead of trust their muscle memory.
|
|
17
|
+
- **The user's place in the system is always visible.** Where they are, what's selected, what they just did. A page that wipes context after every interaction asks the user to rebuild it constantly.
|
|
18
|
+
- **Edges are designed.** Empty states, errors, loading, and success all feel like part of the same product — not afterthoughts grafted onto the happy path.
|
|
19
|
+
- **Hierarchy matches priority.** What's important looks important. When secondary actions outweigh primary ones visually, the user has to fight the design to do the right thing.
|
|
20
|
+
- **Interactive elements look interactive.** A button that looks like a label, a link that looks like static text, a card that hides a click target — each forces the user to discover by trial.
|
|
21
|
+
- **Simpler is preferred when both work.** Two controls where one would do, three options where two cover the cases — the extras add cognitive load without adding capability.
|
|
22
|
+
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
## Scoring Guide
|
|
26
|
+
|
|
27
|
+
**Contributes to dimensions: Usable, Useful, Well-Crafted**
|
|
28
|
+
|
|
29
|
+
| Score | Criteria |
|
|
30
|
+
|-------|----------|
|
|
31
|
+
| 9-10 | Edges are designed. Interactive elements look interactive. Hierarchy matches priority. The product responds to every input with visible craft. |
|
|
32
|
+
| 7-8 | Most flows feel responsive and predictable. Minor gaps in edge-state polish. |
|
|
33
|
+
| 5-6 | Happy path is fine; edges feel unfinished. Some controls don't feel interactive. |
|
|
34
|
+
| 3-4 | Inconsistent feedback. Edge states neglected. Hierarchy fights the user. |
|
|
35
|
+
| 1-2 | No visible system response. Interactions feel unanswered. |
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
# Visual System
|
|
2
|
+
|
|
3
|
+
> **Always load for any visual design. Skip only if the input is purely textual or pre-visual (a wireframe with no visual decisions yet made).**
|
|
4
|
+
|
|
5
|
+
What does the design look like? This reference judges the felt qualities of the visual system — layout, typography, color, surfaces, and visual assets — at the level a designer would discuss them in a critique. Not at the level of CSS variables.
|
|
6
|
+
|
|
7
|
+
## Why this matters
|
|
8
|
+
|
|
9
|
+
The visual system is the voice of the product. It's what users see before they read a word. A coherent visual system feels like one person made it; a fragmented one feels like a committee shipped it. Two designers can have the same layout brief and end up in completely different places — one with a system that feels intentional and quiet, one with a system that feels accumulated and loud.
|
|
10
|
+
|
|
11
|
+
Visual system findings are about *taste applied consistently*. The eye notices when the type sizes don't relate to each other, when the grays are slightly off from each other, when borders happen sometimes and not other times, when icons are different weights, when avatars are different sizes. None of these failures is catastrophic alone. Together, they're what separates "looks pro" from "looks built."
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
## Layout
|
|
16
|
+
|
|
17
|
+
### What good layout feels like
|
|
18
|
+
|
|
19
|
+
- **One focal point per screen.** The eye knows where to land first. Everything else is calmer.
|
|
20
|
+
- **Generous whitespace around what matters.** Primary actions and headlines have air around them. Density is reserved for content where users need to compare or scan many items at once.
|
|
21
|
+
- **A consistent rhythm.** The vertical beat of the page is predictable — sections are spaced consistently, and the spacing between a heading and its content is tighter than the spacing between sections.
|
|
22
|
+
- **Aligned, not approximate.** Elements share precise edges, not "near enough" edges. The eye can detect 2-pixel misalignment even when it can't name it.
|
|
23
|
+
- **Density matched to context.** A dev tool earns dense, utilitarian layout. A consumer onboarding screen earns generous breathability. The layout reflects what the product is trying to be.
|
|
24
|
+
|
|
25
|
+
### Felt observations to make
|
|
26
|
+
|
|
27
|
+
- The eye knows where to land within the first second.
|
|
28
|
+
- Primary content is clearly heavier than chrome (toolbars, headers, sidebars).
|
|
29
|
+
- Headings are closer to their content than to the section above.
|
|
30
|
+
- Page margins are equal and don't change between similar pages.
|
|
31
|
+
- Whitespace around primary actions feels deliberate, not accidental.
|
|
32
|
+
- The grid feels consistent — columns don't shift between similar pages.
|
|
33
|
+
- Toolbar heights, sidebar widths, and content margins feel consistent across screens.
|
|
34
|
+
- Sticky headers stay put; scroll position is preserved when navigating away and back.
|
|
35
|
+
|
|
36
|
+
### What weak layout looks like
|
|
37
|
+
|
|
38
|
+
- The eye doesn't know where to start. Multiple things tied for primary.
|
|
39
|
+
- Sections butt up against each other; nothing breathes.
|
|
40
|
+
- Spacing varies subtly between similar screens — same component, different padding.
|
|
41
|
+
- Elements are *almost* aligned (a few pixels off) — looks like a mistake, not a choice.
|
|
42
|
+
- Page margins are uneven; one page has a wide gutter, another has none.
|
|
43
|
+
- Density mismatches the context — a marketing page is dense, a dashboard is sparse.
|
|
44
|
+
|
|
45
|
+
---
|
|
46
|
+
|
|
47
|
+
## Typography
|
|
48
|
+
|
|
49
|
+
### What good typography feels like
|
|
50
|
+
|
|
51
|
+
- **A small set of sizes, used consistently.** The product has 4–6 distinct text sizes that map to clear roles: page heading, section heading, body, label, metadata. Each role has one size. The reader knows what kind of text is what at a glance.
|
|
52
|
+
- **A tight set of weights.** Two or three weights. Bold for headlines, regular for body, perhaps medium for emphasis. Weight isn't sprinkled across the design.
|
|
53
|
+
- **Headlines have presence.** They feel like something to land on, not something to scroll past. The line break is intentional.
|
|
54
|
+
- **Body text is readable.** Lines are at a comfortable length (not edge-to-edge across a wide screen). Line-height is generous enough that reading feels relaxed.
|
|
55
|
+
- **One voice across the product.** The product speaks in one type voice, not three.
|
|
56
|
+
|
|
57
|
+
### Felt observations to make
|
|
58
|
+
|
|
59
|
+
- Type sizes feel like steps in a scale, not arbitrary choices.
|
|
60
|
+
- Headings stand out clearly. The hierarchy is unmistakable.
|
|
61
|
+
- Body text feels comfortable to read at a glance.
|
|
62
|
+
- The number of weights in active use feels small.
|
|
63
|
+
- Numbers in tables align (don't twitch as values change).
|
|
64
|
+
- Truncated text is signaled cleanly with an ellipsis, with full content available on hover or expand.
|
|
65
|
+
- Text doesn't run edge-to-edge across the entire viewport on wide screens.
|
|
66
|
+
|
|
67
|
+
### What weak typography looks like
|
|
68
|
+
|
|
69
|
+
- The product has many sizes that don't relate to each other — 13px, 14px, 15px, 16px all visible.
|
|
70
|
+
- Three or four weights mixed without clear logic.
|
|
71
|
+
- Headings and body text feel similar in weight or size — flat hierarchy.
|
|
72
|
+
- Body text runs the entire width of a wide screen, exhausting to read.
|
|
73
|
+
- Numbers in tables shift position as values change — feels unfinished.
|
|
74
|
+
- Capitalization is inconsistent: "Save Changes" here, "save changes" there, "SAVE" elsewhere.
|
|
75
|
+
|
|
76
|
+
---
|
|
77
|
+
|
|
78
|
+
## Color
|
|
79
|
+
|
|
80
|
+
### What good color feels like
|
|
81
|
+
|
|
82
|
+
- **A small, intentional palette.** The product uses few colors and uses them consistently. Each color earns its place — brand, action, error, success, neutral. Nothing decorative.
|
|
83
|
+
- **Surfaces feel intentional.** Three or four surface tones — page background, card, hover, selected — each visibly distinct. The eye doesn't have to ask "is this a different gray?"
|
|
84
|
+
- **Color signals meaning.** Green is positive, red is negative, the brand color is reserved for primary moments. The mapping is consistent everywhere.
|
|
85
|
+
- **Restraint with accent color.** The brand color appears where it matters — primary actions, key indicators — not as decoration.
|
|
86
|
+
- **Considered dark mode (if present).** Dark mode is its own design, not a color-inverted afterthought.
|
|
87
|
+
|
|
88
|
+
### Felt observations to make
|
|
89
|
+
|
|
90
|
+
- The palette feels tight and disciplined.
|
|
91
|
+
- Surface tones feel distinct from each other — no near-duplicates.
|
|
92
|
+
- The brand or accent color is used sparingly and purposefully.
|
|
93
|
+
- Status colors (positive, negative, warning) are consistent across the product.
|
|
94
|
+
- Dark mode (if present) feels like its own designed surface.
|
|
95
|
+
- Information isn't carried by color alone — pair with icon, label, or position.
|
|
96
|
+
|
|
97
|
+
### What weak color looks like
|
|
98
|
+
|
|
99
|
+
- Many near-identical grays accumulating across surfaces — the eye registers wear.
|
|
100
|
+
- The accent color is everywhere, including decorative uses, so primary actions don't stand out.
|
|
101
|
+
- Status colors flip meaning between views (green meant "complete" here, "ready to start" there).
|
|
102
|
+
- Dark mode looks like a contrast inversion of light mode, not a designed surface.
|
|
103
|
+
- The palette feels accumulated — colors added by different contributors over time.
|
|
104
|
+
|
|
105
|
+
---
|
|
106
|
+
|
|
107
|
+
## Surfaces
|
|
108
|
+
|
|
109
|
+
### What good surfaces feel like
|
|
110
|
+
|
|
111
|
+
- **Cards, panels, modals all feel like one family.** Same border treatment, same radii, same elevation language. A card on one screen is recognizable as a card on another.
|
|
112
|
+
- **Elevation has intent.** When something is lifted (modal, popover, sticky element), the elevation is clear and consistent. Shadows are tasteful, not heavy.
|
|
113
|
+
- **Borders are restrained.** Not every container has a border. When a border appears, it earns its place — separating things that need separating.
|
|
114
|
+
- **Radii are limited.** The product picks one or two corner radii and sticks to them. Cards aren't 4px-rounded in one place and 12px-rounded in another.
|
|
115
|
+
|
|
116
|
+
### Felt observations to make
|
|
117
|
+
|
|
118
|
+
- Cards across the product feel like the same family.
|
|
119
|
+
- Modals and popovers feel like the same family.
|
|
120
|
+
- Borders appear where separation is needed, not as decoration.
|
|
121
|
+
- Shadows are subtle and consistent — same elevation gets the same shadow.
|
|
122
|
+
- Corner radii are consistent within a context.
|
|
123
|
+
|
|
124
|
+
### What weak surfaces look like
|
|
125
|
+
|
|
126
|
+
- Cards on different screens have different radii, different shadows, different border treatments — the family is fragmented.
|
|
127
|
+
- Borders everywhere — every container framed for no reason.
|
|
128
|
+
- Shadows are too heavy or inconsistent — some elements feel like they're floating in front of glass, others feel painted on.
|
|
129
|
+
- A modal looks like a card looks like a popover looks like a panel — no elevation hierarchy.
|
|
130
|
+
|
|
131
|
+
---
|
|
132
|
+
|
|
133
|
+
## Visual Assets
|
|
134
|
+
|
|
135
|
+
### What good visual assets feel like
|
|
136
|
+
|
|
137
|
+
- **Icons are one family.** Same stroke weight, same style (outlined vs filled), same proportions. They look like a set, not a collection.
|
|
138
|
+
- **Icons are sized consistently in the same context.** A toolbar icon is the same size as another toolbar icon.
|
|
139
|
+
- **Imagery has intent.** Photos and illustrations feel chosen, not searched-and-pasted. They support the content, not decorate it.
|
|
140
|
+
- **Avatars are consistent.** Same size, same shape, same fallback treatment.
|
|
141
|
+
- **Empty states have personality.** When the product needs to fill space because there's nothing to show, the design uses the moment — a small illustration, a clear invitation, a personality.
|
|
142
|
+
|
|
143
|
+
### Felt observations to make
|
|
144
|
+
|
|
145
|
+
- Icons feel like a set — consistent stroke weight and style.
|
|
146
|
+
- Icons in similar contexts are similar sizes.
|
|
147
|
+
- Avatars are the same shape (round vs square) across the product.
|
|
148
|
+
- Imagery feels chosen, not generic.
|
|
149
|
+
- Empty states are designed moments, not blank screens with "No items."
|
|
150
|
+
|
|
151
|
+
### What weak visual assets look like
|
|
152
|
+
|
|
153
|
+
- Icons mix outlined and filled styles randomly. Stroke weights vary.
|
|
154
|
+
- Toolbar icons are different sizes from each other.
|
|
155
|
+
- Stock photography that doesn't match the brand voice.
|
|
156
|
+
- Avatars are round in one place, square in another.
|
|
157
|
+
- Empty states are blank, with a generic "No data" string.
|
|
158
|
+
|
|
159
|
+
---
|
|
160
|
+
|
|
161
|
+
## Cross-cutting felt qualities
|
|
162
|
+
|
|
163
|
+
When evaluating the visual system as a whole, ask:
|
|
164
|
+
|
|
165
|
+
- **Does the system feel like it has a point of view?** Or does it feel like an accumulation of contributions?
|
|
166
|
+
- **Could a new contributor extend this system without guessing?** The patterns should be self-documenting.
|
|
167
|
+
- **Does the visual vocabulary feel small?** Disciplined products use few sizes, weights, colors, and shapes — and use them everywhere.
|
|
168
|
+
- **Is anything shouting that doesn't need to?** Bold weights, accent colors, large sizes, and heavy borders should be reserved.
|
|
169
|
+
- **Where does the eye land first? Second? Third?** If you can't answer, hierarchy is broken.
|
|
170
|
+
|
|
171
|
+
---
|
|
172
|
+
|
|
173
|
+
## Scoring Guide
|
|
174
|
+
|
|
175
|
+
**Contributes to dimensions: Well-Crafted, Coherent**
|
|
176
|
+
|
|
177
|
+
| Score | Criteria |
|
|
178
|
+
|-------|----------|
|
|
179
|
+
| 9–10 | The visual system feels disciplined and intentional. Small vocabulary used consistently. Hierarchy is calm; restraint is visible. Surfaces, type, color, and assets all read as one family. The eye lands where it should. |
|
|
180
|
+
| 7–8 | Strong visual system with minor inconsistencies. The discipline is mostly visible; small drift in secondary screens. |
|
|
181
|
+
| 5–6 | Functional but uneven. Some inconsistencies are felt — type sizes drift, surface colors don't quite match, icons are mixed weights. The system reads as accumulated. |
|
|
182
|
+
| 3–4 | Visibly fragmented. Multiple type sizes without logic, color used decoratively, surfaces don't relate, icons from different families. The product feels assembled by different hands. |
|
|
183
|
+
| 1–2 | No visual system. Browser defaults visible; nothing relates to anything else; chaos. |
|
|
@@ -1,14 +1,18 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: experience-lwc-accessibility-jest-run
|
|
3
|
-
description: "Use ALWAYS when running Sa11y accessibility Jest tests for
|
|
3
|
+
description: "Use ALWAYS when running Sa11y accessibility Jest tests for an LWC — locally before pushing, producing the command(s), running one file vs a suite, selecting tests by naming convention, saving Sa11y-rendered HTML, or reproducing a Sa11y/A11yBug failure. Covers core (Bazel; `bazel test //<module>:<target>`) and standalone `npx jest` (`.accessibility.test.js`, `@sa11y/jest`). REQUIRED for a `run-plan.md`, a failing a11y test's exit code, or `SA11Y_*`/`A11yBug`/core-Bazel test paths. DO NOT TRIGGER for functional Jest tests, a11y review without running tests (use experience-accessibility-validate), or Selenium-based a11y tests."
|
|
4
4
|
metadata:
|
|
5
5
|
version: "1.0"
|
|
6
6
|
domains: ["Experience"]
|
|
7
|
+
relatedSkills:
|
|
8
|
+
- "experience-accessibility-validate"
|
|
7
9
|
cliTools:
|
|
10
|
+
- tool: ["node"]
|
|
11
|
+
semver: ">=18.0.0"
|
|
8
12
|
- tool: ["npm"]
|
|
9
13
|
semver: ">=8.0"
|
|
10
14
|
---
|
|
11
|
-
<!--
|
|
15
|
+
<!-- a11y-expert-managed-skill -->
|
|
12
16
|
|
|
13
17
|
# Running LWC Accessibility Jest Tests
|
|
14
18
|
|
|
@@ -19,7 +23,7 @@ Run Sa11y accessibility unit tests on Lightning Web Components in either:
|
|
|
19
23
|
|
|
20
24
|
Selenium-level reproductions, GUS A11yBug ingestion, and other internal
|
|
21
25
|
Salesforce-only flows are out of scope for this skill. For source-code-level
|
|
22
|
-
WCAG review without running tests, see `experience-
|
|
26
|
+
WCAG review without running tests, see `experience-accessibility-validate`.
|
|
23
27
|
|
|
24
28
|
## When to Use This Skill
|
|
25
29
|
|
|
@@ -39,28 +43,101 @@ WCAG review without running tests, see `experience-lwc-accessibility-validate`.
|
|
|
39
43
|
|
|
40
44
|
## Workflow
|
|
41
45
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
46
|
+
Choose the approach based on the environment. If this is not a Salesforce core
|
|
47
|
+
build environment, do not mention the Core workflow.
|
|
48
|
+
|
|
49
|
+
### Core (Bazel)
|
|
50
|
+
|
|
51
|
+
Use this mode when a `WORKSPACE` file is present. The base command is:
|
|
52
|
+
|
|
53
|
+
```bash
|
|
54
|
+
{coreRootPath}/tools/bazel test [TARGET] --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
Replace `{coreRootPath}` with the Core repository root, `{moduleName}` with the
|
|
58
|
+
module name, and `{relativePath}` with the test file path without the `.test.js`
|
|
59
|
+
extension.
|
|
60
|
+
|
|
61
|
+
To discover targets and paths:
|
|
62
|
+
|
|
63
|
+
```bash
|
|
64
|
+
find {coreRootPath}/{moduleName} -name "*.test.js" -type f
|
|
65
|
+
{coreRootPath}/tools/bazel query "tests(//{moduleName}:*)"
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
Component tests typically live under
|
|
69
|
+
`modules/{componentDir}/{componentName}/__tests__/`.
|
|
70
|
+
|
|
71
|
+
Prefer a single-file target when the failing test path is known:
|
|
72
|
+
|
|
73
|
+
```bash
|
|
74
|
+
{coreRootPath}/tools/bazel test //{moduleName}:{relativePath} --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
Run all Sa11y Jest tests in a module when a specific test is not known:
|
|
78
|
+
|
|
79
|
+
```bash
|
|
80
|
+
{coreRootPath}/tools/bazel test //{moduleName}:sa11y_jest_test --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
Multiple module targets can be passed to the same command. To filter tests
|
|
84
|
+
within a module, add `--test_arg=--testMatch="**/{modulePath}/**"`.
|
|
85
|
+
|
|
86
|
+
Useful options:
|
|
87
|
+
|
|
88
|
+
- Update snapshots: `--test_arg="--updateSnapshot"`
|
|
89
|
+
- Disable cached test results: `--cache_test_results=no`
|
|
90
|
+
- Save rendered HTML:
|
|
91
|
+
`--test_env=SA11Y_ENABLE_RENDERED_DOM_SAVE=1 --test_env=SA11Y_RENDERED_DOM_SAVE_PATH=sfdc-test/unit/javascript/htdocs/sa11y/jest`
|
|
92
|
+
|
|
93
|
+
Use `sfdc-test/unit/javascript/htdocs/sa11y/jest` as the rendered DOM save path
|
|
94
|
+
to avoid EPERM errors.
|
|
95
|
+
|
|
96
|
+
### Standalone (Jest)
|
|
97
|
+
|
|
98
|
+
Use this mode when no `WORKSPACE` file is present. Run all accessibility tests:
|
|
99
|
+
|
|
100
|
+
Do **not** prepend `SA11Y_*` environment variables in standalone mode;
|
|
101
|
+
`@sa11y/jest` is activated through the project's Jest setup.
|
|
102
|
+
|
|
103
|
+
```bash
|
|
104
|
+
npm test -- --testMatch="**/*.accessibility.test.js"
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
Or target a specific file:
|
|
108
|
+
|
|
109
|
+
```bash
|
|
110
|
+
npm test -- src/components/MyComponent/__tests__/MyComponent.accessibility.test.js
|
|
111
|
+
```
|
|
112
|
+
|
|
113
|
+
Use the filename or path supplied by the user. When the named test is in the
|
|
114
|
+
current directory, keep a bare filename bare instead of inventing a path.
|
|
115
|
+
|
|
116
|
+
Other useful options are `--coverage`, `--updateSnapshot`, `--watch`, and
|
|
117
|
+
`--verbose`. To target a named test, use
|
|
118
|
+
`npm test -- --testNamePattern="MyComponent accessibility"`.
|
|
119
|
+
|
|
120
|
+
Ensure Jest uses a `jsdom` environment and loads the project's `@sa11y/jest`
|
|
121
|
+
setup file. Copy or adapt the bundled `assets/jest.config.js` template into
|
|
122
|
+
the project's Jest configuration, and copy `assets/sa11y-jest-setup.js` to
|
|
123
|
+
`test/setup/sa11y-setup.js`. If the project already has a Jest configuration,
|
|
124
|
+
merge the relevant settings instead of overwriting unrelated configuration.
|
|
125
|
+
|
|
126
|
+
The `SA11Y_*` variables shown above are for Core/Bazel only; the Bazel commands
|
|
127
|
+
already include them.
|
|
128
|
+
|
|
129
|
+
## Response Scope
|
|
130
|
+
|
|
131
|
+
Answer only what the user asked. Emit the requested command or commands plus
|
|
132
|
+
the relevant exit-code meaning. Do not add watch, coverage, snapshot-update,
|
|
133
|
+
HTML-save, or other variants unless the user requests them.
|
|
134
|
+
|
|
135
|
+
## Expected Exit Codes
|
|
136
|
+
|
|
137
|
+
- Bazel: `0` means all tests passed, `3` means tests failed, and `1` means the
|
|
138
|
+
build or command failed.
|
|
139
|
+
- Jest: `0` means all tests passed and `1` means tests failed or an error
|
|
140
|
+
occurred.
|
|
64
141
|
|
|
65
142
|
|
|
66
143
|
## Verification Checklist
|
|
@@ -77,3 +154,5 @@ explicitly asks for them.
|
|
|
77
154
|
`.test.js` extension in `{relativePath}`.
|
|
78
155
|
- **HTML saving fails with EPERM** — use the prescribed save path
|
|
79
156
|
`sfdc-test/unit/javascript/htdocs/sa11y/jest`.
|
|
157
|
+
- **Standalone tests do not run** — verify the test naming pattern, Jest
|
|
158
|
+
configuration, `@sa11y/jest` dependency, and `jsdom` environment.
|
|
@@ -163,16 +163,16 @@ Search project code (src/) for existing implementations
|
|
|
163
163
|
v
|
|
164
164
|
Install dependencies (npm install)
|
|
165
165
|
v
|
|
166
|
-
Search, describe, and
|
|
166
|
+
Search, describe, and adopt features (auth, shadcn, search, navigation, GraphQL)
|
|
167
167
|
v
|
|
168
168
|
Resolve conflicts (two-pass: --on-conflict error, then --conflict-resolution)
|
|
169
169
|
v
|
|
170
170
|
Integrate __examples__ files into target files (verify build succeeds), then delete them
|
|
171
171
|
```
|
|
172
172
|
|
|
173
|
-
|
|
173
|
+
Loads the feature skill to install pre-built packages, or adopt ones the template already shipped — never build your own version of a catalog feature. See "Prompt Classification Keywords" for triggers and negative-phrasing handling.
|
|
174
174
|
|
|
175
|
-
|
|
175
|
+
Skip only for a minimal "hello world" with no interactive features; pre-shipped features still require this phase.
|
|
176
176
|
|
|
177
177
|
### Phase 2.5: Custom Objects (Required if the prompt requires a new custom Salesforce object the org doesn't have)
|
|
178
178
|
|
|
@@ -378,14 +378,14 @@ Execute each phase sequentially following the standard pattern in `references/ph
|
|
|
378
378
|
---
|
|
379
379
|
|
|
380
380
|
**Phase 0 -- Template Offer & Bootstrap**
|
|
381
|
-
- Load `experience-ui-bundle-project-generate`, offer templates. If chosen: skip Phase 1, continue at Phase
|
|
381
|
+
- Load `experience-ui-bundle-project-generate`, offer templates. If chosen: skip Phase 1, continue at Phase 2. If declined: run `scripts/check-sfdx-project.sh`, create project if missing.
|
|
382
382
|
|
|
383
383
|
**Phase 1 -- Scaffolding** (skip if template used in Phase 0)
|
|
384
384
|
- **Precondition**: `scripts/check-sfdx-project.sh` passes
|
|
385
385
|
- Load `experience-ui-bundle-metadata-generate`. Determine hosting target FIRST. Run `sf template generate ui-bundle --template reactbasic`, configure meta XML with `<target>`.
|
|
386
386
|
- **Post-verification**: `scripts/check-phase-1-complete.sh` passes
|
|
387
387
|
|
|
388
|
-
**Phase 2 -- Features** (
|
|
388
|
+
**Phase 2 -- Features** (run on any feature keyword, even if pre-installed — see "Prompt Classification Keywords")
|
|
389
389
|
- Load `experience-ui-bundle-features-generate`. Install features, integrate examples. Verify with `npm run build`.
|
|
390
390
|
|
|
391
391
|
**Phase 2.5 -- Custom Objects** (skip if org has all needed objects)
|