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

(prod): 22% of October 2024 Banana 🍌 #11091

Merged
merged 113 commits into from
Oct 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
113 commits
Select commit Hold shift + click to select a range
e2d3e3d
refactor(gallery): streamline NFT metadata fetching
preschian Sep 5, 2024
ac5497c
feat(store): create nft store with initial state
preschian Sep 5, 2024
fbd27d5
feat(gallery): integrate NFT store with GalleryItem component
preschian Sep 5, 2024
419b9bd
refactor(gallery): replace useGalleryItem with useNftStore in components
preschian Sep 5, 2024
e02bbb2
refactor(types): remove unused interfaces and dependencies
preschian Sep 5, 2024
c025f37
feat(oda): add service functions for ODA collection and token management
preschian Sep 5, 2024
a0bb80d
feat(gallery): add refresh metadata option to GalleryItemMoreActionBtn
preschian Sep 5, 2024
196d238
refactor(media): simplify metadata fetching logic and remove unused f…
preschian Sep 5, 2024
a6704e8
refactor(nft): remove redundant nameWithIndex utility function
preschian Sep 5, 2024
e50695d
refactor(nftCard): remove redundant text rendering in template
preschian Sep 5, 2024
ce8c8c0
fix(gallery): add early return for remark chain in useGalleryItem
preschian Sep 5, 2024
60ff2c9
fix(gallery): handle missing metadata in useGalleryItem function
preschian Sep 6, 2024
eba17e0
refactor(routing): implement redirect to gallery page using script setup
preschian Sep 6, 2024
0c234ca
Merge branch 'main' of github.com:kodadot/nft-gallery into fix--get-t…
preschian Sep 7, 2024
93e4923
test(e2e): update collection test for new collection details
preschian Sep 7, 2024
99277f6
test(search): update search term and landing path in e2e test
preschian Sep 7, 2024
c2fb564
fix(items-grid): display correct entity data from chain
preschian Sep 7, 2024
397d3c6
refactor(gallery): replace direct store references with storeToRefs u…
preschian Sep 9, 2024
16d8fbe
fix(gallery): add toast notification before refreshing metadata
preschian Sep 9, 2024
dcfec56
refactor(oda): remove unused QueryClient import
preschian Sep 9, 2024
ca52353
Merge branch 'main' of github.com:kodadot/nft-gallery into fix--get-t…
preschian Sep 10, 2024
34864e9
refactor(activityTab): remove serial number from offer display
preschian Sep 10, 2024
7fd63e2
Merge branch 'main' of github.com:kodadot/nft-gallery into fix--get-t…
preschian Sep 13, 2024
9291723
✨ locales order sript
roiLeo Sep 19, 2024
6711748
🔧 order en.json locale
roiLeo Sep 19, 2024
8bdddfc
Update components/common/party/CursorParty.vue
roiLeo Sep 19, 2024
3dd5c22
Update components/create/Confirm/MintConfirmModal.vue
roiLeo Sep 19, 2024
60ba573
Update components/create/CreateNft.vue
roiLeo Sep 19, 2024
799211b
Update components/profile/activityTab/History.vue
roiLeo Sep 19, 2024
db9a059
Update components/profile/create/stages/Form.vue
roiLeo Sep 19, 2024
8a64927
Update components/shared/DynamicGrid.vue
roiLeo Sep 19, 2024
fc210ee
Update components/shared/TransactionSteps/utils.ts
roiLeo Sep 19, 2024
223c03a
Update composables/autoTeleport/useAutoTeleportTransactionActions.ts
roiLeo Sep 19, 2024
72421b2
Update composables/autoTeleport/useAutoTeleportTransitionDetails.ts
roiLeo Sep 19, 2024
bf3a0d3
Update composables/usePrefix.ts
roiLeo Sep 19, 2024
24000d9
Update utils/math.ts and make reviewdog happy
roiLeo Sep 19, 2024
7112fea
fix(offers): show `EXPIRED` offer expiration date as `expired`
hassnian Sep 23, 2024
89c6723
fix(OwnerButton.vue): show `withdraw amount` when offer is expired
hassnian Sep 23, 2024
459bec4
ref(OfferRow.vue): reuse `ieExpired` computed
hassnian Sep 23, 2024
e523ca8
Merge branch 'main' into issue-11028
hassnian Sep 23, 2024
4f1025e
🔧 base profile contains insensitive
roiLeo Sep 23, 2024
f02a61d
fix(CollectionBanner.vue): overfetching unsued collection nfts data
hassnian Sep 24, 2024
19816b1
fix(CollectionBanner.vue): fetching collection info twice
hassnian Sep 25, 2024
aedb5bc
fix(CollectionRelatedDropNotification.vue): non-drop collection showi…
hassnian Sep 25, 2024
e75006e
Merge branch 'main' into issue-11038
hassnian Sep 25, 2024
c47d8d3
ref(useCollectionDetails.ts): variable rename
hassnian Sep 25, 2024
a08bf15
Merge branch 'issue-11038' of https://github.com/hassnian/nft-gallery…
hassnian Sep 25, 2024
fe3e149
Merge branch 'main' into feature/locales/order
roiLeo Sep 25, 2024
a0011c7
👷 run locales:order on commit
roiLeo Sep 25, 2024
7e7945f
ref(useCollectionDetails.ts): remove unnecessary `collectionDrop` var…
hassnian Sep 26, 2024
872c4db
ref(useCollectionDetails.ts): cleanup collection minimal data fetching
hassnian Sep 26, 2024
1d98cac
fix(useCollectionDetails.ts): collection data ref issue
hassnian Sep 28, 2024
67df7ce
ref(ListingCartModal.vue): move `closeListingCartModal` to `useListin…
hassnian Sep 30, 2024
cf18d05
fix(ListingCartModal.vue): clear discard items on modal animation
hassnian Sep 30, 2024
8ef07a2
fix(ListingCartModal.vue): modal animation & success after click `list`
hassnian Sep 30, 2024
48665a8
Merge branch 'main' into fix/base/profileCount
roiLeo Sep 30, 2024
614b8dc
fix(ListingCartModal.vue): clearing items before modal close
hassnian Sep 30, 2024
d9c3c3f
Merge branch 'main' into issue-10662
hassnian Sep 30, 2024
83bc83d
🔧 replace containsInsensitive with eq
roiLeo Sep 30, 2024
63846d3
🔧 replace containsInsensitive with eq
roiLeo Sep 30, 2024
55fed7e
🔧 replace containsInsensitive with eq
roiLeo Sep 30, 2024
f0ffd27
Merge branch 'main' of github.com:kodadot/nft-gallery into fix--get-t…
preschian Sep 30, 2024
3ab723a
feat(nft): integrate collection ABI fetching across components
preschian Sep 30, 2024
ad25851
Merge branch 'main' into feature/locales/order
roiLeo Sep 30, 2024
f5d7be1
Update ParaSpell to v6.1.1
dudo50 Oct 1, 2024
6fe3e47
Merge pull request #11009 from roiLeo/feature/locales/order
vikiival Oct 1, 2024
09365ae
fix(useDrops.ts): minimum funds not taking item deposit into account
hassnian Oct 1, 2024
20ebd87
fix(drops): enable autotelport action auto fees
hassnian Oct 1, 2024
597b2c8
fix(AddFundsModal.vue): remove ActionlessInteraction.FREE_DROP as enum
hassnian Oct 1, 2024
c368755
fix(AutoTeleportActionButton.vue): prop with default values are required
hassnian Oct 1, 2024
5046efe
fix(useDeposit.ts): `useDeposit` enable for sub only
hassnian Oct 1, 2024
3eb4ea6
fix: Create NFT - adjust font
Jarsen136 Oct 1, 2024
480b04b
fix(useDropMinimumFunds): item deposit for free nfts
hassnian Oct 2, 2024
9dd5171
Merge branch 'main' into issue-11038
hassnian Oct 2, 2024
8a0cc9d
add(collection activity.): loading skeleton
hassnian Oct 2, 2024
68137aa
Merge branch 'main' into main
vikiival Oct 2, 2024
7b171e9
Merge branch 'main' into fix/base/profileCount
roiLeo Oct 2, 2024
7cb037b
refactor(gallery): reorder variable assignments for clarity
preschian Oct 3, 2024
4a1b1bf
Merge branch 'main' of github.com:kodadot/nft-gallery into fix--get-t…
preschian Oct 3, 2024
6565469
Merge pull request #11039 from hassnian/issue-11038
vikiival Oct 3, 2024
b24fdee
Merge pull request #11073 from Jarsen136/issue-11070
vikiival Oct 3, 2024
f980181
Merge pull request #11066 from dudo50/main
vikiival Oct 3, 2024
6e86ac6
Merge pull request #11067 from hassnian/issue-11059
vikiival Oct 3, 2024
8eef09c
Merge branch 'main' into fix/base/profileCount
roiLeo Oct 3, 2024
8d4ecac
Merge branch 'main' into fix--get-token-metadata-from-onchain
preschian Oct 3, 2024
ff308ad
Merge pull request #10934 from kodadot/fix--get-token-metadata-from-o…
preschian Oct 3, 2024
ba4ff11
Merge pull request #11031 from roiLeo/fix/base/profileCount
vikiival Oct 3, 2024
6921486
fix(PaidMint.vue): failed transaction succeeding
hassnian Oct 3, 2024
26d548c
fix(useMetaTransaction.ts): failed unsubmitted transaction not stopping
hassnian Oct 3, 2024
88f2c86
🔧 list action
roiLeo Oct 3, 2024
104c1da
Merge pull request #11077 from roiLeo/hotfix/action/list
vikiival Oct 3, 2024
2ea2830
fix(useTransactionSuccessful.ts): not tracking if transaction success…
hassnian Oct 4, 2024
5c3964a
Merge branch 'main' into issue-11060
hassnian Oct 4, 2024
df33361
ref(useTransactionSuccessful.ts): rollback to prev simpler version
hassnian Oct 4, 2024
136bdca
fix(SkeletonLoader.vue): loading with dots "dancing"
hassnian Oct 5, 2024
bca4256
feat: offer fees displayed in the modal
Jarsen136 Oct 5, 2024
9fd8d90
fix: Royalty Rate (%) - not intiutive in Create
Jarsen136 Oct 6, 2024
e2af23f
Merge pull request #11084 from Jarsen136/issue-11071
vikiival Oct 6, 2024
6f3ed25
fix(useMetaTransaction.ts): sync wallet chain before signing
hassnian Oct 7, 2024
d1f9fcf
Merge pull request #11083 from Jarsen136/issue-11040
vikiival Oct 7, 2024
7f4e16f
Merge pull request #11078 from hassnian/issue-11060
vikiival Oct 7, 2024
d8ce9a8
Merge branch 'main' into issue-10662
vikiival Oct 7, 2024
862805e
Merge pull request #11057 from hassnian/issue-10662
vikiival Oct 7, 2024
0dfd77e
ref(SkeletonLoader.vue): typo
hassnian Oct 7, 2024
557698d
fix(OfferRow.vue): `isExpired` typo
hassnian Oct 7, 2024
d3432b0
Merge branch 'main' into issue-11028
hassnian Oct 7, 2024
b1f2618
Merge branch 'main' into issue-11069-2
vikiival Oct 7, 2024
6dcd66d
Merge pull request #11082 from hassnian/issue-11069-2
vikiival Oct 7, 2024
f58cda2
Merge pull request #11030 from hassnian/issue-11028
vikiival Oct 7, 2024
cf89e8f
Merge pull request #11086 from hassnian/issue-11024-1
vikiival Oct 7, 2024
d010b0c
🔧 collection tests
roiLeo Oct 7, 2024
6e00fa8
Merge pull request #11089 from roiLeo/fix/tests/collection
preschian Oct 7, 2024
6f0b3e5
Merge pull request #11087 from kodadot/main
vikiival Oct 7, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 0 additions & 26 deletions assets/styles/pages/create.scss
Original file line number Diff line number Diff line change
Expand Up @@ -14,29 +14,3 @@
border: 1px solid theme('card-border-color');
}
}

.sale :deep(.o-field__label) {
position: relative;
-webkit-text-stroke: 1px #000;
filter: drop-shadow(1px 1px #000);
font-weight: 700;
font-size: 18px;
}

.sale {
position: relative;
}

.hidden-sale-label {
@apply absolute pointer-events-none text-transparent bg-clip-text font-bold text-lg left-0 top-0;
background: linear-gradient(to right, white, white, white);
-webkit-text-stroke: 0;
-webkit-background-clip: text;
}

.sale.sale-on {
.hidden-sale-label {
background: linear-gradient(90deg, #ffffff 30%, #ff7ac3 100%);
background-clip: text;
}
}
3 changes: 1 addition & 2 deletions components/base/types.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import type { Prefix } from '@kodadot1/static'
import type { ItemResources } from '@/composables/useNft'

export type BaseMintedCollection = {
id: string
Expand All @@ -18,7 +17,7 @@ export type BaseTokenType<T = BaseMintedCollection> = {
secondFile: File | null
}

export interface CarouselNFT extends ItemResources {
export interface CarouselNFT {
currentOwner: string
id: string
image: string
Expand Down
28 changes: 15 additions & 13 deletions components/bsx/Create/RoyaltyForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,21 @@
:max="99.99"
/>

<BasicSwitch
v-model="isMine"
label="mint.royalty.mine"
data-testid="royalty-form-switch"
/>
<AddressInput
v-show="!isMine"
v-model="vAddress"
label="mint.royalty.receiver"
data-testid="royalty-form-custom-address"
:strict="false"
empty-on-error
/>
<template v-if="Number(vRoyalty)">
<BasicSwitch
v-model="isMine"
:label="isMine ? 'mint.royalty.mine' : 'mint.royalty.custom'"
data-testid="royalty-form-switch"
/>
<AddressInput
v-show="!isMine"
v-model="vAddress"
label="mint.royalty.receiver"
data-testid="royalty-form-custom-address"
:strict="false"
empty-on-error
/>
</template>
</div>
</template>

Expand Down
1 change: 1 addition & 0 deletions components/buy/Buy.vue
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ const { $i18n } = useNuxtApp()
const { isTransactionSuccessful } = useTransactionSuccessful({
status,
isError,
isLoading,
})

const nftSubscription = reactive<{
Expand Down
16 changes: 0 additions & 16 deletions components/carousel/module/CarouselMedia.vue
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,6 @@
:class="{ 'carousel-media-collection': isCollection }"
>
<div :aria-label="`slide ${index + 1} of ${length}`">
<img
v-if="showCardIcon"
class="absolute z-[1] right-4 top-4"
:src="cardIcon"
alt="Card Icon"
>
<BaseMediaItem
class="carousel-media-wrapper"
:src="imageSrc || ''"
Expand Down Expand Up @@ -39,15 +33,5 @@ const NuxtImg = resolveComponent('NuxtImg')

const isCollection = inject('isCollection', false)

const { urlPrefix } = usePrefix()
const imageSrc = ref(props.item.image)
const { showCardIcon, cardIcon } = useNftCardIcon(computed(() => props.item))

watch(
() => props.item.image,
async () => {
const nft = await getNftMetadata(props.item, urlPrefix.value)
imageSrc.value = nft.image
},
)
</script>
32 changes: 32 additions & 0 deletions components/collection/CollectionHeader.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<template>
<div>
<CollectionBanner
:collection-id="collectionId"
:collection="collection"
/>
<section class="pt-5">
<div class="container is-fluid">
<CollectionInfo
:collection-id="collectionId"
:collection="collection"
/>
<hr class="!bg-k-grey mb-0">
</div>
</section>
</div>
</template>

<script lang="ts" setup>
import { useCollectionMinimal } from '@/components/collection/utils/useCollectionDetails'
import CollectionInfo from '@/components/collection/CollectionInfo.vue'
import CollectionBanner from '@/components/collection/CollectionHeader/CollectionBanner.vue'

const route = useRoute()
const collectionId = computed(() => route.params.id.toString())

const { collection, refetch } = useCollectionMinimal({
collectionId,
})

watch(collectionId, () => refetch())
</script>
30 changes: 12 additions & 18 deletions components/collection/CollectionHeader/CollectionBanner.vue
Original file line number Diff line number Diff line change
Expand Up @@ -44,21 +44,15 @@ import { sanitizeIpfsUrl, toOriginalContentUrl } from '@/utils/ipfs'
import HeroButtons from '@/components/collection/HeroButtons.vue'
import { generateCollectionImage } from '@/utils/seoImageGenerator'
import { convertMarkdownToText } from '@/utils/markdown'
import collectionById from '@/queries/subsquid/general/collectionById.query'

const NuxtImg = resolveComponent('NuxtImg')

const collectionId = computed(() => route.params.id as string)
const props = defineProps<{
collectionId: string
collection?: unknown
}>()

const route = useRoute()
const { client } = usePrefix()

const { data, refresh: refetch } = useAsyncQuery({
query: collectionById,
variables: {
id: collectionId.value,
},
clientId: client.value,
})

const collectionAvatar = ref('')
const collectionName = ref('--')
Expand All @@ -67,13 +61,13 @@ const bannerImageUrl = computed(
() => collectionAvatar.value && toOriginalContentUrl(collectionAvatar.value),
)

watch(collectionId, () => {
refetch()
watch(() => props.collectionId, () => {
collectionAvatar.value = ''
collectionName.value = '--'
})

watchEffect(async () => {
const collection = data.value?.collectionEntity
const collection = props.collection
const metadata = collection?.metadata
const image = collection?.meta?.image
const name = collection?.name
Expand Down Expand Up @@ -102,21 +96,21 @@ watchEffect(async () => {
useSeoMeta({
title: collectionName,
description: () =>
convertMarkdownToText(data.value?.collectionEntity?.meta?.description),
convertMarkdownToText(props.collection?.meta?.description),
ogUrl: route.path,
ogTitle: collectionName,
ogDescription: () =>
convertMarkdownToText(data.value?.collectionEntity?.meta?.description),
convertMarkdownToText(props.collection?.meta?.description),
ogImage: () =>
generateCollectionImage(
collectionName.value,
data.value?.nftEntitiesConnection?.totalCount,
props.collection?.nftCount,
collectionAvatar.value,
),
twitterImage: () =>
generateCollectionImage(
collectionName.value,
data.value?.nftEntitiesConnection?.totalCount,
props.collection?.nftCount,
collectionAvatar.value,
),
})
Expand Down
29 changes: 14 additions & 15 deletions components/collection/CollectionInfo.vue
Original file line number Diff line number Diff line change
Expand Up @@ -121,29 +121,31 @@

<script setup lang="ts">
import { NeoButton, NeoIcon } from '@kodadot1/brick'
import {
useCollectionDetails,
useCollectionMinimal,
} from './utils/useCollectionDetails'
import { useCollectionDetails } from './utils/useCollectionDetails'
import {
DESCRIPTION_MAX_LENGTH,
generatePreviewDescription,
} from '@/components/collection/utils/description'

const props = defineProps<{
collectionId: string
collection?: unknown
}>()

const body = ref(document.body)
const route = useRoute()
const { urlPrefix } = usePrefix()
const { availableChains } = useChain()
const collectionId = computed(() => route.params.id.toString())

const chain = computed(
() =>
availableChains.value.find(chain => chain.value === route.params.prefix)
?.text,
)
const address = computed(() => collectionInfo.value?.displayCreator)
const recipient = computed(() => collectionInfo.value?.recipient)
const royalty = computed(() => collectionInfo.value?.royalty)
const createdAt = computed(() => collectionInfo.value?.createdAt)
const address = computed(() => props.collection?.displayCreator)
const recipient = computed(() => props.collection?.recipient)
const royalty = computed(() => props.collection?.royalty)
const createdAt = computed(() => props.collection?.createdAt)
const seeAllDescription = ref(false)

const toggleSeeAllDescription = () => {
Expand All @@ -152,13 +154,13 @@ const toggleSeeAllDescription = () => {

const hasSeeAllDescriptionOption = computed(() => {
return (
(collectionInfo.value?.meta?.description?.length || 0)
(props.collection?.meta?.description?.length || 0)
> DESCRIPTION_MAX_LENGTH
)
})

const visibleDescription = computed(() => {
const desc = collectionInfo.value?.meta?.description
const desc = props.collection?.meta?.description

return (
(!hasSeeAllDescriptionOption.value || seeAllDescription.value
Expand All @@ -167,10 +169,7 @@ const visibleDescription = computed(() => {
)
})

const { collection: collectionInfo } = useCollectionMinimal({
collectionId,
})
const { stats } = useCollectionDetails({
collectionId,
collectionId: computed(() => props.collectionId),
})
</script>
16 changes: 5 additions & 11 deletions components/collection/CollectionRelatedDropNotification.vue
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
</div>
</div>
<div
v-else
v-else-if="drop"
class="flex w-full justify-center mt-4"
>
<NeoButton
Expand All @@ -45,7 +45,6 @@
<script lang="ts" setup>
import { NeoButton } from '@kodadot1/brick'
import { getDropAttributes } from '../drops/utils'
import { getDrops } from '@/services/fxart'
import type { DropItem } from '@/params/types'

const NuxtLink = resolveComponent('NuxtLink')
Expand All @@ -54,18 +53,13 @@ const props = defineProps<{
collectionId: string
}>()

const { urlPrefix } = usePrefix()
const { drop: dropItem, isPending } = useCollectionDrop(computed(() => props.collectionId))

const drop = ref<DropItem>()

onBeforeMount(async () => {
const fetchDrops = await getDrops({
chain: [urlPrefix.value],
collection: props.collectionId,
})

if (fetchDrops.length) {
drop.value = await getDropAttributes(fetchDrops[0].alias)
watchEffect(async () => {
if (Boolean(dropItem.value) && !isPending.value) {
drop.value = await getDropAttributes(dropItem.value?.alias as string)
}
})
</script>
18 changes: 13 additions & 5 deletions components/collection/activity/Activity.vue
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
<div class="w-2/3 pr-2">
<ActivityChart
:events="events"
class="mt-2"
:loading="loading"
:class="{ 'mt-2': !loading }"
/>
</div>
<div class="flex-1">
Expand All @@ -29,15 +30,21 @@
:flippers="flippers"
/>
<div class="max-width">
<ActivityChart :events="events" />
<ActivityChart
:events="events"
:loading="loading"
/>
</div>
</div>
</div>
<hr
class="mb-7"
:class="{ 'my-7': !isBreadCrumbsShowing }"
>
<Events :events="sortedEventsWithOffersDesc" />
<Events
:events="sortedEventsWithOffersDesc"
:loading="loading"
/>
</div>
</div>
</template>
Expand All @@ -63,8 +70,9 @@ const isBreadCrumbsShowing = computed(
() => isAnyActivityFilterActive() && tablet.value,
)
const collectionId = computed(() => route.params.id)
const { events, flippers, owners, offers } = useCollectionActivity({
const collectionId = computed(() => route.params.id.toString())
const { events, flippers, owners, offers, loading } = useCollectionActivity({
collectionId,
})
Expand Down
Loading
Loading