-
Notifications
You must be signed in to change notification settings - Fork 0
upstream sync #12
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
base: main
Are you sure you want to change the base?
upstream sync #12
Conversation
Add Business Directory Listing
Add a security policy document outlining supported versions and vulnerability reporting.
Bumps [glob](https://github.com/isaacs/node-glob) from 10.4.5 to 10.5.0. - [Changelog](https://github.com/isaacs/node-glob/blob/main/changelog.md) - [Commits](isaacs/node-glob@v10.4.5...v10.5.0) --- updated-dependencies: - dependency-name: glob dependency-version: 10.5.0 dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]>
- Update getClientTag() to return null when no VITE_SITE_NAME is configured - Modify useListings to show all listings when no client tag is set - Show only listings with matching client tag when VITE_SITE_NAME is configured - Fix useNostrPublish and useRepositories to handle null client tag - Add comprehensive tests for client tag filtering scenarios - Update .env.example with clearer documentation
build(deps): bump glob from 10.4.5 to 10.5.0
- Add client tag filtering as key feature in business listings section - Document flexible directory configurations (open vs curated) - Add comprehensive Client Tag Filtering section with examples - Update environment variables documentation - Clarify use cases for different deployment scenarios - Update important note to reflect new filtering capabilities
- Fix filtering logic to check actual 'client' tag from event instead of 't' tags - Update useListings to properly match client tag values from event.tags - Fix all test cases to use correct client tag format in mock events - Resolves issue where listings with client tags were not showing up - All tests passing (200/200)
- Add CLIENT_SIDE_CURATION and NPUB_CURATORS environment variables - Create useCuratorFlags hook to fetch flags from trusted curators - Update useListingFlags to query actual kind 1984 events - Modify useListings to filter out curator-flagged listings - Add npub to pubkey conversion using nostr-tools - Include comprehensive debug logging for troubleshooting - Support configurable curation via environment variables
- Modify renderDescription function to optionally disable clickable links - Set makeLinksClickable=false when rendering descriptions inside Link components - Prevents nested <a> tags that cause DOM validation warnings - URLs still display with primary color styling but aren't clickable in card/list views
- Remove debug utility imports from all files - Replace debugLog/debugWarn/debugError with console.log/warn/error - Keep debug.ts file for future use - Add example curator npub to .env.example
- Replace console.log/warn/error with debugLog/debugWarn/debugError - Add debug utility imports to all curation-related files - Debug logging now controlled by VITE_DEBUG_LOGGING environment variable - Resolve merge conflict in .env.example keeping curator npub
- Add section visibility utilities to siteConfig.ts based on VITE_SECTIONS - Create useListingsByAuthor hook to fetch author's business listings - Add listings section to profile page with full CRUD support - Respect VITE_SECTIONS configuration to show only enabled sections - Profile page now shows listings with same profile links as main page
- Add object-cover class to AvatarImage component - Images now crop to fit circular avatars without stretching - Shows center portion of images while maintaining aspect ratio - Affects all avatars across listings, profiles, apps, and other components
PR Compliance Guide 🔍Below is a summary of compliance checks for this PR:
Compliance status legend🟢 - Fully Compliant🟡 - Partial Compliant 🔴 - Not Compliant ⚪ - Requires Further Human Verification 🏷️ - Compliance label |
||||||||||||||||||||||||||||||||
PR Code Suggestions ✨Explore these optional code suggestions:
|
|||||||||||||||||||||||
Bumps [mdast-util-to-hast](https://github.com/syntax-tree/mdast-util-to-hast) from 13.2.0 to 13.2.1. - [Release notes](https://github.com/syntax-tree/mdast-util-to-hast/releases) - [Commits](syntax-tree/mdast-util-to-hast@13.2.0...13.2.1) --- updated-dependencies: - dependency-name: mdast-util-to-hast dependency-version: 13.2.1 dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]>
…til-to-hast-13.2.1 build(deps): bump mdast-util-to-hast from 13.2.0 to 13.2.1
Bumps [express](https://github.com/expressjs/express) from 4.21.2 to 4.22.1. - [Release notes](https://github.com/expressjs/express/releases) - [Changelog](https://github.com/expressjs/express/blob/v4.22.1/History.md) - [Commits](expressjs/express@4.21.2...v4.22.1) --- updated-dependencies: - dependency-name: express dependency-version: 4.22.1 dependency-type: indirect ... Signed-off-by: dependabot[bot] <[email protected]>
…-4.22.1 build(deps-dev): bump express from 4.21.2 to 4.22.1
PR Type
Enhancement, Tests, Bug fix, Documentation
Description
Business Listings Feature: Complete implementation of NIP-15 marketplace stalls directory with create, read, update, delete operations
New Hooks: Added
useListings,useListingsByAuthor,useListingSubmissionPayment,useListingFlags,useCuratorFlags, anduseDeleteListingfor listings managementUI Components: New listing display components (
ListingCard,ListingListItem), forms (BusinessListingForm), and dialogs (ListingSubmissionPaymentDialog,ListingFlagDialog)Pages: New pages for listings directory (
ListingsPage), submission (SubmitListingPage), details (ListingDetailPage), and editing (EditListingPage)Payment Integration: Lightning payment support for listing submissions with NIP-57 zaps and configurable relay endpoints
Content Curation: Client-side curation system with curator flags (kind 1984) and flag-based content filtering
Site Configuration: Enhanced
siteConfigwith curation settings, section visibility controls, and curator pubkey managementRouter Updates: Added listing routes and changed default landing page from
/appsto/listingsBug Fixes: Fixed client tag publishing logic to prevent empty tags when
VITE_SITE_NAMEis not configured; fixed regex escaping in GitHub readme displayTesting: Added comprehensive tests for listings filtering, payment handling, and author page integration
Documentation: Updated README with listings feature documentation, configuration details, and environment variables; added security policy
Styling: Added background pattern CSS utility class and updated layout with listings navigation
Code Quality: Removed unused imports, improved type safety, and added debug logging utility
Diagram Walkthrough
File Walkthrough
25 files
useListingSubmissionPayment.ts
Add listing submission payment hook with NIP-57 zap supportsrc/hooks/useListingSubmissionPayment.ts
using NIP-57 zaps
relay queries
LNURL encoding
environment variables
useListings.ts
Add hook for fetching and filtering business listingssrc/hooks/useListings.ts
data
useListingsByAuthor.ts
Add hook for fetching author-specific business listingssrc/hooks/useListingsByAuthor.ts
useListingsuseListingFlags.ts
Add hook for listing flag management and reportingsrc/hooks/useListingFlags.ts
inappropriate, impersonation)
references
useCuratorFlags.ts
Add hook for curator-based content curation flagssrc/hooks/useCuratorFlags.ts
curator pubkeys
useIsStallFlaggedto check if specific stall isflagged
siteConfig.ts
Enhance site config with curation and section visibility settingssrc/lib/siteConfig.ts
'https://lookup.hivetalk.org'
getClientTagto returnnullwhen VITE_SITE_NAME is notexplicitly set
visibility controls
nip19.decodeuseAppSubmissionPayment.ts
Add configurable zap receipt relay supportsrc/hooks/useAppSubmissionPayment.ts
VITE_ZAP_RECEIPT_RELAYenvironment variablefallback to Primal
typeofoperator instead ofcasting
useDeleteListing.ts
Add hook for deleting business listingssrc/hooks/useDeleteListing.ts
debug.ts
Add debug logging utility modulesrc/lib/debug.ts
VITE_DEBUG_LOGGINGdebugLog,debugWarn, anddebugErrorindex.css
Add background pattern CSS utility classsrc/index.css
.bg-bkg-patternCSS class for background pattern styling/bkg.svgas repeating background with fixed attachmentBusinessListingForm.tsx
Add business listing form component with payment integrationsrc/components/BusinessListingForm.tsx
listings
AuthorPage.tsx
Add business listings section to author profile pagesrc/pages/AuthorPage.tsx
useListingsByAuthorhook andListingCardcomponentisSectionVisiblefunctionListingDetailPage.tsx
Add business listing detail page with flag integrationsrc/pages/ListingDetailPage.tsx
information
owner
Layout.tsx
Add listings navigation and update layout stylingsrc/components/Layout.tsx
.bg-bkg-patternCSS classThemeSwitcherimportListingSubmissionPaymentDialog.tsx
Lightning payment dialog for listing submissionssrc/components/ListingSubmissionPaymentDialog.tsx
submissions
WebLN integration
verification polling
ListingsPage.tsx
Business directory listing page with search and filterssrc/pages/ListingsPage.tsx
ListingFlagDialog.tsx
Content flagging dialog for business listingssrc/components/ListingFlagDialog.tsx
inappropriate, impersonation)
EditListingPage.tsx
Edit and delete page for business listingssrc/pages/EditListingPage.tsx
verification
BusinessListingFormcomponent for editingListingListItem.tsx
List item component for business listings displaysrc/components/ListingListItem.tsx
ListingCard.tsx
Card component for business listings displaysrc/components/ListingCard.tsx
SubmitListingPage.tsx
Submit new business listing pagesrc/pages/SubmitListingPage.tsx
BusinessListingFormcomponent for submissionAppsPage.tsx
Relay information display on apps pagesrc/pages/AppsPage.tsx
useAppConfighook to display relay contextZapButton.tsx
Zap button refactoring and variant supportsrc/components/ZapButton.tsx
useCurrentUseranduseAuthorhooksdefault, ghost)
Index.tsx
Index page title and description updatessrc/pages/Index.tsx
avatar.tsx
Avatar image styling with object-coversrc/components/ui/avatar.tsx
object-coverclass to avatar image styling6 files
useListings.test.ts
Add tests for listing client tag filtering logicsrc/hooks/useListings.test.ts
useListingshook client tag filtering functionalityscenarios
getClientTagfunction from siteConfiguseAppSubmissionPayment.test.ts
Refactor app payment tests with QueryClient wrappersrc/hooks/useAppSubmissionPayment.test.ts
invariants
assertions
createWrapperfor test setupEditNipPage.test.tsx
Fix NIP edit page tests for async mutationssrc/pages/EditNipPage.test.tsx
mutatetomutateAsyncforuseNostrPublishwaitForfor async mutation callsAuthorPage.test.tsx
Test updates for author page listings integrationsrc/pages/AuthorPage.test.tsx
useListingsByAuthorhook across all test casesNipPage.test.tsx
NIP page test mock for zap componentsrc/pages/NipPage.test.tsx
ZapCustomNipcomponent to avoid wallet logic in testsIndex.test.tsx
Kind badge hover color test updatesrc/pages/Index.test.tsx
hover:bg-primary/20tohover:bg-purple-2004 files
useGitHubRepository.ts
Remove unused imports from repository hooksrc/hooks/useGitHubRepository.ts
useState,useEffect, anduseQueryClientuseLocalStorage.ts
Remove unused import from local storage hooksrc/hooks/useLocalStorage.ts
useEffectimport from ReactEditRepositoryPage.tsx
Unused import cleanup in edit repository pagesrc/pages/EditRepositoryPage.tsx
Alertimport from alert componentAlertDescriptionimport for actual usageFlagDialog.tsx
Unused error parameter cleanup in flag dialogsrc/components/FlagDialog.tsx
errorparameter in catch block3 files
useNostrPublish.ts
Fix client tag publishing when not configuredsrc/hooks/useNostrPublish.ts
getClientTag()returnsnon-null value
configured
useRepositories.ts
Fix client tag in repository issue creationsrc/hooks/useRepositories.ts
useCreateIssueto only add client tag whengetClientTag()returns non-null
GitHubReadmeDisplay.tsx
GitHub readme display fixes and cleanupsrc/components/GitHubReadmeDisplay.tsx
_repositoryNaddr,_repositoryOwnerPubkey)4 files
test-nip57-flow.js
Update NIP-57 test to use standard relaystests/nip57/test-nip57-flow.js
relay.primal.net, relay.nostr.band)
verification
AppRouter.tsx
Router configuration for business listingssrc/AppRouter.tsx
/listings,/listings/submit,/listings/:stallId,/listings/:stallId/edit)/appsto/listings(new default landing page).env.example
Environment configuration updates for listings and curation.env.example
VITE_SITE_NAMEfrom top-level configsite.webmanifest
Web manifest description updatepublic/site.webmanifest
Businesses, apps and Implementation Possibilities"
3 files
index.html
Update HTML meta tags for business/app focusindex.html
Possibilities" to "Nostr Businesses and Apps"
business/app focus
image alt text
README.md
Documentation updates for business listings and configurationREADME.md
feature
listings
SECURITY.md
Security policy documentationSECURITY.md
6 files