Translations:SVG-Dashboards/53/en: различия между версиями

Материал из Wiren Board
(Новая страница: «Let's make it so that when the value is greater than 20, the stroke of the element becomes red, dotted and 2px thick. For values less than or equal to 20, the element style will be left by default: <syntaxhighlight lang="javascript"> (val > 20) ? 'stroke: red; stroke-width:2px; stroke-dasharray:2,1' : '' </syntaxhighlight>»)
 
(нет различий)

Текущая версия на 12:54, 4 августа 2023

Определение сообщения (SVG-Dashboards)
Сделаем так, чтобы при значении больше 20 обводка элемента стала красного цвета, пунктиром и толщиной 2px. При значениях меньше или равно 20 стиль элемента оставим по умолчанию:
<syntaxhighlight lang="javascript">
(val > 20) ? 'stroke: red; stroke-width:2px; stroke-dasharray:2,1' : ''
</syntaxhighlight>

Let's make it so that when the value is greater than 20, the stroke of the element becomes red, dotted and 2px thick. For values less than or equal to 20, the element style will be left by default:

 
(val > 20) ? 'stroke: red; stroke-width:2px; stroke-dasharray:2,1' : ''