Token导航 LogoToken导航TokenDH.com
前端设计需要联网github未标认证来源可访问许可证需确认审计通过

sf-industry-commoncore-flexcardSF 行业 Commoncore Flex 卡

Agent Skill

sf-industry-commoncore-flexcard 用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要围绕仓库状态、代码变更或协作事项进行整理时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

17,178

周安装

723

GitHub Stars

401

下载量

6,015
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:sf-industry-commoncore-flexcard(SF 行业 Commoncore Flex 卡)
来源仓库:https://github.com/jaganpro/sf-skills
仓库路径:skills/sf-industry-commoncore-flexcard
安装命令:
npx skills add https://github.com/jaganpro/sf-skills --skill sf-industry-commoncore-flexcard
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/jaganpro/sf-skills --skill sf-industry-commoncore-flexcard

简介

用于处理 GitHub 仓库、Issue、Pull Request 和代码协作信息。

  • 适合在需要围绕仓库状态、代码变更或协作事项进行整理时使用。
  • 可结合来源仓库和原始 README 核验具体用法。
  • 安装前建议确认权限范围、维护状态及是否触发联网或文件读写。
  • 安装方式:通过 npx 从指定 GitHub 仓库添加技能。

SKILL.md

sf-industry-commoncore-flexcard: OmniStudio FlexCard Creation and Validation

Expert OmniStudio engineer specializing in FlexCard UI components for Salesforce Industries. Generate production-ready FlexCard definitions that display at-a-glance information with declarative data binding, Integration Procedure data sources, conditional rendering, and proper SLDS styling. All FlexCards are validated against a 130-point scoring rubric across 7 categories.

Core Responsibilities

  1. FlexCard Authoring: Design and build FlexCard definitions with proper layout, states, and field mappings
  2. Data Source Binding: Configure Integration Procedure data sources with correct field mapping and error handling
  3. Test Generation: Validate cards against multiple data states (populated, empty, error, multi-record)
  4. Documentation: Produce deployment-ready documentation with data source lineage and action mappings

Document Map

NeedDocumentDescription
Best practicesreferences/best-practices.mdLayout patterns, SLDS, accessibility, performance
Data bindingreferences/data-binding-guide.mdIP sources, field mapping, conditional rendering

CRITICAL: Orchestration Order

FlexCards sit at the presentation layer of the OmniStudio stack. Ensure upstream components exist before building a FlexCard that depends on them.

sf-industry-commoncore-omnistudio-analyze → sf-industry-commoncore-datamapper → sf-industry-commoncore-integration-procedure → sf-industry-commoncore-omniscript → sf-industry-commoncore-flexcard (you are here)

FlexCards consume data from Integration Procedures and can launch OmniScripts. Build the data layer first, then the presentation layer.


Key Insights

InsightDetail
Configuration fieldsOmniUiCard uses DataSourceConfig for data source bindings and PropertySetConfig for card layout, states, and actions. There is NO Definition field on OmniUiCard in Core namespace.
Data source bindingData sources bind to Integration Procedures for live data; the IP must be active and deployed before the FlexCard can retrieve data
Child card embeddingFlexCards can embed other FlexCards as child cards, enabling composite layouts with shared or independent data sources
OmniScript launchingFlexCards can launch OmniScripts via action buttons, passing context data from the card's data source into the OmniScript's input
Designer virtual objectThe FlexCard Designer uses OmniFlexCardView as a virtual list object (/lightning/o/OmniFlexCardView/home), separate from the OmniUiCard sObject where card records are stored. Cards created via API may not appear in "Recently Viewed" until opened in the Designer.

Workflow (5-Phase Pattern)

Phase 1: Requirements Gathering

Before building, clarify these with the stakeholder:

QuestionWhy It Matters
What is the card's purpose?Determines layout type and data density
Which data sources are needed?Identifies required Integration Procedures
What object context does it run in?Determines record-level vs. list-level display
What actions should the card expose?Drives button/link configuration and OmniScript integration
What layout best fits the use case?Single card, list, tabbed, or flyout
Are there conditional display rules?Fields or sections that appear/hide based on data values

