Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IBX-7187: Get content category Twig filter #2251

Merged
merged 1 commit into from
Dec 19, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 13 additions & 1 deletion docs/templating/twig_function_reference/other_twig_filters.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
</svg>
```

### Icons size variants
#### Icon size variants

The default icon size in the Back Office is `32px`. To change the default size, in the template add the modifier to the class name.

Expand All @@ -56,3 +56,15 @@
|`38px`|`--medium-large`|
|`48px`|`--large`|
|`64px`|`--extra-large`|

### `ibexa_taxonomy_entries_for_content()`

`ibexa_taxonomy_entries_for_content()` fetches names of content categories.

| Argument | Type | Description |
|---------------|------|-------------|
| `content` | `Ibexa\Contracts\Core\Repository\Values\Content\Content` | Content item to display the category name for. |

```html+twig
{{ content|ibexa_taxonomy_entries_for_content|map(entry => "#{entry.name}")|join(', ') }}

Check warning on line 69 in docs/templating/twig_function_reference/other_twig_filters.md

View workflow job for this annotation

GitHub Actions / vale

[vale] docs/templating/twig_function_reference/other_twig_filters.md#L69

[Ibexa.EOLWhitespace] Remove whitespace characters from the end of the line.
Raw output
{"message": "[Ibexa.EOLWhitespace] Remove whitespace characters from the end of the line.", "location": {"path": "docs/templating/twig_function_reference/other_twig_filters.md", "range": {"start": {"line": 69, "column": 90}}}, "severity": "WARNING"}
```