@medialane/ui 0.120.0 → 0.121.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/action-button.cjs.map +1 -1
- package/dist/components/action-button.d.cts +0 -9
- package/dist/components/action-button.d.ts +0 -9
- package/dist/components/action-button.js.map +1 -1
- package/dist/components/action-dialog.cjs.map +1 -1
- package/dist/components/action-dialog.d.cts +0 -1
- package/dist/components/action-dialog.d.ts +0 -1
- package/dist/components/action-dialog.js.map +1 -1
- package/dist/components/activity-card.cjs.map +1 -1
- package/dist/components/activity-card.d.cts +0 -3
- package/dist/components/activity-card.d.ts +0 -3
- package/dist/components/activity-card.js.map +1 -1
- package/dist/components/activity-row.cjs.map +1 -1
- package/dist/components/activity-row.d.cts +0 -1
- package/dist/components/activity-row.d.ts +0 -1
- package/dist/components/activity-row.js.map +1 -1
- package/dist/components/activity-ticker.cjs.map +1 -1
- package/dist/components/activity-ticker.d.cts +0 -1
- package/dist/components/activity-ticker.d.ts +0 -1
- package/dist/components/activity-ticker.js.map +1 -1
- package/dist/components/address-display.cjs.map +1 -1
- package/dist/components/address-display.d.cts +0 -1
- package/dist/components/address-display.d.ts +0 -1
- package/dist/components/address-display.js.map +1 -1
- package/dist/components/animated-token-media.cjs.map +1 -1
- package/dist/components/animated-token-media.d.cts +0 -10
- package/dist/components/animated-token-media.d.ts +0 -10
- package/dist/components/animated-token-media.js.map +1 -1
- package/dist/components/asset-card.cjs.map +1 -1
- package/dist/components/asset-card.d.cts +0 -29
- package/dist/components/asset-card.d.ts +0 -29
- package/dist/components/asset-card.js.map +1 -1
- package/dist/components/asset-collection-bar.cjs.map +1 -1
- package/dist/components/asset-collection-bar.d.cts +0 -1
- package/dist/components/asset-collection-bar.d.ts +0 -1
- package/dist/components/asset-collection-bar.js.map +1 -1
- package/dist/components/asset-license-summary.cjs.map +1 -1
- package/dist/components/asset-license-summary.d.cts +0 -8
- package/dist/components/asset-license-summary.d.ts +0 -8
- package/dist/components/asset-license-summary.js.map +1 -1
- package/dist/components/asset-lightbox.cjs.map +1 -1
- package/dist/components/asset-lightbox.js.map +1 -1
- package/dist/components/asset-marketplace-panel.cjs.map +1 -1
- package/dist/components/asset-marketplace-panel.d.cts +0 -13
- package/dist/components/asset-marketplace-panel.d.ts +0 -13
- package/dist/components/asset-marketplace-panel.js.map +1 -1
- package/dist/components/asset-markets-tab.cjs.map +1 -1
- package/dist/components/asset-markets-tab.js.map +1 -1
- package/dist/components/asset-overview-content.cjs.map +1 -1
- package/dist/components/asset-overview-content.d.cts +0 -7
- package/dist/components/asset-overview-content.d.ts +0 -7
- package/dist/components/asset-overview-content.js.map +1 -1
- package/dist/components/asset-picker-cell.cjs.map +1 -1
- package/dist/components/asset-picker-cell.d.cts +0 -4
- package/dist/components/asset-picker-cell.d.ts +0 -4
- package/dist/components/asset-picker-cell.js.map +1 -1
- package/dist/components/asset-picker.cjs.map +1 -1
- package/dist/components/asset-picker.d.cts +0 -4
- package/dist/components/asset-picker.d.ts +0 -4
- package/dist/components/asset-picker.js.map +1 -1
- package/dist/components/asset-search-picker.cjs.map +1 -1
- package/dist/components/asset-search-picker.d.cts +0 -2
- package/dist/components/asset-search-picker.d.ts +0 -2
- package/dist/components/asset-search-picker.js.map +1 -1
- package/dist/components/asset-top-sections.cjs.map +1 -1
- package/dist/components/asset-top-sections.d.cts +0 -18
- package/dist/components/asset-top-sections.d.ts +0 -18
- package/dist/components/asset-top-sections.js.map +1 -1
- package/dist/components/asset-utility-icons.cjs.map +1 -1
- package/dist/components/asset-utility-icons.d.cts +0 -5
- package/dist/components/asset-utility-icons.d.ts +0 -5
- package/dist/components/asset-utility-icons.js.map +1 -1
- package/dist/components/claim-rail.cjs.map +1 -1
- package/dist/components/claim-rail.d.cts +0 -9
- package/dist/components/claim-rail.d.ts +0 -9
- package/dist/components/claim-rail.js.map +1 -1
- package/dist/components/club-owner-actions.cjs.map +1 -1
- package/dist/components/club-owner-actions.d.cts +0 -2
- package/dist/components/club-owner-actions.d.ts +0 -2
- package/dist/components/club-owner-actions.js.map +1 -1
- package/dist/components/coin-card.cjs.map +1 -1
- package/dist/components/coin-card.d.cts +0 -2
- package/dist/components/coin-card.d.ts +0 -2
- package/dist/components/coin-card.js.map +1 -1
- package/dist/components/coin-launch-preview.cjs.map +1 -1
- package/dist/components/coin-launch-preview.d.cts +0 -7
- package/dist/components/coin-launch-preview.d.ts +0 -7
- package/dist/components/coin-launch-preview.js.map +1 -1
- package/dist/components/coins-explorer.cjs.map +1 -1
- package/dist/components/coins-explorer.d.cts +0 -1
- package/dist/components/coins-explorer.d.ts +0 -1
- package/dist/components/coins-explorer.js.map +1 -1
- package/dist/components/collection-card.cjs.map +1 -1
- package/dist/components/collection-card.d.cts +0 -2
- package/dist/components/collection-card.d.ts +0 -2
- package/dist/components/collection-card.js.map +1 -1
- package/dist/components/collection-filters.cjs.map +1 -1
- package/dist/components/collection-filters.js.map +1 -1
- package/dist/components/collection-hero-banner.cjs.map +1 -1
- package/dist/components/collection-hero-banner.d.cts +0 -7
- package/dist/components/collection-hero-banner.d.ts +0 -7
- package/dist/components/collection-hero-banner.js.map +1 -1
- package/dist/components/collection-traits-tab.cjs.map +1 -1
- package/dist/components/collection-traits-tab.js.map +1 -1
- package/dist/components/community-rewards-section.cjs.map +1 -1
- package/dist/components/community-rewards-section.js.map +1 -1
- package/dist/components/create-form-primitives.cjs.map +1 -1
- package/dist/components/create-form-primitives.d.cts +0 -2
- package/dist/components/create-form-primitives.d.ts +0 -2
- package/dist/components/create-form-primitives.js.map +1 -1
- package/dist/components/creation-record.cjs.map +1 -1
- package/dist/components/creation-record.d.cts +0 -5
- package/dist/components/creation-record.d.ts +0 -5
- package/dist/components/creation-record.js.map +1 -1
- package/dist/components/creator-airdrop-banner.cjs.map +1 -1
- package/dist/components/creator-airdrop-banner.d.cts +0 -1
- package/dist/components/creator-airdrop-banner.d.ts +0 -1
- package/dist/components/creator-airdrop-banner.js.map +1 -1
- package/dist/components/creator-analytics.cjs.map +1 -1
- package/dist/components/creator-analytics.js.map +1 -1
- package/dist/components/creator-score-inline.cjs.map +1 -1
- package/dist/components/creator-score-inline.d.cts +0 -5
- package/dist/components/creator-score-inline.d.ts +0 -5
- package/dist/components/creator-score-inline.js.map +1 -1
- package/dist/components/cta-card-grid.cjs.map +1 -1
- package/dist/components/cta-card-grid.d.cts +0 -2
- package/dist/components/cta-card-grid.d.ts +0 -2
- package/dist/components/cta-card-grid.js.map +1 -1
- package/dist/components/currency-icon.cjs.map +1 -1
- package/dist/components/currency-icon.d.cts +0 -5
- package/dist/components/currency-icon.d.ts +0 -5
- package/dist/components/currency-icon.js.map +1 -1
- package/dist/components/discover-collections-strip.cjs.map +1 -1
- package/dist/components/discover-collections-strip.d.cts +0 -4
- package/dist/components/discover-collections-strip.d.ts +0 -4
- package/dist/components/discover-collections-strip.js.map +1 -1
- package/dist/components/discover-creators-strip.cjs.map +1 -1
- package/dist/components/discover-creators-strip.js.map +1 -1
- package/dist/components/discover-feed-section.cjs.map +1 -1
- package/dist/components/discover-feed-section.d.cts +0 -11
- package/dist/components/discover-feed-section.d.ts +0 -11
- package/dist/components/discover-feed-section.js.map +1 -1
- package/dist/components/discover-hero.cjs.map +1 -1
- package/dist/components/discover-hero.js.map +1 -1
- package/dist/components/drop-countdown.cjs.map +1 -1
- package/dist/components/drop-countdown.js.map +1 -1
- package/dist/components/dual-price.cjs +0 -6
- package/dist/components/dual-price.cjs.map +1 -1
- package/dist/components/dual-price.d.cts +0 -30
- package/dist/components/dual-price.d.ts +0 -30
- package/dist/components/dual-price.js +0 -6
- package/dist/components/dual-price.js.map +1 -1
- package/dist/components/empty-or-error.cjs.map +1 -1
- package/dist/components/empty-or-error.d.cts +0 -1
- package/dist/components/empty-or-error.d.ts +0 -1
- package/dist/components/empty-or-error.js.map +1 -1
- package/dist/components/gradient-button.cjs.map +1 -1
- package/dist/components/gradient-button.d.cts +0 -13
- package/dist/components/gradient-button.d.ts +0 -13
- package/dist/components/gradient-button.js.map +1 -1
- package/dist/components/help-icon.cjs.map +1 -1
- package/dist/components/help-icon.d.cts +0 -4
- package/dist/components/help-icon.d.ts +0 -4
- package/dist/components/help-icon.js.map +1 -1
- package/dist/components/hero-slider.cjs.map +1 -1
- package/dist/components/hero-slider.d.cts +0 -1
- package/dist/components/hero-slider.d.ts +0 -1
- package/dist/components/hero-slider.js.map +1 -1
- package/dist/components/ip-type-badge.cjs.map +1 -1
- package/dist/components/ip-type-badge.d.cts +0 -2
- package/dist/components/ip-type-badge.d.ts +0 -2
- package/dist/components/ip-type-badge.js.map +1 -1
- package/dist/components/ip-type-display.cjs.map +1 -1
- package/dist/components/ip-type-display.js.map +1 -1
- package/dist/components/ip-type-fields.cjs.map +1 -1
- package/dist/components/ip-type-fields.d.cts +0 -2
- package/dist/components/ip-type-fields.d.ts +0 -2
- package/dist/components/ip-type-fields.js.map +1 -1
- package/dist/components/launchpad-filter-bar.cjs.map +1 -1
- package/dist/components/launchpad-filter-bar.d.cts +0 -8
- package/dist/components/launchpad-filter-bar.d.ts +0 -8
- package/dist/components/launchpad-filter-bar.js.map +1 -1
- package/dist/components/launchpad-services.cjs +0 -1
- package/dist/components/launchpad-services.cjs.map +1 -1
- package/dist/components/launchpad-services.d.cts +0 -36
- package/dist/components/launchpad-services.d.ts +0 -36
- package/dist/components/launchpad-services.js +0 -1
- package/dist/components/launchpad-services.js.map +1 -1
- package/dist/components/launchpad-strip.cjs.map +1 -1
- package/dist/components/launchpad-strip.d.cts +0 -6
- package/dist/components/launchpad-strip.d.ts +0 -6
- package/dist/components/launchpad-strip.js.map +1 -1
- package/dist/components/license-terms-builder.cjs.map +1 -1
- package/dist/components/license-terms-builder.d.cts +0 -34
- package/dist/components/license-terms-builder.d.ts +0 -34
- package/dist/components/license-terms-builder.js.map +1 -1
- package/dist/components/listing-card.cjs.map +1 -1
- package/dist/components/listing-card.d.cts +0 -19
- package/dist/components/listing-card.d.ts +0 -19
- package/dist/components/listing-card.js.map +1 -1
- package/dist/components/load-more-sentinel.cjs.map +1 -1
- package/dist/components/load-more-sentinel.d.cts +0 -6
- package/dist/components/load-more-sentinel.d.ts +0 -6
- package/dist/components/load-more-sentinel.js.map +1 -1
- package/dist/components/medialane-collection-card.cjs +1 -4
- package/dist/components/medialane-collection-card.cjs.map +1 -1
- package/dist/components/medialane-collection-card.d.cts +0 -13
- package/dist/components/medialane-collection-card.d.ts +0 -13
- package/dist/components/medialane-collection-card.js +1 -4
- package/dist/components/medialane-collection-card.js.map +1 -1
- package/dist/components/motion-primitives.cjs.map +1 -1
- package/dist/components/motion-primitives.js.map +1 -1
- package/dist/components/nav-command-menu.cjs.map +1 -1
- package/dist/components/nav-command-menu.d.cts +0 -32
- package/dist/components/nav-command-menu.d.ts +0 -32
- package/dist/components/nav-command-menu.js.map +1 -1
- package/dist/components/nav-shell.cjs.map +1 -1
- package/dist/components/nav-shell.d.cts +0 -57
- package/dist/components/nav-shell.d.ts +0 -57
- package/dist/components/nav-shell.js.map +1 -1
- package/dist/components/nav-theme-toggle.cjs.map +1 -1
- package/dist/components/nav-theme-toggle.d.cts +0 -4
- package/dist/components/nav-theme-toggle.d.ts +0 -4
- package/dist/components/nav-theme-toggle.js.map +1 -1
- package/dist/components/order-sort-control.cjs.map +1 -1
- package/dist/components/order-sort-control.d.cts +0 -2
- package/dist/components/order-sort-control.d.ts +0 -2
- package/dist/components/order-sort-control.js.map +1 -1
- package/dist/components/page-container.cjs +0 -3
- package/dist/components/page-container.cjs.map +1 -1
- package/dist/components/page-container.d.cts +0 -6
- package/dist/components/page-container.d.ts +0 -6
- package/dist/components/page-container.js +0 -3
- package/dist/components/page-container.js.map +1 -1
- package/dist/components/parent-attribution-banner.cjs.map +1 -1
- package/dist/components/parent-attribution-banner.d.cts +0 -1
- package/dist/components/parent-attribution-banner.d.ts +0 -1
- package/dist/components/parent-attribution-banner.js.map +1 -1
- package/dist/components/portfolio-activity.cjs.map +1 -1
- package/dist/components/portfolio-activity.js.map +1 -1
- package/dist/components/portfolio-bento-tile.cjs +8 -3
- package/dist/components/portfolio-bento-tile.cjs.map +1 -1
- package/dist/components/portfolio-bento-tile.d.cts +5 -13
- package/dist/components/portfolio-bento-tile.d.ts +5 -13
- package/dist/components/portfolio-bento-tile.js +8 -3
- package/dist/components/portfolio-bento-tile.js.map +1 -1
- package/dist/components/portfolio-chip-filter.cjs.map +1 -1
- package/dist/components/portfolio-chip-filter.d.cts +0 -14
- package/dist/components/portfolio-chip-filter.d.ts +0 -14
- package/dist/components/portfolio-chip-filter.js.map +1 -1
- package/dist/components/portfolio-header.cjs.map +1 -1
- package/dist/components/portfolio-header.d.cts +0 -11
- package/dist/components/portfolio-header.d.ts +0 -11
- package/dist/components/portfolio-header.js.map +1 -1
- package/dist/components/portfolio-overview.cjs +6 -1
- package/dist/components/portfolio-overview.cjs.map +1 -1
- package/dist/components/portfolio-overview.d.cts +0 -18
- package/dist/components/portfolio-overview.d.ts +0 -18
- package/dist/components/portfolio-overview.js +6 -1
- package/dist/components/portfolio-overview.js.map +1 -1
- package/dist/components/price-history-chart.cjs.map +1 -1
- package/dist/components/price-history-chart.js.map +1 -1
- package/dist/components/rewards/badge-catalog.cjs.map +1 -1
- package/dist/components/rewards/badge-catalog.d.cts +0 -5
- package/dist/components/rewards/badge-catalog.d.ts +0 -5
- package/dist/components/rewards/badge-catalog.js.map +1 -1
- package/dist/components/rewards/badge-shelf.cjs.map +1 -1
- package/dist/components/rewards/badge-shelf.d.cts +0 -5
- package/dist/components/rewards/badge-shelf.d.ts +0 -5
- package/dist/components/rewards/badge-shelf.js.map +1 -1
- package/dist/components/rewards/badge-unlock-toast-content.cjs.map +1 -1
- package/dist/components/rewards/badge-unlock-toast-content.d.cts +0 -2
- package/dist/components/rewards/badge-unlock-toast-content.d.ts +0 -2
- package/dist/components/rewards/badge-unlock-toast-content.js.map +1 -1
- package/dist/components/rewards/journey-path.cjs.map +1 -1
- package/dist/components/rewards/journey-path.d.cts +0 -9
- package/dist/components/rewards/journey-path.d.ts +0 -9
- package/dist/components/rewards/journey-path.js.map +1 -1
- package/dist/components/rewards/leaderboard-table.cjs.map +1 -1
- package/dist/components/rewards/leaderboard-table.d.cts +0 -11
- package/dist/components/rewards/leaderboard-table.d.ts +0 -11
- package/dist/components/rewards/leaderboard-table.js.map +1 -1
- package/dist/components/rewards/level-badge.cjs.map +1 -1
- package/dist/components/rewards/level-badge.d.cts +0 -10
- package/dist/components/rewards/level-badge.d.ts +0 -10
- package/dist/components/rewards/level-badge.js.map +1 -1
- package/dist/components/rewards/level-journey-list.cjs.map +1 -1
- package/dist/components/rewards/level-journey-list.d.cts +0 -7
- package/dist/components/rewards/level-journey-list.d.ts +0 -7
- package/dist/components/rewards/level-journey-list.js.map +1 -1
- package/dist/components/rewards/level-up-celebration.cjs.map +1 -1
- package/dist/components/rewards/level-up-celebration.d.cts +0 -4
- package/dist/components/rewards/level-up-celebration.d.ts +0 -4
- package/dist/components/rewards/level-up-celebration.js.map +1 -1
- package/dist/components/rewards/reward-toast.cjs.map +1 -1
- package/dist/components/rewards/reward-toast.d.cts +0 -8
- package/dist/components/rewards/reward-toast.d.ts +0 -8
- package/dist/components/rewards/reward-toast.js.map +1 -1
- package/dist/components/rewards/score-summary-card.cjs.map +1 -1
- package/dist/components/rewards/score-summary-card.d.cts +0 -5
- package/dist/components/rewards/score-summary-card.d.ts +0 -5
- package/dist/components/rewards/score-summary-card.js.map +1 -1
- package/dist/components/rewards/use-rewards-celebrations.cjs.map +1 -1
- package/dist/components/rewards/use-rewards-celebrations.d.cts +0 -10
- package/dist/components/rewards/use-rewards-celebrations.d.ts +0 -10
- package/dist/components/rewards/use-rewards-celebrations.js.map +1 -1
- package/dist/components/rewards/xp-progress.cjs.map +1 -1
- package/dist/components/rewards/xp-progress.d.cts +0 -4
- package/dist/components/rewards/xp-progress.d.ts +0 -4
- package/dist/components/rewards/xp-progress.js.map +1 -1
- package/dist/components/rewards/xp-toast-content.cjs.map +1 -1
- package/dist/components/rewards/xp-toast-content.d.cts +0 -7
- package/dist/components/rewards/xp-toast-content.d.ts +0 -7
- package/dist/components/rewards/xp-toast-content.js.map +1 -1
- package/dist/components/scroll-section.cjs.map +1 -1
- package/dist/components/scroll-section.d.cts +0 -6
- package/dist/components/scroll-section.d.ts +0 -6
- package/dist/components/scroll-section.js.map +1 -1
- package/dist/components/service-form-shell.cjs.map +1 -1
- package/dist/components/service-form-shell.d.cts +0 -14
- package/dist/components/service-form-shell.d.ts +0 -14
- package/dist/components/service-form-shell.js.map +1 -1
- package/dist/components/service-header.cjs.map +1 -1
- package/dist/components/service-header.d.cts +0 -11
- package/dist/components/service-header.d.ts +0 -11
- package/dist/components/service-header.js.map +1 -1
- package/dist/components/share-button.cjs.map +1 -1
- package/dist/components/share-button.js.map +1 -1
- package/dist/components/stat-tile.cjs.map +1 -1
- package/dist/components/stat-tile.d.cts +0 -4
- package/dist/components/stat-tile.d.ts +0 -4
- package/dist/components/stat-tile.js.map +1 -1
- package/dist/components/step-nav.cjs.map +1 -1
- package/dist/components/step-nav.d.cts +0 -11
- package/dist/components/step-nav.d.ts +0 -11
- package/dist/components/step-nav.js.map +1 -1
- package/dist/components/theme-ambient-background.cjs.map +1 -1
- package/dist/components/theme-ambient-background.d.cts +0 -6
- package/dist/components/theme-ambient-background.d.ts +0 -6
- package/dist/components/theme-ambient-background.js.map +1 -1
- package/dist/components/token-card.cjs.map +1 -1
- package/dist/components/token-card.d.cts +0 -6
- package/dist/components/token-card.d.ts +0 -6
- package/dist/components/token-card.js.map +1 -1
- package/dist/components/token-glyph.cjs.map +1 -1
- package/dist/components/token-glyph.d.cts +0 -2
- package/dist/components/token-glyph.d.ts +0 -2
- package/dist/components/token-glyph.js.map +1 -1
- package/dist/data/brand.cjs.map +1 -1
- package/dist/data/brand.d.cts +0 -6
- package/dist/data/brand.d.ts +0 -6
- package/dist/data/brand.js.map +1 -1
- package/dist/data/coins.cjs.map +1 -1
- package/dist/data/coins.d.cts +0 -9
- package/dist/data/coins.d.ts +0 -9
- package/dist/data/coins.js.map +1 -1
- package/dist/data/ip-templates.cjs.map +1 -1
- package/dist/data/ip-templates.d.cts +0 -12
- package/dist/data/ip-templates.d.ts +0 -12
- package/dist/data/ip-templates.js.map +1 -1
- package/dist/data/ip-types.cjs.map +1 -1
- package/dist/data/ip-types.d.cts +0 -2
- package/dist/data/ip-types.d.ts +0 -2
- package/dist/data/ip-types.js.map +1 -1
- package/dist/data/ip.cjs.map +1 -1
- package/dist/data/ip.d.cts +0 -1
- package/dist/data/ip.d.ts +0 -1
- package/dist/data/ip.js.map +1 -1
- package/dist/data/launchpad-services.cjs +0 -10
- package/dist/data/launchpad-services.cjs.map +1 -1
- package/dist/data/launchpad-services.d.cts +0 -10
- package/dist/data/launchpad-services.d.ts +0 -10
- package/dist/data/launchpad-services.js +0 -10
- package/dist/data/launchpad-services.js.map +1 -1
- package/dist/data/living-render-collections.cjs +0 -2
- package/dist/data/living-render-collections.cjs.map +1 -1
- package/dist/data/living-render-collections.d.cts +0 -11
- package/dist/data/living-render-collections.d.ts +0 -11
- package/dist/data/living-render-collections.js +0 -2
- package/dist/data/living-render-collections.js.map +1 -1
- package/dist/data/notification.cjs.map +1 -1
- package/dist/data/notification.d.cts +0 -3
- package/dist/data/notification.d.ts +0 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/preset/tailwind.cjs +0 -9
- package/dist/preset/tailwind.cjs.map +1 -1
- package/dist/preset/tailwind.js +0 -9
- package/dist/preset/tailwind.js.map +1 -1
- package/dist/utils/address.cjs.map +1 -1
- package/dist/utils/address.d.cts +0 -4
- package/dist/utils/address.d.ts +0 -4
- package/dist/utils/address.js.map +1 -1
- package/dist/utils/api-fetch.cjs.map +1 -1
- package/dist/utils/api-fetch.d.cts +0 -21
- package/dist/utils/api-fetch.d.ts +0 -21
- package/dist/utils/api-fetch.js.map +1 -1
- package/dist/utils/format.cjs.map +1 -1
- package/dist/utils/format.d.cts +0 -11
- package/dist/utils/format.d.ts +0 -11
- package/dist/utils/format.js.map +1 -1
- package/dist/utils/ipfs.cjs.map +1 -1
- package/dist/utils/ipfs.d.cts +0 -8
- package/dist/utils/ipfs.d.ts +0 -8
- package/dist/utils/ipfs.js.map +1 -1
- package/dist/utils/license-summary.cjs.map +1 -1
- package/dist/utils/license-summary.d.cts +0 -8
- package/dist/utils/license-summary.d.ts +0 -8
- package/dist/utils/license-summary.js.map +1 -1
- package/dist/utils/notification-storage.cjs.map +1 -1
- package/dist/utils/notification-storage.js.map +1 -1
- package/dist/utils/portfolio-counts.cjs.map +1 -1
- package/dist/utils/portfolio-counts.d.cts +0 -18
- package/dist/utils/portfolio-counts.d.ts +0 -18
- package/dist/utils/portfolio-counts.js.map +1 -1
- package/dist/utils/proxy-body.cjs.map +1 -1
- package/dist/utils/proxy-body.d.cts +0 -11
- package/dist/utils/proxy-body.d.ts +0 -11
- package/dist/utils/proxy-body.js.map +1 -1
- package/dist/utils/time.cjs.map +1 -1
- package/dist/utils/time.d.cts +0 -5
- package/dist/utils/time.d.ts +0 -5
- package/dist/utils/time.js.map +1 -1
- package/dist/utils/use-collections.cjs.map +1 -1
- package/dist/utils/use-collections.d.cts +1 -11
- package/dist/utils/use-collections.d.ts +1 -11
- package/dist/utils/use-collections.js.map +1 -1
- package/dist/utils/use-intersection-active.cjs.map +1 -1
- package/dist/utils/use-intersection-active.d.cts +0 -7
- package/dist/utils/use-intersection-active.d.ts +0 -7
- package/dist/utils/use-intersection-active.js.map +1 -1
- package/dist/utils/use-notifications.cjs.map +1 -1
- package/dist/utils/use-notifications.js.map +1 -1
- package/dist/utils/use-orders.cjs.map +1 -1
- package/dist/utils/use-orders.d.cts +0 -2
- package/dist/utils/use-orders.d.ts +0 -2
- package/dist/utils/use-orders.js.map +1 -1
- package/dist/utils/use-profiles.cjs.map +1 -1
- package/dist/utils/use-profiles.js.map +1 -1
- package/dist/utils/use-remix-offers.cjs.map +1 -1
- package/dist/utils/use-remix-offers.d.cts +0 -1
- package/dist/utils/use-remix-offers.d.ts +0 -1
- package/dist/utils/use-remix-offers.js.map +1 -1
- package/dist/utils/use-rewards.cjs.map +1 -1
- package/dist/utils/use-rewards.d.cts +0 -4
- package/dist/utils/use-rewards.d.ts +0 -4
- package/dist/utils/use-rewards.js.map +1 -1
- package/package.json +1 -1
|
@@ -3,62 +3,33 @@ import { ServiceStatus, ServiceGroup, ServiceDefinition, ServiceGroupDefinition
|
|
|
3
3
|
import 'lucide-react';
|
|
4
4
|
|
|
5
5
|
interface ServiceOverride {
|
|
6
|
-
/** Primary destination — the whole card links here (required for live services) */
|
|
7
6
|
href?: string;
|
|
8
|
-
/** Legacy secondary link — the redesigned card renders a single link, so this is unused. */
|
|
9
7
|
browseHref?: string;
|
|
10
|
-
/** Per-app rollout flips (e.g. coins live on one app first) */
|
|
11
8
|
status?: ServiceStatus;
|
|
12
|
-
/** Per-app one-liner override (rarely needed) */
|
|
13
9
|
blurb?: string;
|
|
14
|
-
/** Live per-user fact shown as a quiet chip on the card (e.g. "3 collections").
|
|
15
|
-
* Apps pass real counts for the signed-in creator; omit when zero/signed out. */
|
|
16
10
|
meta?: string;
|
|
17
11
|
}
|
|
18
12
|
type ServiceOverrides = Record<string, ServiceOverride>;
|
|
19
|
-
/** Each group owns one hue of the Medialane spectrum (blue → indigo → purple →
|
|
20
|
-
* rose → orange in group order), applied flat: icon-tile tint + glyph, the
|
|
21
|
-
* use-case markers, and the card's resting hairline. On hover-capable
|
|
22
|
-
* devices the full-spectrum gradient ring fades in over the hairline
|
|
23
|
-
* (.ml-grad-hover-border — polish only, never carries information). */
|
|
24
13
|
interface GroupSlice {
|
|
25
|
-
/** soft icon-tile background */
|
|
26
14
|
tint: string;
|
|
27
|
-
/** icon glyph + use-case marker tint */
|
|
28
15
|
text: string;
|
|
29
|
-
/** resting card hairline in the group's hue */
|
|
30
16
|
border: string;
|
|
31
17
|
}
|
|
32
18
|
declare const GROUP_SLICES: Record<ServiceGroup, GroupSlice>;
|
|
33
|
-
/** Legacy per-service hue table — kept for LaunchpadStrip (homepage). The grid
|
|
34
|
-
* no longer uses it. */
|
|
35
19
|
interface ServiceHue {
|
|
36
20
|
text: string;
|
|
37
21
|
solid: string;
|
|
38
22
|
border: string;
|
|
39
23
|
tint: string;
|
|
40
24
|
}
|
|
41
|
-
/** Brand tokens only ([[brand-tokens-only]]) — one hue per service, drawn from
|
|
42
|
-
* the brand spectrum. */
|
|
43
25
|
declare const SERVICE_HUES: Record<string, ServiceHue>;
|
|
44
26
|
interface LaunchpadServiceCardProps {
|
|
45
27
|
def: ServiceDefinition;
|
|
46
28
|
override?: ServiceOverride;
|
|
47
|
-
/** Grid position — drives the staggered entrance reveal. */
|
|
48
29
|
index?: number;
|
|
49
30
|
}
|
|
50
31
|
declare function LaunchpadServiceCard({ def, override, index }: LaunchpadServiceCardProps): react_jsx_runtime.JSX.Element;
|
|
51
|
-
/** Shared search predicate — group titles count as search terms so a query
|
|
52
|
-
* like "editions" or "community" finds the whole group. */
|
|
53
32
|
declare function serviceMatchesQuery(def: ServiceDefinition, query: string): boolean;
|
|
54
|
-
/**
|
|
55
|
-
* Owns the search + group-filter state for the launchpad page. A page renders
|
|
56
|
-
* `LaunchpadFilterBar` wherever it wants (e.g. right under the h1) wired to
|
|
57
|
-
* this hook's fields, then passes `query`/`activeGroups` straight through to
|
|
58
|
-
* `LaunchpadGroupedSections` so the grid reacts to the same state.
|
|
59
|
-
* State is mirrored into the URL (?q=…&groups=…) so a filtered view can be
|
|
60
|
-
* shared and survives reload.
|
|
61
|
-
*/
|
|
62
33
|
declare function useLaunchpadFilter(): {
|
|
63
34
|
query: string;
|
|
64
35
|
setQuery: (value: string) => void;
|
|
@@ -69,19 +40,12 @@ declare function useLaunchpadFilter(): {
|
|
|
69
40
|
clear: () => void;
|
|
70
41
|
};
|
|
71
42
|
interface LaunchpadGroupedSectionsProps {
|
|
72
|
-
/** Per-app hrefs / rollout flips, keyed by service key. */
|
|
73
43
|
overrides: ServiceOverrides;
|
|
74
|
-
/** Current search query — from `useLaunchpadFilter()`. */
|
|
75
44
|
query: string;
|
|
76
|
-
/** Current active group filters — from `useLaunchpadFilter()`. */
|
|
77
45
|
activeGroups: Set<ServiceGroup>;
|
|
78
|
-
/** Reset both — from `useLaunchpadFilter()`. */
|
|
79
46
|
onClearFilters: () => void;
|
|
80
47
|
className?: string;
|
|
81
48
|
}
|
|
82
|
-
/** The full launchpad services grid — one dynamic grid of all live services,
|
|
83
|
-
* ordered by group, plus the coming-soon strip. Fully controlled by
|
|
84
|
-
* `useLaunchpadFilter()` state passed in from the page. */
|
|
85
49
|
declare function LaunchpadGroupedSections({ overrides, query, activeGroups, onClearFilters, className }: LaunchpadGroupedSectionsProps): react_jsx_runtime.JSX.Element;
|
|
86
50
|
|
|
87
51
|
export { GROUP_SLICES, LaunchpadGroupedSections, type LaunchpadGroupedSectionsProps, LaunchpadServiceCard, type LaunchpadServiceCardProps, SERVICE_HUES, type ServiceOverride, type ServiceOverrides, serviceMatchesQuery, useLaunchpadFilter };
|
|
@@ -3,62 +3,33 @@ import { ServiceStatus, ServiceGroup, ServiceDefinition, ServiceGroupDefinition
|
|
|
3
3
|
import 'lucide-react';
|
|
4
4
|
|
|
5
5
|
interface ServiceOverride {
|
|
6
|
-
/** Primary destination — the whole card links here (required for live services) */
|
|
7
6
|
href?: string;
|
|
8
|
-
/** Legacy secondary link — the redesigned card renders a single link, so this is unused. */
|
|
9
7
|
browseHref?: string;
|
|
10
|
-
/** Per-app rollout flips (e.g. coins live on one app first) */
|
|
11
8
|
status?: ServiceStatus;
|
|
12
|
-
/** Per-app one-liner override (rarely needed) */
|
|
13
9
|
blurb?: string;
|
|
14
|
-
/** Live per-user fact shown as a quiet chip on the card (e.g. "3 collections").
|
|
15
|
-
* Apps pass real counts for the signed-in creator; omit when zero/signed out. */
|
|
16
10
|
meta?: string;
|
|
17
11
|
}
|
|
18
12
|
type ServiceOverrides = Record<string, ServiceOverride>;
|
|
19
|
-
/** Each group owns one hue of the Medialane spectrum (blue → indigo → purple →
|
|
20
|
-
* rose → orange in group order), applied flat: icon-tile tint + glyph, the
|
|
21
|
-
* use-case markers, and the card's resting hairline. On hover-capable
|
|
22
|
-
* devices the full-spectrum gradient ring fades in over the hairline
|
|
23
|
-
* (.ml-grad-hover-border — polish only, never carries information). */
|
|
24
13
|
interface GroupSlice {
|
|
25
|
-
/** soft icon-tile background */
|
|
26
14
|
tint: string;
|
|
27
|
-
/** icon glyph + use-case marker tint */
|
|
28
15
|
text: string;
|
|
29
|
-
/** resting card hairline in the group's hue */
|
|
30
16
|
border: string;
|
|
31
17
|
}
|
|
32
18
|
declare const GROUP_SLICES: Record<ServiceGroup, GroupSlice>;
|
|
33
|
-
/** Legacy per-service hue table — kept for LaunchpadStrip (homepage). The grid
|
|
34
|
-
* no longer uses it. */
|
|
35
19
|
interface ServiceHue {
|
|
36
20
|
text: string;
|
|
37
21
|
solid: string;
|
|
38
22
|
border: string;
|
|
39
23
|
tint: string;
|
|
40
24
|
}
|
|
41
|
-
/** Brand tokens only ([[brand-tokens-only]]) — one hue per service, drawn from
|
|
42
|
-
* the brand spectrum. */
|
|
43
25
|
declare const SERVICE_HUES: Record<string, ServiceHue>;
|
|
44
26
|
interface LaunchpadServiceCardProps {
|
|
45
27
|
def: ServiceDefinition;
|
|
46
28
|
override?: ServiceOverride;
|
|
47
|
-
/** Grid position — drives the staggered entrance reveal. */
|
|
48
29
|
index?: number;
|
|
49
30
|
}
|
|
50
31
|
declare function LaunchpadServiceCard({ def, override, index }: LaunchpadServiceCardProps): react_jsx_runtime.JSX.Element;
|
|
51
|
-
/** Shared search predicate — group titles count as search terms so a query
|
|
52
|
-
* like "editions" or "community" finds the whole group. */
|
|
53
32
|
declare function serviceMatchesQuery(def: ServiceDefinition, query: string): boolean;
|
|
54
|
-
/**
|
|
55
|
-
* Owns the search + group-filter state for the launchpad page. A page renders
|
|
56
|
-
* `LaunchpadFilterBar` wherever it wants (e.g. right under the h1) wired to
|
|
57
|
-
* this hook's fields, then passes `query`/`activeGroups` straight through to
|
|
58
|
-
* `LaunchpadGroupedSections` so the grid reacts to the same state.
|
|
59
|
-
* State is mirrored into the URL (?q=…&groups=…) so a filtered view can be
|
|
60
|
-
* shared and survives reload.
|
|
61
|
-
*/
|
|
62
33
|
declare function useLaunchpadFilter(): {
|
|
63
34
|
query: string;
|
|
64
35
|
setQuery: (value: string) => void;
|
|
@@ -69,19 +40,12 @@ declare function useLaunchpadFilter(): {
|
|
|
69
40
|
clear: () => void;
|
|
70
41
|
};
|
|
71
42
|
interface LaunchpadGroupedSectionsProps {
|
|
72
|
-
/** Per-app hrefs / rollout flips, keyed by service key. */
|
|
73
43
|
overrides: ServiceOverrides;
|
|
74
|
-
/** Current search query — from `useLaunchpadFilter()`. */
|
|
75
44
|
query: string;
|
|
76
|
-
/** Current active group filters — from `useLaunchpadFilter()`. */
|
|
77
45
|
activeGroups: Set<ServiceGroup>;
|
|
78
|
-
/** Reset both — from `useLaunchpadFilter()`. */
|
|
79
46
|
onClearFilters: () => void;
|
|
80
47
|
className?: string;
|
|
81
48
|
}
|
|
82
|
-
/** The full launchpad services grid — one dynamic grid of all live services,
|
|
83
|
-
* ordered by group, plus the coming-soon strip. Fully controlled by
|
|
84
|
-
* `useLaunchpadFilter()` state passed in from the page. */
|
|
85
49
|
declare function LaunchpadGroupedSections({ overrides, query, activeGroups, onClearFilters, className }: LaunchpadGroupedSectionsProps): react_jsx_runtime.JSX.Element;
|
|
86
50
|
|
|
87
51
|
export { GROUP_SLICES, LaunchpadGroupedSections, type LaunchpadGroupedSectionsProps, LaunchpadServiceCard, type LaunchpadServiceCardProps, SERVICE_HUES, type ServiceOverride, type ServiceOverrides, serviceMatchesQuery, useLaunchpadFilter };
|
|
@@ -152,7 +152,6 @@ function useLaunchpadFilter() {
|
|
|
152
152
|
};
|
|
153
153
|
const totalMatches = useMemo(
|
|
154
154
|
() => LAUNCHPAD_SERVICE_DEFINITIONS.filter(matches).length,
|
|
155
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
156
155
|
[query, activeGroups]
|
|
157
156
|
);
|
|
158
157
|
const clear = () => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/components/launchpad-services.tsx"],"sourcesContent":["\"use client\";\n\n/**\n * Launchpad services — the single source for the /launchpad page UI in\n * medialane-io and medialane-starknet.\n *\n * One dynamic grid (2026-07-13 redesign): one card per service, no group\n * sections. Groups exist as tags — a small accent label on the card and the\n * filter pills above the grid. The card is a single link to the service's own\n * page (its complete control surface); it carries no second link, no feature\n * chips, and no per-service color identity. Five group accents are the only\n * color voice, applied to the icon tile and the tag text.\n *\n * Filter state (search + group pills) lives in `useLaunchpadFilter()` so a\n * page can render `LaunchpadFilterBar` wherever it wants while\n * `LaunchpadGroupedSections` — fully controlled — renders the grid reacting\n * to that same state.\n *\n * Apps own: hrefs + per-app rollout status flips. Everything else lives here.\n */\n\nimport { useEffect, useMemo, useState } from \"react\";\nimport Link from \"next/link\";\nimport { AnimatePresence, motion, useReducedMotion } from \"framer-motion\";\nimport { Lock, ArrowRight, Check } from \"lucide-react\";\nimport { cn } from \"../utils/cn.js\";\nimport {\n LAUNCHPAD_SERVICE_DEFINITIONS,\n LAUNCHPAD_SERVICE_GROUPS,\n type ServiceDefinition,\n type ServiceGroup,\n type ServiceGroupDefinition,\n type ServiceStatus,\n} from \"../data/launchpad-services.js\";\n\n// ── Per-app injection points ─────────────────────────────────────────────────\n\nexport interface ServiceOverride {\n /** Primary destination — the whole card links here (required for live services) */\n href?: string;\n /** Legacy secondary link — the redesigned card renders a single link, so this is unused. */\n browseHref?: string;\n /** Per-app rollout flips (e.g. coins live on one app first) */\n status?: ServiceStatus;\n /** Per-app one-liner override (rarely needed) */\n blurb?: string;\n /** Live per-user fact shown as a quiet chip on the card (e.g. \"3 collections\").\n * Apps pass real counts for the signed-in creator; omit when zero/signed out. */\n meta?: string;\n}\n\nexport type ServiceOverrides = Record<string, ServiceOverride>;\n\n// ── Group accents — the grid's only color voice ─────────────────────────────\n\n/** Each group owns one hue of the Medialane spectrum (blue → indigo → purple →\n * rose → orange in group order), applied flat: icon-tile tint + glyph, the\n * use-case markers, and the card's resting hairline. On hover-capable\n * devices the full-spectrum gradient ring fades in over the hairline\n * (.ml-grad-hover-border — polish only, never carries information). */\ninterface GroupSlice {\n /** soft icon-tile background */\n tint: string;\n /** icon glyph + use-case marker tint */\n text: string;\n /** resting card hairline in the group's hue */\n border: string;\n}\n\nconst DEFAULT_SLICE: GroupSlice = {\n tint: \"bg-muted/60\",\n text: \"text-muted-foreground/60\",\n border: \"border-border/60\",\n};\n\nexport const GROUP_SLICES: Record<ServiceGroup, GroupSlice> = {\n \"nfts\": { tint: \"bg-brand-blue/10\", text: \"text-brand-blue\", border: \"border-brand-blue/30\" },\n \"limited-editions\": { tint: \"bg-brand-maeve/10\", text: \"text-brand-maeve\", border: \"border-brand-maeve/30\" },\n \"coins\": { tint: \"bg-brand-purple/10\", text: \"text-brand-purple\", border: \"border-brand-purple/30\" },\n \"community\": { tint: \"bg-brand-rose/10\", text: \"text-brand-rose\", border: \"border-brand-rose/30\" },\n \"claims\": { tint: \"bg-brand-orange/10\", text: \"text-brand-orange\", border: \"border-brand-orange/30\" },\n \"coming-soon\": DEFAULT_SLICE,\n};\n\n/** Legacy per-service hue table — kept for LaunchpadStrip (homepage). The grid\n * no longer uses it. */\ninterface ServiceHue {\n text: string;\n solid: string;\n border: string;\n tint: string;\n}\n\n/** Brand tokens only ([[brand-tokens-only]]) — one hue per service, drawn from\n * the brand spectrum. */\nexport const SERVICE_HUES: Record<string, ServiceHue> = {\n \"nfts\": { text: \"text-brand-blue\", solid: \"bg-brand-blue\", border: \"border-brand-blue/30\", tint: \"bg-brand-blue/10\" },\n \"limited-editions\": { text: \"text-brand-maeve\", solid: \"bg-brand-maeve\", border: \"border-brand-maeve/30\", tint: \"bg-brand-maeve/10\" },\n \"creator-coins\": { text: \"text-brand-maeve\", solid: \"bg-brand-maeve\", border: \"border-brand-maeve/30\", tint: \"bg-brand-maeve/10\" },\n \"claim-memecoin\": { text: \"text-brand-orange\", solid: \"bg-brand-orange\", border: \"border-brand-orange/30\", tint: \"bg-brand-orange/10\" },\n \"collection-drop\": { text: \"text-brand-purple\", solid: \"bg-brand-purple\", border: \"border-brand-purple/30\", tint: \"bg-brand-purple/10\" },\n \"pop-protocol\": { text: \"text-brand-rose\", solid: \"bg-brand-rose\", border: \"border-brand-rose/30\", tint: \"bg-brand-rose/10\" },\n \"ip-tickets\": { text: \"text-brand-orange\", solid: \"bg-brand-orange\", border: \"border-brand-orange/30\", tint: \"bg-brand-orange/10\" },\n \"remix-asset\": { text: \"text-brand-maeve\", solid: \"bg-brand-maeve\", border: \"border-brand-maeve/30\", tint: \"bg-brand-maeve/10\" },\n \"claim-username\": { text: \"text-brand-purple\", solid: \"bg-brand-purple\", border: \"border-brand-purple/30\", tint: \"bg-brand-purple/10\" },\n \"claim-collection\": { text: \"text-brand-blue\", solid: \"bg-brand-blue\", border: \"border-brand-blue/30\", tint: \"bg-brand-blue/10\" },\n \"claim-collection-name\": { text: \"text-brand-rose\", solid: \"bg-brand-rose\", border: \"border-brand-rose/30\", tint: \"bg-brand-rose/10\" },\n};\n\nconst GROUP_TITLE_BY_KEY = Object.fromEntries(\n LAUNCHPAD_SERVICE_GROUPS.map((g) => [g.key, g.title]),\n) as Record<ServiceGroup, string>;\n\nconst GROUP_KEYS = new Set(LAUNCHPAD_SERVICE_GROUPS.map((g) => g.key));\n\n// ── Service card — one link, one accent, title + one sentence ────────────────\n\nexport interface LaunchpadServiceCardProps {\n def: ServiceDefinition;\n override?: ServiceOverride;\n /** Grid position — drives the staggered entrance reveal. */\n index?: number;\n}\n\nexport function LaunchpadServiceCard({ def, override = {}, index = 0 }: LaunchpadServiceCardProps) {\n const { icon: Icon, title, group, features, cta } = def;\n const status = override.status ?? def.status;\n const blurb = override.blurb ?? def.blurb;\n const { href } = override;\n const reduceMotion = useReducedMotion();\n\n const live = status === \"live\";\n const slice = GROUP_SLICES[group] ?? DEFAULT_SLICE;\n\n const body = (\n <>\n {/* Icon tile + live per-user fact */}\n <div className=\"flex items-start justify-between gap-3\">\n <span className={cn(\"flex h-14 w-14 items-center justify-center rounded-2xl\", live ? slice.tint : \"bg-muted/40\")}>\n <Icon className={cn(\"h-7 w-7\", live ? slice.text : \"text-muted-foreground/50\")} />\n </span>\n {!live ? (\n <span className=\"flex items-center gap-1 text-2xs font-medium text-muted-foreground/60 pt-1\">\n <Lock className=\"h-3 w-3\" />\n Coming soon\n </span>\n ) : override.meta ? (\n <span className=\"text-xs font-semibold tabular-nums px-2.5 py-1 rounded-full bg-muted/50 text-foreground/80\">\n {override.meta}\n </span>\n ) : null}\n </div>\n\n {/* Title + one sentence */}\n <div className=\"mt-auto space-y-2 pt-6\">\n <h3 className=\"text-2xl font-bold tracking-tight leading-tight\">{title}</h3>\n <p className={cn(\"text-sm leading-relaxed\", live ? \"text-muted-foreground\" : \"text-muted-foreground/60\")}>\n {blurb}\n </p>\n </div>\n\n {/* Use cases */}\n {live && features.length > 0 && (\n <ul className=\"space-y-1.5 pt-4\">\n {features.slice(0, 3).map((feature) => (\n <li key={feature} className=\"flex items-start gap-2 text-xs text-muted-foreground leading-relaxed\">\n <Check className={cn(\"h-3.5 w-3.5 shrink-0 mt-px\", slice.text)} />\n {feature}\n </li>\n ))}\n </ul>\n )}\n\n {/* The action — quiet verb, no pill */}\n {live && (\n <div className=\"pt-5\">\n <span className=\"inline-flex items-center gap-1.5 text-sm font-semibold\">\n {cta}\n <ArrowRight className=\"h-4 w-4 transition-transform duration-200 sm:group-hover:translate-x-0.5 motion-reduce:transform-none\" />\n </span>\n </div>\n )}\n </>\n );\n\n return (\n <motion.div\n layout={!reduceMotion}\n initial={{ opacity: 0, y: reduceMotion ? 0 : 16 }}\n animate={{ opacity: 1, y: 0 }}\n exit={{ opacity: 0 }}\n whileTap={live ? { scale: 0.97 } : undefined}\n transition={{ duration: 0.35, delay: index * 0.04, ease: [0.25, 0.46, 0.45, 0.94] }}\n className=\"flex\"\n >\n {live && href ? (\n <Link\n href={href}\n className={cn(\n \"group flex flex-1 flex-col rounded-3xl border bg-card p-6 sm:aspect-[4/5]\",\n \"ml-grad-hover-border\",\n slice.border,\n )}\n >\n {body}\n </Link>\n ) : (\n <div className=\"flex flex-1 flex-col rounded-3xl border border-border/30 bg-card p-6 sm:aspect-[4/5] opacity-75\">\n {body}\n </div>\n )}\n </motion.div>\n );\n}\n\n// ── Coming-soon strip ────────────────────────────────────────────────────────\n\nfunction ComingSoonStrip({ group, defs }: { group: ServiceGroupDefinition; defs: ServiceDefinition[] }) {\n return (\n <div className=\"rounded-2xl border border-border/40 p-5\">\n <p className=\"font-semibold text-sm\">{group.title}</p>\n <p className=\"text-sm text-muted-foreground mt-0.5\">{group.tagline}</p>\n <div className=\"flex flex-wrap gap-2 mt-4\">\n {defs.map(({ key, icon: Icon, title }) => (\n <div key={key} className=\"flex items-center gap-2 px-3 py-2 rounded-full bg-muted/30 border border-border/25\">\n <Icon className=\"h-3.5 w-3.5 text-muted-foreground/60\" />\n <span className=\"text-xs font-medium text-muted-foreground\">{title}</span>\n </div>\n ))}\n </div>\n </div>\n );\n}\n\n// ── Filter state ─────────────────────────────────────────────────────────────\n\n/** Shared search predicate — group titles count as search terms so a query\n * like \"editions\" or \"community\" finds the whole group. */\nexport function serviceMatchesQuery(def: ServiceDefinition, query: string): boolean {\n if (query.trim() === \"\") return true;\n const haystack = `${def.title} ${def.blurb} ${def.subtitle} ${GROUP_TITLE_BY_KEY[def.group] ?? \"\"}`.toLowerCase();\n return haystack.includes(query.trim().toLowerCase());\n}\n\n/** Sync filter state into the URL (?q=…&groups=…) via replaceState — the\n * filtered launchpad becomes shareable and survives reload, without touching\n * the router (this package is router-agnostic). */\nfunction syncFilterUrl(query: string, groups: Set<ServiceGroup>) {\n if (typeof window === \"undefined\") return;\n const params = new URLSearchParams(window.location.search);\n if (query.trim()) params.set(\"q\", query.trim());\n else params.delete(\"q\");\n if (groups.size > 0) params.set(\"groups\", [...groups].join(\",\"));\n else params.delete(\"groups\");\n const qs = params.toString();\n window.history.replaceState(null, \"\", qs ? `${window.location.pathname}?${qs}` : window.location.pathname);\n}\n\n/**\n * Owns the search + group-filter state for the launchpad page. A page renders\n * `LaunchpadFilterBar` wherever it wants (e.g. right under the h1) wired to\n * this hook's fields, then passes `query`/`activeGroups` straight through to\n * `LaunchpadGroupedSections` so the grid reacts to the same state.\n * State is mirrored into the URL (?q=…&groups=…) so a filtered view can be\n * shared and survives reload.\n */\nexport function useLaunchpadFilter() {\n const [query, setQueryState] = useState(\"\");\n const [activeGroups, setActiveGroups] = useState<Set<ServiceGroup>>(new Set());\n\n // Hydrate once from the URL (client only).\n useEffect(() => {\n const params = new URLSearchParams(window.location.search);\n const q = params.get(\"q\");\n if (q) setQueryState(q);\n const g = params.get(\"groups\");\n if (g) {\n const groups = g.split(\",\").filter((k): k is ServiceGroup => GROUP_KEYS.has(k as ServiceGroup));\n if (groups.length > 0) setActiveGroups(new Set(groups));\n }\n }, []);\n\n const filterableGroups = LAUNCHPAD_SERVICE_GROUPS.filter((g) => g.key !== \"coming-soon\");\n\n const setQuery = (value: string) => {\n setQueryState(value);\n syncFilterUrl(value, activeGroups);\n };\n\n const toggleGroup = (key: ServiceGroup) => {\n setActiveGroups((prev) => {\n const next = new Set(prev);\n if (next.has(key)) next.delete(key);\n else next.add(key);\n syncFilterUrl(query, next);\n return next;\n });\n };\n\n const matches = (def: ServiceDefinition): boolean => {\n if (activeGroups.size > 0 && !activeGroups.has(def.group)) return false;\n if (def.status !== \"live\") return false;\n return serviceMatchesQuery(def, query);\n };\n\n const totalMatches = useMemo(\n () => LAUNCHPAD_SERVICE_DEFINITIONS.filter(matches).length,\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [query, activeGroups],\n );\n\n const clear = () => {\n setQueryState(\"\");\n setActiveGroups(new Set());\n syncFilterUrl(\"\", new Set());\n };\n\n return { query, setQuery, activeGroups, toggleGroup, filterableGroups, totalMatches, clear };\n}\n\n// ── The grid ─────────────────────────────────────────────────────────────────\n\nexport interface LaunchpadGroupedSectionsProps {\n /** Per-app hrefs / rollout flips, keyed by service key. */\n overrides: ServiceOverrides;\n /** Current search query — from `useLaunchpadFilter()`. */\n query: string;\n /** Current active group filters — from `useLaunchpadFilter()`. */\n activeGroups: Set<ServiceGroup>;\n /** Reset both — from `useLaunchpadFilter()`. */\n onClearFilters: () => void;\n className?: string;\n}\n\n/** The full launchpad services grid — one dynamic grid of all live services,\n * ordered by group, plus the coming-soon strip. Fully controlled by\n * `useLaunchpadFilter()` state passed in from the page. */\nexport function LaunchpadGroupedSections({ overrides, query, activeGroups, onClearFilters, className }: LaunchpadGroupedSectionsProps) {\n const inActiveGroup = (d: ServiceDefinition) => activeGroups.size === 0 || activeGroups.has(d.group);\n const inSearch = (d: ServiceDefinition) => serviceMatchesQuery(d, query);\n\n const groupOrder = Object.fromEntries(LAUNCHPAD_SERVICE_GROUPS.map((g, i) => [g.key, i]));\n\n const liveDefs = LAUNCHPAD_SERVICE_DEFINITIONS\n .filter((d) => d.group !== \"coming-soon\" && d.status === \"live\" && inActiveGroup(d) && inSearch(d))\n .sort((a, b) => (groupOrder[a.group] ?? 99) - (groupOrder[b.group] ?? 99));\n\n const comingSoonGroup = LAUNCHPAD_SERVICE_GROUPS.find((g) => g.key === \"coming-soon\");\n const comingSoonDefs = LAUNCHPAD_SERVICE_DEFINITIONS.filter(\n (d) => d.group === \"coming-soon\" && inActiveGroup(d) && inSearch(d),\n );\n\n return (\n <div className={cn(\"space-y-8\", className)}>\n {liveDefs.length === 0 && comingSoonDefs.length === 0 ? (\n <div className=\"text-center py-16 space-y-3\">\n <p className=\"text-lg font-semibold\">No services match</p>\n <p className=\"text-sm text-muted-foreground\">Try a different search or clear your filters.</p>\n <button\n type=\"button\"\n onClick={onClearFilters}\n className=\"inline-flex items-center h-9 px-4 rounded-full text-sm font-semibold bg-primary text-primary-foreground\"\n >\n Clear filters\n </button>\n </div>\n ) : (\n <>\n <motion.div layout className=\"grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 xl:grid-cols-4 gap-5 sm:gap-6\">\n <AnimatePresence mode=\"popLayout\">\n {liveDefs.map((def, i) => (\n <LaunchpadServiceCard key={def.key} def={def} override={overrides[def.key]} index={i} />\n ))}\n </AnimatePresence>\n </motion.div>\n {comingSoonGroup && comingSoonDefs.length > 0 && (\n <ComingSoonStrip group={comingSoonGroup} defs={comingSoonDefs} />\n )}\n </>\n )}\n </div>\n );\n}\n"],"mappings":";AAuII,mBAIM,KAGA,YAPN;AAlHJ,SAAS,WAAW,SAAS,gBAAgB;AAC7C,OAAO,UAAU;AACjB,SAAS,iBAAiB,QAAQ,wBAAwB;AAC1D,SAAS,MAAM,YAAY,aAAa;AACxC,SAAS,UAAU;AACnB;AAAA,EACE;AAAA,EACA;AAAA,OAKK;AAoCP,MAAM,gBAA4B;AAAA,EAChC,MAAM;AAAA,EACN,MAAM;AAAA,EACN,QAAQ;AACV;AAEO,MAAM,eAAiD;AAAA,EAC5D,QAAQ,EAAE,MAAM,oBAAoB,MAAM,mBAAmB,QAAQ,uBAAuB;AAAA,EAC5F,oBAAoB,EAAE,MAAM,qBAAqB,MAAM,oBAAoB,QAAQ,wBAAwB;AAAA,EAC3G,SAAS,EAAE,MAAM,sBAAsB,MAAM,qBAAqB,QAAQ,yBAAyB;AAAA,EACnG,aAAa,EAAE,MAAM,oBAAoB,MAAM,mBAAmB,QAAQ,uBAAuB;AAAA,EACjG,UAAU,EAAE,MAAM,sBAAsB,MAAM,qBAAqB,QAAQ,yBAAyB;AAAA,EACpG,eAAe;AACjB;AAaO,MAAM,eAA2C;AAAA,EACtD,QAAQ,EAAE,MAAM,mBAAmB,OAAO,iBAAiB,QAAQ,wBAAwB,MAAM,mBAAmB;AAAA,EACpH,oBAAoB,EAAE,MAAM,oBAAoB,OAAO,kBAAkB,QAAQ,yBAAyB,MAAM,oBAAoB;AAAA,EACpI,iBAAiB,EAAE,MAAM,oBAAoB,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AiB;AAAA,IACtD,oBAAC,OAAE,WAAU,iCAAgC,2DAA6C;AAAA,IAC1F;AAAA,MAAC;AAAA;AAAA,QACC,MAAK;AAAA,QACL,SAAS;AAAA,QACT,WAAU;AAAA,QACX;AAAA;AAAA,IAED;AAAA,KACF,IAEA,iCACE;AAAA,wBAAC,OAAO,KAAP,EAAW,QAAM,MAAC,WAAU,gFAC3B,8BAAC,mBAAgB,MAAK,aACnB,mBAAS,IAAI,CAAC,KAAK,MAClB,oBAAC,wBAAmC,KAAU,UAAU,UAAU,IAAI,GAAG,GAAG,OAAO,KAAxD,IAAI,GAAuD,CACvF,GACH,GACF;AAAA,IACC,mBAAmB,eAAe,SAAS,KAC1C,oBAAC,mBAAgB,OAAO,iBAAiB,MAAM,gBAAgB;AAAA,KAEnE,GAEJ;AAEJ;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../../src/components/launchpad-services.tsx"],"sourcesContent":["\"use client\";\n\nimport { useEffect, useMemo, useState } from \"react\";\nimport Link from \"next/link\";\nimport { AnimatePresence, motion, useReducedMotion } from \"framer-motion\";\nimport { Lock, ArrowRight, Check } from \"lucide-react\";\nimport { cn } from \"../utils/cn.js\";\nimport {\n LAUNCHPAD_SERVICE_DEFINITIONS,\n LAUNCHPAD_SERVICE_GROUPS,\n type ServiceDefinition,\n type ServiceGroup,\n type ServiceGroupDefinition,\n type ServiceStatus,\n} from \"../data/launchpad-services.js\";\n\nexport interface ServiceOverride {\n\n href?: string;\n\n browseHref?: string;\n\n status?: ServiceStatus;\n\n blurb?: string;\n\n meta?: string;\n}\n\nexport type ServiceOverrides = Record<string, ServiceOverride>;\n\ninterface GroupSlice {\n\n tint: string;\n\n text: string;\n\n border: string;\n}\n\nconst DEFAULT_SLICE: GroupSlice = {\n tint: \"bg-muted/60\",\n text: \"text-muted-foreground/60\",\n border: \"border-border/60\",\n};\n\nexport const GROUP_SLICES: Record<ServiceGroup, GroupSlice> = {\n \"nfts\": { tint: \"bg-brand-blue/10\", text: \"text-brand-blue\", border: \"border-brand-blue/30\" },\n \"limited-editions\": { tint: \"bg-brand-maeve/10\", text: \"text-brand-maeve\", border: \"border-brand-maeve/30\" },\n \"coins\": { tint: \"bg-brand-purple/10\", text: \"text-brand-purple\", border: \"border-brand-purple/30\" },\n \"community\": { tint: \"bg-brand-rose/10\", text: \"text-brand-rose\", border: \"border-brand-rose/30\" },\n \"claims\": { tint: \"bg-brand-orange/10\", text: \"text-brand-orange\", border: \"border-brand-orange/30\" },\n \"coming-soon\": DEFAULT_SLICE,\n};\n\ninterface ServiceHue {\n text: string;\n solid: string;\n border: string;\n tint: string;\n}\n\nexport const SERVICE_HUES: Record<string, ServiceHue> = {\n \"nfts\": { text: \"text-brand-blue\", solid: \"bg-brand-blue\", border: \"border-brand-blue/30\", tint: \"bg-brand-blue/10\" },\n \"limited-editions\": { text: \"text-brand-maeve\", solid: \"bg-brand-maeve\", border: \"border-brand-maeve/30\", tint: \"bg-brand-maeve/10\" },\n \"creator-coins\": { text: \"text-brand-maeve\", solid: \"bg-brand-maeve\", border: \"border-brand-maeve/30\", tint: \"bg-brand-maeve/10\" },\n \"claim-memecoin\": { text: \"text-brand-orange\", solid: \"bg-brand-orange\", border: \"border-brand-orange/30\", tint: \"bg-brand-orange/10\" },\n \"collection-drop\": { text: \"text-brand-purple\", solid: \"bg-brand-purple\", border: \"border-brand-purple/30\", tint: \"bg-brand-purple/10\" },\n \"pop-protocol\": { text: \"text-brand-rose\", solid: \"bg-brand-rose\", border: \"border-brand-rose/30\", tint: \"bg-brand-rose/10\" },\n \"ip-tickets\": { text: \"text-brand-orange\", solid: \"bg-brand-orange\", border: \"border-brand-orange/30\", tint: \"bg-brand-orange/10\" },\n \"remix-asset\": { text: \"text-brand-maeve\", solid: \"bg-brand-maeve\", border: \"border-brand-maeve/30\", tint: \"bg-brand-maeve/10\" },\n \"claim-username\": { text: \"text-brand-purple\", solid: \"bg-brand-purple\", border: \"border-brand-purple/30\", tint: \"bg-brand-purple/10\" },\n \"claim-collection\": { text: \"text-brand-blue\", solid: \"bg-brand-blue\", border: \"border-brand-blue/30\", tint: \"bg-brand-blue/10\" },\n \"claim-collection-name\": { text: \"text-brand-rose\", solid: \"bg-brand-rose\", border: \"border-brand-rose/30\", tint: \"bg-brand-rose/10\" },\n};\n\nconst GROUP_TITLE_BY_KEY = Object.fromEntries(\n LAUNCHPAD_SERVICE_GROUPS.map((g) => [g.key, g.title]),\n) as Record<ServiceGroup, string>;\n\nconst GROUP_KEYS = new Set(LAUNCHPAD_SERVICE_GROUPS.map((g) => g.key));\n\nexport interface LaunchpadServiceCardProps {\n def: ServiceDefinition;\n override?: ServiceOverride;\n\n index?: number;\n}\n\nexport function LaunchpadServiceCard({ def, override = {}, index = 0 }: LaunchpadServiceCardProps) {\n const { icon: Icon, title, group, features, cta } = def;\n const status = override.status ?? def.status;\n const blurb = override.blurb ?? def.blurb;\n const { href } = override;\n const reduceMotion = useReducedMotion();\n\n const live = status === \"live\";\n const slice = GROUP_SLICES[group] ?? DEFAULT_SLICE;\n\n const body = (\n <>\n\n <div className=\"flex items-start justify-between gap-3\">\n <span className={cn(\"flex h-14 w-14 items-center justify-center rounded-2xl\", live ? slice.tint : \"bg-muted/40\")}>\n <Icon className={cn(\"h-7 w-7\", live ? slice.text : \"text-muted-foreground/50\")} />\n </span>\n {!live ? (\n <span className=\"flex items-center gap-1 text-2xs font-medium text-muted-foreground/60 pt-1\">\n <Lock className=\"h-3 w-3\" />\n Coming soon\n </span>\n ) : override.meta ? (\n <span className=\"text-xs font-semibold tabular-nums px-2.5 py-1 rounded-full bg-muted/50 text-foreground/80\">\n {override.meta}\n </span>\n ) : null}\n </div>\n\n <div className=\"mt-auto space-y-2 pt-6\">\n <h3 className=\"text-2xl font-bold tracking-tight leading-tight\">{title}</h3>\n <p className={cn(\"text-sm leading-relaxed\", live ? \"text-muted-foreground\" : \"text-muted-foreground/60\")}>\n {blurb}\n </p>\n </div>\n\n {live && features.length > 0 && (\n <ul className=\"space-y-1.5 pt-4\">\n {features.slice(0, 3).map((feature) => (\n <li key={feature} className=\"flex items-start gap-2 text-xs text-muted-foreground leading-relaxed\">\n <Check className={cn(\"h-3.5 w-3.5 shrink-0 mt-px\", slice.text)} />\n {feature}\n </li>\n ))}\n </ul>\n )}\n\n {live && (\n <div className=\"pt-5\">\n <span className=\"inline-flex items-center gap-1.5 text-sm font-semibold\">\n {cta}\n <ArrowRight className=\"h-4 w-4 transition-transform duration-200 sm:group-hover:translate-x-0.5 motion-reduce:transform-none\" />\n </span>\n </div>\n )}\n </>\n );\n\n return (\n <motion.div\n layout={!reduceMotion}\n initial={{ opacity: 0, y: reduceMotion ? 0 : 16 }}\n animate={{ opacity: 1, y: 0 }}\n exit={{ opacity: 0 }}\n whileTap={live ? { scale: 0.97 } : undefined}\n transition={{ duration: 0.35, delay: index * 0.04, ease: [0.25, 0.46, 0.45, 0.94] }}\n className=\"flex\"\n >\n {live && href ? (\n <Link\n href={href}\n className={cn(\n \"group flex flex-1 flex-col rounded-3xl border bg-card p-6 sm:aspect-[4/5]\",\n \"ml-grad-hover-border\",\n slice.border,\n )}\n >\n {body}\n </Link>\n ) : (\n <div className=\"flex flex-1 flex-col rounded-3xl border border-border/30 bg-card p-6 sm:aspect-[4/5] opacity-75\">\n {body}\n </div>\n )}\n </motion.div>\n );\n}\n\nfunction ComingSoonStrip({ group, defs }: { group: ServiceGroupDefinition; defs: ServiceDefinition[] }) {\n return (\n <div className=\"rounded-2xl border border-border/40 p-5\">\n <p className=\"font-semibold text-sm\">{group.title}</p>\n <p className=\"text-sm text-muted-foreground mt-0.5\">{group.tagline}</p>\n <div className=\"flex flex-wrap gap-2 mt-4\">\n {defs.map(({ key, icon: Icon, title }) => (\n <div key={key} className=\"flex items-center gap-2 px-3 py-2 rounded-full bg-muted/30 border border-border/25\">\n <Icon className=\"h-3.5 w-3.5 text-muted-foreground/60\" />\n <span className=\"text-xs font-medium text-muted-foreground\">{title}</span>\n </div>\n ))}\n </div>\n </div>\n );\n}\n\nexport function serviceMatchesQuery(def: ServiceDefinition, query: string): boolean {\n if (query.trim() === \"\") return true;\n const haystack = `${def.title} ${def.blurb} ${def.subtitle} ${GROUP_TITLE_BY_KEY[def.group] ?? \"\"}`.toLowerCase();\n return haystack.includes(query.trim().toLowerCase());\n}\n\nfunction syncFilterUrl(query: string, groups: Set<ServiceGroup>) {\n if (typeof window === \"undefined\") return;\n const params = new URLSearchParams(window.location.search);\n if (query.trim()) params.set(\"q\", query.trim());\n else params.delete(\"q\");\n if (groups.size > 0) params.set(\"groups\", [...groups].join(\",\"));\n else params.delete(\"groups\");\n const qs = params.toString();\n window.history.replaceState(null, \"\", qs ? `${window.location.pathname}?${qs}` : window.location.pathname);\n}\n\nexport function useLaunchpadFilter() {\n const [query, setQueryState] = useState(\"\");\n const [activeGroups, setActiveGroups] = useState<Set<ServiceGroup>>(new Set());\n\n useEffect(() => {\n const params = new URLSearchParams(window.location.search);\n const q = params.get(\"q\");\n if (q) setQueryState(q);\n const g = params.get(\"groups\");\n if (g) {\n const groups = g.split(\",\").filter((k): k is ServiceGroup => GROUP_KEYS.has(k as ServiceGroup));\n if (groups.length > 0) setActiveGroups(new Set(groups));\n }\n }, []);\n\n const filterableGroups = LAUNCHPAD_SERVICE_GROUPS.filter((g) => g.key !== \"coming-soon\");\n\n const setQuery = (value: string) => {\n setQueryState(value);\n syncFilterUrl(value, activeGroups);\n };\n\n const toggleGroup = (key: ServiceGroup) => {\n setActiveGroups((prev) => {\n const next = new Set(prev);\n if (next.has(key)) next.delete(key);\n else next.add(key);\n syncFilterUrl(query, next);\n return next;\n });\n };\n\n const matches = (def: ServiceDefinition): boolean => {\n if (activeGroups.size > 0 && !activeGroups.has(def.group)) return false;\n if (def.status !== \"live\") return false;\n return serviceMatchesQuery(def, query);\n };\n\n const totalMatches = useMemo(\n () => LAUNCHPAD_SERVICE_DEFINITIONS.filter(matches).length,\n\n [query, activeGroups],\n );\n\n const clear = () => {\n setQueryState(\"\");\n setActiveGroups(new Set());\n syncFilterUrl(\"\", new Set());\n };\n\n return { query, setQuery, activeGroups, toggleGroup, filterableGroups, totalMatches, clear };\n}\n\nexport interface LaunchpadGroupedSectionsProps {\n\n overrides: ServiceOverrides;\n\n query: string;\n\n activeGroups: Set<ServiceGroup>;\n\n onClearFilters: () => void;\n className?: string;\n}\n\nexport function LaunchpadGroupedSections({ overrides, query, activeGroups, onClearFilters, className }: LaunchpadGroupedSectionsProps) {\n const inActiveGroup = (d: ServiceDefinition) => activeGroups.size === 0 || activeGroups.has(d.group);\n const inSearch = (d: ServiceDefinition) => serviceMatchesQuery(d, query);\n\n const groupOrder = Object.fromEntries(LAUNCHPAD_SERVICE_GROUPS.map((g, i) => [g.key, i]));\n\n const liveDefs = LAUNCHPAD_SERVICE_DEFINITIONS\n .filter((d) => d.group !== \"coming-soon\" && d.status === \"live\" && inActiveGroup(d) && inSearch(d))\n .sort((a, b) => (groupOrder[a.group] ?? 99) - (groupOrder[b.group] ?? 99));\n\n const comingSoonGroup = LAUNCHPAD_SERVICE_GROUPS.find((g) => g.key === \"coming-soon\");\n const comingSoonDefs = LAUNCHPAD_SERVICE_DEFINITIONS.filter(\n (d) => d.group === \"coming-soon\" && inActiveGroup(d) && inSearch(d),\n );\n\n return (\n <div className={cn(\"space-y-8\", className)}>\n {liveDefs.length === 0 && comingSoonDefs.length === 0 ? (\n <div className=\"text-center py-16 space-y-3\">\n <p className=\"text-lg font-semibold\">No services match</p>\n <p className=\"text-sm text-muted-foreground\">Try a different search or clear your filters.</p>\n <button\n type=\"button\"\n onClick={onClearFilters}\n className=\"inline-flex items-center h-9 px-4 rounded-full text-sm font-semibold bg-primary text-primary-foreground\"\n >\n Clear filters\n </button>\n </div>\n ) : (\n <>\n <motion.div layout className=\"grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 xl:grid-cols-4 gap-5 sm:gap-6\">\n <AnimatePresence mode=\"popLayout\">\n {liveDefs.map((def, i) => (\n <LaunchpadServiceCard key={def.key} def={def} override={overrides[def.key]} index={i} />\n ))}\n </AnimatePresence>\n </motion.div>\n {comingSoonGroup && comingSoonDefs.length > 0 && (\n <ComingSoonStrip group={comingSoonGroup} defs={comingSoonDefs} />\n )}\n </>\n )}\n </div>\n );\n}\n"],"mappings":";AAoGI,mBAIM,KAGA,YAPN;AAlGJ,SAAS,WAAW,SAAS,gBAAgB;AAC7C,OAAO,UAAU;AACjB,SAAS,iBAAiB,QAAQ,wBAAwB;AAC1D,SAAS,MAAM,YAAY,aAAa;AACxC,SAAS,UAAU;AACnB;AAAA,EACE;AAAA,EACA;AAAA,OAKK;AA0BP,MAAM,gBAA4B;AAAA,EAChC,MAAM;AAAA,EACN,MAAM;AAAA,EACN,QAAQ;AACV;AAEO,MAAM,eAAiD;AAAA,EAC5D,QAAQ,EAAE,MAAM,oBAAoB,MAAM,mBAAmB,QAAQ,uBAAuB;AAAA,EAC5F,oBAAoB,EAAE,MAAM,qBAAqB,MAAM,oBAAoB,QAAQ,wBAAwB;AAAA,EAC3G,SAAS,EAAE,MAAM,sBAAsB,MAAM,qBAAqB,QAAQ,yBAAyB;AAAA,EACnG,aAAa,EAAE,MAAM,oBAAoB,MAAM,mBAAmB,QAAQ,uBAAuB;AAAA,EACjG,UAAU,EAAE,MAAM,sBAAsB,MAAM,qBAAqB,QAAQ,yBAAyB;AAAA,EACpG,eAAe;AACjB;AASO,MAAM,eAA2C;AAAA,EACtD,QAAQ,EAAE,MAAM,mBAAmB,OAAO,iBAAiB,QAAQ,wBAAwB,MAAM,mBAAmB;AAAA,EACpH,oBAAoB,EAAE,MAAM,oBAAoB,OAAO,kBAAkB,QAAQ,yBAAyB,MAAM,oBAAoB;AAAA,EACpI,iBAAiB,EAAE,MAAM,oBAAoB,OAAO,kBAAkB,QAAQ,yBAAyB,MAAM,oBAAoB;AAAA,EACjI,kBAAkB,EAAE,MAAM,qBAAqB,OAAO,mBAAmB,QAAQ,0BAA0B,MAAM,qBAAqB;AAAA,EACtI,mBAAmB,EAAE,MAAM,qBAAqB,OA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iCACE;AAAA,wBAAC,OAAO,KAAP,EAAW,QAAM,MAAC,WAAU,gFAC3B,8BAAC,mBAAgB,MAAK,aACnB,mBAAS,IAAI,CAAC,KAAK,MAClB,oBAAC,wBAAmC,KAAU,UAAU,UAAU,IAAI,GAAG,GAAG,OAAO,KAAxD,IAAI,GAAuD,CACvF,GACH,GACF;AAAA,IACC,mBAAmB,eAAe,SAAS,KAC1C,oBAAC,mBAAgB,OAAO,iBAAiB,MAAM,gBAAgB;AAAA,KAEnE,GAEJ;AAEJ;","names":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/components/launchpad-strip.tsx"],"sourcesContent":["\"use client\";\n\nimport Link from \"next/link\";\nimport { ShoppingBag, ArrowRight, Rocket } from \"lucide-react\";\nimport type { LucideIcon } from \"lucide-react\";\nimport { ScrollSection } from \"./scroll-section.js\";\nimport { SERVICE_HUES } from \"./launchpad-services.js\";\nimport { LAUNCHPAD_SERVICE_DEFINITIONS } from \"../data/launchpad-services.js\";\nimport { cn } from \"../utils/cn.js\";\n\
|
|
1
|
+
{"version":3,"sources":["../../src/components/launchpad-strip.tsx"],"sourcesContent":["\"use client\";\n\nimport Link from \"next/link\";\nimport { ShoppingBag, ArrowRight, Rocket } from \"lucide-react\";\nimport type { LucideIcon } from \"lucide-react\";\nimport { ScrollSection } from \"./scroll-section.js\";\nimport { SERVICE_HUES } from \"./launchpad-services.js\";\nimport { LAUNCHPAD_SERVICE_DEFINITIONS } from \"../data/launchpad-services.js\";\nimport { cn } from \"../utils/cn.js\";\n\nexport interface LaunchpadStripProps {\n\n hrefs: Record<string, string>;\n\n marketplaceHref?: string;\n\n launchpadHref?: string;\n}\n\ninterface StripCard {\n key: string;\n href: string;\n icon: LucideIcon;\n title: string;\n blurb: string;\n example?: string;\n cta: string;\n hue: { text: string; solid: string; border: string; tint: string };\n}\n\nconst DEF_BY_KEY = Object.fromEntries(LAUNCHPAD_SERVICE_DEFINITIONS.map((d) => [d.key, d]));\n\nconst STRIP_ORDER = [\n \"nfts\",\n \"limited-editions\",\n \"collection-drop\",\n \"pop-protocol\",\n \"ip-tickets\",\n \"creator-coins\",\n];\n\nconst MARKETPLACE_HUE = {\n text: \"text-brand-maeve\",\n solid: \"bg-brand-maeve\",\n border: \"border-brand-maeve/30\",\n tint: \"bg-brand-maeve/10\",\n};\n\nfunction ServiceCard({ card }: { card: StripCard }) {\n const { icon: Icon, title, blurb, example, cta, hue, href } = card;\n return (\n <Link\n href={href}\n className={cn(\n \"relative rounded-2xl border bg-card overflow-hidden flex flex-col h-full min-h-[280px]\",\n \"transition-transform active:scale-[0.99]\",\n hue.border,\n )}\n >\n <div className=\"relative flex flex-col flex-1 p-6 gap-3.5\">\n <span className={cn(\"flex h-11 w-11 items-center justify-center rounded-xl\", hue.tint)}>\n <Icon className={cn(\"h-6 w-6\", hue.text)} />\n </span>\n\n <div className=\"space-y-1.5\">\n <h3 className=\"text-xl font-black tracking-tight leading-snug\">{title}</h3>\n <p className=\"text-sm text-muted-foreground leading-relaxed\">{blurb}</p>\n {example && (\n <p className=\"text-xs text-muted-foreground/70 italic leading-relaxed\">e.g. {example}</p>\n )}\n </div>\n\n <div className=\"mt-auto pt-1 flex justify-end\">\n <span\n className={cn(\n \"inline-flex items-center gap-2 h-9 px-4 rounded-full\",\n \"text-sm font-semibold text-white\",\n hue.solid,\n )}\n >\n {cta}\n <ArrowRight className=\"h-3.5 w-3.5\" />\n </span>\n </div>\n </div>\n </Link>\n );\n}\n\nexport function LaunchpadStrip({\n hrefs,\n marketplaceHref,\n launchpadHref = \"/launchpad\",\n}: LaunchpadStripProps) {\n const cards: StripCard[] = [\n ...STRIP_ORDER.flatMap((key) => {\n const def = DEF_BY_KEY[key];\n const href = hrefs[key];\n if (!def || !href) return [];\n return [{\n key,\n href,\n icon: def.icon,\n title: def.title,\n blurb: def.blurb,\n example: def.example,\n cta: def.cta,\n hue: SERVICE_HUES[key] ?? MARKETPLACE_HUE,\n }];\n }),\n ...(marketplaceHref\n ? [{\n key: \"marketplace\",\n href: marketplaceHref,\n icon: ShoppingBag,\n title: \"Marketplace\",\n blurb: \"Discover and trade works from creators — gasless, instantly settled.\",\n example: \"Buy an art print, make an offer on a music track\",\n cta: \"Browse\",\n hue: MARKETPLACE_HUE,\n }]\n : []),\n ];\n\n return (\n <ScrollSection\n icon={<Rocket className=\"h-3.5 w-3.5 text-white\" />}\n iconBg=\"bg-gradient-to-br from-primary to-blue-600 shadow-md shadow-primary/20\"\n title=\"Launchpad\"\n href={launchpadHref}\n linkLabel=\"Explore\"\n >\n {cards.map((card) => (\n <div key={card.key} className=\"w-64 sm:w-72 snap-start shrink-0 flex\">\n <ServiceCard card={card} />\n </div>\n ))}\n </ScrollSection>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AA6DU;AA3DV,kBAAiB;AACjB,0BAAgD;AAEhD,4BAA8B;AAC9B,gCAA6B;AAC7B,IAAAA,6BAA8C;AAC9C,gBAAmB;AAsBnB,MAAM,aAAa,OAAO,YAAY,yDAA8B,IAAI,CAAC,MAAM,CAAC,EAAE,KAAK,CAAC,CAAC,CAAC;AAE1F,MAAM,cAAc;AAAA,EAClB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEA,MAAM,kBAAkB;AAAA,EACtB,MAAM;AAAA,EACN,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,MAAM;AACR;AAEA,SAAS,YAAY,EAAE,KAAK,GAAwB;AAClD,QAAM,EAAE,MAAM,MAAM,OAAO,OAAO,SAAS,KAAK,KAAK,KAAK,IAAI;AAC9D,SACE;AAAA,IAAC,YAAAC;AAAA,IAAA;AAAA,MACC;AAAA,MACA,eAAW;AAAA,QACT;AAAA,QACA;AAAA,QACA,IAAI;AAAA,MACN;AAAA,MAEA,uDAAC,SAAI,WAAU,6CACb;AAAA,oDAAC,UAAK,eAAW,cAAG,yDAAyD,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AA;AAAA,MACC,MAAM,4CAAC,8BAAO,WAAU,0BAAyB;AAAA,MACjD,QAAO;AAAA,MACP,OAAM;AAAA,MACN,MAAM;AAAA,MACN,WAAU;AAAA,MAET,gBAAM,IAAI,CAAC,SACV,4CAAC,SAAmB,WAAU,yCAC5B,sDAAC,eAAY,MAAY,KADjB,KAAK,GAEf,CACD;AAAA;AAAA,EACH;AAEJ;","names":["import_launchpad_services","Link"]}
|
|
@@ -1,14 +1,8 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
|
|
3
|
-
/** Homepage launchpad strip — cards derive from the shared launchpad service
|
|
4
|
-
* definitions: creator language, one blurb, one example, one vivid verb pill.
|
|
5
|
-
* No tech chips, no long descriptions. Apps inject only hrefs. */
|
|
6
3
|
interface LaunchpadStripProps {
|
|
7
|
-
/** Per-service destinations, keyed by service key. Services without an href are skipped. */
|
|
8
4
|
hrefs: Record<string, string>;
|
|
9
|
-
/** Marketplace card destination (omit to hide the marketplace card) */
|
|
10
5
|
marketplaceHref?: string;
|
|
11
|
-
/** "Explore" header link */
|
|
12
6
|
launchpadHref?: string;
|
|
13
7
|
}
|
|
14
8
|
declare function LaunchpadStrip({ hrefs, marketplaceHref, launchpadHref, }: LaunchpadStripProps): react_jsx_runtime.JSX.Element;
|
|
@@ -1,14 +1,8 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
|
|
3
|
-
/** Homepage launchpad strip — cards derive from the shared launchpad service
|
|
4
|
-
* definitions: creator language, one blurb, one example, one vivid verb pill.
|
|
5
|
-
* No tech chips, no long descriptions. Apps inject only hrefs. */
|
|
6
3
|
interface LaunchpadStripProps {
|
|
7
|
-
/** Per-service destinations, keyed by service key. Services without an href are skipped. */
|
|
8
4
|
hrefs: Record<string, string>;
|
|
9
|
-
/** Marketplace card destination (omit to hide the marketplace card) */
|
|
10
5
|
marketplaceHref?: string;
|
|
11
|
-
/** "Explore" header link */
|
|
12
6
|
launchpadHref?: string;
|
|
13
7
|
}
|
|
14
8
|
declare function LaunchpadStrip({ hrefs, marketplaceHref, launchpadHref, }: LaunchpadStripProps): react_jsx_runtime.JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/components/launchpad-strip.tsx"],"sourcesContent":["\"use client\";\n\nimport Link from \"next/link\";\nimport { ShoppingBag, ArrowRight, Rocket } from \"lucide-react\";\nimport type { LucideIcon } from \"lucide-react\";\nimport { ScrollSection } from \"./scroll-section.js\";\nimport { SERVICE_HUES } from \"./launchpad-services.js\";\nimport { LAUNCHPAD_SERVICE_DEFINITIONS } from \"../data/launchpad-services.js\";\nimport { cn } from \"../utils/cn.js\";\n\
|
|
1
|
+
{"version":3,"sources":["../../src/components/launchpad-strip.tsx"],"sourcesContent":["\"use client\";\n\nimport Link from \"next/link\";\nimport { ShoppingBag, ArrowRight, Rocket } from \"lucide-react\";\nimport type { LucideIcon } from \"lucide-react\";\nimport { ScrollSection } from \"./scroll-section.js\";\nimport { SERVICE_HUES } from \"./launchpad-services.js\";\nimport { LAUNCHPAD_SERVICE_DEFINITIONS } from \"../data/launchpad-services.js\";\nimport { cn } from \"../utils/cn.js\";\n\nexport interface LaunchpadStripProps {\n\n hrefs: Record<string, string>;\n\n marketplaceHref?: string;\n\n launchpadHref?: string;\n}\n\ninterface StripCard {\n key: string;\n href: string;\n icon: LucideIcon;\n title: string;\n blurb: string;\n example?: string;\n cta: string;\n hue: { text: string; solid: string; border: string; tint: string };\n}\n\nconst DEF_BY_KEY = Object.fromEntries(LAUNCHPAD_SERVICE_DEFINITIONS.map((d) => [d.key, d]));\n\nconst STRIP_ORDER = [\n \"nfts\",\n \"limited-editions\",\n \"collection-drop\",\n \"pop-protocol\",\n \"ip-tickets\",\n \"creator-coins\",\n];\n\nconst MARKETPLACE_HUE = {\n text: \"text-brand-maeve\",\n solid: \"bg-brand-maeve\",\n border: \"border-brand-maeve/30\",\n tint: \"bg-brand-maeve/10\",\n};\n\nfunction ServiceCard({ card }: { card: StripCard }) {\n const { icon: Icon, title, blurb, example, cta, hue, href } = card;\n return (\n <Link\n href={href}\n className={cn(\n \"relative rounded-2xl border bg-card overflow-hidden flex flex-col h-full min-h-[280px]\",\n \"transition-transform active:scale-[0.99]\",\n hue.border,\n )}\n >\n <div className=\"relative flex flex-col flex-1 p-6 gap-3.5\">\n <span className={cn(\"flex h-11 w-11 items-center justify-center rounded-xl\", hue.tint)}>\n <Icon className={cn(\"h-6 w-6\", hue.text)} />\n </span>\n\n <div className=\"space-y-1.5\">\n <h3 className=\"text-xl font-black tracking-tight leading-snug\">{title}</h3>\n <p className=\"text-sm text-muted-foreground leading-relaxed\">{blurb}</p>\n {example && (\n <p className=\"text-xs text-muted-foreground/70 italic leading-relaxed\">e.g. {example}</p>\n )}\n </div>\n\n <div className=\"mt-auto pt-1 flex justify-end\">\n <span\n className={cn(\n \"inline-flex items-center gap-2 h-9 px-4 rounded-full\",\n \"text-sm font-semibold text-white\",\n hue.solid,\n )}\n >\n {cta}\n <ArrowRight className=\"h-3.5 w-3.5\" />\n </span>\n </div>\n </div>\n </Link>\n );\n}\n\nexport function LaunchpadStrip({\n hrefs,\n marketplaceHref,\n launchpadHref = \"/launchpad\",\n}: LaunchpadStripProps) {\n const cards: StripCard[] = [\n ...STRIP_ORDER.flatMap((key) => {\n const def = DEF_BY_KEY[key];\n const href = hrefs[key];\n if (!def || !href) return [];\n return [{\n key,\n href,\n icon: def.icon,\n title: def.title,\n blurb: def.blurb,\n example: def.example,\n cta: def.cta,\n hue: SERVICE_HUES[key] ?? MARKETPLACE_HUE,\n }];\n }),\n ...(marketplaceHref\n ? [{\n key: \"marketplace\",\n href: marketplaceHref,\n icon: ShoppingBag,\n title: \"Marketplace\",\n blurb: \"Discover and trade works from creators — gasless, instantly settled.\",\n example: \"Buy an art print, make an offer on a music track\",\n cta: \"Browse\",\n hue: MARKETPLACE_HUE,\n }]\n : []),\n ];\n\n return (\n <ScrollSection\n icon={<Rocket className=\"h-3.5 w-3.5 text-white\" />}\n iconBg=\"bg-gradient-to-br from-primary to-blue-600 shadow-md shadow-primary/20\"\n title=\"Launchpad\"\n href={launchpadHref}\n linkLabel=\"Explore\"\n >\n {cards.map((card) => (\n <div key={card.key} className=\"w-64 sm:w-72 snap-start shrink-0 flex\">\n <ServiceCard card={card} />\n </div>\n ))}\n </ScrollSection>\n );\n}\n"],"mappings":";AA6DU,cAOE,YAPF;AA3DV,OAAO,UAAU;AACjB,SAAS,aAAa,YAAY,cAAc;AAEhD,SAAS,qBAAqB;AAC9B,SAAS,oBAAoB;AAC7B,SAAS,qCAAqC;AAC9C,SAAS,UAAU;AAsBnB,MAAM,aAAa,OAAO,YAAY,8BAA8B,IAAI,CAAC,MAAM,CAAC,EAAE,KAAK,CAAC,CAAC,CAAC;AAE1F,MAAM,cAAc;AAAA,EAClB;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;AAEA,MAAM,kBAAkB;AAAA,EACtB,MAAM;AAAA,EACN,OAAO;AAAA,EACP,QAAQ;AAAA,EACR,MAAM;AACR;AAEA,SAAS,YAAY,EAAE,KAAK,GAAwB;AAClD,QAAM,EAAE,MAAM,MAAM,OAAO,OAAO,SAAS,KAAK,KAAK,KAAK,IAAI;AAC9D,SACE;AAAA,IAAC;AAAA;AAAA,MACC;AAAA,MACA,WAAW;AAAA,QACT;AAAA,QACA;AAAA,QACA,IAAI;AAAA,MACN;AAAA,MAEA,+BAAC,SAAI,WAAU,6CACb;AAAA,4BAAC,UAAK,WAAW,GAAG,yDAAyD,IAAI,IAAI,GACnF,8BAAC,QAAK,WAAW,GAAG,WAAW,IAAI,IAAI,GAAG,GAC5C;AAAA,QAEA,qBAAC,SAAI,WAAU,eACb;AAAA,8BAAC,QAAG,WAAU,kDAAkD,iBAAM;AAAA,UACtE,oBAAC,OAAE,WAAU,iDAAiD,iBAAM;AAAA,UACnE,WACC,qBAAC,OAAE,WAAU,2DAA0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J;","names":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/components/license-terms-builder.tsx"],"sourcesContent":["\"use client\";\n\nimport { cn } from \"../utils/cn.js\";\nimport { CurrencyIcon } from \"./currency-icon.js\";\nimport { LICENSE_TYPES, AI_POLICIES } from \"../data/ip.js\";\n\n/** Duration units — the on-chain `duration` arg is seconds, but nobody\n * should be forced to think in days for a multi-year deal (or forced into\n * days at all — this is declarative, not contract-enforced). */\nexport const DURATION_UNITS = [\"Days\", \"Weeks\", \"Months\", \"Years\"] as const;\nexport type DurationUnit = (typeof DURATION_UNITS)[number];\nconst DURATION_UNIT_DAYS: Record<DurationUnit, number> = { Days: 1, Weeks: 7, Months: 30, Years: 365 };\n\n/** Converts the user-entered value + unit into whole days for the contract's\n * `duration` arg (seconds = days * 86400, done by the caller). */\nexport function toDurationDays(terms: SponsorshipTerms): number {\n const raw = Number(terms.durationValue || \"0\");\n if (!raw || raw <= 0) return 0;\n return Math.round(raw * DURATION_UNIT_DAYS[terms.durationUnit]);\n}\n\n/** Common sponsorship media/channel types — deliberately not part of the\n * general IP taxonomy in `data/ip.ts` (that's about the asset itself;\n * this is about the sponsorship deal's channels), so it stays local here. */\nexport const MEDIA_TYPES = [\n \"Social Media\", \"Video\", \"Photo\", \"Article/Blog\", \"Print\", \"Broadcast\", \"Podcast/Audio\", \"Livestream\",\n] as const;\n\n/**\n * The deal terms a sponsorship offer/proposal needs, in plain-language shape\n * — no bps, no IPFS, no ByteArray. `royaltyPercent` is a plain 0–100 number\n * (multiply by 100 for the contract's basis-points argument). Every field\n * here is declarative metadata carried in the pinned IPFS document (see\n * `toLicenseMetadata`) — the contract never reads any of it, so none of it\n * is enforced beyond the atomic accept-and-mint payment itself. This\n * component only collects and validates the data, it never fetches or\n * uploads anything itself.\n */\nexport interface SponsorshipTerms {\n amount: string;\n paymentTokenSymbol: string;\n /** No default — the user must explicitly set this, never silently inherit one.\n * Paired with `durationUnit`; convert with `toDurationDays()`. */\n durationValue: string;\n durationUnit: DurationUnit;\n transferable: boolean;\n /** Not surfaced in the UI (no resale-royalty concept here) — always \"0\". Kept\n * on the type because `create_offer`/`propose_sponsorship` still take a\n * `royaltyBps` argument. */\n royaltyPercent: string;\n /** Free-text notes that don't fit any structured field below. */\n licenseText: string;\n licenseType: string;\n commercialUse: \"Yes\" | \"No\";\n derivatives: \"Allowed\" | \"Not Allowed\" | \"Share-Alike\";\n attribution: \"Required\" | \"Not Required\";\n /** Free text — \"Worldwide\" is a fine default, but real deals often name a\n * specific country or an exclusion, which a fixed list can't cover. */\n territory: string;\n aiPolicy: string;\n /** e.g. \"Instagram + YouTube only\" — too deal-specific to bound into an enum. */\n scope: string;\n /** e.g. \"3 posts, 1 video\" */\n deliverables: string;\n exclusive: boolean;\n approvalRequired: boolean;\n media: string[];\n mediaOther: string;\n}\n\nexport const EMPTY_SPONSORSHIP_TERMS: SponsorshipTerms = {\n amount: \"\",\n paymentTokenSymbol: \"\",\n durationValue: \"\",\n durationUnit: \"Days\",\n transferable: true,\n royaltyPercent: \"0\",\n licenseText: \"\",\n licenseType: \"CC BY-SA\",\n commercialUse: \"Yes\",\n derivatives: \"Share-Alike\",\n attribution: \"Required\",\n territory: \"Worldwide\",\n aiPolicy: \"Allowed\",\n scope: \"\",\n deliverables: \"\",\n exclusive: false,\n approvalRequired: false,\n media: [],\n mediaOther: \"\",\n};\n\n/** Shapes the pinned-IPFS-JSON payload — the single place both apps build\n * this object, so it can't drift across call sites. Purely additive; the\n * contract never reads any of it. */\nexport function toLicenseMetadata(terms: SponsorshipTerms): Record<string, unknown> {\n return {\n terms: terms.licenseText,\n transferable: terms.transferable,\n royaltyPercent: Number(terms.royaltyPercent || \"0\"),\n licenseType: terms.licenseType,\n commercialUse: terms.commercialUse,\n derivatives: terms.derivatives,\n attribution: terms.attribution,\n territory: terms.territory,\n aiPolicy: terms.aiPolicy,\n scope: terms.scope,\n deliverables: terms.deliverables,\n exclusive: terms.exclusive,\n approvalRequired: terms.approvalRequired,\n media: terms.media,\n mediaOther: terms.mediaOther,\n };\n}\n\nexport interface LicenseTermsBuilderProps {\n value: SponsorshipTerms;\n onChange: (next: SponsorshipTerms) => void;\n /** Payment token symbols to offer — e.g. from SUPPORTED_TOKENS. */\n tokenOptions: string[];\n /** Copy override for the amount field — \"Minimum bid\" for an owner's\n * offer, \"Amount you'll pay\" for a sponsor's proposal. Default: \"Amount\". */\n amountLabel?: string;\n disabled?: boolean;\n className?: string;\n}\n\nconst FIELD_LABEL = \"text-xs font-semibold text-foreground\";\nconst FIELD_HELP = \"text-xs text-muted-foreground\";\nconst INPUT_BASE =\n \"w-full h-10 rounded-xl border border-border bg-card px-3 text-sm placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-brand-purple/40 focus:border-brand-purple/40 disabled:opacity-50\";\n\nfunction ToggleGroup({ value, options, onChange, disabled }: { value: string; options: readonly string[]; onChange: (v: string) => void; disabled?: boolean }) {\n return (\n <div className=\"flex rounded-lg border border-border overflow-hidden w-full\">\n {options.map((opt, i) => (\n <button\n key={opt}\n type=\"button\"\n disabled={disabled}\n onClick={() => onChange(opt)}\n className={cn(\n \"flex-1 px-3 py-2 text-xs sm:text-sm transition-colors disabled:opacity-50\",\n i > 0 && \"border-l border-border\",\n value === opt\n ? \"bg-primary text-primary-foreground font-medium\"\n : \"bg-background hover:bg-muted text-muted-foreground\",\n )}\n >\n {opt}\n </button>\n ))}\n </div>\n );\n}\n\nfunction YesNoToggle({ label, help, checked, onChange, disabled }: { label: string; help: string; checked: boolean; onChange: (v: boolean) => void; disabled?: boolean }) {\n return (\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>{label}</label>\n <ToggleGroup value={checked ? \"Yes\" : \"No\"} options={[\"Yes\", \"No\"]} onChange={(v) => onChange(v === \"Yes\")} disabled={disabled} />\n <p className={FIELD_HELP}>{help}</p>\n </div>\n );\n}\n\nexport function LicenseTermsBuilder({\n value, onChange, tokenOptions, amountLabel = \"Amount\", disabled, className,\n}: LicenseTermsBuilderProps) {\n const set = <K extends keyof SponsorshipTerms>(key: K, v: SponsorshipTerms[K]) =>\n onChange({ ...value, [key]: v });\n\n const handleLicenseTypeChange = (licenseType: string) => {\n const def = LICENSE_TYPES.find((l) => l.value === licenseType);\n onChange({\n ...value,\n licenseType,\n ...(def ? { commercialUse: def.commercialUse, derivatives: def.derivatives, attribution: def.attribution } : {}),\n });\n };\n\n const selectedLicense = LICENSE_TYPES.find((l) => l.value === value.licenseType);\n const toggleMedia = (m: string) => {\n const next = value.media.includes(m) ? value.media.filter((x) => x !== m) : [...value.media, m];\n set(\"media\", next);\n };\n\n return (\n <div className={cn(\"space-y-4\", className)}>\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>{amountLabel}</label>\n <input\n type=\"number\"\n min={0}\n step=\"0.01\"\n inputMode=\"decimal\"\n disabled={disabled}\n value={value.amount}\n onChange={(e) => set(\"amount\", e.target.value)}\n placeholder=\"0.00\"\n className={INPUT_BASE}\n />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Currency</label>\n <div className=\"grid grid-cols-3 sm:grid-cols-5 gap-1.5\">\n {tokenOptions.map((symbol) => (\n <button\n key={symbol}\n type=\"button\"\n disabled={disabled}\n onClick={() => set(\"paymentTokenSymbol\", symbol)}\n aria-pressed={value.paymentTokenSymbol === symbol}\n className={cn(\n \"h-10 px-2 rounded-xl border text-xs font-semibold flex items-center justify-center gap-1.5 transition-colors disabled:opacity-50\",\n value.paymentTokenSymbol === symbol\n ? \"border-brand-purple bg-brand-purple/10 text-foreground\"\n : \"border-border bg-card text-muted-foreground hover:text-foreground\",\n )}\n >\n <CurrencyIcon symbol={symbol} size={14} />\n {symbol}\n </button>\n ))}\n </div>\n </div>\n\n <label className=\"flex items-start gap-2.5 cursor-pointer select-none\">\n <input\n type=\"checkbox\"\n disabled={disabled}\n checked={value.transferable}\n onChange={(e) => set(\"transferable\", e.target.checked)}\n className=\"mt-0.5 h-4 w-4 rounded border-border text-brand-purple focus:ring-brand-purple/40\"\n />\n <span className=\"text-sm\">\n <span className=\"font-medium\">Sponsor can resell this license</span>\n <span className={cn(FIELD_HELP, \"block\")}>Off means it's meant to stay with the sponsor who accepts it — resale still isn't blocked on-chain, this is just the stated intent.</span>\n </span>\n </label>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>License length</label>\n <div className=\"grid grid-cols-[1fr_auto] gap-2\">\n <input\n type=\"number\"\n min={1}\n disabled={disabled}\n value={value.durationValue}\n onChange={(e) => set(\"durationValue\", e.target.value)}\n placeholder=\"e.g. 30\"\n className={INPUT_BASE}\n />\n <select\n disabled={disabled}\n value={value.durationUnit}\n onChange={(e) => set(\"durationUnit\", e.target.value as DurationUnit)}\n className={cn(INPUT_BASE, \"w-28\")}\n >\n {DURATION_UNITS.map((u) => (\n <option key={u} value={u}>{u}</option>\n ))}\n </select>\n </div>\n <p className={FIELD_HELP}>Counted from the moment the deal is accepted, not from today.</p>\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>License type</label>\n <select\n disabled={disabled}\n value={value.licenseType}\n onChange={(e) => handleLicenseTypeChange(e.target.value)}\n className={INPUT_BASE}\n >\n {LICENSE_TYPES.map((l) => (\n <option key={l.value} value={l.value}>{l.label}</option>\n ))}\n </select>\n {selectedLicense ? <p className={FIELD_HELP}>{selectedLicense.description}</p> : null}\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Commercial use</label>\n <ToggleGroup value={value.commercialUse} options={[\"Yes\", \"No\"]} onChange={(v) => set(\"commercialUse\", v as SponsorshipTerms[\"commercialUse\"])} disabled={disabled} />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Derivatives</label>\n <ToggleGroup value={value.derivatives} options={[\"Allowed\", \"Not Allowed\", \"Share-Alike\"]} onChange={(v) => set(\"derivatives\", v as SponsorshipTerms[\"derivatives\"])} disabled={disabled} />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Attribution</label>\n <ToggleGroup value={value.attribution} options={[\"Required\", \"Not Required\"]} onChange={(v) => set(\"attribution\", v as SponsorshipTerms[\"attribution\"])} disabled={disabled} />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Territory <span className=\"font-normal text-muted-foreground\">(optional)</span></label>\n <input\n type=\"text\"\n disabled={disabled}\n value={value.territory}\n onChange={(e) => set(\"territory\", e.target.value)}\n placeholder=\"e.g. Worldwide, Brazil only, excluding China\"\n className={INPUT_BASE}\n />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>AI policy</label>\n <select\n disabled={disabled}\n value={value.aiPolicy}\n onChange={(e) => set(\"aiPolicy\", e.target.value)}\n className={INPUT_BASE}\n >\n {AI_POLICIES.map((p) => (\n <option key={p} value={p}>{p}</option>\n ))}\n </select>\n <p className={FIELD_HELP}>Whether this work can be used to train AI models.</p>\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Scope <span className=\"font-normal text-muted-foreground\">(optional)</span></label>\n <input\n type=\"text\"\n disabled={disabled}\n value={value.scope}\n onChange={(e) => set(\"scope\", e.target.value)}\n placeholder=\"e.g. Instagram + YouTube only\"\n className={INPUT_BASE}\n />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Deliverables <span className=\"font-normal text-muted-foreground\">(optional)</span></label>\n <textarea\n disabled={disabled}\n value={value.deliverables}\n onChange={(e) => set(\"deliverables\", e.target.value)}\n placeholder=\"e.g. 3 posts, 1 video\"\n rows={2}\n className={cn(INPUT_BASE, \"h-auto py-2.5 resize-y\")}\n />\n </div>\n\n <YesNoToggle\n label=\"Exclusive to this sponsor\"\n help=\"No other sponsors during the license term.\"\n checked={value.exclusive}\n onChange={(v) => set(\"exclusive\", v)}\n disabled={disabled}\n />\n\n <YesNoToggle\n label=\"Content approval required\"\n help=\"Sponsor reviews content before it's published.\"\n checked={value.approvalRequired}\n onChange={(v) => set(\"approvalRequired\", v)}\n disabled={disabled}\n />\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Media <span className=\"font-normal text-muted-foreground\">(optional)</span></label>\n <div className=\"flex flex-wrap gap-1.5\">\n {MEDIA_TYPES.map((m) => (\n <button\n key={m}\n type=\"button\"\n disabled={disabled}\n onClick={() => toggleMedia(m)}\n className={cn(\n \"h-8 px-2.5 rounded-full border text-xs font-medium transition-colors disabled:opacity-50\",\n value.media.includes(m)\n ? \"border-brand-purple bg-brand-purple/10 text-foreground\"\n : \"border-border bg-card text-muted-foreground hover:text-foreground\",\n )}\n >\n {m}\n </button>\n ))}\n </div>\n <input\n type=\"text\"\n disabled={disabled}\n value={value.mediaOther}\n onChange={(e) => set(\"mediaOther\", e.target.value)}\n placeholder=\"Other media type\"\n className={cn(INPUT_BASE, \"mt-1.5\")}\n />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Additional terms <span className=\"font-normal text-muted-foreground\">(optional)</span></label>\n <textarea\n disabled={disabled}\n value={value.licenseText}\n onChange={(e) => set(\"licenseText\", e.target.value)}\n placeholder=\"Anything else worth spelling out.\"\n rows={3}\n className={cn(INPUT_BASE, \"h-auto py-2.5 resize-y\")}\n />\n <p className={FIELD_HELP}>Saved permanently and shown to anyone who holds the license.</p>\n </div>\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAwIQ;AAtIR,gBAAmB;AACnB,2BAA6B;AAC7B,gBAA2C;AAKpC,MAAM,iBAAiB,CAAC,QAAQ,SAAS,UAAU,OAAO;AAEjE,MAAM,qBAAmD,EAAE,MAAM,GAAG,OAAO,GAAG,QAAQ,IAAI,OAAO,IAAI;AAI9F,SAAS,eAAe,OAAiC;AAC9D,QAAM,MAAM,OAAO,MAAM,iBAAiB,GAAG;AAC7C,MAAI,CAAC,OAAO,OAAO,EA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,MAAM,YAAY,CAAC;AAAA,UAC5B,eAAW;AAAA,YACT;AAAA,YACA,MAAM,MAAM,SAAS,CAAC,IAClB,2DACA;AAAA,UACN;AAAA,UAEC;AAAA;AAAA,QAXI;AAAA,MAYP,CACD,GACH;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,MAAK;AAAA,UACL;AAAA,UACA,OAAO,MAAM;AAAA,UACb,UAAU,CAAC,MAAM,IAAI,cAAc,EAAE,OAAO,KAAK;AAAA,UACjD,aAAY;AAAA,UACZ,eAAW,cAAG,YAAY,QAAQ;AAAA;AAAA,MACpC;AAAA,OACF;AAAA,IAEA,6CAAC,SAAI,WAAU,eACb;AAAA,mDAAC,WAAM,WAAW,aAAa;AAAA;AAAA,QAAiB,4CAAC,UAAK,WAAU,qCAAoC,wBAAU;AAAA,SAAO;AAAA,MACrH;AAAA,QAAC;AAAA;AAAA,UACC;AAAA,UACA,OAAO,MAAM;AAAA,UACb,UAAU,CAAC,MAAM,IAAI,eAAe,EAAE,OAAO,KAAK;AAAA,UAClD,aAAY;AAAA,UACZ,MAAM;AAAA,UACN,eAAW,cAAG,YAAY,wBAAwB;AAAA;AAAA,MACpD;AAAA,MACA,4CAAC,OAAE,WAAW,YAAY,0EAA4D;AAAA,OACxF;AAAA,KACF;AAEJ;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../../src/components/license-terms-builder.tsx"],"sourcesContent":["\"use client\";\n\nimport { cn } from \"../utils/cn.js\";\nimport { CurrencyIcon } from \"./currency-icon.js\";\nimport { LICENSE_TYPES, AI_POLICIES } from \"../data/ip.js\";\n\nexport const DURATION_UNITS = [\"Days\", \"Weeks\", \"Months\", \"Years\"] as const;\nexport type DurationUnit = (typeof DURATION_UNITS)[number];\nconst DURATION_UNIT_DAYS: Record<DurationUnit, number> = { Days: 1, Weeks: 7, Months: 30, Years: 365 };\n\nexport function toDurationDays(terms: SponsorshipTerms): number {\n const raw = Number(terms.durationValue || \"0\");\n if (!raw || raw <= 0) return 0;\n return Math.round(raw * DURATION_UNIT_DAYS[terms.durationUnit]);\n}\n\nexport const MEDIA_TYPES = [\n \"Social Media\", \"Video\", \"Photo\", \"Article/Blog\", \"Print\", \"Broadcast\", \"Podcast/Audio\", \"Livestream\",\n] as const;\n\nexport interface SponsorshipTerms {\n amount: string;\n paymentTokenSymbol: string;\n\n durationValue: string;\n durationUnit: DurationUnit;\n transferable: boolean;\n\n royaltyPercent: string;\n\n licenseText: string;\n licenseType: string;\n commercialUse: \"Yes\" | \"No\";\n derivatives: \"Allowed\" | \"Not Allowed\" | \"Share-Alike\";\n attribution: \"Required\" | \"Not Required\";\n\n territory: string;\n aiPolicy: string;\n\n scope: string;\n\n deliverables: string;\n exclusive: boolean;\n approvalRequired: boolean;\n media: string[];\n mediaOther: string;\n}\n\nexport const EMPTY_SPONSORSHIP_TERMS: SponsorshipTerms = {\n amount: \"\",\n paymentTokenSymbol: \"\",\n durationValue: \"\",\n durationUnit: \"Days\",\n transferable: true,\n royaltyPercent: \"0\",\n licenseText: \"\",\n licenseType: \"CC BY-SA\",\n commercialUse: \"Yes\",\n derivatives: \"Share-Alike\",\n attribution: \"Required\",\n territory: \"Worldwide\",\n aiPolicy: \"Allowed\",\n scope: \"\",\n deliverables: \"\",\n exclusive: false,\n approvalRequired: false,\n media: [],\n mediaOther: \"\",\n};\n\nexport function toLicenseMetadata(terms: SponsorshipTerms): Record<string, unknown> {\n return {\n terms: terms.licenseText,\n transferable: terms.transferable,\n royaltyPercent: Number(terms.royaltyPercent || \"0\"),\n licenseType: terms.licenseType,\n commercialUse: terms.commercialUse,\n derivatives: terms.derivatives,\n attribution: terms.attribution,\n territory: terms.territory,\n aiPolicy: terms.aiPolicy,\n scope: terms.scope,\n deliverables: terms.deliverables,\n exclusive: terms.exclusive,\n approvalRequired: terms.approvalRequired,\n media: terms.media,\n mediaOther: terms.mediaOther,\n };\n}\n\nexport interface LicenseTermsBuilderProps {\n value: SponsorshipTerms;\n onChange: (next: SponsorshipTerms) => void;\n\n tokenOptions: string[];\n\n amountLabel?: string;\n disabled?: boolean;\n className?: string;\n}\n\nconst FIELD_LABEL = \"text-xs font-semibold text-foreground\";\nconst FIELD_HELP = \"text-xs text-muted-foreground\";\nconst INPUT_BASE =\n \"w-full h-10 rounded-xl border border-border bg-card px-3 text-sm placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-brand-purple/40 focus:border-brand-purple/40 disabled:opacity-50\";\n\nfunction ToggleGroup({ value, options, onChange, disabled }: { value: string; options: readonly string[]; onChange: (v: string) => void; disabled?: boolean }) {\n return (\n <div className=\"flex rounded-lg border border-border overflow-hidden w-full\">\n {options.map((opt, i) => (\n <button\n key={opt}\n type=\"button\"\n disabled={disabled}\n onClick={() => onChange(opt)}\n className={cn(\n \"flex-1 px-3 py-2 text-xs sm:text-sm transition-colors disabled:opacity-50\",\n i > 0 && \"border-l border-border\",\n value === opt\n ? \"bg-primary text-primary-foreground font-medium\"\n : \"bg-background hover:bg-muted text-muted-foreground\",\n )}\n >\n {opt}\n </button>\n ))}\n </div>\n );\n}\n\nfunction YesNoToggle({ label, help, checked, onChange, disabled }: { label: string; help: string; checked: boolean; onChange: (v: boolean) => void; disabled?: boolean }) {\n return (\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>{label}</label>\n <ToggleGroup value={checked ? \"Yes\" : \"No\"} options={[\"Yes\", \"No\"]} onChange={(v) => onChange(v === \"Yes\")} disabled={disabled} />\n <p className={FIELD_HELP}>{help}</p>\n </div>\n );\n}\n\nexport function LicenseTermsBuilder({\n value, onChange, tokenOptions, amountLabel = \"Amount\", disabled, className,\n}: LicenseTermsBuilderProps) {\n const set = <K extends keyof SponsorshipTerms>(key: K, v: SponsorshipTerms[K]) =>\n onChange({ ...value, [key]: v });\n\n const handleLicenseTypeChange = (licenseType: string) => {\n const def = LICENSE_TYPES.find((l) => l.value === licenseType);\n onChange({\n ...value,\n licenseType,\n ...(def ? { commercialUse: def.commercialUse, derivatives: def.derivatives, attribution: def.attribution } : {}),\n });\n };\n\n const selectedLicense = LICENSE_TYPES.find((l) => l.value === value.licenseType);\n const toggleMedia = (m: string) => {\n const next = value.media.includes(m) ? value.media.filter((x) => x !== m) : [...value.media, m];\n set(\"media\", next);\n };\n\n return (\n <div className={cn(\"space-y-4\", className)}>\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>{amountLabel}</label>\n <input\n type=\"number\"\n min={0}\n step=\"0.01\"\n inputMode=\"decimal\"\n disabled={disabled}\n value={value.amount}\n onChange={(e) => set(\"amount\", e.target.value)}\n placeholder=\"0.00\"\n className={INPUT_BASE}\n />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Currency</label>\n <div className=\"grid grid-cols-3 sm:grid-cols-5 gap-1.5\">\n {tokenOptions.map((symbol) => (\n <button\n key={symbol}\n type=\"button\"\n disabled={disabled}\n onClick={() => set(\"paymentTokenSymbol\", symbol)}\n aria-pressed={value.paymentTokenSymbol === symbol}\n className={cn(\n \"h-10 px-2 rounded-xl border text-xs font-semibold flex items-center justify-center gap-1.5 transition-colors disabled:opacity-50\",\n value.paymentTokenSymbol === symbol\n ? \"border-brand-purple bg-brand-purple/10 text-foreground\"\n : \"border-border bg-card text-muted-foreground hover:text-foreground\",\n )}\n >\n <CurrencyIcon symbol={symbol} size={14} />\n {symbol}\n </button>\n ))}\n </div>\n </div>\n\n <label className=\"flex items-start gap-2.5 cursor-pointer select-none\">\n <input\n type=\"checkbox\"\n disabled={disabled}\n checked={value.transferable}\n onChange={(e) => set(\"transferable\", e.target.checked)}\n className=\"mt-0.5 h-4 w-4 rounded border-border text-brand-purple focus:ring-brand-purple/40\"\n />\n <span className=\"text-sm\">\n <span className=\"font-medium\">Sponsor can resell this license</span>\n <span className={cn(FIELD_HELP, \"block\")}>Off means it's meant to stay with the sponsor who accepts it — resale still isn't blocked on-chain, this is just the stated intent.</span>\n </span>\n </label>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>License length</label>\n <div className=\"grid grid-cols-[1fr_auto] gap-2\">\n <input\n type=\"number\"\n min={1}\n disabled={disabled}\n value={value.durationValue}\n onChange={(e) => set(\"durationValue\", e.target.value)}\n placeholder=\"e.g. 30\"\n className={INPUT_BASE}\n />\n <select\n disabled={disabled}\n value={value.durationUnit}\n onChange={(e) => set(\"durationUnit\", e.target.value as DurationUnit)}\n className={cn(INPUT_BASE, \"w-28\")}\n >\n {DURATION_UNITS.map((u) => (\n <option key={u} value={u}>{u}</option>\n ))}\n </select>\n </div>\n <p className={FIELD_HELP}>Counted from the moment the deal is accepted, not from today.</p>\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>License type</label>\n <select\n disabled={disabled}\n value={value.licenseType}\n onChange={(e) => handleLicenseTypeChange(e.target.value)}\n className={INPUT_BASE}\n >\n {LICENSE_TYPES.map((l) => (\n <option key={l.value} value={l.value}>{l.label}</option>\n ))}\n </select>\n {selectedLicense ? <p className={FIELD_HELP}>{selectedLicense.description}</p> : null}\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Commercial use</label>\n <ToggleGroup value={value.commercialUse} options={[\"Yes\", \"No\"]} onChange={(v) => set(\"commercialUse\", v as SponsorshipTerms[\"commercialUse\"])} disabled={disabled} />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Derivatives</label>\n <ToggleGroup value={value.derivatives} options={[\"Allowed\", \"Not Allowed\", \"Share-Alike\"]} onChange={(v) => set(\"derivatives\", v as SponsorshipTerms[\"derivatives\"])} disabled={disabled} />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Attribution</label>\n <ToggleGroup value={value.attribution} options={[\"Required\", \"Not Required\"]} onChange={(v) => set(\"attribution\", v as SponsorshipTerms[\"attribution\"])} disabled={disabled} />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Territory <span className=\"font-normal text-muted-foreground\">(optional)</span></label>\n <input\n type=\"text\"\n disabled={disabled}\n value={value.territory}\n onChange={(e) => set(\"territory\", e.target.value)}\n placeholder=\"e.g. Worldwide, Brazil only, excluding China\"\n className={INPUT_BASE}\n />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>AI policy</label>\n <select\n disabled={disabled}\n value={value.aiPolicy}\n onChange={(e) => set(\"aiPolicy\", e.target.value)}\n className={INPUT_BASE}\n >\n {AI_POLICIES.map((p) => (\n <option key={p} value={p}>{p}</option>\n ))}\n </select>\n <p className={FIELD_HELP}>Whether this work can be used to train AI models.</p>\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Scope <span className=\"font-normal text-muted-foreground\">(optional)</span></label>\n <input\n type=\"text\"\n disabled={disabled}\n value={value.scope}\n onChange={(e) => set(\"scope\", e.target.value)}\n placeholder=\"e.g. Instagram + YouTube only\"\n className={INPUT_BASE}\n />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Deliverables <span className=\"font-normal text-muted-foreground\">(optional)</span></label>\n <textarea\n disabled={disabled}\n value={value.deliverables}\n onChange={(e) => set(\"deliverables\", e.target.value)}\n placeholder=\"e.g. 3 posts, 1 video\"\n rows={2}\n className={cn(INPUT_BASE, \"h-auto py-2.5 resize-y\")}\n />\n </div>\n\n <YesNoToggle\n label=\"Exclusive to this sponsor\"\n help=\"No other sponsors during the license term.\"\n checked={value.exclusive}\n onChange={(v) => set(\"exclusive\", v)}\n disabled={disabled}\n />\n\n <YesNoToggle\n label=\"Content approval required\"\n help=\"Sponsor reviews content before it's published.\"\n checked={value.approvalRequired}\n onChange={(v) => set(\"approvalRequired\", v)}\n disabled={disabled}\n />\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Media <span className=\"font-normal text-muted-foreground\">(optional)</span></label>\n <div className=\"flex flex-wrap gap-1.5\">\n {MEDIA_TYPES.map((m) => (\n <button\n key={m}\n type=\"button\"\n disabled={disabled}\n onClick={() => toggleMedia(m)}\n className={cn(\n \"h-8 px-2.5 rounded-full border text-xs font-medium transition-colors disabled:opacity-50\",\n value.media.includes(m)\n ? \"border-brand-purple bg-brand-purple/10 text-foreground\"\n : \"border-border bg-card text-muted-foreground hover:text-foreground\",\n )}\n >\n {m}\n </button>\n ))}\n </div>\n <input\n type=\"text\"\n disabled={disabled}\n value={value.mediaOther}\n onChange={(e) => set(\"mediaOther\", e.target.value)}\n placeholder=\"Other media type\"\n className={cn(INPUT_BASE, \"mt-1.5\")}\n />\n </div>\n\n <div className=\"space-y-1.5\">\n <label className={FIELD_LABEL}>Additional terms <span className=\"font-normal text-muted-foreground\">(optional)</span></label>\n <textarea\n disabled={disabled}\n value={value.licenseText}\n onChange={(e) => set(\"licenseText\", e.target.value)}\n placeholder=\"Anything else worth spelling out.\"\n rows={3}\n className={cn(INPUT_BASE, \"h-auto py-2.5 resize-y\")}\n />\n <p className={FIELD_HELP}>Saved permanently and shown to anyone who holds the license.</p>\n </div>\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AA8GQ;AA5GR,gBAAmB;AACnB,2BAA6B;AAC7B,gBAA2C;AAEpC,MAAM,iBAAiB,CAAC,QAAQ,SAAS,UAAU,OAAO;AAEjE,MAAM,qBAAmD,EAAE,MAAM,GAAG,OAAO,GAAG,QAAQ,IAAI,OAAO,IAAI;AAE9F,SAAS,eAAe,OAAiC;AAC9D,QAAM,MAAM,OAAO,MAAM,iBAAiB,GAAG;AAC7C,MAAI,CAAC,OAAO,OAAO,EAAG,QAAO;AAC7B,SAAO,KAAK,MAAM,MAAM,mBAAmB,MAAM,YAAY,CAAC;AAChE;AAEO,MAAM,cAAc;AAAA,EACzB;AAAA,EAAgB;AAAA,EAAS;AAAA,EAAS;AAAA,EAAgB;AAAA,EAAS;AAAA,EAAa;AAAA,EAAiB;AAC3F;AA8BO,MAAM,0BAA4C;AAAA,EACvD,QAAQ;AAA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,UACb,UAAU,CAAC,MAAM,IAAI,cAAc,EAAE,OAAO,KAAK;AAAA,UACjD,aAAY;AAAA,UACZ,eAAW,cAAG,YAAY,QAAQ;AAAA;AAAA,MACpC;AAAA,OACF;AAAA,IAEA,6CAAC,SAAI,WAAU,eACb;AAAA,mDAAC,WAAM,WAAW,aAAa;AAAA;AAAA,QAAiB,4CAAC,UAAK,WAAU,qCAAoC,wBAAU;AAAA,SAAO;AAAA,MACrH;AAAA,QAAC;AAAA;AAAA,UACC;AAAA,UACA,OAAO,MAAM;AAAA,UACb,UAAU,CAAC,MAAM,IAAI,eAAe,EAAE,OAAO,KAAK;AAAA,UAClD,aAAY;AAAA,UACZ,MAAM;AAAA,UACN,eAAW,cAAG,YAAY,wBAAwB;AAAA;AAAA,MACpD;AAAA,MACA,4CAAC,OAAE,WAAW,YAAY,0EAA4D;AAAA,OACxF;AAAA,KACF;AAEJ;","names":[]}
|
|
@@ -1,52 +1,24 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
2
|
|
|
3
|
-
/** Duration units — the on-chain `duration` arg is seconds, but nobody
|
|
4
|
-
* should be forced to think in days for a multi-year deal (or forced into
|
|
5
|
-
* days at all — this is declarative, not contract-enforced). */
|
|
6
3
|
declare const DURATION_UNITS: readonly ["Days", "Weeks", "Months", "Years"];
|
|
7
4
|
type DurationUnit = (typeof DURATION_UNITS)[number];
|
|
8
|
-
/** Converts the user-entered value + unit into whole days for the contract's
|
|
9
|
-
* `duration` arg (seconds = days * 86400, done by the caller). */
|
|
10
5
|
declare function toDurationDays(terms: SponsorshipTerms): number;
|
|
11
|
-
/** Common sponsorship media/channel types — deliberately not part of the
|
|
12
|
-
* general IP taxonomy in `data/ip.ts` (that's about the asset itself;
|
|
13
|
-
* this is about the sponsorship deal's channels), so it stays local here. */
|
|
14
6
|
declare const MEDIA_TYPES: readonly ["Social Media", "Video", "Photo", "Article/Blog", "Print", "Broadcast", "Podcast/Audio", "Livestream"];
|
|
15
|
-
/**
|
|
16
|
-
* The deal terms a sponsorship offer/proposal needs, in plain-language shape
|
|
17
|
-
* — no bps, no IPFS, no ByteArray. `royaltyPercent` is a plain 0–100 number
|
|
18
|
-
* (multiply by 100 for the contract's basis-points argument). Every field
|
|
19
|
-
* here is declarative metadata carried in the pinned IPFS document (see
|
|
20
|
-
* `toLicenseMetadata`) — the contract never reads any of it, so none of it
|
|
21
|
-
* is enforced beyond the atomic accept-and-mint payment itself. This
|
|
22
|
-
* component only collects and validates the data, it never fetches or
|
|
23
|
-
* uploads anything itself.
|
|
24
|
-
*/
|
|
25
7
|
interface SponsorshipTerms {
|
|
26
8
|
amount: string;
|
|
27
9
|
paymentTokenSymbol: string;
|
|
28
|
-
/** No default — the user must explicitly set this, never silently inherit one.
|
|
29
|
-
* Paired with `durationUnit`; convert with `toDurationDays()`. */
|
|
30
10
|
durationValue: string;
|
|
31
11
|
durationUnit: DurationUnit;
|
|
32
12
|
transferable: boolean;
|
|
33
|
-
/** Not surfaced in the UI (no resale-royalty concept here) — always "0". Kept
|
|
34
|
-
* on the type because `create_offer`/`propose_sponsorship` still take a
|
|
35
|
-
* `royaltyBps` argument. */
|
|
36
13
|
royaltyPercent: string;
|
|
37
|
-
/** Free-text notes that don't fit any structured field below. */
|
|
38
14
|
licenseText: string;
|
|
39
15
|
licenseType: string;
|
|
40
16
|
commercialUse: "Yes" | "No";
|
|
41
17
|
derivatives: "Allowed" | "Not Allowed" | "Share-Alike";
|
|
42
18
|
attribution: "Required" | "Not Required";
|
|
43
|
-
/** Free text — "Worldwide" is a fine default, but real deals often name a
|
|
44
|
-
* specific country or an exclusion, which a fixed list can't cover. */
|
|
45
19
|
territory: string;
|
|
46
20
|
aiPolicy: string;
|
|
47
|
-
/** e.g. "Instagram + YouTube only" — too deal-specific to bound into an enum. */
|
|
48
21
|
scope: string;
|
|
49
|
-
/** e.g. "3 posts, 1 video" */
|
|
50
22
|
deliverables: string;
|
|
51
23
|
exclusive: boolean;
|
|
52
24
|
approvalRequired: boolean;
|
|
@@ -54,17 +26,11 @@ interface SponsorshipTerms {
|
|
|
54
26
|
mediaOther: string;
|
|
55
27
|
}
|
|
56
28
|
declare const EMPTY_SPONSORSHIP_TERMS: SponsorshipTerms;
|
|
57
|
-
/** Shapes the pinned-IPFS-JSON payload — the single place both apps build
|
|
58
|
-
* this object, so it can't drift across call sites. Purely additive; the
|
|
59
|
-
* contract never reads any of it. */
|
|
60
29
|
declare function toLicenseMetadata(terms: SponsorshipTerms): Record<string, unknown>;
|
|
61
30
|
interface LicenseTermsBuilderProps {
|
|
62
31
|
value: SponsorshipTerms;
|
|
63
32
|
onChange: (next: SponsorshipTerms) => void;
|
|
64
|
-
/** Payment token symbols to offer — e.g. from SUPPORTED_TOKENS. */
|
|
65
33
|
tokenOptions: string[];
|
|
66
|
-
/** Copy override for the amount field — "Minimum bid" for an owner's
|
|
67
|
-
* offer, "Amount you'll pay" for a sponsor's proposal. Default: "Amount". */
|
|
68
34
|
amountLabel?: string;
|
|
69
35
|
disabled?: boolean;
|
|
70
36
|
className?: string;
|