Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(feat/beta): 25% of October 2024 Banana 🍌 #11093

Merged
merged 11 commits into from
Oct 8, 2024
14 changes: 5 additions & 9 deletions components/carousel/CarouselTypeRelated.vue
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
<template>
<div>
<LoadLazily>
<CarouselIndex
v-if="nfts"
:title="`${$t('nft.related')}`"
:nfts="nfts"
/>
</LoadLazily>
</div>
<LazyCarouselIndex
v-if="nfts"
:title="$t('nft.related')"
:nfts="nfts"
/>
</template>

<script lang="ts" setup>
Expand Down
4 changes: 2 additions & 2 deletions components/carousel/CarouselTypeVisited.vue
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<template>
<CarouselIndex
<LazyCarouselIndex
v-if="showCarousel"
:title="`${$t('nft.visited')}`"
:title="$t('nft.visited')"
:nfts="nfts"
/>
</template>
Expand Down
2 changes: 1 addition & 1 deletion components/collection/CollectionCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
import { NeoSkeleton } from '@kodadot1/brick'
import type { TokenMetadata } from '@kodadot1/hyperdata'
import CollectionDetail from './CollectionDetail.vue'
import type { CollectionWithMeta } from '@/components/rmrk/service/scheme'
import type { CollectionWithMeta } from '@/types'
import BasicImage from '@/components/shared/view/BasicImage.vue'
import { processSingleMetadata } from '@/utils/cachingStrategy'
import { sanitizeIpfsUrl } from '@/utils/ipfs'
Expand Down
2 changes: 1 addition & 1 deletion components/collection/CollectionDetail.vue
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@

<script lang="ts" setup>
import { NeoSkeleton } from '@kodadot1/brick'
import type { Interaction, NFT } from '@/components/rmrk/service/scheme'
import type { Interaction, NFT } from '@/types'
import { getVolume } from '@/utils/math'
import BasicImage from '@/components/shared/view/BasicImage.vue'
import CommonTokenMoney from '@/components/shared/CommonTokenMoney.vue'
Expand Down
2 changes: 1 addition & 1 deletion components/collection/CollectionGrid.vue
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@

<script lang="ts" setup>
import isEqual from 'lodash/isEqual'
import type { Collection } from '@/components/rmrk/service/scheme'
import type { Collection } from '@/types'
import type { SearchQuery } from '@/components/search/types'
import collectionListWithSearch from '@/queries/subsquid/general/collectionListWithSearch.graphql'
import collectionListWithSearchProfile from '@/queries/subsquid/general/collectionListWithSearchProfile.graphql'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
</template>

<script setup lang="ts">
import type { NFTMetadata } from '@/components/rmrk/service/scheme'
import type { NFTMetadata } from '@/types'
import { processSingleMetadata } from '@/utils/cachingStrategy'
import { sanitizeIpfsUrl, toOriginalContentUrl } from '@/utils/ipfs'
import HeroButtons from '@/components/collection/HeroButtons.vue'
Expand Down
2 changes: 1 addition & 1 deletion components/collection/activity/ActivityChart.vue
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ import {
sortAsc,
toDataPoint,
} from './utils'
import type { ActivityInteraction } from '@/components/rmrk/service/scheme'
import type { ActivityInteraction } from '@/types'
import PriceChart from '@/components/chart/PriceChart.vue'

const { decimals } = useChain()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
<script setup lang="ts">
import { sanitizeIpfsUrl } from '@/utils/ipfs'
import { processSingleMetadata } from '@/utils/cachingStrategy'
import type { NFTMetadata } from '@/components/rmrk/service/scheme'
import type { NFTMetadata } from '@/types'
import Money from '@/components/shared/format/ChainMoney.vue'
import type { FlipEvent } from '@/composables/collectionActivity/types'
import { format } from '@/components/collection/activity/utils'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
<script setup lang="ts">
import { sanitizeIpfsUrl } from '@/utils/ipfs'
import { processSingleMetadata } from '@/utils/cachingStrategy'
import type { NFTMetadata } from '@/components/rmrk/service/scheme'
import type { NFTMetadata } from '@/types'
import type { NFTExcludingEvents } from '@/composables/collectionActivity/types'
import BasicImage from '@/components/shared/view/BasicImage.vue'