Phase 2: Design & Layout

Card Layout Options

Layout TypeUse CaseDescription
Single CardRecord summaryOne card displaying fields from a single record
Card ListRelated recordsRepeating cards bound to an array data source
Tabbed CardMulti-contextMultiple states displayed as tabs within one card
Flyout CardDetail on demandExpandable detail panel triggered from a summary card

Data Source Configuration

Each FlexCard data source connects to an Integration Procedure (or other source type) and maps response fields to display elements.

FlexCard → Data Source (type: IntegrationProcedure)
         → IP Name + Input Mapping
         → Response Field Mapping → Card Elements
  • Map IP response fields to card display elements using {datasource.fieldName} merge syntax
  • Configure input parameters to pass record context (e.g., {recordId}) to the IP
  • Set data source order when multiple sources feed the same card

Action Button Design

Action TypePurposeConfiguration
Launch OmniScriptStart a guided processOmniScript Type + SubType, pass context params
NavigateGo to record or URLRecord ID or URL template with merge fields
Custom ActionPlatform event, LWC, etc.Custom action handler with payload mapping

Conditional Visibility

  • Show/hide fields based on data values using visibility conditions
  • Show/hide entire card states based on data source results
  • Display empty-state messaging when data source returns no records

Phase 3: Generation & Validation

  1. Generate the FlexCard definition JSON
  2. Validate all data source references resolve to active Integration Procedures
  3. Run the 130-point scoring rubric (see Scoring section below)
  4. Verify merge field syntax matches IP response structure
  5. Check accessibility attributes on all interactive elements

Phase 4: Deployment

  1. Ensure all upstream Integration Procedures are deployed and active
  2. Deploy the FlexCard metadata (OmniUiCard)
  3. Activate the FlexCard in the target org
  4. Embed the FlexCard in the target Lightning page, OmniScript, or parent FlexCard

Phase 5: Testing

Test each FlexCard against multiple data scenarios:

ScenarioWhat to Verify
Populated dataAll fields render correctly, merge fields resolve
Empty dataEmpty-state message displays, no broken merge fields
Error stateGraceful handling when IP returns an error or times out
Multi-recordCard list renders correct number of items, pagination works
Action buttonsOmniScript launches with correct pre-populated data
Conditional fieldsVisibility rules toggle correctly based on data values
MobileCard layout adapts to smaller viewport widths

Generation Guardrails

Avoid these patterns when generating FlexCard definitions:

Anti-PatternWhy It's WrongCorrect Approach
Referencing non-existent IP data sourcesCard fails to load data at runtimeVerify IP exists and is active before binding
Hardcoded colors in stylesBreaks SLDS theming and dark modeUse SLDS design tokens and CSS custom properties
Missing accessibility attributesFails WCAG complianceAdd aria-label, role, and keyboard handlers
Excessive nested child cardsPerformance degrades with deep nestingLimit to 2 levels of nesting; flatten where possible
Ignoring empty statesBroken UI when data source returns no recordsConfigure explicit empty-state messaging
Hardcoded record IDsCard breaks across environmentsUse merge fields and context-driven parameters

Scoring Rubric (130 Points)

All FlexCards are validated against 7 categories. Thresholds: ✅ 90+ (Deploy) | ⚠️ 67-89 (Review) | ❌ <67 (Block - fix required)

CategoryPointsCriteria
Design & Layout25Appropriate layout type, logical field grouping, responsive design, consistent spacing, clear visual hierarchy
Data Binding20Correct IP references, proper merge field syntax, input parameter mapping, multi-source coordination
Actions & Navigation20Action buttons configured correctly, OmniScript launch params mapped, navigation targets valid, action labels descriptive
Styling20SLDS tokens used (no hardcoded colors), consistent typography, proper use of card/tile patterns, dark mode compatible
Accessibility15aria-label on interactive elements, keyboard navigable actions, sufficient color contrast, screen reader friendly field labels
Testing15Verified with populated data, empty state, error state, multi-record scenario, and mobile viewport
Performance15Data source calls minimized, child card nesting limited (max 2 levels), no redundant IP calls, lazy loading for non-visible states

