Skip to content

Commit 0d8feb0

Browse files
author
Athul Sai
committed
Added verification code view and fixed issue #1
1 parent 514f791 commit 0d8feb0

24 files changed

Lines changed: 807 additions & 357 deletions

.DS_Store

2 KB
Binary file not shown.

.gitignore

Lines changed: 8 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1+
# Mac OS X
2+
.DS_Store
3+
14
# Xcode
2-
#
3-
# gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore
45

56
## Build generated
67
build/
7-
DerivedData/
8+
DerivedData
89

910
## Various settings
1011
*.pbxuser
@@ -15,51 +16,24 @@ DerivedData/
1516
!default.mode2v3
1617
*.perspectivev3
1718
!default.perspectivev3
18-
xcuserdata/
19+
xcuserdata
1920

2021
## Other
22+
*.xccheckout
2123
*.moved-aside
2224
*.xcuserstate
25+
*.xcscmblueprint
2326

2427
## Obj-C/Swift specific
2528
*.hmap
2629
*.ipa
27-
*.dSYM.zip
28-
*.dSYM
2930

3031
## Playgrounds
3132
timeline.xctimeline
3233
playground.xcworkspace
3334

3435
# Swift Package Manager
35-
#
36-
# Add this line if you want to avoid checking in source code from Swift Package Manager dependencies.
37-
# Packages/
3836
.build/
3937

40-
# CocoaPods
41-
#
42-
# We recommend against adding the Pods directory to your .gitignore. However
43-
# you should judge for yourself, the pros and cons are mentioned at:
44-
# https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control
45-
#
46-
# Pods/
47-
4838
# Carthage
49-
#
50-
# Add this line if you want to avoid checking in source code from Carthage dependencies.
51-
# Carthage/Checkouts
52-
53-
Carthage/Build
54-
55-
# fastlane
56-
#
57-
# It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the
58-
# screenshots whenever they are needed.
59-
# For more information about the recommended setup visit:
60-
# https://github.com/fastlane/fastlane/blob/master/fastlane/docs/Gitignore.md
61-
62-
fastlane/report.xml
63-
fastlane/Preview.html
64-
fastlane/screenshots
65-
fastlane/test_output
39+
Carthage/Build

Example/KWVerificationCodeView.xcodeproj/project.pbxproj

