Pen Settings

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

You're using npm packages, so we've auto-selected Babel for you here, which we require to process imports and make it all work. If you need to use a different JavaScript preprocessor, remove the packages in the npm tab.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Use npm Packages

We can make npm packages available for you to use in your JavaScript. We use webpack to prepare them and make them available to import. We'll also process your JavaScript with Babel.

⚠️ This feature can only be used by logged in users.

Code Indentation

     

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

HTML Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

            
              <button class="btn btn-primary">4 seconds</button>
            
          
!
            
              body {
  padding: 2em;
}

[data-notify="container"] {
  background: linear-gradient(132.63deg, #D5625F 89.02%, #C72E29 129.69%), #FFFFFF;
  border-radius: 3px;
  padding: 0.7em 1.2em;
  border: none;
  font-size: 16px;
  color: white;
}
.alert {
  opacity: 0.3;
}


            
          
!
            
              $(function(){
  const messages = [
    "Liability insurance is designed to offer specific protection against third-party insurance claims.",
    "Commercial liability is an important segment for the insurance industry.",
    "The US is by far the largest market, with 51% of the global liability premiums written in 2013.",
    "Japan and Australia are the largest markets in the Asia Pacific region.",
    "The duty to defend is generally broader than the duty to indemnify, because most (but not all) policies that provide for such a duty also specifically promise to defend against claims that are groundless, false, or fraudulent.",
    "The insurer can also seek a declaratory judgment.",
    "An indemnity case arises when an individual is obliged to pay for the loss or damage incurred by another person in an event of an accident, collision etc.",
    "In some jurisdictions, there is a third duty, the duty to settle a reasonably clear claim against the insured.",
    "Traditionally, liability insurance was written on an occurrence basis.",
    "General Liability Insurance is the kind of coverage that provides an individual with protection against variety of claims which may include bodily injuries, physical damage to car, property damage etc arising from business operations.",
    "U.S. workers' compensation insurance generally covers only bodily injury to and death of employees",
    "During the 1980s, as U.S. employees began to obtain jury verdicts against their employers more frequently.",
    "In the United States, most states make only the carrying of motor vehicle insurance mandatory.",
    "Because technology companies represent a relatively new industry that deals largely with intangible yet highly valuable data, some definitions of legal liability may still be evolving in this field.",
    "A Cumis counsel is an attorney employed by a defendant",
    "Professional liability insurance is a form of liability insurance which helps protect professional advice- and service-providing individuals and companies"
    

  ];
  $(".btn").on("click",function(){
    for (let i = 0; i < 3; i++) {
      // const index = Math.floor(Math.random() * messages.length);
      // console.log(index, messages[index]);
      setTimeout(() => {
        $.notify({
          // Options
          // title: "Rating",
          message: messages[Math.floor(Math.random() * messages.length)]
        },{
          // Settings
          type: 'danger',
          animate: {
            enter: 'animated fadeInUp',
            exit: 'animated fadeOutRight'
          },
          placement: {
            from: "bottom",
            align: "right"
          },
          offset: 20,
          spacing: 3,
          z_index: 1031,
          delay: 4000,
          mouse_over: 'pause',
          showProgressbar: false,
        });
      }, 1000 * i);
    }
  });
});

            
          
!
999px
🕑 One or more of the npm packages you are using needs to be built. You're the first person to ever need it! We're building it right now and your preview will start updating again when it's ready.

Console