Updates
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
import {
|
||||
UICompBuilder,
|
||||
stringExposingStateControl,
|
||||
Section,
|
||||
withExposingConfigs,
|
||||
NameConfig,
|
||||
} from "lowcoder-sdk";
|
||||
|
||||
import styles from "./style.module.css";
|
||||
|
||||
const childrenMap = {
|
||||
text: stringExposingStateControl("text", "world"),
|
||||
};
|
||||
|
||||
const HelloWorldCompBase = new UICompBuilder(childrenMap, (props: any) => {
|
||||
const text = props.text.value;
|
||||
return <div className={styles.wrapper}>Hello {text}</div>;
|
||||
})
|
||||
.setPropertyViewFn((children: any) => {
|
||||
return <Section name="Basic">{children.text.propertyView({ label: "Text" })}</Section>;
|
||||
})
|
||||
.build();
|
||||
|
||||
export default withExposingConfigs(HelloWorldCompBase, [new NameConfig("text", "")]);
|
||||
Reference in New Issue
Block a user