From bb808a9b9cdbd118df8b9729c3297f5edc99448c Mon Sep 17 00:00:00 2001 From: Nathan Osman Date: Mon, 4 Jan 2021 22:49:44 -0800 Subject: [PATCH] Fix invalid markup generated for dropdown in Bootstrap 4 When run in Bootstrap 4, the plugin creates elements for the dropdown. However, this is invalid markup, as the href attribute is required for the element. The result of this omission is that the text color is incorrect in many themes and the cursor is not a pointer. This pull request fixes the oversight. --- src/dropdownV4.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/dropdownV4.ts b/src/dropdownV4.ts index 58fe69f..2951aa2 100644 --- a/src/dropdownV4.ts +++ b/src/dropdownV4.ts @@ -209,6 +209,7 @@ export class DropdownV4 { const li = $(''); li.addClass('dropdown-item') + .attr('href', 'javascript:void(0)') .css({ 'overflow': 'hidden', 'text-overflow': 'ellipsis' }) .html(itemHtml) .data('item', item);