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

Five min is not five min #6173

Merged
merged 8 commits into from
Jun 6, 2023
Merged

Five min is not five min #6173

merged 8 commits into from
Jun 6, 2023

Conversation

vikiival
Copy link
Member

@vikiival vikiival commented Jun 6, 2023

Thank you for your contribution to the KodaDot - One Stop Shop for Polkadot NFTs.

👇 __ Let's make a quick check before the contribution.

PR Type

  • Bugfix
  • Feature
  • Refactoring

Needs Design check

Context

  • Closes #<issue_number>
  • Requires deployment <snek/rubick/worker>

Did your issue had any of the "$" label on it?

Screenshot 📸

  • My fix has changed UI

Copilot Summary

🤖 Generated by Copilot at 8630971

The pull request adds a dynamic minting window feature for NFT collections, which allows users to mint NFTs only within the current hour. It also refactors the date logic and simplifies the code structure by using date-fns functions and moving countDownTime to const.ts.

🤖 Generated by Copilot at 8630971

To mint NFTs in a hurry
The code had to change and not worry
It used date-fns
To set the minting ends
And moved countDownTime in a flurry

@vikiival vikiival requested a review from a team as a code owner June 6, 2023 11:56
@vikiival vikiival requested review from preschian and roiLeo and removed request for a team June 6, 2023 11:56
@netlify
Copy link

netlify bot commented Jun 6, 2023

Deploy Preview for koda-canary ready!

Name Link
🔨 Latest commit e7fd5ce
🔍 Latest deploy log https://app.netlify.com/sites/koda-canary/deploys/647f2d04e322760007759f91
😎 Deploy Preview https://deploy-preview-6173--koda-canary.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@reviewpad reviewpad bot added small Pull request is small waiting-for-review labels Jun 6, 2023
@reviewpad
Copy link
Contributor

reviewpad bot commented Jun 6, 2023

Reviewpad Report

⚠️ Warnings

  • Please link an issue to the pull request

@reviewpad
Copy link
Contributor

reviewpad bot commented Jun 6, 2023

AI-Generated Summary: This pull request modifies the UnlockableContainer.vue and const.ts files. It primarily replaces hardcoded date-time values used for mintStartTime and countDownTime with dynamic values derived from the current date using the date-fns library's endOfHour and startOfHour functions. The windowRange now starts and ends within the current hour, and the countdown timer is set to the end of the current hour.

@@ -159,6 +159,7 @@ import { OSlider } from '@oruga-ui/oruga'
import { timeAgo } from '@/components/collection/utils/timeAgo'
import { collectionId, countDownTime } from './const'
import { UNLOCKABLE_CAMPAIGN, createUnlockableMetadata } from './utils'
import { endOfHour, startOfHour } from 'date-fns'
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Quick hack sir + we already use date-fns a lot

@codeclimate
Copy link

codeclimate bot commented Jun 6, 2023

Code Climate has analyzed commit e7fd5ce and detected 0 issues on this pull request.

View more on Code Climate.

@vikiival vikiival merged commit 70ddeef into main Jun 6, 2023
@vikiival vikiival deleted the 15-min-mint branch June 6, 2023 14:27
This was referenced Jun 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
small Pull request is small waiting-for-review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants