-
-
Notifications
You must be signed in to change notification settings - Fork 242
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(text-styles): expand support properties
- Loading branch information
1 parent
c3e797e
commit 221c9a2
Showing
4 changed files
with
85 additions
and
25 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,6 @@ | ||
--- | ||
"@pandacss/generator": minor | ||
"@pandacss/types": minor | ||
--- | ||
|
||
Add support for more typography related properties in text styles such as `fontFeatureSettings`, `fontPalette`, etc. |
2 changes: 1 addition & 1 deletion
2
packages/generator/src/artifacts/generated/composition.d.ts.json
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 |
---|---|---|
@@ -1,3 +1,3 @@ | ||
{ | ||
"content": "import type { CompositionStyleObject } from './system-types'\n\ninterface Token<T> {\n value: T\n description?: string\n}\n\ninterface Recursive<T> {\n [key: string]: Recursive<T> | T\n}\n\n/* -----------------------------------------------------------------------------\n * Text styles\n * -----------------------------------------------------------------------------*/\n\ntype TextStyleProperty =\n | 'fontSize'\n | 'fontSizeAdjust'\n | 'fontVariationSettings'\n | 'fontVariantPosition'\n | 'fontVariantCaps'\n | 'fontVariantNumeric'\n | 'fontVariantAlternates'\n | 'fontVariantLigatures'\n | 'fontFamily'\n | 'fontWeight'\n | 'fontSynthesis'\n | 'fontStyle'\n | 'fontVariant'\n | 'lineHeight'\n | 'letterSpacing'\n | 'textDecoration'\n | 'textTransform'\n | 'textIndent'\n | 'textDecorationColor'\n | 'textDecorationLine'\n | 'textDecorationStyle'\n | 'textEmphasisColor'\n | 'textEmphasisPosition'\n | 'textEmphasisStyle'\n | 'hyphenateCharacter'\n | 'textOrientation'\n | 'textOverflow'\n | 'textRendering'\n\nexport type TextStyle = CompositionStyleObject<TextStyleProperty>\n\nexport type TextStyles = Recursive<Token<TextStyle>>\n\n/* -----------------------------------------------------------------------------\n * Layer styles\n * -----------------------------------------------------------------------------*/\n\ntype Placement =\n | 'Top'\n | 'Right'\n | 'Bottom'\n | 'Left'\n | 'Inline'\n | 'Block'\n | 'InlineStart'\n | 'InlineEnd'\n | 'BlockStart'\n | 'BlockEnd'\n\ntype Radius =\n | `Top${'Right' | 'Left'}`\n | `Bottom${'Right' | 'Left'}`\n | `Start${'Start' | 'End'}`\n | `End${'Start' | 'End'}`\n\ntype LayerStyleProperty =\n | 'background'\n | 'backgroundColor'\n | 'backgroundImage'\n | 'borderRadius'\n | 'border'\n | 'borderWidth'\n | 'borderColor'\n | 'borderStyle'\n | 'boxShadow'\n | 'filter'\n | 'backdropFilter'\n | 'transform'\n | 'color'\n | 'opacity'\n | 'backgroundBlendMode'\n | 'backgroundAttachment'\n | 'backgroundClip'\n | 'backgroundOrigin'\n | 'backgroundPosition'\n | 'backgroundRepeat'\n | 'backgroundSize'\n | `border${Placement}`\n | `border${Placement}Width`\n | 'borderRadius'\n | `border${Radius}Radius`\n | `border${Placement}Color`\n | `border${Placement}Style`\n | 'padding'\n | `padding${Placement}`\n\nexport type LayerStyle = CompositionStyleObject<LayerStyleProperty>\n\nexport type LayerStyles = Recursive<Token<LayerStyle>>\n\nexport interface CompositionStyles {\n textStyles: TextStyles\n layerStyles: LayerStyles\n}\n" | ||
"content": "import type { CompositionStyleObject } from './system-types'\n\ninterface Token<T> {\n value: T\n description?: string\n}\n\ninterface Recursive<T> {\n [key: string]: Recursive<T> | T\n}\n\n/* -----------------------------------------------------------------------------\n * Text styles\n * -----------------------------------------------------------------------------*/\n\ntype TextStyleProperty =\n | 'font'\n | 'fontFamily'\n | 'fontFeatureSettings'\n | 'fontKerning'\n | 'fontLanguageOverride'\n | 'fontOpticalSizing'\n | 'fontPalette'\n | 'fontSize'\n | 'fontSizeAdjust'\n | 'fontStretch'\n | 'fontStyle'\n | 'fontSynthesis'\n | 'fontVariant'\n | 'fontVariantAlternates'\n | 'fontVariantCaps'\n | 'fontVariantLigatures'\n | 'fontVariantNumeric'\n | 'fontVariantPosition'\n | 'fontVariationSettings'\n | 'fontWeight'\n | 'hypens'\n | 'hyphenateCharacter'\n | 'hyphenateLimitChars'\n | 'letterSpacing'\n | 'lineBreak'\n | 'lineHeight'\n | 'quotes'\n | 'overflowWrap'\n | 'textCombineUpright'\n | 'textDecoration'\n | 'textDecorationColor'\n | 'textDecorationLine'\n | 'textDecorationSkipInk'\n | 'textDecorationStyle'\n | 'textDecorationThickness'\n | 'textEmphasis'\n | 'textEmphasisColor'\n | 'textEmphasisPosition'\n | 'textEmphasisStyle'\n | 'textIndent'\n | 'textJustify'\n | 'textOrientation'\n | 'textOverflow'\n | 'textRendering'\n | 'textShadow'\n | 'textTransform'\n | 'textUnderlineOffset'\n | 'textUnderlinePosition'\n | 'textWrap'\n | 'textWrapMode'\n | 'textWrapStyle'\n | 'verticalAlign'\n | 'whiteSpace'\n | 'wordBreak'\n | 'wordSpacing'\n\nexport type TextStyle = CompositionStyleObject<TextStyleProperty>\n\nexport type TextStyles = Recursive<Token<TextStyle>>\n\n/* -----------------------------------------------------------------------------\n * Layer styles\n * -----------------------------------------------------------------------------*/\n\ntype Placement =\n | 'Top'\n | 'Right'\n | 'Bottom'\n | 'Left'\n | 'Inline'\n | 'Block'\n | 'InlineStart'\n | 'InlineEnd'\n | 'BlockStart'\n | 'BlockEnd'\n\ntype Radius =\n | `Top${'Right' | 'Left'}`\n | `Bottom${'Right' | 'Left'}`\n | `Start${'Start' | 'End'}`\n | `End${'Start' | 'End'}`\n\ntype LayerStyleProperty =\n | 'background'\n | 'backgroundColor'\n | 'backgroundImage'\n | 'borderRadius'\n | 'border'\n | 'borderWidth'\n | 'borderColor'\n | 'borderStyle'\n | 'boxShadow'\n | 'filter'\n | 'backdropFilter'\n | 'transform'\n | 'color'\n | 'opacity'\n | 'backgroundBlendMode'\n | 'backgroundAttachment'\n | 'backgroundClip'\n | 'backgroundOrigin'\n | 'backgroundPosition'\n | 'backgroundRepeat'\n | 'backgroundSize'\n | `border${Placement}`\n | `border${Placement}Width`\n | 'borderRadius'\n | `border${Radius}Radius`\n | `border${Placement}Color`\n | `border${Placement}Style`\n | 'padding'\n | `padding${Placement}`\n\nexport type LayerStyle = CompositionStyleObject<LayerStyleProperty>\n\nexport type LayerStyles = Recursive<Token<LayerStyle>>\n\nexport interface CompositionStyles {\n textStyles: TextStyles\n layerStyles: LayerStyles\n}\n" | ||
} |
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