Cody Weaver 255f6e99b4
[ActionSheet] Update docs to include themers (#5209)
### Context
The docs for ActionSheet haven't been updated since the initial PR.
### The problem
There was no section for theming, color or typography theming.
### The fix
Add sections for both color and typography theming to the README.
2018-09-24 15:26:02 -04:00
..

Action Sheet

Material design action sheets should be used as an overflow menu. An Action Sheet comes up from the bottom of the screen and displays actions a user can take.

An animation showing a Material Design Action Sheet. An animation showing a Material Design Action Sheet.


Overview

MDCActionSheetController is a material design implementation of UIAlertControllerStyleActionSheet.

Action Sheet is currently an alpha component. Therefore, clients that wish to use Action Sheet in their app will need to manually clone the repo and add the code to their project.

Installation

Usage

MDCActionSheetController vs. UIAlertControllerStyleActionSheet

MDCActionSheetController is intended to mirror a UIAlertController with the UIAlertControllerStyleActionSheet style.

Similarities

  1. Both classes are presented from the bottom of the screen on an iPhone and have a list of actions.

  2. Both classes support optional title and message properties.

Differences

  1. UIAlertControllerActionSheetStyle requires that you set the popoverPresentationController on larger devices, MDCActionSheetController doesn't support popoverPresentationController but instead always comes up from the bottom of the screen.

  2. UIAlertControllerStyleActionSheet is a style of UIAlertController and not its own class. If you need a Material UIAlertController please see the MDCAlertController class.

  3. MDCActionSheetController does not support text fields.

  4. MDCActionSheetController does not have a preferredAction.

Extensions