Skip to content

Commit f381f79

Browse files
adnanqaopsraheeliftikhar5
authored andcommitted
added examples for multiple components
1 parent 8b13735 commit f381f79

File tree

24 files changed

+7875
-176
lines changed

24 files changed

+7875
-176
lines changed

client/packages/lowcoder/src/pages/ComponentDoc/examples/ButtonComp/FloatButton.tsx

Lines changed: 24 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,25 @@ import { trans } from "i18n";
33
import Example from "../../common/Example";
44
import ExampleGroup from "../../common/ExampleGroup";
55

6+
const buttons = {
7+
"manual": [
8+
{
9+
"id": 0,
10+
"label": "Option 1",
11+
"badge": "1",
12+
"description": "",
13+
"icon": "/icon:antd/filetextoutlined"
14+
},
15+
{
16+
"id": 1,
17+
"label": "Option 2",
18+
"badge": "0",
19+
"description": "",
20+
"icon": "/icon:antd/filetextoutlined"
21+
}
22+
]
23+
};
24+
625
export default function FloatButtonExample() {
726
return (
827
<>
@@ -13,44 +32,13 @@ export default function FloatButtonExample() {
1332
<Example
1433
title={trans("componentDoc.default")}
1534
config={{
35+
buttons: buttons,
36+
buttonTheme: "primary",
1637
icon: "/icon:antd/questioncircleoutlined",
17-
value: "",
38+
includeMargin: true,
39+
preventStyleOverwriting: false,
1840
shape: "circle",
19-
manual: [
20-
{
21-
badge: "1",
22-
description: "",
23-
icon: "/icon:antd/filetextoutlined",
24-
id: 0,
25-
label: "Option 1"
26-
},
27-
{
28-
badge: "1",
29-
description: "",
30-
icon: "/icon:antd/filetextoutlined",
31-
id: 1,
32-
label: "Option 2"
33-
}
34-
]
35-
36-
}}
37-
compFactory={FloatButtonComp}
38-
/>
39-
<Example
40-
title={trans("componentDoc.loading")}
41-
width={120}
42-
config={{
43-
text: trans("componentDoc.submit"),
44-
loading: true
45-
}}
46-
compFactory={FloatButtonComp}
47-
/>
48-
<Example
49-
title={trans("componentDoc.disabled")}
50-
width={120}
51-
config={{
52-
text: trans("componentDoc.submit"),
53-
disabled: true
41+
value: "",
5442
}}
5543
compFactory={FloatButtonComp}
5644
/>

client/packages/lowcoder/src/pages/ComponentDoc/examples/ButtonComp/IconButton.tsx

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,9 @@ export default function IconButtonExample() {
1212
>
1313
<Example
1414
title={trans("componentDoc.default")}
15-
width={20}
1615
config={{
17-
form: "",
18-
type: "",
1916
prefixIcon: "/icon:solid/align-justify",
2017
iconSize: "30px",
21-
aspectRatio: "1 / 1",
22-
autoHeight: "fixed",
2318
}}
2419
compFactory={IconComp}
2520
/>

0 commit comments

Comments
 (0)