Skip to content

Commit 5b428d3

Browse files
authored
Applied Icons reference feedback (#2631)
* Applied Icons reference feedback * Fixed links * Fixed links2 * Added description
1 parent 7223f7a commit 5b428d3

File tree

7 files changed

+29
-26
lines changed

7 files changed

+29
-26
lines changed

docs/administration/back_office/back_office_elements/custom_icons.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ Place the icon in `public/assets/images` and run `yarn encore <dev|prod>` after
2525

2626
If you want to configure icons per SiteAccess, see [Icon sets](#icon-sets).
2727

28-
To see more configuration options, see [icon sizes](other_twig_filters.md).
28+
To see more configuration options, see [the icon reference](icon_twig_functions.md).
2929

3030
### Access icons in Twig templates
3131

docs/templating/twig_function_reference/content_twig_functions.md

+13
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,19 @@ If the content item doesn't have a translation in the prioritized or passed lang
106106
{% endif %}
107107
```
108108

109+
### `ibexa_taxonomy_entries_for_content()` filter
110+
111+
`ibexa_taxonomy_entries_for_content()` fetches names of content categories.
112+
113+
| Argument | Type | Description |
114+
|---------------|------|-------------|
115+
| `content` | [`Ibexa\Contracts\Core\Repository\Values\Content\Content`](../../api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-Values-Content-Content.html) | Content item to display the category name for. |
116+
117+
```html+twig
118+
{{ content|ibexa_taxonomy_entries_for_content|map(entry => "#{entry.name}")|join(', ') }}
119+
```
120+
121+
109122
## Non-content related queries
110123

111124
### `ibexa_render_content_query()`

docs/templating/twig_function_reference/other_twig_filters.md docs/templating/twig_function_reference/icon_twig_functions.md

+11-22
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
---
2+
description: Icon Twig functions enable referencing SVG icons in templates.
23
page_type: reference
34
---
45

5-
# Other Twig filters
6+
# Icon Twig functions
67

78
### `ibexa_icon_path()`
89

@@ -53,16 +54,16 @@ To change the default size, in the template add the modifier to the class name.
5354

5455
The list of available icon sizes:
5556

56-
|Size| Modifier|
57+
|Modifier|Size|
5758
|----|---------|
58-
|`8px`|`--tiny`|
59-
|`12px`|`--tiny-small`|
60-
|`16px`|`--small`|
61-
|`20px`|`--small-medium`|
62-
|`24px`|`--medium`|
63-
|`38px`|`--medium-large`|
64-
|`48px`|`--large`|
65-
|`64px`|`--extra-large`|
59+
|`--tiny`|`8px`|
60+
|`--tiny-small`|`12px`|
61+
|`--small`|`16px`|
62+
|`--small-medium`|`20px`|
63+
|`--medium`|`24px`|
64+
|`--medium-large`|`38px`|
65+
|`--large`|`48px`|
66+
|`--extra-large`|`64px`|
6667

6768
#### Icons reference
6869

@@ -395,15 +396,3 @@ The following icons are available out-of-the-box:
395396
| ![interface-block](img/icons/interface-block.svg.png) | `interface-block` |
396397
| ![full-view](img/icons/full-view.svg.png) | `full-view` |
397398
| ![un-full-view](img/icons/un-full-view.svg.png) | `un-full-view` |
398-
399-
### `ibexa_taxonomy_entries_for_content()`
400-
401-
`ibexa_taxonomy_entries_for_content()` fetches names of content categories.
402-
403-
| Argument | Type | Description |
404-
|---------------|------|-------------|
405-
| `content` | `Ibexa\Contracts\Core\Repository\Values\Content\Content` | Content item to display the category name for. |
406-
407-
```html+twig
408-
{{ content|ibexa_taxonomy_entries_for_content|map(entry => "#{entry.name}")|join(', ') }}
409-
```
Loading

docs/templating/twig_function_reference/twig_function_reference.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ In addition to the [native functions provided by Twig](https://twig.symfony.com/
1616
"templating/twig_function_reference/product_twig_functions",
1717
"templating/twig_function_reference/site_context_twig_functions",
1818
"templating/twig_function_reference/storefront_twig_functions",
19+
"templating/twig_function_reference/icon_twig_functions",
1920
"templating/twig_function_reference/image_twig_functions",
2021
"templating/twig_function_reference/url_twig_functions",
2122
"templating/twig_function_reference/date_twig_filters",
2223
"templating/twig_function_reference/ai_actions_twig_functions",
23-
"templating/twig_function_reference/other_twig_filters",
2424
], columns=4) =]]

mkdocs.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -293,14 +293,14 @@ nav:
293293
- Content Twig functions: templating/twig_function_reference/content_twig_functions.md
294294
- Date Twig filters: templating/twig_function_reference/date_twig_filters.md
295295
- Field Twig functions: templating/twig_function_reference/field_twig_functions.md
296+
- Icon Twig functions: templating/twig_function_reference/icon_twig_functions.md
296297
- Image Twig functions: templating/twig_function_reference/image_twig_functions.md
297298
- Product Twig functions: templating/twig_function_reference/product_twig_functions.md
298299
- Site context Twig functions: templating/twig_function_reference/site_context_twig_functions.md
299300
- Storefront Twig functions: templating/twig_function_reference/storefront_twig_functions.md
300301
- URL Twig functions: templating/twig_function_reference/url_twig_functions.md
301302
- User Twig functions: templating/twig_function_reference/user_twig_functions.md
302303
- AI Twig functions: templating/twig_function_reference/ai_actions_twig_functions.md
303-
- Other Twig filters: templating/twig_function_reference/other_twig_filters.md
304304
- URLs and routes:
305305
- URLs and routes: templating/urls_and_routes/urls_and_routes.md
306306
- Custom breadcrumbs: templating/urls_and_routes/custom_breadcrumbs.md

plugins.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ plugins:
190190
'guide/content_rendering/twig_function_reference/image_twig_functions.md': 'templating/twig_function_reference/image_twig_functions.md'
191191
'guide/content_rendering/twig_function_reference/url_twig_functions.md': 'templating/twig_function_reference/url_twig_functions.md'
192192
'guide/content_rendering/twig_function_reference/date_twig_filters.md': 'templating/twig_function_reference/date_twig_filters.md'
193-
'guide/content_rendering/twig_function_reference/other_twig_filters.md': 'templating/twig_function_reference/other_twig_filters.md'
193+
'guide/content_rendering/twig_function_reference/other_twig_filters.md': 'templating/twig_function_reference/icon_twig_functions.md'
194194
'guide/content_rendering/urls_and_routes.md': 'templating/urls_and_routes/urls_and_routes.md'
195195
'guide/content_rendering/custom_breadcrumbs.md': 'templating/urls_and_routes/custom_breadcrumbs.md'
196196
'guide/content_rendering/design_engine/design_engine.md': 'templating/design_engine/design_engine.md'
@@ -531,6 +531,7 @@ plugins:
531531
'getting_started/install_ez_platform.md': 'getting_started/install_ibexa_dxp.md'
532532

533533
'templating/layout/create_user_registration_form.md': 'customer_management/create_user_registration_form.md'
534+
'templating/twig_function_reference/other_twig_filters.md': 'templating/twig_function_reference/icon_twig_functions.md'
534535

535536
'tutorials/platform_beginner/building_a_bicycle_route_tracker_in_ez_platform.md': 'tutorials/beginner_tutorial/beginner_tutorial.md'
536537
'tutorials/platform_beginner/1_get_ready.md': 'tutorials/beginner_tutorial/1_get_ready.md'

0 commit comments

Comments
 (0)