From ac9b7313a9ba997144455c150879bc42d92d1b2f Mon Sep 17 00:00:00 2001 From: JGerla Date: Wed, 28 Jan 2026 11:20:56 +0100 Subject: [PATCH 1/2] chore: added Copyright strings --- src/App.css | 5 +++ src/App.tsx | 4 ++ src/components/Logging/Filters.module.css | 5 +++ src/components/Logging/Filters.tsx | 3 ++ src/components/Logging/Logging.module.css | 5 +++ src/components/Logging/Logging.tsx | 3 ++ src/components/Logging/useLogs.ts | 3 ++ src/components/MultilineTextField.tsx | 3 ++ src/components/ScrollIntoView.tsx | 3 ++ src/components/TextField.module.css | 5 +++ src/components/TextField.tsx | 3 ++ src/components/components.tsx | 3 ++ src/index.css | 6 +++ src/main.tsx | 3 ++ src/pages/ConnectedRobots/ConnectedRobots.tsx | 3 ++ src/pages/Home/Home.module.css | 5 +++ src/pages/Home/Home.tsx | 3 ++ .../MonitoringPage/MonitoringPage.module.css | 5 +++ src/pages/MonitoringPage/MonitoringPage.tsx | 7 ++- src/pages/MonitoringPage/MonitoringPageAPI.ts | 3 ++ .../MonitoringPageComponents.tsx | 3 ++ src/pages/Robot/Robot.tsx | 3 ++ src/pages/TemplatePage/Template.tsx | 3 ++ src/pages/VisProgPage/VisProg.module.css | 5 +++ src/pages/VisProgPage/VisProg.tsx | 7 ++- src/pages/VisProgPage/VisProgLogic.ts | 5 ++- src/pages/VisProgPage/VisProgLogic.tsx | 43 ------------------- .../visualProgrammingUI/EditorUndoRedo.ts | 3 ++ .../visualProgrammingUI/HandleRuleLogic.ts | 3 ++ .../visualProgrammingUI/HandleRules.ts | 3 ++ .../visualProgrammingUI/NodeRegistry.ts | 3 ++ .../visualProgrammingUI/VisProgStores.tsx | 3 ++ .../visualProgrammingUI/VisProgTypes.tsx | 3 ++ .../components/DragDropSidebar.tsx | 3 ++ .../components/EditorWarnings.tsx | 3 ++ .../components/GestureValueEditor.module.css | 6 ++- .../components/GestureValueEditor.tsx | 3 ++ .../components/NodeComponents.tsx | 3 ++ .../components/Plan.default.ts | 3 ++ .../visualProgrammingUI/components/Plan.tsx | 3 ++ .../components/PlanEditingFunctions.tsx | 3 ++ .../components/PlanEditor.module.css | 5 +++ .../components/PlanEditor.tsx | 3 ++ .../components/RuleBasedHandle.module.css | 5 +++ .../components/RuleBasedHandle.tsx | 3 ++ .../components/SaveLoadPanel.module.css | 5 +++ .../components/SaveLoadPanel.tsx | 3 ++ .../components/WarningSidebar.module.css | 5 +++ .../components/WarningSidebar.tsx | 3 ++ .../nodes/BasicBeliefNode.default.ts | 3 ++ .../nodes/BasicBeliefNode.tsx | 3 ++ .../nodes/BeliefGlobals.ts | 3 ++ .../nodes/EndNode.default.ts | 3 ++ .../visualProgrammingUI/nodes/EndNode.tsx | 3 ++ .../nodes/GoalNode.default.ts | 3 ++ .../visualProgrammingUI/nodes/GoalNode.tsx | 3 ++ .../nodes/InferredBeliefNode.default.ts | 3 ++ .../nodes/InferredBeliefNode.module.css | 5 +++ .../nodes/InferredBeliefNode.tsx | 3 ++ .../nodes/NormNode.default.ts | 3 ++ .../visualProgrammingUI/nodes/NormNode.tsx | 3 ++ .../nodes/PhaseNode.default.ts | 3 ++ .../visualProgrammingUI/nodes/PhaseNode.tsx | 3 ++ .../nodes/StartNode.default.ts | 3 ++ .../visualProgrammingUI/nodes/StartNode.tsx | 3 ++ .../nodes/TriggerNode.default.ts | 3 ++ .../visualProgrammingUI/nodes/TriggerNode.tsx | 3 ++ src/utils/SaveLoad.ts | 3 ++ src/utils/cellStore.ts | 3 ++ src/utils/duplicateIndices.ts | 3 ++ src/utils/formatDuration.ts | 3 ++ src/utils/orderPhaseNodes.ts | 3 ++ src/utils/priorityFiltering.ts | 3 ++ src/utils/programStore.ts | 3 ++ test/components.test.tsx | 3 ++ test/components/Logging/Filters.test.tsx | 3 ++ test/components/Logging/Logging.test.tsx | 3 ++ test/components/Logging/useLogs.test.tsx | 3 ++ test/eslint.config.js.ts | 3 ++ .../connectedRobots/ConnectedRobots.test.tsx | 3 ++ .../monitoringPage/MonitoringPage.test.tsx | 7 ++- .../monitoringPage/MonitoringPageAPI.test.ts | 3 ++ .../MonitoringPageComponents.test.tsx | 3 ++ test/pages/robot/Robot.test.tsx | 3 ++ .../EditorUndoRedo.test.ts | 3 ++ .../visualProgrammingUI/GraphReducer.test.ts | 3 ++ .../HandleRuleLogic.test.ts | 3 ++ .../visualProgrammingUI/HandleRules.test.ts | 3 ++ .../VisProgStores.test.tsx | 3 ++ .../components/DragDropSidebar.test.tsx | 3 ++ .../components/EditorWarnings.test.tsx | 3 ++ .../components/GestureValueEditor.test.tsx | 3 ++ .../components/NodeComponents.test.tsx | 3 ++ .../components/PlanEditor.test.tsx | 3 ++ .../components/SaveLoadPanel.test.tsx | 3 ++ .../components/ScrollIntoView.test.tsx | 3 ++ .../components/WarningSidebar.test.tsx | 3 ++ .../nodes/BeliefGlobals.test.ts | 3 ++ .../nodes/BeliefNode.test.tsx | 3 ++ .../nodes/GoalNode.test.tsx | 3 ++ .../nodes/InferredBeliefNode.test.tsx | 3 ++ .../nodes/NormNode.test.tsx | 3 ++ .../nodes/PhaseNode.test.tsx | 3 ++ .../nodes/StartNode.test.tsx | 3 ++ .../nodes/TriggerNode.test.tsx | 3 ++ .../nodes/UniversalNodes.test.tsx | 3 ++ test/setupFlowTests.ts | 3 ++ test/setupTests.ts | 3 ++ test/test-utils/mocks.ts | 3 ++ test/test-utils/test-utils.tsx | 3 ++ test/utils/cellStore.test.tsx | 3 ++ test/utils/duplicateIndices.test.ts | 3 ++ test/utils/formatDuration.test.ts | 3 ++ test/utils/orderPhaseNodes.test.ts | 3 ++ test/utils/priorityFiltering.test.ts | 3 ++ test/utils/programStore.test.ts | 3 ++ 116 files changed, 382 insertions(+), 51 deletions(-) delete mode 100644 src/pages/VisProgPage/VisProgLogic.tsx diff --git a/src/App.css b/src/App.css index 8e078f6..624192b 100644 --- a/src/App.css +++ b/src/App.css @@ -1,3 +1,8 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} .logopepper { height: 8em; padding: 1.5em; diff --git a/src/App.tsx b/src/App.tsx index e0576a2..2188309 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { Routes, Route, Link } from 'react-router' import './App.css' import TemplatePage from './pages/TemplatePage/Template.tsx' @@ -15,6 +18,7 @@ function App(){ return ( <>
+ © Utrecht University (ICS) Home
diff --git a/src/components/Logging/Filters.module.css b/src/components/Logging/Filters.module.css index 405560c..3353866 100644 --- a/src/components/Logging/Filters.module.css +++ b/src/components/Logging/Filters.module.css @@ -1,3 +1,8 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} .filter-root { position: relative; display: flex; diff --git a/src/components/Logging/Filters.tsx b/src/components/Logging/Filters.tsx index 4b95de6..acf30fc 100644 --- a/src/components/Logging/Filters.tsx +++ b/src/components/Logging/Filters.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {useEffect, useRef, useState} from "react"; import type {LogFilterPredicate} from "./useLogs.ts"; diff --git a/src/components/Logging/Logging.module.css b/src/components/Logging/Logging.module.css index 6fc2988..c3f2ef3 100644 --- a/src/components/Logging/Logging.module.css +++ b/src/components/Logging/Logging.module.css @@ -1,3 +1,8 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} .logging-container { box-sizing: border-box; diff --git a/src/components/Logging/Logging.tsx b/src/components/Logging/Logging.tsx index 8c2101f..2e10081 100644 --- a/src/components/Logging/Logging.tsx +++ b/src/components/Logging/Logging.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {useEffect, useRef, useState} from "react"; import {create} from "zustand"; diff --git a/src/components/Logging/useLogs.ts b/src/components/Logging/useLogs.ts index 752a4ab..21e418d 100644 --- a/src/components/Logging/useLogs.ts +++ b/src/components/Logging/useLogs.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {useCallback, useEffect, useRef, useState} from "react"; import {applyPriorityPredicates, type PriorityFilterPredicate} from "../../utils/priorityFiltering.ts"; diff --git a/src/components/MultilineTextField.tsx b/src/components/MultilineTextField.tsx index ad88513..a2af183 100644 --- a/src/components/MultilineTextField.tsx +++ b/src/components/MultilineTextField.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { useEffect, useRef, useState } from "react"; import styles from "./TextField.module.css"; diff --git a/src/components/ScrollIntoView.tsx b/src/components/ScrollIntoView.tsx index df5148f..7e60677 100644 --- a/src/components/ScrollIntoView.tsx +++ b/src/components/ScrollIntoView.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {useEffect, useRef} from "react"; /** diff --git a/src/components/TextField.module.css b/src/components/TextField.module.css index 308ec43..139a55c 100644 --- a/src/components/TextField.module.css +++ b/src/components/TextField.module.css @@ -1,3 +1,8 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} .text-field { border: 1px solid transparent; border-radius: 5pt; diff --git a/src/components/TextField.tsx b/src/components/TextField.tsx index 6395e18..9d993a9 100644 --- a/src/components/TextField.tsx +++ b/src/components/TextField.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {useEffect, useState} from "react"; import styles from "./TextField.module.css"; diff --git a/src/components/components.tsx b/src/components/components.tsx index 7ee7f0d..1a1c5b7 100644 --- a/src/components/components.tsx +++ b/src/components/components.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { useState } from 'react' /** diff --git a/src/index.css b/src/index.css index 7f56d84..58b1acf 100644 --- a/src/index.css +++ b/src/index.css @@ -1,3 +1,9 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} + :root { font-family: system-ui, Avenir, Helvetica, Arial, sans-serif; line-height: 1.5; diff --git a/src/main.tsx b/src/main.tsx index ae3d161..edf41bd 100644 --- a/src/main.tsx +++ b/src/main.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { StrictMode } from 'react' import { createRoot } from 'react-dom/client' import { BrowserRouter } from 'react-router' diff --git a/src/pages/ConnectedRobots/ConnectedRobots.tsx b/src/pages/ConnectedRobots/ConnectedRobots.tsx index 176f8d5..bddfbd4 100644 --- a/src/pages/ConnectedRobots/ConnectedRobots.tsx +++ b/src/pages/ConnectedRobots/ConnectedRobots.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { useEffect, useState } from 'react' /** diff --git a/src/pages/Home/Home.module.css b/src/pages/Home/Home.module.css index cd880b3..11499aa 100644 --- a/src/pages/Home/Home.module.css +++ b/src/pages/Home/Home.module.css @@ -1,3 +1,8 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} .read_the_docs { color: #888; } diff --git a/src/pages/Home/Home.tsx b/src/pages/Home/Home.tsx index c998e25..605b803 100644 --- a/src/pages/Home/Home.tsx +++ b/src/pages/Home/Home.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { Link } from 'react-router' import pepperLogo from '../../assets/pepper_transp2_small.svg' import styles from './Home.module.css' diff --git a/src/pages/MonitoringPage/MonitoringPage.module.css b/src/pages/MonitoringPage/MonitoringPage.module.css index 183fe4b..84e8a7e 100644 --- a/src/pages/MonitoringPage/MonitoringPage.module.css +++ b/src/pages/MonitoringPage/MonitoringPage.module.css @@ -1,3 +1,8 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} .dashboardContainer { display: grid; grid-template-columns: 2fr 1fr; /* Left = content, Right = logs */ diff --git a/src/pages/MonitoringPage/MonitoringPage.tsx b/src/pages/MonitoringPage/MonitoringPage.tsx index 3b79df9..4d912f5 100644 --- a/src/pages/MonitoringPage/MonitoringPage.tsx +++ b/src/pages/MonitoringPage/MonitoringPage.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import React, { useCallback, useState } from 'react'; import styles from './MonitoringPage.module.css'; @@ -15,7 +18,7 @@ import { type CondNormsStateUpdate, type PhaseUpdate } from "./MonitoringPageAPI"; -import { graphReducer, runProgramm } from '../VisProgPage/VisProgLogic.ts'; +import { graphReducer, runProgram } from '../VisProgPage/VisProgLogic.ts'; // Types import type { NormNodeData } from '../VisProgPage/visualProgrammingUI/nodes/NormNode'; @@ -131,7 +134,7 @@ function useExperimentLogic() { setGoalIndex(0); setIsFinished(false); - await runProgramm(); + await runProgram(); console.log("Experiment & UI successfully reset."); } catch (err) { console.error("Failed to reset program:", err); diff --git a/src/pages/MonitoringPage/MonitoringPageAPI.ts b/src/pages/MonitoringPage/MonitoringPageAPI.ts index c210968..1a9838c 100644 --- a/src/pages/MonitoringPage/MonitoringPageAPI.ts +++ b/src/pages/MonitoringPage/MonitoringPageAPI.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import React, { useEffect } from 'react'; const API_BASE = "http://localhost:8000"; diff --git a/src/pages/MonitoringPage/MonitoringPageComponents.tsx b/src/pages/MonitoringPage/MonitoringPageComponents.tsx index d1d2854..ef4f561 100644 --- a/src/pages/MonitoringPage/MonitoringPageComponents.tsx +++ b/src/pages/MonitoringPage/MonitoringPageComponents.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import React, { useEffect, useState } from 'react'; import styles from './MonitoringPage.module.css'; import { sendAPICall } from './MonitoringPageAPI'; diff --git a/src/pages/Robot/Robot.tsx b/src/pages/Robot/Robot.tsx index 803b2f5..49dc120 100644 --- a/src/pages/Robot/Robot.tsx +++ b/src/pages/Robot/Robot.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { useState, useEffect, useRef } from 'react' /** diff --git a/src/pages/TemplatePage/Template.tsx b/src/pages/TemplatePage/Template.tsx index dc24adf..64d157a 100644 --- a/src/pages/TemplatePage/Template.tsx +++ b/src/pages/TemplatePage/Template.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import Counter from '../../components/components.tsx' function TemplatePage() { diff --git a/src/pages/VisProgPage/VisProg.module.css b/src/pages/VisProgPage/VisProg.module.css index 8a0003c..05a5fc6 100644 --- a/src/pages/VisProgPage/VisProg.module.css +++ b/src/pages/VisProgPage/VisProg.module.css @@ -1,3 +1,8 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} /* editor UI */ .inner-editor-container { diff --git a/src/pages/VisProgPage/VisProg.tsx b/src/pages/VisProgPage/VisProg.tsx index 590f99e..3398d1c 100644 --- a/src/pages/VisProgPage/VisProg.tsx +++ b/src/pages/VisProgPage/VisProg.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { Background, Controls, @@ -20,7 +23,7 @@ import styles from './VisProg.module.css' import {NodeTypes} from './visualProgrammingUI/NodeRegistry.ts'; import SaveLoadPanel from './visualProgrammingUI/components/SaveLoadPanel.tsx'; import MonitoringPage from '../MonitoringPage/MonitoringPage.tsx'; -import { graphReducer, runProgramm } from './VisProgLogic.ts'; +import {graphReducer, runProgram} from './VisProgLogic.ts'; // --| config starting params for flow |-- @@ -218,7 +221,7 @@ function VisProgPage() { const phases = graphReducer(); // reduce graph setProgramState({ phases }); // <-- save to store setShowSimpleProgram(true); // show SimpleProgram - runProgramm(); // send to backend if needed + runProgram(); // send to backend if needed }; if (showSimpleProgram) { diff --git a/src/pages/VisProgPage/VisProgLogic.ts b/src/pages/VisProgPage/VisProgLogic.ts index 69c7f77..696a8a7 100644 --- a/src/pages/VisProgPage/VisProgLogic.ts +++ b/src/pages/VisProgPage/VisProgLogic.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import useProgramStore from "../../utils/programStore"; import orderPhaseNodeArray from "../../utils/orderPhaseNodes"; import useFlowStore from './visualProgrammingUI/VisProgStores'; @@ -20,7 +23,7 @@ export function graphReducer() { /** * Outputs the prepared program to the console and sends it to the backend */ -export function runProgramm() { +export function runProgram() { const phases = graphReducer(); const program = {phases} console.log(JSON.stringify(program, null, 2)); diff --git a/src/pages/VisProgPage/VisProgLogic.tsx b/src/pages/VisProgPage/VisProgLogic.tsx deleted file mode 100644 index 3753a3f..0000000 --- a/src/pages/VisProgPage/VisProgLogic.tsx +++ /dev/null @@ -1,43 +0,0 @@ -import useProgramStore from "../../utils/programStore"; -import orderPhaseNodeArray from "../../utils/orderPhaseNodes"; -import useFlowStore from './visualProgrammingUI/VisProgStores'; -import { NodeReduces } from './visualProgrammingUI/NodeRegistry'; -import type { PhaseNode } from "./visualProgrammingUI/nodes/PhaseNode"; - -/** - * Reduces the graph into its phases' information and recursively calls their reducing function - */ -export function graphReducer() { - const { nodes } = useFlowStore.getState(); - return orderPhaseNodeArray(nodes.filter((n) => n.type == 'phase') as PhaseNode []) - .map((n) => { - const reducer = NodeReduces['phase']; - return reducer(n, nodes) - }); -} - - -/** - * Outputs the prepared program to the console and sends it to the backend - */ -export function runProgram() { - const phases = graphReducer(); - const program = {phases} - console.log(JSON.stringify(program, null, 2)); - fetch( - "http://localhost:8000/program", - { - method: "POST", - headers: {"Content-Type": "application/json"}, - body: JSON.stringify(program), - } - ).then((res) => { - if (!res.ok) throw new Error("Failed communicating with the backend.") - console.log("Successfully sent the program to the backend."); - - // store reduced program in global program store for further use in the UI - // when the program was sent to the backend successfully: - useProgramStore.getState().setProgramState(structuredClone(program)); - }).catch(() => console.log("Failed to send program to the backend.")); - console.log(program); -} \ No newline at end of file diff --git a/src/pages/VisProgPage/visualProgrammingUI/EditorUndoRedo.ts b/src/pages/VisProgPage/visualProgrammingUI/EditorUndoRedo.ts index 4e45148..58c0bf8 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/EditorUndoRedo.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/EditorUndoRedo.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type {Edge, Node} from "@xyflow/react"; import type {StateCreator, StoreApi } from 'zustand/vanilla'; import type { diff --git a/src/pages/VisProgPage/visualProgrammingUI/HandleRuleLogic.ts b/src/pages/VisProgPage/visualProgrammingUI/HandleRuleLogic.ts index e212ed2..b420b1b 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/HandleRuleLogic.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/HandleRuleLogic.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {type Connection} from "@xyflow/react"; import {useEffect} from "react"; import useFlowStore from "./VisProgStores.tsx"; diff --git a/src/pages/VisProgPage/visualProgrammingUI/HandleRules.ts b/src/pages/VisProgPage/visualProgrammingUI/HandleRules.ts index aca415e..1c2301d 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/HandleRules.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/HandleRules.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { type HandleRule, ruleResult diff --git a/src/pages/VisProgPage/visualProgrammingUI/NodeRegistry.ts b/src/pages/VisProgPage/visualProgrammingUI/NodeRegistry.ts index a4285ec..e2ae8a1 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/NodeRegistry.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/NodeRegistry.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import EndNode, { EndConnectionTarget, EndConnectionSource, diff --git a/src/pages/VisProgPage/visualProgrammingUI/VisProgStores.tsx b/src/pages/VisProgPage/visualProgrammingUI/VisProgStores.tsx index 65df21f..1f76b75 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/VisProgStores.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/VisProgStores.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { create } from 'zustand'; import { applyNodeChanges, diff --git a/src/pages/VisProgPage/visualProgrammingUI/VisProgTypes.tsx b/src/pages/VisProgPage/visualProgrammingUI/VisProgTypes.tsx index a34a3e7..d715a1d 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/VisProgTypes.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/VisProgTypes.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) // VisProgTypes.ts import type { Edge, diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/DragDropSidebar.tsx b/src/pages/VisProgPage/visualProgrammingUI/components/DragDropSidebar.tsx index 338039a..53b540b 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/DragDropSidebar.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/components/DragDropSidebar.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { useDraggable } from '@neodrag/react'; import { useReactFlow, type XYPosition } from '@xyflow/react'; import { type ReactNode, useCallback, useRef, useState } from 'react'; diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/EditorWarnings.tsx b/src/pages/VisProgPage/visualProgrammingUI/components/EditorWarnings.tsx index 497aac6..c6d1495 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/EditorWarnings.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/components/EditorWarnings.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) /* contains all logic for the VisProgEditor warning system * * Missing but desirable features: diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/GestureValueEditor.module.css b/src/pages/VisProgPage/visualProgrammingUI/components/GestureValueEditor.module.css index 9d0f3e6..442c862 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/GestureValueEditor.module.css +++ b/src/pages/VisProgPage/visualProgrammingUI/components/GestureValueEditor.module.css @@ -1,4 +1,8 @@ - +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} .gestureEditor { display: flex; flex-direction: column; diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/GestureValueEditor.tsx b/src/pages/VisProgPage/visualProgrammingUI/components/GestureValueEditor.tsx index 3b5863a..19affa5 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/GestureValueEditor.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/components/GestureValueEditor.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { useState, useRef } from "react"; import styles from './GestureValueEditor.module.css' diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/NodeComponents.tsx b/src/pages/VisProgPage/visualProgrammingUI/components/NodeComponents.tsx index 2d9bbd8..669b47f 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/NodeComponents.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/components/NodeComponents.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {NodeToolbar, useReactFlow} from '@xyflow/react'; import '@xyflow/react/dist/style.css'; import {type JSX, useState} from "react"; diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/Plan.default.ts b/src/pages/VisProgPage/visualProgrammingUI/components/Plan.default.ts index 87d7d94..26ea9af 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/Plan.default.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/components/Plan.default.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type { Plan, PlanElement } from "./Plan"; export const defaultPlan: Plan = { diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/Plan.tsx b/src/pages/VisProgPage/visualProgrammingUI/components/Plan.tsx index 3bc2825..255354c 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/Plan.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/components/Plan.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { type Node } from "@xyflow/react" import { GoalReduce } from "../nodes/GoalNode" diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/PlanEditingFunctions.tsx b/src/pages/VisProgPage/visualProgrammingUI/components/PlanEditingFunctions.tsx index 9e7e446..c683881 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/PlanEditingFunctions.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/components/PlanEditingFunctions.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) // This file is to avoid sharing both functions and components which eslint dislikes. :) import type { GoalNode } from "../nodes/GoalNode" import type { Goal, Plan } from "./Plan" diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/PlanEditor.module.css b/src/pages/VisProgPage/visualProgrammingUI/components/PlanEditor.module.css index ed16c78..91e3f98 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/PlanEditor.module.css +++ b/src/pages/VisProgPage/visualProgrammingUI/components/PlanEditor.module.css @@ -1,3 +1,8 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} .planDialog { overflow:visible; width: 80vw; diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/PlanEditor.tsx b/src/pages/VisProgPage/visualProgrammingUI/components/PlanEditor.tsx index 2c2d098..15a4d89 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/PlanEditor.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/components/PlanEditor.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {useRef, useState} from "react"; import useFlowStore from "../VisProgStores.tsx"; import styles from './PlanEditor.module.css'; diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/RuleBasedHandle.module.css b/src/pages/VisProgPage/visualProgrammingUI/components/RuleBasedHandle.module.css index 582ec2d..963e46d 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/RuleBasedHandle.module.css +++ b/src/pages/VisProgPage/visualProgrammingUI/components/RuleBasedHandle.module.css @@ -1,3 +1,8 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} :global(.react-flow__handle.source){ border-radius: 100%; } diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/RuleBasedHandle.tsx b/src/pages/VisProgPage/visualProgrammingUI/components/RuleBasedHandle.tsx index 2026b00..41f15d3 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/RuleBasedHandle.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/components/RuleBasedHandle.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { Handle, type HandleProps, diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/SaveLoadPanel.module.css b/src/pages/VisProgPage/visualProgrammingUI/components/SaveLoadPanel.module.css index 9dbafa2..3b1733b 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/SaveLoadPanel.module.css +++ b/src/pages/VisProgPage/visualProgrammingUI/components/SaveLoadPanel.module.css @@ -1,3 +1,8 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} .save-load-panel { border-radius: 0 0 5pt 5pt; background-color: canvas; diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/SaveLoadPanel.tsx b/src/pages/VisProgPage/visualProgrammingUI/components/SaveLoadPanel.tsx index 8cf4146..2c24c79 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/SaveLoadPanel.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/components/SaveLoadPanel.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {type ChangeEvent, useRef, useState} from "react"; import useFlowStore from "../VisProgStores"; import visProgStyles from "../../VisProg.module.css"; diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/WarningSidebar.module.css b/src/pages/VisProgPage/visualProgrammingUI/components/WarningSidebar.module.css index 82168dc..6134d7a 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/WarningSidebar.module.css +++ b/src/pages/VisProgPage/visualProgrammingUI/components/WarningSidebar.module.css @@ -1,3 +1,8 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} .warnings-sidebar { min-width: auto; max-width: 340px; diff --git a/src/pages/VisProgPage/visualProgrammingUI/components/WarningSidebar.tsx b/src/pages/VisProgPage/visualProgrammingUI/components/WarningSidebar.tsx index 27a4684..56176eb 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/components/WarningSidebar.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/components/WarningSidebar.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {useReactFlow, useStoreApi} from "@xyflow/react"; import clsx from "clsx"; import {useEffect, useState} from "react"; diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/BasicBeliefNode.default.ts b/src/pages/VisProgPage/visualProgrammingUI/nodes/BasicBeliefNode.default.ts index 01f1cfa..65c3e2b 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/BasicBeliefNode.default.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/BasicBeliefNode.default.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type { BasicBeliefNodeData } from "./BasicBeliefNode.tsx"; diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/BasicBeliefNode.tsx b/src/pages/VisProgPage/visualProgrammingUI/nodes/BasicBeliefNode.tsx index 4495745..1426e89 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/BasicBeliefNode.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/BasicBeliefNode.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { type NodeProps, Position, diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/BeliefGlobals.ts b/src/pages/VisProgPage/visualProgrammingUI/nodes/BeliefGlobals.ts index b92c5b2..8253889 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/BeliefGlobals.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/BeliefGlobals.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {getOutgoers, type Node} from '@xyflow/react'; import {type HandleRule, type RuleResult, ruleResult} from "../HandleRuleLogic.ts"; import useFlowStore from "../VisProgStores.tsx"; diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/EndNode.default.ts b/src/pages/VisProgPage/visualProgrammingUI/nodes/EndNode.default.ts index 3fb5e43..23d2b0f 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/EndNode.default.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/EndNode.default.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type { EndNodeData } from "./EndNode"; /** diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/EndNode.tsx b/src/pages/VisProgPage/visualProgrammingUI/nodes/EndNode.tsx index 3bbfa14..9426ed8 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/EndNode.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/EndNode.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { type NodeProps, Position, diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/GoalNode.default.ts b/src/pages/VisProgPage/visualProgrammingUI/nodes/GoalNode.default.ts index 76dc3d1..ce3a403 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/GoalNode.default.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/GoalNode.default.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type { GoalNodeData } from "./GoalNode"; /** diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/GoalNode.tsx b/src/pages/VisProgPage/visualProgrammingUI/nodes/GoalNode.tsx index 1974e99..a225299 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/GoalNode.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/GoalNode.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { type NodeProps, Position, diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/InferredBeliefNode.default.ts b/src/pages/VisProgPage/visualProgrammingUI/nodes/InferredBeliefNode.default.ts index 976ee16..26c3a47 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/InferredBeliefNode.default.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/InferredBeliefNode.default.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type { InferredBeliefNodeData } from "./InferredBeliefNode.tsx"; diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/InferredBeliefNode.module.css b/src/pages/VisProgPage/visualProgrammingUI/nodes/InferredBeliefNode.module.css index 2f9b7ae..d6186ed 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/InferredBeliefNode.module.css +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/InferredBeliefNode.module.css @@ -1,3 +1,8 @@ +{/* +This program has been developed by students from the bachelor Computer Science at Utrecht +University within the Software Project course. +© Copyright Utrecht University (Department of Information and Computing Sciences) +*/} .operator-switch { display: inline-flex; align-items: center; diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/InferredBeliefNode.tsx b/src/pages/VisProgPage/visualProgrammingUI/nodes/InferredBeliefNode.tsx index 924517b..d8c01c0 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/InferredBeliefNode.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/InferredBeliefNode.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {getConnectedEdges, type Node, type NodeProps, Position, useNodeConnections} from '@xyflow/react'; import {useEffect, useState} from "react"; import styles from '../../VisProg.module.css'; diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/NormNode.default.ts b/src/pages/VisProgPage/visualProgrammingUI/nodes/NormNode.default.ts index 185d232..dce1154 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/NormNode.default.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/NormNode.default.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type { NormNodeData } from "./NormNode"; /** diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/NormNode.tsx b/src/pages/VisProgPage/visualProgrammingUI/nodes/NormNode.tsx index 29a03df..1b4d200 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/NormNode.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/NormNode.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { type NodeProps, Position, diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/PhaseNode.default.ts b/src/pages/VisProgPage/visualProgrammingUI/nodes/PhaseNode.default.ts index 73697eb..b854179 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/PhaseNode.default.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/PhaseNode.default.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type { PhaseNodeData } from "./PhaseNode"; /** diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/PhaseNode.tsx b/src/pages/VisProgPage/visualProgrammingUI/nodes/PhaseNode.tsx index e5f2b9b..3fbde48 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/PhaseNode.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/PhaseNode.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { type NodeProps, Position, diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/StartNode.default.ts b/src/pages/VisProgPage/visualProgrammingUI/nodes/StartNode.default.ts index 0837e03..3812f64 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/StartNode.default.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/StartNode.default.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type { StartNodeData } from "./StartNode"; /** diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/StartNode.tsx b/src/pages/VisProgPage/visualProgrammingUI/nodes/StartNode.tsx index 925d1dd..1355dee 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/StartNode.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/StartNode.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { type NodeProps, Position, diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/TriggerNode.default.ts b/src/pages/VisProgPage/visualProgrammingUI/nodes/TriggerNode.default.ts index 9c1b92f..2da7d8b 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/TriggerNode.default.ts +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/TriggerNode.default.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type { TriggerNodeData } from "./TriggerNode"; /** diff --git a/src/pages/VisProgPage/visualProgrammingUI/nodes/TriggerNode.tsx b/src/pages/VisProgPage/visualProgrammingUI/nodes/TriggerNode.tsx index caa8c58..2bd3ebd 100644 --- a/src/pages/VisProgPage/visualProgrammingUI/nodes/TriggerNode.tsx +++ b/src/pages/VisProgPage/visualProgrammingUI/nodes/TriggerNode.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { type NodeProps, Position, diff --git a/src/utils/SaveLoad.ts b/src/utils/SaveLoad.ts index 4ea9666..2672ad4 100644 --- a/src/utils/SaveLoad.ts +++ b/src/utils/SaveLoad.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {type Edge, type Node } from "@xyflow/react"; export type SavedProject = { diff --git a/src/utils/cellStore.ts b/src/utils/cellStore.ts index 9c14695..8839351 100644 --- a/src/utils/cellStore.ts +++ b/src/utils/cellStore.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {useSyncExternalStore} from "react"; type Unsub = () => void; diff --git a/src/utils/duplicateIndices.ts b/src/utils/duplicateIndices.ts index 08a4d43..fee06a5 100644 --- a/src/utils/duplicateIndices.ts +++ b/src/utils/duplicateIndices.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) /** * Find the indices of all elements that occur more than once. * diff --git a/src/utils/formatDuration.ts b/src/utils/formatDuration.ts index 2e9f88d..d731a5e 100644 --- a/src/utils/formatDuration.ts +++ b/src/utils/formatDuration.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) /** * Format a time duration like `HH:MM:SS.mmm`. * diff --git a/src/utils/orderPhaseNodes.ts b/src/utils/orderPhaseNodes.ts index 00b7a26..c9d6de5 100644 --- a/src/utils/orderPhaseNodes.ts +++ b/src/utils/orderPhaseNodes.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type {PhaseNode} from "../pages/VisProgPage/visualProgrammingUI/nodes/PhaseNode.tsx"; /** diff --git a/src/utils/priorityFiltering.ts b/src/utils/priorityFiltering.ts index 7638f34..8336956 100644 --- a/src/utils/priorityFiltering.ts +++ b/src/utils/priorityFiltering.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) export type PriorityFilterPredicate = { priority: number; predicate: (element: T) => boolean | null; // The predicate and its priority are ignored if it returns null. diff --git a/src/utils/programStore.ts b/src/utils/programStore.ts index 4e12bb3..0c79e59 100644 --- a/src/utils/programStore.ts +++ b/src/utils/programStore.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {create} from "zustand"; // the type of a reduced program diff --git a/test/components.test.tsx b/test/components.test.tsx index c1a39bb..c138ddb 100644 --- a/test/components.test.tsx +++ b/test/components.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import userEvent from '@testing-library/user-event'; import { render, screen} from '@testing-library/react'; import Counter from '../src/components/components'; diff --git a/test/components/Logging/Filters.test.tsx b/test/components/Logging/Filters.test.tsx index 9d5e40b..9ba4417 100644 --- a/test/components/Logging/Filters.test.tsx +++ b/test/components/Logging/Filters.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {render, screen, waitFor, fireEvent} from "@testing-library/react"; import userEvent from "@testing-library/user-event"; import * as React from "react"; diff --git a/test/components/Logging/Logging.test.tsx b/test/components/Logging/Logging.test.tsx index a3b6d09..39a5b5f 100644 --- a/test/components/Logging/Logging.test.tsx +++ b/test/components/Logging/Logging.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {render, screen, fireEvent, act, waitFor} from "@testing-library/react"; import userEvent from "@testing-library/user-event"; import "@testing-library/jest-dom"; diff --git a/test/components/Logging/useLogs.test.tsx b/test/components/Logging/useLogs.test.tsx index 30a7c2d..d2272b8 100644 --- a/test/components/Logging/useLogs.test.tsx +++ b/test/components/Logging/useLogs.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { render, screen, act } from "@testing-library/react"; import "@testing-library/jest-dom"; import {type LogRecord, useLogs} from "../../../src/components/Logging/useLogs.ts"; diff --git a/test/eslint.config.js.ts b/test/eslint.config.js.ts index e69de29..8bae862 100644 --- a/test/eslint.config.js.ts +++ b/test/eslint.config.js.ts @@ -0,0 +1,3 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) \ No newline at end of file diff --git a/test/pages/connectedRobots/ConnectedRobots.test.tsx b/test/pages/connectedRobots/ConnectedRobots.test.tsx index 017b2a2..e5b1fc3 100644 --- a/test/pages/connectedRobots/ConnectedRobots.test.tsx +++ b/test/pages/connectedRobots/ConnectedRobots.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { render, screen, act, cleanup, waitFor } from '@testing-library/react'; import ConnectedRobots from '../../../src/pages/ConnectedRobots/ConnectedRobots'; diff --git a/test/pages/monitoringPage/MonitoringPage.test.tsx b/test/pages/monitoringPage/MonitoringPage.test.tsx index 482372a..0d5aa64 100644 --- a/test/pages/monitoringPage/MonitoringPage.test.tsx +++ b/test/pages/monitoringPage/MonitoringPage.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { render, screen, fireEvent, act } from '@testing-library/react'; import '@testing-library/jest-dom'; import MonitoringPage from '../../../src/pages/MonitoringPage/MonitoringPage'; @@ -160,12 +163,12 @@ describe('MonitoringPage', () => { expect(VisProg.graphReducer).toHaveBeenCalled(); expect(mockSetProgramState).toHaveBeenCalledWith({ phases: [{ id: 'new-phase' }] }); - expect(VisProg.runProgramm).toHaveBeenCalled(); + expect(VisProg.runProgram).toHaveBeenCalled(); }); test('Reset Experiment handles errors gracefully', async () => { const consoleSpy = jest.spyOn(console, 'error').mockImplementation(() => {}); - (VisProg.runProgramm as jest.Mock).mockRejectedValue(new Error('Fail')); + (VisProg.runProgram as jest.Mock).mockRejectedValue(new Error('Fail')); render(); await act(async () => { diff --git a/test/pages/monitoringPage/MonitoringPageAPI.test.ts b/test/pages/monitoringPage/MonitoringPageAPI.test.ts index 01a21b7..19afbdc 100644 --- a/test/pages/monitoringPage/MonitoringPageAPI.test.ts +++ b/test/pages/monitoringPage/MonitoringPageAPI.test.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { renderHook, act, cleanup } from '@testing-library/react'; import { sendAPICall, diff --git a/test/pages/monitoringPage/MonitoringPageComponents.test.tsx b/test/pages/monitoringPage/MonitoringPageComponents.test.tsx index f454fe1..992e3bd 100644 --- a/test/pages/monitoringPage/MonitoringPageComponents.test.tsx +++ b/test/pages/monitoringPage/MonitoringPageComponents.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import React from 'react'; import { render, screen, fireEvent, act } from '@testing-library/react'; import '@testing-library/jest-dom'; diff --git a/test/pages/robot/Robot.test.tsx b/test/pages/robot/Robot.test.tsx index bcebac8..2e872c7 100644 --- a/test/pages/robot/Robot.test.tsx +++ b/test/pages/robot/Robot.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { render, screen, act, cleanup, fireEvent } from '@testing-library/react'; import Robot from '../../../src/pages/Robot/Robot'; diff --git a/test/pages/visProgPage/visualProgrammingUI/EditorUndoRedo.test.ts b/test/pages/visProgPage/visualProgrammingUI/EditorUndoRedo.test.ts index 39b459d..fc203d1 100644 --- a/test/pages/visProgPage/visualProgrammingUI/EditorUndoRedo.test.ts +++ b/test/pages/visProgPage/visualProgrammingUI/EditorUndoRedo.test.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {act} from '@testing-library/react'; import useFlowStore from '../../../../src/pages/VisProgPage/visualProgrammingUI/VisProgStores.tsx'; import { mockReactFlow } from '../../../setupFlowTests.ts'; diff --git a/test/pages/visProgPage/visualProgrammingUI/GraphReducer.test.ts b/test/pages/visProgPage/visualProgrammingUI/GraphReducer.test.ts index 192a7cf..034c8b3 100644 --- a/test/pages/visProgPage/visualProgrammingUI/GraphReducer.test.ts +++ b/test/pages/visProgPage/visualProgrammingUI/GraphReducer.test.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) describe('not yet implemented', () => { test('nothing yet', () => { expect(true); diff --git a/test/pages/visProgPage/visualProgrammingUI/HandleRuleLogic.test.ts b/test/pages/visProgPage/visualProgrammingUI/HandleRuleLogic.test.ts index fbeddb1..16f1a56 100644 --- a/test/pages/visProgPage/visualProgrammingUI/HandleRuleLogic.test.ts +++ b/test/pages/visProgPage/visualProgrammingUI/HandleRuleLogic.test.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {renderHook} from "@testing-library/react"; import type {Connection} from "@xyflow/react"; import { diff --git a/test/pages/visProgPage/visualProgrammingUI/HandleRules.test.ts b/test/pages/visProgPage/visualProgrammingUI/HandleRules.test.ts index 65abe19..78496a6 100644 --- a/test/pages/visProgPage/visualProgrammingUI/HandleRules.test.ts +++ b/test/pages/visProgPage/visualProgrammingUI/HandleRules.test.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {ruleResult} from "../../../../src/pages/VisProgPage/visualProgrammingUI/HandleRuleLogic.ts"; import { allowOnlyConnectionsFromType, diff --git a/test/pages/visProgPage/visualProgrammingUI/VisProgStores.test.tsx b/test/pages/visProgPage/visualProgrammingUI/VisProgStores.test.tsx index d53d1bc..1467076 100644 --- a/test/pages/visProgPage/visualProgrammingUI/VisProgStores.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/VisProgStores.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {act} from '@testing-library/react'; import { type Connection, diff --git a/test/pages/visProgPage/visualProgrammingUI/components/DragDropSidebar.test.tsx b/test/pages/visProgPage/visualProgrammingUI/components/DragDropSidebar.test.tsx index 559ed68..7697c0e 100644 --- a/test/pages/visProgPage/visualProgrammingUI/components/DragDropSidebar.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/components/DragDropSidebar.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { getByTestId, render } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import useFlowStore from '../../../../../src/pages/VisProgPage/visualProgrammingUI/VisProgStores'; diff --git a/test/pages/visProgPage/visualProgrammingUI/components/EditorWarnings.test.tsx b/test/pages/visProgPage/visualProgrammingUI/components/EditorWarnings.test.tsx index 8351c8d..defddc4 100644 --- a/test/pages/visProgPage/visualProgrammingUI/components/EditorWarnings.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/components/EditorWarnings.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { describe, it, expect} from '@jest/globals'; import { type EditorWarning, warningSummary diff --git a/test/pages/visProgPage/visualProgrammingUI/components/GestureValueEditor.test.tsx b/test/pages/visProgPage/visualProgrammingUI/components/GestureValueEditor.test.tsx index 3bbc205..a171bdd 100644 --- a/test/pages/visProgPage/visualProgrammingUI/components/GestureValueEditor.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/components/GestureValueEditor.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { useState } from 'react'; import userEvent from '@testing-library/user-event'; import { renderWithProviders, screen } from '../../../../test-utils/test-utils.tsx'; diff --git a/test/pages/visProgPage/visualProgrammingUI/components/NodeComponents.test.tsx b/test/pages/visProgPage/visualProgrammingUI/components/NodeComponents.test.tsx index f7f56ed..c28e0e3 100644 --- a/test/pages/visProgPage/visualProgrammingUI/components/NodeComponents.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/components/NodeComponents.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { fireEvent, screen } from '@testing-library/react'; import '@testing-library/jest-dom'; import {Tooltip} from "../../../../../src/pages/VisProgPage/visualProgrammingUI/components/NodeComponents.tsx"; diff --git a/test/pages/visProgPage/visualProgrammingUI/components/PlanEditor.test.tsx b/test/pages/visProgPage/visualProgrammingUI/components/PlanEditor.test.tsx index 671a115..0dac0e2 100644 --- a/test/pages/visProgPage/visualProgrammingUI/components/PlanEditor.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/components/PlanEditor.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { describe, it, beforeEach, jest } from '@jest/globals'; import { screen, within } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; diff --git a/test/pages/visProgPage/visualProgrammingUI/components/SaveLoadPanel.test.tsx b/test/pages/visProgPage/visualProgrammingUI/components/SaveLoadPanel.test.tsx index 65458c9..14b3e61 100644 --- a/test/pages/visProgPage/visualProgrammingUI/components/SaveLoadPanel.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/components/SaveLoadPanel.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) // SaveLoadPanel.all.test.tsx import { act, fireEvent, render, screen, waitFor } from '@testing-library/react'; import useFlowStore from '../../../../../src/pages/VisProgPage/visualProgrammingUI/VisProgStores.tsx'; diff --git a/test/pages/visProgPage/visualProgrammingUI/components/ScrollIntoView.test.tsx b/test/pages/visProgPage/visualProgrammingUI/components/ScrollIntoView.test.tsx index 2a91e85..2182c68 100644 --- a/test/pages/visProgPage/visualProgrammingUI/components/ScrollIntoView.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/components/ScrollIntoView.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { render } from '@testing-library/react'; import { act } from '@testing-library/react'; import ScrollIntoView from '../../../../../src/components/ScrollIntoView'; diff --git a/test/pages/visProgPage/visualProgrammingUI/components/WarningSidebar.test.tsx b/test/pages/visProgPage/visualProgrammingUI/components/WarningSidebar.test.tsx index 9ccf735..d9a5da0 100644 --- a/test/pages/visProgPage/visualProgrammingUI/components/WarningSidebar.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/components/WarningSidebar.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {fireEvent, render, screen} from '@testing-library/react'; import '@testing-library/jest-dom'; import {useReactFlow, useStoreApi} from "@xyflow/react"; diff --git a/test/pages/visProgPage/visualProgrammingUI/nodes/BeliefGlobals.test.ts b/test/pages/visProgPage/visualProgrammingUI/nodes/BeliefGlobals.test.ts index 54cfa7f..263ed4c 100644 --- a/test/pages/visProgPage/visualProgrammingUI/nodes/BeliefGlobals.test.ts +++ b/test/pages/visProgPage/visualProgrammingUI/nodes/BeliefGlobals.test.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { describe, it, expect, jest, beforeEach } from '@jest/globals'; import {type Connection, getOutgoers, type Node} from '@xyflow/react'; import {ruleResult} from "../../../../../src/pages/VisProgPage/visualProgrammingUI/HandleRuleLogic.ts"; diff --git a/test/pages/visProgPage/visualProgrammingUI/nodes/BeliefNode.test.tsx b/test/pages/visProgPage/visualProgrammingUI/nodes/BeliefNode.test.tsx index 67d80c6..b5592ea 100644 --- a/test/pages/visProgPage/visualProgrammingUI/nodes/BeliefNode.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/nodes/BeliefNode.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) // BasicBeliefNode.test.tsx import { describe, it, beforeEach } from '@jest/globals'; import { screen, waitFor } from '@testing-library/react'; diff --git a/test/pages/visProgPage/visualProgrammingUI/nodes/GoalNode.test.tsx b/test/pages/visProgPage/visualProgrammingUI/nodes/GoalNode.test.tsx index 96f7fd9..ad75aff 100644 --- a/test/pages/visProgPage/visualProgrammingUI/nodes/GoalNode.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/nodes/GoalNode.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { describe, it, beforeEach } from '@jest/globals'; import { screen, waitFor } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; diff --git a/test/pages/visProgPage/visualProgrammingUI/nodes/InferredBeliefNode.test.tsx b/test/pages/visProgPage/visualProgrammingUI/nodes/InferredBeliefNode.test.tsx index d683b23..caeb19d 100644 --- a/test/pages/visProgPage/visualProgrammingUI/nodes/InferredBeliefNode.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/nodes/InferredBeliefNode.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { describe, it, expect, jest, beforeEach } from '@jest/globals'; import type {Node, Edge} from '@xyflow/react'; import * as FlowStore from '../../../../../src/pages/VisProgPage/visualProgrammingUI/VisProgStores.tsx'; diff --git a/test/pages/visProgPage/visualProgrammingUI/nodes/NormNode.test.tsx b/test/pages/visProgPage/visualProgrammingUI/nodes/NormNode.test.tsx index 49e5e74..935ea55 100644 --- a/test/pages/visProgPage/visualProgrammingUI/nodes/NormNode.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/nodes/NormNode.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { describe, it, beforeEach } from '@jest/globals'; import { screen, waitFor } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; diff --git a/test/pages/visProgPage/visualProgrammingUI/nodes/PhaseNode.test.tsx b/test/pages/visProgPage/visualProgrammingUI/nodes/PhaseNode.test.tsx index 327bd8c..b34be4c 100644 --- a/test/pages/visProgPage/visualProgrammingUI/nodes/PhaseNode.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/nodes/PhaseNode.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type { Node, Edge, Connection } from '@xyflow/react' import useFlowStore from '../../../../../src/pages/VisProgPage/visualProgrammingUI/VisProgStores'; import type {PhaseNode, PhaseNodeData} from "../../../../../src/pages/VisProgPage/visualProgrammingUI/nodes/PhaseNode"; diff --git a/test/pages/visProgPage/visualProgrammingUI/nodes/StartNode.test.tsx b/test/pages/visProgPage/visualProgrammingUI/nodes/StartNode.test.tsx index f1d468d..d405b35 100644 --- a/test/pages/visProgPage/visualProgrammingUI/nodes/StartNode.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/nodes/StartNode.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { describe, it } from '@jest/globals'; import '@testing-library/jest-dom'; import { screen } from '@testing-library/react'; diff --git a/test/pages/visProgPage/visualProgrammingUI/nodes/TriggerNode.test.tsx b/test/pages/visProgPage/visualProgrammingUI/nodes/TriggerNode.test.tsx index 43530a2..a152f93 100644 --- a/test/pages/visProgPage/visualProgrammingUI/nodes/TriggerNode.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/nodes/TriggerNode.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { describe, it, beforeEach } from '@jest/globals'; import { screen } from '@testing-library/react'; import { renderWithProviders } from '../../../../test-utils/test-utils.tsx'; diff --git a/test/pages/visProgPage/visualProgrammingUI/nodes/UniversalNodes.test.tsx b/test/pages/visProgPage/visualProgrammingUI/nodes/UniversalNodes.test.tsx index 1aee53a..f07efe1 100644 --- a/test/pages/visProgPage/visualProgrammingUI/nodes/UniversalNodes.test.tsx +++ b/test/pages/visProgPage/visualProgrammingUI/nodes/UniversalNodes.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { describe, beforeEach } from '@jest/globals'; import { screen } from '@testing-library/react'; import { renderWithProviders } from '../../../../test-utils/test-utils.tsx'; diff --git a/test/setupFlowTests.ts b/test/setupFlowTests.ts index caeda94..bcf13e6 100644 --- a/test/setupFlowTests.ts +++ b/test/setupFlowTests.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import '@testing-library/jest-dom'; import { cleanup } from '@testing-library/react'; import { diff --git a/test/setupTests.ts b/test/setupTests.ts index 748f491..83a13ce 100644 --- a/test/setupTests.ts +++ b/test/setupTests.ts @@ -1,2 +1,5 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) // Adds jest-dom matchers for React testing library import '@testing-library/jest-dom'; \ No newline at end of file diff --git a/test/test-utils/mocks.ts b/test/test-utils/mocks.ts index 21971c1..8f5f0b8 100644 --- a/test/test-utils/mocks.ts +++ b/test/test-utils/mocks.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import { jest } from '@jest/globals'; import React from 'react'; import '@testing-library/jest-dom'; diff --git a/test/test-utils/test-utils.tsx b/test/test-utils/test-utils.tsx index 157ea19..1f51702 100644 --- a/test/test-utils/test-utils.tsx +++ b/test/test-utils/test-utils.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) // __tests__/utils/test-utils.tsx import { render, type RenderOptions } from '@testing-library/react'; import { type ReactElement, type ReactNode } from 'react'; diff --git a/test/utils/cellStore.test.tsx b/test/utils/cellStore.test.tsx index 96460b8..ec28c59 100644 --- a/test/utils/cellStore.test.tsx +++ b/test/utils/cellStore.test.tsx @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {render, screen, act} from "@testing-library/react"; import "@testing-library/jest-dom"; import {type Cell, cell, useCell} from "../../src/utils/cellStore.ts"; diff --git a/test/utils/duplicateIndices.test.ts b/test/utils/duplicateIndices.test.ts index 25dce1a..6fbc703 100644 --- a/test/utils/duplicateIndices.test.ts +++ b/test/utils/duplicateIndices.test.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import duplicateIndices from "../../src/utils/duplicateIndices.ts"; describe("duplicateIndices (unit)", () => { diff --git a/test/utils/formatDuration.test.ts b/test/utils/formatDuration.test.ts index b686a43..7a59b61 100644 --- a/test/utils/formatDuration.test.ts +++ b/test/utils/formatDuration.test.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import formatDuration from "../../src/utils/formatDuration.ts"; describe("formatting durations (unit)", () => { diff --git a/test/utils/orderPhaseNodes.test.ts b/test/utils/orderPhaseNodes.test.ts index 5020378..cff6edc 100644 --- a/test/utils/orderPhaseNodes.test.ts +++ b/test/utils/orderPhaseNodes.test.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import type {PhaseNode} from "../../src/pages/VisProgPage/visualProgrammingUI/nodes/PhaseNode.tsx"; import orderPhaseNodeArray from "../../src/utils/orderPhaseNodes.ts"; diff --git a/test/utils/priorityFiltering.test.ts b/test/utils/priorityFiltering.test.ts index 6cc8789..a553243 100644 --- a/test/utils/priorityFiltering.test.ts +++ b/test/utils/priorityFiltering.test.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import {applyPriorityPredicates, type PriorityFilterPredicate} from "../../src/utils/priorityFiltering"; const makePred = (priority: number, fn: (el: T) => boolean | null): PriorityFilterPredicate => ({ diff --git a/test/utils/programStore.test.ts b/test/utils/programStore.test.ts index 9865668..e78a98c 100644 --- a/test/utils/programStore.test.ts +++ b/test/utils/programStore.test.ts @@ -1,3 +1,6 @@ +// This program has been developed by students from the bachelor Computer Science at Utrecht +// University within the Software Project course. +// © Copyright Utrecht University (Department of Information and Computing Sciences) import useProgramStore, {type ReducedProgram} from "../../src/utils/programStore.ts"; -- 2.49.1 From aeddd93b2dd99f82cffbfc246900cf138e6454cf Mon Sep 17 00:00:00 2001 From: JGerla Date: Wed, 28 Jan 2026 11:27:24 +0100 Subject: [PATCH 2/2] chore: removed unused template page and fixed tests to work after the removal of a duplicate file --- src/App.tsx | 2 - src/pages/Home/Home.tsx | 1 - src/pages/TemplatePage/Template.tsx | 14 ---- .../monitoringPage/MonitoringPage.test.tsx | 2 +- test/pages/simpleProgram/SimpleProgram.tsx | 83 ------------------- 5 files changed, 1 insertion(+), 101 deletions(-) delete mode 100644 src/pages/TemplatePage/Template.tsx delete mode 100644 test/pages/simpleProgram/SimpleProgram.tsx diff --git a/src/App.tsx b/src/App.tsx index 2188309..25c9468 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -3,7 +3,6 @@ // © Copyright Utrecht University (Department of Information and Computing Sciences) import { Routes, Route, Link } from 'react-router' import './App.css' -import TemplatePage from './pages/TemplatePage/Template.tsx' import Home from './pages/Home/Home.tsx' import Robot from './pages/Robot/Robot.tsx'; import ConnectedRobots from './pages/ConnectedRobots/ConnectedRobots.tsx' @@ -26,7 +25,6 @@ function App(){
} /> - } /> } /> } /> } /> diff --git a/src/pages/Home/Home.tsx b/src/pages/Home/Home.tsx index 605b803..b2ccb5c 100644 --- a/src/pages/Home/Home.tsx +++ b/src/pages/Home/Home.tsx @@ -24,7 +24,6 @@ function Home() {
Robot Interaction → Editor → - Template → Connected Robots →
diff --git a/src/pages/TemplatePage/Template.tsx b/src/pages/TemplatePage/Template.tsx deleted file mode 100644 index 64d157a..0000000 --- a/src/pages/TemplatePage/Template.tsx +++ /dev/null @@ -1,14 +0,0 @@ -// This program has been developed by students from the bachelor Computer Science at Utrecht -// University within the Software Project course. -// © Copyright Utrecht University (Department of Information and Computing Sciences) -import Counter from '../../components/components.tsx' - -function TemplatePage() { - return ( - <> - - - ) -} - -export default TemplatePage \ No newline at end of file diff --git a/test/pages/monitoringPage/MonitoringPage.test.tsx b/test/pages/monitoringPage/MonitoringPage.test.tsx index 0d5aa64..87f1f30 100644 --- a/test/pages/monitoringPage/MonitoringPage.test.tsx +++ b/test/pages/monitoringPage/MonitoringPage.test.tsx @@ -30,7 +30,7 @@ jest.mock('../../../src/pages/MonitoringPage/MonitoringPageAPI', () => ({ // Mock VisProg functionality jest.mock('../../../src/pages/VisProgPage/VisProgLogic', () => ({ graphReducer: jest.fn(), - runProgramm: jest.fn(), + runProgram: jest.fn(), })); // Mock Child Components to reduce noise (optional, but keeps unit test focused) diff --git a/test/pages/simpleProgram/SimpleProgram.tsx b/test/pages/simpleProgram/SimpleProgram.tsx deleted file mode 100644 index 22fcbbf..0000000 --- a/test/pages/simpleProgram/SimpleProgram.tsx +++ /dev/null @@ -1,83 +0,0 @@ -import { render, screen, fireEvent } from "@testing-library/react"; -import SimpleProgram from "../../../src/pages/SimpleProgram/SimpleProgram"; -import useProgramStore from "../../../src/utils/programStore"; - -/** - * Helper to preload the program store before rendering. - */ -function loadProgram(phases: Record[]) { - useProgramStore.getState().setProgramState({ phases }); -} - -describe("SimpleProgram", () => { - beforeEach(() => { - loadProgram([]); - }); - - test("shows empty state when no program is loaded", () => { - render(); - expect(screen.getByText("No program loaded.")).toBeInTheDocument(); - }); - - test("renders first phase content", () => { - loadProgram([ - { - id: "phase-1", - norms: [{ id: "n1", norm: "Be polite" }], - goals: [{ id: "g1", description: "Finish task", achieved: true }], - triggers: [{ id: "t1", label: "Keyword trigger" }], - }, - ]); - - render(); - - expect(screen.getByText("Phase 1 / 1")).toBeInTheDocument(); - expect(screen.getByText("Be polite")).toBeInTheDocument(); - expect(screen.getByText("Finish task")).toBeInTheDocument(); - expect(screen.getByText("Keyword trigger")).toBeInTheDocument(); - }); - - test("allows navigating between phases", () => { - loadProgram([ - { - id: "phase-1", - norms: [], - goals: [], - triggers: [], - }, - { - id: "phase-2", - norms: [{ id: "n2", norm: "Be careful" }], - goals: [], - triggers: [], - }, - ]); - - render(); - - expect(screen.getByText("Phase 1 / 2")).toBeInTheDocument(); - - fireEvent.click(screen.getByText("Next ▶")); - - expect(screen.getByText("Phase 2 / 2")).toBeInTheDocument(); - expect(screen.getByText("Be careful")).toBeInTheDocument(); - }); - - test("prev button is disabled on first phase", () => { - loadProgram([ - { id: "phase-1", norms: [], goals: [], triggers: [] }, - ]); - - render(); - expect(screen.getByText("◀ Prev")).toBeDisabled(); - }); - - test("next button is disabled on last phase", () => { - loadProgram([ - { id: "phase-1", norms: [], goals: [], triggers: [] }, - ]); - - render(); - expect(screen.getByText("Next ▶")).toBeDisabled(); - }); -}); -- 2.49.1