├── .docs
├── favicon.ico
├── index.html
├── developer-og.jpg
├── images
│ ├── gif1.gif
│ └── gif2.gif
├── index
│ ├── data.mdb
│ ├── navigator.index
│ ├── availability.index
│ └── index.json
├── developer-og-twitter.jpg
├── metadata.json
├── img
│ ├── deprecated-icon.7bf1740a.svg
│ ├── added-icon.832a5d2c.svg
│ └── modified-icon.efb2697d.svg
├── js
│ ├── highlight-js-shell-js.0ad5b20f.js
│ ├── highlight-js-json-js.2a1856ba.js
│ ├── highlight-js-diff-js.4db9a783.js
│ ├── highlight-js-http-js.f78e83c2.js
│ ├── highlight-js-xml-js.0d78f903.js
│ ├── highlight-js-markdown-js.a2f456af.js
│ ├── highlight-js-java-js.4fe21e94.js
│ ├── highlight-js-llvm-js.26121771.js
│ ├── highlight-js-objectivec-js.74dea052.js
│ ├── highlight-js-bash-js.702f0c5c.js
│ ├── highlight-js-custom-markdown.78c9f6ed.js
│ ├── highlight-js-python-js.60354774.js
│ ├── highlight-js-ruby-js.7272231f.js
│ ├── highlight-js-c-js.063069d3.js
│ ├── highlight-js-php-js.c458ffa4.js
│ ├── highlight-js-perl-js.da6eda82.js
│ ├── highlight-js-cpp-js.458a9ae4.js
│ └── highlight-js-javascript-js.dfc9d16d.js
├── documentation
│ └── rangepicker
│ │ ├── index.html
│ │ ├── rangepickerview
│ │ ├── index.html
│ │ ├── delegate
│ │ │ └── index.html
│ │ ├── unitfont
│ │ │ └── index.html
│ │ ├── valuefont
│ │ │ └── index.html
│ │ ├── valuetype
│ │ │ └── index.html
│ │ ├── init(coder:)
│ │ │ └── index.html
│ │ ├── init(frame:)
│ │ │ └── index.html
│ │ ├── selectedindex
│ │ │ └── index.html
│ │ ├── unittextcolor
│ │ │ └── index.html
│ │ ├── valuetextcolor
│ │ │ └── index.html
│ │ ├── visibilityrange
│ │ │ └── index.html
│ │ ├── alignment-swift.enum
│ │ │ ├── index.html
│ │ │ ├── !=(_:_:)
│ │ │ │ └── index.html
│ │ │ ├── horizontal
│ │ │ │ └── index.html
│ │ │ ├── vertical
│ │ │ │ └── index.html
│ │ │ └── equatable-implementations
│ │ │ │ └── index.html
│ │ ├── alignment-swift.property
│ │ │ └── index.html
│ │ ├── selectrow(_:animated:)
│ │ │ └── index.html
│ │ └── seperatorbackgroundcolor
│ │ │ └── index.html
│ │ └── rangepickerviewdelegate
│ │ ├── index.html
│ │ ├── rangepickerview(_:didselectrow:)
│ │ └── index.html
│ │ ├── rangepickerview(_:numberofindicesat:)
│ │ └── index.html
│ │ ├── rangepickerview(_:titleforrowatindex:)
│ │ └── index.html
│ │ └── rangepickerview(_:headertitleindicesat:)
│ │ └── index.html
├── favicon.svg
├── data
│ └── documentation
│ │ ├── rangepicker.json
│ │ └── rangepicker
│ │ ├── rangepickerview
│ │ ├── init(frame:).json
│ │ ├── init(coder:).json
│ │ ├── unitfont.json
│ │ ├── valuefont.json
│ │ ├── selectedindex.json
│ │ ├── valuetype.json
│ │ ├── unittextcolor.json
│ │ ├── visibilityrange.json
│ │ ├── valuetextcolor.json
│ │ ├── alignment-swift.enum
│ │ │ ├── vertical.json
│ │ │ ├── horizontal.json
│ │ │ ├── equatable-implementations.json
│ │ │ └── !=(_:_:).json
│ │ ├── seperatorbackgroundcolor.json
│ │ ├── selectrow(_:animated:).json
│ │ ├── delegate.json
│ │ ├── alignment-swift.property.json
│ │ └── alignment-swift.enum.json
│ │ ├── rangepickerviewdelegate
│ │ ├── rangepickerview(_:didselectrow:).json
│ │ ├── rangepickerview(_:numberofindicesat:).json
│ │ ├── rangepickerview(_:titleforrowatindex:).json
│ │ └── rangepickerview(_:headertitleindicesat:).json
│ │ └── rangepickerviewdelegate.json
└── css
│ └── 675.40c3bcb2.css
├── Sample
└── Sample
│ ├── Sample
│ ├── Assets.xcassets
│ │ ├── Contents.json
│ │ ├── AccentColor.colorset
│ │ │ └── Contents.json
│ │ └── AppIcon.appiconset
│ │ │ └── Contents.json
│ ├── Info.plist
│ ├── ViewController.swift
│ ├── AppDelegate.swift
│ ├── Base.lproj
│ │ ├── LaunchScreen.storyboard
│ │ └── Main.storyboard
│ └── SceneDelegate.swift
│ └── Sample.xcodeproj
│ ├── project.xcworkspace
│ ├── contents.xcworkspacedata
│ └── xcshareddata
│ │ └── IDEWorkspaceChecks.plist
│ └── xcshareddata
│ └── xcschemes
│ └── Sample.xcscheme
├── Sources
└── RangePicker
│ ├── Documentation.docc
│ ├── Resources
│ │ ├── gif1.gif
│ │ └── gif2.gif
│ └── Documentation.md
│ ├── Alignment.swift
│ ├── RangePickerViewNib.swift
│ ├── RangePickerViewDataSource.swift
│ └── RangePickerView.swift
├── .swiftformat
├── Package.swift
├── Tests
└── RangePickerTests
│ └── RangePickerViewTests.swift
├── .github
└── workflows
│ └── docc.yml
├── LICENSE
├── .gitignore
└── README.md
/.docs/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mobven/RangePicker/HEAD/.docs/favicon.ico
--------------------------------------------------------------------------------
/.docs/index.html:
--------------------------------------------------------------------------------
1 |
2 |
--------------------------------------------------------------------------------
/.docs/developer-og.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mobven/RangePicker/HEAD/.docs/developer-og.jpg
--------------------------------------------------------------------------------
/.docs/images/gif1.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mobven/RangePicker/HEAD/.docs/images/gif1.gif
--------------------------------------------------------------------------------
/.docs/images/gif2.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mobven/RangePicker/HEAD/.docs/images/gif2.gif
--------------------------------------------------------------------------------
/.docs/index/data.mdb:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mobven/RangePicker/HEAD/.docs/index/data.mdb
--------------------------------------------------------------------------------
/.docs/index/navigator.index:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mobven/RangePicker/HEAD/.docs/index/navigator.index
--------------------------------------------------------------------------------
/.docs/developer-og-twitter.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mobven/RangePicker/HEAD/.docs/developer-og-twitter.jpg
--------------------------------------------------------------------------------
/.docs/index/availability.index:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mobven/RangePicker/HEAD/.docs/index/availability.index
--------------------------------------------------------------------------------
/.docs/metadata.json:
--------------------------------------------------------------------------------
1 | {"bundleDisplayName":"RangePicker","bundleIdentifier":"RangePicker","schemaVersion":{"patch":0,"major":0,"minor":1}}
--------------------------------------------------------------------------------
/Sample/Sample/Sample/Assets.xcassets/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "info" : {
3 | "author" : "xcode",
4 | "version" : 1
5 | }
6 | }
7 |
--------------------------------------------------------------------------------
/Sources/RangePicker/Documentation.docc/Resources/gif1.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mobven/RangePicker/HEAD/Sources/RangePicker/Documentation.docc/Resources/gif1.gif
--------------------------------------------------------------------------------
/Sources/RangePicker/Documentation.docc/Resources/gif2.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mobven/RangePicker/HEAD/Sources/RangePicker/Documentation.docc/Resources/gif2.gif
--------------------------------------------------------------------------------
/Sample/Sample/Sample.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/Sample/Sample/Sample/Assets.xcassets/AccentColor.colorset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "colors" : [
3 | {
4 | "idiom" : "universal"
5 | }
6 | ],
7 | "info" : {
8 | "author" : "xcode",
9 | "version" : 1
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/Sources/RangePicker/Documentation.docc/Documentation.md:
--------------------------------------------------------------------------------
1 | # ``RangePicker``
2 | ## Gifs
3 | |  |  |
4 | |:--------------------------------------------------:|:-----------------------------------:|
5 |
--------------------------------------------------------------------------------
/Sample/Sample/Sample/Assets.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "universal",
5 | "platform" : "ios",
6 | "size" : "1024x1024"
7 | }
8 | ],
9 | "info" : {
10 | "author" : "xcode",
11 | "version" : 1
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/Sample/Sample/Sample.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/.swiftformat:
--------------------------------------------------------------------------------
1 | # format options
2 | --importgrouping testable-bottom
3 | --maxwidth 120
4 | --wraparguments before-first
5 | --wrapparameters before-first
6 | --wrapcollections before-first
7 | --funcattributes same-line
8 | --typeattributes same-line
9 | --varattributes same-line
10 |
11 | # file options
12 | --exclude Build
13 |
14 | # rules
15 | --disable wrapMultilineStatementBraces, unusedArguments, trailingCommas
16 |
--------------------------------------------------------------------------------
/.docs/img/deprecated-icon.7bf1740a.svg:
--------------------------------------------------------------------------------
1 |
10 |
11 |
--------------------------------------------------------------------------------
/Package.swift:
--------------------------------------------------------------------------------
1 | // swift-tools-version: 5.8
2 |
3 | import PackageDescription
4 |
5 | let package = Package(
6 | name: "RangePicker",
7 | platforms: [.iOS(.v11)],
8 | products: [
9 | .library(
10 | name: "RangePicker",
11 | targets: ["RangePicker"]
12 | )
13 | ],
14 | dependencies: [],
15 | targets: [
16 | .target(
17 | name: "RangePicker",
18 | dependencies: []
19 | ),
20 | .testTarget(
21 | name: "RangePickerTests",
22 | dependencies: ["RangePicker"]
23 | )
24 | ]
25 | )
26 |
--------------------------------------------------------------------------------
/.docs/img/added-icon.832a5d2c.svg:
--------------------------------------------------------------------------------
1 |
10 |
11 |
--------------------------------------------------------------------------------
/.docs/js/highlight-js-shell-js.0ad5b20f.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * This source file is part of the Swift.org open source project
3 | *
4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors
5 | * Licensed under Apache License v2.0 with Runtime Library Exception
6 | *
7 | * See https://swift.org/LICENSE.txt for license information
8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors
9 | */
10 | (self["webpackChunkswift_docc_render"]=self["webpackChunkswift_docc_render"]||[]).push([[176],{7874:function(s){function e(s){return{name:"Shell Session",aliases:["console","shellsession"],contains:[{className:"meta",begin:/^\s{0,3}[/~\w\d[\]()@-]*[>%$#][ ]?/,starts:{end:/[^\\](?=\s*$)/,subLanguage:"bash"}}]}}s.exports=e}}]);
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/index.html:
--------------------------------------------------------------------------------
1 |
Documentation
--------------------------------------------------------------------------------
/Sources/RangePicker/Alignment.swift:
--------------------------------------------------------------------------------
1 | //
2 | // Alignment.swift
3 | // RangePicker
4 | //
5 | // Created by Rashid Ramazanov on 21.06.2023.
6 | //
7 |
8 | import Foundation
9 |
10 | public extension RangePickerView {
11 | enum Alignment {
12 | case horizontal, vertical
13 | var angle: CGFloat {
14 | switch self {
15 | case .horizontal: return -90 / 180.0 * CGFloat.pi
16 | case .vertical: return 90 / 180.0 * CGFloat.pi
17 | }
18 | }
19 |
20 | var rotationAngle: CGFloat {
21 | switch self {
22 | case .horizontal: return CGFloat.pi / 2
23 | case .vertical: return CGFloat.pi * 2
24 | }
25 | }
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/delegate/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/unitfont/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/valuefont/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/valuetype/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerviewdelegate/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/init(coder:)/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/init(frame:)/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/selectedindex/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/unittextcolor/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/valuetextcolor/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/visibilityrange/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/alignment-swift.enum/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/alignment-swift.property/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/selectrow(_:animated:)/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/seperatorbackgroundcolor/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/alignment-swift.enum/!=(_:_:)/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/alignment-swift.enum/horizontal/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/alignment-swift.enum/vertical/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerviewdelegate/rangepickerview(_:didselectrow:)/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerview/alignment-swift.enum/equatable-implementations/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerviewdelegate/rangepickerview(_:numberofindicesat:)/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerviewdelegate/rangepickerview(_:titleforrowatindex:)/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/.docs/documentation/rangepicker/rangepickerviewdelegate/rangepickerview(_:headertitleindicesat:)/index.html:
--------------------------------------------------------------------------------
1 | Documentation
--------------------------------------------------------------------------------
/Sample/Sample/Sample/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | UIApplicationSceneManifest
6 |
7 | UIApplicationSupportsMultipleScenes
8 |
9 | UISceneConfigurations
10 |
11 | UIWindowSceneSessionRoleApplication
12 |
13 |
14 | UISceneConfigurationName
15 | Default Configuration
16 | UISceneDelegateClassName
17 | $(PRODUCT_MODULE_NAME).SceneDelegate
18 | UISceneStoryboardFile
19 | Main
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/.docs/js/highlight-js-json-js.2a1856ba.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * This source file is part of the Swift.org open source project
3 | *
4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors
5 | * Licensed under Apache License v2.0 with Runtime Library Exception
6 | *
7 | * See https://swift.org/LICENSE.txt for license information
8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors
9 | */
10 | (self["webpackChunkswift_docc_render"]=self["webpackChunkswift_docc_render"]||[]).push([[82],{14:function(e){function n(e){const n={className:"attr",begin:/"(\\.|[^\\"\r\n])*"(?=\s*:)/,relevance:1.01},c={match:/[{}[\],:]/,className:"punctuation",relevance:0},a={beginKeywords:["true","false","null"].join(" ")};return{name:"JSON",contains:[n,c,e.QUOTE_STRING_MODE,a,e.C_NUMBER_MODE,e.C_LINE_COMMENT_MODE,e.C_BLOCK_COMMENT_MODE],illegal:"\\S"}}e.exports=n}}]);
--------------------------------------------------------------------------------
/.docs/js/highlight-js-diff-js.4db9a783.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * This source file is part of the Swift.org open source project
3 | *
4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors
5 | * Licensed under Apache License v2.0 with Runtime Library Exception
6 | *
7 | * See https://swift.org/LICENSE.txt for license information
8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors
9 | */
10 | (self["webpackChunkswift_docc_render"]=self["webpackChunkswift_docc_render"]||[]).push([[213],{7731:function(e){function n(e){const n=e.regex;return{name:"Diff",aliases:["patch"],contains:[{className:"meta",relevance:10,match:n.either(/^@@ +-\d+,\d+ +\+\d+,\d+ +@@/,/^\*\*\* +\d+,\d+ +\*\*\*\*$/,/^--- +\d+,\d+ +----$/)},{className:"comment",variants:[{begin:n.either(/Index: /,/^index/,/={3,}/,/^-{3}/,/^\*{3} /,/^\+{3}/,/^diff --git/),end:/$/},{match:/^\*{15}$/}]},{className:"addition",begin:/^\+/,end:/$/},{className:"deletion",begin:/^-/,end:/$/},{className:"addition",begin:/^!/,end:/$/}]}}e.exports=n}}]);
--------------------------------------------------------------------------------
/Tests/RangePickerTests/RangePickerViewTests.swift:
--------------------------------------------------------------------------------
1 | //
2 | // RangePickerViewTests.swift
3 | // RangePickerTests
4 | //
5 | // Created by Rashid Ramazanov on 21.06.2023.
6 | //
7 |
8 | import XCTest
9 | @testable import RangePicker
10 |
11 | final class RangePickerViewTests: XCTestCase {
12 | var sut: RangePickerView!
13 |
14 | override func setUp() {
15 | sut = .init()
16 | }
17 |
18 | func testAlignment() {
19 | setAlignment(.horizontal)
20 | // Test whether resetting does not changes orientation
21 | setAlignment(.horizontal)
22 |
23 | sut.alignment = .vertical
24 | }
25 |
26 | private func setAlignment(_ alignment: RangePickerView.Alignment) {
27 | sut.alignment = alignment
28 | XCTAssertEqual(sut.alignment, alignment)
29 | XCTAssertEqual(sut.mAlignment, alignment)
30 | XCTAssertEqual(sut.transform, .init(rotationAngle: alignment.angle))
31 | XCTAssertEqual(sut.valueView.transform, .init(rotationAngle: alignment.rotationAngle))
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/.github/workflows/docc.yml:
--------------------------------------------------------------------------------
1 | #1
2 | name: docc
3 |
4 | #2
5 | on:
6 | push:
7 | branches: [main]
8 | workflow_dispatch:
9 |
10 | #3
11 | permissions:
12 | pages: write
13 | id-token: write
14 | contents: read
15 |
16 | #1
17 | jobs:
18 | build:
19 | #2
20 | runs-on: macos-12
21 | #3
22 | steps:
23 | - name: Checkout Repository
24 | uses: actions/checkout@v3
25 | with:
26 | fetch-depth: 0
27 | #4
28 | - name: Run Build Docs
29 | run: ./build-docc.sh
30 | #5
31 | - name: Setup Pages
32 | id: pages
33 | uses: actions/configure-pages@v3
34 | - name: Upload artifact
35 | uses: actions/upload-pages-artifact@v1
36 | with:
37 | path: .docs
38 |
39 | #1
40 | deploy:
41 | #2
42 | runs-on: ubuntu-latest
43 | #3
44 | needs: build
45 | #4
46 | steps:
47 | - name: Deploy to GitHub Pages
48 | id: deployment
49 | uses: actions/deploy-pages@v2
50 | environment:
51 | name: github-pages
52 | url: ${{ steps.deployment.outputs.page_url }}
53 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2023 Mobven
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/.docs/img/modified-icon.efb2697d.svg:
--------------------------------------------------------------------------------
1 |
10 |
11 |
--------------------------------------------------------------------------------
/.docs/js/highlight-js-http-js.f78e83c2.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * This source file is part of the Swift.org open source project
3 | *
4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors
5 | * Licensed under Apache License v2.0 with Runtime Library Exception
6 | *
7 | * See https://swift.org/LICENSE.txt for license information
8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors
9 | */
10 | (self["webpackChunkswift_docc_render"]=self["webpackChunkswift_docc_render"]||[]).push([[878],{8937:function(e){function n(e){const n=e.regex,a="HTTP/(2|1\\.[01])",s=/[A-Za-z][A-Za-z0-9-]*/,t={className:"attribute",begin:n.concat("^",s,"(?=\\:\\s)"),starts:{contains:[{className:"punctuation",begin:/: /,relevance:0,starts:{end:"$",relevance:0}}]}},i=[t,{begin:"\\n\\n",starts:{subLanguage:[],endsWithParent:!0}}];return{name:"HTTP",aliases:["https"],illegal:/\S/,contains:[{begin:"^(?="+a+" \\d{3})",end:/$/,contains:[{className:"meta",begin:a},{className:"number",begin:"\\b\\d{3}\\b"}],starts:{end:/\b\B/,illegal:/\S/,contains:i}},{begin:"(?=^[A-Z]+ (.*?) "+a+"$)",end:/$/,contains:[{className:"string",begin:" ",end:" ",excludeBegin:!0,excludeEnd:!0},{className:"meta",begin:a},{className:"keyword",begin:"[A-Z]+"}],starts:{end:/\b\B/,illegal:/\S/,contains:i}},e.inherit(t,{relevance:0})]}}e.exports=n}}]);
--------------------------------------------------------------------------------
/Sample/Sample/Sample/ViewController.swift:
--------------------------------------------------------------------------------
1 | //
2 | // ViewController.swift
3 | // Sample
4 | //
5 | // Created by Cem Eke on 20.06.2023.
6 | //
7 |
8 | import RangePicker
9 | import UIKit
10 |
11 | class ViewController: UIViewController {
12 | @IBOutlet var rangePickerView: RangePickerView!
13 | var values = Array(1 ... 100)
14 |
15 | override func viewDidLoad() {
16 | super.viewDidLoad()
17 | rangePickerView.delegate = self
18 | rangePickerView.alignment = .horizontal
19 | rangePickerView.valueType = "kg"
20 | }
21 |
22 | @IBAction func changePickerAlignment(_ sender: UISwitch) {
23 | rangePickerView.alignment = sender.isOn ? .horizontal : .vertical
24 | }
25 | }
26 |
27 | extension ViewController: RangePickerViewDelegate {
28 | func rangePickerView(_ rangePickerView: RangePickerView, titleForRowAtIndex row: Int) -> String? {
29 | String(values[row])
30 | }
31 |
32 | func rangePickerView(_ rangePickerView: RangePickerView, didSelectRow row: Int) {}
33 |
34 | func rangePickerView(_ rangePickerView: RangePickerView, numberOfIndicesAt row: Int) -> Int? {
35 | values.count
36 | }
37 |
38 | func rangePickerView(_ rangePickerView: RangePickerView, headerTitleIndicesAt row: Int) -> String? {
39 | String(values[row])
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/.docs/favicon.svg:
--------------------------------------------------------------------------------
1 |
10 |
11 |
--------------------------------------------------------------------------------
/Sample/Sample/Sample/AppDelegate.swift:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate.swift
3 | // Sample
4 | //
5 | // Created by Cem Eke on 20.06.2023.
6 | //
7 |
8 | import UIKit
9 |
10 | @main class AppDelegate: UIResponder, UIApplicationDelegate {
11 | func application(
12 | _ application: UIApplication,
13 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
14 | ) -> Bool {
15 | // Override point for customization after application launch.
16 | true
17 | }
18 |
19 | // MARK: UISceneSession Lifecycle
20 |
21 | func application(
22 | _ application: UIApplication,
23 | configurationForConnecting connectingSceneSession: UISceneSession,
24 | options: UIScene.ConnectionOptions
25 | ) -> UISceneConfiguration {
26 | // Called when a new scene session is being created.
27 | // Use this method to select a configuration to create the new scene with.
28 | UISceneConfiguration(name: "Default Configuration", sessionRole: connectingSceneSession.role)
29 | }
30 |
31 | func application(_ application: UIApplication, didDiscardSceneSessions sceneSessions: Set) {
32 | // Called when the user discards a scene session.
33 | // If any sessions were discarded while the application was not running, this will be called shortly after
34 | // application:didFinishLaunchingWithOptions.
35 | // Use this method to release any resources that were specific to the discarded scenes, as they will not return.
36 | }
37 | }
38 |
--------------------------------------------------------------------------------
/Sample/Sample/Sample/Base.lproj/LaunchScreen.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/Sources/RangePicker/RangePickerViewNib.swift:
--------------------------------------------------------------------------------
1 | //
2 | // RangePickerViewNib.swift
3 | // RangePickerView
4 | //
5 | // Created by Rashid Ramazanov on 8/15/22.
6 | // Copyright © 2022 Mobven. All rights reserved.
7 | //
8 |
9 | import Foundation
10 | import UIKit
11 |
12 | extension RangePickerView {
13 | func setupNib() {
14 | let view = fromNib()
15 | addSubview(pinningView: view)
16 | view.backgroundColor = .clear
17 | view.frame = bounds
18 | view.autoresizingMask = [.flexibleWidth, .flexibleHeight]
19 | }
20 |
21 | func fromNib() -> UIView {
22 | guard let nibName = type(of: self).description().components(separatedBy: ".").last else {
23 | fatalError("nibName not found")
24 | }
25 |
26 | let nib = UINib(nibName: nibName, bundle: Bundle.module)
27 |
28 | guard let view = nib.instantiate(withOwner: self, options: nil).first as? UIView else {
29 | fatalError("View not found")
30 | }
31 |
32 | return view
33 | }
34 | }
35 |
36 | extension UIView {
37 | /// Add subview to view and set constraints to fit all bounds.
38 | /// - Parameter view: To be added as subview.
39 | func addSubview(pinningView view: UIView) {
40 | view.translatesAutoresizingMaskIntoConstraints = false
41 | addSubview(view)
42 | view.pinView(self)
43 | }
44 |
45 | /// Sets constraints the specified view to fit all bounds.
46 | /// - Parameter view: To set constraints on.
47 | func pinView(_ view: UIView, top: CGFloat = 0, leading: CGFloat = 0, trailing: CGFloat = 0, bottom: CGFloat = 0) {
48 | NSLayoutConstraint.activate([
49 | leadingAnchor.constraint(equalTo: view.leadingAnchor, constant: leading),
50 | trailingAnchor.constraint(equalTo: view.trailingAnchor, constant: trailing),
51 | topAnchor.constraint(equalTo: view.topAnchor, constant: top),
52 | bottomAnchor.constraint(equalTo: view.bottomAnchor, constant: bottom)
53 | ])
54 | }
55 | }
56 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Xcode
2 | #
3 | # gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore
4 |
5 | ## Build generated
6 | build/
7 | DerivedData/
8 | .derivedData
9 | FeedbackReporterIOS/DrivedData
10 | *.ipa
11 | *.app.dSYM.zip
12 |
13 | ## Various settings
14 | *.pbxuser
15 | !default.pbxuser
16 | *.mode1v3
17 | !default.mode1v3
18 | *.mode2v3
19 | !default.mode2v3
20 | *.perspectivev3
21 | !default.perspectivev3
22 | xcuserdata/
23 |
24 | ## Other
25 | *.moved-aside
26 | *.xccheckout
27 | *.xcscmblueprint
28 |
29 | ## Obj-C/Swift specific
30 | *.hmap
31 | *.ipa
32 | *.dSYM.zip
33 | *.dSYM
34 |
35 | ## Playgrounds
36 | timeline.xctimeline
37 | playground.xcworkspace
38 |
39 | # Swift Package Manager
40 | #
41 | # Add this line if you want to avoid checking in source code from Swift Package Manager dependencies.
42 | # Packages/
43 | # Package.pins
44 | # Package.resolved
45 | # *.xcodeproj
46 | #
47 | # Xcode automatically generates this directory with a .xcworkspacedata file and xcuserdata
48 | # hence it is not needed unless you have added a package configuration file to your project
49 | .swiftpm
50 |
51 | .build/
52 |
53 | # CocoaPods
54 | #
55 | # We recommend against adding the Pods directory to your .gitignore. However
56 | # you should judge for yourself, the pros and cons are mentioned at:
57 | # https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control
58 | #
59 | Pods/
60 |
61 | # Carthage
62 | #
63 | # Add this line if you want to avoid checking in source code from Carthage dependencies.
64 | # Carthage/Checkouts
65 |
66 | Carthage/Build
67 | vendor
68 |
69 | # fastlane
70 | #
71 | # It is recommended to not store the screenshots in the git repo.
72 | # Instead, use fastlane to re-generate the screenshots whenever they are needed.
73 | # For more information about the recommended setup visit:
74 | # https://docs.fastlane.tools/best-practices/source-control/#source-control
75 |
76 | fastlane/report.xml
77 | fastlane/Preview.html
78 | fastlane/screenshots
79 | fastlane/test_output
80 | .DS_Store
81 | fastlane/README.md
82 | reports/
83 | firebase-debug.log
84 | Gemfile.lock
85 | fastlane/Matchfile
86 |
--------------------------------------------------------------------------------
/.docs/js/highlight-js-xml-js.0d78f903.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * This source file is part of the Swift.org open source project
3 | *
4 | * Copyright (c) 2021 Apple Inc. and the Swift project authors
5 | * Licensed under Apache License v2.0 with Runtime Library Exception
6 | *
7 | * See https://swift.org/LICENSE.txt for license information
8 | * See https://swift.org/CONTRIBUTORS.txt for Swift project authors
9 | */
10 | (self["webpackChunkswift_docc_render"]=self["webpackChunkswift_docc_render"]||[]).push([[490],{4610:function(e){function n(e){const n=e.regex,a=n.concat(/[A-Z_]/,n.optional(/[A-Z0-9_.-]*:/),/[A-Z0-9_.-]*/),s=/[A-Za-z0-9._:-]+/,t={className:"symbol",begin:/&[a-z]+;|[0-9]+;|[a-f0-9]+;/},c={begin:/\s/,contains:[{className:"keyword",begin:/#?[a-z_][a-z1-9_-]+/,illegal:/\n/}]},i=e.inherit(c,{begin:/\(/,end:/\)/}),l=e.inherit(e.APOS_STRING_MODE,{className:"string"}),r=e.inherit(e.QUOTE_STRING_MODE,{className:"string"}),g={endsWithParent:!0,illegal:/,relevance:0,contains:[{className:"attr",begin:s,relevance:0},{begin:/=\s*/,relevance:0,contains:[{className:"string",endsParent:!0,variants:[{begin:/"/,end:/"/,contains:[t]},{begin:/'/,end:/'/,contains:[t]},{begin:/[^\s"'=<>`]+/}]}]}]};return{name:"HTML, XML",aliases:["html","xhtml","rss","atom","xjb","xsd","xsl","plist","wsf","svg"],case_insensitive:!0,contains:[{className:"meta",begin://,relevance:10,contains:[c,r,l,i,{begin:/\[/,end:/\]/,contains:[{className:"meta",begin://,contains:[c,i,r,l]}]}]},e.COMMENT(//,{relevance:10}),{begin://,relevance:10},t,{className:"meta",begin:/<\?xml/,end:/\?>/,relevance:10},{className:"tag",begin:/