format
continuous-integration/drone/push Build is passing Details

pull/81/head
DahmaneYanis 1 year ago
parent b48eb385a9
commit 5407d3fcb7

@ -116,23 +116,26 @@ export default function BendableArrow({
const styleWidth = style?.width ?? ArrowStyleDefaults.width const styleWidth = style?.width ?? ArrowStyleDefaults.width
const computeInternalSegments = useCallback((segments: Segment[]) => { const computeInternalSegments = useCallback(
return segments.map((segment, idx) => { (segments: Segment[]) => {
if (idx == 0) { return segments.map((segment, idx) => {
if (idx == 0) {
return {
start: startPos,
controlPoint: segment.controlPoint ?? null,
end: segment.next,
}
}
const start = segments[idx - 1].next
return { return {
start: startPos, start,
controlPoint: segment.controlPoint ?? null, controlPoint: segment.controlPoint ?? null,
end: segment.next, end: segment.next,
} }
} })
const start = segments[idx - 1].next },
return { [segments, startPos],
start, )
controlPoint: segment.controlPoint ?? null,
end: segment.next,
}
})
}, [segments, startPos])
// Cache the segments so that when the user is changing the segments (it moves an ArrowPoint), // Cache the segments so that when the user is changing the segments (it moves an ArrowPoint),
// it does not unwind to this arrow's component parent until validated. // it does not unwind to this arrow's component parent until validated.
@ -151,8 +154,6 @@ export default function BendableArrow({
const headRef = useRef<HTMLDivElement>(null) const headRef = useRef<HTMLDivElement>(null)
const tailRef = useRef<HTMLDivElement>(null) const tailRef = useRef<HTMLDivElement>(null)
/** /**
* Computes and return the segments edition points * Computes and return the segments edition points
* @param parentBase * @param parentBase

@ -1,35 +1,33 @@
#main { #main {
margin-left : 10%; margin-left: 10%;
margin-right: 10%; margin-right: 10%;
border : solid 2px purple; border: solid 2px purple;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
font-family: Helvetica,; font-family: Helvetica;
} }
.new { .new {
border-radius: 100%; border-radius: 100%;
} }
#header { #header {
text-align: center; text-align: center;
background-color: green; background-color: green;
margin : 0px; margin: 0px;
} }
#body { #body {
display: flex; display: flex;
flex-direction: row; flex-direction: row;
border : solid 10px violet; border: solid 10px violet;
margin:0px margin: 0px;
} }
#personal-space { #personal-space {
background-color: orange; background-color: orange;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
} }
#sideMenu { #sideMenu {
@ -42,46 +40,44 @@
#sideMenu h2 { #sideMenu h2 {
display: inline-block; display: inline-block;
margin-right : 5%; margin-right: 5%;
} }
.titreSideMenu { .titreSideMenu {
border-bottom: black solid 2px; border-bottom: black solid 2px;
width: 95%; width: 95%;
} }
#sideMenu .title { #sideMenu .title {
font-size: 13px; font-size: 13px;
font-weight: bold; font-weight: bold;
color : #FFFFFF; color: #ffffff;
letter-spacing: 1px; letter-spacing: 1px;
text-transform: uppercase; text-transform: uppercase;
background-color: black; background-color: black;
padding : 1.5%; padding: 1.5%;
margin-bottom: 0px; margin-bottom: 0px;
} }
#bodyPersonalSpace { #bodyPersonalSpace {
width: 95%; width: 95%;
border : 1px red solid; border: 1px red solid;
align-self: center; align-self: center;
} }
#bodyPersonalSpace table{ #bodyPersonalSpace table {
width: 100%; width: 100%;
border-collapse : separate; border-collapse: separate;
border-spacing : 1em; border-spacing: 1em;
} }
td { td {
border : 3px solid black; border: 3px solid black;
padding-bottom : 1%; padding-bottom: 1%;
padding-top : 1%; padding-top: 1%;
margin: 80px; margin: 80px;
text-align: center; text-align: center;
} }
td:hover { td:hover {
background-color: red; background-color: red;
}
}

@ -42,7 +42,7 @@ export default function Home({
} }
/** /**
* *
* @param param0 username * @param param0 username
* @returns Header * @returns Header
*/ */

@ -90,5 +90,5 @@ class TeamGateway {
public function getAll(int $user): array { public function getAll(int $user): array {
return $this->con->fetch("SELECT * FROM Team", []); return $this->con->fetch("SELECT * FROM Team", []);
} }
} }

@ -85,7 +85,7 @@ class TeamModel {
* @param integer $user * @param integer $user
* @return array<array<string, mixed>> * @return array<array<string, mixed>>
*/ */
public function getAll(int $user) : array { public function getAll(int $user): array {
return $this->teams->getAll($user); return $this->teams->getAll($user);
} }

Loading…
Cancel
Save