-
Notifications
You must be signed in to change notification settings - Fork 1
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
309 unlock new routes v1 shopify connect and unlock #310
309 unlock new routes v1 shopify connect and unlock #310
Conversation
… data ⬆️ Migrate NX migrations to newer versions for improved project configuration management ⬆️ (package.json): upgrade various dependencies including Next.js, React, and NX to their latest versions for improved features and bug fixes
…hitecture ✨ Add useConnectWallet hook with tests to manage wallet connections effectively ✨ (useConnectWallet.tsx): add new hook for wallet connection in Shopify feature ♻️ (useShopifyCustomer.spec.tsx, useShopifyCustomer.tsx): refactor hooks to remove unnecessary organizerId parameter, simplifying the API and usage
…ation 🚀 (shopify): enable dynamic import for RootLayout to improve loading times 🔧 (middleware.ts): update middleware config to exclude 'shopify' from paths ♻️ (shopify): refactor useShopifyCustomer hook to support generic type for additionalData ✅ (useShopifyCustomer.spec.tsx): add tests for additionalData handling in useShopifyCustomer hook 📝 (Connect.stories.tsx): add storybook entries for V1Connect component with various states ✨ (examples.tsx, Connected.tsx): add new example and connected components for Shopify feature ✨ (context.tsx, hooks.ts): enhance iframe context and hooks with generic type support and additional data handling ✨ (context.tsx): add handling for additional data in iframe provider and context
…onnect component with new user stories and localization support - **Connect.stories.tsx**: Added new user stories to simulate different customer statuses and interactions. - **Connect.tsx**: Integrated localization and dynamic button actions based on customer status to improve UX. - **examples.tsx**: Extended mock data to support new stories and added `additionalData` for dynamic text based on customer status.
…t-side operation handling ♻️ (index.spec.ts, index.ts): change error handling to return null instead of throwing error for already minted loyalty cards to simplify flow and prevent crashes ✅ (index.spec.ts): update tests to reflect new behavior of returning null for minted loyalty cards
…ructure ♻️ Refactor deleteContentSpaceFile to return revalidateTagKey for better testability ♻️ Refactor deleteContentSpaceFiles to return revalidateTagKey for consistency and testability ♻️ Refactor deleteEventPassFile to return revalidateTagKey, aligning with new testing strategy ♻️ Refactor deleteEventPassFiles to return revalidateTagKey, improving code consistency and testability ✅ Update tests to expect return values from delete actions, enhancing test coverage and reliability ✨ (useConnectWallet.spec.tsx, useConnectWallet.tsx): add integration with iframe for dapp connection ✅ (useConnectWallet.spec.tsx): update tests to cover new functionality and error handling ♻️ (useConnectWallet.tsx): refactor to use useEffect for automatic dapp connection on wallet and customer id availability 💡 (useConnectWallet.tsx): add comments to clarify mutation usage and effects ♻️ (Connect.stories.tsx, Connect.tsx, examples.tsx): refactor Shopify connect components to simplify and centralize UI logic ✨ (Connect.tsx): enhance button loading states and error handling for a smoother user experience 🔧 (examples.tsx): update mock data to align with new simplified connect logic 💡 (Connect.tsx): add detailed comments and clean up unused code to improve maintainability
The latest updates on your projects. Learn more about Vercel for Git ↗︎ |
PR Reviewer Guide 🔍
|
PR Code Suggestions ✨
|
…fy-connect-and-unlock 309 unlock new routes v1 shopify connect and unlock
PR Type
Enhancement, Tests, Dependencies
Description
RootLayout
component with multiple providers for Shopify integration.V1Connect
andV1Connected
components for Shopify features.useShopifyCustomer
hook to removeorganizerId
parameter and added support foradditionalData
.useConnectWallet
hook for managing wallet connections.revalidateTagKey
.Changes walkthrough 📝
20 files
layout.tsx
Add RootLayout Component with Multiple Providers
apps/unlock/app/shopify/layout.tsx
RootLayout
component for Shopify integration.IFrameProvider
,ReactQueryProviders
,WalletProvider
, andThemeProvider
.RootLayout
to improve loading times.page.tsx
Add V1 Shopify Connect Page Component
apps/unlock/app/shopify/v1/connect/page.tsx
deleteContentSpaceFile.ts
Modify deleteContentSpaceFile to Return revalidateTagKey
libs/features/back-office/content-spaces/src/lib/actions/deleteContentSpaceFile.ts
deleteContentSpaceFile
function to returnrevalidateTagKey
.deleteContentSpaceFiles.ts
Modify deleteContentSpaceFiles to Return revalidateTagKey
libs/features/back-office/content-spaces/src/lib/actions/deleteContentSpaceFiles.ts
deleteContentSpaceFiles
function to returnrevalidateTagKey
.deleteEventPassFile.ts
Modify deleteEventPassFile to Return revalidateTagKey
libs/features/back-office/events/src/lib/actions/deleteEventPassFile.ts
deleteEventPassFile
function to returnrevalidateTagKey
.deleteEventPassFiles.ts
Modify deleteEventPassFiles to Return revalidateTagKey
libs/features/back-office/events/src/lib/actions/deleteEventPassFiles.ts
deleteEventPassFiles
function to returnrevalidateTagKey
.index.ts
Export V1Connect from Shopify Feature Library
libs/features/unlock/shopify/src/index.ts
V1Connect
from the Shopify feature library.OffKeyAuth.tsx
Refactor OffKeyAuth to Use useConnectWallet Hook
libs/features/unlock/shopify/src/lib/OffKeyAuth/OffKeyAuth.tsx
useConnectWallet
hook.OffKeyGate.tsx
Simplify useShopifyCustomer Hook Usage in OffKeyGate
libs/features/unlock/shopify/src/lib/OffKeyGate/OffKeyGate.tsx
organizerId
parameter fromuseShopifyCustomer
hook.OffKeyGateNotConnected.tsx
Simplify useShopifyCustomer Hook Usage in OffKeyGateNotConnected
libs/features/unlock/shopify/src/lib/OffKeyGateNotConnected/OffKeyGateNotConnected.tsx
organizerId
parameter fromuseShopifyCustomer
hook.OffKeyHeaderConnected.tsx
Simplify useShopifyCustomer Hook Usage in OffKeyHeaderConnected
libs/features/unlock/shopify/src/lib/OffKeyHeaderConnected/OffKeyHeaderConnected.tsx
organizerId
parameter fromuseShopifyCustomer
hook.OffKeyHeaderNotConnected.tsx
Simplify useShopifyCustomer Hook Usage in OffKeyHeaderNotConnected
libs/features/unlock/shopify/src/lib/OffKeyHeaderNotConnected/OffKeyHeaderNotConnected.tsx
organizerId
parameter fromuseShopifyCustomer
hook.OffKeyProfile.tsx
Simplify useShopifyCustomer Hook Usage in OffKeyProfile
libs/features/unlock/shopify/src/lib/OffKeyProfile/OffKeyProfile.tsx
organizerId
parameter fromuseShopifyCustomer
hook.useConnectWallet.tsx
Add useConnectWallet Hook for Wallet Management
libs/features/unlock/shopify/src/lib/hooks/useConnectWallet.tsx
useConnectWallet
hook for managing wallet connections.useShopifyCustomer.tsx
Enhance useShopifyCustomer Hook with Additional Data
libs/features/unlock/shopify/src/lib/hooks/useShopifyCustomer.tsx
organizerId
parameter.additionalData
in the hook.Connect.tsx
Add V1Connect Component for Shopify Integration
libs/features/unlock/shopify/src/lib/v1/Connect/Connect.tsx
V1Connect
component for Shopify integration.useConnectWallet
anduseShopifyCustomer
hooks.Connected.tsx
Add V1Connected Component
libs/features/unlock/shopify/src/lib/v1/Connected/Connected.tsx
V1Connected
component.context.tsx
Enhance IFrameContext with Additional Data Support
libs/next/iframe/src/lib/context.tsx
additionalData
inIFrameContext
.hooks.ts
Enhance IFrame Hooks with Generic Type Support
libs/next/iframe/src/lib/hooks.ts
additionalData
.index.ts
Modify mint Method to Handle Already Minted Cards
libs/nft/loyalty-card/src/lib/index.ts
mint
method to return null if the loyalty card is alreadyminted.
3 files
middleware.ts
Update Middleware Configuration for Shopify Paths
apps/unlock/middleware.ts
.env.local
Update Shopify API Secret
.env.local
SHOPIFY_API_SECRET
value..prettierignore
Extend .prettierignore with Workspace Data
.prettierignore
.prettierignore
to include workspace data.9 files
deleteContentSpaceFile.spec.ts
Update Tests for deleteContentSpaceFile Action
libs/features/back-office/content-spaces/src/lib/actions/deleteContentSpaceFile.spec.ts
revalidateTag
function.revalidateTagKey
.deleteContentSpaceFiles.spec.ts
Update Tests for deleteContentSpaceFiles Action
libs/features/back-office/content-spaces/src/lib/actions/deleteContentSpaceFiles.spec.ts
revalidateTagKey
.deleteEventPassFile.spec.ts
Update Tests for deleteEventPassFile Action
libs/features/back-office/events/src/lib/actions/deleteEventPassFile.spec.ts
revalidateTagKey
.deleteEventPassFiles.spec.ts
Update Tests for deleteEventPassFiles Action
libs/features/back-office/events/src/lib/actions/deleteEventPassFiles.spec.ts
revalidateTagKey
.useConnectWallet.spec.tsx
Add Tests for useConnectWallet Hook
libs/features/unlock/shopify/src/lib/hooks/useConnectWallet.spec.tsx
useConnectWallet
hook.useShopifyCustomer.spec.tsx
Update Tests for useShopifyCustomer Hook
libs/features/unlock/shopify/src/lib/hooks/useShopifyCustomer.spec.tsx
organizerId
parameter.additionalData
.Connect.stories.tsx
Add Storybook Stories for V1Connect Component
libs/features/unlock/shopify/src/lib/v1/Connect/Connect.stories.tsx
V1Connect
component.examples.tsx
Add Example Data for V1Connect Component
libs/features/unlock/shopify/src/lib/v1/Connect/examples.tsx
V1Connect
component.index.spec.ts
Update Tests for LoyaltyCardNftWrapper
libs/nft/loyalty-card/src/lib/index.spec.ts
2 files
migrations.json
Update NX Migrations to Newer Versions
migrations.json
package.json
Upgrade Dependencies for Next.js, React, and NX
package.json