0

I have a problem, I can't change the width of my popover, I need the width of the popover to fit its content

Problem

My view:

<button uib-popover-template="'excelTools.html'" popover-placement="bottom"
        popover-title="" type="button"
        class="btn btn-default pull-right">Importar</button>

<script type="text/ng-template" id="excelTools.html">
  <div class="container-fluid">
    <div class="text-element content-element circles-list">
      <ol>
        <li>Create a new Canva account to get started with your own Organizational Chart design.</li>
        <li><span style="font-weight: 400">Choose a template and click on the text boxes to start customizing your chart. </span></li>
        <li><span style="font-weight: 400">Customize details like colors and fonts.</span></li>
        <li>Choose from our stunning range of graph elements, like frames, s, like frames, s, like frames, s, like frames, s, like frames, s, like frames, shapes and lines.</li>
        <li>Save and share.</li>
      </ol>
    </div>
  </div>
</script>

My .css:

.content-element{
    margin:50px 0 0 50px;
}
.circles-list ol {
    list-style-type: none;
    margin-left: 1.25em;
    padding-left: 2.5em;
    counter-reset: li-counter;
    border-left: 1px solid #00c4cc;
    position: relative;
}

.circles-list ol > li {
    position: relative;
    margin-bottom: 3.125em;
    clear: both;
}

.circles-list ol > li:before {
    position: absolute;
    top: -0.5em;
    font-family: "Open Sans", sans-serif;
    font-weight: 600;
    font-size: 1em;
    left: -3.75em;
    width: 2.25em;
    height: 2.25em;
    line-height: 2.25em;
    text-align: center;
    z-index: 9;
    color: #00c4cc;
    border: 2px solid #00c4cc;
    border-radius: 50%;
    content: counter(li-counter);
    background-color: #ebeced;
    counter-increment: li-counter;
}

I already tried the solutionshere UI Bootstrap Popover: change width but none works for me, I don't know if I'm doing well

I took my popover code on this page http://angular-ui.github.io/bootstrap/

georgeawg
  • 48,608
  • 13
  • 72
  • 95
  • 1
    Inspect the element in the Developer Console. Use the Computed Style Pane to determine the appropriate CSS to use. – georgeawg Jul 31 '19 at 03:02

1 Answers1

0

it worked add !important in my CSS

.popover {
    width: 500px !important;
    max-width:500px !important;
}