Version 0.2.1

This commit is contained in:
Andrew Illarionov 2024-02-20 22:14:58 +03:00
parent eadc0b119d
commit 36dd770ce4
6 changed files with 73 additions and 43 deletions

View File

@ -1 +1 @@
[{"D:\\Software\\Development\\Websites\\enderman.ch\\index\\assets\\styles\\transitions.scss":"1","D:\\Software\\Development\\Websites\\enderman.ch\\index\\app.vue":"2","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\EMail.vue":"3","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\about.vue":"4","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\index.vue":"5","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\projects.vue":"6","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\social.vue":"7","D:\\Software\\Development\\Websites\\enderman.ch\\index\\layouts\\Card.vue":"8","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\blocks\\Options.vue":"9","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\blocks\\Flooter.vue":"10","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\blocks\\SwipeControls.vue":"11","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\blocks\\Logo.vue":"12","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\blocks\\Route.vue":"13","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\animations\\Portal.vue":"14","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\ui\\Icon.vue":"15","D:\\Software\\Development\\Websites\\enderman.ch\\index\\assets\\styles\\vuetify.scss":"16","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\[...slug].vue":"17","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\blog\\index.vue":"18","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\blog\\[slug].vue":"19","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\content\\Card.vue":"20","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\content\\OgImage.vue":"21","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\animations\\NotFound.vue":"22"},{"size":165,"mtime":1700688268778,"hashOfConfig":"23"},{"size":1550,"mtime":1700850776284,"hashOfConfig":"23"},{"size":804,"mtime":1700688952880,"hashOfConfig":"23"},{"size":2135,"mtime":1700689265787,"hashOfConfig":"23"},{"size":3117,"mtime":1700689271383,"hashOfConfig":"23"},{"size":2304,"mtime":1700689265769,"hashOfConfig":"23"},{"size":3232,"mtime":1700689265781,"hashOfConfig":"23"},{"size":1623,"mtime":1700748530633,"hashOfConfig":"23"},{"size":3065,"mtime":1708262194629,"hashOfConfig":"24"},{"size":1132,"mtime":1708254584095,"hashOfConfig":"24"},{"size":1269,"mtime":1708255068679,"hashOfConfig":"24"},{"size":1147,"mtime":1708248797872,"hashOfConfig":"24"},{"size":979,"mtime":1706003786966,"hashOfConfig":"24"},{"size":16968,"mtime":1708180277353,"hashOfConfig":"24"},{"size":935,"mtime":1706445231843,"hashOfConfig":"24"},{"size":120,"mtime":1706789613657,"hashOfConfig":"25"},{"size":2084,"mtime":1708424343371,"hashOfConfig":"24"},{"size":2560,"mtime":1708202402381,"hashOfConfig":"24"},{"size":983,"mtime":1708206997656,"hashOfConfig":"24"},{"size":1912,"mtime":1708290866348,"hashOfConfig":"24"},{"size":976,"mtime":1708431988520,"hashOfConfig":"24"},{"size":1645,"mtime":1708450985689,"hashOfConfig":"24"},"5tgxr3","1nljphs","1lk8nat"] [{"D:\\Software\\Development\\Websites\\enderman.ch\\index\\assets\\styles\\transitions.scss":"1","D:\\Software\\Development\\Websites\\enderman.ch\\index\\app.vue":"2","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\EMail.vue":"3","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\about.vue":"4","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\index.vue":"5","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\projects.vue":"6","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\social.vue":"7","D:\\Software\\Development\\Websites\\enderman.ch\\index\\layouts\\Card.vue":"8","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\blocks\\Options.vue":"9","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\blocks\\Flooter.vue":"10","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\blocks\\SwipeControls.vue":"11","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\blocks\\Logo.vue":"12","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\blocks\\Route.vue":"13","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\animations\\Portal.vue":"14","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\ui\\Icon.vue":"15","D:\\Software\\Development\\Websites\\enderman.ch\\index\\assets\\styles\\vuetify.scss":"16","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\[...slug].vue":"17","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\blog\\index.vue":"18","D:\\Software\\Development\\Websites\\enderman.ch\\index\\pages\\blog\\[slug].vue":"19","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\content\\Card.vue":"20","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\content\\OgImage.vue":"21","D:\\Software\\Development\\Websites\\enderman.ch\\index\\components\\animations\\NotFound.vue":"22"},{"size":165,"mtime":1700688268778,"hashOfConfig":"23"},{"size":1550,"mtime":1700850776284,"hashOfConfig":"23"},{"size":804,"mtime":1700688952880,"hashOfConfig":"23"},{"size":2135,"mtime":1700689265787,"hashOfConfig":"23"},{"size":3117,"mtime":1700689271383,"hashOfConfig":"23"},{"size":2304,"mtime":1700689265769,"hashOfConfig":"23"},{"size":3232,"mtime":1700689265781,"hashOfConfig":"23"},{"size":1623,"mtime":1700748530633,"hashOfConfig":"23"},{"size":3855,"mtime":1708455917401,"hashOfConfig":"24"},{"size":1132,"mtime":1708254584095,"hashOfConfig":"24"},{"size":1269,"mtime":1708255068679,"hashOfConfig":"24"},{"size":1147,"mtime":1708248797872,"hashOfConfig":"24"},{"size":979,"mtime":1706003786966,"hashOfConfig":"24"},{"size":17150,"mtime":1708455647910,"hashOfConfig":"24"},{"size":935,"mtime":1706445231843,"hashOfConfig":"24"},{"size":120,"mtime":1706789613657,"hashOfConfig":"25"},{"size":2084,"mtime":1708424343371,"hashOfConfig":"24"},{"size":2560,"mtime":1708202402381,"hashOfConfig":"24"},{"size":983,"mtime":1708206997656,"hashOfConfig":"24"},{"size":1912,"mtime":1708290866348,"hashOfConfig":"24"},{"size":976,"mtime":1708431988520,"hashOfConfig":"24"},{"size":1645,"mtime":1708450985689,"hashOfConfig":"24"},"5tgxr3","1nljphs","1lk8nat"]

