@salesforce/afv-skills 1.14.0 → 1.15.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/applying-slds/SKILL.md +322 -0
- package/skills/applying-slds/checklists.md +83 -0
- package/skills/applying-slds/examples.md +283 -0
- package/skills/applying-slds/guidance/README.md +83 -0
- package/skills/applying-slds/guidance/blueprints-index.md +213 -0
- package/skills/applying-slds/guidance/icons-guidance.md +186 -0
- package/skills/applying-slds/guidance/overviews/borders.md +236 -0
- package/skills/applying-slds/guidance/overviews/color.md +266 -0
- package/skills/applying-slds/guidance/overviews/display-density.md +366 -0
- package/skills/applying-slds/guidance/overviews/icons.md +240 -0
- package/skills/applying-slds/guidance/overviews/illustrations.md +235 -0
- package/skills/applying-slds/guidance/overviews/shadows.md +176 -0
- package/skills/applying-slds/guidance/overviews/spacing.md +216 -0
- package/skills/applying-slds/guidance/overviews/typography.md +323 -0
- package/skills/applying-slds/guidance/overviews/utilities.md +542 -0
- package/skills/applying-slds/guidance/slds-development-guide.md +288 -0
- package/skills/applying-slds/guidance/styling-hooks/borders.md +202 -0
- package/skills/applying-slds/guidance/styling-hooks/color/expressive-palette-hooks.md +153 -0
- package/skills/applying-slds/guidance/styling-hooks/color/index.md +171 -0
- package/skills/applying-slds/guidance/styling-hooks/color/semantic/accent-hooks.md +204 -0
- package/skills/applying-slds/guidance/styling-hooks/color/semantic/feedback-hooks.md +768 -0
- package/skills/applying-slds/guidance/styling-hooks/color/semantic/surface-hooks.md +337 -0
- package/skills/applying-slds/guidance/styling-hooks/color/system-hooks.md +132 -0
- package/skills/applying-slds/guidance/styling-hooks/index.md +327 -0
- package/skills/applying-slds/guidance/styling-hooks/shadows.md +238 -0
- package/skills/applying-slds/guidance/styling-hooks/spacing.md +254 -0
- package/skills/applying-slds/guidance/styling-hooks/typography.md +448 -0
- package/skills/applying-slds/guidance/utilities/alignment.md +119 -0
- package/skills/applying-slds/guidance/utilities/borders.md +131 -0
- package/skills/applying-slds/guidance/utilities/box.md +125 -0
- package/skills/applying-slds/guidance/utilities/color.md +165 -0
- package/skills/applying-slds/guidance/utilities/dark-mode.md +111 -0
- package/skills/applying-slds/guidance/utilities/description-list.md +168 -0
- package/skills/applying-slds/guidance/utilities/floats.md +117 -0
- package/skills/applying-slds/guidance/utilities/grid.md +264 -0
- package/skills/applying-slds/guidance/utilities/horizontal-list.md +110 -0
- package/skills/applying-slds/guidance/utilities/hyphenation.md +84 -0
- package/skills/applying-slds/guidance/utilities/index.md +205 -0
- package/skills/applying-slds/guidance/utilities/interactions.md +89 -0
- package/skills/applying-slds/guidance/utilities/layout.md +109 -0
- package/skills/applying-slds/guidance/utilities/line-clamp.md +131 -0
- package/skills/applying-slds/guidance/utilities/margin.md +155 -0
- package/skills/applying-slds/guidance/utilities/media-object.md +161 -0
- package/skills/applying-slds/guidance/utilities/name-value-list.md +152 -0
- package/skills/applying-slds/guidance/utilities/padding.md +155 -0
- package/skills/applying-slds/guidance/utilities/position.md +177 -0
- package/skills/applying-slds/guidance/utilities/print.md +114 -0
- package/skills/applying-slds/guidance/utilities/scrollable.md +126 -0
- package/skills/applying-slds/guidance/utilities/sizing.md +190 -0
- package/skills/applying-slds/guidance/utilities/themes.md +121 -0
- package/skills/applying-slds/guidance/utilities/truncate.md +127 -0
- package/skills/applying-slds/guidance/utilities/typography.md +166 -0
- package/skills/applying-slds/guidance/utilities/vertical-list.md +166 -0
- package/skills/applying-slds/guidance/utilities/visibility.md +228 -0
- package/skills/applying-slds/metadata/README.md +84 -0
- package/skills/applying-slds/metadata/blueprints/components/accordion.yaml +304 -0
- package/skills/applying-slds/metadata/blueprints/components/activity-timeline.yaml +92 -0
- package/skills/applying-slds/metadata/blueprints/components/alert.yaml +103 -0
- package/skills/applying-slds/metadata/blueprints/components/app-launcher.yaml +94 -0
- package/skills/applying-slds/metadata/blueprints/components/avatar-group.yaml +81 -0
- package/skills/applying-slds/metadata/blueprints/components/avatar.yaml +97 -0
- package/skills/applying-slds/metadata/blueprints/components/badges.yaml +102 -0
- package/skills/applying-slds/metadata/blueprints/components/brand-band.yaml +198 -0
- package/skills/applying-slds/metadata/blueprints/components/breadcrumbs.yaml +95 -0
- package/skills/applying-slds/metadata/blueprints/components/builder-header.yaml +192 -0
- package/skills/applying-slds/metadata/blueprints/components/button-groups.yaml +82 -0
- package/skills/applying-slds/metadata/blueprints/components/button-icons.yaml +295 -0
- package/skills/applying-slds/metadata/blueprints/components/buttons.yaml +230 -0
- package/skills/applying-slds/metadata/blueprints/components/cards.yaml +124 -0
- package/skills/applying-slds/metadata/blueprints/components/carousel.yaml +140 -0
- package/skills/applying-slds/metadata/blueprints/components/chat.yaml +179 -0
- package/skills/applying-slds/metadata/blueprints/components/checkbox-button-group.yaml +192 -0
- package/skills/applying-slds/metadata/blueprints/components/checkbox-button.yaml +204 -0
- package/skills/applying-slds/metadata/blueprints/components/checkbox-toggle.yaml +177 -0
- package/skills/applying-slds/metadata/blueprints/components/checkbox.yaml +108 -0
- package/skills/applying-slds/metadata/blueprints/components/color-picker.yaml +172 -0
- package/skills/applying-slds/metadata/blueprints/components/combobox.yaml +136 -0
- package/skills/applying-slds/metadata/blueprints/components/counter.yaml +147 -0
- package/skills/applying-slds/metadata/blueprints/components/data-tables.yaml +157 -0
- package/skills/applying-slds/metadata/blueprints/components/datepickers.yaml +130 -0
- package/skills/applying-slds/metadata/blueprints/components/datetime-picker.yaml +155 -0
- package/skills/applying-slds/metadata/blueprints/components/docked-composer.yaml +201 -0
- package/skills/applying-slds/metadata/blueprints/components/docked-form-footer.yaml +161 -0
- package/skills/applying-slds/metadata/blueprints/components/docked-utility-bar.yaml +175 -0
- package/skills/applying-slds/metadata/blueprints/components/drop-zone.yaml +115 -0
- package/skills/applying-slds/metadata/blueprints/components/dueling-picklist.yaml +196 -0
- package/skills/applying-slds/metadata/blueprints/components/dynamic-icons.yaml +128 -0
- package/skills/applying-slds/metadata/blueprints/components/dynamic-menu.yaml +141 -0
- package/skills/applying-slds/metadata/blueprints/components/expandable-section.yaml +115 -0
- package/skills/applying-slds/metadata/blueprints/components/expression.yaml +143 -0
- package/skills/applying-slds/metadata/blueprints/components/feeds.yaml +125 -0
- package/skills/applying-slds/metadata/blueprints/components/file-selector.yaml +154 -0
- package/skills/applying-slds/metadata/blueprints/components/files.yaml +119 -0
- package/skills/applying-slds/metadata/blueprints/components/form-element.yaml +145 -0
- package/skills/applying-slds/metadata/blueprints/components/global-header.yaml +120 -0
- package/skills/applying-slds/metadata/blueprints/components/global-navigation.yaml +100 -0
- package/skills/applying-slds/metadata/blueprints/components/icons.yaml +138 -0
- package/skills/applying-slds/metadata/blueprints/components/illustration.yaml +205 -0
- package/skills/applying-slds/metadata/blueprints/components/input.yaml +151 -0
- package/skills/applying-slds/metadata/blueprints/components/list-builder.yaml +127 -0
- package/skills/applying-slds/metadata/blueprints/components/lookups.yaml +132 -0
- package/skills/applying-slds/metadata/blueprints/components/map.yaml +118 -0
- package/skills/applying-slds/metadata/blueprints/components/menus.yaml +134 -0
- package/skills/applying-slds/metadata/blueprints/components/modals.yaml +152 -0
- package/skills/applying-slds/metadata/blueprints/components/notifications.yaml +88 -0
- package/skills/applying-slds/metadata/blueprints/components/page-headers.yaml +135 -0
- package/skills/applying-slds/metadata/blueprints/components/panels.yaml +149 -0
- package/skills/applying-slds/metadata/blueprints/components/path.yaml +154 -0
- package/skills/applying-slds/metadata/blueprints/components/picklist.yaml +125 -0
- package/skills/applying-slds/metadata/blueprints/components/pills.yaml +154 -0
- package/skills/applying-slds/metadata/blueprints/components/popovers.yaml +120 -0
- package/skills/applying-slds/metadata/blueprints/components/progress-bar.yaml +110 -0
- package/skills/applying-slds/metadata/blueprints/components/progress-indicator.yaml +133 -0
- package/skills/applying-slds/metadata/blueprints/components/progress-ring.yaml +102 -0
- package/skills/applying-slds/metadata/blueprints/components/prompt.yaml +126 -0
- package/skills/applying-slds/metadata/blueprints/components/publishers.yaml +178 -0
- package/skills/applying-slds/metadata/blueprints/components/radio-button-group.yaml +172 -0
- package/skills/applying-slds/metadata/blueprints/components/radio-group.yaml +112 -0
- package/skills/applying-slds/metadata/blueprints/components/rich-text-editor.yaml +135 -0
- package/skills/applying-slds/metadata/blueprints/components/scoped-notifications.yaml +188 -0
- package/skills/applying-slds/metadata/blueprints/components/scoped-tabs.yaml +97 -0
- package/skills/applying-slds/metadata/blueprints/components/select.yaml +127 -0
- package/skills/applying-slds/metadata/blueprints/components/setup-assistant.yaml +152 -0
- package/skills/applying-slds/metadata/blueprints/components/slider.yaml +111 -0
- package/skills/applying-slds/metadata/blueprints/components/spinners.yaml +135 -0
- package/skills/applying-slds/metadata/blueprints/components/split-view.yaml +112 -0
- package/skills/applying-slds/metadata/blueprints/components/summary-detail.yaml +103 -0
- package/skills/applying-slds/metadata/blueprints/components/tabs.yaml +138 -0
- package/skills/applying-slds/metadata/blueprints/components/textarea.yaml +116 -0
- package/skills/applying-slds/metadata/blueprints/components/tiles.yaml +108 -0
- package/skills/applying-slds/metadata/blueprints/components/timepicker.yaml +111 -0
- package/skills/applying-slds/metadata/blueprints/components/toast.yaml +154 -0
- package/skills/applying-slds/metadata/blueprints/components/tooltips.yaml +107 -0
- package/skills/applying-slds/metadata/blueprints/components/tree-grid.yaml +116 -0
- package/skills/applying-slds/metadata/blueprints/components/trees.yaml +116 -0
- package/skills/applying-slds/metadata/blueprints/components/trial-bar.yaml +112 -0
- package/skills/applying-slds/metadata/blueprints/components/vertical-navigation.yaml +130 -0
- package/skills/applying-slds/metadata/blueprints/components/vertical-tabs.yaml +140 -0
- package/skills/applying-slds/metadata/blueprints/components/visual-picker.yaml +150 -0
- package/skills/applying-slds/metadata/blueprints/components/welcome-mat.yaml +136 -0
- package/skills/applying-slds/metadata/hooks-index.json +6272 -0
- package/skills/applying-slds/metadata/icon-metadata.json +38466 -0
- package/skills/applying-slds/metadata/utilities-index.json +21912 -0
- package/skills/applying-slds/references/component-selection.md +112 -0
- package/skills/applying-slds/references/icons-decision-guide.md +124 -0
- package/skills/applying-slds/references/styling-decision-guide.md +228 -0
- package/skills/applying-slds/references/utilities-quick-ref.md +125 -0
- package/skills/applying-slds/scripts/search-blueprints.cjs +117 -0
- package/skills/applying-slds/scripts/search-hooks.cjs +139 -0
- package/skills/applying-slds/scripts/search-icons.cjs +174 -0
- package/skills/applying-slds/scripts/search-utilities.cjs +161 -0
- package/skills/generating-custom-lightning-type/SKILL.md +17 -39
- package/skills/generating-custom-lightning-type/assets/primitive-types-and-constraints.md +41 -0
- package/skills/generating-custom-lightning-type/references/widget-rendition.md +124 -0
- package/skills/investigating-agentforce-architecture/README.md +156 -0
- package/skills/investigating-agentforce-architecture/SKILL.md +230 -0
- package/skills/investigating-agentforce-architecture/assets/cli/describe_sobject.yaml +16 -0
- package/skills/investigating-agentforce-architecture/assets/cli/describe_tooling_sobject.yaml +17 -0
- package/skills/investigating-agentforce-architecture/assets/cli/list_metadata_genaiprompttemplate.yaml +17 -0
- package/skills/investigating-agentforce-architecture/assets/cli/org_display.yaml +15 -0
- package/skills/investigating-agentforce-architecture/assets/cli/retrieve_genai_plugin.yaml +18 -0
- package/skills/investigating-agentforce-architecture/assets/cli/show_access_token.yaml +27 -0
- package/skills/investigating-agentforce-architecture/assets/mermaid/action_tree.mmd +20 -0
- package/skills/investigating-agentforce-architecture/assets/mermaid/data_flow.mmd +19 -0
- package/skills/investigating-agentforce-architecture/assets/mermaid/dependency_graph.mmd +19 -0
- package/skills/investigating-agentforce-architecture/assets/mermaid/invocation_sequence.mmd +20 -0
- package/skills/investigating-agentforce-architecture/assets/mermaid/planner_state.mmd +18 -0
- package/skills/investigating-agentforce-architecture/assets/soql/apex_class_bodies_by_ids.soql +3 -0
- package/skills/investigating-agentforce-architecture/assets/soql/apex_class_bodies_by_names.soql +3 -0
- package/skills/investigating-agentforce-architecture/assets/soql/bot_definition_details.soql +3 -0
- package/skills/investigating-agentforce-architecture/assets/soql/bot_version_lookup.soql +4 -0
- package/skills/investigating-agentforce-architecture/assets/soql/flow_definition_by_ids.soql +3 -0
- package/skills/investigating-agentforce-architecture/assets/soql/flow_definition_ids_by_names.soql +3 -0
- package/skills/investigating-agentforce-architecture/assets/soql/flow_definition_view_by_durable_ids.soql +4 -0
- package/skills/investigating-agentforce-architecture/assets/soql/flow_metadata_by_id.soql +3 -0
- package/skills/investigating-agentforce-architecture/assets/soql/functions_by_plugins.soql +5 -0
- package/skills/investigating-agentforce-architecture/assets/soql/planner_attrs_by_parent_ids.soql +3 -0
- package/skills/investigating-agentforce-architecture/assets/soql/planner_bundle_functions.soql +3 -0
- package/skills/investigating-agentforce-architecture/assets/soql/planner_definition_by_agent_chain.soql +3 -0
- package/skills/investigating-agentforce-architecture/assets/soql/plugin_functions_by_plugin_ids.soql +3 -0
- package/skills/investigating-agentforce-architecture/assets/soql/plugin_instructions_by_plugin_ids.soql +3 -0
- package/skills/investigating-agentforce-architecture/assets/soql/plugins_by_planner.soql +4 -0
- package/skills/investigating-agentforce-architecture/references/architecture_sections.md +243 -0
- package/skills/investigating-agentforce-architecture/references/contract.json +244 -0
- package/skills/investigating-agentforce-architecture/references/soql_fields.md +512 -0
- package/skills/investigating-agentforce-architecture/scripts/_shared/__init__.py +1 -0
- package/skills/investigating-agentforce-architecture/scripts/_shared/fs_guard.py +329 -0
- package/skills/investigating-agentforce-architecture/scripts/_shared/paths.py +110 -0
- package/skills/investigating-agentforce-architecture/scripts/_shared/runtime.py +59 -0
- package/skills/investigating-agentforce-architecture/scripts/_shared/sql.py +10 -0
- package/skills/investigating-agentforce-architecture/scripts/cache_check.py +234 -0
- package/skills/investigating-agentforce-architecture/scripts/config.py +131 -0
- package/skills/investigating-agentforce-architecture/scripts/fetch_soql.py +689 -0
- package/skills/investigating-agentforce-architecture/scripts/finalize.py +295 -0
- package/skills/investigating-agentforce-architecture/scripts/main.py +2835 -0
- package/skills/investigating-agentforce-architecture/scripts/metadata_listing.py +265 -0
- package/skills/investigating-agentforce-architecture/scripts/parallel_retrieve.py +69 -0
- package/skills/investigating-agentforce-architecture/scripts/parse_bundle.py +215 -0
- package/skills/investigating-agentforce-architecture/scripts/parse_wave.py +845 -0
- package/skills/investigating-agentforce-architecture/scripts/probe_channels.py +302 -0
- package/skills/investigating-agentforce-architecture/scripts/render_architecture.py +1043 -0
- package/skills/investigating-agentforce-architecture/scripts/resolve_bot.py +255 -0
- package/skills/investigating-agentforce-architecture/scripts/resolve_invocation_target.py +130 -0
- package/skills/investigating-agentforce-architecture/scripts/rest_client.py +763 -0
- package/skills/investigating-agentforce-architecture/scripts/retrieve_planner.py +13 -0
- package/skills/investigating-agentforce-architecture/scripts/sf_cli.py +242 -0
- package/skills/investigating-agentforce-architecture/scripts/soql_loader.py +253 -0
- package/skills/investigating-agentforce-architecture/scripts/summarize_tree.py +143 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/__init__.py +0 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/_bootstrap.py +23 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/fixtures/__init__.py +0 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/fixtures/genai_payloads.py +400 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_cache_check.py +307 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_cache_check_main.py +283 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_config.py +115 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_end_to_end_fixture.py +651 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_finalize.py +278 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_flow_children_inflation.py +582 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_fs_guard.py +113 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_iterative_wave_b.py +478 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_main_pipeline.py +3359 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_parallel_retrieve.py +131 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_parse_bundle.py +400 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_parse_wave.py +644 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_parse_wave_classifiers.py +224 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_parse_wave_helpers.py +380 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_parse_wave_main.py +397 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_per_branch_visited.py +244 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_probe_channels.py +359 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_probe_cli_recipes.py +185 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_render_architecture.py +810 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_resolve_bot.py +203 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_resolve_creds.py +157 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_resolve_invocation_target.py +145 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_rest_client.py +1253 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_runtime_override.py +100 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_sf_cli.py +261 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_signature_stamping.py +466 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_soql_loader.py +501 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_summarize_tree.py +241 -0
- package/skills/investigating-agentforce-architecture/scripts/tests/test_write_emit_ctx.py +480 -0
- package/skills/investigating-agentforce-architecture/tools/emit_env.py +157 -0
- package/skills/investigating-agentforce-architecture/tools/emit_result.py +262 -0
- package/skills/investigating-agentforce-architecture/tools/sanitize.py +33 -0
- package/skills/investigating-agentforce-architecture/tools/write_emit_ctx.py +332 -0
- package/skills/investigating-agentforce-d360/README.md +123 -0
- package/skills/investigating-agentforce-d360/SKILL.md +163 -0
- package/skills/investigating-agentforce-d360/assets/dc/app_generation.sql +51 -0
- package/skills/investigating-agentforce-d360/assets/dc/content_category.sql +44 -0
- package/skills/investigating-agentforce-d360/assets/dc/content_quality.sql +41 -0
- package/skills/investigating-agentforce-d360/assets/dc/discover_sessions.sql +36 -0
- package/skills/investigating-agentforce-d360/assets/dc/feedback.sql +47 -0
- package/skills/investigating-agentforce-d360/assets/dc/feedback_details.sql +38 -0
- package/skills/investigating-agentforce-d360/assets/dc/gateway_records.sql +45 -0
- package/skills/investigating-agentforce-d360/assets/dc/gateway_request_llm.sql +50 -0
- package/skills/investigating-agentforce-d360/assets/dc/gateway_request_metadata.sql +44 -0
- package/skills/investigating-agentforce-d360/assets/dc/gateway_request_tags.sql +42 -0
- package/skills/investigating-agentforce-d360/assets/dc/gateway_requests.sql +89 -0
- package/skills/investigating-agentforce-d360/assets/dc/gateway_responses.sql +43 -0
- package/skills/investigating-agentforce-d360/assets/dc/generations.sql +52 -0
- package/skills/investigating-agentforce-d360/assets/dc/interactions.sql +53 -0
- package/skills/investigating-agentforce-d360/assets/dc/messages.sql +53 -0
- package/skills/investigating-agentforce-d360/assets/dc/messaging_session.sql +37 -0
- package/skills/investigating-agentforce-d360/assets/dc/moment_interactions.sql +34 -0
- package/skills/investigating-agentforce-d360/assets/dc/moments.sql +39 -0
- package/skills/investigating-agentforce-d360/assets/dc/participants.sql +48 -0
- package/skills/investigating-agentforce-d360/assets/dc/sessions.sql +78 -0
- package/skills/investigating-agentforce-d360/assets/dc/steps.sql +64 -0
- package/skills/investigating-agentforce-d360/assets/dc/tag_associations.sql +46 -0
- package/skills/investigating-agentforce-d360/assets/dc/tag_definition_associations.sql +37 -0
- package/skills/investigating-agentforce-d360/assets/dc/tag_definitions.sql +50 -0
- package/skills/investigating-agentforce-d360/assets/dc/tags.sql +37 -0
- package/skills/investigating-agentforce-d360/assets/dc/telemetry_spans.sql +55 -0
- package/skills/investigating-agentforce-d360/references/artifacts.md +50 -0
- package/skills/investigating-agentforce-d360/references/dc_dmo_fields.md +823 -0
- package/skills/investigating-agentforce-d360/references/dc_pipeline_contract.md +608 -0
- package/skills/investigating-agentforce-d360/scripts/_shared/__init__.py +2 -0
- package/skills/investigating-agentforce-d360/scripts/_shared/cli_override.py +98 -0
- package/skills/investigating-agentforce-d360/scripts/_shared/fs_guard.py +334 -0
- package/skills/investigating-agentforce-d360/scripts/_shared/paths.py +155 -0
- package/skills/investigating-agentforce-d360/scripts/_shared/runtime.py +59 -0
- package/skills/investigating-agentforce-d360/scripts/_shared/sql.py +14 -0
- package/skills/investigating-agentforce-d360/scripts/assemble_dc.py +1624 -0
- package/skills/investigating-agentforce-d360/scripts/config.py +45 -0
- package/skills/investigating-agentforce-d360/scripts/dc.py +188 -0
- package/skills/investigating-agentforce-d360/scripts/discover_sessions.py +556 -0
- package/skills/investigating-agentforce-d360/scripts/fetch_dc.py +1045 -0
- package/skills/investigating-agentforce-d360/scripts/render_dc.py +1750 -0
- package/skills/investigating-agentforce-d360/scripts/resolve_session.py +264 -0
- package/skills/investigating-agentforce-d360/scripts/storage.py +92 -0
- package/skills/investigating-agentforce-d360/scripts/tests/__init__.py +0 -0
- package/skills/investigating-agentforce-d360/scripts/tests/_bootstrap.py +15 -0
- package/skills/investigating-agentforce-d360/scripts/tests/fixtures/__init__.py +0 -0
- package/skills/investigating-agentforce-d360/scripts/tests/fixtures/synthetic_session.py +424 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_assemble_dc_bootstrap_and_mode.py +115 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_assemble_dc_gateway_direct.py +220 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_assemble_dc_gateway_direct_integration.py +158 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_assemble_dc_helpers.py +287 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_assemble_dc_integration.py +247 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_dc_and_resolve_session.py +433 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_discover_sessions.py +458 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_discover_sessions_grep_ci.py +193 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_fetch_dc_helpers.py +266 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_fetch_dc_identity.py +528 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_fetch_dc_main.py +251 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_fetch_dc_waterfall.py +229 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_fetch_dc_waterfall_full.py +283 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_identity_coherence.py +327 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_render_dc_branches.py +256 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_render_dc_gateway_direct.py +130 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_render_dc_helpers.py +291 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_render_dc_integration.py +220 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_render_dc_planner_llm_calls.py +284 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_render_dc_show_prompts_gating.py +215 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_resolve_from_disk.py +100 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_resolve_session_main.py +149 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_runtime_override.py +104 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_session_shape.py +95 -0
- package/skills/investigating-agentforce-d360/scripts/tests/test_session_shape_dropped_by_stdm.py +85 -0
- package/skills/managing-managed-event-subscription/SKILL.md +152 -0
- package/skills/managing-managed-event-subscription/assets/managed-event-subscription-template.xml +20 -0
- package/skills/managing-managed-event-subscription/references/delete-guide.md +57 -0
- package/skills/managing-managed-event-subscription/references/topic-name-formats.md +26 -0
- package/skills/managing-managed-event-subscription/references/update-constraints.md +30 -0
- package/skills/uplifting-components-to-slds2/SKILL.md +3 -2
- package/skills/uplifting-components-to-slds2/references/color-hooks-decision-guide.md +30 -9
- package/skills/uplifting-components-to-slds2/references/examples.md +24 -6
- package/skills/validating-slds/SKILL.md +262 -0
- package/skills/validating-slds/references/quality-checks.md +308 -0
- package/skills/validating-slds/references/report-format.md +302 -0
- package/skills/validating-slds/scripts/analyze-quality.cjs +521 -0
|
@@ -0,0 +1,366 @@
|
|
|
1
|
+
---
|
|
2
|
+
id: slds.guidance.overview.display-density
|
|
3
|
+
title: Display Density Overview
|
|
4
|
+
description: Foundational guidance for implementing comfy and compact density modes in SLDS
|
|
5
|
+
summary: "Comprehensive display density guidance covering comfy vs compact settings, density-aware styling hooks, and responsive component design. Includes implementation workflow and common pitfalls."
|
|
6
|
+
|
|
7
|
+
artifact_type: overview
|
|
8
|
+
domain: overviews
|
|
9
|
+
topic: display-density
|
|
10
|
+
|
|
11
|
+
content_format: narrative
|
|
12
|
+
complexity: foundational
|
|
13
|
+
audience: [implementer, designer]
|
|
14
|
+
|
|
15
|
+
tasks: [learn, choose, implement]
|
|
16
|
+
|
|
17
|
+
refs:
|
|
18
|
+
- slds.guidance.hooks.spacing
|
|
19
|
+
- slds.guidance.hooks.typography
|
|
20
|
+
|
|
21
|
+
tags: [display-density, comfy, compact, responsive, user-preferences]
|
|
22
|
+
keywords: [comfy mode, compact mode, density-aware, user preferences, responsive design, data density, form layout]
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
# Display Density Guidance for SLDS Implementation
|
|
26
|
+
|
|
27
|
+
**Purpose:** This document provides the foundational principles and guidance for implementing display density in Salesforce Lightning Design System. When working with SLDS components and interfaces, follow these guidelines to ensure consistent user experiences across both comfy and compact density settings.
|
|
28
|
+
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
## About Display Density
|
|
32
|
+
|
|
33
|
+
Display density controls the spacing and layout of interface elements within a given screen area. Salesforce Lightning Design System 2 (SLDS 2) offers two density settings: **comfy** and **compact**.
|
|
34
|
+
|
|
35
|
+
**Comfy** (the default setting) places labels on top of fields and adds more space between page elements, creating a spacious view with increased vertical and horizontal spacing. **Compact** increases visual density with labels on the same line as fields and less space between lines, allowing more information to be visible simultaneously.
|
|
36
|
+
|
|
37
|
+
**Key Requirement:** Because users select which display density setting to use, design Salesforce interfaces to work well in both settings. Display density is a user preference that must be supported universally across all implementations.
|
|
38
|
+
|
|
39
|
+
---
|
|
40
|
+
|
|
41
|
+
## Core Principles
|
|
42
|
+
|
|
43
|
+
When working with display density in UI interfaces, adhere to these foundational principles:
|
|
44
|
+
|
|
45
|
+
1. **Respect user preferences.** Display density is a user-controlled setting, not a design decision. Interfaces must function equally well in both comfy and compact modes, as users select their preferred density based on their needs and workflows.
|
|
46
|
+
|
|
47
|
+
2. **Design for both settings from the start.** Implement components with density-aware styling hooks to ensure seamless adaptation. Retrofitting density support is more complex than building it in from the beginning.
|
|
48
|
+
|
|
49
|
+
3. **Maintain accessibility across densities.** Both comfy and compact modes must meet WCAG standards. Touch targets, text readability, and visual hierarchy must remain accessible regardless of the density setting.
|
|
50
|
+
|
|
51
|
+
4. **Use density-aware styling hooks strategically.** Not every element needs to adapt to density changes. Identify which components truly benefit from density responsiveness—typically data-dense elements like tables, lists, forms, and navigation.
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
|
|
55
|
+
## Comfy Setting
|
|
56
|
+
|
|
57
|
+
Comfy is the default density setting in Salesforce. The comfy setting offers a spacious view with increased vertical and horizontal spacing, and vertically stacked form elements.
|
|
58
|
+
|
|
59
|
+
### Benefits of Comfy Setting
|
|
60
|
+
|
|
61
|
+
The comfy setting provides these benefits:
|
|
62
|
+
|
|
63
|
+
- **Better accommodation for localized content** with longer text strings, reducing truncation and improving internationalization support
|
|
64
|
+
- **Enhanced visual separation** for improved accessibility, particularly benefiting users with cognitive disabilities or those who benefit from clear visual grouping
|
|
65
|
+
- **Reduced cognitive load and better scannability**, particularly beneficial for new users learning the system or users navigating complex workflows
|
|
66
|
+
|
|
67
|
+
### Comfy Setting Guidelines
|
|
68
|
+
|
|
69
|
+
When implementing components for comfy mode, address these factors:
|
|
70
|
+
|
|
71
|
+
- **Critical information prominence:** Ensure that critical information remains prominent despite additional whitespace. The increased spacing should enhance, not diminish, the visibility of important content.
|
|
72
|
+
- **Localized content testing:** Test with localized content to verify that spacing accommodates longer text strings common in languages like German or Finnish.
|
|
73
|
+
- **Vertical scrolling requirements:** Elements use more vertical space in comfy mode, which may increase scrolling requirements for long forms or data-heavy screens.
|
|
74
|
+
|
|
75
|
+
---
|
|
76
|
+
|
|
77
|
+
## Compact Setting
|
|
78
|
+
|
|
79
|
+
Compact mode creates a denser view with reduced spacing between elements, more information visibility in the viewport, and horizontally stacked form elements.
|
|
80
|
+
|
|
81
|
+
### Benefits of Compact Setting
|
|
82
|
+
|
|
83
|
+
The compact setting provides these benefits:
|
|
84
|
+
|
|
85
|
+
- **Improved efficiency** when working with large data sets, allowing users to see and compare more records without scrolling
|
|
86
|
+
- **Reduced scrolling** for data-heavy screens, improving workflow efficiency for power users
|
|
87
|
+
- **More information visible simultaneously**, supporting tasks that require viewing multiple data points at once
|
|
88
|
+
|
|
89
|
+
### Compact Setting Guidelines
|
|
90
|
+
|
|
91
|
+
When implementing components for compact mode, address these critical factors:
|
|
92
|
+
|
|
93
|
+
- **Touch target accessibility:** Verify that touch targets remain large enough for comfortable interaction, meeting minimum size requirements of 44×44 pt/dp/px for mobile and 24×24 CSS pixels for desktop (with 44×44 recommended for Salesforce mixed environments).
|
|
94
|
+
- **Text readability:** Ensure that text remains readable with reduced spacing, maintaining appropriate line height and letter spacing for legibility.
|
|
95
|
+
- **Horizontal layout behavior:** Test how horizontal layouts behave in narrower viewports, ensuring form elements that stack horizontally don't create usability issues on smaller screens.
|
|
96
|
+
|
|
97
|
+
---
|
|
98
|
+
|
|
99
|
+
## User Control of Density
|
|
100
|
+
|
|
101
|
+
To personalize the look of Lightning Experience, users can change their display density setting through their profile menu. After a user changes their display density setting, the page automatically refreshes to apply the new density. Salesforce administrators can also set org-wide defaults.
|
|
102
|
+
|
|
103
|
+
**Implementation Requirement:** When designing and developing interfaces, ensure that the interface adapts appropriately to both density settings. Components must respond gracefully to density changes without breaking layouts or compromising functionality.
|
|
104
|
+
|
|
105
|
+
---
|
|
106
|
+
|
|
107
|
+
## Density-Aware Styling Hooks
|
|
108
|
+
|
|
109
|
+
Use density-aware styling hooks when specific areas, components, spacing, and typographical elements require the ability to adapt or respond to a user's density setting. Density-aware styling hooks are denoted by **"var"** in the naming convention (e.g., `--slds-g-spacing-var-1`) and act as responsive variables that change their values when the density setting changes.
|
|
110
|
+
|
|
111
|
+
### Elements That Benefit from Density-Aware Hooks
|
|
112
|
+
|
|
113
|
+
Implement density-aware styling hooks for these element types:
|
|
114
|
+
|
|
115
|
+
- **Data-dense components** like tables, lists, and grids where information density directly impacts usability
|
|
116
|
+
- **Form layouts and field arrangements** where spacing affects scannability and completion efficiency
|
|
117
|
+
- **Card and container padding** where internal spacing adapts to user preference
|
|
118
|
+
- **Navigation and toolbar spacing** where compact spacing supports power users while comfy spacing aids discoverability
|
|
119
|
+
|
|
120
|
+
### Matching Hooks to Properties
|
|
121
|
+
|
|
122
|
+
When implementing density-aware styling hooks, match the styling hooks with the appropriate CSS properties:
|
|
123
|
+
|
|
124
|
+
- **For all-sides spacing (top-bottom-left-right):** Use `--slds-g-spacing-var-[size]`
|
|
125
|
+
- **For horizontal spacing (left-right):** Use `--slds-g-spacing-var-inline-[size]`
|
|
126
|
+
- **For vertical spacing (top-bottom):** Use `--slds-g-spacing-var-block-[size]`
|
|
127
|
+
- **For font sizes:** Use `--slds-g-font-scale-var-[size]`
|
|
128
|
+
- **For font line height:** Use `--slds-g-font-lineheight-var-base`
|
|
129
|
+
|
|
130
|
+
### Implementation Example
|
|
131
|
+
|
|
132
|
+
When the system detects a density change, properties using density-aware hooks automatically adapt:
|
|
133
|
+
|
|
134
|
+
```css
|
|
135
|
+
/* This hook provides different values based on density setting */
|
|
136
|
+
.my-component {
|
|
137
|
+
padding: var(--slds-g-spacing-var-4);
|
|
138
|
+
/* Comfy: 1rem | Compact: 0.5rem */
|
|
139
|
+
}
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
---
|
|
143
|
+
|
|
144
|
+
## Available Density-Aware Styling Hooks
|
|
145
|
+
|
|
146
|
+
The following sections list all density-aware styling hooks available in SLDS. For detailed usage patterns, dos and don'ts, and accessibility requirements for spacing-related hooks, refer to the Spacing and Sizing Styling Hooks documentation.
|
|
147
|
+
|
|
148
|
+
### Density-Aware Spacing (All Sides)
|
|
149
|
+
|
|
150
|
+
These density-aware styling hooks control spacing applied equally to all sides of an element (top, bottom, left, right) when the system switches between comfy and compact display density settings.
|
|
151
|
+
|
|
152
|
+
**Hook Pattern:** `--slds-g-spacing-var-{size}` where `{size}` is the spacing size
|
|
153
|
+
|
|
154
|
+
> **Reference:** See Spacing and Sizing Styling Hooks for complete usage guidance, accessibility requirements, and implementation patterns.
|
|
155
|
+
|
|
156
|
+
### Density-Aware Vertical Spacing (Block Axis)
|
|
157
|
+
|
|
158
|
+
These density-aware styling hooks control spacing along the vertical (block) axis when the system switches between comfy and compact display density settings. This spacing corresponds to top and bottom margins or paddings.
|
|
159
|
+
|
|
160
|
+
**Hook Pattern:** `--slds-g-spacing-var-block-{size}` where `{size}` is the spacing size
|
|
161
|
+
|
|
162
|
+
> **Reference:** See Spacing and Sizing Styling Hooks for complete usage guidance, accessibility requirements, and implementation patterns.
|
|
163
|
+
|
|
164
|
+
### Density-Aware Horizontal Spacing (Inline Axis)
|
|
165
|
+
|
|
166
|
+
These density-aware styling hooks control spacing along the horizontal (inline) axis when the system switches between comfy and compact display density settings. This spacing corresponds to left and right margins or paddings.
|
|
167
|
+
|
|
168
|
+
**Hook Pattern:** `--slds-g-spacing-var-inline-{size}` where `{size}` is the spacing size
|
|
169
|
+
|
|
170
|
+
> **Reference:** See Spacing and Sizing Styling Hooks for complete usage guidance, accessibility requirements, and implementation patterns.
|
|
171
|
+
|
|
172
|
+
### Density-Aware Line Height
|
|
173
|
+
|
|
174
|
+
This density-aware styling hook controls the line height when the system switches between comfy and compact display density settings.
|
|
175
|
+
|
|
176
|
+
**Hook Pattern:** `--slds-g-font-lineheight-var-base`
|
|
177
|
+
|
|
178
|
+
### Density-Aware Font Scale
|
|
179
|
+
|
|
180
|
+
These density-aware styling hooks control the font scale when the system switches between comfy and compact display density settings.
|
|
181
|
+
|
|
182
|
+
**Hook Pattern:** `--slds-g-font-scale-var-{size}` where `{size}` is the density-aware scale step
|
|
183
|
+
|
|
184
|
+
---
|
|
185
|
+
|
|
186
|
+
## Responsive Density
|
|
187
|
+
|
|
188
|
+
Density settings control global spacing, but different screen sizes require additional responsive adjustments. Combine density-aware hooks with responsive design patterns to create interfaces that adapt to both user preferences and device constraints.
|
|
189
|
+
|
|
190
|
+
### Implementing Responsive Density
|
|
191
|
+
|
|
192
|
+
When building responsive components, follow this approach:
|
|
193
|
+
|
|
194
|
+
1. **Use SLDS standard CSS media queries** (30em, 48em, 64em, 80em) to define responsive breakpoints
|
|
195
|
+
2. **Apply appropriate SLDS density-aware styling hooks** within each media query breakpoint
|
|
196
|
+
3. **Test thoroughly** across device sizes in both density settings to ensure layouts work in all combinations
|
|
197
|
+
|
|
198
|
+
### Responsive Density Example
|
|
199
|
+
|
|
200
|
+
Use this pattern for implementing responsive table cell padding that adapts to both viewport size and density setting:
|
|
201
|
+
|
|
202
|
+
```css
|
|
203
|
+
/* Default (Mobile-first) padding */
|
|
204
|
+
.my-custom-table td,
|
|
205
|
+
.my-custom-table th {
|
|
206
|
+
padding: var(--slds-g-spacing-var-1); /* Smallest padding for narrow screens */
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
/* Medium screens and up (768px+) */
|
|
210
|
+
@media (min-width: 48em) {
|
|
211
|
+
.my-custom-table td,
|
|
212
|
+
.my-custom-table th {
|
|
213
|
+
/* Increase padding for tablets / small laptops */
|
|
214
|
+
padding: var(--slds-g-spacing-var-3);
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
/* Large screens and up (1024px+) */
|
|
219
|
+
@media (min-width: 64em) {
|
|
220
|
+
.my-custom-table td,
|
|
221
|
+
.my-custom-table th {
|
|
222
|
+
/* Use larger padding for standard desktops */
|
|
223
|
+
padding: var(--slds-g-spacing-var-4);
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
```
|
|
227
|
+
|
|
228
|
+
---
|
|
229
|
+
|
|
230
|
+
## Custom Component Guidelines
|
|
231
|
+
|
|
232
|
+
When building custom components that need to respond to density, follow these guidelines to ensure consistent behavior with SLDS standards.
|
|
233
|
+
|
|
234
|
+
### Design Guidelines
|
|
235
|
+
|
|
236
|
+
When implementing custom density-aware components:
|
|
237
|
+
|
|
238
|
+
- **Analyze similar SLDS components:** Review how existing SLDS components adapt to density and follow similar patterns for consistency
|
|
239
|
+
- **Identify which elements need to adapt:** Not everything needs to respond to density changes. Focus density adaptation on spacing, typography, and form layouts
|
|
240
|
+
- **Use appropriate styling hooks:** Select hooks that match the property's purpose (spacing-var for padding/margin, font-scale-var for text sizing)
|
|
241
|
+
- **Test in both density settings:** Verify that your component works well in both comfy and compact modes before finalizing implementation
|
|
242
|
+
|
|
243
|
+
### Testing Custom Density Implementation
|
|
244
|
+
|
|
245
|
+
When validating custom density implementations, ensure that interfaces work well across display density settings:
|
|
246
|
+
|
|
247
|
+
- **Test the same screens in both comfy and compact settings** to verify visual consistency and functional parity
|
|
248
|
+
- **Check rendering in different screen regions and viewports** to ensure responsive density works across device sizes
|
|
249
|
+
- **Verify that touch targets remain accessible in compact setting**, meeting minimum size requirements (44×44 pt/dp/px recommended for Salesforce)
|
|
250
|
+
- **Confirm that text remains readable and hierarchy is maintained** with reduced spacing in compact mode
|
|
251
|
+
- **Verify that localized content displays properly** in both density settings, particularly for languages with longer text strings
|
|
252
|
+
|
|
253
|
+
---
|
|
254
|
+
|
|
255
|
+
## SLDS Components with Built-in Density Support
|
|
256
|
+
|
|
257
|
+
SLDS includes several components with built-in density adaptation that automatically respond to density changes through density-aware styling hooks.
|
|
258
|
+
|
|
259
|
+
### Components with Automatic Density Adaptation
|
|
260
|
+
|
|
261
|
+
The following components include density-aware styling hooks that enable automatic adjustments for different display densities:
|
|
262
|
+
|
|
263
|
+
- [Cards](https://www.lightningdesignsystem.com/2e1ef8501/p/33cd77-cards)
|
|
264
|
+
- [File selector](https://www.lightningdesignsystem.com/2e1ef8501/p/77d584-file-selector)
|
|
265
|
+
- [Tabs](https://www.lightningdesignsystem.com/2e1ef8501/p/1152cf-tabs)
|
|
266
|
+
|
|
267
|
+
### Component Blueprints with Configurable Density Support
|
|
268
|
+
|
|
269
|
+
When using component blueprints, use the standard SLDS markup patterns and CSS classes. The following component blueprints include density-aware styling hooks:
|
|
270
|
+
|
|
271
|
+
- [Cards](https://www.lightningdesignsystem.com/2e1ef8501/p/33cd77-cards)
|
|
272
|
+
- [Feed](https://v1.lightningdesignsystem.com/components/feeds/)
|
|
273
|
+
- [File selector](https://www.lightningdesignsystem.com/2e1ef8501/p/77d584-file-selector)
|
|
274
|
+
- [Page header](https://v1.lightningdesignsystem.com/components/page-headers/)
|
|
275
|
+
- [Path](https://v1.lightningdesignsystem.com/components/path/)
|
|
276
|
+
- [Split view](https://v1.lightningdesignsystem.com/components/split-view/)
|
|
277
|
+
- [Tabs](https://www.lightningdesignsystem.com/2e1ef8501/p/1152cf-tabs)
|
|
278
|
+
|
|
279
|
+
> **Reference:** To access component blueprints, see the [Salesforce Lightning Design System 1](https://v1.lightningdesignsystem.com/) website.
|
|
280
|
+
|
|
281
|
+
---
|
|
282
|
+
|
|
283
|
+
## Implementation Workflow
|
|
284
|
+
|
|
285
|
+
Follow this sequence when implementing density-aware components:
|
|
286
|
+
|
|
287
|
+
### Step 1: Determine Density Requirement
|
|
288
|
+
|
|
289
|
+
Identify whether your component needs density adaptation:
|
|
290
|
+
- **Does the component contain data-dense elements?** (tables, lists, grids)
|
|
291
|
+
- **Does spacing significantly impact usability?** (forms, cards, navigation)
|
|
292
|
+
- **Will users benefit from density control?** (power users vs. new users)
|
|
293
|
+
|
|
294
|
+
If the answer is yes to any of these, implement density-aware hooks.
|
|
295
|
+
|
|
296
|
+
### Step 2: Select Appropriate Hooks
|
|
297
|
+
|
|
298
|
+
Choose the correct density-aware hooks for your use case:
|
|
299
|
+
- **For padding/margin on all sides:** Use `--slds-g-spacing-var-*`
|
|
300
|
+
- **For vertical spacing only:** Use `--slds-g-spacing-var-block-*`
|
|
301
|
+
- **For horizontal spacing only:** Use `--slds-g-spacing-var-inline-*`
|
|
302
|
+
- **For text sizing:** Use `--slds-g-font-scale-var-*`
|
|
303
|
+
- **For line height:** Use `--slds-g-font-lineheight-var-base`
|
|
304
|
+
|
|
305
|
+
### Step 3: Implement with Appropriate Scale
|
|
306
|
+
|
|
307
|
+
Apply hooks with appropriate scale values:
|
|
308
|
+
- **Smaller values (1-4):** For compact elements, tight spacing
|
|
309
|
+
- **Medium values (5-8):** For standard component spacing
|
|
310
|
+
- **Larger values (9-12):** For section spacing and major divisions
|
|
311
|
+
|
|
312
|
+
### Step 4: Validate Implementation
|
|
313
|
+
|
|
314
|
+
Before finalizing, verify the implementation using the Pre-Implementation Checklist below to ensure all requirements are met across both density settings.
|
|
315
|
+
|
|
316
|
+
---
|
|
317
|
+
|
|
318
|
+
## Pre-Implementation Checklist
|
|
319
|
+
|
|
320
|
+
Before generating or modifying any display density related code, verify:
|
|
321
|
+
|
|
322
|
+
| Requirement | Status |
|
|
323
|
+
|-------------|--------|
|
|
324
|
+
| **Analysis & Planning** | |
|
|
325
|
+
| Component analyzed to determine if density adaptation is beneficial | [ ] |
|
|
326
|
+
| Similar SLDS components reviewed for density patterns | [ ] |
|
|
327
|
+
| Identified which elements need to adapt vs. remain fixed | [ ] |
|
|
328
|
+
| **Hook Selection** | |
|
|
329
|
+
| Appropriate density-aware hooks selected (spacing-var, font-scale-var, etc.) | [ ] |
|
|
330
|
+
| Hooks matched to correct CSS properties (spacing for margin/padding, font-scale for text) | [ ] |
|
|
331
|
+
| Appropriate scale values chosen (1-4 compact, 5-8 standard, 9-12 sections) | [ ] |
|
|
332
|
+
| No hard-coded spacing or sizing values (all use styling hooks) | [ ] |
|
|
333
|
+
| **Testing: Comfy Mode** | |
|
|
334
|
+
| Component tested in comfy density setting | [ ] |
|
|
335
|
+
| Visual hierarchy maintained with increased spacing | [ ] |
|
|
336
|
+
| Localized content accommodated (longer text strings) | [ ] |
|
|
337
|
+
| Critical information remains prominent despite additional whitespace | [ ] |
|
|
338
|
+
| **Testing: Compact Mode** | |
|
|
339
|
+
| Component tested in compact density setting | [ ] |
|
|
340
|
+
| Touch targets meet minimum size requirements (44×44 pt/dp/px recommended) | [ ] |
|
|
341
|
+
| Text remains readable with reduced spacing and line height | [ ] |
|
|
342
|
+
| Horizontal layouts work in narrower viewports | [ ] |
|
|
343
|
+
| **Cross-Density Validation** | |
|
|
344
|
+
| Visual consistency maintained - component maintains its visual identity in both modes | [ ] |
|
|
345
|
+
| Functional parity confirmed - all functionality works equally well in both densities | [ ] |
|
|
346
|
+
| Component behavior consistent with similar SLDS components | [ ] |
|
|
347
|
+
| **Responsive & Accessibility** | |
|
|
348
|
+
| Responsive breakpoints tested with both density settings | [ ] |
|
|
349
|
+
| Component works across viewport sizes in both densities | [ ] |
|
|
350
|
+
| Accessibility standards met in both modes (WCAG 2.1 AA) | [ ] |
|
|
351
|
+
|
|
352
|
+
**Target outcome:** Interfaces that respect user density preferences while maintaining accessibility, visual consistency, and functional parity across both comfy and compact settings.
|
|
353
|
+
|
|
354
|
+
---
|
|
355
|
+
|
|
356
|
+
## Related Documentation
|
|
357
|
+
|
|
358
|
+
For detailed implementation guidance and related concepts, refer to:
|
|
359
|
+
|
|
360
|
+
- **Spacing and Sizing Styling Hooks** - For complete density-aware spacing hook details, usage patterns, dos and don'ts, and accessibility requirements
|
|
361
|
+
- **Spacing and Sizing Overview** - For foundational spacing and sizing principles and the grid system architecture
|
|
362
|
+
- **Accessibility Overview** - For ensuring touch targets, contrast, and keyboard navigation work across density settings
|
|
363
|
+
- **Typography Guidance** (when available) - For font-scale density hooks and line height implementation patterns
|
|
364
|
+
- **Color Overview** - For understanding how spacing and density interact with visual hierarchy and surface layering
|
|
365
|
+
|
|
366
|
+
|
|
@@ -0,0 +1,240 @@
|
|
|
1
|
+
---
|
|
2
|
+
id: slds.guidance.overview.icons
|
|
3
|
+
title: Icons Overview
|
|
4
|
+
description: Foundational principles and guidance for implementing icons in SLDS
|
|
5
|
+
summary: "Comprehensive icon guidance covering utility, object, action, doctype, and custom icons. Includes icon selection decision tree, accessibility requirements, and visual specifications."
|
|
6
|
+
|
|
7
|
+
artifact_type: overview
|
|
8
|
+
domain: overviews
|
|
9
|
+
topic: icons
|
|
10
|
+
|
|
11
|
+
content_format: narrative
|
|
12
|
+
complexity: foundational
|
|
13
|
+
audience: [implementer, designer]
|
|
14
|
+
|
|
15
|
+
tasks: [learn, choose, implement]
|
|
16
|
+
|
|
17
|
+
refs:
|
|
18
|
+
- slds.guidance.icons
|
|
19
|
+
- slds.guidance.accessibility.overview
|
|
20
|
+
|
|
21
|
+
tags: [icons, iconography, utility-icons, object-icons, accessibility]
|
|
22
|
+
keywords: [icon types, utility icons, object icons, action icons, icon accessibility, informational icons, decorative icons]
|
|
23
|
+
---
|
|
24
|
+
|
|
25
|
+
# Icons Guidance for SLDS Implementation
|
|
26
|
+
|
|
27
|
+
**Purpose:** This document provides the foundational principles and guidance for implementing icons in Salesforce Lightning Design System. When working with SLDS components and interfaces, follow these guidelines to ensure consistent, readable, and accessible iconography across all experiences.
|
|
28
|
+
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
## About Icons
|
|
32
|
+
|
|
33
|
+
Icons are symbols used to represent features, functionality, or content. They provide visual cues that help users navigate and interact with the interface more efficiently. Salesforce icon design blends professional and playful qualities, prioritizing simplicity, approachability, and legibility.
|
|
34
|
+
|
|
35
|
+
**Key Requirement:** To ensure an inclusive experience, implement icon accessibility by distinguishing between informational and decorative icons.
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
|
|
39
|
+
## Core Principles
|
|
40
|
+
|
|
41
|
+
When working with icons in UI interfaces, adhere to these four foundational principles:
|
|
42
|
+
|
|
43
|
+
1. **Choose the correct icon type for the context.** Match the icon category (utility, object, action, doctype, or product) to its specific functional role in the UI.
|
|
44
|
+
2. **Ensure accessibility compliance.** Distinguish between informational icons (requiring labels) and decorative icons (hidden from screen readers).
|
|
45
|
+
3. **Maintain visual consistency.** Follow SLDS standards for stroke weight, corner radius, and color usage to ensure a cohesive system.
|
|
46
|
+
4. **Follow the grid system and keyline shapes.** Align icons to the 8pt grid and use approved keyline shapes to maintain visual balance and weight.
|
|
47
|
+
|
|
48
|
+
---
|
|
49
|
+
|
|
50
|
+
## Icon Types
|
|
51
|
+
|
|
52
|
+
SLDS includes five distinct icon types, each optimized for specific use cases and platforms.
|
|
53
|
+
|
|
54
|
+
### 1. Utility Icons
|
|
55
|
+
Utility icons are simple, single-color glyphs that identify labels and actions. They are the most commonly used icons across all device types.
|
|
56
|
+
|
|
57
|
+
**Use for:**
|
|
58
|
+
- UI-specific actions (Close, Search, Edit, Settings)
|
|
59
|
+
- Global headers and navigation elements
|
|
60
|
+
- Button groups, alerts, and toasts
|
|
61
|
+
- Feed interactions (Share, Like, Comment)
|
|
62
|
+
|
|
63
|
+
**Anatomy and Specs:**
|
|
64
|
+
- **Grid Sizes:** 16x16px (small), 24x24px (standard).
|
|
65
|
+
- **Stroke Weight:** 1px (for 16px), 2px (for 24px).
|
|
66
|
+
- **Standard Scales:** 16x16, 24x24, 32x32, 48x48, and 60x60px.
|
|
67
|
+
- **Color:** No fixed background shape; can be any color (typically matches adjacent text).
|
|
68
|
+
|
|
69
|
+
**SLDS 2 Note:** Utility icons remain unchanged from SLDS 1.
|
|
70
|
+
|
|
71
|
+
### 2. Object Icons (Standard and Custom)
|
|
72
|
+
Object icons represent Salesforce entities. Standard icons are for core objects (e.g., Accounts), while custom icons represent customer-created objects.
|
|
73
|
+
|
|
74
|
+
**Use for:**
|
|
75
|
+
- Representing records in list views, search results, and page headers.
|
|
76
|
+
- Identifying entity types in related lists and cards.
|
|
77
|
+
|
|
78
|
+
**Anatomy and Specs:**
|
|
79
|
+
- **Background Shape:** White glyph on a solid colored circular background.
|
|
80
|
+
- **Grid Size:** 60x60px.
|
|
81
|
+
- **Stroke Weight:** 6px.
|
|
82
|
+
- **Corner Radius:** 6px (for glyph details).
|
|
83
|
+
|
|
84
|
+
**SLDS 2 Note:** The background shape for standard object icons has updated from a square to a **circle**.
|
|
85
|
+
|
|
86
|
+
> ** Accessibility Warning:** Not all custom object icons meet WCAG color contrast guidelines. Always pair them with text as decorative elements.
|
|
87
|
+
|
|
88
|
+
### 3. Action Icons
|
|
89
|
+
Action icons represent the primary ways users accomplish tasks on touch devices. They appear exclusively in the mobile action bar.
|
|
90
|
+
|
|
91
|
+
**Use for:**
|
|
92
|
+
- Touch-device specific actions (New Lead, Log a Call, Share Post).
|
|
93
|
+
- Mobile action bar interactions.
|
|
94
|
+
|
|
95
|
+
**Anatomy and Specs:**
|
|
96
|
+
- **Background Shape:** White glyph on a colored circle.
|
|
97
|
+
- **Grid Size:** 48x48px.
|
|
98
|
+
- **Stroke Weight:** 4px.
|
|
99
|
+
- **Artboard:** 52x52px with a 32x32px icon live area.
|
|
100
|
+
|
|
101
|
+
### 4. Doctype Icons
|
|
102
|
+
Doctype icons represent document file formats and are used when a file preview is unavailable.
|
|
103
|
+
|
|
104
|
+
**Use for:**
|
|
105
|
+
- Identifying file types (PDF, Word, Excel, Sheets, etc.).
|
|
106
|
+
- Feeds, publishers, cards, and related lists where files are attached.
|
|
107
|
+
|
|
108
|
+
**Anatomy and Specs:**
|
|
109
|
+
- **Background Shape:** Vertical rectangle (56x64px) with a folded corner (earflap).
|
|
110
|
+
- **Glyph:** White glyph or text abbreviation of the file extension.
|
|
111
|
+
- **Corner Radius:** 6px.
|
|
112
|
+
|
|
113
|
+
### 5. Product Icons
|
|
114
|
+
Product icons represent official Salesforce applications and feature product-specific branding.
|
|
115
|
+
|
|
116
|
+
**Use for:**
|
|
117
|
+
- App Launcher (Desktop) at 48x48px.
|
|
118
|
+
- Mobile device home screens and app headers.
|
|
119
|
+
|
|
120
|
+
**Anatomy and Specs:**
|
|
121
|
+
- **Glyph:** Two-color branded glyph on a white background.
|
|
122
|
+
- **Stroke:** 4px rounded stroke weight.
|
|
123
|
+
|
|
124
|
+
---
|
|
125
|
+
|
|
126
|
+
## Accessibility
|
|
127
|
+
|
|
128
|
+
Screen readers handle icons based on their functional role.
|
|
129
|
+
|
|
130
|
+
### Informational Icons
|
|
131
|
+
Icons that convey important information not present in surrounding text (e.g., a standalone button icon).
|
|
132
|
+
- **Requirement:** Must include an `aria-label` or assistive text.
|
|
133
|
+
- **Description Rule:** Describe the *purpose* (e.g., "Upload File"), not the *appearance* (e.g., "paperclip").
|
|
134
|
+
|
|
135
|
+
### Decorative Icons
|
|
136
|
+
Icons that reinforce adjacent text or provide purely visual interest.
|
|
137
|
+
- **Requirement:** Must use an empty `alt=""` tag or be hidden from screen readers.
|
|
138
|
+
- **Behavior:** Screen readers will skip these to avoid redundant announcements.
|
|
139
|
+
|
|
140
|
+
---
|
|
141
|
+
|
|
142
|
+
## Grid System and Keyline Shapes
|
|
143
|
+
|
|
144
|
+
SLDS icons are built on an 8pt grid system to ensure visual consistency across the entire library. Icons utilize four standard keyline shapes based on BPMN diagram conventions:
|
|
145
|
+
- **Circle**
|
|
146
|
+
- **Square**
|
|
147
|
+
- **Vertical Rectangle**
|
|
148
|
+
- **Horizontal Rectangle**
|
|
149
|
+
|
|
150
|
+
These shapes ensure that icons across different categories maintain consistent visual weight when appearing together.
|
|
151
|
+
|
|
152
|
+
---
|
|
153
|
+
|
|
154
|
+
## Mobile Tap Targeting
|
|
155
|
+
|
|
156
|
+
When designing for mobile, ensure icons are easy to select by providing adequate spacing.
|
|
157
|
+
- **Minimum Target Size:** Maintain a minimum tap target of 44x44px.
|
|
158
|
+
- **Spacing:** Add generous padding around icons in touch environments to prevent accidental taps.
|
|
159
|
+
|
|
160
|
+
---
|
|
161
|
+
|
|
162
|
+
## Usage and Best Practices
|
|
163
|
+
|
|
164
|
+
### Recommended Usage
|
|
165
|
+
|
|
166
|
+
| Context | Recommended Icon Type |
|
|
167
|
+
|---------|-----------------------|
|
|
168
|
+
| Generic UI Actions | Utility Icons |
|
|
169
|
+
| Record Representation | Object Icons |
|
|
170
|
+
| Mobile Action Bar | Action Icons |
|
|
171
|
+
| File Attachments | Doctype Icons |
|
|
172
|
+
| App Navigation | Product Icons |
|
|
173
|
+
|
|
174
|
+
### Implementation Constraints
|
|
175
|
+
|
|
176
|
+
- **Utility Color Matching:** Always match utility icon color to adjacent text (e.g., use `on-surface-3` if the title is that color).
|
|
177
|
+
- **White Glyphs:** Use only white glyphs for Object and Action icons.
|
|
178
|
+
- **Standard Scaling:** Only scale icons to standard sizes (16, 24, 32, 48, 60px). Avoid scaling outside these increments.
|
|
179
|
+
|
|
180
|
+
### Visual Standards (Dos and Don’ts)
|
|
181
|
+
|
|
182
|
+
#### Utility Icons
|
|
183
|
+
- ** Do:** Scale to standard pixel sizes (16x16, 24x24, etc.).
|
|
184
|
+
- ** Do:** Use front-facing solid shapes for clarity.
|
|
185
|
+
- ** Don't:** Use outlines or angled/dimensional views.
|
|
186
|
+
- ** Don't:** Make icons overly complicated for small scales.
|
|
187
|
+
|
|
188
|
+
#### Object Icons
|
|
189
|
+
- ** Do:** Use white glyphs on approved colored backgrounds.
|
|
190
|
+
- ** Do:** Use approved BPMN keyline shapes.
|
|
191
|
+
- ** Don't:** Use unapproved background shapes or non-white glyphs.
|
|
192
|
+
|
|
193
|
+
#### Doctype Icons
|
|
194
|
+
- ** Do:** Represent the earflap without a visible gap.
|
|
195
|
+
- ** Don't:** Add a gap or separation to the icon's earflap.
|
|
196
|
+
|
|
197
|
+
---
|
|
198
|
+
|
|
199
|
+
## Recommended Specs Summary
|
|
200
|
+
|
|
201
|
+
| Icon Type | Grid Size | Stroke Weight | Corner Radius | Artboard Size |
|
|
202
|
+
|-----------|-----------|---------------|---------------|---------------|
|
|
203
|
+
| Utility (S) | 16x16px | 1px | 1px | 52x52px |
|
|
204
|
+
| Utility (M) | 24x24px | 2px | 2px | 52x52px |
|
|
205
|
+
| Object | 60x60px | 6px | 6px | 100x100px |
|
|
206
|
+
| Action | 48x48px | 4px | 4px | 52x52px |
|
|
207
|
+
| Doctype | 56x64px | - | 6px | 56x64px |
|
|
208
|
+
| Product | 48x48px | 4px | - | - |
|
|
209
|
+
|
|
210
|
+
---
|
|
211
|
+
|
|
212
|
+
## Implementation Workflow
|
|
213
|
+
|
|
214
|
+
Follow this sequence when implementing icons:
|
|
215
|
+
|
|
216
|
+
1. **Identify Icon Need:** Determine the semantic role (action, record type, file, etc.).
|
|
217
|
+
2. **Select Icon Type:** Choose the category that matches the role (e.g., Utility for actions).
|
|
218
|
+
3. **Apply Sizing and Color:** Use standard scales and match colors to context (for Utility).
|
|
219
|
+
4. **Implement Accessibility:** Add `aria-label` for informational icons; use empty `alt` for decorative.
|
|
220
|
+
5. **Validate:** Check against the pre-implementation checklist for compliance.
|
|
221
|
+
|
|
222
|
+
---
|
|
223
|
+
|
|
224
|
+
## Pre-Implementation Checklist
|
|
225
|
+
|
|
226
|
+
| Requirement | Status |
|
|
227
|
+
|-------------|--------|
|
|
228
|
+
| **Type Selection** | |
|
|
229
|
+
| Icon type matches functional role (Utility/Object/Action/Doctype/Product) | [ ] |
|
|
230
|
+
| **Sizing & Specs** | |
|
|
231
|
+
| Icon scaled to standard size (16/24/32/48/60px) | [ ] |
|
|
232
|
+
| Anatomy specs (stroke, radius) match the chosen scale | [ ] |
|
|
233
|
+
| **Color & Consistency** | |
|
|
234
|
+
| Utility icon color matches adjacent text | [ ] |
|
|
235
|
+
| Object/Action icons use white glyphs on colored backgrounds | [ ] |
|
|
236
|
+
| **Accessibility** | |
|
|
237
|
+
| Informational icons have descriptive `aria-label` (purpose, not look) | [ ] |
|
|
238
|
+
| Decorative icons have empty `alt=""` or are hidden | [ ] |
|
|
239
|
+
| **Mobile** | |
|
|
240
|
+
| Touch target meets minimum 44x44px requirement | [ ] |
|