Search code examples
htmlangularjsmagnific-popup

Magnific Popup not working in small screen


I can use magnificPopup directive in html as attribute. It's working in browser but it's not working in mobile.

angular.module('App')
        .directive('magnificPopup', function () {
            'use strict';

            return {
                restrict: 'A',
                link: function (scope, element, attrs) {
                    element.magnificPopup({
                        type: 'image'
                    });
                }
            };
        });

Solution

  • need to install magnificpopup, write command in

    bower install magnific-popup
    
    {
      "name": "magnific-popup",
      "main": [
        "dist/jquery.magnific-popup.js",
        "dist/magnific-popup.css"
      ],
      "dependencies": {
        "jquery": ">=1.8.0"
      },
      "ignore": [
        "node_modules/",
        "components/",
        "website/",
        "libs/"
      ]
    }