Sharkey/src/client/components/particle.vue

55 lines
29 KiB
Vue
Raw Normal View History

2020-02-21 08:20:58 -08:00
<template>
<div class="vswabwbm" :style="{ top: `${y - 50}px`, left: `${x - 50}px` }" :class="{ active }"></div>
</template>
<script lang="ts">
import Vue from 'vue';
export default Vue.extend({
props: {
x: {
type: Number,
required: true
},
y: {
type: Number,
required: true
}
},
data() {
return {
active: false
}
},
mounted() {
setTimeout(() => {
this.active = true;
}, 10);
setTimeout(() => {
this.destroyDom();
}, 1000);
}
});
</script>
<style lang="scss" scoped>
.vswabwbm {
pointer-events: none;
position: fixed;
z-index: 1000000;
width: 100px;
height: 100px;
background: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAABqUAAABkCAYAAAAPKjqIAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAA25pVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMDE0IDc5LjE1Njc5NywgMjAxNC8wOC8yMC0wOTo1MzowMiAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnR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bK3xCNLZ49/7/it0Iw6kAMkNcH3UfvhGnbL7hMQka8erxxb9lfOxV9pXwj+txt/zvobtKIe8/K2vefzmibTvjnTNQaOEJXbq6kF33H
background-size: initial;
background-position: 0 0;
transition: background-position 1s steps(25);
transition-duration: 0s;
&.active {
transition-duration: 1s;
background-position: -2500px 0;
}
}
</style>