APEX 20.1 - 交互式网格的样式列组标题

APEX 20.1 - Styling Column Group Heading of Interactive Grid

有没有人举例说明如何在交互式网格中设置列标题的样式?

我希望 4 个不同的列组中的每个列标题都具有不同的背景颜色,以使组更容易区分:

似乎没有办法通过开发人员界面轻松地将样式分配给列组。所以,我尝试使用 TH ID:

#R141502556723241100_ig_grid_vc_cur {
    background-color: #242d45;
    color: #ffffff;
}

但它不会为 Term/Element TH 更改 background-color,而是为单击的任何元素更改 background-color。

首先给你的IG添加静态ID。

  • 静态 ID:我的静态 ID

然后您可以使用以下 css 片段:


/*

where the value between the quotation marks ("") is the index of the column heading

*/
#my-static-id  th[data-idx="0"] { 
  background-color: rebeccapurple;
}

#my-static-id  th[data-idx="1"] {
  background-color: green;
}

结果: