Pen Settings

HTML

CSS

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

JavaScript

Babel is required to process package imports. If you need a different preprocessor remove all packages first.

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

Behavior

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.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <html lang="en">

<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1">
  <title>Cards - UIkit 3 KickOff</title>
  <link rel="icon" href="img/favicon.ico">
  <!-- CSS FILES -->
  <link rel="stylesheet" type="text/css" href="https://cdnjs.cloudflare.com/ajax/libs/uikit/3.0.0-rc.2/css/uikit.min.css">
  <link rel="stylesheet" type="text/css" href="css/cards.css">
  <script src="https://cdn.jsdelivr.net/npm/vue-resource@1.5.1"></script>

</head>

<body>
  <div class="uk-offcanvas-content">
    <!--HEADER-->
    <header id="site-head">
      <div class="uk-container uk-container-expand">
        <div class="uk-grid uk-grid-medium uk-flex uk-flex-middle" data-uk-grid>
          <div class="uk-width-auto">
            <a href="#" class="uk-logo" title=""><img src="img/logo.svg" alt=""></a>
          </div>
          <div class="uk-width-expand">
            <form action="cards.html">
              <div class="uk-inline uk-width-1-1">
                <span class="uk-form-icon uk-form-icon-flip" data-uk-icon="icon: search"></span>
                <input class="uk-input uk-width-1-1 search-fld" type="search" placeholder="Search...">
              </div>
            </form>
          </div>
          <div class="uk-width-auto">
            <ul class="uk-subnav" data-uk-margin>
              <li class="uk-visible@s"><a href="#">Home</a></li>
              <li class="uk-visible@s"><a href="#">About Us</a></li>
              <li class="uk-visible@s">
                <a href="#" data-uk-icon="icon:comments"></a>
                <div class="drop-nav drop-comments uk-dropdown" data-uk-dropdown="mode: click; offset: 20;animation: uk-animation-slide-bottom-small; duration: 150">
                  <ul class="uk-child-width-expand" data-uk-tab="animation: uk-animation-fade">
                    <li><a href="#">Your Messages</a></li>
                    <li><a href="#">Activity</a></li>
                  </ul>
                  <ul class="uk-switcher uk-margin">
                    <li class="uk-height-small uk-overflow-auto">
                      <div class="message">
                        Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum...<a href="" class="uk-link">VIEW MESSAGE</a>
                      </div>
                      <div class="message">
                        Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum...<a href="" class="uk-link">VIEW MESSAGE</a>
                      </div>
                      <div class="message">
                        Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum...<a href="" class="uk-link">VIEW MESSAGE</a>
                      </div>
                      <div class="message">
                        Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum...<a href="" class="uk-link">VIEW MESSAGE</a>
                      </div>
                    </li>
                    <li>Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</li>
                  </ul>
                </div>
              </li>
              <li class="uk-visible@s">
                <a href="#" data-uk-icon="icon:more"></a>
                <div class="drop-nav uk-dropdown" data-uk-dropdown="mode: click; offset: 20;animation: uk-animation-slide-bottom-small; duration: 150">
                  <h4 class="uk-margin-small-bottom uk-margin-remove-adjacent">Lorem ipsum dolor sit amet, consectetur adipisicing elit.</h4>
                  <p class="uk-text-small uk-text-muted">Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>
                  <hr>
                  <a href="#" class="uk-button uk-button-primary uk-width-1-1">UPDATE YOUR ACCOUNT</a>
                  <hr>
                  <ul class="uk-nav-default uk-nav-parent-icon" data-uk-nav>
                    <li class="uk-nav-header">Header</li>
                    <li><a href="#"><span class="uk-margin-small-right" data-uk-icon="icon: table"></span> Item</a></li>
                    <li><a href="#"><span class="uk-margin-small-right" data-uk-icon="icon: thumbnails"></span> Item</a></li>
                    <li class="uk-nav-divider"></li>
                    <li><a href="#"><span class="uk-margin-small-right" data-uk-icon="icon: trash"></span> Item</a></li>
                  </ul>
                </div>
              </li>
              <li class="uk-hidden@s"><a data-uk-navbar-toggle-icon data-uk-toggle href="#offcanvas-nav"></a></li>
            </ul>
          </div>
        </div>
      </div>
    </header>
    <!--/HEADER-->
    <div class="spacer"></div>
    <!--CARDS WRAPPER-->
    <section class="uk-section uk-section-small uk-section-default uk-padding-remove-bottom" data-uk-filter="target: .js-filter">
      <div class="uk-container uk-container-expand uk-margin-large-bottom">
        
        
        
        
        <ul class="uk-subnav uk-subnav-pill">
          <li class="uk-active" data-uk-filter-control><a href="#">Show All</a></li>
          <li data-uk-filter-control=".nature-card"><a href="#">Nature</a></li>
          <li data-uk-filter-control=".music-card"><a href="#">Music</a></li>
          <li data-uk-filter-control=".photo-card"><a href="#">Photography</a></li>
          <li data-uk-filter-control=".design-card"><a href="#">Design</a></li>
        </ul>
        <hello></hello>
      </div>
    </section>
    <!--/CARDS WRAPPER-->

    <div id="app"></div>
    <!--FOOTER-->
    <footer id="site-foot" class="uk-section uk-section-secondary uk-section-xsmall">
      <div class="uk-container uk-text-small uk-text-center">
        <a href="https://github.com/zzseba78/Kick-Off">Created by KickOff</a> | Built with <a href="http://getuikit.com" title="Visit UIkit 3 site" target="_blank" data-uk-tooltip><span data-uk-icon="uikit"></span></a>
      </div>
    </footer>
    <!--/FOOTER-->
    <!-- OFFCANVAS -->
    <div id="offcanvas-nav" data-uk-offcanvas="flip: true; overlay: true">
      <div class="uk-offcanvas-bar uk-offcanvas-bar-animation uk-offcanvas-slide">
        <button class="uk-offcanvas-close uk-close uk-icon" type="button" data-uk-close></button>
        <ul class="uk-nav uk-nav-default">
          <li class="uk-active"><a href="#">Active</a></li>
          <li class="uk-parent">
            <a href="#">Parent</a>
            <ul class="uk-nav-sub">
              <li><a href="#">Sub item</a></li>
              <li><a href="#">Sub item</a></li>
            </ul>
          </li>
          <li class="uk-nav-header">Header</li>
          <li><a href="#js-options"><span class="uk-margin-small-right uk-icon" data-uk-icon="icon: table"></span> Item</a></li>
          <li><a href="#"><span class="uk-margin-small-right uk-icon" data-uk-icon="icon: thumbnails"></span> Item</a></li>
          <li class="uk-nav-divider"></li>
          <li><a href="#"><span class="uk-margin-small-right uk-icon" data-uk-icon="icon: trash"></span> Item</a></li>
        </ul>
        <h3>Title</h3>
        <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</p>
      </div>
    </div>
    <!-- /OFFCANVAS -->
  </div>
  <!-- JS FILES -->
  <script src="https://cdnjs.cloudflare.com/ajax/libs/uikit/3.0.0-rc.2/js/uikit.min.js"></script>
  <script src="https://cdnjs.cloudflare.com/ajax/libs/uikit/3.0.0-rc.2/js/uikit-icons.min.js"></script>

</body>

</html>
              
            
!

CSS

              
                @import url("https://cdnjs.cloudflare.com/ajax/libs/uikit/2.27.5/css/uikit.min.css"); /* Using a url */
#site-head {
	padding: 10px 0;
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 99;
	background-color: white;
	border-bottom: 1px solid rgba(0,0,0,0.06);
}
#site-foot {
	position: fixed;
	z-index: 3;
	bottom: 0;
	left: 0;
	right: 0;
	font-size: 0.8rem;
}
.uk-section-xsmall {
    padding-top: 0.6rem;
    padding-bottom: 0.6rem;
}
.uk-logo img {
	width: 50px;
}
.spacer {
	height: 60px;
}
.uk-card {
	border-top: 2px solid;
	position: relative;
	-webkit-transition: box-shadow 0.15s ease-out;
	transition: box-shadow 0.15s ease-out;
	border-radius: 3px;
}
.uk-card:hover {
	box-shadow: 0 0 0 7px rgba(0,0,0,0.045);
}
.uk-card .uk-inline {
	z-index: 99;
}
.uk-card .uk-card-footer {
	padding: 0.55rem 1rem;
}
.uk-card .uk-card-header {
	padding: 0.55rem 1rem;
}
.uk-card .cat-txt {
	font-weight: 600;
	text-transform: uppercase;
	font-size: 0.75rem;
	letter-spacing: 0.01em;
}
.nature-card .uk-card {
	border-top-color: #1E87F0;
}
.uk-subnav li a {
	border-radius: 3px; 
}
.uk-subnav li.uk-active:nth-child(3) a {
	background-color:#8630F0;
}
.uk-subnav li.uk-active:nth-child(4) a {
	background-color:#F03A7F;
}
.uk-subnav li.uk-active:nth-child(5) a {
	background-color:#E84DF0;
}
.nature-card .uk-card .cat-txt {
	color: #1E87F0;
}
.music-card .uk-card {
	border-top-color: #8630F0;
}
.music-card .uk-card .cat-txt {
	color: #8630F0;
}
.design-card .uk-card {
	border-top-color: #E84DF0;
}
.design-card .uk-card .cat-txt {
	color: #E84DF0;
}
.photo-card .uk-card {
	border-top-color: #F03A7F;
}
.photo-card .uk-card .cat-txt {
	color: #F03A7F;
}
.uk-card .uk-overlay-primary {
	padding:  0.5rem;
	text-align: center;
	font-size: 0.7rem;
	text-transform: uppercase;
	opacity: 0.7;
}
img[data-src][src*='data:image'] { background: rgba(0,0,0,0.1); }
.search-fld {
	border-radius: 50px;
	padding: 0 1rem;
}
.uk-dropdown.drop-nav {
	border-radius: 4px;
	box-shadow: 0 2px 24px rgba(0,0,0,.1);
	width: 300px;
}
.uk-dropdown.drop-comments {
	width: 370px;
}
.drop-nav::after {
	bottom: 100%;
	right: 4%;
	border: solid transparent;
	content: '';
	height: 0;
	width: 0;
	position: absolute;
	pointer-events: none;
	border-color: rgba(255, 255, 255, 0);
	border-bottom-color: #ffffff;
	border-width: 6px;
	margin-left: -6px;
}
.uk-dropdown.uk-dropdown-right-center::after {
	right: 100%;
	top: 50%;
	border: solid transparent;
	content: " ";
	height: 0;
	width: 0;
	position: absolute;
	pointer-events: none;
	border-color: rgba(255, 255, 255, 0);
	border-right-color: #ffffff;
	border-width: 6px;
	margin-top: -6px;
}
.uk-dropdown.uk-dropdown-left-center::after {
	left: 100%;
	top: 50%;
	border: solid transparent;
	content: " ";
	height: 0;
	width: 0;
	position: absolute;
	pointer-events: none;
	border-color: rgba(255, 255, 255, 0);
	border-left-color: #ffffff;
	border-width: 6px;
	margin-top: -6px;
}
.message {
	font-size: 0.85rem;
	display: block;
	line-height: 1.3rem;
	padding: 0.5rem 0;
}


              
            
!

JS

              
                
const Hello = Vue.extend({
  template: `
<div class="uk-grid uk-grid-medium uk-child-width-1-2@s uk-child-width-1-3@m uk-child-width-1-4@l  uk-child-width-1-6@xl uk-grid-match js-filter" data-uk-grid="masonry: true" data-uk-sortable="handle: .drag-icon">
    <div  v-for="item in items" class="nature-card">
        <div class="uk-card uk-card-small uk-card-default">
            <div class="uk-card-header">

                <div class="uk-grid uk-grid-small uk-text-small" data-uk-grid>
                    <div class="uk-width-expand">
                        <span class="cat-txt">Nature / Outdoor</span>
                    </div>
                    <div class="uk-width-auto uk-text-right uk-text-muted">
                        <span data-uk-icon="icon:clock; ratio: 0.8"></span> 3 min.
                    </div>
                </div>
            </div>
            <div class="uk-card-media">
                <div class="uk-inline-clip uk-transition-toggle" tabindex="0">
                    <img class="lazy" data-src="https://picsum.photos/400/300/?random=5" data-width="400" data-height="300" data-uk-img alt="" src="img/transp.gif">
                    <div class="uk-transition-slide-bottom uk-position-bottom uk-overlay uk-overlay-primary">
                        <span data-uk-icon="icon:heart; ratio: 0.8"></span> 12.345 <span data-uk-icon="icon:comment; ratio: 0.8"></span> 12.345
                    </div>
                </div>
            </div>
            <div class="uk-card-body">
                <h6 class="uk-margin-small-bottom uk-margin-remove-adjacent uk-text-bold">
{{ item.title }}
</h6>
                <p class="">{{ item.synopsis }}</p>
            </div>
            <div class="uk-card-footer">
                <div class="uk-grid uk-grid-small uk-grid-divider uk-flex uk-flex-middle" data-uk-grid>
                   
            </div>
        </div>
    </div>
    <!-- /card -->
</div>
<div class=""></div>
<button v-on:click="greet">Load more</button>
`,
  data () {
    return {
      name: 'Hello!',
      items:[],
      loadPage:''
    }
  },
      /**
         *
         */
 created: function () {
   // GET /someUrl
    this.$http.get('https://tv-v2.api-fetch.website/movies/1').then(response => {


      this.items = response.data;

       console.log(this.items);

    }, response => {
      // error callback
    });


  },
  
   methods: {
    greet: function (event) {
    
      
      
      
       // GET /someUrl
    this.$http.get('https://tv-v2.api-fetch.website/movies/1').then(response => {


      this.items = this.items.concat(response.data);

       console.log(this.items);

    }, response => {
      // error callback
    });

      
    }
  }

})

new Vue({
  el: 'hello',
  components: {
    Hello
  }
})

              
            
!
999px

Console