diff --git a/Apptentive/Apptentive.xcodeproj/project.pbxproj b/Apptentive/Apptentive.xcodeproj/project.pbxproj index 5e3f2fff7..0d6d967d8 100644 --- a/Apptentive/Apptentive.xcodeproj/project.pbxproj +++ b/Apptentive/Apptentive.xcodeproj/project.pbxproj @@ -2409,7 +2409,7 @@ CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; COPY_PHASE_STRIP = NO; - CURRENT_PROJECT_VERSION = 42; + CURRENT_PROJECT_VERSION = 43; DEBUG_INFORMATION_FORMAT = dwarf; ENABLE_STRICT_OBJC_MSGSEND = YES; ENABLE_TESTABILITY = YES; @@ -2467,7 +2467,7 @@ CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; COPY_PHASE_STRIP = NO; - CURRENT_PROJECT_VERSION = 42; + CURRENT_PROJECT_VERSION = 43; DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; ENABLE_NS_ASSERTIONS = NO; ENABLE_STRICT_OBJC_MSGSEND = YES; @@ -2499,7 +2499,7 @@ DEFINES_MODULE = YES; DEVELOPMENT_TEAM = 86WML2UN43; DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 42; + DYLIB_CURRENT_VERSION = 43; DYLIB_INSTALL_NAME_BASE = "@rpath"; GCC_PREFIX_HEADER = "Apptentive/Misc/ApptentiveConnect-Prefix.pch"; GCC_PREPROCESSOR_DEFINITIONS = "APPTENTIVE_DEBUG=1"; @@ -2519,7 +2519,7 @@ DEFINES_MODULE = YES; DEVELOPMENT_TEAM = 86WML2UN43; DYLIB_COMPATIBILITY_VERSION = 1; - DYLIB_CURRENT_VERSION = 42; + DYLIB_CURRENT_VERSION = 43; DYLIB_INSTALL_NAME_BASE = "@rpath"; GCC_PREFIX_HEADER = "Apptentive/Misc/ApptentiveConnect-Prefix.pch"; INFOPLIST_FILE = Apptentive/Info.plist; diff --git a/Apptentive/Apptentive/Apptentive.h b/Apptentive/Apptentive/Apptentive.h index 550d7874b..e7e3ec443 100644 --- a/Apptentive/Apptentive/Apptentive.h +++ b/Apptentive/Apptentive/Apptentive.h @@ -20,7 +20,7 @@ FOUNDATION_EXPORT double ApptentiveVersionNumber; FOUNDATION_EXPORT const unsigned char ApptentiveVersionString[]; /** The version number of the Apptentive SDK. */ -#define kApptentiveVersionString @"5.2.13" +#define kApptentiveVersionString @"5.2.14" /** The version number of the Apptentive API platform. */ #define kApptentiveAPIVersionString @"9" diff --git a/Apptentive/Apptentive/Info.plist b/Apptentive/Apptentive/Info.plist index f1a37d4e4..c9181d63d 100644 --- a/Apptentive/Apptentive/Info.plist +++ b/Apptentive/Apptentive/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType FMWK CFBundleShortVersionString - 5.2.13 + 5.2.14 CFBundleVersion $(CURRENT_PROJECT_VERSION) NSPrincipalClass diff --git a/Apptentive/Apptentive/Surveys/View Controllers/ApptentiveSurveyViewController.m b/Apptentive/Apptentive/Surveys/View Controllers/ApptentiveSurveyViewController.m index 4c64e3637..05bf92df0 100644 --- a/Apptentive/Apptentive/Surveys/View Controllers/ApptentiveSurveyViewController.m +++ b/Apptentive/Apptentive/Surveys/View Controllers/ApptentiveSurveyViewController.m @@ -668,16 +668,24 @@ - (void)presentationControllerDidDismiss:(UIPresentationController *)presentatio #pragma mark - View model delegate - (void)viewModelValidationChanged:(ApptentiveSurveyViewModel *)viewModel isValid:(BOOL)valid { - [self.collectionView reloadData]; - + [self.collectionViewLayout invalidateLayout]; + [self setToolbarHidden:valid]; - + for (UICollectionViewCell *cell in self.collectionView.visibleCells) { if ([cell isKindOfClass:[ApptentiveSurveyOtherCell class]]) { ApptentiveSurveyOtherCell *otherCell = (ApptentiveSurveyOtherCell *)cell; otherCell.valid = [self.viewModel answerIsValidAtIndexPath:[self.viewModel indexPathForTextFieldTag:otherCell.textField.tag]]; } } + + for (NSIndexPath *indexPath in [self.collectionView indexPathsForVisibleSupplementaryElementsOfKind:UICollectionElementKindSectionHeader]) { + UIView *view = [self.collectionView supplementaryViewForElementKind:UICollectionElementKindSectionHeader atIndexPath:indexPath]; + + if ([view isKindOfClass:[ApptentiveSurveyQuestionView class]]) { + view.accessibilityLabel = [self.viewModel accessibilityLabelForQuestionAtIndexPath:indexPath]; + } + } } - (void)viewModel:(ApptentiveSurveyViewModel *)viewModel didDeselectAnswerAtIndexPath:(NSIndexPath *)indexPath { diff --git a/Apptentive/ApptentiveTests/Info.plist b/Apptentive/ApptentiveTests/Info.plist index 67b4d1db8..e1a203814 100644 --- a/Apptentive/ApptentiveTests/Info.plist +++ b/Apptentive/ApptentiveTests/Info.plist @@ -15,7 +15,7 @@ CFBundlePackageType BNDL CFBundleShortVersionString - 5.2.13 + 5.2.14 CFBundleVersion 1 diff --git a/CHANGELOG.md b/CHANGELOG.md index 00c6e50bb..bf27305d5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +# 2020-07-08 - v5.2.14 + +#### Bugs Fixed + +* Fix a bug where a survey with missing/invalid answers loses all user selections on attempted submit. + # 2020-07-06 - v5.2.13 #### Bugs Fixed diff --git a/Example/Podfile.lock b/Example/Podfile.lock index c41d9a71c..2ff507aec 100644 --- a/Example/Podfile.lock +++ b/Example/Podfile.lock @@ -1,5 +1,5 @@ PODS: - - apptentive-ios (5.2.13) + - apptentive-ios (5.2.14) DEPENDENCIES: - apptentive-ios (from `..`) @@ -9,8 +9,8 @@ EXTERNAL SOURCES: :path: ".." SPEC CHECKSUMS: - apptentive-ios: d99c34d093015a81d2c8621dcd749d95ad750569 + apptentive-ios: 16951b1f9546bbae9165792679f865dc53bbe82f PODFILE CHECKSUM: 89d2b5f4683b04482e89df6d46b268cc9ed1ef79 -COCOAPODS: 1.9.1 +COCOAPODS: 1.9.3 diff --git a/apptentive-ios.podspec b/apptentive-ios.podspec index 66805cea6..c526494ee 100644 --- a/apptentive-ios.podspec +++ b/apptentive-ios.podspec @@ -1,7 +1,7 @@ Pod::Spec.new do |s| s.name = 'apptentive-ios' s.module_name = 'Apptentive' - s.version = '5.2.13' + s.version = '5.2.14' s.license = 'BSD' s.summary = 'Apptentive Customer Communications SDK.' s.homepage = 'https://www.apptentive.com/'