-
Notifications
You must be signed in to change notification settings - Fork 557
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: pass options to transforms filters, live demo main page (#1208)
- Loading branch information
1 parent
0972b26
commit 4ec34fd
Showing
6 changed files
with
315 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'style-dictionary': patch | ||
--- | ||
|
||
Pass options to all of the filter functions in our built-in transforms, to check for `usesDTCG` and `$type` property. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,237 @@ | ||
{ | ||
"colors": { | ||
"$type": "color", | ||
"black": { | ||
"$value": "#000000" | ||
}, | ||
"white": { | ||
"$value": "#ffffff" | ||
}, | ||
"orange": { | ||
"100": { | ||
"$value": "#fffaf0" | ||
}, | ||
"200": { | ||
"$value": "#feebc8" | ||
}, | ||
"300": { | ||
"$value": "#fbd38d" | ||
}, | ||
"400": { | ||
"$value": "#f6ad55" | ||
}, | ||
"500": { | ||
"$value": "#ed8936" | ||
}, | ||
"600": { | ||
"$value": "#dd6b20" | ||
}, | ||
"700": { | ||
"$value": "#c05621" | ||
}, | ||
"800": { | ||
"$value": "#9c4221" | ||
}, | ||
"900": { | ||
"$value": "#7b341e" | ||
} | ||
} | ||
}, | ||
"dimensions": { | ||
"$type": "dimension", | ||
"0": { | ||
"$value": "0px" | ||
}, | ||
"1": { | ||
"$value": "4px" | ||
}, | ||
"2": { | ||
"$value": "8px" | ||
}, | ||
"3": { | ||
"$value": "12px" | ||
}, | ||
"4": { | ||
"$value": "16px" | ||
}, | ||
"5": { | ||
"$value": "20px" | ||
}, | ||
"6": { | ||
"$value": "24px" | ||
}, | ||
"7": { | ||
"$value": "28px" | ||
}, | ||
"8": { | ||
"$value": "32px" | ||
}, | ||
"9": { | ||
"$value": "36px" | ||
}, | ||
"10": { | ||
"$value": "40px" | ||
}, | ||
"11": { | ||
"$value": "44px" | ||
}, | ||
"12": { | ||
"$value": "48px" | ||
}, | ||
"13": { | ||
"$value": "52px" | ||
}, | ||
"14": { | ||
"$value": "56px" | ||
}, | ||
"15": { | ||
"$value": "60px" | ||
}, | ||
"max": { | ||
"$value": "9999px" | ||
} | ||
}, | ||
"text": { | ||
"fonts": { | ||
"$type": "fontFamily", | ||
"serif": { | ||
"$value": "Times New Roman, serif" | ||
}, | ||
"sans": { | ||
"$value": "Open Sans, sans-serif" | ||
} | ||
}, | ||
"weights": { | ||
"$type": "fontWeight", | ||
"light": { | ||
"$value": "thin" | ||
}, | ||
"regular": { | ||
"$value": "regular" | ||
}, | ||
"bold": { | ||
"$value": "extra-bold" | ||
} | ||
}, | ||
"lineHeights": { | ||
"$type": "number", | ||
"normal": { | ||
"$value": 1.2 | ||
}, | ||
"large": { | ||
"$value": 1.8 | ||
} | ||
}, | ||
"typography": { | ||
"$type": "typography", | ||
"heading": { | ||
"$value": { | ||
"fontFamily": "{text.fonts.sans}", | ||
"fontWeight": "{text.weights.bold}", | ||
"fontSize": "{dimensions.7}", | ||
"lineHeight": "{text.lineHeights.large}" | ||
} | ||
}, | ||
"body": { | ||
"$value": { | ||
"fontFamily": "{text.fonts.serif}", | ||
"fontWeight": "{text.weights.regular}", | ||
"fontSize": "{dimensions.4}", | ||
"lineHeight": "{text.lineHeights.normal}" | ||
} | ||
} | ||
} | ||
}, | ||
"transitions": { | ||
"$type": "transition", | ||
"emphasis": { | ||
"$value": { | ||
"duration": "{transitions.durations.medium}", | ||
"delay": "{transitions.durations.instant}", | ||
"timingFunction": "{transitions.easingFunctions.accelerate}" | ||
} | ||
}, | ||
"fade": { | ||
"$value": { | ||
"duration": "{transitions.durations.long}", | ||
"delay": "{transitions.durations.instant}", | ||
"timingFunction": "{transitions.easingFunctions.decelerate}" | ||
} | ||
}, | ||
"easingFunctions": { | ||
"$type": "cubicBezier", | ||
"accelerate": { | ||
"$value": [0.5, 0, 1, 1] | ||
}, | ||
"decelerate": { | ||
"$value": [0, 0, 0.5, 1] | ||
} | ||
}, | ||
"durations": { | ||
"$type": "duration", | ||
"instant": { | ||
"$value": "0ms" | ||
}, | ||
"short": { | ||
"$value": "100ms" | ||
}, | ||
"medium": { | ||
"$value": "300ms" | ||
}, | ||
"long": { | ||
"$value": "600ms" | ||
} | ||
} | ||
}, | ||
"borders": { | ||
"$type": "border", | ||
"heavy": { | ||
"$value": { | ||
"color": "{colors.black}", | ||
"width": "{dimensions.1}", | ||
"style": "{borders.styles.solid}" | ||
} | ||
}, | ||
"wireframe": { | ||
"$value": { | ||
"color": "{colors.orange.600}", | ||
"width": "{dimensions.2}", | ||
"style": "{borders.styles.dashed}" | ||
} | ||
}, | ||
"styles": { | ||
"$type": "strokeStyle", | ||
"solid": { | ||
"$value": "solid" | ||
}, | ||
"dashed": { | ||
"$value": { | ||
"dashArray": ["0.5rem", "0.25rem"], | ||
"lineCap": "round" | ||
} | ||
} | ||
} | ||
}, | ||
"shadows": { | ||
"$type": "shadow", | ||
"sm": { | ||
"$value": { | ||
"color": "{colors.black}", | ||
"offsetX": "{dimensions.0}", | ||
"offsetY": "{dimensions.1}", | ||
"blur": "{dimensions.3}" | ||
} | ||
}, | ||
"lg": { | ||
"$value": { | ||
"color": "{colors.black}", | ||
"offsetX": "{dimensions.0}", | ||
"offsetY": "{dimensions.2}", | ||
"blur": "{dimensions.4}" | ||
} | ||
}, | ||
"multi": { | ||
"$value": ["{shadows.sm}", "{shadows.lg}"] | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.