Skip to content

Commit

Permalink
Remove mentions of unreleased APIs from README
Browse files Browse the repository at this point in the history
  • Loading branch information
saket committed Oct 15, 2020
1 parent d39bcae commit 28f8367
Showing 1 changed file with 2 additions and 14 deletions.
16 changes: 2 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,6 @@ implementation "me.saket.cascade:cascade:1.0.0"
popup.show()
```

**Use as Toolbar's overflow menu**

```kotlin
toolbar.overrideOverflowMenu { context, anchor ->
CascadePopupMenu(context, anchor)
}

// The lambda can be collapsed into a reference
// if you're only using the two-param constructor.
toolbar.overrideOverflowMenu(with = ::CascadePopupMenu)
```

### Customization

`cascade` is great for apps that prefer applying dynamic themes at runtime, which `PopupMenu` makes it extremely hard to do so. By providing a `CascadePopupMenu.Styler` object, you can adjust colors, spacings and text styles from Kotlin ([example](https://github.com/saket/cascade/blob/038bbf054657c243ae62f2d780e5488ed54fcafb/sample/src/main/java/me/saket/cascade/sample/MainActivity.kt#L93-L111)).
Expand Down Expand Up @@ -72,8 +60,8 @@ popup.menu.addSubMenu("Remove").also {

```kotlin
val popup = CascadePopupWindow(context)
popup.contentView.addView(CustomMenuView(context)) // Also see goBack().
popup.show(anchor)
popup.contentView.goForward(CustomMenuView(context)) // Also see goBack().
popup.showAsDropdown(anchor, ...)
```

## License
Expand Down

0 comments on commit 28f8367

Please sign in to comment.