From e22acdc1a7703c39e321cc18c0275514da30a9c9 Mon Sep 17 00:00:00 2001 From: jay-jay-lama Date: Tue, 9 Sep 2025 20:49:28 +0200 Subject: [PATCH] Added an ability to return different view types for UI builders --- Sources/Public/Configurables/Public+CalendarConfig.swift | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Sources/Public/Configurables/Public+CalendarConfig.swift b/Sources/Public/Configurables/Public+CalendarConfig.swift index e64afb5..83f169f 100644 --- a/Sources/Public/Configurables/Public+CalendarConfig.swift +++ b/Sources/Public/Configurables/Public+CalendarConfig.swift @@ -60,13 +60,13 @@ public extension CalendarConfig { // MARK: - Custom Views public extension CalendarConfig { /// Replaces the default weekdays view with a selected implementation. - func weekdaysView(_ builder: @escaping () -> some WeekdaysView) -> Self { changing(path: \.weekdaysView, to: builder) } + func weekdaysView(_ builder: @escaping () -> any WeekdaysView) -> Self { changing(path: \.weekdaysView, to: builder) } /// Replaces the default month label with a selected implementation. - func monthLabel(_ builder: @escaping (Date) -> some MonthLabel) -> Self { changing(path: \.monthLabel, to: builder) } + func monthLabel(_ builder: @escaping (Date) -> any MonthLabel) -> Self { changing(path: \.monthLabel, to: builder) } /// Replaces the default day view with a selected implementation. - func dayView(_ builder: @escaping (Date, Bool, Binding?, Binding?) -> some DayView) -> Self { changing(path: \.dayView, to: builder) } + func dayView(_ builder: @escaping (Date, Bool, Binding?, Binding?) -> any DayView) -> Self { changing(path: \.dayView, to: builder) } } // MARK: - Modifiers