GithubHelp home page GithubHelp logo

Comments (5)

compact avatar compact commented on August 26, 2024

Sorry, I don't understand. Can you show code or screenshots?

from angular-bootstrap-lightbox.

ThiagoJem avatar ThiagoJem commented on August 26, 2024

Hi compact,
First I want to thank you for providing this excellent tool.

I'll try to explain better (sorry , I understand little English ):
I have a pagination in my site(https://github.com/michaelbromley/angularUtils/tree/master/src/directives/pagination) the images that are on page 2 onwards , when clicked , opens the first image of page 1. I would like to open the corresponding image , how can I do this?

from angular-bootstrap-lightbox.

ThiagoJem avatar ThiagoJem commented on August 26, 2024

I posted a vídeo for demonstration, please view...

Link vídeo: http://tinypic.com/m/il9ceg/1

On page 1 the corresponding images to click open normally. On page 2 opens the corresponding images page 1.

from angular-bootstrap-lightbox.

compact avatar compact commented on August 26, 2024

It looks like you are using $index as in Lightbox.openModal(images, $index), but each page in the pagination starts it over at 0, so $index goes 0, 1, 0, 1, 0, 1... instead of 0, 1, 2, 3, 4, 5...

I found a relevant answer in that library: michaelbromley/angularUtils#76

Add this to your controller:

$scope.imageIndex = $scope.$index + ($scope.currentPage - 1) * $scope.pageSize;

Then change your $index to imageIndex.

from angular-bootstrap-lightbox.

ThiagoJem avatar ThiagoJem commented on August 26, 2024

It did not work.
I thought better and I will make content open on another page , I will most benefit and ease in other implementations. Valeu, abraço!

from angular-bootstrap-lightbox.

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.