Skip to content

Instantly share code, notes, and snippets.

View LukasCZ's full-sized avatar

Lukáš Petr LukasCZ

View GitHub Profile
@LukasCZ
LukasCZ / SwiftUI+tintedWidgets.swift
Created August 20, 2024 10:15
iOS 18 tintable widgets helper method
//
// SwiftUI+tintedWidgets.swift
// Timelines
//
// Created by Lukas Petr on 18.08.2024.
//
import SwiftUI
fileprivate struct LuminanceViewModifier: ViewModifier {
@LukasCZ
LukasCZ / gist:1e1da01102b22e112b9c34cbb3db16b8
Created September 6, 2023 15:27
Supporting iOS 17 widget environment variables on previous releases
//
// WidgetEnvironmentBackporting.swift
// Widget Extension
//
// Created by Lukas Petr on 06.09.2023.
// Copyright © 2023 Glimsoft. All rights reserved.
//
// This solution is heavily inspired by https://developer.apple.com/forums/thread/733780?answerId=759064022#759064022
// All credit should go to him.
@LukasCZ
LukasCZ / ComplicationController+helpers.swift
Created February 18, 2022 13:41
Helper methods for creating pixel-perfect complications for all Apple Watch sizes.
//
// ComplicationController+helpers.swift
// WatchKit Extension
//
// Created by Lukas Petr on 09.02.2022.
// Distributed under MIT License.
//
//
// Helper methods for creating pixel-perfect complications for all Apple Watch sizes.