Page MenuHomePhorge

No OneTemporary

Authored By
Unknown
Size
4 KB
Referenced Files
None
Subscribers
None
diff --git a/src/components/update_notification/update_notification.js b/src/components/update_notification/update_notification.js
index 1dd771ebc8..da3e18768f 100644
--- a/src/components/update_notification/update_notification.js
+++ b/src/components/update_notification/update_notification.js
@@ -1,58 +1,59 @@
import Modal from 'src/components/modal/modal.vue'
import { library } from '@fortawesome/fontawesome-svg-core'
import pleromaTan from 'src/assets/pleromatan_apology.png'
import pleromaTanFox from 'src/assets/pleromatan_apology_fox.png'
import {
faTimes
} from '@fortawesome/free-solid-svg-icons'
library.add(
faTimes
)
const CURRENT_UPDATE_COUNTER = 1
const UpdateNotification = {
data () {
return {
pleromaTanVariant: Math.random() > 0.5 ? pleromaTan : pleromaTanFox,
- showingMore: true,
+ showingMore: false,
contentHeight: 0
}
},
components: {
Modal
},
computed: {
pleromaTanStyles () {
return {
'shape-outside': 'url(' + this.pleromaTanVariant + ')'
}
},
shouldShow () {
return this.$store.state.serverSideStorage.flagStorage.updateCounter < CURRENT_UPDATE_COUNTER &&
!this.$store.state.serverSideStorage.flagStorage.dontShowUpdateNotifs
}
},
methods: {
toggleShow () {
this.showingMore = !this.showingMore
},
neverShowAgain () {
- this.$store.commit('setFlag', { flag: 'updateCounter', value: CURRENT_UPDATE_COUNTER })
- this.$store.commit('setFlag', { flag: 'dontShowUpdateNotifs', value: 1 })
- this.$store.dispatch('pushServerSideStorage')
+ this.toggleShow()
+ // this.$store.commit('setFlag', { flag: 'updateCounter', value: CURRENT_UPDATE_COUNTER })
+ // this.$store.commit('setFlag', { flag: 'dontShowUpdateNotifs', value: 1 })
+ // this.$store.dispatch('pushServerSideStorage')
},
dismiss () {
this.$store.commit('setFlag', { flag: 'updateCounter', value: CURRENT_UPDATE_COUNTER })
- this.$store.dispatch('pushServerSideStorage')
+ // this.$store.dispatch('pushServerSideStorage')
}
},
mounted () {
setTimeout(() => {
this.contentHeight = this.$refs.content.offsetHeight
}, 10)
}
}
export default UpdateNotification
diff --git a/src/components/update_notification/update_notification.vue b/src/components/update_notification/update_notification.vue
index 793966eba3..07e91ec953 100644
--- a/src/components/update_notification/update_notification.vue
+++ b/src/components/update_notification/update_notification.vue
@@ -1,61 +1,61 @@
<template>
<Modal
:is-open="shouldShow"
class="UpdateNotification"
:no-background="true"
>
<div
class="UpdateNotificationModal panel"
:class="{ '-peek': !showingMore }"
>
<div class="panel-heading">
<span class="title">
{{ $t('update.big_update_title') }}
</span>
</div>
<div class="panel-body">
<div class="content" ref="content">
<img class="pleroma-tan" :src="pleromaTanVariant" :style="pleromaTanStyles"/>
<div class="spacer-top"/>
<div class="text">
<p>
{{ $t('update.big_update_content') }}
</p>
<p class="extra-info">
{{ $t('update.update_bugs') }}
</p>
<p class="extra-info">
{{ $t('update.update_changelog') }}
</p>
</div>
<div class="spacer-bottom"/>
</div>
</div>
<div class="panel-footer">
<button
class="button-default"
@click.prevent="neverShowAgain"
>
{{ $t("general.never_show_again") }}
</button>
<button
class="button-default"
- @click.prevent="toggleShowMore"
+ @click.prevent="toggleShow"
v-if="!showingMore"
>
{{ $t("general.show_more") }}
</button>
<button
class="button-default"
@click.prevent="dismiss"
>
{{ $t("general.dismiss") }}
</button>
</div>
</div>
</Modal>
</template>
<script src="./update_notification.js"></script>
<style src="./update_notification.scss" lang="scss"></style>

File Metadata

Mime Type
text/x-diff
Expires
Mon, Nov 2, 8:55 AM (8 h, 52 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1804005
Default Alt Text
(4 KB)

Event Timeline