# Conditionally change row colour in EuiInMemoryTable

**URL:** https://discuss.elastic.co/t/conditionally-change-row-colour-in-euiinmemorytable/332515
**Category:** Kibana
**Tags:** kibana-plugin-development
**Created:** [May 4, 2023, 8:21am UTC](https://discuss.elastic.co/t/conditionally-change-row-colour-in-euiinmemorytable/332515 "2023-05-04T08:21:31Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![Sheereen](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sheereen/32/122005_2.png) [@Sheereen](https://discuss.elastic.co/u/Sheereen)
#### Post date: [May 4, 2023, 8:21am UTC](https://discuss.elastic.co/t/conditionally-change-row-colour-in-euiinmemorytable/332515/1 "2023-05-04T08:21:31Z")

</div>

Hi,

How can I **conditionally change the row colour in EuiInMemoryTable ?**

I have a column, say health. I want to change the entire row colour based on the value in the health column (of the corresponding row).

## Health -\> row-colour

Alarm red  
Warning orange  
Healthy green

And what is the rowProps property of EuiInMemoryTable for? ([Elastic UI Framework | Elastic UI Framework](https://elastic.github.io/eui/#/tabular-content/in-memory-tables:~:text=string-,rowProps,-Applied%20to%20EuiTableRow))

Thanks

---

<div class="post-metadata">

### Author: ![JLeysens](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jleysens/32/67404_2.png) [@JLeysens](https://discuss.elastic.co/u/JLeysens)
#### Post date: [May 9, 2023, 10:35am UTC](https://discuss.elastic.co/t/conditionally-change-row-colour-in-euiinmemorytable/332515/2 "2023-05-09T10:35:43Z")

</div>

Hello @Sheereen !

Is this what you had in mind: [EUI table (forked) - CodeSandbox](https://codesandbox.io/s/eui-table-forked-pi6djg?file=/index.js)

---

<div class="post-metadata">

### Author: ![Sheereen](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sheereen/32/122005_2.png) [@Sheereen](https://discuss.elastic.co/u/Sheereen)
#### Post date: [May 10, 2023, 5:24am UTC](https://discuss.elastic.co/t/conditionally-change-row-colour-in-euiinmemorytable/332515/3 "2023-05-10T05:24:44Z")

</div>

Yes... exactly

Thanks so much

Got to know rowprops and cellprops too 😃

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [June 7, 2023, 5:25am UTC](https://discuss.elastic.co/t/conditionally-change-row-colour-in-euiinmemorytable/332515/4 "2023-06-07T05:25:16Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
