Skip to content

Commit

Permalink
docs: update the storage hooks demos
Browse files Browse the repository at this point in the history
  • Loading branch information
malkiii committed Jul 9, 2024
1 parent 3e6ea86 commit d00e21f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions packages/hooks/src/useLocalStorage/index.page.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ export function Example() {

return (
<div className="demo">
<label className="text-center flex flex-col max-w-md gap-4 mx-auto">
<label className="text-center text-balance flex flex-col max-w-md gap-4 mx-auto">
This input will be saved in the local storage.
<input type="text" defaultValue={text} onChange={e => setText(e.target.value)} />
<input type="text" value={text} onChange={e => setText(e.target.value)} />
</label>
</div>
);
Expand Down
2 changes: 1 addition & 1 deletion packages/hooks/src/useScrollDirection/index.page.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export function Navbar() {
}}
className="sticky top-0 inset-x-0 transition-all duration-300 bg-primary p-4"
>
<p className="mx-auto w-fit text-slate-50">This will apears scroll up.</p>
<p className="mx-auto w-fit text-slate-50">This will apears when you scroll up.</p>
</div>
<div className="h-[640px]"></div>
</div>
Expand Down
4 changes: 2 additions & 2 deletions packages/hooks/src/useSessionStorage/index.page.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ export function Example() {

return (
<div className="demo">
<label className="text-center flex flex-col max-w-md gap-4 mx-auto">
<label className="text-center text-balance flex flex-col max-w-md gap-4 mx-auto">
This input will be saved in the session storage.
<input type="text" defaultValue={text} onChange={e => setText(e.target.value)} />
<input type="text" value={text} onChange={e => setText(e.target.value)} />
</label>
</div>
);
Expand Down

0 comments on commit d00e21f

Please sign in to comment.