|
| 1 | +<template> |
| 2 | + <div id="app"> |
| 3 | + <!--Example dependecies--> |
| 4 | + <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bulma/0.4.1/css/bulma.min.css"> |
| 5 | + <link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet"> |
| 6 | + <a href="https://github.com/PygmySlowLoris/vue-ripple-directive"><img style="position: absolute; top: 0; right: 0; border: 0;" src="https://camo.githubusercontent.com/38ef81f8aca64bb9a64448d0d70f1308ef5341ab/68747470733a2f2f73332e616d617a6f6e6177732e636f6d2f6769746875622f726962626f6e732f666f726b6d655f72696768745f6461726b626c75655f3132313632312e706e67" alt="Fork me on GitHub" data-canonical-src="https://s3.amazonaws.com/github/ribbons/forkme_right_darkblue_121621.png"></a> |
| 7 | + |
| 8 | + <!--Example Elements--> |
| 9 | + <section class="hero"> |
| 10 | + <div class="hero-body" style="padding: 1rem 0"> |
| 11 | + <div class="container"> |
| 12 | + <div class="columns"> |
| 13 | + <div class="column is-6 is-offset-3" style="display: flex; align-items: center;"> |
| 14 | + <div class="is-pulled-left"> |
| 15 | + <img width="350px" src="./assets/logo.png"> |
| 16 | + </div> |
| 17 | + <div class="is-pulled-left" style="text-align: left"> |
| 18 | + <h1 class="title text-medium-grey" style="margin-bottom: .5rem"> |
| 19 | + Material Ripple Effect |
| 20 | + </h1> |
| 21 | + <hr class="is-marginless"> |
| 22 | + <h2 class="subtitle text-light-grey" style="margin-top: .5rem"> |
| 23 | + A Vue Directive |
| 24 | + </h2> |
| 25 | + </div> |
| 26 | + </div> |
| 27 | + </div> |
| 28 | + </div> |
| 29 | + </div> |
| 30 | + </section> |
| 31 | + |
| 32 | + <section class="section" style="padding-top: .5rem"> |
| 33 | + <div class="container"> |
| 34 | + <div class="columns"> |
| 35 | + <div class="column is-8 is-offset-2"> |
| 36 | + <div class="box formated"> |
| 37 | + <div class="heading"> |
| 38 | + <div class="columns"> |
| 39 | + <div class="column"> |
| 40 | + <i class="material-icons top-left">code</i> |
| 41 | + <span class="is-pulled-right"><b>Examples</b></span> |
| 42 | + </div> |
| 43 | + </div> |
| 44 | + </div> |
| 45 | + <div class="content"> |
| 46 | + <div class="columns"> |
| 47 | + <div class="column"> |
| 48 | + <div> |
| 49 | + <table class="table is-striped"> |
| 50 | + <thead> |
| 51 | + <tr v-ripple> |
| 52 | + <th>One</th> |
| 53 | + <th>Two</th> |
| 54 | + </tr> |
| 55 | + </thead> |
| 56 | + <tbody> |
| 57 | + <tr v-for="n in 2"> |
| 58 | + <td v-ripple>Yes ripple {{ n }}</td> |
| 59 | + <td>No ripple {{ n }}</td> |
| 60 | + </tr> |
| 61 | + </tbody> |
| 62 | + </table> |
| 63 | + </div> |
| 64 | + <div> |
| 65 | + <div v-ripple="'rgba(255, 255, 255, 0.35)'" class="button is-primary" style="margin: .5rem">This is a button</div> |
| 66 | + <a v-ripple="'rgba(230, 68, 3, 0.71)'" class="button is-success is-outlined" style="text-decoration: none; margin: .5rem">This is an Outlined</a> |
| 67 | + </div> |
| 68 | + <div> |
| 69 | + <span v-ripple="'rgba(99, 249, 8, 0.71)'" class="tag is-info pointer">Info</span> |
| 70 | + <span v-ripple class="tag is-success pointer">Success</span> |
| 71 | + <span v-ripple="'rgba(9, 249, 8, 0.71)'" class="tag is-primary is-medium pointer">Medium</span> |
| 72 | + <span v-ripple="'rgba(99, 9, 8, 0.71)'" class="tag is-info is-large pointer">Large</span> |
| 73 | + </div> |
| 74 | + </div> |
| 75 | + </div> |
| 76 | + <div class="columns"> |
| 77 | + <div class="column has-text-centered"> |
| 78 | + <a href="https://github.com/PygmySlowLoris/vue-ripple-directive">Code usage & samples</a> |
| 79 | + </div> |
| 80 | + </div> |
| 81 | + </div> |
| 82 | + </div> |
| 83 | + </div> |
| 84 | + </div> |
| 85 | + </div> |
| 86 | + </section> |
| 87 | + |
| 88 | + <footer class="footer"> |
| 89 | + <div class="container"> |
| 90 | + <div class="content has-text-centered"> |
| 91 | + <p> |
| 92 | + <strong>Material Ripple Effect Vue Directive</strong> by <a href="https://github.com/PygmySlowLoris">Pygmy Team</a>. |
| 93 | + </p> |
| 94 | + <p><small>Used dependencies for this demo: <a href="http://bulma.io">bulma</a></small></p> |
| 95 | + </div> |
| 96 | + </div> |
| 97 | + </footer> |
| 98 | + |
| 99 | + </div> |
| 100 | +</template> |
| 101 | + |
| 102 | +<script> |
| 103 | + export default { |
| 104 | + name: 'app', |
| 105 | + data(){ |
| 106 | + return { |
| 107 | + colors: '', |
| 108 | + updatedColor: '', |
| 109 | + newColor: '', |
| 110 | + } |
| 111 | + } |
| 112 | + } |
| 113 | +</script> |
| 114 | + |
| 115 | +<style scoped> |
| 116 | + #app { |
| 117 | + -webkit-font-smoothing: antialiased; |
| 118 | + -moz-osx-font-smoothing: grayscale; |
| 119 | + text-align: center; |
| 120 | + color: #2c3e50; |
| 121 | + } |
| 122 | +
|
| 123 | + .pointer { |
| 124 | + cursor: pointer; |
| 125 | + } |
| 126 | +
|
| 127 | + h1, h2 { |
| 128 | + font-weight: normal; |
| 129 | + } |
| 130 | +
|
| 131 | + hr { |
| 132 | + background-color: transparent; |
| 133 | + border: none; |
| 134 | + display: block; |
| 135 | + height: inherit; |
| 136 | + margin: 1.5rem 0; |
| 137 | + border-top: dashed 1px; |
| 138 | + } |
| 139 | +
|
| 140 | +
|
| 141 | + li { |
| 142 | + display: inline-block; |
| 143 | + margin: 0 10px; |
| 144 | + } |
| 145 | +
|
| 146 | + a { |
| 147 | + color: #0b99b9; |
| 148 | + text-decoration: underline; |
| 149 | + } |
| 150 | +
|
| 151 | + .text-medium-grey { |
| 152 | + color: #333; |
| 153 | + } |
| 154 | + |
| 155 | + .text-light-grey { |
| 156 | + color: #888; |
| 157 | + } |
| 158 | +
|
| 159 | + .box.formated { |
| 160 | + position: relative; |
| 161 | + padding: 0; |
| 162 | + } |
| 163 | +
|
| 164 | + .box.formated .heading { |
| 165 | + font-size: 1rem; |
| 166 | + text-transform: capitalize; |
| 167 | + padding: .8rem 1.5rem; |
| 168 | + background-color: #fafafa; |
| 169 | + } |
| 170 | +
|
| 171 | + .box.formated .content { |
| 172 | + padding: 1rem 2rem; |
| 173 | + } |
| 174 | +
|
| 175 | + i.top-left { |
| 176 | + position: absolute; |
| 177 | + left: 1.5rem; |
| 178 | + top: 0.8rem; |
| 179 | + } |
| 180 | +
|
| 181 | + .vertical-separator { |
| 182 | + display: flex; justify-content: space-around; |
| 183 | + } |
| 184 | +
|
| 185 | + .vertical-separator .line { |
| 186 | + border-right: 1px solid #cccccc; |
| 187 | + } |
| 188 | +</style> |
0 commit comments