# Badge Module

## Component

With the badge you can mark or highlight an element with a special meaning. A obvious example is the 'Coming soon' badge in the evalink marketplace.

*optional* @Input() **position**: [BadgePosition](/modules-components/elements/badge-module.md#badgeposition), *Default `BadgePosition.TopLeft`*

{% hint style="info" %}
*`The parent element needs to be set to`**`position: relative.`***&#x20;
{% endhint %}

![Examples with the different position of the evalink-badge](/files/-MdMszJJLXy9udCB-yIx)

### Example

Import the `CauseBadgeModule` into the desired module as demonstrated in the following example:

{% tabs %}
{% tab title="some.module.ts" %}

```typescript
...
import { SomeComponent } from './some.component';
//Import from evalink cause
import { CauseBadgeModule } from '@evalink/cause';
...

@NgModule({
  declarations: [
   SomeComponent
  ],
  imports: [
    ...
    CauseCardModule,
    // Import the CauseBadgeModule into the module 
    CauseBadgeModule,
    ...
  ]
})
export class SomeModule {}
```

{% endtab %}

{% tab title="some.component.ts" %}

```markup
<cause-card class="relative">
    <cause-badge>Coming soon</cause-badge>
    ...
</cause-card>
```

{% endtab %}
{% endtabs %}

## Enums

### BadgePosition

```typescript
export enum BadgePosition {
  TopLeft = 'cause-badge--top-left',
  TopRight = 'cause-badge--top-right',
  BottomLeft = 'cause-badge--bottom-left',
  BottomRight = 'cause-badge--bottom-right',
}
```


---

# Agent Instructions: Querying This Documentation

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

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://cause.evalink.io/modules-components/elements/badge-module.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
