import 'package:freezed_annotation/freezed_annotation.dart'; part 'quick_link.freezed.dart'; /// Quick link type for navigation behavior. enum QuickLinkType { /// Opens in embedded iframe within the app. iframe, /// Opens in a new browser tab. newTab, } /// Quick link entity for Front Hall navigation. /// /// Represents a shortcut link that can either open embedded content /// in an iframe or navigate to an external URL in a new tab. @freezed sealed class QuickLink with _$QuickLink { const factory QuickLink({ /// Unique identifier. required String id, /// Display name. required String name, /// Target URL. required String url, /// Material icon name (e.g., 'home', 'settings', 'movie'). required String iconName, /// Category for grouping (e.g., 'Home', 'AMP', 'Coding', 'Infrastructure'). String? category, /// Navigation behavior type. @Default(QuickLinkType.iframe) QuickLinkType type, /// Sort order within category. @Default(0) int sortOrder, /// Whether the link is active/visible. @Default(true) bool isActive, }) = _QuickLink; const QuickLink._(); /// Whether this link opens in an iframe. bool get isIframe => type == QuickLinkType.iframe; /// Whether this link opens in a new tab. bool get isNewTab => type == QuickLinkType.newTab; }