Expand Down
2 changes: 1 addition & 1 deletion components/collection/utils/types.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { CollectionMetadata } from '@/components/rmrk/service/scheme'
import type { CollectionMetadata } from '@/types'

export type Stats = {
listedCount?: number
Expand Down
2 changes: 1 addition & 1 deletion components/collection/utils/useCollectionDetails.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { useQuery } from '@tanstack/vue-query'
import type { Stats } from './types'
import { getVolume } from '@/utils/math'
import type { NFT, NFTMetadata } from '@/components/rmrk/service/scheme'
import type { NFT, NFTMetadata } from '@/types'
import type { NFTListSold } from '@/components/identity/utils/useIdentity'
import { processSingleMetadata } from '@/utils/cachingStrategy'
import collectionBuyEventStatsById from '@/queries/subsquid/general/collectionBuyEventStatsById.query'
Expand Down
2 changes: 1 addition & 1 deletion components/common/itemTransfer/ItemTransferModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ import { NeoButton, NeoIcon, NeoModal } from '@kodadot1/brick'
import { Interaction } from '@kodadot1/minimark/v1'
import { toSubstrateAddress } from '@/services/profile'
import ModalIdentityItem from '@/components/shared/ModalIdentityItem.vue'
import type { NFT } from '@/components/rmrk/service/scheme'
import type { NFT } from '@/types'
import BasicImage from '@/components/shared/view/BasicImage.vue'
import { parseNftAvatar } from '@/utils/nft'
import AddressInput from '@/components/shared/AddressInput.vue'
Expand Down
2 changes: 1 addition & 1 deletion components/common/shoppingCart/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import type {
CollectionFloorPrice,
EntityWithId,
NFTMetadata,
} from '@/components/rmrk/service/scheme'
} from '@/types'

import type { Royalty } from '@/utils/royalty'

Expand Down
2 changes: 1 addition & 1 deletion components/common/shoppingCart/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { calculateExactUsdFromToken } from '@/utils/calculation'
import type { ListCartItem, ListCartItemMediaUrl } from '@/stores/listingCart'
import { useFiatStore } from '@/stores/fiat'
import { sum } from '@/utils/math'
import type { NFT, TokenId } from '@/components/rmrk/service/scheme'
import type { NFT, TokenId } from '@/types'
import { chainPropListOf } from '@/utils/config/chain.config'
import type { MakingOfferItem } from '@/components/offer/types'

Expand Down
2 changes: 1 addition & 1 deletion components/create/CreateNft.vue
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,7 @@ import {
NeoSelect,
NeoSwitch,
} from '@kodadot1/brick'
import { toNFTId } from '@kodadot1/minimark/v2'
import type { CreatedNFT } from '@kodadot1/minimark/v1'
import { Interaction } from '@kodadot1/minimark/v1'
import CreateNftPreview from './CreateNftPreview.vue'
Expand All @@ -313,7 +314,6 @@ import { availablePrefixes } from '@/utils/chain'
import { balanceFrom } from '@/utils/balance'
import { DETAIL_TIMEOUT } from '@/utils/constants'
import { delay } from '@/utils/fetch'
import { toNFTId } from '@/components/rmrk/service/scheme'
import type { AutoTeleportAction } from '@/composables/autoTeleport/types'
import type { AutoTeleportActionButtonConfirmEvent } from '@/components/common/autoTeleport/AutoTeleportActionButton.vue'

