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: Link card to profile #361

Open
wants to merge 29 commits into
base: main
Choose a base branch
from
Open

feat: Link card to profile #361

wants to merge 29 commits into from

Conversation

PanicS7
Copy link

@PanicS7 PanicS7 commented Mar 29, 2023

This feature will allow user to link nfc card to his profile

How to test:

  1. Navigate to URL https://deploy-preview-361--wedance-panics7.netlify.app/nfc/[ID] where [ID] is one from the list a ,b, c, d, e for example https://deploy-preview-361--wedance-panics7.netlify.app/nfc/a
  2. If URL is not linked to username you will see landing page
  3. Click at "Link your profile" button to link your profile to this URL
  4. Sign in to your profile
  5. It will redirect you to your profile page and your should see pop up modal for try premium animating

Closes #349

@netlify
Copy link

netlify bot commented Mar 29, 2023

Deploy Preview for wedance-panics7 ready!

Name Link
🔨 Latest commit d30ab62
🔍 Latest deploy log https://app.netlify.com/sites/wedance-panics7/deploys/6424aab27c844100080fbfe7
😎 Deploy Preview https://deploy-preview-361--wedance-panics7.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.

Copy link
Contributor

Choose a reason for hiding this comment

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

This should be svg

Copy link
Author

Choose a reason for hiding this comment

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

It is changed now

name="instagram"
size="10"
class="rounded-full p-2"
style="box-shadow: 0px 1px 3px rgba(0, 0, 0, 0.1), 0px 1px 2px rgba(0, 0, 0, 0.06);"
Copy link
Contributor

Choose a reason for hiding this comment

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

use tailwind shadows

Copy link
Author

Choose a reason for hiding this comment

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

I changed it to use "shadow" tailwind class

const { softUpdate } = useDoc('nfc-card')
let username = ''

let pageId = $nuxt.$route.params.landing
Copy link
Contributor

Choose a reason for hiding this comment

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

landing is confusing name for param, rename it to id

Suggested change
let pageId = $nuxt.$route.params.landing
let pageId = $nuxt.$route.params.id

Copy link
Author

Choose a reason for hiding this comment

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

It is "id" now


let pageId = $nuxt.$route.params.landing
// when page is loaded after signIn
if (pageId === undefined) {
Copy link
Contributor

Choose a reason for hiding this comment

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

shorter:

Suggested change
if (pageId === undefined) {
if (!pageId) {

Copy link
Author

Choose a reason for hiding this comment

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

To fix error "nuxt is not defined" I changed my implementation, so this code is outdated

Copy link
Contributor

Choose a reason for hiding this comment

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

that page is not needed

Copy link
Author

Choose a reason for hiding this comment

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

Page is removed now

Comment on lines 25 to 27
default() {
return []
},
Copy link
Contributor

Choose a reason for hiding this comment

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

shorter:

Suggested change
default() {
return []
},
default: () => [],

Copy link
Author

Choose a reason for hiding this comment

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

I changed code, so it is shorter now


<TBenefits
title="Why get Premium?"
icon="check-green"
Copy link
Contributor

Choose a reason for hiding this comment

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

if it is already set by default, no need to overwrite it

Copy link
Author

Choose a reason for hiding this comment

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

You are right, I had changed code

},
mounted() {
// show tryPremium modal
const query = $nuxt.$route.query
Copy link
Contributor

Choose a reason for hiding this comment

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

solution for: error '$nuxt' is not defined

Suggested change
const query = $nuxt.$route.query
const query = this.$route.query

Copy link
Author

Choose a reason for hiding this comment

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

I had error in diferent file, so this does not fix anything, but I added this implementation

error '$nuxt' is not defined and warning  unexpected usage of 'this'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Link card to profile
2 participants