Are Bootstrap dynamic pills limited to only one use?

I have been working on a login/sign-up form where the display switches between the two forms when clicking on specific buttons. The issue that I'm facing is that the functionality only works once. My client provided me with a website template that they purchased, which includes extensive custom CSS files and its own version of Bootstrap (CSS and JavaScript). I suspect that there might be some modifications in the template causing this problem.

The HTML code for the login form and dynamic tabs looks like this:

<!-- SIGN IN/UP FORM -->
        <div class="form-custom text-center container bg-white">
            <img src="images/logo.png" alt="">

            <div class="tab-content">
                <div id="signin" class="tab-pane fade in active">
                    <form action="" method="post" class="mb-3">
                        <div class="container px-4">
                            <input class="form-style" type="email" name="email" placeholder="Email">
                            <input class="form-style" type="password" name="password" placeholder="Password">
                        </div>
                    </form>
                </div>

                <div id="signup" class="tab-pane fade">
                    <form action="" method="post" class="mb-3">
                        <div class="container px-4">
                            <input class="form-style" type="text" name="first_name" placeholder="First Name">
                            <input class="form-style" type="text" name="last_name" placeholder="Last Name">
                            <input class="form-style" type="email" name="email" placeholder="Email">
                            <input class="form-style" type="password" name="password" placeholder="Password">
                        </div>
                    </form>
                </div>
            </div>

              <ul class="nav nav-pills">
                 <div class="container">
                  <div class="d-flex flex-row justify-content-center">
                      <li class="active">
                            <button data-toggle="pill" href="#signin" class="btn btn-sign">Sign in</button>
                       </li>
                       <li>
                            <button data-toggle="pill" href="#signup" class="btn btn-sign">Sign up</button>
                       </li>
                  </div>
                </div>
             </ul>
        </div>

Here are my own custom style classes created from Sass:

.form-custom {
  position: absolute;
  top: 35vh;
  left: calc(90vw - 475px);
  width: 475px;
  z-index: 5000;
}
@media (max-width: 575.98px) {
  .form-custom {
    width: 420px;
    left: calc(90vw - 420px);
  }
}
@media (max-width: 500px) {
  .form-custom {
    width: 375px;
    left: calc(90vw - 375px);
  }
}
@media (max-width: 400px) {
  .form-custom {
    width: 275px;
    left: calc(90vw - 275px);
  }
}

.form-style {
  display: block;
  width: 100%;
  border-top: 0px;
  border-right: 0px;
  border-left: 0px;
  font-size: 1rem;
}

.form-style:focus {
  outline-color: transparent;
}

.btn-sign {
  display: inline;
  margin: 0px 20px 0px 20px;
  border-radius: 0px;
  width: 180px;
}
@media (max-width: 575.98px) {
  .btn-sign {
    width: 162px;
  }
}
@media (max-width: 500px) {
  .btn-sign {
    width: 126px;
  }
}
@media (max-width: 400px) {
  .btn-sign {
    width: 90px;
  }
}

If anyone has any insights or suggestions on how to make this work seamlessly without glitches, please feel free to share. Your help will be greatly appreciated. Thank you!

Answer №1

I made adjustments to the container and flex div's by commenting them out, which successfully resolved the issue.

<ul class="nav nav-pills">
      <li class="active">
           <button data-toggle="pill" href="#signin" class="btn btn-sign">Sign in</button>
      </li>
      <li>
            <button data-toggle="pill" href="#signup" class="btn btn-sign">Sign up</button>
      </li>
</ul>

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Displaying form fields based on conditions in CodeIgniter using PHP

One of the elements in my form is a select input for manufacturers. <div class="form-group"> <label for="manufacturer">Manufacturer</label> <select id="manufacturerSelect" name="manufacturer" class="form-control"> ...

Can we integrate Bootstrap 5 icons into Bootstrap 4?

Looking to incorporate Bootstrap 5 icons into a Bootstrap 4 project, as mentioned in the title. This is necessary because I have an older web application that relies on Bootstrap 4 and Font Awesome, and I need it to integrate smoothly with a new Bootstrap ...

Managing websites on Android when the keyboard is displayed

I am currently facing an issue with my webpage on Android (Galaxy SIII). The problem occurs when visitors try to enter their email in the form at the bottom of the page. The keyboard becomes visible, causing the design to look messy. When using Chrome, the ...

Ways to ensure the background color stretches the entire length of the page

