Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
101 commits
Select commit Hold shift + click to select a range
9c23282
Add customizable accessoryView besides messageContainer
tinder-sgong Jun 2, 2018
b36924e
consider accessoryViewPadding vertical attributes
tinder-sgong Jun 2, 2018
3554e3f
Fix configCell stub cell type
tinder-sgong Jun 2, 2018
7fde2fd
mimic avatar
tinder-sgong Jun 3, 2018
9c3032d
Don’t ignore size calculation on zero size, and consider accessoryVie…
tinder-sgong Jun 3, 2018
4dabb02
Fix broken test (not related to this PR), and formatting
tinder-sgong Jun 4, 2018
081ca7a
keyboard frame done more correctly
tinder-sgong Jun 5, 2018
2aa83ee
Revert "keyboard frame done more correctly"
tinder-sgong Jun 5, 2018
4086f3f
Merge branch 'development' into development
hyouuu Jun 7, 2018
bd1c1b3
Added entry in changelog
tinder-sgong Jun 27, 2018
7dd498a
revert changelog
tinder-sgong Jun 27, 2018
ee08f3c
Merge pull request #1 from MessageKit/development
hyouuu Jun 27, 2018
957f5ff
update changelog
tinder-sgong Jun 27, 2018
fab22c5
Merge pull request #710 from hyouuu/development
SD10 Jun 27, 2018
57165b7
Merge branch 'development' of https://github.com/MessageKit/MessageKi…
SD10 Jul 3, 2018
9eed4d8
Adjust contentInset for the keyboard frame properly
andreyvit Jul 30, 2018
39d4b6c
Add a link to WWDC video about keyboard insets
andreyvit Aug 1, 2018
b49a0e0
A tiny optimisation in keyboard handling
andreyvit Aug 1, 2018
2ca89ec
Better document the rationale behind keyboard code
andreyvit Aug 1, 2018
79b1ff0
Rename computeXxx to requiredXxx
andreyvit Aug 1, 2018
a0b0749
Introduce extraBottomInset property
andreyvit Aug 1, 2018
8fb64d9
CHANGELOG for keyboard handling changes
andreyvit Aug 1, 2018
8f7c407
Fix: make extraBottomInset work when set before showing
andreyvit Aug 1, 2018
34dcda0
Fix #569 and #789
nathantannar4 Aug 1, 2018
51f1ff3
Changelog edit
nathantannar4 Aug 1, 2018
d9f8856
Add back parseForAttachedImages
nathantannar4 Aug 1, 2018
5e5c80f
Merge pull request #791 from MessageKit/fix-inputtextview
nathantannar4 Aug 3, 2018
540f203
Fix insets calculation when present and dismiss vc && remove precisio…
zhongwuzw Aug 7, 2018
f889487
Merge pull request #787 from andreyvit/keyboard-inset-fix-to-rule-em-all
SD10 Aug 7, 2018
5de6481
All-New ChatExample App
nathantannar4 Aug 12, 2018
b058727
Correct Typo
nathantannar4 Aug 12, 2018
b82aeec
Remove Random.swift, add more examples
nathantannar4 Aug 12, 2018
1be7622
Fix CHANGELOG
SD10 Aug 15, 2018
0090905
Make requested changes from @zhongwuzw
nathantannar4 Aug 21, 2018
ba9baac
Merge pull request #803 from MessageKit/update-example
nathantannar4 Aug 22, 2018
a009e72
Add init with coder for MessageReusableView
maxxx777 Aug 30, 2018
6a81f5c
Add convenience method to register Reusable View from nib
maxxx777 Aug 30, 2018
a3c7a2f
Add delegate and adjust layout
nathantannar4 Aug 31, 2018
041a239
CHANGELOG Entry
nathantannar4 Aug 31, 2018
fe0a000
MessagesDataSource & MessagesLayoutDelegate methods for MessageType.c…
RealBonus Sep 8, 2018
3bfeccd
Fix a typo in scrollsToBottomOnKeybordBeginsEditing
p-petrenko Sep 11, 2018
1803650
Fix CHANGELOG entry
SD10 Sep 12, 2018
ae68e19
Rename convenience method to register Reusable View from nib
maxxx777 Sep 15, 2018
a36fa7c
Update CHANGELOG
maxxx777 Sep 15, 2018
04c2369
Merge pull request #832 from maxxx777/enhancement/init-reusable-view-…
SD10 Sep 15, 2018
2d1fe72
Merge pull request #856 from p-petrenko/bugfix/issue-829-dev
SD10 Sep 16, 2018
4ca60bb
Updating FAQ with linkable sections.
marcocapano Sep 16, 2018
6374b87
Merge pull request #865 from marcocapano/patch-1
SD10 Sep 16, 2018
230e067
Integrate MessageInputBar as a dependency (#732)
nathantannar4 Sep 17, 2018
ad7b00f
Updating "apps using this library"
marcocapano Sep 20, 2018
0e6c797
Merge pull request #874 from MessageKit/marcocapano-patch-1
nathantannar4 Sep 23, 2018
406f700
Minor edits
nathantannar4 Sep 26, 2018
485b460
swiftlint
RealBonus Sep 27, 2018
9a2affc
Update to Swift 4.2
nathantannar4 Sep 29, 2018
dbf9d65
Bump Cartfile versions, fix .circleci config
nathantannar4 Sep 29, 2018
d806da7
Update Example to Swift 4.2
nathantannar4 Sep 29, 2018
7db7aac
CHANGELOG
nathantannar4 Sep 30, 2018
095abe0
Merge pull request #883 from MessageKit/swift-4.2
nathantannar4 Sep 30, 2018
2aa9573
Better method names
RealBonus Oct 2, 2018
6a2eef7
fix intrinsic content size for MessageLabel
Oct 2, 2018
bc70b5b
[Accessoryview] Fix
JulienKode Oct 4, 2018
c606ca2
update changelog
Oct 5, 2018
fa08526
Merge pull request #889 from monzo/bugfix/messagelabel-autolayout
nathantannar4 Oct 5, 2018
d62d9b4
isLastSectionVisible method returns wrong results for the BasicExampl…
hamzaozturk Oct 8, 2018
95297ce
Merge pull request #899 from hamzaozturk/development
nathantannar4 Oct 10, 2018
83b483f
Merge pull request #893 from JulienKode/accessoryview-updates-fix
nathantannar4 Oct 12, 2018
78c48fb
Merge remote-tracking branch 'origin/development' into accessoryview-…
nathantannar4 Oct 12, 2018
2e6de00
Horizontal Padding only for accessoryView
nathantannar4 Oct 12, 2018
c29618f
Adds WiseEyes to "Apps using this library"
srgisme Oct 12, 2018
a6f9d81
Merge pull request #907 from srgisme/master
nathantannar4 Oct 13, 2018
197ec8b
Final tweak to layout
nathantannar4 Oct 13, 2018
50bce2a
Merge pull request #834 from MessageKit/accessoryview-updates
nathantannar4 Oct 13, 2018
9639bdc
Merge Changelogs
nathantannar4 Oct 13, 2018
b3950af
Correct AccessoryView Size in Example
nathantannar4 Oct 13, 2018
648609d
Fix: Allow required init coder @ MessageLabel, MessagesCollection, Pl…
Oct 14, 2018
aa734da
Merge pull request #905 from talanov/development
zhongwuzw Oct 14, 2018
91a17c7
Bump to 2.0.0 beta 1 version
nathantannar4 Oct 14, 2018
c93b21c
Merge branch 'master' into version2.0.0
nathantannar4 Oct 14, 2018
1e73aca
Merge pull request #910 from MessageKit/version2.0.0
nathantannar4 Oct 14, 2018
4930d62
Update Changelog to show changes for 2.0.0-beta.1
nathantannar4 Oct 14, 2018
634da70
Merge branch 'master' into development
nathantannar4 Oct 14, 2018
4156260
allow dynamic avatar size per message size calculator (#898)
marius-serban Oct 16, 2018
5ce67b4
Fix CHANGELOG entry order (#914)
SD10 Oct 17, 2018
eb848be
Changelog and some comments
RealBonus Oct 19, 2018
801b1e2
Fix Code of Conduct link broken (#918)
cruisediary Oct 20, 2018
e5bc762
Settings aded to enable/disable message types.
hamzaozturk Oct 23, 2018
5327b01
Merge branch 'master'
hamzaozturk Oct 23, 2018
3b3db11
Merge pull request #879 from RealBonus/enhancement/customMessageKind
nathantannar4 Oct 26, 2018
be571b0
[MessageLabel] Change privacy of properties and function to use allow…
JulienKode Oct 15, 2018
b9e1190
Update changelog
JulienKode Oct 27, 2018
59b28f7
Update changelog
JulienKode Oct 27, 2018
07f611d
Merge branch 'development' into patch-1
nathantannar4 Nov 1, 2018
93d04d5
Merge pull request #912 from JulienKode/patch-1
nathantannar4 Nov 1, 2018
6f04569
Move test to Quick/Nimble (#924)
Nov 2, 2018
37dc8f6
Merge branch 'development'
nathantannar4 Nov 4, 2018
d16c6a8
Version 2.0.0 Release
nathantannar4 Nov 4, 2018
0c0e544
Update CHANGELOG.md
SD10 Nov 4, 2018
5d2ac65
add getting started section (#955)
TomWFox Dec 20, 2018
a17ec16
Updated
Feb 8, 2019
8465a86
Adjusted image mask and padding on bottom text
Feb 12, 2019
7e0aac3
inset change
Mar 17, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 5 additions & 8 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ jobs:
build-and-test:

environment:
- DESTINATION: "platform=iOS Simulator,name=iPhone 8"
- DESTINATION: "platform=iOS Simulator,name=iPhone XS"

# Specify the Xcode version to use.
macos:
xcode: "9.2.0"
xcode: "10.0.0"

# Define the steps required to build the project.
steps:
Expand All @@ -22,17 +22,14 @@ jobs:
- run:
name: Update Homebrew
command: brew update
- run:
name: Update carthage
command: brew upgrade carthage
- run:
name: Bootstrap Carthage
command: carthage bootstrap --platform ios
- run:
name: Biuld framework
name: Build framework
command: xcodebuild build -project MessageKit.xcodeproj -scheme MessageKit -destination "$DESTINATION" CODE_SIGNING_REQUIRED=NO | xcpretty -c
- run:
name: Biuld and run tests
name: Build and run tests
command: xcodebuild test -project MessageKit.xcodeproj -scheme MessageKitTests -destination "$DESTINATION" CODE_SIGNING_REQUIRED=NO | xcpretty -c
- run:
name: Fetch CocoaPods Specs
Expand All @@ -41,7 +38,7 @@ jobs:
name: Update Pods
command: cd Example && pod install
- run:
name: Biuld and analyze Example
name: Build and analyze Example
command: xcodebuild build analyze -workspace Example/ChatExample.xcworkspace -scheme ChatExample -destination "$DESTINATION" ONLY_ACTIVE_ARCH=NO CODE_SIGNING_REQUIRED=NO | xcpretty -c

# Run tests.
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,5 @@ Pods/

# Carthage
Carthage
Carthage/Build
Carthage/Checkouts
9 changes: 9 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[submodule "Carthage/Checkouts/Nimble"]
path = Carthage/Checkouts/Nimble
url = https://github.com/Quick/Nimble.git
[submodule "Carthage/Checkouts/Quick"]
path = Carthage/Checkouts/Quick
url = https://github.com/Quick/Quick.git
[submodule "Carthage/Checkouts/MessageInputBar"]
path = Carthage/Checkouts/MessageInputBar
url = https://github.com/ZkHaider/MessageInputBar.git
2 changes: 1 addition & 1 deletion .swift-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
4.0
4.2
54 changes: 52 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,63 @@ The changelog for `MessageKit`. Also see the [releases](https://github.com/Messa

--------------------------------------

## Upcoming release
## [2.0.0](https://github.com/MessageKit/MessageKit/releases/tag/2.0.0)

### Added

- **Breaking Change** Added new methods to simplify using of custom messages: `customCellSizeCalculator(for:at:in:)` for `MessagesLayoutDelegate` and `customCell(for:at:in:)` for `MessagesDataSource`.
[#879](https://github.com/MessageKit/MessageKit/pull/879) by [@realbonus](https://github.com/RealBonus)

### Changed

- Change acl of `handleGesture(touchLocation:)` in `MessageLabel` from internal to open.
[#912](https://github.com/MessageKit/MessageKit/pull/912) by [@julienkode](https://github.com/JulienKode)

## [2.0.0-beta.1](https://github.com/MessageKit/MessageKit/releases/tag/2.0.0-beta.1)

### Changed

- The `MessageData.emoji` case once again uses a default font of 2x the `messageLabelFont` size.
- **Breaking Change** Updated codebase to Swift 4.2 [#883](https://github.com/MessageKit/MessageKit/pull/883) by [@nathantannar4](https://github.com/nathantannar4)

- Fixed the way that the Strings and UIImages are parsed in the `InputTextView` to prevent crashes in `parseForComponents()`.
[#791](https://github.com/MessageKit/MessageKit/pull/791) by [@nathantannar4](https://github.com/nathantannar4)

### Added

- Added support for detection and handling of `NSLink`s inside of messages.
[#815](https://github.com/MessageKit/MessageKit/pull/815) by [@jnic](https://github.com/jnic)

- Added customizable `accessoryView`, with a new `MessagesDisplayDelegate` function `configureAccessoryView`, and corresponding size & padding properties in `MessageSizeCalculator`. The `accessoryView` is aligned to the center of the `messageContainerView`.
[#710](https://github.com/MessageKit/MessageKit/pull/710) by [@hyouuu](https://github.com/hyouuu)

- Added a tap gesture recognition to the `accessoryView` which calls the `MessageCellDelagate` function `didTapAccessoryView(in:)`.
[#834](https://github.com/MessageKit/MessageKit/pull/834) by [@nathantannar4](https://github.com/nathantannar4)

- Added `additionalBottomInset` property that allows to adjust the bottom content inset automatically set on the messages collection view by the view controller.
[#787](https://github.com/MessageKit/MessageKit/pull/787) by [@andreyvit](https://github.com/andreyvit)

### Fixed

- **Breaking Change** Fixed typo of `scrollsToBottomOnKeybordBeginsEditing` to `scrollsToBottomOnKeyboardBeginsEditing`.
[#856](https://github.com/MessageKit/MessageKit/pull/856) by [@p-petrenko](https://github.com/p-petrenko)

- Fixed a bug that prevented `MessageLabel` from laying out properly when contained by superviews using autolayout.
[#889](https://github.com/MessageKit/MessageKit/pull/889) by [@marius-serban](https://github.com/marius-serban).

- Fixed bottom content inset adjustment when using an undocked keyboard on iPad, or when `edgesForExtendedLayout` does not include `.top`, or when a parent container view controller adds extra views at the top of the screen.
[#787](https://github.com/MessageKit/MessageKit/pull/787) by [@andreyvit](https://github.com/andreyvit)

- Fixed the `MessageData.emoji` case to use 2x the `messageLabelFont` size by default.
[#795](https://github.com/MessageKit/MessageKit/pull/795) by [@Vortec4800](https://github.com/vortec4800).

### Fixed

- Fixed `MessagesCollectionView` to allow to use nibs with `MessageReusableView`.
[#832](https://github.com/MessageKit/MessageKit/pull/832) by [@maxxx777](https://github.com/maxxx777).

- Fixed multiple crashes at views, when views are being called from another XIB.
[#905](https://github.com/MessageKit/MessageKit/pull/905) by [@talanov](https://github.com/talanov).

## [1.0.0](https://github.com/MessageKit/MessageKit/releases/tag/1.0.0)

- First major release.
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

### Code of Conduct

Please read our [Code of Conduct](https://github.com/MessageKit/MessageKit/blob/master/Code_of_Conduct.md).
Please read our [Code of Conduct](https://github.com/MessageKit/MessageKit/blob/master/CODE_OF_CONDUCT.md).
The MessageKit maintainers take this Code of Conduct very seriously. Intolerance, disrespect, harassment, and any form of negativity will not be tolerated.

### Ways to Contribute
Expand Down
1 change: 1 addition & 0 deletions Cartfile
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
github "ZkHaider/MessageInputBar" "static"
5 changes: 3 additions & 2 deletions Cartfile.resolved
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
github "Quick/Nimble" "v7.0.3"
github "Quick/Quick" "v1.2.0"
github "Quick/Nimble" "v7.3.3"
github "Quick/Quick" "v1.3.4"
github "ZkHaider/MessageInputBar" "83e91fe05b75582fabce16cabf9ffa5646379906"
17 changes: 12 additions & 5 deletions Documentation/FAQs.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
# MessageKit Frequently Asked Questions

**Why doesn't the `MessageInputBar` appear in my controller?**
- [Why doesn't the `MessageInputBar` appear in my controller?](#why-doesnt-the-messageinputbar-appear-in-my-controller)
- [How can I remove the `AvatarView` from the cell?](#how-can-i-remove-the-avatarview-from-the-cell)
- [How can I move the `AvatarView` to prevent it from overlapping text in the `MessageBottomLabel` or `CellTopLabel`?](#how-can-i-move-the-avatarview-to-prevent-it-from-overlapping-text-in-the-messagebottomlabel-or-celltoplabel)
- [How can I dismiss the keyboard?](#how-can-i-dismiss-the-keyboard)
- [How can I get a reference to the `MessageType` in the `MessageCellDelegate` methods?](#how-can-i-get-a-reference-to-the-messagetype-in-the-messagecelldelegate-methods)


## Why doesn't the `MessageInputBar` appear in my controller?

If you're using the `MessagesViewController` as a child view controller then
you have to call `becomeFirstResponder()` on your view controller. The
Expand All @@ -21,7 +28,7 @@ class ParentVC: UIViewController {
}
```

**How can I remove the `AvatarView` from the cell?**
## How can I remove the `AvatarView` from the cell?

You can set the `AvatarView` to hidden through the `configureAvatarView(_:AvatarView,for:MessageType,at:IndexPath,in:MessagesCollectionView)` method of `MessagesDisplayDelegate`.

Expand Down Expand Up @@ -52,7 +59,7 @@ if let layout = messagesCollectionView.collectionViewLayout as? MessagesCollecti
}
```

**How can I move the `AvatarView` to prevent it from overlapping text in the `MessageBottomLabel` or `CellTopLabel`?**
## How can I move the `AvatarView` to prevent it from overlapping text in the `MessageBottomLabel` or `CellTopLabel`?

If you have resized the `AvatarView` to be larger than the default size in MessageKit then you may notice that the
`AvatarView` overlaps text either in the `MessageBottomLabel` or `CallTopLabel`. MessageKit allows the `AvatarView`
Expand All @@ -75,7 +82,7 @@ if let layout = messagesCollectionView.collectionViewLayout as? MessagesCollecti

There are other options provided as well so take a look at the `AvatarPosition` struct to see what they are.

**How can I dismiss the keyboard?**
## How can I dismiss the keyboard?

The `MessagesViewController` needs to resign the first responder.

Expand All @@ -84,7 +91,7 @@ let controller = MessagesViewController()
controller.resignFirstResponder()
```

**How can I get a reference to the `MessageType` in the `MessageCellDelegate` methods?**
## How can I get a reference to the `MessageType` in the `MessageCellDelegate` methods?

You can use `UICollectionView`'s method `indexPath(for: UICollectionViewCell)` to get the
`IndexPath` for the `MessageCollectionViewCell` argument. Using this `IndexPath`, you can
Expand Down
Loading