Format code
This commit is contained in:
parent
57623be595
commit
d5f034e667
6 changed files with 21 additions and 7 deletions
|
|
@ -1,6 +1,10 @@
|
|||
import { nodeColors } from "../../utils/styleUtils";
|
||||
|
||||
export function getNodeInputColors(input_types: string[] | undefined, type: string | undefined, types: {[char: string]: string}) {
|
||||
export function getNodeInputColors(
|
||||
input_types: string[] | undefined,
|
||||
type: string | undefined,
|
||||
types: { [char: string]: string },
|
||||
) {
|
||||
// Helper function to get the color based on type
|
||||
const getColorByType = (type) => nodeColors[type] ?? nodeColors.unknown;
|
||||
|
||||
|
|
|
|||
|
|
@ -2,7 +2,11 @@ import { OutputFieldType } from "../../types/api";
|
|||
import { NodeDataType } from "../../types/flow";
|
||||
import { nodeColors } from "../../utils/styleUtils";
|
||||
|
||||
export function getNodeOutputColors(output: OutputFieldType, data: NodeDataType, types: {[char: string]: string}): string[] {
|
||||
export function getNodeOutputColors(
|
||||
output: OutputFieldType,
|
||||
data: NodeDataType,
|
||||
types: { [char: string]: string },
|
||||
): string[] {
|
||||
// Helper function to get the color based on type
|
||||
const getColorByType = (type) => nodeColors[type] ?? nodeColors.unknown;
|
||||
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import useAlertStore from "../../stores/alertStore";
|
|||
import ForwardedIconComponent from "../genericIconComponent";
|
||||
import { Separator } from "../ui/separator";
|
||||
|
||||
export default function ImageViewer({ image }: {image: string}) {
|
||||
export default function ImageViewer({ image }: { image: string }) {
|
||||
const viewerRef = useRef(null);
|
||||
const [errorDownloading, setErrordownloading] = useState(false);
|
||||
const setErrorList = useAlertStore((state) => state.setErrorData);
|
||||
|
|
|
|||
|
|
@ -4,8 +4,8 @@ export default function HorizontalScrollFadeComponent({
|
|||
children,
|
||||
isFolder = true,
|
||||
}: {
|
||||
children: JSX.Element | JSX.Element[],
|
||||
isFolder?: boolean,
|
||||
children: JSX.Element | JSX.Element[];
|
||||
isFolder?: boolean;
|
||||
}) {
|
||||
const scrollContainerRef = useRef<HTMLDivElement>(null);
|
||||
const fadeContainerRef = useRef<HTMLDivElement>(null);
|
||||
|
|
|
|||
|
|
@ -3,7 +3,10 @@ import { addFolder, updateFolder } from "../../../pages/MainPage/services";
|
|||
import useAlertStore from "../../../stores/alertStore";
|
||||
import { useFolderStore } from "../../../stores/foldersStore";
|
||||
|
||||
const useFolderSubmit = (setOpen: (a: boolean) => void, folderToEdit: FolderType | null) => {
|
||||
const useFolderSubmit = (
|
||||
setOpen: (a: boolean) => void,
|
||||
folderToEdit: FolderType | null,
|
||||
) => {
|
||||
const setSuccessData = useAlertStore((state) => state.setSuccessData);
|
||||
const setErrorData = useAlertStore((state) => state.setErrorData);
|
||||
const getFoldersApi = useFolderStore((state) => state.getFoldersApi);
|
||||
|
|
|
|||
|
|
@ -4,7 +4,10 @@ import { addFolder, updateFolder } from "../../../pages/MainPage/services";
|
|||
import useAlertStore from "../../../stores/alertStore";
|
||||
import { useFolderStore } from "../../../stores/foldersStore";
|
||||
|
||||
const useFolderSubmit = (setOpen: (a: boolean) => void, folderToEdit: FolderType | null) => {
|
||||
const useFolderSubmit = (
|
||||
setOpen: (a: boolean) => void,
|
||||
folderToEdit: FolderType | null,
|
||||
) => {
|
||||
const setSuccessData = useAlertStore((state) => state.setSuccessData);
|
||||
const setErrorData = useAlertStore((state) => state.setErrorData);
|
||||
const getFoldersApi = useFolderStore((state) => state.getFoldersApi);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue