Skip to content
This repository was archived by the owner on Dec 5, 2025. It is now read-only.

Commit ccf7388

Browse files
committed
🖼 resolve conflict
2 parents 531da85 + 264b69e commit ccf7388

File tree

14 files changed

+207
-522
lines changed

14 files changed

+207
-522
lines changed

‎components/rmrk/Create/CreateToken.vue‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -531,8 +531,7 @@ export default class CreateToken extends mixins(
531531
showNotification('You will go to the detail in 2 seconds')
532532
const go = () =>
533533
this.$router.push({
534-
name: 'nftDetail',
535-
params: { id: getNftId(nft, blockNumber) },
534+
path: `/rmrk/gallery/${getNftId(nft, blockNumber)}`,
536535
query: { message: 'congrats' }
537536
})
538537
setTimeout(go, 2000)

‎components/rmrk/Create/SimpleMint.vue‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -788,7 +788,7 @@ export default class SimpleMint extends mixins(
788788
showNotification('You will go to the detail in 2 seconds')
789789
const go = () =>
790790
this.$router.push({
791-
path: `/rmrk/detail/${getNftId(nft, blockNumber)}`,
791+
path: `/rmrk/gallery/${getNftId(nft, blockNumber)}`,
792792
query: { message: 'congrats' },
793793
})
794794
setTimeout(go, 2000)

‎components/rmrk/Gallery/CollectionItem.vue‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,19 +118,20 @@ const components = {
118118
}
119119
@Component<CollectionItem>({
120120
metaInfo() {
121+
const image = `https://og-image-green-seven.vercel.app/${encodeURIComponent(this.collection.name as string)}.png?price=Items: ${this.collection?.nfts?.length}&image=${(this.meta.image as string)}`
121122
return {
122123
title: 'KodaDot cares about environmental impact',
123124
titleTemplate: '%s | Low Carbon NFTs',
124125
meta: [
125126
{ name: 'description', content: 'Creating Carbonless NFTs on Kusama' },
126127
{ property: 'og:title', content: this.collection.name || 'KodaDot cares about environmental impact'},
127128
{ property: 'og:url', content: 'https://nft.kodadot.xyz/' + this.$route.path },
128-
{ property: 'og:image', content: this.meta.image || 'https://nft.kodadot.xyz/kodadot_carbonless.jpg'},
129+
{ property: 'og:image', content: image},
129130
{ property: 'og:description', content: this.meta.description || 'Creating Carbonless NFTs on Kusama'},
130131
{ property: 'twitter:card', content: 'summary_large_image' },
131132
{ property: 'twitter:title', content: this.collection.name || 'KodaDOT cares about environmental impact'},
132133
{ property: 'twitter:description', content: this.meta.description || 'Creating Carbonless NFTs on Kusama'},
133-
{ property: 'twitter:image', content: this.meta.image || 'https://nft.kodadot.xyz/kodadot_carbonless.jpg'},
134+
{ property: 'twitter:image', content: image},
134135
]
135136
}
136137
},

‎components/rmrk/Gallery/GalleryCard.vue‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55
>
66
<LinkResolver
77
class="nft-card__skeleton"
8-
:route="type"
9-
:param="id"
8+
:route="route"
109
:link="link"
10+
:param="id"
1111
tag="a"
1212
>
1313
<div
@@ -95,8 +95,8 @@ const components = {
9595
9696
@Component({ components })
9797
export default class GalleryCard extends Vue {
98-
@Prop({ default: '/rmrk/detail' }) public type!: string;
99-
@Prop({ default: 'rmrk/detail' }) public link!: string;
98+
@Prop({ default: '/rmrk/gallery' }) public route!: string;
99+
@Prop({ default: 'rmrk/gallery' }) public link!: string;
100100
@Prop() public id!: string;
101101
@Prop() public name!: string;
102102
protected image = '';

‎components/rmrk/Gallery/GalleryCardList.vue‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
<GalleryCard
1313
:id="nft.id"
1414
:name="nft.name"
15-
:type="type"
15+
:route="route"
1616
:link="link"
1717
:metadata="nft.metadata"
1818
:price="nft.price"
@@ -35,8 +35,8 @@ const components = {
3535
3636
@Component({ components })
3737
export default class GalleryCardList extends Vue {
38-
@Prop({ default: 'nftDetail' }) public type!: string;
39-
@Prop({ default: 'rmrk/detail' }) public link!: string;
38+
@Prop({ default: '/rmrk/gallery' }) public route!: string;
39+
@Prop({ default: 'rmrk/gallery' }) public link!: string;
4040
@Prop() public items!: RmrkType[];
4141
@Prop({ default: false }) public horizontalLayout!: boolean;
4242
get classLayout() {

‎components/rmrk/Gallery/GalleryItem.vue‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ import Orientation from '@/directives/DeviceOrientation'
138138
139139
@Component<GalleryItem>({
140140
metaInfo() {
141-
const image = `https://og-image-green-seven.vercel.app/${encodeURIComponent(this.nft.name as string)}.png?price=${Number(this.nft.price) ? Vue.filter('formatBalance')(this.nft.price, 12, 'KSM') : ''}&image=${(this.meta.image as string)}`
141+
const image = `https://og-image-green-seven.vercel.app/${encodeURIComponent(this.nft.name as string)}.png?price=${Number(this.nft.price) ? Vue.filter('formatBalance')(this.nft.price, 12, 'KSM') : ''}&image=${(this.meta.image as string)}&mime=${this.mimeType}`
142142
return {
143143
title: this.nft.name,
144144
titleTemplate: '%s | Low Carbon NFTs',

‎components/shared/AddressInput.vue‎

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
<script lang="ts">
1717
import correctFormat from '@/utils/ss58Format'
18-
import { checkAddress } from '@polkadot/util-crypto'
18+
import { checkAddress, isAddress } from '@polkadot/util-crypto'
1919
import { Debounce } from 'vue-debounce-decorator'
2020
import { Component, Emit, Prop, Vue } from 'nuxt-property-decorator'
2121
@@ -25,6 +25,7 @@ export default class AddressInput extends Vue {
2525
private err: string | null = '';
2626
@Prop({ type: String, default: 'insert address' }) public label!: string;
2727
@Prop(Boolean) public emptyOnError!: boolean;
28+
@Prop({ type: Boolean, default: true }) public strict!: boolean;
2829
2930
get inputValue(): string {
3031
return this.value
@@ -34,15 +35,19 @@ export default class AddressInput extends Vue {
3435
this.handleInput(value)
3536
}
3637
37-
get type() {
38+
get type(): string {
3839
return this.err ? 'is-danger': ''
3940
}
4041
4142
@Debounce(500)
4243
@Emit('input')
4344
protected handleInput(value: string) {
44-
const [, err] = checkAddress(value, correctFormat(this.ss58Format))
45-
this.err = value ? err : ''
45+
if (this.strict) {
46+
const [, err] = checkAddress(value, correctFormat(this.ss58Format))
47+
this.err = value ? err : ''
48+
} else {
49+
this.err = isAddress(value) ? '' : 'Invalid address'
50+
}
4651
4752
return this.emptyOnError && this.err ? '' : value
4853
}
Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,17 @@
11
<template>
2-
<b-field
3-
:label="label"
4-
:expanded="expanded"
5-
>
6-
<b-input
7-
:value="value"
8-
disabled
9-
/>
2+
<b-field :label="label" :expanded="expanded">
3+
<b-input :value="value" :readonly="readonly" disabled ></b-input>
104
</b-field>
115
</template>
126
<script lang="ts">
137
import { Component, Prop, Vue } from 'nuxt-property-decorator'
148
159
@Component({})
1610
export default class DisabledInput extends Vue {
17-
@Prop() public label!: any;
18-
@Prop() public value!: any;
19-
@Prop({default: false}) public expanded!: boolean;
11+
@Prop({ type: String, required: true }) public label!: string;
12+
@Prop({ type: String, required: true }) public value!: string;
13+
@Prop({ type: Boolean, default: false}) public expanded!: boolean;
14+
@Prop({ type: Boolean, default: false}) public readonly!: boolean;
15+
2016
}
2117
</script>

‎components/shared/LinkResolver.vue‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ import isShareMode from '@/utils/isShareMode'
2828
2929
@Component
3030
export default class LinkResolver extends mixins(InlineMixin) {
31-
@Prop({ default: '/rmrk/detail' }) public route!: string;
32-
@Prop({ default: 'rmrk/detail' }) public link!: string;
31+
@Prop({ default: '/rmrk/gallery' }) public route!: string;
32+
@Prop({ default: 'rmrk/gallery' }) public link!: string;
3333
@Prop({ default: 'a' }) public tag!: string;
3434
@Prop({}) public param!: string;
3535

‎docker-compose.yml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,4 @@ services:
1414
- HOST=0.0.0.0
1515
- CHOKIDAR_USEPOLLING=true
1616
ports:
17-
- 3000:3000
17+
- 9000:9000

0 commit comments

Comments
 (0)