Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Places plugin #171

Merged
merged 30 commits into from
Dec 2, 2017
Merged

Places plugin #171

merged 30 commits into from
Dec 2, 2017

Conversation

cammace
Copy link
Contributor

@cammace cammace commented Nov 19, 2017

As part of the Mapbox Java 3.0 release, we are removing the geocoder widget and replacing it with a new, feature rich, version. The places plugin will eventually (not all in this PR) include a location picker activity, place details bottom sheet view, and an autocomplete activity (this PR).

First, you have two autocomplete modes, one with the cards, and the other full screen. You'll pick this in this intent builder among other options as seen below:

Intent intent = new PlaceAutocomplete.IntentBuilder(PlaceAutocomplete.MODE_CARDS)
      .limit(10)
      .backgroundColor(Color.parseColor("#EEEEEE"))
      .injectPlaces(<List of CarmenFeatures>)
      .build(AutocompleteLauncherActivity.this);
    startActivityForResult(intent, REQUEST_CODE_AUTOCOMPLETE);

when the activity starts it looks like this:

ezgif com-crop

The cards which include bright blue text are the CarmenFeatures which were injected using the IntentBuilder, Useful for including users home/work address or quick access to other favorite places.

When the user selects an item from the list, the activity finishes, and the picked CarmenFeature is received through onActivityResult.

cc: @mapbox/android

@cammace cammace self-assigned this Nov 19, 2017
@langsmith langsmith changed the title Plugin places Places plugin Nov 19, 2017
@langsmith
Copy link
Contributor

Love it @cammace . I'm going to call it com.mapbox.mapboxsdk:mapbox-android-plugin-places for now as I set up docs for this, but let me know whatever your final naming decision is.

@cammace
Copy link
Contributor Author

cammace commented Nov 20, 2017

Damn your quick @langsmith :) not sure what naming we want to go with here either.

robolectric : '3.4.2',
lifecycleCompiler : '1.0.0',
lifecycleRuntime : '1.0.3'
mapboxMapSdk : '5.2.0-beta.4',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To avoid conflicts with Lost, we should bump mapboxMapSdk version to 5.2.0.

Per mapbox/mapbox-gl-native#9488 the location provider is optional (we're not including Lost within the SDK anymore) and in mapbox/mapbox-gl-native#10355 we bumped the Lost version to 3.0.4 https://github.com/mapbox/mapbox-gl-native/blob/ffea8e145f5b67bbeb7aec46c77d73b95ef6ea31/platform/android/dependencies.gradle#L23 which is the one that MAS 2.2.9 uses.

@cammace cammace added ready for review When your PR has been personally reviewed, its time for an external contributors to approve and removed ⚠️ DO NOT MERGE labels Nov 30, 2017
@cammace
Copy link
Contributor Author

cammace commented Nov 30, 2017

This guy's ready for a first pass review. Although I plan to merge into master, the test will be coming after in a different PR since this one is already reaching a large number of lines.

Cameron Mace and others added 3 commits November 30, 2017 11:11
* Adds README to places plugin folder

* adding places plugin line to repo readme

* tweaks

* fixed a few typos

* nit line
Copy link
Member

@tobrun tobrun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good, quick glance through didn't show anything worth addressing. Maybe good to have a second pair of 👀 on this.

Copy link
Contributor

@danesfeder danesfeder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree with @tobrun here - looks great. Let's get it merged and start testing

@cammace cammace merged commit 51943e8 into master Dec 2, 2017
@cammace cammace deleted the cam-plugin-places branch December 2, 2017 05:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature ready for review When your PR has been personally reviewed, its time for an external contributors to approve
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants