Open jeffleeismyhero opened 9 years ago
We could do something like we do with fields. A method that takes a boolean to consider or exclude hidden values.
https://github.com/hyperoslo/Form/blob/master/Source/FORMDataSource.h#L193-L194
/*!
* @discussion A method to find a @c field with its specific @c indexPath
* @param fieldID The identifier for the field
* @param includingHiddenFields A flag for whether look for hidden or collapsed fields or not
*/
- (void)fieldWithID:(NSString *)fieldID
includingHiddenFields:(BOOL)includingHiddenFields
completion:(void (^)(FORMField *field,
NSIndexPath *indexPath))completion;
I can hide a section with:
Similarly, I can show a section with:
How can I determine if a section is hidden or visible? I want a button that will toggle the section to display or hide.
Additionally, how can I mark sections as hidden initially without resorting to the code above? That doesn't currently seem to be supported.