Skip to content

Commit

Permalink
Windows installer config + Redesign
Browse files Browse the repository at this point in the history
  • Loading branch information
aarkue committed Mar 17, 2024
1 parent 43abcaf commit bc381e4
Show file tree
Hide file tree
Showing 14 changed files with 598 additions and 614 deletions.
2 changes: 2 additions & 0 deletions backend/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 0 additions & 3 deletions backend/shared/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ pub mod preprocessing {
pub mod tests;
}



#[derive(Debug, Serialize, Deserialize)]
pub struct OCELInfo {
pub num_objects: usize,
Expand All @@ -32,4 +30,3 @@ impl From<&OCEL> for OCELInfo {
}
}
}

5 changes: 2 additions & 3 deletions backend/web-server/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,8 @@ use itertools::Itertools;
use ocedeclare_shared::{
constraints::{check_with_tree, CheckWithTreeRequest, ViolationsWithoutID},
discovery::{
auto_discover_constraints_with_options, auto_discover_count_constraints,
auto_discover_eventually_follows, auto_discover_or_constraints, get_obj_types_per_ev_type,
AutoDiscoverConstraintsRequest, AutoDiscoverConstraintsResponse,
auto_discover_constraints_with_options, AutoDiscoverConstraintsRequest,
AutoDiscoverConstraintsResponse,
},
ocel_qualifiers::qualifiers::{
get_qualifiers_for_event_types, QualifierAndObjectType, QualifiersForEventType,
Expand Down
Binary file added frontend/public/favicon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 0 additions & 1 deletion frontend/public/vite.svg

This file was deleted.

30 changes: 8 additions & 22 deletions frontend/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -70,24 +70,19 @@ function App() {
<OcelInfoContext.Provider value={ocelInfo}>
<div className="max-w-full overflow-hidden h-screen text-center grid grid-cols-[15rem_auto]">
<div className="bg-gray-50 border-r border-r-slate-200 px-2">
<div className="flex justify-center py-2 px-2">
<h1 className="text-pink-500 opacity-90 py-1 text-2xl font-black">
OCED
</h1>
<h1 className="text-blue-500 opacity-90 py-1 text-2xl font-black -ml-[0.5ch]">
DECLARE
</h1>
</div>
<img src="/favicon.png" className="w-[7rem] h-[7rem] mx-auto my-4"/>
<div className="flex flex-col gap-2">
{ocelInfo !== undefined && (
<span className="flex flex-col items-start mx-auto">
<span className="font-mono">{ocelInfo.num_events} Events</span>
<span className="flex flex-col items-center mx-auto text-xl">
<span className=" font-semibold text-green-700">OCEL loaded</span>
<span>{ocelInfo.num_events} Events</span>
<span>{ocelInfo.num_objects} Objects</span>
</span>
)}
{ocelInfo !== undefined && (
<>
<MenuLink to="/ocel-info">View OCEL Info</MenuLink>
<MenuLink to="/beta">Open Beta</MenuLink>
<MenuLink to="/ocel-info">OCEL Info</MenuLink>
<MenuLink to="/constraints">Constraints</MenuLink>
</>
)}
<br />
Expand All @@ -98,16 +93,7 @@ function App() {
)}
</div>
</div>
<div className="px-4 overflow-auto">
<div className="flex justify-center px-2 pt-4">
<h1 className="text-pink-500 opacity-90 py-1 text-5xl font-black">
OCED
</h1>
<h1 className="text-blue-500 opacity-90 py-1 text-5xl font-black -ml-[0.5ch]">
DECLARE
</h1>
</div>

<div className="px-4 overflow-auto py-8">
{/* <Spinner loadingText="Importing OCEL..." spinning={loading} /> */}
{isAtRoot && (
<div className="">
Expand Down
14 changes: 1 addition & 13 deletions frontend/src/router.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,25 +4,13 @@ import OuterVisualEditor from "./routes/visual-editor/outer-visual-editor/OuterV
import OcelInfoViewer from "./routes/ocel-info/OcelInfoViewer.tsx";
import ErrorPage from "./ErrorPage.tsx";

// export const router = createBrowserRouter([
// {
// path: "/",
// element: <App />,
// errorElement: <ErrorPage />,
// children: [
// { path: "/beta", element: <OuterVisualEditor /> },
// { path: "/ocel-info", element: <OcelInfoViewer /> },
// ],
// },
// ]);

const router = createBrowserRouter([
{
path: "/",
element: <App />,
errorElement: <ErrorPage />,
children: [
{ path: "/beta", element: <OuterVisualEditor /> },
{ path: "/constraints", element: <OuterVisualEditor /> },
{ path: "/ocel-info", element: <OcelInfoViewer /> },
],
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,17 +134,12 @@ export default function ConstraintContainer({
// const valWithCorrectCaps = ocelInfo.object_types.find(
// (o) => o.name.toLowerCase() === val,
// )?.name;
console.log({ valWithCorrectCaps });
if (
valWithCorrectCaps == null ||
valWithCorrectCaps === ""
) {
return;
}
console.log(
{ valWithCorrectCaps },
ocelInfo.object_types,
);
if (
editMetaInfoData.name === "" ||
editMetaInfoData.name.match(
Expand Down
Loading

0 comments on commit bc381e4

Please sign in to comment.