Expand Down
2 changes: 0 additions & 2 deletions components/gallery/GalleryItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -178,8 +178,6 @@ import GalleryItemDescription from './GalleryItemDescription.vue'
import GalleryItemTabsPanel from './GalleryItemTabsPanel/GalleryItemTabsPanel.vue'
import UnlockableTag from './UnlockableTag.vue'
import { useGalleryItem } from './useGalleryItem'
import CarouselTypeRelated from '@/components/carousel/CarouselTypeRelated.vue'
import CarouselTypeVisited from '@/components/carousel/CarouselTypeVisited.vue'
import CollectionDetailsPopover from '@/components/collectionDetailsPopover/CollectionDetailsPopover.vue'
import { MediaType } from '@/components/rmrk/types'
import { usePreferencesStore } from '@/stores/preferences'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import GalleryItemOffer from './GalleryItemActionType/GalleryItemOffer.vue'
import GalleryItemPriceRelist from './GalleryItemActionType/GalleryItemRelist.vue'
import { listVisible, offerVisible } from '@/utils/config/permission.config'
import type { NFTOffer } from '@/composables/useNft'
import type { NFT } from '@/components/rmrk/service/scheme'
import type { NFT } from '@/types'

const props = defineProps<{
nft: NFT | undefined
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ import GalleryItemPriceSection from '../GalleryItemActionSection.vue'
import { useShoppingCartStore } from '@/stores/shoppingCart'
import { usePreferencesStore } from '@/stores/preferences'
import { openShoppingCart } from '@/components/common/shoppingCart/ShoppingCartModalConfig'
import type { NFT } from '@/components/rmrk/service/scheme'
import type { NFT } from '@/types'
import { nftToShoppingCartItem } from '@/components/common/shoppingCart/utils'
import { doAfterCheckCurrentChainVM } from '@/components/common/ConnectWallet/openReconnectWalletModal'

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

<script setup lang="ts">
import { NeoButton } from '@kodadot1/brick'
import type { NFT } from '@/components/rmrk/service/scheme'
import type { NFT } from '@/types'
import { nftToOfferItem } from '@/components/common/shoppingCart/utils'
import { usePreferencesStore } from '@/stores/preferences'
import { useMakingOfferStore } from '@/stores/makeOffer'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<script setup lang="ts">
import { NeoButton } from '@kodadot1/brick'
import GalleryItemPriceSection from '../GalleryItemActionSection.vue'
import type { NFT } from '@/components/rmrk/service/scheme'
import type { NFT } from '@/types'
import { nftToListingCartItem } from '@/components/common/shoppingCart/utils'
import { useCollectionDetails } from '@/components/collection/utils/useCollectionDetails'
import ListingCartModal from '@/components/common/listingCart/ListingCartModal.vue'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ import { isMobileDevice } from '@/utils/extension'
import { hasOperationsDisabled } from '@/utils/prefix'
import { refreshOdaTokenMetadata } from '@/services/oda'
import ItemTransferModal from '@/components/common/itemTransfer/ItemTransferModal.vue'
import type { NFT } from '@/components/rmrk/service/scheme'
import type { NFT } from '@/types'
import type { Abi } from '@/composables/transaction/types'

const { $i18n, $consola } = useNuxtApp()
Expand Down
2 changes: 1 addition & 1 deletion components/gallery/GalleryItemHolderOf.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
<script setup lang="ts">
import { NeoIcon } from '@kodadot1/brick'
import { useDrop, useHolderOfCollectionDrop } from '../drops/useDrops'
import type { NFT } from '@/components/rmrk/service/scheme'
import type { NFT } from '@/types'
import {
DROP_COLLECTION_TO_ALIAS_MAP,
FALLBACK_DROP_COLLECTION_MAX,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ import Identity from '@/components/identity/IdentityIndex.vue'
import { formatToNow } from '@/utils/format/time'
import { parseDate } from '@/utils/datetime'

import type { Interaction } from '@/components/rmrk/service/scheme'
import type { Interaction } from '@/types'
import useSubscriptionGraphql from '@/composables/useSubscriptionGraphql'

const dprops = defineProps<{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
</template>

<script lang="ts" setup>
import type { Interaction } from '@/components/rmrk/service/scheme'
import type { Interaction } from '@/types'
import PriceChart from '@/components/chart/PriceChart.vue'
import { parseChartAmount } from '@/utils/historyEvent'

Expand Down
2 changes: 1 addition & 1 deletion components/gallery/UnlockableTag.vue
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@

<script lang="ts" setup>
import { NeoTooltip } from '@kodadot1/brick'
import type { NFT } from '@/components/rmrk/service/scheme'
import type { NFT } from '@/types'
import { useIcon } from '@/composables/useIcon'

const props = defineProps<{
Expand Down
2 changes: 1 addition & 1 deletion components/identity/module/IdentityPopoverFooter.vue
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@
import { NeoSkeleton } from '@kodadot1/brick'
import useIdentityStats from '../utils/useIdentityStats'
import { fetchFollowersOf } from '@/services/profile'
import type { NFT } from '@/components/rmrk/service/scheme'
import type { NFT } from '@/types'

const GalleryCard = defineAsyncComponent(
() => import('../../rmrk/Gallery/GalleryCard.vue'),
Expand Down
2 changes: 1 addition & 1 deletion components/identity/utils/useIdentity.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { NFT } from '@/components/rmrk/service/scheme'
import type { NFT } from '@/types'

export interface NFTListSold {
nftEntities?: NFT[]
Expand Down
2 changes: 1 addition & 1 deletion components/items/ItemsGrid/ItemsGrid.vue
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ import {
import { getTokensNfts } from './useNftActions'
import { useListingCartStore } from '@/stores/listingCart'
import DynamicGrid from '@/components/shared/DynamicGrid.vue'
import type { NFT } from '@/components/rmrk/service/scheme'
import type { NFT } from '@/types'
import type { GridSection } from '@/stores/preferences'

const slots = useSlots()
Expand Down
2 changes: 1 addition & 1 deletion components/items/ItemsGrid/useItemsGrid.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { getDenyList } from '@/utils/prefix'
import type { NFTWithMetadata, TokenEntity } from '@/composables/useNft'
import { nftToListingCartItem } from '@/components/common/shoppingCart/utils'
import { useListingCartStore } from '@/stores/listingCart'
import type { NFT, TokenId } from '@/components/rmrk/service/scheme'
import type { NFT, TokenId } from '@/types'

const DEFAULT_RESET_SEARCH_QUERY_PARAMS = [
'sort',
Expand Down
2 changes: 1 addition & 1 deletion components/items/ItemsGrid/useNftActions.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import nftById from '@/queries/subsquid/general/nftById.graphql'
import listCount from '@/queries/subsquid/general/countOfTokenNftsToList.graphql'
import nftListWithSearch from '@/queries/subsquid/ahk/nftListWithSearch.graphql'
import type { TokenId } from '@/components/rmrk/service/scheme'
import type { TokenId } from '@/types'

export type NFTWitToken = NFTWithMetadata & TokenId
export const isStack = (entity: TokenEntity) => entity.supply > 1
Expand Down
2 changes: 1 addition & 1 deletion components/landing/topCollections/utils/types.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { Interaction } from '~~/components/rmrk/service/scheme'
import type { Interaction } from '@/types'

export type CollectionEntity = {
id: string
Expand Down
2 changes: 1 addition & 1 deletion components/offer/OfferOverviewModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ import { NeoModal } from '@kodadot1/brick'
import ModalBody from '@/components/shared/modals/ModalBody.vue'
import ModalIdentityItem from '@/components/shared/ModalIdentityItem.vue'
import nftById from '@/queries/subsquid/general/nftById.graphql'
import type { NFT } from '@/components/rmrk/service/scheme'
import type { NFT } from '@/types'
import { nftToOfferItem } from '@/components/common/shoppingCart/utils'
import { formatToNow } from '@/utils/format/time'

Expand Down
2 changes: 1 addition & 1 deletion components/offer/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import type {
CollectionFloorPrice,
EntityWithId,
NFTMetadata,
} from '@/components/rmrk/service/scheme'
} from '@/types'

export type MakingOfferItem = {
urlPrefix: string
Expand Down
2 changes: 1 addition & 1 deletion components/profile/activityTab/History.vue
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ import { usePreferencesStore } from '@/stores/preferences'
import { HistoryEventType, InteractionBsxOnly } from '@/utils/historyEvent'
import { parseDate } from '@/utils/datetime'

import type { Interaction as EventInteraction } from '@/components/rmrk/service/scheme'
import type { Interaction as EventInteraction } from '@/types'
import ResponsiveTable from '@/components/shared/ResponsiveTable.vue'
import Pagination from '@/components/rmrk/Gallery/Pagination.vue'
import { emptyObject } from '@/utils/empty'
Expand Down
2 changes: 1 addition & 1 deletion components/rmrk/Gallery/GalleryCard.vue
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ import { processSingleMetadata } from '@/utils/cachingStrategy'
import { getMimeType } from '@/utils/gallery/media'
import { sanitizeIpfsUrl } from '@/utils/ipfs'

import type { NFTMetadata } from '@/components/rmrk/service/scheme'
import type { NFTMetadata } from '@/types'
import { usePreferencesStore } from '@/stores/preferences'

const props = withDefaults(
Expand Down
2 changes: 1 addition & 1 deletion components/rmrk/Gallery/Holder/Holder.vue
Original file line number Diff line number Diff line change
Expand Up @@ -205,8 +205,8 @@ import {
NeoTableColumn,
NeoTooltip,
} from '@kodadot1/brick'
import type { Interaction as EventInteraction } from '../../service/scheme'
import { parsePriceForItem } from './helper'
import type { Interaction as EventInteraction } from '@/types'
import { toPercent } from '@/utils/filters'
import { parseDate } from '@/utils/datetime'
import { usePreferencesStore } from '@/stores/preferences'
Expand Down
11 changes: 0 additions & 11 deletions components/rmrk/service/NftUtils.ts

This file was deleted.

5 changes: 1 addition & 4 deletions components/search/SearchSuggestion.vue
Original file line number Diff line number Diff line change
Expand Up @@ -285,10 +285,7 @@ import { useTopCollections } from '../landing/topCollections/utils/useTopCollect
import { fetchCollectionSuggestion } from './utils/collectionSearch'
import type { DefaultCollectionSuggestion, SearchQuery } from './types'
import { getDenyList } from '@/utils/prefix'
import {
type CollectionWithMeta,
type NFTWithMeta,
} from '@/components/rmrk/service/scheme'
import type { CollectionWithMeta, NFTWithMeta } from '@/types'
import { sanitizeIpfsUrl } from '@/utils/ipfs'
import { logError, mapNFTorCollectionMetadata } from '@/utils/mappers'
import { processMetadata } from '@/utils/cachingStrategy'
Expand Down
2 changes: 1 addition & 1 deletion components/search/types.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { CollectionWithMeta, NFTWithMeta } from '../rmrk/service/scheme'
import type { CollectionWithMeta, NFTWithMeta } from '@/types'

export type QueryType = Record<string, unknown>

Expand Down
2 changes: 1 addition & 1 deletion components/series/SeriesTable.vue
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ import {
toSort,
today,
} from './utils'
import type { Collection } from '@/components/rmrk/service/scheme'
import type { Collection } from '@/types'
import { exist } from '@/utils/exist'
import { sanitizeIpfsUrl } from '@/utils/ipfs'
import collectionsEvents from '@/queries/rmrk/subsquid/collectionsEvents.graphql'
Expand Down
2 changes: 1 addition & 1 deletion components/series/utils.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { eachDayOfInterval, formatISO, subDays } from 'date-fns'
import type { Interaction } from '../rmrk/service/scheme'
import type { SortType } from './types'
import type { Interaction } from '@/types'
import { after, between, getVolume } from '@/utils/math'

export const today = new Date()
Expand Down
Loading
Loading