Inspired by Heinrich Reimer Material Intro and developed with love from scratch
Java
2,688
69 commits
updated Sep 19, 2020
Material intro screen is inspired by Material Intro and developed with love from scratch. I decided to rewrite completely almost all features in order to make Android intro screen easy to use for everyone and extensible as possible.
dependencies {
compile 'agency.tango.android:material-intro-screen:{latest_release}'
}
public class IntroActivity extends MaterialIntroActivity
<activity
android:name=".IntroActivity"
android:theme="@style/Theme.Intro" />
@Override
protected void onCreate(@Nullable Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
addSlide(new SlideFragmentBuilder()
.backgroundColor(R.color.colorPrimary)
.buttonsColor(R.color.colorAccent)
.possiblePermissions(new String[]{Manifest.permission.CALL_PHONE, Manifest.permission.READ_SMS})
.neededPermissions(new String[]{Manifest.permission.CAMERA, Manifest.permission.ACCESS_FINE_LOCATION, Manifest.permission.ACCESS_COARSE_LOCATION})
.image(agency.tango.materialintroscreen.R.drawable.ic_next)
.title("title 3")
.description("Description 3")
.build(),
new MessageButtonBehaviour(new View.OnClickListener() {
@Override
public void onClick(View v) {
showMessage("We provide solutions to make you love your work");
}
}, "Work with love"));
}
possiblePermissions ⇾ permissions which are not necessary to be grantedneededPersmissions ⇾ permission which are needed to be granted to move further from that slideMessageButtonBehaviour ⇾ create a new instance only if you want to have a custom action or text on a message buttonsetSkipButtonVisible() ⇾ show skip button instead of back button on the left bottom of screenhideBackButton() ⇾ hides any button on the left bottom of screenenableLastSlideAlphaExitTransition() ⇾ set if the last slide should disapear with alpha hiding effectYou can set enter, default and exit translation for every view in intro activity. To achive this you need to get translation wrapper for chosen view (for example: getNextButtonTranslationWrapper()) and set there new class which will implement IViewTranslation
getBackButtonTranslationWrapper()
.setEnterTranslation(new IViewTranslation() {
@Override
public void translate(View view, @FloatRange(from = 0, to = 1.0) float percentage) {
view.setAlpha(percentage);
}
});
getNextButtonTranslationWrapper()getBackButtonTranslationWrapper()getPageIndicatorTranslationWrapper()getViewPagerTranslationWrapper()getSkipButtonTranslationWrapper()backgroundColor()buttonsColor()canMoveFurther() (only if you want to stop user from being able to move further before he will do some action)cantMoveFurtherErrorMessage() (as above)<agency.tango.materialintroscreen.parallax.ParallaxLinearLayout
xmlns:android="http://schemas.android.com/apk/res/android">
<ImageView
android:id="@+id/image_slide"
app:layout_parallaxFactor="0.6"/>
All features which are not available in simple Slide Fragment are shown here: Custom Slide
To report a specific problem or feature request, open a new issue on Github.
Here you can see open source work developed by Tango Agency.
Whether you're searching for a new partner or trusted team for creating your new great product we are always ready to start work with you.
You can contact us via [email protected]. Thanks in advance.
1,026 followers · starred Oct 2016
98 followers · starred Dec 2020
113 followers · starred Sep 2016
16 followers · starred Jun 2017
Inspired by Heinrich Reimer Material Intro and developed with love from scratch
Java
2,688
69 commits
updated Sep 19, 2020
Material intro screen is inspired by Material Intro and developed with love from scratch. I decided to rewrite completely almost all features in order to make Android intro screen easy to use for everyone and extensible as possible.
dependencies {
compile 'agency.tango.android:material-intro-screen:{latest_release}'
}
public class IntroActivity extends MaterialIntroActivity
<activity
android:name=".IntroActivity"
android:theme="@style/Theme.Intro" />
@Override
protected void onCreate(@Nullable Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
addSlide(new SlideFragmentBuilder()
.backgroundColor(R.color.colorPrimary)
.buttonsColor(R.color.colorAccent)
.possiblePermissions(new String[]{Manifest.permission.CALL_PHONE, Manifest.permission.READ_SMS})
.neededPermissions(new String[]{Manifest.permission.CAMERA, Manifest.permission.ACCESS_FINE_LOCATION, Manifest.permission.ACCESS_COARSE_LOCATION})
.image(agency.tango.materialintroscreen.R.drawable.ic_next)
.title("title 3")
.description("Description 3")
.build(),
new MessageButtonBehaviour(new View.OnClickListener() {
@Override
public void onClick(View v) {
showMessage("We provide solutions to make you love your work");
}
}, "Work with love"));
}
possiblePermissions ⇾ permissions which are not necessary to be grantedneededPersmissions ⇾ permission which are needed to be granted to move further from that slideMessageButtonBehaviour ⇾ create a new instance only if you want to have a custom action or text on a message buttonsetSkipButtonVisible() ⇾ show skip button instead of back button on the left bottom of screenhideBackButton() ⇾ hides any button on the left bottom of screenenableLastSlideAlphaExitTransition() ⇾ set if the last slide should disapear with alpha hiding effectYou can set enter, default and exit translation for every view in intro activity. To achive this you need to get translation wrapper for chosen view (for example: getNextButtonTranslationWrapper()) and set there new class which will implement IViewTranslation
getBackButtonTranslationWrapper()
.setEnterTranslation(new IViewTranslation() {
@Override
public void translate(View view, @FloatRange(from = 0, to = 1.0) float percentage) {
view.setAlpha(percentage);
}
});
getNextButtonTranslationWrapper()getBackButtonTranslationWrapper()getPageIndicatorTranslationWrapper()getViewPagerTranslationWrapper()getSkipButtonTranslationWrapper()backgroundColor()buttonsColor()canMoveFurther() (only if you want to stop user from being able to move further before he will do some action)cantMoveFurtherErrorMessage() (as above)<agency.tango.materialintroscreen.parallax.ParallaxLinearLayout
xmlns:android="http://schemas.android.com/apk/res/android">
<ImageView
android:id="@+id/image_slide"
app:layout_parallaxFactor="0.6"/>
All features which are not available in simple Slide Fragment are shown here: Custom Slide
To report a specific problem or feature request, open a new issue on Github.
Here you can see open source work developed by Tango Agency.
Whether you're searching for a new partner or trusted team for creating your new great product we are always ready to start work with you.
You can contact us via [email protected]. Thanks in advance.
1,026 followers · starred Oct 2016
98 followers · starred Dec 2020
113 followers · starred Sep 2016
16 followers · starred Jun 2017