Scoring Breakdown Detail

Design & Layout (25 points)

CriterionPointsDescription
Layout type matches use case5Single, list, tabbed, or flyout chosen appropriately
Field grouping is logical5Related fields are visually grouped together
Responsive behavior5Card adapts to different viewport widths
Consistent spacing5Margins and padding follow SLDS spacing scale
Visual hierarchy5Primary information is prominent, secondary is de-emphasized

Data Binding (20 points)

CriterionPointsDescription
IP references are valid5All referenced IPs exist and are active
Merge field syntax correct5{datasource.field} paths resolve to actual IP response fields
Input parameters mapped5Record context passed correctly to IP inputs
Multi-source coordination5Multiple data sources load in correct order without conflicts

Actions & Navigation (20 points)

CriterionPointsDescription
Action buttons functional5All buttons trigger their configured actions
OmniScript params mapped5Context data flows correctly into launched OmniScripts
Navigation targets valid5Record and URL navigation resolves correctly
Labels are descriptive5Action labels clearly communicate what the action does

Styling (20 points)

CriterionPointsDescription
SLDS tokens used5Colors, fonts, spacing via design tokens
Consistent typography5Text sizes follow SLDS type scale
Card pattern compliance5Uses standard SLDS card or tile patterns
Dark mode compatible5No hardcoded colors; works with SLDS dark theme

Accessibility (15 points)

CriterionPointsDescription
ARIA labels on interactive elements5Buttons, links, and inputs have accessible names
Keyboard navigable5All actions reachable via Tab, activated via Enter/Space
Color contrast sufficient5Meets WCAG 2.1 AA contrast ratio (4.5:1 for text)

Testing (15 points)

CriterionPointsDescription
Populated data verified3Card renders correctly with full data
Empty state verified3Empty-state message displays properly
Error state verified3Graceful handling of IP errors
Multi-record verified3Card list renders correct items
Mobile viewport verified3Layout adapts to small screens

Performance (15 points)

CriterionPointsDescription
Data source calls minimized5No redundant or duplicate IP invocations
Child card nesting limited5Maximum 2 levels of nested child cards
Lazy loading for hidden states5Non-visible tabs/flyouts load on demand

CLI Commands

# Query active FlexCards in the org
sf data query -q "SELECT Id,Name,DataSourceConfig,PropertySetConfig,IsActive FROM OmniUiCard WHERE IsActive=true" -o <org>

# Retrieve a specific FlexCard by name
sf project retrieve start -m OmniUiCard:<Name> -o <org>

# Deploy a FlexCard to the target org
sf project deploy start -m OmniUiCard:<Name> -o <org>

# Retrieve all FlexCards
sf project retrieve start -m OmniUiCard -o <org>

# Deploy all OmniStudio metadata (FlexCards + dependencies)
sf project deploy start -m OmniUiCard -m OmniIntegrationProcedure -m OmniScript -o <org>

Data Source Binding

FlexCard Data Source Configuration

The DataSourceConfig field on OmniUiCard contains the data source bindings as JSON. The PropertySetConfig field contains the card layout, states, and field definitions.

IMPORTANT: There is NO Definition field on OmniUiCard in Core namespace. Use DataSourceConfig for data sources and PropertySetConfig for layout.
{
  "dataSource": {
    "type": "IntegrationProcedures",
    "value": {
      "ipMethod": "Type_SubType",
      "vlocityAsync": false,
      "inputMap": {
        "recordId": "{recordId}"
      },
      "resultVar": ""
    },
    "orderBy": {
      "name": "",
      "isReverse": ""
    },
    "contextVariables": []
  }
}

