triniwiz / nativescript-pager

Apache License 2.0
90 stars 48 forks source link

Documentation #169

Open henrikruscon opened 4 years ago

henrikruscon commented 4 years ago

Am I blind or is there no documentation page? Can't seem to get any information on how to display indicators on iOS with nativescript-vue.

triniwiz commented 4 years ago

No full docs but in the demo should have some examples

henrikruscon commented 4 years ago

Doesn't seem like showIndicator does anything on iOS (Vue)? @triniwiz

triniwiz commented 4 years ago

You have the following options

                 showIndicator="true"
                 indicator="worm"
                 indicatorColor="red"
                 indicatorSelectedColor="blue"
henrikruscon commented 4 years ago

Thanks for the help, but even with those options no indicator is seen, how does it know where to put the indicator?

<Pager
                class="pager"
                row="1"
                :selectedIndex="0"
                showIndicator="true"
                indicator="worm"
                indicatorColor="red"
                indicatorSelectedColor="blue"
            >
                <PagerItem>
                    <GridLayout rows="auto, auto">
                        <Label class="title" row="0" textWrap="true">Upptäck ditt drömhem</Label>
                        <Label class="paragraph" row="1" textWrap="true">Ett drömhem är bara en liten svamp bort - hoppa ner i kaninhålet med oss</Label>
                    </GridLayout>
                </PagerItem>
                <PagerItem>
                    <GridLayout rows="auto, auto">
                        <Label class="title" row="0" textWrap="true">Upptäck ditt drömhem</Label>
                        <Label class="paragraph" row="1" textWrap="true">Ett drömhem är bara en liten svamp bort - hoppa ner i kaninhålet med oss</Label>
                    </GridLayout>
                </PagerItem>
                <PagerItem>
                    <GridLayout rows="auto, auto">
                        <Label class="title" row="0" textWrap="true">Upptäck ditt drömhem</Label>
                        <Label class="paragraph" row="1" textWrap="true">Ett drömhem är bara en liten svamp bort - hoppa ner i kaninhålet med oss</Label>
                    </GridLayout>
                </PagerItem>
                <PagerItem>
                    <GridLayout rows="auto, auto">
                        <Label class="title" row="0" textWrap="true">Upptäck ditt drömhem</Label>
                        <Label class="paragraph" row="1" textWrap="true">Ett drömhem är bara en liten svamp bort - hoppa ner i kaninhålet med oss</Label>
                    </GridLayout>
                </PagerItem>
            </Pager>
triniwiz commented 4 years ago

Ah you are using the static version there might be a bug I’ll confirm in a bit

henrikruscon commented 4 years ago

Tried using the loop version instead and still no indicator. Not sure what I'm doing wrong.

<Pager
                for="item in items"
                class="pager"
                row="1"
                showIndicator="true"
                indicator="worm"
                indicatorColor="red"
                indicatorSelectedColor="pink"
            >
                <v-template>
                    <GridLayout class="pager-item" rows="auto, auto">
                        <Label class="title" :text="item.title" row="0" textWrap="true" />
                        <Label class="paragraph" :text="item.paragraph" row="1" textWrap="true" />
                    </GridLayout>
                </v-template>
            </Pager>
wuilmerj24 commented 4 years ago

Hi @triniwiz in static it does not show the indicator.