Lines changed: 31 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
2CA88CD58398C2B419E9B36C /* Pods_KWVerificationCodeView_Tests.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C68BD3F967305D340EA20FFD /* Pods_KWVerificationCodeView_Tests.framework */; };
1111
2DB200677C25A654990BA580 /* Pods_KWVerificationCodeView_Example.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 29FC60609011D27ACC17DB2A /* Pods_KWVerificationCodeView_Example.framework */; };
1212
607FACD61AFB9204008FA782 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 607FACD51AFB9204008FA782 /* AppDelegate.swift */; };
13-
607FACD81AFB9204008FA782 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 607FACD71AFB9204008FA782 /* ViewController.swift */; };
13+
607FACD81AFB9204008FA782 /* VerificationCodeViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 607FACD71AFB9204008FA782 /* VerificationCodeViewController.swift */; };
1414
607FACDB1AFB9204008FA782 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 607FACD91AFB9204008FA782 /* Main.storyboard */; };
1515
607FACDD1AFB9204008FA782 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 607FACDC1AFB9204008FA782 /* Images.xcassets */; };
1616
607FACE01AFB9204008FA782 /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 607FACDE1AFB9204008FA782 /* LaunchScreen.xib */; };
@@ -33,7 +33,7 @@
3333
607FACD01AFB9204008FA782 /* KWVerificationCodeView_Example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = KWVerificationCodeView_Example.app; sourceTree = BUILT_PRODUCTS_DIR; };
3434
607FACD41AFB9204008FA782 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
3535
607FACD51AFB9204008FA782 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
36-
607FACD71AFB9204008FA782 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = "<group>"; };
36+
607FACD71AFB9204008FA782 /* VerificationCodeViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = VerificationCodeViewController.swift; sourceTree = "<group>"; };
3737
607FACDA1AFB9204008FA782 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; };
3838
607FACDC1AFB9204008FA782 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = "<group>"; };
3939
607FACDF1AFB9204008FA782 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = "<group>"; };
@@ -84,7 +84,7 @@
8484
isa = PBXGroup;
8585
children = (
8686
607FACF51AFB993E008FA782 /* Podspec Metadata */,
87-
607FACD21AFB9204008FA782 /* Example for KWVerificationCodeView */,
87+
607FACD21AFB9204008FA782 /* Example */,
8888
607FACE81AFB9204008FA782 /* Tests */,
8989
607FACD11AFB9204008FA782 /* Products */,
9090
5BDB25E32F432AA3094DB5BE /* Pods */,
@@ -101,17 +101,17 @@
101101
name = Products;
102102
sourceTree = "<group>";
103103
};
104-
607FACD21AFB9204008FA782 /* Example for KWVerificationCodeView */ = {
104+
607FACD21AFB9204008FA782 /* Example */ = {
105105
isa = PBXGroup;
106106
children = (
107107
607FACD51AFB9204008FA782 /* AppDelegate.swift */,
108-
607FACD71AFB9204008FA782 /* ViewController.swift */,
108+
607FACD71AFB9204008FA782 /* VerificationCodeViewController.swift */,
109109
607FACD91AFB9204008FA782 /* Main.storyboard */,
110110
607FACDC1AFB9204008FA782 /* Images.xcassets */,
111111
607FACDE1AFB9204008FA782 /* LaunchScreen.xib */,
112112
607FACD31AFB9204008FA782 /* Supporting Files */,
113113
);
114-
name = "Example for KWVerificationCodeView";
114+
name = Example;
115115
path = KWVerificationCodeView;
116116
sourceTree = "<group>";
117117
};
@@ -210,15 +210,17 @@
210210
isa = PBXProject;
211211
attributes = {
212212
LastSwiftUpdateCheck = 0720;
213-
LastUpgradeCheck = 0720;
213+
LastUpgradeCheck = 0820;
214214
ORGANIZATIONNAME = CocoaPods;
215215
TargetAttributes = {
216216
607FACCF1AFB9204008FA782 = {
217217
CreatedOnToolsVersion = 6.3.1;
218+
DevelopmentTeam = MJQV7AA4JY;
218219
LastSwiftMigration = 0820;
219220
};
220221
607FACE41AFB9204008FA782 = {
221222
CreatedOnToolsVersion = 6.3.1;
223+
DevelopmentTeam = MJQV7AA4JY;
222224
LastSwiftMigration = 0820;
223225
TestTargetID = 607FACCF1AFB9204008FA782;
224226
};
@@ -361,7 +363,7 @@
361363
isa = PBXSourcesBuildPhase;
362364
buildActionMask = 2147483647;
363365
files = (
364-
607FACD81AFB9204008FA782 /* ViewController.swift in Sources */,
366+
607FACD81AFB9204008FA782 /* VerificationCodeViewController.swift in Sources */,
365367
607FACD61AFB9204008FA782 /* AppDelegate.swift in Sources */,
366368
);
367369
runOnlyForDeploymentPostprocessing = 0;
@@ -417,8 +419,10 @@
417419
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
418420
CLANG_WARN_EMPTY_BODY = YES;
419421
CLANG_WARN_ENUM_CONVERSION = YES;
422+
CLANG_WARN_INFINITE_RECURSION = YES;
420423
CLANG_WARN_INT_CONVERSION = YES;
421424
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
425+
CLANG_WARN_SUSPICIOUS_MOVE = YES;
422426
CLANG_WARN_UNREACHABLE_CODE = YES;
423427
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
424428
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
@@ -441,7 +445,7 @@
441445
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
442446
GCC_WARN_UNUSED_FUNCTION = YES;
443447
GCC_WARN_UNUSED_VARIABLE = YES;
444-
IPHONEOS_DEPLOYMENT_TARGET = 8.3;
448+
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
445449
MTL_ENABLE_DEBUG_INFO = YES;
446450
ONLY_ACTIVE_ARCH = YES;
447451
SDKROOT = iphoneos;
@@ -462,8 +466,10 @@
462466
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
463467
CLANG_WARN_EMPTY_BODY = YES;
464468
CLANG_WARN_ENUM_CONVERSION = YES;
469+
CLANG_WARN_INFINITE_RECURSION = YES;
465470
CLANG_WARN_INT_CONVERSION = YES;
466471
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
472+
CLANG_WARN_SUSPICIOUS_MOVE = YES;
467473
CLANG_WARN_UNREACHABLE_CODE = YES;
468474
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
469475
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
@@ -479,9 +485,10 @@
479485
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
480486
GCC_WARN_UNUSED_FUNCTION = YES;
481487
GCC_WARN_UNUSED_VARIABLE = YES;
482-
IPHONEOS_DEPLOYMENT_TARGET = 8.3;
488+
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
483489
MTL_ENABLE_DEBUG_INFO = NO;
484490
SDKROOT = iphoneos;
491+
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
485492
VALIDATE_PRODUCT = YES;
486493
};
487494
name = Release;
@@ -490,38 +497,44 @@
490497
isa = XCBuildConfiguration;
491498
baseConfigurationReference = D51BF4885572F8FECD1E4AF7 /* Pods-KWVerificationCodeView_Example.debug.xcconfig */;
492499
buildSettings = {
500+
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
493501
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
502+
DEVELOPMENT_TEAM = MJQV7AA4JY;
494503
INFOPLIST_FILE = KWVerificationCodeView/Info.plist;
504+
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
495505
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
496506
MODULE_NAME = ExampleApp;
497-
PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.$(PRODUCT_NAME:rfc1034identifier)";
507+
PRODUCT_BUNDLE_IDENTIFIER = "com.keepworks.KWVerificationCodeView-Example";
498508
PRODUCT_NAME = "$(TARGET_NAME)";
499509
SWIFT_VERSION = 3.0;
510+
TARGETED_DEVICE_FAMILY = "1,2";
500511
};
501512
name = Debug;
502513
};
503514
607FACF11AFB9204008FA782 /* Release */ = {
504515
isa = XCBuildConfiguration;
505516
baseConfigurationReference = 7DA49E735ED3B0C245F0B8C7 /* Pods-KWVerificationCodeView_Example.release.xcconfig */;
506517
buildSettings = {
518+
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
507519
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
520+
DEVELOPMENT_TEAM = MJQV7AA4JY;
508521
INFOPLIST_FILE = KWVerificationCodeView/Info.plist;
522+
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
509523
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
510524
MODULE_NAME = ExampleApp;
511-
PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.demo.$(PRODUCT_NAME:rfc1034identifier)";
525+
PRODUCT_BUNDLE_IDENTIFIER = "com.keepworks.KWVerificationCodeView-Example";
512526
PRODUCT_NAME = "$(TARGET_NAME)";
513527
SWIFT_VERSION = 3.0;
528+
TARGETED_DEVICE_FAMILY = "1,2";
514529
};
515530
name = Release;
516531
};
517532
607FACF31AFB9204008FA782 /* Debug */ = {
518533
isa = XCBuildConfiguration;
519534
baseConfigurationReference = 423112B5C6F551741EC3F015 /* Pods-KWVerificationCodeView_Tests.debug.xcconfig */;
520535
buildSettings = {
521-
FRAMEWORK_SEARCH_PATHS = (
522-
"$(SDKROOT)/Developer/Library/Frameworks",
523-
"$(inherited)",
524-
);
536+
DEVELOPMENT_TEAM = MJQV7AA4JY;
537+
FRAMEWORK_SEARCH_PATHS = "$(inherited)";
525538
GCC_PREPROCESSOR_DEFINITIONS = (
526539
"DEBUG=1",
527540
"$(inherited)",
@@ -538,10 +551,8 @@
538551
isa = XCBuildConfiguration;
539552
baseConfigurationReference = 8F723ADDC751FC9CC3C9BE34 /* Pods-KWVerificationCodeView_Tests.release.xcconfig */;
540553
buildSettings = {
541-
FRAMEWORK_SEARCH_PATHS = (
542-
"$(SDKROOT)/Developer/Library/Frameworks",
543-
"$(inherited)",
544-
);
554+
DEVELOPMENT_TEAM = MJQV7AA4JY;
555+
FRAMEWORK_SEARCH_PATHS = "$(inherited)";
545556
INFOPLIST_FILE = Tests/Info.plist;
546557
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
547558
PRODUCT_BUNDLE_IDENTIFIER = "org.cocoapods.$(PRODUCT_NAME:rfc1034identifier)";

Example/KWVerificationCodeView.xcodeproj/xcshareddata/xcschemes/KWVerificationCodeView-Example.xcscheme

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<Scheme
3-
LastUpgradeVersion = "0720"
3+
LastUpgradeVersion = "0820"
44
version = "1.3">
55
<BuildAction
66
parallelizeBuildables = "YES"

Example/KWVerificationCodeView/AppDelegate.swift

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
// KWVerificationCodeView
44
//
55
// Created by Athul Sai on 01/10/2017.
6-
// Copyright (c) 2017 Athul Sai. All rights reserved.
6+
// Copyright (c) 2017 Keep Works. All rights reserved.
77
//
88

99
import UIKit
@@ -15,30 +15,22 @@ class AppDelegate: UIResponder, UIApplicationDelegate {
1515

1616

1717
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {
18-
// Override point for customization after application launch.
1918
return true
2019
}
2120

2221
func applicationWillResignActive(_ application: UIApplication) {
23-
// Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
24-
// Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
2522
}
2623

2724
func applicationDidEnterBackground(_ application: UIApplication) {
28-
// Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
29-
// If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
3025
}
3126

3227
func applicationWillEnterForeground(_ application: UIApplication) {
33-
// Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
3428
}
3529

3630
func applicationDidBecomeActive(_ application: UIApplication) {
37-
// Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
3831
}
3932

4033
func applicationWillTerminate(_ application: UIApplication) {
41-
// Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
4234
}
4335

4436

Example/KWVerificationCodeView/Base.lproj/LaunchScreen.xib

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,13 @@
1-
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2-
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="6214" systemVersion="14A314h" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES">
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="11762" systemVersion="16C68" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" colorMatched="YES">
3+
<device id="retina4_7" orientation="portrait">
4+
<adaptation id="fullscreen"/>
5+
</device>
36
<dependencies>
4-
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="6207"/>
7+
<deployment identifier="iOS"/>
8+
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="11757"/>
59
<capability name="Constraints with non-1.0 multipliers" minToolsVersion="5.1"/>
10+
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
611
</dependencies>
712
<objects>
813
<placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
@@ -11,20 +16,20 @@
1116
<rect key="frame" x="0.0" y="0.0" width="480" height="480"/>
1217
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
1318
<subviews>
14-
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text=" Copyright (c) 2015 CocoaPods. All rights reserved." textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" minimumFontSize="9" translatesAutoresizingMaskIntoConstraints="NO" id="8ie-xW-0ye">
19+
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text=" Copyright (c) 2017 Keep Works. All rights reserved." textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" minimumFontSize="9" translatesAutoresizingMaskIntoConstraints="NO" id="8ie-xW-0ye" userLabel="copyrightLabel">
1520
<rect key="frame" x="20" y="439" width="441" height="21"/>
1621
<fontDescription key="fontDescription" type="system" pointSize="17"/>
1722
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
1823
<nil key="highlightedColor"/>
1924
</label>
20-
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="KWVerificationCodeView" textAlignment="center" lineBreakMode="middleTruncation" baselineAdjustment="alignBaselines" minimumFontSize="18" translatesAutoresizingMaskIntoConstraints="NO" id="kId-c2-rCX">
25+
<label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="KWVerificationCodeView" textAlignment="center" lineBreakMode="middleTruncation" baselineAdjustment="alignBaselines" minimumFontSize="18" translatesAutoresizingMaskIntoConstraints="NO" id="kId-c2-rCX" userLabel="titleLabel">
2126
<rect key="frame" x="20" y="140" width="441" height="43"/>
2227
<fontDescription key="fontDescription" type="boldSystem" pointSize="36"/>
2328
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
2429
<nil key="highlightedColor"/>
2530
</label>
2631
</subviews>
27-
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
32+
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
2833
<constraints>
2934
<constraint firstItem="kId-c2-rCX" firstAttribute="centerY" secondItem="iN0-l3-epB" secondAttribute="bottom" multiplier="1/3" constant="1" id="5cJ-9S-tgC"/>
3035
<constraint firstAttribute="centerX" secondItem="kId-c2-rCX" secondAttribute="centerX" id="Koa-jz-hwk"/>

0 commit comments

Comments
 (0)