> For the complete documentation index, see [llms.txt](https://docs.inforiver.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.inforiver.com/analytics+/working-with-analytics+/9.-conditional-formatting/one-click-rules/one-click-rules-for-cards.md).

# One click rules for cards

In this section, we'll discover the single-click conditional formatting options for cards. Selecting a single-click rule will open the Conditional Formatting side pane. By default, single-click rules will use the AC (Actuals) measure. The configurations are automatically set but you can modify them as required. We'll learn more about configuring rules in later sections.

### 1. Value

You can highlight positive/negative values using this option. You can also set a threshold and highlight values that are lesser or greater than the custom threshold.

Let's use the **custom threshold** option to highlight the cards with sales greater than 14m.

<figure><img src="https://3132984990-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbOoZhPvC57Z0CNgep4Ib%2Fuploads%2FHuCIWzOBndAHBPKPZ09B%2Fimage.png?alt=media&amp;token=7e183670-d8eb-4f88-907e-1b8ee4f2620e" alt=""><figcaption><p>The background color has been changed for the cards with sales > 14m</p></figcaption></figure>

### 2. Comparison value

You can use the comparison value option to quickly highlight data based on comparing 2 columns. Analytics+ offers two methods to highlight data based on column comparisons:

* Greater/less than a benchmark
* Ranges

#### 2.1. Greater/less than benchmark

You can highlight values with a single color when the measure is greater or lesser than the benchmark measure.&#x20;

In this case, we used the **Less than benchmark** to highlight the KPI title and value when the 2023 Actuals are lesser than the 2022 Actuals benchmark.

<figure><img src="https://3132984990-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbOoZhPvC57Z0CNgep4Ib%2Fuploads%2F3v3FZCkr7FUzq3L5tGEa%2Fimage.png?alt=media&amp;token=908f92a1-9b5d-4fe9-8175-a6f26e50523d" alt=""><figcaption><p>Benchmark based conditional formatting for cards</p></figcaption></figure>

#### 2.2 Ranges

You can use a heatmap to highlight values when the benchmark measure falls within a specified range.  Analytics+ dynamically calculates the range - enabling you to apply conditional formatting in a single click. You can also override the pre-calculated ranges and specify custom values.

In this example, we used the **Ranges** option and formatted the background color of the cards to format based on specific ranges.

Note: The ranges and colors have been manually updated to use custom values and shades.

<figure><img src="https://3132984990-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbOoZhPvC57Z0CNgep4Ib%2Fuploads%2F9GqqAPlKBeHyREYmevka%2Fimage.png?alt=media&amp;token=f9d4c9f8-0a59-4e5f-afd7-e95894342e0a" alt=""><figcaption><p>Ranges option to format cards</p></figcaption></figure>

### 3. Color scales

Based on your data, you can apply different hcolor scales: sequential, qualitative, and diverging.&#x20;

When a heatmap is used, the font colors are automatically adjusted to be in contrast with their backgrounds for enhanced readability.

{% hint style="info" %}
For Inforiver to automatically adjust the font color, enable the Canvas > Auto color property.
{% endhint %}

In this example, we have used the diverging color scale to format the area charts.

<figure><img src="https://3132984990-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FbOoZhPvC57Z0CNgep4Ib%2Fuploads%2FIdYLkKHtW9O1Bt3ZxvPJ%2Fimage.png?alt=media&amp;token=62b90808-4eb3-4506-84ea-02dfc3cb891c" alt=""><figcaption><p>Diverging color scale for sparkline chart</p></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.inforiver.com/analytics+/working-with-analytics+/9.-conditional-formatting/one-click-rules/one-click-rules-for-cards.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
