Table rows styling based on criteria not working as expected

Hi,
I am trying to style the rows of a table using the value of a column but it seems that the styling is not applied to all relevant rows of the table. What I want to achieve is to make bold all rows of a table based on the value of a column. Please find below my steps:

  1. On the OnInit, I have used the following script:

formHistoriesTable.setStyleProvider( (entity,property)->{

        if (property == null) {
            if (entity.getForm().equals("xreport"))
              return "new-record";
            else
                return null;
        }
        return null;

    });
  1. I have created a theme extension for Halo and I have added the following css script:

.v-table-row.new-record {
font-weight: bold;
}

What I finally get is the following table:

image

Although all the rows should be styled as bold, I’ve noticed that only the even rows are styled. Am I missing something?

Regards,
George

Hi,

Odd rows have different style name: v-table-row-odd. In addition, you may find this live demo useful.

Gleb

Thank you very much. It’s working now as expected.

Regards,
George