- Notifications
You must be signed in to change notification settings - Fork254
Doc/existing components#1403
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Merged
Uh oh!
There was an error while loading.Please reload this page.
Merged
Changes fromall commits
Commits
Show all changes
4 commits Select commitHold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Uh oh!
There was an error while loading.Please reload this page.
Jump to
Jump to file
Failed to load files.
Loading
Uh oh!
There was an error while loading.Please reload this page.
Diff view
Diff view
There are no files selected for viewing
2 changes: 1 addition & 1 deletionclient/packages/lowcoder/src/comps/comps/transferComp.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
61 changes: 61 additions & 0 deletionsclient/packages/lowcoder/src/pages/ComponentDoc/examples/ButtonComp/FloatButton.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
import { FloatButtonComp } from "comps/comps/buttonComp/floatButtonComp" | ||
import { trans } from "i18n"; | ||
import Example from "../../common/Example"; | ||
import ExampleGroup from "../../common/ExampleGroup"; | ||
export default function FloatButtonExample() { | ||
return ( | ||
<> | ||
<ExampleGroup | ||
title={trans("componentDoc.basicUsage")} | ||
description={trans("componentDoc.basicDemoDescription")} | ||
> | ||
<Example | ||
title={trans("componentDoc.default")} | ||
config={{ | ||
icon: "/icon:antd/questioncircleoutlined", | ||
value: "", | ||
shape: "circle", | ||
manual: [ | ||
{ | ||
badge: "1", | ||
description: "", | ||
icon: "/icon:antd/filetextoutlined", | ||
id: 0, | ||
label: "Option 1" | ||
}, | ||
{ | ||
badge: "1", | ||
description: "", | ||
icon: "/icon:antd/filetextoutlined", | ||
id: 1, | ||
label: "Option 2" | ||
} | ||
] | ||
}} | ||
compFactory={FloatButtonComp} | ||
/> | ||
<Example | ||
title={trans("componentDoc.loading")} | ||
width={120} | ||
config={{ | ||
text: trans("componentDoc.submit"), | ||
loading: true | ||
}} | ||
compFactory={FloatButtonComp} | ||
/> | ||
<Example | ||
title={trans("componentDoc.disabled")} | ||
width={120} | ||
config={{ | ||
text: trans("componentDoc.submit"), | ||
disabled: true | ||
}} | ||
compFactory={FloatButtonComp} | ||
/> | ||
</ExampleGroup> | ||
</> | ||
); | ||
} |
68 changes: 68 additions & 0 deletionsclient/packages/lowcoder/src/pages/ComponentDoc/examples/ButtonComp/IconButton.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
import { IconComp } from "comps/comps/iconComp"; | ||
import { trans } from "i18n"; | ||
import Example from "../../common/Example"; | ||
import ExampleGroup from "../../common/ExampleGroup"; | ||
export default function IconButtonExample() { | ||
return ( | ||
<> | ||
<ExampleGroup | ||
title={trans("componentDoc.basicUsage")} | ||
description={trans("componentDoc.basicDemoDescription")} | ||
> | ||
<Example | ||
title={trans("componentDoc.default")} | ||
width={20} | ||
config={{ | ||
form: "", | ||
type: "", | ||
prefixIcon: "/icon:solid/align-justify", | ||
iconSize: "30px", | ||
aspectRatio: "1 / 1", | ||
autoHeight: "fixed", | ||
}} | ||
compFactory={IconComp} | ||
/> | ||
<Example | ||
title={trans("componentDoc.loading")} | ||
width={120} | ||
config={{ type: "default", text: trans("componentDoc.submit"), loading: true }} | ||
compFactory={IconComp} | ||
/> | ||
<Example | ||
title={trans("componentDoc.disabled")} | ||
width={120} | ||
config={{ type: "default", text: trans("componentDoc.submit"), disabled: true }} | ||
compFactory={IconComp} | ||
/> | ||
</ExampleGroup> | ||
<ExampleGroup title={trans("componentDoc.style")}> | ||
<Example | ||
title={trans("componentDoc.danger")} | ||
width={120} | ||
config={{ | ||
style: { backgroundColor: "#CD574C", borderColor: "#AC3A32", color: "#E0ECF6" }, | ||
}} | ||
compFactory={IconComp} | ||
/> | ||
<Example | ||
title={trans("componentDoc.warning")} | ||
width={120} | ||
config={{ | ||
style: { backgroundColor: "#F4A125", borderColor: "#DA7D16", color: "#000000" }, | ||
}} | ||
compFactory={IconComp} | ||
/> | ||
<Example | ||
title={trans("componentDoc.success")} | ||
width={120} | ||
config={{ | ||
style: { backgroundColor: "#5E8D6E", borderColor: "#40694E", color: "#E0ECF6" }, | ||
}} | ||
compFactory={IconComp} | ||
/> | ||
</ExampleGroup> | ||
</> | ||
); | ||
} |
110 changes: 110 additions & 0 deletionsclient/packages/lowcoder/src/pages/ComponentDoc/examples/ButtonComp/ToggleButton.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,110 @@ | ||
import { ToggleButtonComp } from "comps/comps/buttonComp/toggleButtonComp" | ||
import { trans } from "i18n"; | ||
import Example from "../../common/Example"; | ||
import ExampleGroup from "../../common/ExampleGroup"; | ||
export default function ToggleButtonExample() { | ||
return ( | ||
<> | ||
<ExampleGroup | ||
title={trans("componentDoc.basicUsage")} | ||
description={trans("componentDoc.basicDemoDescription")} | ||
> | ||
<Example | ||
title={trans("componentDoc.default")} | ||
width={120} | ||
config={{ | ||
text: trans("componentDoc.submit") | ||
}} | ||
compFactory={ToggleButtonComp} | ||
/> | ||
<Example | ||
title={trans("componentDoc.loading")} | ||
width={120} | ||
config={{ | ||
text: trans("componentDoc.submit"), | ||
loading: true | ||
}} | ||
compFactory={ToggleButtonComp} | ||
/> | ||
<Example | ||
title={trans("componentDoc.disabled")} | ||
width={120} | ||
config={{ | ||
text: trans("componentDoc.submit"), | ||
disabled: true | ||
}} | ||
compFactory={ToggleButtonComp} | ||
/> | ||
</ExampleGroup> | ||
<ExampleGroup title="Advanced"> | ||
<Example | ||
title="Hide Text" | ||
width={120} | ||
config={{ | ||
text: trans("componentDoc.submit"), | ||
showText: false, | ||
}} | ||
compFactory={ToggleButtonComp} | ||
/> | ||
<Example | ||
title="Text for True & False" | ||
width={120} | ||
config={{ | ||
text: trans("componentDoc.submit"), | ||
showText: true, | ||
trueText: "True", | ||
falseText: "False", | ||
}} | ||
compFactory={ToggleButtonComp} | ||
/> | ||
<Example | ||
title="Icon Position" | ||
width={120} | ||
config={{ | ||
text: trans("componentDoc.submit"), | ||
iconPosition: "left", | ||
}} | ||
compFactory={ToggleButtonComp} | ||
/> | ||
<Example | ||
title="Content Alignment - Left" | ||
width={180} | ||
config={{ | ||
text: trans("componentDoc.submit"), | ||
alignment: "left", | ||
}} | ||
compFactory={ToggleButtonComp} | ||
/> | ||
<Example | ||
title="Content Alignment - Right" | ||
width={180} | ||
config={{ | ||
text: trans("componentDoc.submit"), | ||
alignment: "right", | ||
}} | ||
compFactory={ToggleButtonComp} | ||
/> | ||
<Example | ||
title="Content Alignment - Center" | ||
width={180} | ||
config={{ | ||
text: trans("componentDoc.submit"), | ||
alignment: "center", | ||
}} | ||
compFactory={ToggleButtonComp} | ||
/> | ||
<Example | ||
title="Content Alignment - Justified" | ||
width={180} | ||
config={{ | ||
text: trans("componentDoc.submit"), | ||
alignment: "stretch", | ||
}} | ||
compFactory={ToggleButtonComp} | ||
/> | ||
</ExampleGroup> | ||
</> | ||
); | ||
} |
29 changes: 29 additions & 0 deletionsclient/packages/lowcoder/src/pages/ComponentDoc/examples/CalendarInputComp/Timer.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
import { TimerComp } from "comps/comps/timerComp"; | ||
import Example from "../../common/Example"; | ||
import ExampleGroup from "../../common/ExampleGroup"; | ||
export default function TimerExample() { | ||
return ( | ||
<> | ||
<ExampleGroup | ||
title="Basic Usage" | ||
> | ||
<Example | ||
title="Default Value" | ||
config={{ | ||
defaultValue: "00:00:03:000", | ||
}} | ||
compFactory={TimerComp} | ||
/> | ||
<Example | ||
title="Hide Buttons" | ||
config={{ | ||
defaultValue: "00:00:00:000", | ||
hideButton: true, | ||
}} | ||
compFactory={TimerComp} | ||
/> | ||
</ExampleGroup> | ||
</> | ||
); | ||
} |
78 changes: 78 additions & 0 deletionsclient/packages/lowcoder/src/pages/ComponentDoc/examples/ContainersComp/ColumnLayout.tsx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,78 @@ | ||
import { ColumnLayoutComp } from "comps/comps/columnLayout/columnLayout"; | ||
import Example from "../../common/Example"; | ||
import ExampleGroup from "../../common/ExampleGroup"; | ||
export default function ColumnLayoutExample() { | ||
return ( | ||
<> | ||
<ExampleGroup | ||
title="Basic Usage" | ||
description="The Following Examples Show the Basic Usage of the Column Layout Component." | ||
> | ||
<Example | ||
title="Hiding the Component" | ||
config={{ | ||
hidden: true, | ||
}} | ||
compFactory={ColumnLayoutComp} | ||
/> | ||
<Example | ||
title="Disabling the Component" | ||
config={{ | ||
disabled: true, | ||
}} | ||
compFactory={ColumnLayoutComp} | ||
/> | ||
<Example | ||
title="Multiple Columns" | ||
config={{ | ||
columns:{ | ||
manual:[ | ||
{ | ||
id:0, | ||
label:"Column1", | ||
}, | ||
{ | ||
id:1, | ||
label:"Column2", | ||
}, | ||
{ | ||
id:2, | ||
label:"Column3", | ||
}, | ||
] | ||
} | ||
}} | ||
compFactory={ColumnLayoutComp} | ||
/> | ||
</ExampleGroup> | ||
<ExampleGroup | ||
title="Column's Layout" | ||
description="The Following Examples Show the Column Layout options on Column Layout Component." | ||
> | ||
<Example | ||
title="Column Definition" | ||
config={{ | ||
templateColumns: "1fr 1fr 1fr 1fr", | ||
}} | ||
compFactory={ColumnLayoutComp} | ||
/> | ||
<Example | ||
title="Row Definition" | ||
config={{ | ||
templateRows: "1fr 1fr", | ||
}} | ||
compFactory={ColumnLayoutComp} | ||
/> | ||
<Example | ||
title="Column Gap" | ||
config={{ | ||
columnGap: "50px", | ||
}} | ||
compFactory={ColumnLayoutComp} | ||
/> | ||
</ExampleGroup> | ||
</> | ||
); | ||
} |
Oops, something went wrong.
Uh oh!
There was an error while loading.Please reload this page.
Oops, something went wrong.
Uh oh!
There was an error while loading.Please reload this page.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.