Skip to content

Instantly share code, notes, and snippets.

@Ademking
Last active July 23, 2018 16:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Ademking/c92fa1c631c04a924ef0075bd69dcb60 to your computer and use it in GitHub Desktop.
Save Ademking/c92fa1c631c04a924ef0075bd69dcb60 to your computer and use it in GitHub Desktop.
πŸ’™ Ionic 3: Fabs with label

in SCSS add :


button[ion-fab] {
  overflow: visible;
  position: relative;

  ion-label {
      position: absolute;
      top: -8px;
      right: 40px;

      color: white;
      background-color: rgba(0,0,0,0.7);
      line-height: 24px;
      padding: 4px 8px;
      border-radius: 4px;
  }
}

.fab{
  contain: layout;
}

in your HTML add < ion-label >

<ion-fab-list side="top">

          <button ion-fab color="danger">
            <ion-icon name="information-circle"></ion-icon>
            <ion-label>TEXT HERE</ion-label>
          </button>
          
          <button ion-fab color="danger">
           ...
          </button>
          
        </ion-fab-list>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment