animatedModal.js | Buku Catatan si Ugi
27
May

AnimatedModal.js adalah plugin jQuery untuk membuat modal layar penuh dengan transisi CSS3.

Anda dapat menggunakan transisi dari animate.css atau membuat transisi Anda sendiri.


DOWNLOAD VERSION 1.0


  • DEMO 01

  • animatedIn: 'zoomIn',

    animatedOut: 'bounceOut'

  • DEMO 02

  • animatedIn: lightSpeedIn

    animatedOut: bounceOutDown

  • DEMO 03

  • animatedIn: bounceIn

    animatedOut: bounceOut


1. Sertakan Animate.css di dalam tag <head>


<head>
  <link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/animate.css/3.2.0/animate.min.css">
</head>

2. Sertakan contoh syntax berikut ini dalam tag <body>


<body>
    <!--Call your modal-->
    <a id="demo01" href="#animatedModal">DEMO01</a>

    <!--DEMO01-->
    <div id="animatedModal">
        <!--THIS IS IMPORTANT! to close the modal, the class name has to match the name given on the ID  class="close-animatedModal" -->
        <div class="close-animatedModal"> 
            CLOSE MODAL
        </div>
            
        <div class="modal-content">
                  <!--Your modal content goes here-->
        </div>
    </div>
</body>

3. Sertakan Libraries berikut di bagian bawah tag </ body>


<body>
  <script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
  <script src="yourPath/animatedModal.min.js"></script>
</body>


4. Inisialisasi Dasar


<script>
  $("#demo01").animatedModal();
</script>

Options

VariableDefault ValueOptionsDescription
modalTargetanimatedModalCustomize your target
color#39BEB9HEX, HSL, RGB, RBADefine background color
animatedInzoomInChooseHereTransition when the modal goes in
animatedOutzoomOutChooseHereTransition when the modal goes out
animationDuration.6ssecondsAnimation duration
overflowautoscroll; hidden; auto;This makes your modal scrollable or not

5. Contoh Implementasi


        <script>

            //demo 02
            $("#demo02").animatedModal({
                modalTarget:'modal-02',
                animatedIn:'lightSpeedIn',
                animatedOut:'bounceOutDown',
                color:'#3498db',
                // Callbacks
                beforeOpen: function() {
                    console.log("The animation was called");
                },           
                afterOpen: function() {
                    console.log("The animation is completed");
                }, 
                beforeClose: function() {
                    console.log("The animation was called");
                }, 
                afterClose: function() {
                    console.log("The animation is completed");
                }
            });

        </script>
sumber:joaopereirawd











0 komentar:

Post a Comment



Catatan :

Untuk menyisipkan gambar kedalam komentar, gunakan tag : [img]URL_Gambar[/img]
atau <i rel="image">URL_Gambar</i>
Untuk Video Youtube : [youtube]URL_Video[/youtube]
atau <i rel="youtube">URL_Video</i>
Untuk "Kutipan", gunakan : [blockquote]Kutipan_Anda[/blockquote]
atau <b rel="quote">Kutipan_Anda</b>
Untuk menyisipkan Kode: [code]KODE[/code]
atau <i rel="code">KODE</i>
atau <i rel="pre">KODE</i>
Dan untuk menyisipkan smiles/ emoticon, lihat kode Emoticon







:) :)) ;(( :-) =)) ;( ;-( :d :-d @-) :p :o :>) (o) [-( :-? (p) :-s (m) 8-) :-t :-b b-( :L :M :N :t :s :Q :R :x :y :z :-# =p~ $-) (b) (f) x-) (k) (h) (c) cheer lel lol mpok
Click an Emoticon to view Code
Untuk memasukkan emoticon kedalam komentar, sisipkan kode emot dan berikan spasi sebelumnya.

 

Anda sudah mengaktifkan penyaringan konten ( AdBlocker di Aktifkan )

Mohon maaf untuk sementara Anda tidak dapat melihat halaman ini, silahkan kembali lagi setelah Anda menonaktifkan filter yang Anda gunakan. Abaikan