[Add] YLProgressHUD 0.0.2
[CocoaPods.git] / Specs / 4 / 6 / 5 / RxMapKit / 1.0.0 / RxMapKit.podspec.json
blobea631a7f20bb7d6c694f301a6fafe17a2409fd70
2   "name": "RxMapKit",
3   "version": "1.0.0",
4   "summary": "RxSwift reactive wrapper for MapKit.",
5   "description": "# RxMapKit\n![Swift](https://img.shields.io/badge/Swift-3.0-orange.svg)\n\n\nRxMapKit is a [RxSwift](https://github.com/ReactiveX/RxSwift) wrapper for [MapKit](https://developer.apple.com/reference/mapkit)\n\n## Example Usages\n\n### Setup MKMapView\n```swift\n// Setup MKMapview from Interface Builder\n@IBOutlet weak var mapView: MKMapView!\n```\nor\n```swift\n// Setup MKMapview\nlet mapView = MKMapView(frame: self.view.bounds)\nself.view.addSubview(mapView)\n```\n\n### Observing properties\n```swift\n// Camera position\n\nmapView.rx.regionDidChange.asDriver()\n    .drive(onNext: { print(\"Did region change: ($0.region) isAnimated ($0.isAnimated)\") })\n    .addDisposableTo(disposeBag)\n\n// Marker tapped\n\nmapView.rx.didTapMarker.asDriver()\n    .drive(onNext: { print(\"Did tap marker: ($0)\") })\n    .addDisposableTo(disposeBag)\n\n// Update marker icon \n\nmapView.rx.didSelectAnnotationView.asDriver()\n    .drive(onNext: { $0.image = #imageLiteral(resourceName: \"marker_selected\") })\n    .addDisposableTo(disposeBag)\n\nmapView.rx.didDeselectAnnotationView.asDriver()\n    .drive(onNext: { $0.image = #imageLiteral(resourceName: \"marker_normal\") })\n    .addDisposableTo(disposeBag)\n                \n```\n\n### Binding properties\n```Swift\n// Camera animations\n\nbutton.rx.tap\n    .map { MKMapCamera(lookingAtCenter: center, fromDistance: 50000, pitch: 30, heading: 45) }\n    .bindTo(mapView.rx.cameraToAnimate)\n    .addDisposableTo(disposeBag)\n    \nbutton.rx.tap\n    .map { CLLocationCoordinate2D(latitude: 33.3659424, longitude: 126.3476852) }\n    .bindTo(mapView.rx.centerToAnimate)\n    .addDisposableTo(disposeBag)\n\nbutton.rx.tap\n    .map { [annotation0, annotaion1] }\n    .bindTo(mapView.rx.annotationsToShowToAnimate)\n    .addDisposableTo(disposeBag)\n\n// Properties\n\nbutton.rx.tap\n    .map { .satellite }\n    .bindTo(mapView.rx.mapType)\n    .addDisposableTo(disposeBag)\n    \nbutton.rx.tap\n    .map { false }\n    .bindTo(mapView.rx.showsTraffic)\n    .addDisposableTo(disposeBag)\n\n```\n\n### Delegates which have a return value\n```Swift\n//  func mapView(_ mapView: MKMapView, viewFor annotation: MKAnnotation) -> MKAnnotationView?\n\nmapView.rx.handleViewForAnnotation { (mapView, annotation) in\n    if let _ = annotation as? MKUserLocation {\n        return nil\n    } else {\n        let view = mapView.dequeueReusableAnnotationView(withIdentifier: \"reusableIdentifier\") ??\n            MKAnnotationView(annotation: annotation, reuseIdentifier: \"reusableIdentifier\")\n        view.image = #imageLiteral(resourceName: \"marker_normal\")\n        view.canShowCallout = true\n        return view\n    }\n}\n\n// func mapView(_ mapView: MKMapView, rendererFor overlay: MKOverlay) -> MKOverlayRenderer\n\nmapView.rx.handleRendererForOverlay { (mapView, overlay) in\n    if overlay is MKCircle {\n        let renderer = MKCircleRenderer(overlay: overlay)\n        renderer.strokeColor = UIColor.green.withAlphaComponent(0.8)\n        renderer.lineWidth = 4\n        renderer.fillColor = UIColor.green.withAlphaComponent(0.3)\n        return renderer\n    } else {\n        return MKOverlayRenderer(overlay: overlay)\n    }\n}\n\n```\n\n## Requirements\n\nRxMapKit requires Swift 3.0 and dedicated versions of RxSwift 3.0.0-beta.2 (Xcode8+ and iOS8+)\n\n## License\n\nMIT",
6   "homepage": "https://github.com/inkyfox/RxMapKit",
7   "license": "MIT",
8   "authors": {
9     "Yongha Yoo": "inkyfox@oo-v.com"
10   },
11   "source": {
12     "git": "https://github.com/inkyfox/RxMapKit.git",
13     "tag": "1.0.0"
14   },
15   "requires_arc": true,
16   "platforms": {
17     "ios": "8.0"
18   },
19   "source_files": "Sources/*.swift",
20   "dependencies": {
21     "RxSwift": [
22       "~> 3.0.0-beta.2"
23     ],
24     "RxCocoa": [
25       "~> 3.0.0-beta.2"
26     ]
27   },
28   "pod_target_xcconfig": {
29     "SWIFT_VERSION": "3.0"
30   }