make virtual scrolling optional in case people want to be able to ctrl-f all page
This commit is contained in:
parent
42f8fb2dca
commit
c49b8e2089
|
@ -92,6 +92,11 @@
|
|||
{{ $t('settings.reply_link_preview') }}
|
||||
</Checkbox>
|
||||
</li>
|
||||
<li>
|
||||
<Checkbox v-model="virtualScrolling">
|
||||
{{ $t('settings.virtual_scrolling') }}
|
||||
</Checkbox>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
|
|
|
@ -70,11 +70,14 @@ const Timeline = {
|
|||
pinnedStatusIdsObject () {
|
||||
return keyBy(this.pinnedStatusIds)
|
||||
},
|
||||
displayingStatuses () {
|
||||
statusesToDisplay () {
|
||||
const amount = this.timeline.visibleStatuses.length
|
||||
const min = Math.max(0, this.vScrollIndex - 20)
|
||||
const max = Math.min(amount, this.vScrollIndex + 20)
|
||||
return this.timeline.visibleStatuses.slice(min, max).map(_ => _.id)
|
||||
},
|
||||
virtualScrollingEnabled () {
|
||||
return this.$store.getters.mergedConfig.virtualScrolling
|
||||
}
|
||||
},
|
||||
components: {
|
||||
|
|
|
@ -56,7 +56,7 @@
|
|||
:collapsable="true"
|
||||
:in-profile="inProfile"
|
||||
:profile-user-id="userId"
|
||||
:virtualHidden="!displayingStatuses.includes(status.id)"
|
||||
:virtualHidden="virtualScrollingEnabled && !statusesToDisplay.includes(status.id)"
|
||||
/>
|
||||
</template>
|
||||
</div>
|
||||
|
|
|
@ -375,6 +375,7 @@
|
|||
"false": "no",
|
||||
"true": "yes"
|
||||
},
|
||||
"virtual_scrolling": "Optimize timeline rendering",
|
||||
"fun": "Fun",
|
||||
"greentext": "Meme arrows",
|
||||
"notifications": "Notifications",
|
||||
|
|
|
@ -228,7 +228,8 @@
|
|||
"values": {
|
||||
"false": "pois päältä",
|
||||
"true": "päällä"
|
||||
}
|
||||
},
|
||||
"virtual_scrolling": "Optimoi aikajanan suorituskykyä"
|
||||
},
|
||||
"time": {
|
||||
"day": "{0} päivä",
|
||||
|
|
|
@ -49,7 +49,8 @@ export const defaultState = {
|
|||
useContainFit: false,
|
||||
greentext: undefined, // instance default
|
||||
hidePostStats: undefined, // instance default
|
||||
hideUserStats: undefined // instance default
|
||||
hideUserStats: undefined, // instance default
|
||||
virtualScrolling: undefined // instance default
|
||||
}
|
||||
|
||||
// caching the instance default properties
|
||||
|
|
|
@ -34,6 +34,7 @@ const defaultState = {
|
|||
showFeaturesPanel: true,
|
||||
minimalScopesMode: false,
|
||||
greentext: false,
|
||||
virtualScrolling: true,
|
||||
|
||||
// Nasty stuff
|
||||
pleromaBackend: true,
|
||||
|
|
Loading…
Reference in New Issue