Skip to content

Commit

Permalink
Corrected issue with select2 not affecting all dropdowns of the same …
Browse files Browse the repository at this point in the history
…class
  • Loading branch information
TheMrDew committed Aug 27, 2024
1 parent 9203c5d commit c333cb0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
4 changes: 2 additions & 2 deletions Pokedex/Pokedex/Views/Shared/_Layout.cshtml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<head>
<title class="pageTitle">@ViewBag.Title</title>
<link href="https://stackpath.bootstrapcdn.com/bootstrap/4.5.0/css/bootstrap.min.css" rel="stylesheet" asp-append-version="true">
<link href="https://cdn.jsdelivr.net/npm/select2@4.1.0-rc.0/dist/css/select2.min.css" rel="stylesheet" asp-append-version="true" />
<link href="https://cdn.jsdelivr.net/npm/select2@4.0.0/dist/css/select2.min.css" rel="stylesheet" asp-append-version="true" />
<link href="~/css/main.css" rel="stylesheet" asp-append-version="true">
@RenderSection("styles", required: false)
<meta name="viewport" content="width=device-width, initial-scale=1">
Expand Down Expand Up @@ -74,7 +74,7 @@
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js" asp-append-version="true"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.13.2/jquery-ui.min.js" asp-append-version="true"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.5.0/js/bootstrap.min.js" asp-append-version="true"></script>
<script src="https://cdn.jsdelivr.net/npm/select2@4.1.0-rc.0/dist/js/select2.min.js" asp-append-version="true"></script>
<script src="https://cdn.jsdelivr.net/npm/select2@4.0.0/dist/js/select2.min.js" asp-append-version="true"></script>
<script src="~/js/signalr/dist/browser/signalr.js"></script>

<script>
Expand Down
4 changes: 1 addition & 3 deletions Pokedex/Pokedex/wwwroot/js/pokemonPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -159,9 +159,7 @@ $(document).ready(function () {
$('#TerapagosTerastal.page .teraTypeSelectList').val(0);
}

$('.teraTypeSelectList').each(function () {
$(this).select2();
});
$('.teraTypeSelectList').select2();
})

$('span[title]').on('click', function() {
Expand Down

0 comments on commit c333cb0

Please sign in to comment.