refactor[CustomNodes]: Add types to functions that didnt have it
This commit is contained in:
parent
fff6e494db
commit
84b2fb8aae
4 changed files with 2 additions and 4 deletions
|
|
@ -44,7 +44,7 @@ export default function ParameterComponent({
|
||||||
required = false,
|
required = false,
|
||||||
optionalHandle = null,
|
optionalHandle = null,
|
||||||
info = "",
|
info = "",
|
||||||
}: ParameterComponentType) {
|
}: ParameterComponentType): JSX.Element {
|
||||||
const ref = useRef(null);
|
const ref = useRef(null);
|
||||||
const refHtml = useRef(null);
|
const refHtml = useRef(null);
|
||||||
const refNumberComponents = useRef(0);
|
const refNumberComponents = useRef(0);
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@ export default function GenericNode({
|
||||||
}: {
|
}: {
|
||||||
data: NodeDataType;
|
data: NodeDataType;
|
||||||
selected: boolean;
|
selected: boolean;
|
||||||
}) {
|
}): JSX.Element {
|
||||||
const { setErrorData } = useContext(alertContext);
|
const { setErrorData } = useContext(alertContext);
|
||||||
const showError = useRef(true);
|
const showError = useRef(true);
|
||||||
const { types, deleteNode } = useContext(typesContext);
|
const { types, deleteNode } = useContext(typesContext);
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,6 @@ import { classNames } from "../../../../utils/utils";
|
||||||
import { nodeToolbarType } from "../../../../types/components";
|
import { nodeToolbarType } from "../../../../types/components";
|
||||||
|
|
||||||
const NodeToolbarComponent = (props): JSX.Element => {
|
const NodeToolbarComponent = (props): JSX.Element => {
|
||||||
console.log(props);
|
|
||||||
const [nodeLength, setNodeLength] = useState(
|
const [nodeLength, setNodeLength] = useState(
|
||||||
Object.keys(props.data.node.template).filter(
|
Object.keys(props.data.node.template).filter(
|
||||||
(t) =>
|
(t) =>
|
||||||
|
|
|
||||||
|
|
@ -262,7 +262,6 @@ export function varHighlightHTML({ name }: IVarHighlightType): string {
|
||||||
};
|
};
|
||||||
|
|
||||||
export function buildTweakObject(tweak: tweakType[]): string {
|
export function buildTweakObject(tweak: tweakType[]): string {
|
||||||
console.log(tweak)
|
|
||||||
tweak.forEach((el) => {
|
tweak.forEach((el) => {
|
||||||
Object.keys(el).forEach((key) => {
|
Object.keys(el).forEach((key) => {
|
||||||
for (let kp in el[key]) {
|
for (let kp in el[key]) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue