diff options
| author | syuilo <Syuilotan@yahoo.co.jp> | 2024-01-24 09:31:06 +0900 |
|---|---|---|
| committer | syuilo <Syuilotan@yahoo.co.jp> | 2024-01-24 09:31:06 +0900 |
| commit | 443d1b2f5cc48a240bdac96f24d6896cedd76365 (patch) | |
| tree | 34ed09af7465356b659bf2113365955b56d2b72c /packages | |
| parent | :art: (diff) | |
| parent | fix(frontend/HorizontalSwipe): スワイプ・UIアニメーションが無... (diff) | |
| download | sharkey-443d1b2f5cc48a240bdac96f24d6896cedd76365.tar.gz sharkey-443d1b2f5cc48a240bdac96f24d6896cedd76365.tar.bz2 sharkey-443d1b2f5cc48a240bdac96f24d6896cedd76365.zip | |
Merge branch 'develop' of https://github.com/misskey-dev/misskey into develop
Diffstat (limited to 'packages')
| -rw-r--r-- | packages/frontend/src/components/MkHorizontalSwipe.vue | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/packages/frontend/src/components/MkHorizontalSwipe.vue b/packages/frontend/src/components/MkHorizontalSwipe.vue index 55bb4b13b0..67d32c505a 100644 --- a/packages/frontend/src/components/MkHorizontalSwipe.vue +++ b/packages/frontend/src/components/MkHorizontalSwipe.vue @@ -6,7 +6,7 @@ SPDX-License-Identifier: AGPL-3.0-only <template> <div ref="rootEl" - :class="[$style.transitionRoot]" + :class="[$style.transitionRoot, { [$style.enableAnimation]: shouldAnimate }]" @touchstart.passive="touchStart" @touchmove.passive="touchMove" @touchend.passive="touchEnd" @@ -44,6 +44,8 @@ const emit = defineEmits<{ (ev: 'swiped', newKey: string, direction: 'left' | 'right'): void; }>(); +const shouldAnimate = computed(() => defaultStore.reactiveState.enableHorizontalSwipe.value || defaultStore.reactiveState.animation.value); + // ▼ しきい値 ▼ // // スワイプと判定される最小の距離 @@ -188,7 +190,9 @@ watch(tabModel, (newTab, oldTab) => { .transitionChildren { grid-area: 1 / 1 / 2 / 2; transform: translateX(var(--swipe)); +} +.enableAnimation .transitionChildren { &.swipeAnimation_enterActive, &.swipeAnimation_leaveActive { transition: transform .3s cubic-bezier(0.65, 0.05, 0.36, 1); |