-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(Disclosure): use logical properties #1140
Conversation
Preview is ready. |
src/components/Disclosure/README.md
Outdated
@@ -11,7 +11,7 @@ Disclosure component that shows and hides enclosed content. | |||
| disabled | `Boolean` | | `false` | Disabled state | | |||
| defaultExpanded | `Boolean` | | `false` | Default opening state | | |||
| expanded | `Boolean` | | | Controlled opening state | | |||
| arrowPosition | `left` `right` | | `left` | Control position | | |||
| arrowPosition | `left` `right` `start` `end` | | `start` | Control position | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We suppose left and right are being deprecated, so they don’t need to be documented
@@ -38,11 +38,19 @@ export function DefaultDisclosureSummary({ | |||
disabled, | |||
}: DisclosureSummaryRenderFunctionProps) { | |||
const {size, summary, arrowPosition} = useDisclosureAttributes(); | |||
let sideMod = arrowPosition; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Isn’t it arrowMod
?
@@ -11,7 +11,7 @@ import {b} from './cn'; | |||
import './Disclosure.scss'; | |||
|
|||
export type DisclosureSize = 'm' | 'l' | 'xl'; | |||
export type DisclosureArrowPosition = 'left' | 'right' | 'start' | 'end'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would break typings for those who passes this type to the props. Let's keep them here. I will add warning later, for all such types
No description provided.