Skip to content

Commit

Permalink
docs: 문법적 오류 개선
Browse files Browse the repository at this point in the history
  • Loading branch information
d0422 committed Apr 16, 2024
1 parent f59949d commit 1d53cf6
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ simple hook to change input components(uncontroll component) to controll compone

The animation of this package is based on ClassName by default.

So first, declare css classNames that show animations
First, declare css classNames that show animations

```css
@keyframes fadeIn {
Expand Down Expand Up @@ -64,15 +64,15 @@ So first, declare css classNames that show animations
}
```

then, you can use className as parameters of animation hooks
You can then use class names as parameters for the animation hooks.

### useAnimation

useAnimation manages mount/unmountAnimation.

`AnimationWrapper`: Apply mount/unmountAnimation to the children prop provided in the AnimationWrapper. you can provide style prop to apply style to Wrapper

`show` : trigger mountAnimation
`show` : triggers the mount animation.

`hide` : trigger unmountAnimation and unmount children prop

Expand All @@ -89,12 +89,12 @@ With "useDragIndexCarousel," you can easily implement a dragable Index Carousel.

you can set `startIndex` and `minMove`.

`minMove` : minimum movement that the index goes over.
`minMove` : Minimum movement required for the index to shift.

### useDragCarouselIndex

this hook must be called in carousel provider which is provided by useDragIndexCarousel Component.
carousel provider renders children elements. It already contains `display:flex` property.
This hook should be called within the carousel provider provided by the useDragIndexCarousel component.
carousel provider renders children elements. It already has the `display: flex` property included.

you can get current index in carousel children.

Expand All @@ -108,15 +108,15 @@ you can get current index in carousel children.

`startIndex` : specifies the start index.

`infinity` : When the carousel is over, decide whether to return for the first time.
`infinity` : Specifies whether to loop back to the beginning when the carousel reaches the end.

#### return values

useCarousel returns `CarouselWrapper`, `next`, `prev`, `index`, `ref`, `isEnd`, `isStart`

`CarouselWrapper`: renders children elements. It already contains `display:flex` property.

`ref`: you have to assign ref to Carousel Wrapper
`ref`: you need to assign a ref to the Carousel Wrapper.

`next`: increase index

Expand Down

0 comments on commit 1d53cf6

Please sign in to comment.