GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - AndroidPoet/Material-Intro: ☯️App intro with Material Motion Animations(No more viewpager transformer or Memory leak)

BranchesTags
Open more actions menu

Latest commit

 

History

38 Commits
38 Commits

Folders and files

NameName
Last commit message
Last commit date
app
app
 
 
gradle/wrapper
gradle/wrapper
 
 
materialintro
materialintro
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 
build.gradle
build.gradle
 
 
dependencies.gradle
dependencies.gradle
 
 
gradle.properties
gradle.properties
 
 
gradlew
gradlew
 
 
gradlew.bat
gradlew.bat
 
 
settings.gradle
settings.gradle
 
 
spotless.gradle
spotless.gradle
 
 
spotless.license.kt
spotless.license.kt
 
 
usecases.md
usecases.md
 
 

Repository files navigation

Material Intro

Sophisticated and cool intro with Material Motion Animations.

Google

License Profile



Who's using Material Intro?

👉 Check out who's using Material Intro

Include in your project

Maven Central

Gradle

Add the dependency below to your module's build.gradle file:

dependencies {
    implementation("io.github.androidpoet:materialintro:1.0.8")
}

SetUp for Views

<com.androidpoet.materialintro.MaterialIntroView
android:id="@+id/materialintroView"
android:layout_width="match_parent"
android:layout_height="match_parent">
</com.androidpoet.materialintro.MaterialIntroView>
//add views into list
  list.add(R.layout.layout_one)
  list.add(R.layout.layout_two)
  list.add(R.layout.layout_three)


   with(binding.materialintroView) {
      setViewsList(list)
      nextAnimation = IntroAnimation.Fade
      previousAnimation = IntroAnimation.Fade
      nextDuration = 500
      previousDuration = 500
    }


//  go next view with animation
binding.nextButton.setOnClickListener {
    binding.materialIntroFragment.next()
}

//  go previous view with animation
binding.backButton.setOnClickListener {
    binding.materialIntroFragment.previous()
}

SetUp for Fragments

<com.androidpoet.materialintro.MaterialIntroFragment
android:id="@+id/materialintroView"
android:layout_width="match_parent"
android:layout_height="match_parent">
</com.androidpoet.materialintro.MaterialIntroFragment>
//add fragments into list
list.add(FragmentOne())
list.add(FragmentTwo())
list.add(FragmentThree())
	
  binding.materialIntroFragment.apply {
      setFragmentsList(list)
      enterAnimation = IntroAnimation.SharedAxisXForward
     
      enterDuration = 500
   
    }


//  go next view with animation
binding.nextButton.setOnClickListener {
    binding.materialintroView.next()
}

//  go previous view with animation
binding.backButton.setOnClickListener {
    binding.materialintroView.previous()
}

Supported Animations

IntroAnimation.None
IntroAnimation.FadeThrough
IntroAnimation.Fade
IntroAnimation.SharedAxisXForward
IntroAnimation.SharedAxisYForward
IntroAnimation.SharedAxisZForward
IntroAnimation.SharedAxisXBackward
IntroAnimation.SharedAxisYBackward
IntroAnimation.SharedAxisZBackward
IntroAnimation.ElevationScaleGrow
IntroAnimation.ElevationScale

Create using Builder

We can create the MaterialIntro using MaterialIntro.Builder.

val meta = MaterialIntroFragment.Builder(this)
 .setFragmentsList(list)
.setEnterAnimation(IntroAnimation.Fade)
.setEnterDuration(300)
.setEnterOverlap(true)
.build()

meta.next()
meta.previous()

This is how to create an instance of the MaterialIntro using kotlin dsl.

val meta = materialIntroFragment(this) {
setFragmentsList(list)
setEnterAnimation(IntroAnimation.Fade)
setEnterDuration(300)
setEnterOverlap(true)
build()
}
meta.next()
meta.previous()

MaterialFade


Fade


SharedAxis


Card icons created by Freepik - Flaticon

Find this library useful? ❤️

Support it by joining stargazers for this repository. ⭐

Buy Me A Coffee

License

Copyright 2022 AndroidPoet (Ranbir Singh)

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

About

☯️App intro with Material Motion Animations(No more viewpager transformer or Memory leak)

Topics

androidandroid-libraryandroidpoetanimationintrokotlinmaterial-uimaterialanimationsmaterialintro

Resources

Readme
Activity

Stars

37 stars

Watchers

1 watching

Forks

2 forks
Report repository

Releases

Sponsor this project

Packages

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.