Skip to content

Instantly share code, notes, and snippets.

@edwardlorilla
edwardlorilla / center search form.html
Last active October 16, 2017 14:28
center search for search form in HAGO project
<v-ons-toolbar>
<div class="center" style="padding-top:4px;"><v-ons-search-input style="" placeholder="Search something"></v-ons-search-input></div>
</v-ons-toolbar>
<p style="display: flex;justify-content: center; ">
<v-ons-search-input style="width: 90%;" placeholder="Search something"></v-ons-search-input>
</p>
@edwardlorilla
edwardlorilla / index.html
Created October 23, 2017 13:03
nearest multiple color vue
<div id="app">
<div id="pallete" >
<div v-for="pallete in palletes" class="base_color" :style="{'background-color': 'rgb(' + pallete.join( ', ') + ')' }">
</div>
</div>
<div v-if="!image">
<h2>Select an image</h2>
<input type="file" @change="onFileChange">
</div>
@edwardlorilla
edwardlorilla / index.html
Created November 24, 2017 15:22
Vue localstorage plugin
<div id="app">
counter: {{setCounter}}
<div>
<button type="button" @click="increment()">Increment</button>
<button type="button" @click="decrement()">Decrement</button>
</div>
</div>
@edwardlorilla
edwardlorilla / index.html
Created November 25, 2017 11:26
Perform CRUD Operations with Local Storage Data Vuejs
<div id="app">
<input type="text" v-model="todo.title" placeholder="input todo"
v-on:keyup.enter="addTodo"
>
<ul>
<li v-for="(todo, index) in todos">
<input v-if="todo.edit" type="text" v-model="todo.title">
<span v-else>{{todo.title}} </span>
@edwardlorilla
edwardlorilla / index.html
Last active May 9, 2022 08:49
velocity vuejs
<div id="app">
<div id="div1" ref="expandBox" class="box"></div>
<div ref="expandBoxTwo" class="box"></div>
<button @click="expandBox">expandBox</button>
</div>
@edwardlorilla
edwardlorilla / index.html
Created December 6, 2017 14:14
vuejs velocityjs transition
<template id='image'>
<img ref="imgs" alt=""/>
</template>
<div id="app">
<transition mode="out-in"
v-on:before-enter="beforeEnter"
v-on:enter="enter"
v-on:leave="leave"
>
@edwardlorilla
edwardlorilla / index.html
Created December 16, 2017 03:12
VueJS FireBase
<template id='register-form'>
<div>
<div class="panel-body">
<div class="form-group">
<label for="user">Name:</label>
<input v-model="name" type="text" class="form-control" id="user">
</div>
<div class="form-group">
<label for="email">Email:</label>
<input v-model="email" type="email" class="form-control" id="email">
@edwardlorilla
edwardlorilla / index.html
Last active December 20, 2017 14:07
quiz-list test
<template id="create-incorrect-question">
<li>
<input type="checkbox" :id="value" :value="value" v-model="internalValue">
<label :for="value">{{value}}</label>
</li>
</template>
<template id="preview-quiz">
<div >
<a v-if="remove" @click="remove(quiz.key, index)">&times;</a>
function multiFilter(array, filters) {
var filterKeys = Object.keys(filters);
return array.filter(function (eachObj) {
return filterKeys.every(function (eachKey) {
if (!filters[eachKey].length) {
return true; // passing an empty filter means that filter is ignored.
}
return _.isArray(eachObj[eachKey]) ?
eachObj[eachKey].some(function (o) {