- GitHub: [BonnierNews/dn-design-system/../web/src/components/image-caption](https://github.com/BonnierNews/dn-design-system/tree/main/web/src/components/image-caption)
- Storybook: [ImageCaption](https://designsystem.dn.se/?path=/docs/article-imagecaption--docs)
- Storybook (Latest): [ImageCaption](https://designsystem-latest.dn.se/?path=/docs/article-imagecaption--docs)

----

# ImageCaption

## Parameters

|parameter | type | required | options | default | description |
|:--- | :--- | :--- | :--- | :--- | :--- |
|caption | String | no | | | Ex "Detta är en bildtext" |
|imageType | String | no | | | Type of image. Ex "Foto" |
|author | String | no | | | Ex "Paul Hansen" |
|attributes | Object | no | | | Ex. { target: "_blank", "data-test": "lorem ipsum" } |
|classNames | String | no | | | Ex. "my-special-class" |
|forcePx | Bool | no | true, false | false | Fixed pixel value is used for typography to prevent scaling based on html font-size

## Minimum requirement example

### Nunjucks

These are copy paste friendly examples to quickliy get started using a component.

```html
{% from '@bonniernews/dn-design-system-web/components/image-caption/image-caption.njk' import ImageCaption %}

{{ ImageCaption({
  caption: "En bildtext",
  imageType: "Foto",
  author: "Paul Hansen"
})}}
```

### SCSS
```scss
@use "@bonniernews/dn-design-system-web/components/image-caption/image-caption";
```
