├── .gitignore ├── README.md ├── css └── styles.css ├── images ├── beer_celebration.svg ├── favicon.png └── trash.svg └── index.html /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Todo List with Vue.js 2 | 3 | A simple in-browser todo list that saves your todos in Local storage. 4 | 5 | Made to make life and day-to-day work a little bit easier! 6 | 7 | [Check it out here!](https://nourabusoud.github.io/vue-todo-list/) 8 | -------------------------------------------------------------------------------- /css/styles.css: -------------------------------------------------------------------------------- 1 | *{ 2 | box-sizing: border-box; 3 | } 4 | 5 | body{ 6 | font-size: 15px; 7 | font-family: 'Open Sans', sans-serif; 8 | color: #444; 9 | background-color: #fefefe; 10 | background-image: linear-gradient(#fc6c48 0%, #ef5081 100%); 11 | background-repeat: no-repeat; 12 | background-size: cover; 13 | padding: 50px 20px; 14 | margin: 0; 15 | min-height: 100vh; 16 | position: relative; 17 | } 18 | 19 | h1{ 20 | color: #fff; 21 | text-align: center; 22 | margin-bottom: 40px; 23 | } 24 | .todo-wrapper{ 25 | width: 400px; 26 | max-width: 100%; 27 | min-height: 500px; 28 | margin: 20px auto 50px; 29 | border: 1px solid #eee; 30 | border-radius: 4px; 31 | padding: 40px 20px; 32 | -webkit-box-shadow: 0 0 15px 0 rgba(0,0,0,0.05); 33 | box-shadow: 0 0 15px 0 rgba(0,0,0,0.05); 34 | background-color: #f4f7fc; 35 | overflow: hidden; 36 | position: relative; 37 | } 38 | 39 | .todo-title{ 40 | font-size: 1.2em; 41 | color: #f65c65; 42 | font-weight: normal; 43 | } 44 | 45 | form{ 46 | overflow: overlay; 47 | } 48 | 49 | form label{ 50 | display: block; 51 | text-align: center; 52 | font-size: 1.2em; 53 | } 54 | 55 | .btn, input { 56 | line-height: 2em; 57 | border-radius: 3px; 58 | border: 0; 59 | display: inline-block; 60 | margin: 15px 0; 61 | padding: 0.2em 1em; 62 | font-size: 1em; 63 | } 64 | 65 | input[type='text'] { 66 | border: 1px solid #ddd; 67 | min-width: 80%; 68 | transition: all ease-in 0.25s; 69 | } 70 | 71 | input:focus{ 72 | outline: none; 73 | border: 1px solid #a3b1ff; 74 | } 75 | 76 | input::placeholder{ 77 | color: rgba(0,0,0,0.3); 78 | font-style: italic; 79 | } 80 | 81 | /* disable ios zoom on focus */ 82 | @media screen and (-webkit-min-device-pixel-ratio:0) { 83 | select, 84 | textarea, 85 | input { 86 | font-size: 16px; 87 | } 88 | } 89 | 90 | @media screen and (-webkit-min-device-pixel-ratio:0) { 91 | select:focus, 92 | textarea:focus, 93 | input:focus { 94 | font-size: 16px; 95 | } 96 | } 97 | 98 | 99 | .btn{ 100 | text-align: center; 101 | font-weight: bold; 102 | cursor: pointer; 103 | border-width: 1px; 104 | border-style: solid; 105 | } 106 | 107 | .btn-add { 108 | background: #ddd; 109 | color: #fefefe; 110 | border-color: #ddd; 111 | min-width: 17%; 112 | pointer-events: none; 113 | transition: all ease-in 0.25s; 114 | font-size: 2.2em; 115 | line-height: 0.5em; 116 | padding: 0.3em 0.3em; 117 | float: right; 118 | } 119 | 120 | .btn-add.active{ 121 | background: #6664ff; 122 | border-color: #6664ff; 123 | pointer-events: visible; 124 | } 125 | 126 | .btn-add.active:hover{ 127 | background: #4442f6; 128 | border-color: #4442f6; 129 | } 130 | 131 | .btn-add:active{ 132 | transform: scale(0.95); 133 | } 134 | 135 | .control-buttons{ 136 | position: absolute; 137 | bottom: 20px; 138 | left: 50%; 139 | transform: translateX(-50%); 140 | width: 100%; 141 | text-align: center; 142 | } 143 | .btn-secondary{ 144 | display: inline-block; 145 | position: relative; 146 | border: 0; 147 | padding: 0; 148 | margin: 0 10px; 149 | } 150 | 151 | .btn-secondary:after{ 152 | position: absolute; 153 | content: ''; 154 | width: 0; 155 | height: 3px; 156 | background-color: #f4586e; 157 | bottom: 0px; 158 | left: 0; 159 | transition: all ease-in 0.25s; 160 | } 161 | 162 | .btn-secondary:hover:after{ 163 | width: 100%; 164 | } 165 | 166 | ul.todo-list{ 167 | padding: 0; 168 | margin-bottom: 30px; 169 | } 170 | 171 | ul.todo-list li{ 172 | position: relative; 173 | list-style-type: none; 174 | display: block; 175 | margin: 10px 0; 176 | background: #e0e8f5; 177 | border-radius: 3px; 178 | padding-left: 38px; /* custom checkbox width + 16 */ 179 | padding-top: 12px; 180 | padding-bottom: 12px; 181 | padding-right: 49px; /* delete button + 5 */ 182 | overflow: hidden; 183 | } 184 | 185 | ul.todo-list.archived li{ 186 | background: #fff; 187 | } 188 | 189 | .todo-text{ 190 | position: relative; 191 | display: inline-block; 192 | padding: 0 0.5em; 193 | } 194 | 195 | 196 | ul.todo-list li .delete{ 197 | position: absolute; 198 | height: 100%; 199 | top: 50%; 200 | right: 0; 201 | transform: translateY(-50%); 202 | cursor: pointer; 203 | opacity: 0; 204 | width: 0; 205 | background-color: #f56468; 206 | color: #fff; 207 | transition: all ease-in 0.25s; 208 | } 209 | 210 | ul.todo-list li .delete:after{ 211 | position: absolute; 212 | content: ''; 213 | width: 16px; 214 | height: 16px; 215 | top: 50%; 216 | left: 50%; 217 | background-image: url(../images/trash.svg); 218 | background-repeat: no-repeat; 219 | background-position: center; 220 | background-size: contain; 221 | transform: translate(-50%, -50%) scale(0.5); 222 | transition: all ease-in 0.25s; 223 | } 224 | 225 | ul.todo-list li:hover .delete{ 226 | width: 44px; 227 | opacity: 1; 228 | } 229 | 230 | ul.todo-list li:hover .delete:after{ 231 | transform: translate(-50%, -50%) scale(1); 232 | } 233 | 234 | .todo-checkbox{ 235 | position: absolute; 236 | opacity: 0; 237 | display: none; 238 | } 239 | 240 | .todo-checkbox + label { 241 | position: absolute; 242 | cursor: pointer; 243 | left: 10px; 244 | top: 50%; 245 | transform: translateY(-50%); 246 | width: 22px; 247 | height: 22px; 248 | border-radius: 2px; 249 | border: 1px solid #cfdcec; 250 | background-color: #fff; 251 | } 252 | 253 | .todo-checkbox:checked + label:after{ 254 | position: absolute; 255 | content: ''; 256 | top: 30%; 257 | left: 50%; 258 | height: 3px; 259 | width: 6px; 260 | border: solid #fc6c48; 261 | border-width: 0 0 2px 2px; 262 | transform-origin: center center; 263 | transform: rotate(-45deg) translate(-50%, -50%); 264 | } 265 | 266 | .todo-checkbox:checked + label:after{ 267 | display: block; 268 | } 269 | 270 | .todo-checkbox:checked ~ .todo-text{ 271 | color: #888; 272 | text-decoration: line-through 273 | } 274 | 275 | .status.free{ 276 | font-weight: bold; 277 | text-align: center; 278 | margin: 40px 0; 279 | } 280 | .status.free img{ 281 | display: block; 282 | width: 50px; 283 | margin: 10px auto; 284 | vertical-align: middle; 285 | } 286 | 287 | .todo-item-enter-active, .todo-item-leave-active { 288 | transition: opacity ease 0.25s, transform ease-in-out 0.3s; 289 | transform-origin: left center; 290 | } 291 | 292 | /* .todo-item-leave-active below version 2.1.8 */ 293 | .todo-item-enter, .todo-item-leave-to { 294 | opacity: 0; 295 | transform: translateX(100%); 296 | } 297 | 298 | 299 | .slide-fade-enter-active, .slide-fade-leave-active { 300 | transition: all 0.3s ease; 301 | } 302 | /* .slide-fade-leave-active below version 2.1.8 */ 303 | .slide-fade-enter, .slide-fade-leave-to { 304 | transform: scale(1.1); 305 | opacity: 0; 306 | } 307 | 308 | 309 | /* Footer */ 310 | footer{ 311 | width: 100%; 312 | text-align: center; 313 | color: #fff; 314 | } 315 | 316 | footer a{ 317 | color: #fff; 318 | } 319 | 320 | .github-links{ 321 | margin-bottom: 30px; 322 | } -------------------------------------------------------------------------------- /images/beer_celebration.svg: -------------------------------------------------------------------------------- 1 | beer celebration -------------------------------------------------------------------------------- /images/favicon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nourabusoud/vue-todo-list/3818c99c93a6fc70f331502333ad82eed46c8490/images/favicon.png -------------------------------------------------------------------------------- /images/trash.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Todo list - Vue.js 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 20 | 21 | 22 | 23 | 24 |
25 |

Daily To-Do list manager

26 |
27 |

{{ today.day }}
{{ today.date }}

28 |
29 | 30 |
+
31 |
32 | 33 |
34 |

You have {{ pending.length }} pending items

35 | 36 |
  • 37 | 38 | 39 | {{ item.title }} 40 | 41 |
  • 42 | 43 |
    44 | 45 | 46 |

    celebrationTime to chill! You have no todos.

    47 |
    48 | 49 |
    50 |

    Completed tasks: {{ completedPercentage }}

    51 | 52 |
  • 53 | 54 | 55 | {{ item.title }} 56 | 57 |
  • 58 | 59 |
    60 |
    61 |
    ShowHide Complete
    62 |
    Clear All
    63 |
    64 |
    65 |
    66 | 74 | 75 | 76 | 77 | 78 | 174 | --------------------------------------------------------------------------------