Tap to swap out words with emojis. Inspired by Messages.app on iOS 10.

Overview

EmojiTextView

Tap to swap out words with emojis. Works with any UITextView. Heavily inspired by Messages.app on iOS 10.

Created by Arkadiusz Holko (@arekholko).

Demo GIF

Usage

Add a property of EmojiController type to a class that holds your UITextView instance, e.g. a view controller:

var emojiController: EmojiController?

Then, initialize EmojiController by passing it your text view (e.g. in viewDidLoad()):

emojiController = EmojiController(textView: textView)

That's it! πŸŽ‰

Customization

EmojiController provides three points of customization through properties:

  • mapping – contains a mapping from words to an array of emojis
  • textHighlightingFactory – creates a new instance of an object conforming to TextHighlighting protocol; each instance of that object is responsible for highlighting a single word
  • defaultAttributes - attributes (as in NSAttributedString) of a text that's not replaceable with emoji

Installation

EmojiTextView is available through CocoaPods. To install it simply add the following line to your Podfile:

pod "EmojiTextView", "0.0.1"

Then you can import it with:

import EmojiTextView

Requirements

iOS 9 and above.

Future Improvements

  • Should the emoji replacement be enabled only when the emoji keyboard is selected? It probably requires the use of the private API as UITextInputMode doesn't help here.
  • If there's more than one emoji match for a given word there should be an ability to choose which one we want to use.
  • (EASY) There should be an option to switch back from an emoji to the full word. Hint: add an attribute with the original word to the part of the string replaced by an emoji.

Credits

  • Emoji keyword library is based on emojilib.
You might also like...
🍯 Awesome log aggregator for iOS
🍯 Awesome log aggregator for iOS

🍯 Awesome log aggregator for iOS

Bugfender SDK for iOS, a remote logger tailor-made for mobile
Bugfender SDK for iOS, a remote logger tailor-made for mobile

Bugfender SDK for iOS Bugfender is a cloud service to collect mobile application logs. Developers can control log sending programmatically and manuall

Monitor and terminate/throttle CPU hogging processes in iOS

Vedette Monitor and terminate/throttle CPU hogging processes in iOS Vedette is a CPU usage monitoring tweak for processes in iOS like apps and daemons

A fast & simple, yet powerful & flexible logging framework for Mac and iOS
A fast & simple, yet powerful & flexible logging framework for Mac and iOS

CocoaLumberjack CocoaLumberjack is a fast & simple, yet powerful & flexible logging framework for macOS, iOS, tvOS and watchOS. How to get started Fir

Elegant and extensive logging facility for OS X & iOS (includes database, Telnet and HTTP servers)

Overview XLFacility, which stands for Extensive Logging Facility, is an elegant and powerful logging facility for OS X & iOS. It was written from scra

A Simple iOS Testing Framework

LumberMill Stupidly Simple Logging for iOS. LumberMill is a simple logging library for iOS 10 and Swift 3.0. It allows users to Log files with 5 diffe

Easy to use and lightweight logger for iOS, macOS, tvOS, watchOS and Linux in Swift.
Easy to use and lightweight logger for iOS, macOS, tvOS, watchOS and Linux in Swift.

Lighty Easy to use and lightweight logger for iOS, macOS, tvOS, watchOS and Linux in Swift. Screenshots Requirements Lighty Version Minimum iOS Target

JustLog brings logging on iOS to the next level. It supports console, file and remote Logstash logging via TCP socket with no effort. Support for logz.io available.
JustLog brings logging on iOS to the next level. It supports console, file and remote Logstash logging via TCP socket with no effort. Support for logz.io available.

JustLog JustLog takes logging on iOS to the next level. It supports console, file and remote Logstash logging via TCP socket with no effort. Support f

Twitter Logging Service is a robust and performant logging framework for iOS clients

Twitter Logging Service Background Twitter created a framework for logging in order to fulfill the following requirements: fast (no blocking the main

Owner
Arek Holko
Arek Holko
Log messages to text files and share them by email or other way.

LogToFiles How to log messages to text files and share them by email or share center. 1 - Add the Log.swift file to your App 2 - Just log the messages

Miguel Chaves 0 Jan 9, 2022
LogDog is designed to work out of the box, you can use the pre-configured logger anytime, anywhere

LogDog user-friendly logging apple/swift-log api compatible Usage LogDog is designed to work out of the box, you can use the pre-configured logger any

Luo Xiu 21 Aug 14, 2022
Shows your current framerate (fps) in the status bar of your iOS app

WatchdogInspector Shows your current framerate (fps) in the status bar of your iOS app Be a good citizen! Don't block your main thread! WatchdogInspec

Christian Menschel 510 Nov 24, 2022
Customizable Console UI overlay with debug log on top of your iOS App

AEConsole Customizable Console UI overlay with debug log on top of your iOS App AEConsole is built on top of AELog, so you should probably see that fi

Marko Tadić 142 Dec 21, 2022
In-App iOS Debugging Tool With Enhanced Logging, Networking Info, Crash reporting And More.

The debugger tool for iOS developer. Display logs, network request, device informations, crash logs while using the app. Easy accessible with its bubble head button ?? . Easy to integrate in any apps, to handle development or testing apps easier. First version, there is plenty of room for improvement.

Remi ROBERT 1.8k Dec 29, 2022
Stock tradings Logger app for iOS

Stock Logger Contributor: Name: Prof. Darren Takaki Author: Name: Ibrahim (Wusiman Yibulayin) Student ID: 0728356 Table of contents Description Gettin

null 2 Jul 28, 2022
A simple iOS app to simulate a laser level using built-in camera and gyroscope.

Laser Level A simple iOS app to simulate a laser level using built-in camera and gyroscope. Demo https://youtu.be/aB03EtQ5zsU Usage Download Open .xco

Pavel Trusov 2 Oct 30, 2022
Tracker - A simple location logger app written in Swift and MVVM architecture

Tracker - A simple location logger app written in Swift and MVVM architecture

Loay Ashraf 1 Mar 12, 2022
πŸ“±πŸ’¬πŸš¦ TinyConsole is a micro-console that can help you log and display information inside an iOS application, where having a connection to a development computer is not possible.

TinyConsole TinyConsole is a tiny log console to display information while using your iOS app and written in Swift. Usage Wrap your Main ViewControlle

Devran Cosmo Uenal 2k Jan 3, 2023
TraceLog is a highly configurable, flexible, portable, and simple to use debug logging system for Swift and Objective-C applications running on Linux, macOS, iOS, watchOS, and tvOS.

Please star this github repository to stay up to date. TraceLog Introduction TraceLog is a highly configurable, flexible, portable, and simple to use

Tony Stone 52 Oct 28, 2022