Repository navigation
refactor: rename variant and enum values to shared names - #978
rohanchkrabrty wants to merge 2 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 14 minutes. View limit details
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info
📝 Walkthrough
Priority: ➖ Normal Merge Risk: ⚪ Minimal · up to
|
commit: |
Summary
variantvalues to the names other components use:Input,TextAreaandSearchtakeoutlineandtext(weredefaultandborderless),FilterChiptakesoutline(wasdefault), andChiptakessolid(wasfilled).EmptyStatevariants after their layouts:empty1iscompactandempty2ispage.Gridtakesalignandjustifyin place ofalignItemsandjustifyContent, asFlexdoes.justifyandalignContenttakebetween,aroundandevenlyin place of thespace-*values.alignContentandjustifyItemskeep their names.CalendarPreviewnames the half-year scalehalf-year(washalfYear) inscales,scale,defaultScale,onScaleChange, value objects anddata-scale.Decisions
EmptyStatenames:compactis the centered layout with stacked actions for panels and lists.pageis the full-page layout with left-aligned content, a larger icon and actions in a row. The docs already describe them this way, and the CSS calls the second oneemptyStatePage.<prop>-<value>: FilterChipchip-defaultisvariant-outline, and Chip's private--chip-filled-*variables are--chip-solid-*. Computed styles do not change.variantrow it was missing.docs/V1-migration.mdanddocs/rfcs/005-calendar-preview.mdkeep the old names, because they describe earlier releases.direction(rowReverse,columnReverse) andwrap(noWrap,wrapReverse) values are camelCase, but the proposal does not list them, so they do not change here.Checks
pnpm lint,pnpm exec tsc --noEmitinpackages/react,pnpm test:apsara(3724 tests) andpnpm build:apsarapass.Compared the docs pages against apsara.raystack.org: Input, TextArea, Search, FilterChip, Chip, EmptyState, Grid, CalendarPreview, Command, Editor and PromptInput in light, and TextArea, Search, FilterChip, Chip, EmptyState and Grid in dark. The computed styles of every demo match. The Chip, TextArea, FilterChip, EmptyState and Grid playgrounds render the new values with the same styles as the old ones. The Upgrading page renders.
I have followed the pull request section of the contributing guide.