Split a button to change the background of part of it

Asked

Viewed 32 times

1

I would like to do the same on this button in the chaos, split to use the 4 with the gray background and the rest in the common white, Obs. I’m using the Bootstrap 4 button. Modelo do botão

1 answer

1


Face this has in the documentation... It is called button-group https://getbootstrap.com/docs/4.0/components/button-group/

Application example

<link rel="stylesheet" type="text/css" media="screen" href="https://stackpath.bootstrapcdn.com/bootstrap/4.2.1/css/bootstrap.min.css" />

<div class="container">
    <div class="row">
        <div class="col">
            <div class="btn-group btn-group-lg" role="group" aria-label="Large button group">
                <button type="button" class="btn btn-secondary">4</button>
                <!-- <button type="button" class="btn">Middle</button> -->
                <input type="text" class="border px-2 border-right-0">
                <button type="button" class="btn border border-left-0">←</button>
            </div>
        </div>
    </div>
</div>

Browser other questions tagged

You are not signed in. Login or sign up in order to post.