Add example for justify text

This commit is contained in:
Denis
2022-04-11 16:36:16 +02:00
parent 5a61bb51f5
commit c45a443cf5
2 changed files with 135 additions and 0 deletions

View File

@@ -0,0 +1,14 @@
---
layout: example.html
title: Vector Labels - Justify Text
shortdesc: Example of text justification within a label.
docs: >
This example showcases how the text can be justified within the label box.
By default, the text is justified according to the `textAlign` option.
However, this option justifies the label itself according to the setting.
If one wants to change this behavior, it is possible to use the `justify` text style option.
For more information, see the discussion:
https://github.com/openlayers/openlayers/issues/13481
tags: "vector, openstreetmap, label, rich-text"
---
<div id="map" class="map"></div>