Back to Library
Floating Action Button

Floating Action Button

by Luiz Mello

@luizmellodev
buttonfabmenuanimationinteraction

Description

Elegant FAB with expandable menu of actions. Features smooth animations, customizable positions (all corners), labels, overlay backdrop, and Speed Dial variant. Perfect for quick actions in your app.

SwiftUI Code

6 files • Scroll to see all →
public struct FABActionItem: Identifiable {
    public let id = UUID()
    let icon: String
    let label: String
    let color: Color
    let action: () -> Void
    
    public init(
        icon: String,
        label: String,
        color: Color = .blue,
        action: @escaping () -> Void
    ) {
        self.icon = icon
        self.label = label
        self.color = color
        self.action = action
    }
}
Viewing: FABActionItem.swift1 of 6