Giter Club home page Giter Club logo

Comments (6)

leecade avatar leecade commented on July 2, 2024

thanks, @aksonov

For custom label string with X/Y, my option is add a prop pagination(function type), like:

var renderPagination = function(index, total) {
  return <View style={{}}><Text>{index}/{total}</Text></View>
}
<Swiper pagination={renderPagination}>
        <View style={styles.slide1}>
          <Text style={styles.text}>Hello Swiper</Text>
        </View>
      </Swiper>

And your opinion?

from react-native-swiper.

aksonov avatar aksonov commented on July 2, 2024

Sounds great!

Sent from my iPhone

On 24 апр. 2015, at 22:09, 斯人 [email protected] wrote:

thanks, Now the dot prop allow to custom element.

like:

<View style={{backgroundColor:'rgba(0,0,0,.2)', width: 8, height: 8,borderRadius: 4, marginLeft: 3, marginRight: 3, marginTop: 3, marginBottom: 3,}} />
For custom label string with X/Y, my option is allow dot / activeDot props supports function type, like:

var renderDot = function(index, total) {
return {index}/{total}
}


Hello Swiper


And your opinion?


Reply to this email directly or view it on GitHub.

from react-native-swiper.

leecade avatar leecade commented on July 2, 2024

OK. CI later

from react-native-swiper.

leecade avatar leecade commented on July 2, 2024

Sorry so late @aksonov , Now there is a new prop renderPagination done.

see https://github.com/leecade/react-native-swiper/blob/master/examples/examples/swiper_number.js

Update doc later, thanks your idea.

from react-native-swiper.

smithaitufe avatar smithaitufe commented on July 2, 2024

What if I need a custom pagination but also wants to render dots?

from react-native-swiper.

Hari70a avatar Hari70a commented on July 2, 2024

@leecade and @smithaitufe
I also want both custom pagination and render dots. Is it possible?

from react-native-swiper.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.