forked from mirror/misskey
Merge branch 'develop' into preview-cw
This commit is contained in:
commit
0b5fc47427
@ -31,6 +31,7 @@
|
|||||||
- Fix: コードエディタが正しく表示されない問題を修正
|
- Fix: コードエディタが正しく表示されない問題を修正
|
||||||
- Fix: プロフィールの「ファイル」にセンシティブな画像がある際のデザインを修正
|
- Fix: プロフィールの「ファイル」にセンシティブな画像がある際のデザインを修正
|
||||||
- Fix: 一度に大量の通知が入った際に通知音が音割れする問題を修正
|
- Fix: 一度に大量の通知が入った際に通知音が音割れする問題を修正
|
||||||
|
- Fix: 通知のグルーピング設定を変更してもリロードされるまで表示が変わらない問題を修正 #12470
|
||||||
|
|
||||||
### Server
|
### Server
|
||||||
- Enhance: MFM `$[ruby ]` が他ソフトウェアと連合されるように
|
- Enhance: MFM `$[ruby ]` が他ソフトウェアと連合されるように
|
||||||
|
@ -186,6 +186,10 @@ export const packedNoteSchema = {
|
|||||||
optional: false, nullable: false,
|
optional: false, nullable: false,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
clippedCount: {
|
||||||
|
type: 'number',
|
||||||
|
optional: true, nullable: false,
|
||||||
|
},
|
||||||
|
|
||||||
myReaction: {
|
myReaction: {
|
||||||
type: 'object',
|
type: 'object',
|
||||||
|
@ -202,20 +202,24 @@ export async function common(createVue: () => App<Element>) {
|
|||||||
}
|
}
|
||||||
}, { immediate: true });
|
}, { immediate: true });
|
||||||
|
|
||||||
if (defaultStore.state.keepScreenOn) {
|
// Keep screen on
|
||||||
if ('wakeLock' in navigator) {
|
const onVisibilityChange = () => document.addEventListener('visibilitychange', () => {
|
||||||
navigator.wakeLock.request('screen')
|
if (document.visibilityState === 'visible') {
|
||||||
.then(() => {
|
navigator.wakeLock.request('screen');
|
||||||
document.addEventListener('visibilitychange', async () => {
|
|
||||||
if (document.visibilityState === 'visible') {
|
|
||||||
navigator.wakeLock.request('screen');
|
|
||||||
}
|
|
||||||
});
|
|
||||||
})
|
|
||||||
.catch(() => {
|
|
||||||
// If Permission fails on an AppleDevice such as Safari
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
});
|
||||||
|
if (defaultStore.state.keepScreenOn && 'wakeLock' in navigator) {
|
||||||
|
navigator.wakeLock.request('screen')
|
||||||
|
.then(onVisibilityChange)
|
||||||
|
.catch(() => {
|
||||||
|
// On WebKit-based browsers, user activation is required to send wake lock request
|
||||||
|
// https://webkit.org/blog/13862/the-user-activation-api/
|
||||||
|
document.addEventListener(
|
||||||
|
'click',
|
||||||
|
() => navigator.wakeLock.request('screen').then(onVisibilityChange),
|
||||||
|
{ once: true },
|
||||||
|
);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
//#region Fetch user
|
//#region Fetch user
|
||||||
|
@ -24,7 +24,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { onUnmounted, onDeactivated, onMounted, computed, shallowRef, onActivated } from 'vue';
|
import { onUnmounted, onDeactivated, onMounted, computed, shallowRef, onActivated, watch } from 'vue';
|
||||||
import MkPagination, { Paging } from '@/components/MkPagination.vue';
|
import MkPagination, { Paging } from '@/components/MkPagination.vue';
|
||||||
import XNotification from '@/components/MkNotification.vue';
|
import XNotification from '@/components/MkNotification.vue';
|
||||||
import MkDateSeparatedList from '@/components/MkDateSeparatedList.vue';
|
import MkDateSeparatedList from '@/components/MkDateSeparatedList.vue';
|
||||||
@ -43,7 +43,7 @@ const props = defineProps<{
|
|||||||
|
|
||||||
const pagingComponent = shallowRef<InstanceType<typeof MkPagination>>();
|
const pagingComponent = shallowRef<InstanceType<typeof MkPagination>>();
|
||||||
|
|
||||||
const pagination: Paging = defaultStore.state.useGroupedNotifications ? {
|
let pagination = $computed(() => defaultStore.reactiveState.useGroupedNotifications.value ? {
|
||||||
endpoint: 'i/notifications-grouped' as const,
|
endpoint: 'i/notifications-grouped' as const,
|
||||||
limit: 20,
|
limit: 20,
|
||||||
params: computed(() => ({
|
params: computed(() => ({
|
||||||
@ -55,7 +55,7 @@ const pagination: Paging = defaultStore.state.useGroupedNotifications ? {
|
|||||||
params: computed(() => ({
|
params: computed(() => ({
|
||||||
excludeTypes: props.excludeTypes ?? undefined,
|
excludeTypes: props.excludeTypes ?? undefined,
|
||||||
})),
|
})),
|
||||||
};
|
});
|
||||||
|
|
||||||
function onNotification(notification) {
|
function onNotification(notification) {
|
||||||
const isMuted = props.excludeTypes ? props.excludeTypes.includes(notification.type) : false;
|
const isMuted = props.excludeTypes ? props.excludeTypes.includes(notification.type) : false;
|
||||||
|
@ -186,7 +186,7 @@ watch([$$(backed), $$(contentEl)], () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// パラメータに何らかの変更があった際、再読込したい(チャンネル等のIDが変わったなど)
|
// パラメータに何らかの変更があった際、再読込したい(チャンネル等のIDが変わったなど)
|
||||||
watch(() => props.pagination.params, init, { deep: true });
|
watch(() => [props.pagination.endpoint, props.pagination.params], init, { deep: true });
|
||||||
|
|
||||||
watch(queue, (a, b) => {
|
watch(queue, (a, b) => {
|
||||||
if (a.size === 0 && b.size === 0) return;
|
if (a.size === 0 && b.size === 0) return;
|
||||||
|
@ -161,7 +161,7 @@ export function play(operationType: OperationType) {
|
|||||||
if (sound.type == null || !canPlay) return;
|
if (sound.type == null || !canPlay) return;
|
||||||
|
|
||||||
canPlay = false;
|
canPlay = false;
|
||||||
playFile(sound).then(() => {
|
playFile(sound).finally(() => {
|
||||||
// ごく短時間に音が重複しないように
|
// ごく短時間に音が重複しないように
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
canPlay = true;
|
canPlay = true;
|
||||||
|
@ -150,10 +150,14 @@ export function getConfig(): UserConfig {
|
|||||||
test: {
|
test: {
|
||||||
environment: 'happy-dom',
|
environment: 'happy-dom',
|
||||||
deps: {
|
deps: {
|
||||||
inline: [
|
optimizer: {
|
||||||
// XXX: misskey-dev/browser-image-resizer has no "type": "module"
|
web: {
|
||||||
'browser-image-resizer',
|
include: [
|
||||||
],
|
// XXX: misskey-dev/browser-image-resizer has no "type": "module"
|
||||||
|
'browser-image-resizer',
|
||||||
|
],
|
||||||
|
},
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user