Skip to content

Commit

Permalink
fix: scrollbar gutter
Browse files Browse the repository at this point in the history
  • Loading branch information
segunadebayo committed Dec 6, 2024
1 parent ab827ea commit af9715a
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 6 deletions.
7 changes: 7 additions & 0 deletions .changeset/six-doors-live.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
'@pandacss/preset-base': patch
'@pandacss/generator': patch
---

Fix issue where `scrollbarGutter` property incorrectly referenced spacing tokens. The only valid values are `auto`,
`stable`, and `both-edges`.
1 change: 0 additions & 1 deletion packages/generator/__tests__/generate-prop-types.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,6 @@ describe('generate property types', () => {
caretColor: Tokens["colors"];
scrollbar: "visible" | "hidden";
scrollbarColor: Tokens["colors"];
scrollbarGutter: Tokens["spacing"];
scrollbarWidth: Tokens["sizes"];
scrollMargin: Tokens["spacing"];
scrollMarginLeft: Tokens["spacing"];
Expand Down
4 changes: 2 additions & 2 deletions packages/generator/__tests__/generate-style-props.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4846,7 +4846,7 @@ describe('generate property types', () => {
*
* @see https://developer.mozilla.org/docs/Web/CSS/scrollbar-gutter
*/
scrollbarGutter?: ConditionalValue<UtilityValues["scrollbarGutter"] | CssVars | CssProperties["scrollbarGutter"] | AnyString>
scrollbarGutter?: ConditionalValue<CssProperties["scrollbarGutter"] | AnyString>
/**
* The **\`scrollbar-width\`** property allows the author to set the maximum thickness of an element's scrollbars when they are shown.
*
Expand Down Expand Up @@ -12318,7 +12318,7 @@ describe('generate property types', () => {
*
* @see https://developer.mozilla.org/docs/Web/CSS/scrollbar-gutter
*/
scrollbarGutter?: ConditionalValue<WithEscapeHatch<UtilityValues["scrollbarGutter"] | CssVars>>
scrollbarGutter?: ConditionalValue<WithEscapeHatch<CssProperties["scrollbarGutter"]>>
/**
* The **\`scrollbar-width\`** property allows the author to set the maximum thickness of an element's scrollbars when they are shown.
*
Expand Down
1 change: 0 additions & 1 deletion packages/preset-base/src/utilities/interactivity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ export const interactivity: UtilityConfig = {
},
scrollbarGutter: {
className: 'scr-bar-g',
values: 'spacing',
group: 'Scroll',
},
scrollbarWidth: {
Expand Down
1 change: 0 additions & 1 deletion packages/studio/styled-system/types/prop-type.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,6 @@ export interface UtilityValues {
caretColor: Tokens["colors"];
scrollbar: "visible" | "hidden";
scrollbarColor: Tokens["colors"];
scrollbarGutter: Tokens["spacing"];
scrollbarWidth: Tokens["sizes"];
scrollMargin: Tokens["spacing"];
scrollMarginLeft: Tokens["spacing"];
Expand Down
2 changes: 1 addition & 1 deletion packages/studio/styled-system/types/style-props.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4840,7 +4840,7 @@ scrollbarColor?: ConditionalValue<UtilityValues["scrollbarColor"] | CssVars | Cs
*
* @see https://developer.mozilla.org/docs/Web/CSS/scrollbar-gutter
*/
scrollbarGutter?: ConditionalValue<UtilityValues["scrollbarGutter"] | CssVars | CssProperties["scrollbarGutter"] | AnyString>
scrollbarGutter?: ConditionalValue<CssProperties["scrollbarGutter"] | AnyString>
/**
* The **`scrollbar-width`** property allows the author to set the maximum thickness of an element's scrollbars when they are shown.
*
Expand Down

0 comments on commit af9715a

Please sign in to comment.