Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/twbs/bootstrap.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGaƫl Poupard <ffoodd@users.noreply.github.com>2020-09-04 20:21:54 +0300
committerGitHub <noreply@github.com>2020-09-04 20:21:54 +0300
commit5b37d03ff9973107bb3131e0bea83fa4cdf5ec3e (patch)
tree0cb7b70a466b51694633ca58884513196e9468a7 /site/layouts
parentfb9bf54d2c114d79111a315c1dc74ac4ba219329 (diff)
docs(placeholder): drop role=img and use aria-hidden for decorative SVG placeholders (#31575)
Co-authored-by: XhmikosR <xhmikosr@gmail.com>
Diffstat (limited to 'site/layouts')
-rw-r--r--site/layouts/shortcodes/placeholder.html2
1 files changed, 1 insertions, 1 deletions
diff --git a/site/layouts/shortcodes/placeholder.html b/site/layouts/shortcodes/placeholder.html
index 03fbd05df0..2373bc9274 100644
--- a/site/layouts/shortcodes/placeholder.html
+++ b/site/layouts/shortcodes/placeholder.html
@@ -23,7 +23,7 @@
{{- $show_title := not (eq $title "false") -}}
{{- $show_text := not (eq $text "false") -}}
-<svg class="bd-placeholder-img{{ with $class }} {{ . }}{{ end }}" width="{{ $width }}" height="{{ $height }}" xmlns="http://www.w3.org/2000/svg"{{ if (or $show_title $show_text) }} aria-label="{{ if $show_title }}{{ $title }}{{ if $show_text }}: {{ end }}{{ end }}{{ if ($show_text) }}{{ $text }}{{ end }}"{{ end }} preserveAspectRatio="xMidYMid slice" role="img" focusable="false">
+<svg class="bd-placeholder-img{{ with $class }} {{ . }}{{ end }}" width="{{ $width }}" height="{{ $height }}" xmlns="http://www.w3.org/2000/svg"{{ if (or $show_title $show_text) }} role="img" aria-label="{{ if $show_title }}{{ $title }}{{ if $show_text }}: {{ end }}{{ end }}{{ if ($show_text) }}{{ $text }}{{ end }}"{{ else }} aria-hidden="true"{{ end }} preserveAspectRatio="xMidYMid slice" focusable="false">
{{- if $show_title -}}<title>{{ $title }}</title>{{- end -}}
<rect width="100%" height="100%" fill="{{ $background }}"/>
{{- if $show_text -}}<text x="50%" y="50%" fill="{{ $color }}" dy=".3em">{{ $text }}</text>{{- end -}}