Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
fahrtenbuch
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
SWP WS21_22 - Fahrtenbuch
Team Einhorn
fahrtenbuch
Commits
679efeac
Commit
679efeac
authored
3 years ago
by
Sebastian Kuzniarz
Browse files
Options
Downloads
Patches
Plain Diff
Added managed boat tile (not tested)
parent
13e423a8
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
client/src/components/ManagedBoatTile.tsx
+22
-0
22 additions, 0 deletions
client/src/components/ManagedBoatTile.tsx
with
22 additions
and
0 deletions
client/src/components/ManagedBoatTile.tsx
0 → 100644
+
22
−
0
View file @
679efeac
import
React
from
"
react
"
;
import
{
Button
,
Col
}
from
"
react-bootstrap
"
;
import
{
useTranslation
}
from
"
react-i18next
"
;
// import { Image } from "react-bootstrap";
// import { Link } from "react-router-dom";
function
ManagedBoatTile
(
props
:
any
)
{
const
{
t
}
=
useTranslation
();
return
(
<
Col
>
<
div
className
=
{
`card-body shadow position-relative mb-1 rounded-2
${
props
.
blocked
?
'
bg-dark
'
:
'
bg-green
'
}
`
}
style
=
{
{
height
:
"
80px
"
}
}
>
<
div
className
=
"text-uppercase fs-4 tile-label-boatName position-absolute ms-2 mt-1 top-0 start-0 text-white fw-bold"
>
{
props
.
boatName
}
</
div
>
<
div
className
=
"tile-label-time position-absolute me-2 mt-2 top-0 end-0 text-white"
>
{
props
.
lastUsed
}
</
div
>
<
Button
variant
=
"light"
className
=
"mb-2 ms-2 bottom-0 start-0 shadow-sm bg-white border w-50 text-uppercase rounded-pill"
>
{
t
(
"
managedBoatTile.buttonInfo
"
)
}
</
Button
>
<
Button
variant
=
"light"
className
=
{
`mb-2 me-2 bottom-0 end-0 shadow-sm
${
props
.
blocked
?
'
bg-green
'
:
'
bg-danger
'
}
border w-50 text-uppercase rounded-pill`
}
>
{
props
.
blocked
?
t
(
"
managedBoatTile.buttonUnblock
"
)
:
t
(
"
managedBoatTile.buttonUBlock
"
)
}
</
Button
>
</
div
>
</
Col
>
);
}
export
default
ManagedBoatTile
;
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment