Skip to content

Commit

Permalink
fix: programme badge in proposal details page
Browse files Browse the repository at this point in the history
  • Loading branch information
aleche28 committed Jan 25, 2024
1 parent 54c909c commit 1ccb363
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 3 deletions.
6 changes: 3 additions & 3 deletions frontend/src/pages/ProposalDetailsPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@ function ProposalDetailsPage({ mode }) {
</Alert>
</Container>
)

: (
<Container className="proposal-details-container" fluid>
<Form>
Expand Down Expand Up @@ -749,8 +749,8 @@ function ProposalDetailsPage({ mode }) {
name="proposal-programmes"
>
{programmes.map((programme, index) => (
<Badge key={index} bg="">
{programme.title_degree}
<Badge className="programme-badge" key={index} bg="">
<span>{programme.title_degree}</span>
</Badge>
))}
</Card.Text>
Expand Down
13 changes: 13 additions & 0 deletions frontend/src/style/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,20 @@ body {
background-color: #003576;
}

@media (max-width: 767px) {
.programme-badge {
max-width: 220px; /* Set your desired maximum width */
display: inline-block; /* Make sure the width constraint is applied */
word-wrap: break-word;
}

.programme-badge span {
display: block;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
}
/*************************/
/* ARCHIVE MODAL *******/
/*************************/
Expand Down

0 comments on commit 1ccb363

Please sign in to comment.