Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

410
Vistas
PrimeNg multiselect inside a modal don't close on clicking outside of the multiselect box
    <modal #myModal>
        <modal-header>
            <h1>Material Picker</h1>
        </modal-header>
        <modal-content>
            Brand:
            <p-dropdown [(ngModel)]="selectedBrand"
                        [options]="brands"
                        id="brand"
                        placeholder="Select a brand"
            ></p-dropdown>
            <br>
            Product Type:
            <p-multiSelect
                [(ngModel)]="selectedProductType"
                [options]="productTypes"
                defaultLabel="Select a product type"
                id="productType"
                [maxSelectedLabels]="0"
                selectedItemsLabel="{0} product(s) selected"
            ></p-multiSelect>
        </modal-content>
        <modal-footer>
            <button (click)="closeModal()" class="btn btn-primary">close</button>
        </modal-footer>
    </modal>

If I open this p-multiselect or p-dropdown then click outside it doesn't close. What should I do to make this multiselect or dropdown close on clicking outside of the component?

about 4 years ago · Juan Pablo Isaza
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda