List view No items found own text translation

2
Hi all,  I changed the text with custom text for empty lists with css (like in this forum question https://community.mendix.com/link/questions/96237).  .MyReservationsList>ul>li.mx-listview-empty::before { content:"There are no reservations yet for the upcoming period."; } My app is in English and in Dutch so I would like to translate this sentence to Dutch for the other users. I have multiple lists in the application and every list got a different sentence. I tried this to translate the sentence but it won't work. .MyReservationsList>ul>li.mx-listview-empty::before:lang(nl) { content:"Er zijn nog geen reserveringen voor de komende periode."; } Does anyone know how to translate content in css to another language?   Thanks! Kolien
asked
2 answers
3

Switch the :lang(nl) and ::before parts, ::before should always come last.

answered
7

I fixed it. It was the right code bits but in a different order. To change the language of the empy list text: 

.MyReservationsList>ul>li.mx-listview-empty{
    &:lang(nl)::before {
        content:"Er zijn nog geen reserveringen voor de komende periode.";
    }
    &:lang(en)::before {
        content:"There are no reservations yet for the upcoming period.";
    }
}
.MyReservationsList>ul>li.mx-listview-empty label{
   display: none;
}

 

answered