mirror of
https://github.com/misskey-dev/misskey.git
synced 2026-05-23 21:34:10 +02:00
Merge branch 'develop' into room
This commit is contained in:
@@ -28,11 +28,11 @@
|
||||
"@rollup/plugin-json": "6.1.0",
|
||||
"@rollup/plugin-replace": "6.0.3",
|
||||
"@rollup/pluginutils": "5.3.0",
|
||||
"@sentry/vue": "10.40.0",
|
||||
"@sentry/vue": "10.43.0",
|
||||
"@syuilo/aiscript": "1.2.1",
|
||||
"@syuilo/aiscript-0-19-0": "npm:@syuilo/aiscript@^0.19.0",
|
||||
"@twemoji/parser": "16.0.0",
|
||||
"@vitejs/plugin-vue": "6.0.4",
|
||||
"@vitejs/plugin-vue": "6.0.5",
|
||||
"aiscript-vscode": "github:aiscript-dev/aiscript-vscode#v0.1.16",
|
||||
"analytics": "0.8.19",
|
||||
"broadcast-channel": "7.3.0",
|
||||
@@ -49,7 +49,7 @@
|
||||
"date-fns": "4.1.0",
|
||||
"eventemitter3": "5.0.4",
|
||||
"execa": "9.6.1",
|
||||
"exifreader": "4.36.2",
|
||||
"exifreader": "4.37.0",
|
||||
"frontend-shared": "workspace:*",
|
||||
"i18n": "workspace:*",
|
||||
"icons-subsetter": "workspace:*",
|
||||
@@ -59,7 +59,7 @@
|
||||
"is-file-animated": "1.0.2",
|
||||
"json5": "2.2.3",
|
||||
"matter-js": "0.20.0",
|
||||
"mediabunny": "1.35.1",
|
||||
"mediabunny": "1.39.2",
|
||||
"mfm-js": "0.25.0",
|
||||
"misskey-bubble-game": "workspace:*",
|
||||
"misskey-js": "workspace:*",
|
||||
@@ -70,7 +70,7 @@
|
||||
"qr-scanner": "1.4.2",
|
||||
"rollup": "4.59.0",
|
||||
"sanitize-html": "2.17.1",
|
||||
"sass": "1.97.3",
|
||||
"sass": "1.98.0",
|
||||
"shiki": "3.23.0",
|
||||
"textarea-caret": "3.1.0",
|
||||
"three": "0.183.2",
|
||||
@@ -78,28 +78,28 @@
|
||||
"tinycolor2": "1.6.0",
|
||||
"v-code-diff": "1.13.1",
|
||||
"vite": "7.3.1",
|
||||
"vue": "3.5.29",
|
||||
"vue": "3.5.30",
|
||||
"wanakana": "5.3.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@misskey-dev/summaly": "5.2.5",
|
||||
"@storybook/addon-essentials": "8.6.17",
|
||||
"@storybook/addon-interactions": "8.6.17",
|
||||
"@storybook/addon-links": "10.2.13",
|
||||
"@storybook/addon-mdx-gfm": "8.6.17",
|
||||
"@storybook/addon-storysource": "8.6.17",
|
||||
"@storybook/blocks": "8.6.17",
|
||||
"@storybook/components": "8.6.17",
|
||||
"@storybook/core-events": "8.6.17",
|
||||
"@storybook/manager-api": "8.6.17",
|
||||
"@storybook/preview-api": "8.6.17",
|
||||
"@storybook/react": "10.2.13",
|
||||
"@storybook/react-vite": "10.2.13",
|
||||
"@storybook/test": "8.6.17",
|
||||
"@storybook/theming": "8.6.17",
|
||||
"@storybook/types": "8.6.17",
|
||||
"@storybook/vue3": "10.2.13",
|
||||
"@storybook/vue3-vite": "10.2.13",
|
||||
"@storybook/addon-essentials": "8.6.18",
|
||||
"@storybook/addon-interactions": "8.6.18",
|
||||
"@storybook/addon-links": "10.2.17",
|
||||
"@storybook/addon-mdx-gfm": "8.6.18",
|
||||
"@storybook/addon-storysource": "8.6.18",
|
||||
"@storybook/blocks": "8.6.18",
|
||||
"@storybook/components": "8.6.18",
|
||||
"@storybook/core-events": "8.6.18",
|
||||
"@storybook/manager-api": "8.6.18",
|
||||
"@storybook/preview-api": "8.6.18",
|
||||
"@storybook/react": "10.2.17",
|
||||
"@storybook/react-vite": "10.2.17",
|
||||
"@storybook/test": "8.6.18",
|
||||
"@storybook/theming": "8.6.18",
|
||||
"@storybook/types": "8.6.18",
|
||||
"@storybook/vue3": "10.2.17",
|
||||
"@storybook/vue3-vite": "10.2.17",
|
||||
"@tabler/icons-webfont": "3.35.0",
|
||||
"@testing-library/vue": "8.1.0",
|
||||
"@types/canvas-confetti": "1.9.0",
|
||||
@@ -107,17 +107,17 @@
|
||||
"@types/insert-text-at-cursor": "0.3.2",
|
||||
"@types/matter-js": "0.20.2",
|
||||
"@types/micromatch": "4.0.10",
|
||||
"@types/node": "24.11.0",
|
||||
"@types/node": "24.12.0",
|
||||
"@types/punycode.js": "npm:@types/punycode@2.1.4",
|
||||
"@types/sanitize-html": "2.16.0",
|
||||
"@types/sanitize-html": "2.16.1",
|
||||
"@types/seedrandom": "3.0.8",
|
||||
"@types/textarea-caret": "3.0.4",
|
||||
"@types/throttle-debounce": "5.0.2",
|
||||
"@types/tinycolor2": "1.4.6",
|
||||
"@typescript-eslint/eslint-plugin": "8.56.1",
|
||||
"@typescript-eslint/parser": "8.56.1",
|
||||
"@vitest/coverage-v8": "4.0.18",
|
||||
"@vue/compiler-core": "3.5.29",
|
||||
"@typescript-eslint/eslint-plugin": "8.57.0",
|
||||
"@typescript-eslint/parser": "8.57.0",
|
||||
"@vitest/coverage-v8": "4.1.0",
|
||||
"@vue/compiler-core": "3.5.30",
|
||||
"acorn": "8.16.0",
|
||||
"astring": "1.9.0",
|
||||
"cross-env": "10.1.0",
|
||||
@@ -125,7 +125,7 @@
|
||||
"eslint-plugin-import": "2.32.0",
|
||||
"eslint-plugin-vue": "10.8.0",
|
||||
"estree-walker": "3.0.3",
|
||||
"happy-dom": "20.7.0",
|
||||
"happy-dom": "20.8.4",
|
||||
"intersection-observer": "0.12.2",
|
||||
"magic-string": "0.30.21",
|
||||
"micromatch": "4.0.8",
|
||||
@@ -138,12 +138,12 @@
|
||||
"react-dom": "19.2.4",
|
||||
"seedrandom": "3.0.5",
|
||||
"start-server-and-test": "2.1.5",
|
||||
"storybook": "10.2.13",
|
||||
"storybook": "10.2.17",
|
||||
"storybook-addon-misskey-theme": "github:misskey-dev/storybook-addon-misskey-theme",
|
||||
"tsx": "4.21.0",
|
||||
"vite-plugin-glsl": "1.5.5",
|
||||
"vite-plugin-turbosnap": "1.0.3",
|
||||
"vitest": "4.0.18",
|
||||
"vitest": "4.1.0",
|
||||
"vitest-fetch-mock": "0.4.5",
|
||||
"vue-component-type-helpers": "3.2.5",
|
||||
"vue-eslint-parser": "10.4.0",
|
||||
|
||||
@@ -6,8 +6,6 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||
<template>
|
||||
<MkWindow
|
||||
ref="window"
|
||||
:initialWidth="800"
|
||||
:initialHeight="500"
|
||||
:canResize="true"
|
||||
@closed="emit('closed')"
|
||||
>
|
||||
|
||||
@@ -6,8 +6,6 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||
<template>
|
||||
<MkWindow
|
||||
ref="windowEl"
|
||||
:initialWidth="500"
|
||||
:initialHeight="500"
|
||||
:canResize="true"
|
||||
:closeButton="true"
|
||||
:buttonsLeft="buttonsLeft"
|
||||
|
||||
@@ -106,7 +106,9 @@ async function toggleReaction() {
|
||||
reaction: props.reaction,
|
||||
}).then(() => {
|
||||
const emoji = customEmojisMap.get(emojiName.value);
|
||||
if (emoji == null) return;
|
||||
if (emoji == null && getUnicodeEmojiOrNull(props.reaction) == null) {
|
||||
return;
|
||||
}
|
||||
noteEvents.emit(`reacted:${props.noteId}`, {
|
||||
userId: me.id,
|
||||
reaction: props.reaction,
|
||||
@@ -138,7 +140,9 @@ async function toggleReaction() {
|
||||
reaction: props.reaction,
|
||||
}).then(() => {
|
||||
const emoji = customEmojisMap.get(emojiName.value);
|
||||
if (emoji == null) return;
|
||||
if (emoji == null && getUnicodeEmojiOrNull(props.reaction) == null) {
|
||||
return;
|
||||
}
|
||||
|
||||
noteEvents.emit(`reacted:${props.noteId}`, {
|
||||
userId: me.id,
|
||||
|
||||
@@ -13,7 +13,7 @@ SPDX-License-Identifier: AGPL-3.0-only
|
||||
@afterLeave="emit('closed')"
|
||||
>
|
||||
<div v-if="showing" ref="rootEl" :class="[$style.root, { [$style.maximized]: maximized }]">
|
||||
<div :class="$style.body" class="_shadow" @mousedown="onBodyMousedown" @keydown="onKeydown">
|
||||
<div :class="$style.body" class="_shadow" @pointerdown="onBodyPointerDown" @keydown="onKeydown">
|
||||
<div :class="[$style.header, { [$style.mini]: mini }]" @contextmenu.prevent.stop="onContextmenu">
|
||||
<span :class="$style.headerLeft">
|
||||
<template v-if="!minimized">
|
||||
@@ -106,8 +106,8 @@ function capturePointer(evt: PointerEvent) {
|
||||
}
|
||||
|
||||
const props = withDefaults(defineProps<{
|
||||
initialWidth: number;
|
||||
initialHeight: number | null;
|
||||
initialWidth?: number | null;
|
||||
initialHeight?: number | null;
|
||||
canResize?: boolean;
|
||||
closeButton?: boolean;
|
||||
mini?: boolean;
|
||||
@@ -116,7 +116,7 @@ const props = withDefaults(defineProps<{
|
||||
buttonsLeft?: WindowButton[];
|
||||
buttonsRight?: WindowButton[];
|
||||
}>(), {
|
||||
initialWidth: 400,
|
||||
initialWidth: null,
|
||||
initialHeight: null,
|
||||
canResize: false,
|
||||
closeButton: true,
|
||||
@@ -131,6 +131,12 @@ const emit = defineEmits<{
|
||||
(ev: 'closed'): void;
|
||||
}>();
|
||||
|
||||
const INITIAL_WINDOW_WIDTH_RATIO = 0.5;
|
||||
const INITIAL_WINDOW_HEIGHT_RATIO = 0.75;
|
||||
const INITIAL_WINDOW_WIDTH_MIN = 400; // スクリーンの最小幅に合わせるのはapplyTransormWidthの担当
|
||||
const INITIAL_WINDOW_WIDTH_MAX = 1000; // 画面幅いっぱいに広がるのを防止するための最大幅
|
||||
const INITIAL_WINDOW_HEIGHT_MIN = 500; // スクリーンの最小幅に合わせるのはapplyTransormHeightの担当
|
||||
|
||||
provide('inWindow', true);
|
||||
|
||||
const rootEl = useTemplateRef('rootEl');
|
||||
@@ -216,7 +222,7 @@ function unMinimize() {
|
||||
if (position.left + windowWidth > browserWidth) main.style.left = browserWidth - windowWidth + 'px';
|
||||
}
|
||||
|
||||
function onBodyMousedown() {
|
||||
function onBodyPointerDown() {
|
||||
top();
|
||||
}
|
||||
|
||||
@@ -484,8 +490,14 @@ function onBrowserResize() {
|
||||
}
|
||||
|
||||
onMounted(() => {
|
||||
applyTransformWidth(props.initialWidth);
|
||||
if (props.initialHeight) applyTransformHeight(props.initialHeight);
|
||||
let initialWidth = props.initialWidth;
|
||||
let initialHeight = props.initialHeight;
|
||||
|
||||
if (initialWidth == null) initialWidth = Math.min(Math.max(Math.round(window.innerWidth * INITIAL_WINDOW_WIDTH_RATIO), INITIAL_WINDOW_WIDTH_MIN), INITIAL_WINDOW_WIDTH_MAX);
|
||||
if (initialHeight == null) initialHeight = Math.max(Math.round(window.innerHeight * INITIAL_WINDOW_HEIGHT_RATIO), INITIAL_WINDOW_HEIGHT_MIN);
|
||||
|
||||
applyTransformWidth(initialWidth);
|
||||
applyTransformHeight(initialHeight);
|
||||
|
||||
if (rootEl.value) {
|
||||
applyTransformTop((window.innerHeight / 2) - (rootEl.value.offsetHeight / 2));
|
||||
|
||||
@@ -150,6 +150,7 @@ import { definePage } from '@/page.js';
|
||||
import { claimAchievement, claimedAchievements } from '@/utility/achievements.js';
|
||||
import { $i } from '@/i.js';
|
||||
import { prefer } from '@/preferences.js';
|
||||
import { DEFAULT_EMOJIS } from '@@/js/const.js';
|
||||
|
||||
const patronsWithIcon = [{
|
||||
name: 'カイヤン',
|
||||
@@ -429,7 +430,12 @@ const containerEl = useTemplateRef('containerEl');
|
||||
|
||||
function iconLoaded() {
|
||||
if (containerEl.value == null) return;
|
||||
const emojis = prefer.s.emojiPalettes[0].emojis;
|
||||
const emojis = prefer.s.emojiPalettes[0]?.emojis ?? [];
|
||||
|
||||
if (emojis.length < DEFAULT_EMOJIS.length) {
|
||||
emojis.push(...DEFAULT_EMOJIS.slice(0, DEFAULT_EMOJIS.length - emojis.length));
|
||||
}
|
||||
|
||||
const containerWidth = containerEl.value.offsetWidth;
|
||||
for (let i = 0; i < 32; i++) {
|
||||
easterEggEmojis.value.push({
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
|
||||
import * as Misskey from 'misskey-js';
|
||||
import { hemisphere } from '@@/js/intl-const.js';
|
||||
import { DEFAULT_EMOJIS } from '@@/js/const.js';
|
||||
import { prefersReducedMotion } from '@@/js/config.js';
|
||||
import { definePreferences } from './manager.js';
|
||||
import type { Theme } from '@/theme.js';
|
||||
@@ -103,7 +104,7 @@ export const PREF_DEF = definePreferences({
|
||||
default: () => [{
|
||||
id: genId(),
|
||||
name: '',
|
||||
emojis: ['👍', '❤️', '😆', '🤔', '😮', '🎉', '💢', '😥', '😇', '🍮'],
|
||||
emojis: DEFAULT_EMOJIS,
|
||||
}] as {
|
||||
id: string;
|
||||
name: string;
|
||||
|
||||
Reference in New Issue
Block a user