Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 50 additions & 0 deletions .changeset/simplify-cards-schema.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
---
"@adobe/spectrum-component-api-schemas": patch
---

fix(component-schemas): simplify cards component schema to fix ingestion issues

## Components Changed (0 added, 0 deleted, 1 updated)

**Original Branch:** `main`

**New Branch:** `card-schema-cleanup`

### 🔧 Schema Fixes Applied

This PR fixes **1 schema issue(s)** that were preventing proper ingestion. The changes restore expected functionality.

<details open><summary><strong>🔧 Schema Fixes</strong></summary>

**cards**
- Updated: `variant` - removed default: "asset" - "Gallery cards display one image or video asset. Asset cards show one asset of any type. Collection cards support multiple assets. Horizontal cards place text and one asset side-by-side. Product cards use one thumbnail asset. Flex cards accept any asset type and quantity."
- Added: `size` (string, default: m) - "Overall size of the card."
- Added: `state` (string, default: default)
- Added: `isSelected` (boolean)
- Added: `isQuiet` (boolean)
- Added: `isDisabled` (boolean)
- Added: `hideCheckbox` (boolean) - "If true, the selection checkbox is hidden."
- Added: `title` (string) - "Optional card title."
- Added: `description` (string) - "Optional description shown below the title."
- Added: `actionLabel` (string) - "Optional action button label."
- Added: `metadata` (string) - "Optional metadata shown below the card."
- Added: `assetTypes` (array)
- Added: `imageProportion` (string, default: auto) - "How much of the card container the image or video occupies. Does not apply to document or thumbnail assets."
- Added: `style` (string, default: primary) - "The style of the card."
- Added: `imageRatio` (string, default: auto) - "Aspect ratio of the image or video. Does not apply to document or thumbnail assets."
- Updated: `variant` - "Gallery cards display one image or video asset. Asset cards show one asset of any type. Collection cards support multiple assets. Horizontal cards place text and one asset side-by-side. Product cards use one thumbnail asset. Flex cards accept any asset type and quantity."
- Added: `required` - ["variant", "assetTypes"]

</details>

---

### ✅ Fix Summary

This change resolves ingestion issues with the v0 website by:
1. **Removing unsupported conditionals**: Flattens properties for universal application
2. **Restoring expected structure**: Ensures proper schema validation
3. **Maintaining compatibility**: Preserves all existing functionality
4. **Improving reliability**: Fixes data flow from Figma to implementation teams

_This comment was automatically generated by the component schema diff tool. 🤖_
8 changes: 5 additions & 3 deletions .lintstagedrc.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
{
"**/*.{js,jsx,ts,tsx,json,yml,yaml}": ["prettier --write"],
"**/*.md": ["remark --use remark-gfm --use remark-github --output"],
"**/*.md": [
"remark --use remark-frontmatter --use remark-gfm --use remark-github --output"
],
"!**/.changeset/*.md": [],
"!**/pnpm-lock.yaml": [],
"!**/package-lock.json": [],
"!**/yarn.lock": [],
".changeset/*.md": [
"pnpm changeset-lint check-file",
"remark --use remark-gfm --use remark-github --output"
"pnpm changeset-lint check-file"
]
}
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
"prettier": "^3.5.3",
"remark": "^15.0.1",
"remark-cli": "^12.0.1",
"remark-frontmatter": "^5.0.0",
"remark-gfm": "^4.0.1",
"remark-github": "^12.0.0"
},
Expand Down
Loading
Loading