View File

@ -7,6 +7,8 @@ const fqdn = config.url.split('//')[1]
const resources: string[] = [sky, particles] const resources: string[] = [sky, particles]
const pages = storeToRefs(usePageStore())
const props = defineProps({ const props = defineProps({
layout: { layout: {
default: '#ender-app', default: '#ender-app',
@ -65,7 +67,7 @@ class Canvas {
compatible( compatible(
obj: HTMLCanvasElement | HTMLElement | Element, obj: HTMLCanvasElement | HTMLElement | Element,
): obj is HTMLCanvasElement { ): obj is HTMLCanvasElement {
return obj.tagName === 'CANVAS' return obj.tagName.toLowerCase() === 'canvas'
} }
query(): HTMLCanvasElement { query(): HTMLCanvasElement {
@ -252,7 +254,7 @@ class Portal {
this.animate = animate this.animate = animate
this.randomize = randomize this.randomize = randomize
// Set default speed. // Set the default speed.
this.speed = speed this.speed = speed
this.initialSpeed = this.speed this.initialSpeed = this.speed
this.dv = 20 this.dv = 20
@ -561,6 +563,9 @@ class Portal {
// Run the scene. // Run the scene.
this.scene() this.scene()
// TODO: Make it into a composable? The toggle will not work. Hardcoded.
if (!pages.animate.value) this.pause()
// Request the next animation frame if animation is enabled. // Request the next animation frame if animation is enabled.
if (this.animate) requestAnimationFrame(this.render.bind(this)) if (this.animate) requestAnimationFrame(this.render.bind(this))
} }

View File

@ -11,10 +11,12 @@ const mailTemplate = `I've just found a bug on ${config.url} and would like to r
}%0D%0ABuild date: ${ }%0D%0ABuild date: ${
config.build.date config.build.date
}%0D%0ATimestamp: ${new Date().toISOString()}%0D%0A%0D%0A%0D%0ASteps to reproduce:%0D%0A{ Explain in detail what happened here, or attach a video/screenshot }%0D%0A%0D%0AAdditional information:%0D%0A{ Helpful information, such as developer console output / Leave empty if none }%0D%0A%0D%0A%0D%0A// Keep in mind that it's just a template, you can change it as you wish! :)` }%0D%0ATimestamp: ${new Date().toISOString()}%0D%0A%0D%0A%0D%0ASteps to reproduce:%0D%0A{ Explain in detail what happened here, or attach a video/screenshot }%0D%0A%0D%0AAdditional information:%0D%0A{ Helpful information, such as developer console output / Leave empty if none }%0D%0A%0D%0A%0D%0A// Keep in mind that it's just a template, you can change it as you wish! :)`
const pages = storeToRefs(usePageStore())
</script> </script>
<template> <template>
<VDialog> <VDialog width="auto">
<template #activator="{ props }"> <template #activator="{ props }">
<div v-bind="props" class="options clickable"> <div v-bind="props" class="options clickable">
<img <img
@ -27,48 +29,69 @@ const mailTemplate = `I've just found a bug on ${config.url} and would like to r
</template> </template>
<template #default="{ isActive }"> <template #default="{ isActive }">
<VCard> <VCard>
<img
draggable="false"
:src="pearlIcon"
alt="Pearl"
class="icon-badge user-select-none"
/>
<template #title> <template #title>
<h3 class="alex text-align-center">Site options</h3> <h3 class="alex text-align-center">Site options</h3>
</template> </template>
<div class="overlay background"></div> <div class="overlay background"></div>
<VCardText class="overlay content"> <template #text>
<img <p class="center mb-3">
draggable="false" This tab is experimental and isn't ready for production.
:src="pearlIcon" <em>I was too lazy to exclude it from the build.</em><br />
alt="Pearl" <strong>Features provided here may or may not work.</strong>
class="icon-badge user-select-none" </p>
/>
<div> <div>
<div class="row"> <VRow>
<div class="col-12 col-sm-6"> <VCol>
<strong>Theme</strong>
<p>Available in all flavors, vanilla and chocolate.</p>
<VBtn variant="flat" color="secondary" @click="theme.toggle()">
Toggle theme
</VBtn>
</VCol>
<VCol>
<strong>Animation</strong>
<p> <p>
<strong>Theme</strong><br />
Available in all flavors, vanilla and chocolate.
</p>
</div>
<div class="col-12 col-sm-6">
<p>
<strong>Animation</strong><br />
Some computers may have issues rendering that gorgeous Some computers may have issues rendering that gorgeous
background animation. Enabling it substantially increases background animation. Disabling it substantially decreases
power consumption. power consumption, but also makes the website less cool.
</p> </p>
</div> <VBtn
</div> variant="flat"
color="primary"
@click="pages.animate.value = !pages.animate.value"
>
Stop animation
</VBtn>
</VCol>
</VRow>
</div> </div>
<EMail <span class="mt-3">
class="link-hi" Since you're so curious and thus here, why not report a bug from the
:address="`contact@${fqdn}`" production environment behind this tab?<br />
:cc="`admin@${fqdn}`" It will greatly help me improve the website!
:subject="`Bug report: ${fqdn}`" <EMail
:body="mailTemplate" class="link-hi"
> :address="`contact@${fqdn}`"
<strong>Report a bug</strong> :cc="`admin@${fqdn}`"
</EMail> :subject="`Bug report: ${fqdn}`"
</VCardText> :body="mailTemplate"
<VCardActions> >
<VSpacer></VSpacer> <strong>Report a bug</strong>
<VBtn color="danger" @click="theme.toggle()" /> </EMail>
</span>
</template>
<template #actions>
<VSpacer />
<VBtn <VBtn
variant="outlined" variant="outlined"
prepend-icon="close" prepend-icon="close"
@ -76,7 +99,7 @@ const mailTemplate = `I've just found a bug on ${config.url} and would like to r
> >
Close Close
</VBtn> </VBtn>
</VCardActions> </template>
</VCard> </VCard>
</template> </template>
</VDialog> </VDialog>
@ -96,10 +119,10 @@ const mailTemplate = `I've just found a bug on ${config.url} and would like to r
.icon-badge { .icon-badge {
position: fixed; position: fixed;
top: -16px; top: -48px;
left: -16px; left: -32px;
transform: rotate(-30deg); transform: rotate(-15deg);
} }
.logo { .logo {

View File

@ -1,6 +1,6 @@
import { useDark, useToggle } from '@vueuse/core' import { useDark, useToggle } from '@vueuse/core'
export default function () { export default () => {
const { $vuetify } = useNuxtApp() const { $vuetify } = useNuxtApp()
const config = useAppConfig() const config = useAppConfig()

View File

@ -1,6 +1,6 @@
{ {
"name": "enderapp", "name": "enderapp",
"version": "0.1.3", "version": "0.2.1",
"private": true, "private": true,
"type": "module", "type": "module",
"scripts": { "scripts": {

View File

@ -51,6 +51,7 @@ export const usePageStore = defineStore('page', () => {
]) ])
const reader = ref(false) const reader = ref(false)
const animate = ref(true)
function _autoFetchPages() { function _autoFetchPages() {
while (pages.value.length) pages.value.pop() while (pages.value.length) pages.value.pop()
@ -71,5 +72,6 @@ export const usePageStore = defineStore('page', () => {
keywords, keywords,
pages, pages,
reader, reader,
animate,
} }
}) })