|
1 | 1 | <template> |
2 | | - <div class="wrapper section no-padding-desktop"> |
| 2 | + <div class="wrapper section no-padding-desktop gallery-item"> |
3 | 3 | <div class="container"> |
4 | 4 | <div class="columns"> |
5 | 5 | <div class="image-wrapper"> |
|
11 | 11 | :src="nft.image || require('@/assets/kodadot_logo_v1_transparent_400px.png')" |
12 | 12 | :src-fallback="require('@/assets/kodadot_logo_v1_transparent_400px.png')" |
13 | 13 | alt="KodaDot NFT minted multimedia" |
| 14 | + ratio="1by1" |
14 | 15 | ></b-image> |
15 | 16 | <img class="fullscreen-image" :src="nft.image || require('@/assets/kodadot_logo_v1_transparent_400px.png')" alt="KodaDot NFT minted multimedia"> |
16 | 17 | <b-skeleton height="524px" size="is-large" :active="isLoading"></b-skeleton> |
|
28 | 29 | <div class="columns"> |
29 | 30 | <div class="column is-6"> |
30 | 31 | <Appreciation :accountId="accountId" :currentOwnerId="nft.currentOwner" :nftId="nft.id" /> |
31 | | - |
| 32 | + |
32 | 33 | <div class="nft-title"> |
33 | 34 | <Name :nft="nft" :isLoading="isLoading" /> |
34 | 35 | </div> |
35 | 36 |
|
36 | 37 | <p class="label"> |
37 | 38 | {{ $t('legend')}} |
38 | 39 | </p> |
39 | | - |
| 40 | + |
40 | 41 | <div class="subtitle is-size-7"> |
41 | 42 | <p v-if="!isLoading" |
42 | 43 | class="subtitle is-size-5"> |
|
45 | 46 | </p> |
46 | 47 | <b-skeleton :count="3" size="is-large" :active="isLoading"></b-skeleton> |
47 | 48 | </div> |
48 | | - |
| 49 | + |
49 | 50 | <template v-if="detailVisible"> |
50 | 51 | <Facts :nft="nft" /> |
51 | 52 | </template> |
52 | 53 | </div> |
53 | 54 | <div class="column is-3 is-offset-3" v-if="detailVisible"> |
54 | | - |
| 55 | + |
55 | 56 | <b-skeleton :count="2" size="is-large" :active="isLoading"></b-skeleton> |
56 | 57 | <div class="price-block" v-if="hasPrice"> |
57 | 58 | <div class="price-block__original">{{ this.nft.price | formatBalance(12, 'KSM') }}</div> |
@@ -250,118 +251,162 @@ export default class GalleryItem extends Vue { |
250 | 251 | } |
251 | 252 | </script> |
252 | 253 |
|
253 | | -<style scoped lang="scss"> |
| 254 | +<style lang="scss"> |
254 | 255 | @import "@/colors"; |
255 | 256 | @import "@/typography"; |
256 | 257 |
|
257 | | -.nft-title { |
258 | | - margin-bottom: 24px; |
259 | | -} |
260 | | -
|
261 | | -.gallery-item__skeleton { |
262 | | - width: 95%; |
263 | | - margin: auto; |
264 | | -} |
265 | | -
|
266 | | -.withPicture { |
267 | | - margin: 0.75em 0; |
268 | | -} |
269 | | -
|
270 | | -.image-wrapper { |
271 | | - position: relative; |
272 | | - margin: 30px auto; |
273 | | - width: 100%; |
| 258 | +.gallery-item { |
| 259 | + .nft-title { |
| 260 | + margin-bottom: 24px; |
| 261 | + } |
274 | 262 |
|
275 | | - .image { |
276 | | - border: 2px solid $primary; |
| 263 | + .gallery-item__skeleton { |
| 264 | + width: 95%; |
| 265 | + margin: auto; |
277 | 266 | } |
278 | 267 |
|
279 | | - .fullscreen-image { |
280 | | - display: none; |
| 268 | + .withPicture { |
| 269 | + margin: 0.75em 0; |
281 | 270 | } |
282 | 271 |
|
283 | | - .image-preview { |
284 | | - &.fullscreen { |
285 | | - position: fixed; |
286 | | - width: 100%; |
287 | | - height: 100%; |
288 | | - top: 0; |
289 | | - left: 0; |
290 | | - z-index: 999998; |
291 | | - background: #000; |
| 272 | + .image-wrapper { |
| 273 | + position: relative; |
| 274 | + margin: 30px auto; |
| 275 | + width: 100%; |
292 | 276 |
|
293 | | - img.fullscreen-image { |
294 | | - display: block; |
295 | | - width: auto !important; |
296 | | - height: 100% !important; |
297 | | - position: absolute; |
| 277 | + .image { |
| 278 | + border: 2px solid $primary; |
| 279 | + } |
| 280 | +
|
| 281 | + .fullscreen-image { |
| 282 | + display: none; |
| 283 | + } |
| 284 | +
|
| 285 | + .image-preview { |
| 286 | + &.fullscreen { |
| 287 | + position: fixed; |
| 288 | + width: 100%; |
| 289 | + height: 100%; |
298 | 290 | top: 0; |
299 | | - left: 50%; |
300 | | - transform: translate(-50%, 0); |
| 291 | + left: 0; |
| 292 | + z-index: 999998; |
| 293 | + background: #000; |
| 294 | +
|
| 295 | + img.fullscreen-image { |
| 296 | + display: block; |
| 297 | + width: auto !important; |
| 298 | + height: 100% !important; |
| 299 | + position: absolute; |
| 300 | + top: 0; |
| 301 | + left: 50%; |
| 302 | + transform: translate(-50%, 0); |
| 303 | + } |
| 304 | +
|
| 305 | + .image { |
| 306 | + visibility: hidden; |
| 307 | + } |
301 | 308 | } |
| 309 | + } |
| 310 | +
|
| 311 | + .column { |
| 312 | + transition: .3s all; |
| 313 | + } |
302 | 314 |
|
303 | | - .image { |
304 | | - visibility: hidden; |
| 315 | + button { |
| 316 | + border: 2px solid $primary; |
| 317 | + color: $primary; |
| 318 | + font-weight: bold; |
| 319 | + text-transform: uppercase; |
| 320 | + padding: 7px 16px; |
| 321 | + font-size: 20px; |
| 322 | + background: #fafafa; |
| 323 | + z-index: 2; |
| 324 | +
|
| 325 | + &:hover { |
| 326 | + color: #fff; |
| 327 | + background: $primary; |
| 328 | + cursor: pointer; |
305 | 329 | } |
306 | 330 | } |
307 | 331 | } |
308 | 332 |
|
309 | | - .column { |
310 | | - transition: .3s all; |
| 333 | + button#theatre-view { |
| 334 | + position: absolute; |
| 335 | + top: 13px; |
| 336 | + left: 13px; |
311 | 337 | } |
312 | 338 |
|
313 | | - button { |
| 339 | + button#fullscreen-view { |
| 340 | + position: absolute; |
| 341 | + bottom: 13px; |
| 342 | + right: 13px; |
| 343 | +
|
| 344 | + &.fullscreen { |
| 345 | + position: fixed; |
| 346 | + z-index: 999998; |
| 347 | + bottom:0; |
| 348 | + right: 0; |
| 349 | + } |
| 350 | + } |
| 351 | +
|
| 352 | + .price-block { |
314 | 353 | border: 2px solid $primary; |
315 | | - color: $primary; |
316 | | - font-weight: bold; |
317 | | - text-transform: uppercase; |
318 | | - padding: 7px 16px; |
319 | | - font-size: 20px; |
320 | | - background: #fafafa; |
321 | | - z-index: 2; |
322 | | -
|
323 | | - &:hover { |
324 | | - color: #fff; |
325 | | - background: $primary; |
326 | | - cursor: pointer; |
| 354 | + border-width: 2px 2px 0; |
| 355 | + padding: 14px; |
| 356 | +
|
| 357 | + &__original { |
| 358 | + color: $dark; |
| 359 | + font-size: 24px; |
| 360 | + text-transform: uppercase; |
| 361 | + font-weight: 500; |
| 362 | + } |
| 363 | +
|
| 364 | + &__exchange { |
| 365 | + opacity: .6; |
| 366 | + color: $dark; |
| 367 | + margin: 0; |
327 | 368 | } |
328 | 369 | } |
329 | | -} |
330 | 370 |
|
331 | | -button#theatre-view { |
332 | | - position: absolute; |
333 | | - top: 13px; |
334 | | - left: 13px; |
335 | | -} |
| 371 | + .card { |
| 372 | + border-radius: 0 !important; |
| 373 | + box-shadow: none; |
| 374 | + border: 2px solid $primary; |
336 | 375 |
|
337 | | -button#fullscreen-view { |
338 | | - position: absolute; |
339 | | - bottom: 13px; |
340 | | - right: 13px; |
| 376 | + &-header { |
| 377 | + border-radius: 0; |
| 378 | + position: relative; |
341 | 379 |
|
342 | | - &.fullscreen { |
343 | | - position: fixed; |
344 | | - z-index: 999998; |
345 | | - bottom:0; |
346 | | - right: 0; |
347 | | - } |
348 | | -} |
| 380 | + &:before { |
| 381 | + content: ''; |
| 382 | + width: 100%; |
| 383 | + height: 2px; |
| 384 | + position: absolute; |
| 385 | + bottom: -2px; |
| 386 | + left: 0; |
| 387 | + width: 100%; |
| 388 | + background: $primary; |
| 389 | + } |
349 | 390 |
|
350 | | -.price-block { |
351 | | - border: 2px solid $primary; |
352 | | - padding: 14px; |
| 391 | + &-title { |
| 392 | + color: $primary; |
| 393 | + } |
| 394 | + } |
| 395 | +
|
| 396 | + &-footer { |
| 397 | + border-radius: none; |
| 398 | + border-top: none; |
353 | 399 |
|
354 | | - &__original { |
355 | | - color: $dark; |
356 | | - font-size: 24px; |
357 | | - text-transform: uppercase; |
358 | | - font-weight: 500; |
| 400 | + &-item:not(:last-child){ |
| 401 | + border-right-color: $primary; |
| 402 | + } |
| 403 | + } |
359 | 404 | } |
360 | 405 |
|
361 | | - &__exchange { |
362 | | - opacity: .6; |
363 | | - color: $dark; |
364 | | - margin: 0; |
| 406 | + &.no-padding-desktop { |
| 407 | + @media screen and (min-width: 1023px) { |
| 408 | + padding: 0; |
| 409 | + } |
365 | 410 | } |
366 | 411 | } |
367 | 412 | </style> |
0 commit comments