Skip to content

Instantly share code, notes, and snippets.

View 10Macit's full-sized avatar

Samet Macit 10Macit

  • Bulba
  • London
View GitHub Profile
struct MyContentView: View {
@StateObject var viewModel = EventStore()
var body: some View {
MyCalendarViewRepresentable(calendarView: viewModel.calendarView)
}
}
struct MyCalendarViewRepresentable: UIViewRepresentable {
@10Macit
10Macit / SingleStarView.swift
Created August 10, 2023 15:49
Single star view for SwiftUI
//
// RatingView.swift
// Bulba
//
// Created by Samet Macit on 9.08.2023.
//
import SwiftUI
struct SingleStarView: View {
@10Macit
10Macit / animation.json
Last active October 26, 2022 15:49
Animation
{"v":"5.9.6","fr":30,"ip":0,"op":61,"w":1290,"h":2796,"nm":"COFE App Splash - RS2022 - iOS - 1290X2796 - En","ddd":0,"assets":[{"id":"image_0","w":1800,"h":2546,"u":"","p":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAABwgAAAnyCAYAAADMpdSkAAAACXBIWXMAAAABAAAAAQBPJcTWAAAAJHpUWHRDcmVhdG9yAAAImXNMyU9KVXBMK0ktUnBNS0tNLikGAEF6Bs5qehXFAAAgAElEQVR4nOzd4XEjR5IG0CyF/g89ENeC4VogrAWiBwNZsDwLFrLg6MFiPKAsWMiCAy040IIDLcj70c0Vl0MOQaC6qwG8F8GYiBG7Kqu7wYjhp6yKAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA
class SelfSizingCollectionView: UICollectionView {
override init(frame: CGRect, collectionViewLayout layout: UICollectionViewLayout) {
super.init(frame: frame, collectionViewLayout: layout)
commonInit()
}
required init?(coder aDecoder: NSCoder) {
super.init(coder: aDecoder)
commonInit()
}
@10Macit
10Macit / PagingList.swift
Created June 19, 2019 20:10 — forked from srirammanian/PagingList.swift
Generic infinite paging list in SwiftUI
//
// PagingList.swift
//
// Created by Sriram Manian on 6/17/19.
// Copyright © 2019 Sriram Manian. All rights reserved.
//
import SwiftUI
import Combine
# "Türkiye plaka kodu için regular expression Swift 4.2"
# "99 X 9999", "99 X 99999"
# "99 XX 999", "99 XX 9999"
# "99 XXX 99", "99 XXX 999"
# "boşluk karakterleri silme"
let plate = self.plateStr.replacingOccurrences(of: " ", with: "").localizedUppercase
public static func isValidPlate(candidate: String) -> Bool {
let pattern = "(0[1-9]|[1-7][0-9]|8[01])(([A-Z])(\\d{4,5})|([A-Z]{2})(\\d{3,4})|([A-Z]{3})(\\d{2,3}))"
@10Macit
10Macit / location.php
Created June 19, 2016 15:37 — forked from ferdiunal/array2json.php
Ülkelerin İl, İlçeleri. Şimdilik Türkiye'yi ekleyebildim.
<?php
/**
* Created by PhpStorm.
* User: ferdiunal
* Date: 19.06.2016
* Time: 14:35
*/
return[
/***
* Turkey - Türkiye