GithubHelp home page GithubHelp logo

oncebot / popbox.js Goto Github PK

View Code? Open in Web Editor NEW
296.0 10.0 17.0 1.43 MB

A tiny and simple stackable modal plugin for web apps

License: MIT License

JavaScript 100.00%
modal modal-plugin modal-dialogs popup-window popup

popbox.js's People

Contributors

oncebot avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

popbox.js's Issues

NPM Package.

Hi there,
Do you have any plans to make this a npm/yarn package?

Popbox prevents submit event to be triggered

Hi, the e.preventDefault(); on line 45 of popbox.js, prevents events such as submit() from jQuery to be fired. I'm not sure why it is there in the first place, but had no other solution to remove it from the code.

Initialize new content loaded by ajax

Is it currently possible to initialize new popups dynamically loaded via ajax without creating a new instance?

When I do

<script type="text/javascript">
  var popbox = new Popbox({
        blur:true,
        overlay:true,
      });
</script>

again the plugin is initialized twice -> all event handlers will execute multiple times instead of just once so I need to unbind all of them.
I searched in the code but I wasn't able to spot something useful, do I need to fork it and include the feature on my own?

Unable to toggle checkbox

This modal plugin is awesome but I am blocked with 1 issue. I can't toggle checkbox inside this popbox. If checked it can not be unchecked and if unchecked I can not make it checked.

<div class="popbox" data-popbox-id="manageGroupModalConfirm">
    <div class="popbox-content bg-white">
      <div class="modal-body">
        <input type="checkbox">
        <div class="custom-control custom-checkbox">
          <label class="custom-control-label" for="manageGroupDontShow">Don’t show this message again</label>
        </div>
      </div>
      <div class="modal-footer">
        <button type="button" class="btn btn-primary" data-popbox-close="manageGroupModalConfirm">Ok</button>
      </div>
    </div>
</div>

How to listen to emitted events ?

Hello,

I have some youtube video playing inside a popbox modal. I want to pause the video when closing the modal.
I'm trying to listen to event popbox_closing like so :
var popbox = new Popbox(); popbox.addEventListener('popbox_closing', function () { video.pause(); }, false);

But it's not working :
popbox.addEventListener is not a function

What should I do ?

Thanks

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.