Skip to content

Commit 5c32095

Browse files
Deploying to gh-pages from @ 2702042 🚀
1 parent c14d1a4 commit 5c32095

1,059 files changed

Lines changed: 54666 additions & 54650 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

nightly/assets/Achievement-BseiMz8z.js

Lines changed: 0 additions & 102 deletions
This file was deleted.

nightly/assets/Achievement-CnoP4N_C.js

Lines changed: 102 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
import{n as e}from"./chunk-jRWAZmH_.js";import{Gm as t}from"./iframe-Dv9_Cl4s.js";import{r as n}from"./react-BVF2Vu1y.js";import{_ as r,o as i,p as a,s as o,t as s}from"./components-DHY-Eqdw.js";import{_ as c,d as l,r as u}from"./blocks-mS-NSdaN.js";import{Default as d,n as f,t as p}from"./ActionSheet.stories-CSn2UNzG.js";function m(e){let t={code:`code`,h2:`h2`,p:`p`,pre:`pre`,strong:`strong`,...n(),...e.components};return(0,g.jsxs)(g.Fragment,{children:[(0,g.jsx)(l,{of:p}),`
2+
`,(0,g.jsx)(o,{of:p,subComponents:[`Button`]}),`
3+
`,(0,g.jsx)(`br`,{}),`
4+
`,(0,g.jsx)(t.h2,{id:`example`,children:`Example`}),`
5+
`,(0,g.jsx)(u,{of:d}),`
6+
`,(0,g.jsx)(t.h2,{id:`properties`,children:`Properties`}),`
7+
`,(0,g.jsx)(a,{of:d}),`
8+
`,(0,g.jsx)(t.h2,{id:`opening-actionsheets`,children:`Opening ActionSheets`}),`
9+
`,(0,g.jsx)(`br`,{}),`
10+
`,(0,g.jsxs)(t.p,{children:[`You can open and close the `,(0,g.jsx)(t.code,{children:`ActionSheet`}),` component in a declarative way using the `,(0,g.jsx)(t.code,{children:`open`}),` and `,(0,g.jsx)(t.code,{children:`opener`}),` prop.`]}),`
11+
`,(0,g.jsx)(t.pre,{children:(0,g.jsx)(t.code,{className:`language-tsx`,children:`const MyComponentWithActionSheet = () => {
12+
const [actionSheetIsOpen, setActionSheetIsOpen] = useState(false);
13+
return (
14+
<>
15+
<Button
16+
id={'openActionSheetBtn'}
17+
onClick={() => {
18+
setActionSheetIsOpen(true);
19+
}}
20+
>
21+
Open Action Sheet
22+
</Button>
23+
<ActionSheet
24+
opener={'openActionSheetBtn'}
25+
open={actionSheetIsOpen}
26+
onClose={() => {
27+
setActionSheetIsOpen(false);
28+
}}
29+
/>
30+
</>
31+
);
32+
};
33+
`})}),`
34+
`,(0,g.jsx)(t.p,{children:(0,g.jsxs)(t.strong,{children:[`Opening an `,(0,g.jsx)(t.code,{children:`ActionSheet`}),` by reference`]})}),`
35+
`,(0,g.jsxs)(t.p,{children:[`The `,(0,g.jsx)(t.code,{children:`ActionSheet`}),` exposes a way to pass a reference of an element instead of an `,(0,g.jsx)(t.code,{children:`id`}),` to the `,(0,g.jsx)(t.code,{children:`opener`}),` prop.
36+
You can do that by e.g. leveraging a React Ref.`]}),`
37+
`,(0,g.jsx)(t.pre,{children:(0,g.jsx)(t.code,{className:`language-jsx`,children:`const ActionSheetComponent = () => {
38+
const buttonRef = useRef(null);
39+
const [open, setOpen] = useState(false);
40+
const handleOpenerClick = (e) => {
41+
setOpen((prev) => !prev);
42+
};
43+
return (
44+
<>
45+
<Button ref={buttonRef} onClick={handleOpenerClick}>
46+
Opener
47+
</Button>
48+
<ActionSheet opener={buttonRef.current} open={open}>
49+
{/* Content */}
50+
</ActionSheet>
51+
</>
52+
);
53+
};
54+
`})}),`
55+
`,(0,g.jsx)(i,{})]})}function h(e={}){let{wrapper:t}={...n(),...e.components};return t?(0,g.jsx)(t,{...e,children:(0,g.jsx)(m,{...e})}):m(e)}var g;e((()=>{g=t(),r(),s(),c(),f()}))();export{h as default};

nightly/assets/ActionSheet-BOzFXB3V.js

Lines changed: 0 additions & 55 deletions
This file was deleted.

nightly/assets/ActionSheet.stories-BGwCMxUJ.js

Lines changed: 0 additions & 27 deletions
This file was deleted.

nightly/assets/ActionSheet.stories-CSn2UNzG.js

Lines changed: 27 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)