I've been attempting to create a background image or color that extends across the entire main content area, but haven't had any success so far. For reference, please visit My attempts have involved adding a class called fill to the container-f ...

Issue with menu display after clicking icon

On my website, I am trying to set up an icon that will display a menu bar for mobile users. I have written some JavaScript code for this functionality, but it's not working as expected. My approach involved creating an element called "Menu" and assign ...

The problem with the CSS3 media query arises only within a particular div and not on

I've been encountering an issue with one of the media queries on my website. Specifically, the query targeting a div in the footer is not working as expected. I'm wondering if there's a problem with how I've written the notation? @medi ...

Excessive width of the lower border

I have a dropdown menu on my website and I wanted to add a border-bottom to the menu. However, the border appears too wide. I went through every step of this solution as it seemed like the same problem, but nothing seems to be working. It would be great i ...

Attempting to arrange six images in a row using dividers

Having trouble aligning six images (2 per row with text in between) to the center of your webpage? Don't worry, we've got you covered! Check out the screenshot attached for reference and let us know how we can assist. Click here for a snapshot of ...

What is the best way to use CSS in conjunction with a Master Page and a new content page, ensuring that the new CSS does not interfere with

Currently, I am working with an ASP.Net 4.5 website that incorporates a master page. The site utilizes a CSS file that is applied universally across all pages. Recently, I added a new page to the website which contains its own custom CSS specifically desig ...

How do I utilize the Material-UI slider's activated (CSS API) feature to conceal the shadows?

Can someone please explain to me how I can use the activated class to change the style of the thumb and hide its shadows? According to the official website, the activated class is applied to the track and thumb elements to trigger JSS nested styles when a ...

When attempting to open the HTML file through an Express application, the background image specified by `background-image: url()` may

Upon opening the html file by directly clicking on it, the background-image styled with url() functions correctly. However, when I open this file within an express app using res.sendFile(), the background-image fails to display. Interestingly, all other CS ...

Enter the text div that has been chosen

I have a mini question regarding how to select text and place it in a selected div. This demo was created from codepen.io. In this demo, you will see a blue button and text in a textarea. I would like to be able to select the text "Select this text", cli ...

Implementing jQuery UI toggleClass method to seamlessly alternate between two distinct CSS classes

My goal is to toggle between two CSS classes on a selector click using Jquery UI .toggleClass(), but unfortunately, it's not producing the desired toggle effect. $(".toggle").click(function () { $(".archivePosts .columns").removeClass( "l ...

What could be causing the issue with image handling in ASP.NET deployed on a local IIS server?

My web app, built using ASP.NET 4 MVC2 architecture in Visual Studio 2010, has been deployed to my local IIS server under the virtual directory EasyMan4. Recently, I added an image to the Content Folder via Solution Explorer. In the Site.Master page, I ins ...

Is there a way to prevent my navbar from breaking buttons on mobile devices?

I am a beginner working on my practice portfolio and I have decided to make it fully responsive using flexbox as much as possible. I am following a "mobile-first" approach, so I can address any design issues for desktop later on. One problem I am facing is ...

Creating uniform line lengths with a ruler utilizing Fabric.js

I have a div that scrolls horizontally and contains a ruler div and a canvas where I draw horizontal lines of varying lengths. When drawing the lines, I want to ensure they are accurately measured against the ruler using JavaScript and CSS: var canvas = ...

Fixed top navigation bar that remains sticky while keeping the logo at a consistent size

I stumbled upon this code snippet: <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"> <nav class="navbar navbar-default navbar-fixed-top"> <div class="container"> <div class=" ...

Hide the navigation menu when a page link is selected

Within my Angular 8 application, a fixed navigation bar is positioned at the top of the screen. Upon hovering over a dropdown nav link, a menu will appear for the user to explore. However, when a user clicks on one of these menu links, Angular Routing is ...

How to integrate half-star ratings in Ionic

Recently, I have been struggling with implementing half stars in the rating module of my Ionic mobile application. When the average rating is not a whole number, I opted to round it off and display an Ionic icon star. Below are snippets of the code I curre ...

What could be causing the position sticky to not function properly in my script?

Can someone help me troubleshoot an issue with the TopOptions image and component sticking to the top of the page? {!categorySearch && ( <div className="max-w-2xl mx-auto z-40 relative overflow-x-hidden font-metropolis_semibold" ...