Data Source Types

TypedataSource.typeWhen to Use
Integration ProcedureIntegrationProcedures (plural, capital P)Primary pattern; calls an IP for live data
SOQLSOQLDirect query (use sparingly; prefer IP for abstraction)
Apex RemoteApexRemoteCustom Apex class invocation
RESTRESTExternal API call via Named Credential
CustomCustomCustom data provider (pass JSON body directly)

Field Mapping from IP Response

Map IP response fields to card display elements using merge field syntax:

IP Response:                    FlexCard Merge Field:
─────────────                   ─────────────────────
{ "Name": "Acme Corp" }   →    {Name}
{ "Account": {            →    {Account.Name}
    "Name": "Acme Corp"
  }
}
{ "records": [             →    {records[0].Name}  (single)
    { "Name": "Acme" }          or iterate with Card List layout
  ]
}

Input Parameter Mapping

Pass context from the hosting page into the IP data source:

Context VariableSourceExample
{recordId}Current record pagePass to IP to query related data
{userId}Running userFilter data by current user
{param.customKey}URL parameter or parent cardPass from parent FlexCard or URL

Cross-Skill Integration

SkillRelationship to sf-industry-commoncore-flexcard
sf-industry-commoncore-integration-procedureBuild the IP data sources that FlexCards consume
sf-industry-commoncore-omniscriptBuild the OmniScripts that FlexCard action buttons launch
sf-industry-commoncore-datamapperBuild DataRaptors/DataMappers that IPs use under the hood
sf-industry-commoncore-omnistudio-analyzeAnalyze dependency chains across FlexCards, IPs, and OmniScripts
sf-deployDeploy FlexCard metadata along with upstream dependencies
sf-lwcBuild custom LWC components embedded within FlexCards

Edge Cases

ScenarioHandling
Empty dataConfigure an explicit empty-state with a user-friendly message; do not show raw "No data" or blank card
Error statesDisplay a meaningful error message when the IP data source fails; log the error for debugging
Mobile responsivenessUse single-column layout for mobile; avoid horizontal scrolling; test at 320px viewport width
Long text valuesTruncate with ellipsis and provide a flyout or tooltip for full text
Large record setsUse card list with pagination; limit initial load to 10-25 records
Null field valuesUse conditional visibility to hide fields with null values rather than showing empty labels
Mixed data freshnessWhen multiple data sources have different refresh rates, display a "last updated" indicator

FlexCard vs LWC Decision Guide

FactorFlexCardLWC
Build methodDeclarative (drag-and-drop)Code (JS, HTML, CSS)
Data bindingIntegration Procedure merge fieldsWire service, Apex, GraphQL
Best forAt-a-glance information displayComplex interactive UIs
TestingManual + data state verificationJest unit tests + manual
CustomizationLimited to OmniStudio frameworkFull platform flexibility
ReuseEmbed as child cardsImport as child components
When to chooseStandard card layouts with IP dataCustom behavior, animations, complex state

Dependencies

Required: Target org with OmniStudio (Industries Cloud) license, sf CLI authenticated For Data Sources: Active Integration Procedures deployed to the target org For Actions: Active OmniScripts deployed (if action buttons launch OmniScripts) Scoring: Block deployment if score < 67

Creating FlexCards programmatically: Use REST API (sf api request rest --method POST --body @file.json). Required fields: Name, VersionNumber, OmniUiCardType (e.g., Child). Set DataSourceConfig (JSON string) for data source bindings and PropertySetConfig (JSON string) for card layout. The sf data create record --values flag cannot handle JSON in textarea fields. Activate by updating IsActive=true after creation.


External References


License

MIT License. Copyright (c) 2026 David Ryan (weytani)

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

35.75%
按下载量换算2,150

Claude

31.1%
按下载量换算1,871

Cursor

16.25%
按下载量换算977

Gemini CLI

9.6%
按下载量换算577

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills