bergben / ng2-file-input

Angular 2 component that implements a drag and drop or select file selection, including preview.
MIT License
25 stars 11 forks source link

Double input visible #24

Open speedfl opened 6 years ago

speedfl commented 6 years ago

Hello

I don't understand but I have a double input (one with bootstrap style) and one with crappy style.

Version: 1.1.0

My code:

<div class="company-image">
         <img src="assets/images/profilePicture.png" *ngIf="!company.pictures || !company.pictures.originial"/>
         <div class="file-chooser">
           <ng2-file-input (OnRemoved)="OnRemoved($event)" (OnInvalidDenied)="OnInvalidDenied($event)" [drop-text]="'Glisser un fichier ici'"></ng2-file-input>
         </div>
       </div>

Generated code:

<ng2-file-input _ngcontent-c2="" ng-reflect-drop-text="Glisser un fichier ici"><div class="ng2-file-input">
                    <div class="ng2-file-input-invalid text-danger" hidden="">Mauvais choix</div>
                    <div class="ng2-file-input-drop-container" filedrop="" ng-reflect-klass="ng2-file-input-drop-container" ng-reflect-ng-class="[object Object]">
                        <span>Glisser un fichier ici</span>
                        <button class="btn btn-primary" type="button">Choisir</button>
                    </div>
                    <!--bindings={
  "ng-reflect-ng-if": "false"
}-->
                    <input type="file" accept="undefined">
                </div></ng2-file-input>

Render is file attached:

untitled