Skip to content

Commit

Permalink
Merge branch 'main' into issue-offer-reuse-nft
Browse files Browse the repository at this point in the history
  • Loading branch information
hassnian authored Jan 2, 2025
2 parents 9ca79ac + e937678 commit c663b01
Show file tree
Hide file tree
Showing 48 changed files with 6,403 additions and 7,119 deletions.
85 changes: 0 additions & 85 deletions components/base/BaseCollectionForm.vue

This file was deleted.

2 changes: 1 addition & 1 deletion components/drops/CreateCalendarEventModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ const eventDetails = {
const getNextDropDate = (): Date => {
const currentDate = new Date()
const daysUntilThursday = (11 - currentDate.getDay()) % 7
const millisecondsUntilThursday = daysUntilThursday * 24 * 60 * 60 * 1000
const millisecondsUntilThursday = daysUntilThursday * ONE_DAY_MS
currentDate.setUTCHours(14, 0, 0, 0) // Set time to 3 PM CET
const dropDate = new Date(currentDate.getTime() + millisecondsUntilThursday)
dropDate.setHours(currentDate.getHours())
Expand Down
3 changes: 1 addition & 2 deletions components/drops/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ export const parseCETDate = (datetime: string): Date => {

export const dateHasTime = (datetime: string): boolean => /:/.test(datetime)

const ONE_DAYH_IN_MS = 24 * 60 * 60 * 1000
const getLocalDropStatus = (drop: Pick<DropItem, 'dropStartTime' | 'minted' | 'max' | 'disabled'>): DropStatus => {
const now = new Date()

Expand All @@ -81,7 +80,7 @@ const getLocalDropStatus = (drop: Pick<DropItem, 'dropStartTime' | 'minted' | 'm
return DropStatus.MINTING_LIVE
}

if (drop.dropStartTime.valueOf() - now.valueOf() <= ONE_DAYH_IN_MS) {
if (drop.dropStartTime.valueOf() - now.valueOf() <= ONE_DAY_MS) {
return DropStatus.SCHEDULED_SOON
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,26 +86,11 @@ const onMakeOfferClick = () => {
const onSwapClick = () => {
onTradeActionClick(() => {
const nft = props.nft
const swap = swapStore.createSwap(nft.currentOwner)
swapStore.updateItem({
...swap,
desired: [
{
id: nft.id,
collectionId: nft.collection.id,
sn: nft.sn,
name: nft.name,
meta: nft.meta,
},
],
const swap = swapStore.createSwap(nft.currentOwner, {
desired: [nftToSwapItem(nft)],
})
navigateTo({
name: 'prefix-swap-id',
params: { id: nft.currentOwner },
query: { swapId: swap.id },
})
navigateToSwap(swap)
})
}
Expand Down
9 changes: 7 additions & 2 deletions components/gallery/useGalleryItem.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,12 @@ export const useGalleryItem = (nftId?: string): GalleryItem => {
},
})

const refreshToken = async () => {
const getIndexerToken = () => {
refetch({ id })
}

const refreshToken = async () => {
getIndexerToken()
getOdaToken()
}

Expand Down Expand Up @@ -120,7 +124,8 @@ export const useGalleryItem = (nftId?: string): GalleryItem => {
id
}
}`,
onChange: refetch,
onChange: getIndexerToken,
immediate: false,
})

useSubscriptionGraphql({
Expand Down
3 changes: 3 additions & 0 deletions components/items/ItemsGrid/ItemsGrid.vue
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
? 'minimal'
: 'primary'
"
:link-target="linkTarget"
/>
<ItemsGridImageTokenEntity
v-else
Expand All @@ -51,6 +52,7 @@
:hide-action="hideNFTHoverAction"
:hide-listing="hideListing"
hide-video-controls
:link-target="linkTarget"
:lazy-loading="
shouldLazyLoad({
cols: slotProps.cols,
Expand Down Expand Up @@ -148,6 +150,7 @@ const props = defineProps<{
hideHoverAction?: boolean
collectionPopoverHide?: boolean
hideListing?: boolean
linkTarget?: string
}>()
const emit = defineEmits(['total', 'loading'])
Expand Down
2 changes: 2 additions & 0 deletions components/items/ItemsGrid/ItemsGridImage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
bind-key="to"
:media-static-video="hideVideoControls"
media-hover-on-cover-play
:link-target="linkTarget"
>
<template
v-if="!hideAction"
Expand Down Expand Up @@ -106,6 +107,7 @@ const props = defineProps<{
collectionPopoverHide?: boolean
lazyLoading?: boolean
skeletonVariant: string
linkTarget?: string
}>()
const {
Expand Down
2 changes: 2 additions & 0 deletions components/items/ItemsGrid/ItemsGridImageTokenEntity.vue
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
:media-static-video="hideVideoControls"
:lazy-loading="lazyLoading"
media-hover-on-cover-play
:link-target="linkTarget"
>
<template
v-if="!hideAction"
Expand Down Expand Up @@ -123,6 +124,7 @@ const props = defineProps<{
lazyLoading?: boolean
skeletonVariant: string
hideListing?: boolean
linkTarget?: string
}>()
const {
Expand Down
162 changes: 0 additions & 162 deletions components/rmrk/Create/CreateCollection.vue

This file was deleted.

Loading

0 comments on commit c663b01

Please sign in to comment.