File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 6868 <small class =" text-muted" >@tip.PublishedDate.ToString( " MMM dd, yyyy" )</small >
6969 </div >
7070 <h5 class =" card-title" >@tip.Title </h5 >
71- <p class =" card-text text-truncate-3" >@tip.Description </p > <div class =" d-flex flex-wrap gap-1 mb-2" style =" max-width : 100% ; overflow : hidden ;" >
71+ <p class =" card-text text-truncate-3" >@tip.Description </p >
72+ <div class =" d-flex flex-wrap gap-1 mb-2" style =" max-width : 100% ; overflow : hidden ;" >
7273 @foreach ( var tag in tip .Tags .Take (3 ))
7374 {
7475 <span class =" badge bg-light text-dark text-truncate" style =" max-width : 150px ;" >#@tag </span >
8283 <div class =" card-footer border-0" >
8384 <div class =" d-flex justify-content-between align-items-center" >
8485 <small class =" text-muted" ><i class =" bi bi-clock" ></i > @tip.ReadingTimeMinutes min read </small >
86+ @if (! string .IsNullOrEmpty (tip .Difficulty ))
87+ {
88+ <span class =" badge @(tip.Difficulty switch
89+ {
90+ " Beginner " => " bg-success " ,
91+ " Intermediate " => " bg-warning text-dark " ,
92+ " Advanced " => " bg-danger " ,
93+ _ => " bg-secondary "
94+ })" >@tip.Difficulty </span >
95+ }
8596 <a asp-page =" /Tips/Details" asp-route-slug =" @tip.UrlSlug" class =" btn btn-sm btn-primary" >Read More </a >
8697 </div >
8798 </div >
You can’t perform that action at this time.
0 commit comments