> Documentation index: https://www.gooddata.ai/docs/gooddata-ui/llms.txt lists every page of these docs as Markdown.

# getColorMappingPredicate()

- Package: [@gooddata/sdk-ui-vis-commons](https://www.gooddata.ai/docs/gooddata-ui/latest/api-reference/sdk-ui-vis-commons/index.md)
- Kind: function
- Source: https://github.com/gooddata/gooddata-ui-sdk/blob/rel/11.64/libs/sdk-ui-vis-commons/src/coloring/color.ts

Creates new predicate for mapping colors to chart entities:

- if attribute header, URI is expected to match testValue - otherwise (attr or measure descriptor) expecting local identifier match

**Signature:**

```typescript
export declare function getColorMappingPredicate(testValue: string): IHeaderPredicate;
```

## Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| testValue | string | right hand side to test against |

**Returns:**

[IHeaderPredicate](https://www.gooddata.ai/docs/gooddata-ui/latest/api-reference/sdk-ui/sdk-ui.iheaderpredicate/index.md)
