lohanidamodar/flutter_ui_challenges

custom swiper pagination issue.

suresh-kumara-gist opened this issue · 5 comments

import 'package:flutter_ui_challenges/src/widgets/swiper_pagination.dart';

I have changed item count to 6. But I can see only 3 pagination items .

int itemCount = config.itemCount;
int activeIndex = config.activeIndex;

itemCount is printing 3 instead of 6.
activeIndex is printing 0,1,2 instead of 0,1,2,3,4,5 .

I/flutter (16370): Another exception was thrown: RangeError (index): Invalid value: Not in range 0..2, inclusive: 5

Please post with your code.

@suresh-kumara-gist I am closing this issue as there wasn't any more interaction. If you still have the issue, feel free to reopen the issue with more details and runnable code that you used.

Sorry delay in replay.

I have cloned complete git repo of https://github.com/lohanidamodar/flutter_ui_challenges.git

this is the file having issue its seems. lib/src/widgets/swiper_pagination.dart

Please change itemCount greater than 6 (images) from 3 .

I have changed item count to 6. But I can see only 3 pagination items .

in file lib/src/widgets/swiper_pagination.dart

int itemCount = config.itemCount;
int activeIndex = config.activeIndex;

itemCount is printing 3 instead of 6.
activeIndex is printing 0,1,2 instead of 0,1,2,3,4,5 .

Please provide the exact code you are using, because if it's not working it's because there's something missing..or misconfigured..
Where have you changed the item count from 3 to 6?