Skip to content

Commit

Permalink
Merge pull request #85 from danheron/fix/truncate-cell-template
Browse files Browse the repository at this point in the history
Hide overflow text in cell template
  • Loading branch information
danheron authored Jan 23, 2024
2 parents 84dc41e + d20da10 commit 0305808
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<MudCalendar Items="_events" Height="500" />

@code {
public static string __description__ = "Calendar Long Text Tests";

private List<CalendarItem> _events = new()
{
new CalendarItem
{
Start = DateTime.Today.AddHours(10),
End = DateTime.Today.AddHours(11),
Text = "Event today"
},
new CalendarItem
{
Start = DateTime.Today.AddDays(1).AddHours(11),
End = DateTime.Today.AddDays(1).AddHours(12.5),
Text = "This is an event tomorrow"
}
};
}
3 changes: 3 additions & 0 deletions Heron.MudCalendar/Styles/Heron.MudCalendar.css
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,9 @@
width: 100%;
margin: 0;
}
.mud-cal-cell-template-chip .mud-chip-content {
overflow: hidden;
}

.mud-cal-clickable {
cursor: pointer;
Expand Down
4 changes: 4 additions & 0 deletions Heron.MudCalendar/Styles/_cellTemplate.scss
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@
.mud-cal-cell-template-chip {
width: 100%;
margin: 0;

.mud-chip-content {
overflow: hidden;
}
}

.mud-cal-clickable {
Expand Down

0 comments on commit 0305808

Please sign in to comment.