Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • B bootstrap
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 263
    • Issues 263
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 114
    • Merge requests 114
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Bootstrap
  • bootstrap
  • Issues
  • #20730
Closed
Open
Issue created Sep 16, 2016 by Administrator@rootContributor

custom-checkbox broken when not using label next to checkbox

Created by: Gillardo

When reporting a bug, include:

  • Operating system and version (Windows)
  • Browser and version (Chrome 52.0.2743.116 m (64-bit))

image

Code to reproduce, as you can see i am using a form, so no need to have a description

    <div class="row form-group">
        <label class="col-sm-2 col-form-label">Legend</label>
        <div class="col-sm-10 col-md-7">
            <label class="custom-control custom-checkbox">
                <input type="checkbox" class="custom-control-input" />
                <span class="custom-control-indicator"></span>
            </label>
            <div class="text-muted">
                Display legend
            </div>
        </div>
    </div>

I have also tried adding a blank custom-control-description class to the html, so it looks like this, and again, still same line up issue

    <div class="row form-group">
        <label class="col-sm-2 col-form-label">Legend</label>
        <div class="col-sm-10 col-md-7">
            <label class="custom-control custom-checkbox">
                <input type="checkbox" class="custom-control-input" />
                <span class="custom-control-indicator"></span>
                <span class="custom-control-description"></span>
            </label>
            <div class="text-muted">
                Display legend
            </div>
        </div>
    </div>

If however, i use custom-control-description and ever in a single character, it lines up fine, as you can see here

image

Assignee
Assign to
Time tracking