Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 | 10x 10x 10x 10x 10x 10x 10x 10x 10x | {
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "https://slds.lightningdesignsystem.com/schemas/uif-foundation.v1.json",
"title": "UIF Foundation Schema",
"description": "Schema for design-system agnostic component foundations",
"type": "object",
"properties": {
"$schema": {
"type": "string",
"description": "JSON Schema URI for validation"
},
"apiVersion": {
"type": "string",
"pattern": "^\\d+\\.\\d+\\.\\d+$",
"description": "UIF schema version (e.g., '1.0.0')"
},
"name": {
"type": "string",
"pattern": "^[A-Z][a-zA-Z0-9]*$",
"description": "Component name in PascalCase"
},
"description": {
"type": "string",
"description": "Brief description of the component"
},
"dateAdded": {
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$",
"description": "ISO date when component was added"
},
"genReady": {
"type": "boolean",
"description": "Whether the component is ready for code generation"
},
"structure": {
"$ref": "#/definitions/FoundationStructure",
"description": "Root structural node defining DOM hierarchy"
},
"states": {
"type": "array",
"items": { "$ref": "#/definitions/State" },
"description": "Interactive states with ARIA mappings"
},
"accessibility": {
"$ref": "https://slds.lightningdesignsystem.com/schemas/uif-shared.v1.json#/definitions/Accessibility",
"description": "Accessibility requirements"
},
"behavior": {
"type": "string",
"description": "Path to behavior module (TypeScript/JavaScript)"
},
"composition": {
"$ref": "#/definitions/Composition",
"description": "Parent-child constraints"
},
"componentRefs": {
"type": "object",
"description": "Interface declarations for composed components",
"additionalProperties": {
"$ref": "https://slds.lightningdesignsystem.com/schemas/uif-shared.v1.json#/definitions/ComponentRef"
}
}
},
"required": ["apiVersion", "name", "description", "structure"],
"additionalProperties": false,
"definitions": {
"State": {
"type": "object",
"description": "Interactive state definition",
"properties": {
"name": {
"$ref": "https://slds.lightningdesignsystem.com/schemas/uif-shared.v1.json#/definitions/IdentifierName",
"description": "Unique identifier for the state (becomes a prop)"
},
"type": {
"type": "string",
"enum": ["boolean", "enum"],
"description": "Data type"
},
"aria": {
"type": "string",
"description": "ARIA attribute this state maps to"
},
"description": {
"type": "string",
"description": "Description of the state's effect"
},
"options": {
"type": "array",
"items": { "type": "string" },
"description": "For enum type, the allowed values"
}
},
"required": ["name", "type"],
"additionalProperties": false
},
"Composition": {
"type": "object",
"description": "Parent-child constraints",
"properties": {
"requiredComponentParent": {
"type": "string",
"description": "Component must be a direct child of this parent"
}
},
"additionalProperties": false
},
"FoundationChild": {
"type": "object",
"description": "Child element in foundation structure",
"properties": {
"name": {
"type": "string",
"description": "Unique identifier for the child element"
},
"restrict": {
"type": "array",
"items": { "type": "string" },
"description": "Allowed HTML elements"
},
"description": {
"type": "string",
"description": "Description of this child"
},
"component": {
"type": "string",
"description": "Reference to another UIF component (instead of HTML element)"
},
"attributes": {
"$ref": "#/definitions/FoundationAttributes"
},
"renderWhen": {
"type": "string",
"enum": ["slotFilled"],
"description": "Conditional rendering"
},
"repeats": {
"type": "boolean",
"description": "Whether this child repeats (maps over array)"
},
"slot": {
"$ref": "https://slds.lightningdesignsystem.com/schemas/uif-shared.v1.json#/definitions/Slot"
},
"children": {
"type": "array",
"items": { "$ref": "#/definitions/FoundationChild" },
"description": "Nested children"
}
},
"required": ["name"],
"additionalProperties": false
},
"FoundationAttributes": {
"type": "object",
"description": "Attributes for foundation elements (no class in static)",
"properties": {
"static": {
"type": "object",
"description": "Hardcoded attribute values (class not allowed in foundations)",
"additionalProperties": { "type": "string" },
"propertyNames": {
"not": { "const": "class" }
}
},
"bound": {
"type": "object",
"description": "Attributes bound to component props",
"additionalProperties": {
"$ref": "https://slds.lightningdesignsystem.com/schemas/uif-shared.v1.json#/definitions/BoundAttribute"
}
},
"conditional": {
"type": "object",
"description": "Conditionally rendered attributes",
"additionalProperties": {
"oneOf": [
{
"$ref": "https://slds.lightningdesignsystem.com/schemas/uif-shared.v1.json#/definitions/ConditionalAttribute"
},
{
"type": "array",
"items": {
"$ref": "https://slds.lightningdesignsystem.com/schemas/uif-shared.v1.json#/definitions/ConditionalAttribute"
}
}
]
}
}
},
"additionalProperties": false
},
"FoundationStructure": {
"type": "object",
"description": "Root structural node for foundations",
"properties": {
"name": {
"type": "string",
"description": "Unique identifier for this structural node"
},
"restrict": {
"type": "array",
"items": { "type": "string" },
"description": "Allowed HTML elements (first is used for generation)"
},
"description": {
"type": "string",
"description": "Description of this structural element"
},
"attributes": {
"$ref": "#/definitions/FoundationAttributes"
},
"children": {
"type": "array",
"items": { "$ref": "#/definitions/FoundationChild" },
"description": "Child elements and slots"
},
"slot": {
"$ref": "https://slds.lightningdesignsystem.com/schemas/uif-shared.v1.json#/definitions/Slot"
}
},
"required": ["name", "restrict"],
"additionalProperties": false
}
}
}
|