Skip to content

Instantly share code, notes, and snippets.

@KalpeshTalkar
KalpeshTalkar / KView.swift
Created September 20, 2017 09:32
KView is a custom IBDesignable UIView written in Swift 3. KView offers gradient background, border color, border width, corner radius.
// Copyright © 2017 Kalpesh Talkar. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
@KalpeshTalkar
KalpeshTalkar / MyApp.java
Last active August 22, 2017 07:30
A custom application class that provides global application context.
//
// Copyright © 2017 Kalpesh Talkar. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
@KalpeshTalkar
KalpeshTalkar / LocalStorage.java
Last active March 23, 2020 08:09
A wrapper over shared preferences. *Dependency required: A custom application class which provides global app context. (https://gist.github.com/KalpeshTalkar/c4c7ccf8003c6214c11226b86c565bb7)
//
// Copyright © 2017 Kalpesh Talkar. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
@KalpeshTalkar
KalpeshTalkar / KDebugInfoOverlay.swift
Last active June 10, 2017 10:40
The class enables the UIDebuggingInformationOverlay (which is a private UIWindow subclass). This helps developers and designers debug the app.
//
// Copyright © 2017 Kalpesh Talkar. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
@KalpeshTalkar
KalpeshTalkar / UIUtils.swift
Last active May 25, 2017 10:47
UIUtils is a utility file written in Swift 3. It has UIView extension for clipping, applying corner radius, drop shadow. It features device details, screen size, device orientation, etc.
// Copyright © 2017 Kalpesh Talkar. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
@KalpeshTalkar
KalpeshTalkar / KTextField.swift
Last active July 20, 2021 14:13
Custom IBDesignable text field written in Swift 3
// Copyright © 2017 Kalpesh Talkar. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
@KalpeshTalkar
KalpeshTalkar / LocalStorage.swift
Last active December 7, 2018 20:33
LocalStorage is an abstraction over the UserDefaults. The class is written in Swift 3
// Copyright © 2017 Kalpesh Talkar. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
@KalpeshTalkar
KalpeshTalkar / KCircularProgressView.swift
Last active August 19, 2020 18:46
Circular progress view build in swift 3
//
// Copyright © 2017 Kalpesh Talkar. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
@KalpeshTalkar
KalpeshTalkar / KBreadCrumb.swift
Last active May 17, 2017 09:11
KBreadCrumbView is a custom @IBDesignable UIView component build to show bread crumbs. The component is built in Swift 2.2
//
// Copyright © 2017 Kalpesh Talkar. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
@KalpeshTalkar
KalpeshTalkar / KTabBar.swift
Last active July 17, 2018 10:27
IBDesignable tab bar view written in Swift 3
//
// Copyright © 2017 Kalpesh Talkar. All rights reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software