Skip to content

Commit

Permalink
Merge pull request #146 from UniRegensburg/dev
Browse files Browse the repository at this point in the history
Release 2.2.0
  • Loading branch information
JuliaSageder authored Nov 24, 2023
2 parents 2609d38 + ece2821 commit 723bd36
Show file tree
Hide file tree
Showing 38 changed files with 3,294 additions and 1,233 deletions.
554 changes: 319 additions & 235 deletions package-lock.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
"js-cookie": "^3.0.1",
"jspdf": "^2.5.1",
"jspdf-autotable": "^3.5.28",
"jszip": "^3.10.1",
"pdf-lib": "^1.17.1",
"phosphor-react": "^1.4.1",
"react": "^18.2.0",
Expand Down
Binary file added public/videos/BDBeiträgeGliederung.mp4
Binary file not shown.
Binary file added public/videos/BDBeweiseFiltern.mp4
Binary file not shown.
Binary file added public/videos/BDErweiterteSignatur.mp4
Binary file not shown.
Binary file added public/videos/BDpdftiff.mp4
Binary file not shown.
Binary file added public/videos/BDuVgdB.mp4
Binary file not shown.
26 changes: 23 additions & 3 deletions src/components/AboutDevelopersMenu.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,17 @@
import { CaretDown, CaretUp, Envelope, Info, Notebook } from "phosphor-react";
import {
CaretDown,
CaretUp,
Envelope,
Info,
Notebook,
Question,
} from "phosphor-react";
import { useState } from "react";
import { AiFillGithub } from "react-icons/ai";
import { Tooltip } from "./Tooltip";
import { useImprint, usePatchnotes } from "../contexts";
import { useOnboarding } from "../contexts/OnboardingContext";
import { Onboarding } from "./Onboarding";

const studentData2021 = [
{
Expand Down Expand Up @@ -70,6 +79,7 @@ export const AboutDevelopersMenu = () => {
const [showDevelopers2023, setShowDevelopers2023] = useState<boolean>(false);
const { setShowPatchnotesPopup } = usePatchnotes();
const { setShowImprintPopup } = useImprint();
const { isOnboardingVisible, setIsOnboardingVisible } = useOnboarding();

return (
<div>
Expand All @@ -92,6 +102,15 @@ export const AboutDevelopersMenu = () => {
<Notebook size={20} />
</div>
</Tooltip>
<Tooltip text="Hilfe">
<div
className="bg-offWhite p-2 rounded-md cursor-pointer hover:bg-lightGrey items-center"
onClick={() => {
setIsOnboardingVisible(true);
}}>
<Question size={20} />
</div>
</Tooltip>
<div
className="flex flex-row items-center justify-center gap-1 bg-offWhite p-2 rounded-md cursor-pointer hover:bg-lightGrey"
onClick={() => {
Expand All @@ -105,7 +124,8 @@ export const AboutDevelopersMenu = () => {
)}
</div>
</div>
{showDevelopersMenu ? (
{isOnboardingVisible && <Onboarding></Onboarding>}
{showDevelopersMenu && (
<div className="w-full bg-offWhite rounded-md p-6 mt-2">
<div className="pt-4 pb-6">
<img
Expand Down Expand Up @@ -286,7 +306,7 @@ export const AboutDevelopersMenu = () => {
</div>
)}
</div>
) : null}
)}
</div>
);
};
6 changes: 1 addition & 5 deletions src/components/AssociationsPopup.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { X } from "phosphor-react";
import cx from "classnames";
import { IEntry, UserRole } from "../types";
import { Entry } from "./entry";
import { useUser } from "../contexts";
Expand All @@ -23,10 +22,7 @@ export const AssociationsPopup: React.FC<AssociationsPopupProps> = ({

return (
<>
<div
className={cx(
"justify-center items-center flex overflow-x-hidden overflow-y-auto fixed inset-0 z-50 outline-none focus:outline-none"
)}>
<div className="justify-center items-center flex overflow-x-hidden overflow-y-auto fixed inset-0 z-50 outline-none focus:outline-none">
<div className="my-6 mx-auto w-[80vw]">
{/*content*/}
<div
Expand Down
29 changes: 25 additions & 4 deletions src/components/Discussion.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,13 @@ import { EntryList } from "./entry";
import { JudgeDiscussion } from "./JudgeDiscussion";
import { MetaData } from "./metadata/MetaData";
import { SectionHeader } from "./section-header/SectionHeader";
import { MetaDataHeader } from "./metadata/MetaDataHeader";
import { useState } from "react";

export const Discussion = () => {
const [isBodyOpenPlaintiff, setIsBodyOpenPlaintiff] = useState<boolean>(true);
const [isBodyOpenDefendant, setIsBodyOpenDefendant] = useState<boolean>(true);

const { groupedEntries } = useCase();
const { sectionList, individualSorting } = useSection();
const { user } = useUser();
Expand All @@ -26,7 +31,7 @@ export const Discussion = () => {

return (
<DndProvider backend={HTML5Backend}>
<div className="bg-offWhite h-full overflow-y-scroll py-28 px-4 space-y-4 scroll-smooth">
<div className="bg-offWhite h-full overflow-y-scroll py-8 px-4 space-y-4 scroll-smooth">
<div className="max-w-[1500px] m-auto">
{highlightElementsWithSpecificVersion ? (
<div className="flex justify-center z-[30] relative">
Expand All @@ -48,9 +53,25 @@ export const Discussion = () => {
</div>
</div>
) : null}
<div className="grid grid-cols-2 gap-6 mb-16 ml-[40px]">
<MetaData owner={UserRole.Plaintiff} />
<MetaData owner={UserRole.Defendant} />
<div className="grid grid-cols-2 gap-6 ml-[40px]">
<MetaDataHeader
owner={UserRole.Plaintiff}
isBodyOpen={isBodyOpenPlaintiff}
setIsBodyOpen={setIsBodyOpenPlaintiff}
/>
<MetaDataHeader
owner={UserRole.Defendant}
isBodyOpen={isBodyOpenDefendant}
setIsBodyOpen={setIsBodyOpenDefendant}
/>
</div>
<div className="grid grid-cols-2 gap-6 ml-[40px] mt-4">
{isBodyOpenPlaintiff ? (
<MetaData owner={UserRole.Plaintiff} />
) : (
<div></div>
)}
{isBodyOpenDefendant && <MetaData owner={UserRole.Defendant} />}
</div>
{selectedSorting === Sorting.Privat && showEntrySorting ? (
<JudgeDiscussion />
Expand Down
Loading

0 comments on commit 723bd36

Please sign in to comment.