Skip to content

Commit

Permalink
🎨 fix: StampRecordPerUser を StampUser に変更
Browse files Browse the repository at this point in the history
#4320 (comment) を参考に
  • Loading branch information
reiroop committed Jun 29, 2024
1 parent a61a1b8 commit 3101a06
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,7 @@
import StampDetailElementContent from './StampDetailElementContent.vue'
import { computed } from 'vue'
import { useStampsStore } from '/@/store/entities/stamps'
import type {
StampRecordPerUser,
MessageStampById
} from '/@/lib/messageStampList'
import type { StampUser, MessageStampById } from '/@/lib/messageStampList'
const props = defineProps<{
stamp: MessageStampById
Expand All @@ -33,7 +30,7 @@ const stampName = computed(
() => stampsMap.value.get(props.stamp.id)?.name ?? ''
)
const isLastUser = (user: StampRecordPerUser) =>
const isLastUser = (user: StampUser) =>
user === props.stamp.users[props.stamp.users.length - 1]
</script>

Expand Down
4 changes: 2 additions & 2 deletions src/lib/messageStampList.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import type { StampId, UserId } from '/@/types/entity-ids'
/**
* ユーザー、そのユーザーの押した数と最初に押した時間
*/
export interface StampRecordPerUser {
export interface StampUser {
id: UserId
count: number
createdAt: Date
Expand All @@ -29,7 +29,7 @@ export interface MessageStampById {
/**
* ユーザー、そのユーザーの押した数と最初に押した時間
*/
users: Array<StampRecordPerUser>
users: Array<StampUser>
/**
* 一番最初に押された時間
*/
Expand Down

0 comments on commit 3101a06

Please sign in to comment.