aboutsummaryrefslogtreecommitdiff
path: root/docs/4.0/components
diff options
context:
space:
mode:
authorHerst <[email protected]>2017-10-03 03:59:37 +0200
committerMark Otto <[email protected]>2017-10-02 18:59:37 -0700
commitaae11ab6aba1f2ededd591853f0c0294b32a81a4 (patch)
tree94426c343eb74bb625558421e9b66e7321c390a7 /docs/4.0/components
parent0c03b70bcb81ebb83eb41bf3b561a3b2106ec76f (diff)
downloadbootstrap-aae11ab6aba1f2ededd591853f0c0294b32a81a4.tar.xz
bootstrap-aae11ab6aba1f2ededd591853f0c0294b32a81a4.zip
Added type="button" to <button>s without any type (#23866)
https://github.com/twbs/bootlint/wiki/W007
Diffstat (limited to 'docs/4.0/components')
-rw-r--r--docs/4.0/components/badge.md4
-rw-r--r--docs/4.0/components/modal.md2
2 files changed, 3 insertions, 3 deletions
diff --git a/docs/4.0/components/badge.md b/docs/4.0/components/badge.md
index 3ea58bbe8..c42d948d6 100644
--- a/docs/4.0/components/badge.md
+++ b/docs/4.0/components/badge.md
@@ -31,7 +31,7 @@ Badges scale to match the size of the immediate parent element by using relative
Badges can be used as part of links or buttons to provide a counter.
{% example html %}
-<button class="btn btn-primary">
+<button type="button" class="btn btn-primary">
Notifications <span class="badge badge-light">4</span>
</button>
{% endexample %}
@@ -41,7 +41,7 @@ Note that depending on how they are used, badges may be confusing for users of s
Unless the context is clear (as with the "Notifications" example, where it is understood that the "4" is the number of notifications), consider including additional context with a visually hidden piece of additional text.
{% example html %}
-<button class="btn btn-primary">
+<button type="button" class="btn btn-primary">
Profile <span class="badge badge-light">9</span>
<span class="sr-only">unread messages</span>
</button>
diff --git a/docs/4.0/components/modal.md b/docs/4.0/components/modal.md
index 55c1dbc31..491bd3fb8 100644
--- a/docs/4.0/components/modal.md
+++ b/docs/4.0/components/modal.md
@@ -422,7 +422,7 @@ Modals have two optional sizes, available via modifier classes to be placed on a
{% highlight html %}
<!-- Large modal -->
-<button class="btn btn-primary" data-toggle="modal" data-target=".bd-example-modal-lg">Large modal</button>
+<button type="button" class="btn btn-primary" data-toggle="modal" data-target=".bd-example-modal-lg">Large modal</button>
<div class="modal fade bd-example-modal-lg" tabindex="-1" role="dialog" aria-labelledby="myLargeModalLabel" aria-hidden="true">
<div class="modal-dialog modal-lg">