@cellarnode/ui 0.17.3 → 0.19.1
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/chat/unified-timeline.d.ts +15 -0
- package/dist/chat/unified-timeline.d.ts.map +1 -1
- package/dist/chat/unified-timeline.js.map +1 -1
- package/dist/components/__tests__/countdown-pill.test.d.ts +2 -0
- package/dist/components/__tests__/countdown-pill.test.d.ts.map +1 -0
- package/dist/components/__tests__/countdown-pill.test.js +28 -0
- package/dist/components/__tests__/countdown-pill.test.js.map +1 -0
- package/dist/components/__tests__/country-flag.test.d.ts +2 -0
- package/dist/components/__tests__/country-flag.test.d.ts.map +1 -0
- package/dist/components/__tests__/country-flag.test.js +20 -0
- package/dist/components/__tests__/country-flag.test.js.map +1 -0
- package/dist/components/__tests__/status-pill.test.d.ts +2 -0
- package/dist/components/__tests__/status-pill.test.d.ts.map +1 -0
- package/dist/components/__tests__/status-pill.test.js +24 -0
- package/dist/components/__tests__/status-pill.test.js.map +1 -0
- package/dist/components/confirmation-dialog.stories.d.ts +26 -0
- package/dist/components/confirmation-dialog.stories.d.ts.map +1 -0
- package/dist/components/confirmation-dialog.stories.js +94 -0
- package/dist/components/confirmation-dialog.stories.js.map +1 -0
- package/dist/components/countdown-pill.d.ts +7 -0
- package/dist/components/countdown-pill.d.ts.map +1 -0
- package/dist/components/countdown-pill.js +27 -0
- package/dist/components/countdown-pill.js.map +1 -0
- package/dist/components/countdown-pill.stories.d.ts +15 -0
- package/dist/components/countdown-pill.stories.d.ts.map +1 -0
- package/dist/components/countdown-pill.stories.js +14 -0
- package/dist/components/countdown-pill.stories.js.map +1 -0
- package/dist/components/country-flag.d.ts +6 -0
- package/dist/components/country-flag.d.ts.map +1 -0
- package/dist/components/country-flag.js +31 -0
- package/dist/components/country-flag.js.map +1 -0
- package/dist/components/country-flag.stories.d.ts +14 -0
- package/dist/components/country-flag.stories.d.ts.map +1 -0
- package/dist/components/country-flag.stories.js +16 -0
- package/dist/components/country-flag.stories.js.map +1 -0
- package/dist/components/period-select.stories.d.ts +29 -0
- package/dist/components/period-select.stories.d.ts.map +1 -0
- package/dist/components/period-select.stories.js +65 -0
- package/dist/components/period-select.stories.js.map +1 -0
- package/dist/components/sidebar/context.d.ts +24 -0
- package/dist/components/sidebar/context.d.ts.map +1 -0
- package/dist/components/sidebar/context.js +73 -0
- package/dist/components/sidebar/context.js.map +1 -0
- package/dist/components/sidebar/index.d.ts +9 -0
- package/dist/components/sidebar/index.d.ts.map +1 -0
- package/dist/components/sidebar/index.js +9 -0
- package/dist/components/sidebar/index.js.map +1 -0
- package/dist/components/sidebar/sidebar-group.d.ts +10 -0
- package/dist/components/sidebar/sidebar-group.d.ts.map +1 -0
- package/dist/components/sidebar/sidebar-group.js +21 -0
- package/dist/components/sidebar/sidebar-group.js.map +1 -0
- package/dist/components/sidebar/sidebar-inset.d.ts +3 -0
- package/dist/components/sidebar/sidebar-inset.d.ts.map +1 -0
- package/dist/components/sidebar/sidebar-inset.js +7 -0
- package/dist/components/sidebar/sidebar-inset.js.map +1 -0
- package/dist/components/sidebar/sidebar-menu-sub.d.ts +9 -0
- package/dist/components/sidebar/sidebar-menu-sub.d.ts.map +1 -0
- package/dist/components/sidebar/sidebar-menu-sub.js +15 -0
- package/dist/components/sidebar/sidebar-menu-sub.js.map +1 -0
- package/dist/components/sidebar/sidebar-menu.d.ts +23 -0
- package/dist/components/sidebar/sidebar-menu.d.ts.map +1 -0
- package/dist/components/sidebar/sidebar-menu.js +63 -0
- package/dist/components/sidebar/sidebar-menu.js.map +1 -0
- package/dist/components/sidebar/sidebar-sections.d.ts +8 -0
- package/dist/components/sidebar/sidebar-sections.d.ts.map +1 -0
- package/dist/components/sidebar/sidebar-sections.js +20 -0
- package/dist/components/sidebar/sidebar-sections.js.map +1 -0
- package/dist/components/sidebar/sidebar-trigger.d.ts +4 -0
- package/dist/components/sidebar/sidebar-trigger.d.ts.map +1 -0
- package/dist/components/sidebar/sidebar-trigger.js +17 -0
- package/dist/components/sidebar/sidebar-trigger.js.map +1 -0
- package/dist/components/sidebar/sidebar.d.ts +7 -0
- package/dist/components/sidebar/sidebar.d.ts.map +1 -0
- package/dist/components/sidebar/sidebar.js +26 -0
- package/dist/components/sidebar/sidebar.js.map +1 -0
- package/dist/components/status-pill.d.ts +7 -0
- package/dist/components/status-pill.d.ts.map +1 -0
- package/dist/components/status-pill.js +14 -0
- package/dist/components/status-pill.js.map +1 -0
- package/dist/components/status-pill.stories.d.ts +21 -0
- package/dist/components/status-pill.stories.d.ts.map +1 -0
- package/dist/components/status-pill.stories.js +18 -0
- package/dist/components/status-pill.stories.js.map +1 -0
- package/dist/components/toast.stories.d.ts +25 -0
- package/dist/components/toast.stories.d.ts.map +1 -0
- package/dist/components/toast.stories.js +38 -0
- package/dist/components/toast.stories.js.map +1 -0
- package/dist/components/toaster.stories.d.ts +19 -0
- package/dist/components/toaster.stories.d.ts.map +1 -0
- package/dist/components/toaster.stories.js +27 -0
- package/dist/components/toaster.stories.js.map +1 -0
- package/dist/globe/globe-scene-camera.d.ts +25 -0
- package/dist/globe/globe-scene-camera.d.ts.map +1 -0
- package/dist/globe/globe-scene-camera.js +59 -0
- package/dist/globe/globe-scene-camera.js.map +1 -0
- package/dist/globe/globe-scene-channel.d.ts +27 -0
- package/dist/globe/globe-scene-channel.d.ts.map +1 -0
- package/dist/globe/globe-scene-channel.js +60 -0
- package/dist/globe/globe-scene-channel.js.map +1 -0
- package/dist/globe/globe-scene-controls.d.ts +38 -0
- package/dist/globe/globe-scene-controls.d.ts.map +1 -0
- package/dist/globe/globe-scene-controls.js +62 -0
- package/dist/globe/globe-scene-controls.js.map +1 -0
- package/dist/globe/globe-scene-data.d.ts +16 -0
- package/dist/globe/globe-scene-data.d.ts.map +1 -0
- package/dist/globe/globe-scene-data.js +51 -0
- package/dist/globe/globe-scene-data.js.map +1 -0
- package/dist/globe/globe-scene-interactions.d.ts +11 -0
- package/dist/globe/globe-scene-interactions.d.ts.map +1 -0
- package/dist/globe/globe-scene-interactions.js +54 -0
- package/dist/globe/globe-scene-interactions.js.map +1 -0
- package/dist/globe/globe-scene-layers.d.ts +22 -0
- package/dist/globe/globe-scene-layers.d.ts.map +1 -0
- package/dist/globe/globe-scene-layers.js +170 -0
- package/dist/globe/globe-scene-layers.js.map +1 -0
- package/dist/globe/globe-scene-props.d.ts +32 -0
- package/dist/globe/globe-scene-props.d.ts.map +1 -0
- package/dist/globe/globe-scene-props.js +8 -0
- package/dist/globe/globe-scene-props.js.map +1 -0
- package/dist/globe/globe-scene-types.d.ts +34 -0
- package/dist/globe/globe-scene-types.d.ts.map +1 -0
- package/dist/globe/globe-scene-types.js +14 -0
- package/dist/globe/globe-scene-types.js.map +1 -0
- package/dist/globe/globe-scene.d.ts +10 -25
- package/dist/globe/globe-scene.d.ts.map +1 -1
- package/dist/globe/globe-scene.js +54 -349
- package/dist/globe/globe-scene.js.map +1 -1
- package/dist/hooks/__tests__/use-animated-number.test.d.ts +2 -0
- package/dist/hooks/__tests__/use-animated-number.test.d.ts.map +1 -0
- package/dist/hooks/__tests__/use-animated-number.test.js +58 -0
- package/dist/hooks/__tests__/use-animated-number.test.js.map +1 -0
- package/dist/hooks/index.d.ts +3 -0
- package/dist/hooks/index.d.ts.map +1 -0
- package/dist/hooks/index.js +2 -0
- package/dist/hooks/index.js.map +1 -0
- package/dist/hooks/use-animated-number.d.ts +6 -0
- package/dist/hooks/use-animated-number.d.ts.map +1 -0
- package/dist/hooks/use-animated-number.js +56 -0
- package/dist/hooks/use-animated-number.js.map +1 -0
- package/dist/index.d.ts +8 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +6 -0
- package/dist/index.js.map +1 -1
- package/dist/notifications/notification-badge.stories.d.ts +42 -0
- package/dist/notifications/notification-badge.stories.d.ts.map +1 -0
- package/dist/notifications/notification-badge.stories.js +42 -0
- package/dist/notifications/notification-badge.stories.js.map +1 -0
- package/dist/notifications/notification-empty-state.stories.d.ts +16 -0
- package/dist/notifications/notification-empty-state.stories.d.ts.map +1 -0
- package/dist/notifications/notification-empty-state.stories.js +22 -0
- package/dist/notifications/notification-empty-state.stories.js.map +1 -0
- package/dist/notifications/notification-item.stories.d.ts +41 -0
- package/dist/notifications/notification-item.stories.d.ts.map +1 -0
- package/dist/notifications/notification-item.stories.js +110 -0
- package/dist/notifications/notification-item.stories.js.map +1 -0
- package/dist/notifications/notification-list.stories.d.ts +25 -0
- package/dist/notifications/notification-list.stories.d.ts.map +1 -0
- package/dist/notifications/notification-list.stories.js +148 -0
- package/dist/notifications/notification-list.stories.js.map +1 -0
- package/dist/notifications/notification-page.stories.d.ts +20 -0
- package/dist/notifications/notification-page.stories.d.ts.map +1 -0
- package/dist/notifications/notification-page.stories.js +140 -0
- package/dist/notifications/notification-page.stories.js.map +1 -0
- package/dist/notifications/notification-tray.stories.d.ts +21 -0
- package/dist/notifications/notification-tray.stories.d.ts.map +1 -0
- package/dist/notifications/notification-tray.stories.js +123 -0
- package/dist/notifications/notification-tray.stories.js.map +1 -0
- package/dist/notifications/push-prompt-banner.stories.d.ts +27 -0
- package/dist/notifications/push-prompt-banner.stories.d.ts.map +1 -0
- package/dist/notifications/push-prompt-banner.stories.js +33 -0
- package/dist/notifications/push-prompt-banner.stories.js.map +1 -0
- package/dist/offer/__tests__/opportunity-requirements.test.d.ts +2 -0
- package/dist/offer/__tests__/opportunity-requirements.test.d.ts.map +1 -0
- package/dist/offer/__tests__/opportunity-requirements.test.js +33 -0
- package/dist/offer/__tests__/opportunity-requirements.test.js.map +1 -0
- package/dist/offer/attachments-card.d.ts +9 -0
- package/dist/offer/attachments-card.d.ts.map +1 -0
- package/dist/offer/attachments-card.js +16 -0
- package/dist/offer/attachments-card.js.map +1 -0
- package/dist/offer/attachments-card.stories.d.ts +17 -0
- package/dist/offer/attachments-card.stories.d.ts.map +1 -0
- package/dist/offer/attachments-card.stories.js +24 -0
- package/dist/offer/attachments-card.stories.js.map +1 -0
- package/dist/offer/buyer-notes-card.d.ts +7 -0
- package/dist/offer/buyer-notes-card.d.ts.map +1 -0
- package/dist/offer/buyer-notes-card.js +6 -0
- package/dist/offer/buyer-notes-card.js.map +1 -0
- package/dist/offer/buyer-notes-card.stories.d.ts +16 -0
- package/dist/offer/buyer-notes-card.stories.d.ts.map +1 -0
- package/dist/offer/buyer-notes-card.stories.js +25 -0
- package/dist/offer/buyer-notes-card.stories.js.map +1 -0
- package/dist/offer/counter-slide-over.d.ts +44 -0
- package/dist/offer/counter-slide-over.d.ts.map +1 -0
- package/dist/offer/counter-slide-over.js +81 -0
- package/dist/offer/counter-slide-over.js.map +1 -0
- package/dist/offer/counter-slide-over.stories.d.ts +23 -0
- package/dist/offer/counter-slide-over.stories.d.ts.map +1 -0
- package/dist/offer/counter-slide-over.stories.js +235 -0
- package/dist/offer/counter-slide-over.stories.js.map +1 -0
- package/dist/offer/facts-card.d.ts +32 -0
- package/dist/offer/facts-card.d.ts.map +1 -0
- package/dist/offer/facts-card.js +87 -0
- package/dist/offer/facts-card.js.map +1 -0
- package/dist/offer/facts-card.stories.d.ts +25 -0
- package/dist/offer/facts-card.stories.d.ts.map +1 -0
- package/dist/offer/facts-card.stories.js +177 -0
- package/dist/offer/facts-card.stories.js.map +1 -0
- package/dist/offer/index.d.ts +39 -0
- package/dist/offer/index.d.ts.map +1 -1
- package/dist/offer/index.js +21 -0
- package/dist/offer/index.js.map +1 -1
- package/dist/offer/inline-counter-form.d.ts +16 -0
- package/dist/offer/inline-counter-form.d.ts.map +1 -1
- package/dist/offer/inline-counter-form.js +8 -0
- package/dist/offer/inline-counter-form.js.map +1 -1
- package/dist/offer/match-compatibility-card.d.ts +16 -0
- package/dist/offer/match-compatibility-card.d.ts.map +1 -0
- package/dist/offer/match-compatibility-card.js +27 -0
- package/dist/offer/match-compatibility-card.js.map +1 -0
- package/dist/offer/match-compatibility-card.stories.d.ts +19 -0
- package/dist/offer/match-compatibility-card.stories.d.ts.map +1 -0
- package/dist/offer/match-compatibility-card.stories.js +111 -0
- package/dist/offer/match-compatibility-card.stories.js.map +1 -0
- package/dist/offer/match-glyph.d.ts +14 -0
- package/dist/offer/match-glyph.d.ts.map +1 -0
- package/dist/offer/match-glyph.js +40 -0
- package/dist/offer/match-glyph.js.map +1 -0
- package/dist/offer/match-glyph.stories.d.ts +26 -0
- package/dist/offer/match-glyph.stories.d.ts.map +1 -0
- package/dist/offer/match-glyph.stories.js +26 -0
- package/dist/offer/match-glyph.stories.js.map +1 -0
- package/dist/offer/match-headline-bar.d.ts +11 -0
- package/dist/offer/match-headline-bar.d.ts.map +1 -0
- package/dist/offer/match-headline-bar.js +28 -0
- package/dist/offer/match-headline-bar.js.map +1 -0
- package/dist/offer/match-headline-bar.stories.d.ts +17 -0
- package/dist/offer/match-headline-bar.stories.d.ts.map +1 -0
- package/dist/offer/match-headline-bar.stories.js +39 -0
- package/dist/offer/match-headline-bar.stories.js.map +1 -0
- package/dist/offer/match-preview.d.ts +18 -0
- package/dist/offer/match-preview.d.ts.map +1 -0
- package/dist/offer/match-preview.js +13 -0
- package/dist/offer/match-preview.js.map +1 -0
- package/dist/offer/match-preview.stories.d.ts +18 -0
- package/dist/offer/match-preview.stories.d.ts.map +1 -0
- package/dist/offer/match-preview.stories.js +103 -0
- package/dist/offer/match-preview.stories.js.map +1 -0
- package/dist/offer/negotiation-section.d.ts +11 -0
- package/dist/offer/negotiation-section.d.ts.map +1 -0
- package/dist/offer/negotiation-section.js +99 -0
- package/dist/offer/negotiation-section.js.map +1 -0
- package/dist/offer/negotiation-section.stories.d.ts +18 -0
- package/dist/offer/negotiation-section.stories.d.ts.map +1 -0
- package/dist/offer/negotiation-section.stories.js +156 -0
- package/dist/offer/negotiation-section.stories.js.map +1 -0
- package/dist/offer/new-activity-pill.d.ts +7 -0
- package/dist/offer/new-activity-pill.d.ts.map +1 -0
- package/dist/offer/new-activity-pill.js +8 -0
- package/dist/offer/new-activity-pill.js.map +1 -0
- package/dist/offer/new-activity-pill.stories.d.ts +17 -0
- package/dist/offer/new-activity-pill.stories.d.ts.map +1 -0
- package/dist/offer/new-activity-pill.stories.js +22 -0
- package/dist/offer/new-activity-pill.stories.js.map +1 -0
- package/dist/offer/offer-detail-header.stories.d.ts +19 -0
- package/dist/offer/offer-detail-header.stories.d.ts.map +1 -0
- package/dist/offer/offer-detail-header.stories.js +59 -0
- package/dist/offer/offer-detail-header.stories.js.map +1 -0
- package/dist/offer/offer-detail-shell.stories.d.ts +17 -0
- package/dist/offer/offer-detail-shell.stories.d.ts.map +1 -0
- package/dist/offer/offer-detail-shell.stories.js +69 -0
- package/dist/offer/offer-detail-shell.stories.js.map +1 -0
- package/dist/offer/offer-detail-tabs.stories.d.ts +17 -0
- package/dist/offer/offer-detail-tabs.stories.d.ts.map +1 -0
- package/dist/offer/offer-detail-tabs.stories.js +66 -0
- package/dist/offer/offer-detail-tabs.stories.js.map +1 -0
- package/dist/offer/offer-document.d.ts +33 -0
- package/dist/offer/offer-document.d.ts.map +1 -0
- package/dist/offer/offer-document.js +125 -0
- package/dist/offer/offer-document.js.map +1 -0
- package/dist/offer/offer-document.stories.d.ts +25 -0
- package/dist/offer/offer-document.stories.d.ts.map +1 -0
- package/dist/offer/offer-document.stories.js +168 -0
- package/dist/offer/offer-document.stories.js.map +1 -0
- package/dist/offer/offer-export-button.d.ts +8 -0
- package/dist/offer/offer-export-button.d.ts.map +1 -0
- package/dist/offer/offer-export-button.js +11 -0
- package/dist/offer/offer-export-button.js.map +1 -0
- package/dist/offer/offer-export-button.stories.d.ts +15 -0
- package/dist/offer/offer-export-button.stories.d.ts.map +1 -0
- package/dist/offer/offer-export-button.stories.js +11 -0
- package/dist/offer/offer-export-button.stories.js.map +1 -0
- package/dist/offer/offer-product-card.d.ts +32 -0
- package/dist/offer/offer-product-card.d.ts.map +1 -0
- package/dist/offer/offer-product-card.js +10 -0
- package/dist/offer/offer-product-card.js.map +1 -0
- package/dist/offer/offer-product-card.stories.d.ts +16 -0
- package/dist/offer/offer-product-card.stories.d.ts.map +1 -0
- package/dist/offer/offer-product-card.stories.js +40 -0
- package/dist/offer/offer-product-card.stories.js.map +1 -0
- package/dist/offer/opportunity-card.d.ts +16 -0
- package/dist/offer/opportunity-card.d.ts.map +1 -0
- package/dist/offer/opportunity-card.js +9 -0
- package/dist/offer/opportunity-card.js.map +1 -0
- package/dist/offer/opportunity-card.stories.d.ts +16 -0
- package/dist/offer/opportunity-card.stories.d.ts.map +1 -0
- package/dist/offer/opportunity-card.stories.js +33 -0
- package/dist/offer/opportunity-card.stories.js.map +1 -0
- package/dist/offer/opportunity-requirements.d.ts.map +1 -1
- package/dist/offer/opportunity-requirements.js +4 -0
- package/dist/offer/opportunity-requirements.js.map +1 -1
- package/dist/offer/parties-card.d.ts +11 -0
- package/dist/offer/parties-card.d.ts.map +1 -0
- package/dist/offer/parties-card.js +14 -0
- package/dist/offer/parties-card.js.map +1 -0
- package/dist/offer/parties-card.stories.d.ts +17 -0
- package/dist/offer/parties-card.stories.d.ts.map +1 -0
- package/dist/offer/parties-card.stories.js +37 -0
- package/dist/offer/parties-card.stories.js.map +1 -0
- package/dist/offer/terms-card.d.ts +17 -0
- package/dist/offer/terms-card.d.ts.map +1 -0
- package/dist/offer/terms-card.js +50 -0
- package/dist/offer/terms-card.js.map +1 -0
- package/dist/offer/terms-card.stories.d.ts +17 -0
- package/dist/offer/terms-card.stories.d.ts.map +1 -0
- package/dist/offer/terms-card.stories.js +42 -0
- package/dist/offer/terms-card.stories.js.map +1 -0
- package/dist/offer/timeline-event.d.ts +12 -0
- package/dist/offer/timeline-event.d.ts.map +1 -0
- package/dist/offer/timeline-event.js +57 -0
- package/dist/offer/timeline-event.js.map +1 -0
- package/dist/offer/timeline-event.stories.d.ts +21 -0
- package/dist/offer/timeline-event.stories.d.ts.map +1 -0
- package/dist/offer/timeline-event.stories.js +57 -0
- package/dist/offer/timeline-event.stories.js.map +1 -0
- package/dist/offer/types.d.ts +118 -0
- package/dist/offer/types.d.ts.map +1 -1
- package/dist/opportunities/__a11y__/opportunity-card-actions-menu.a11y.test.d.ts +2 -0
- package/dist/opportunities/__a11y__/opportunity-card-actions-menu.a11y.test.d.ts.map +1 -0
- package/dist/opportunities/__a11y__/opportunity-card-actions-menu.a11y.test.js +40 -0
- package/dist/opportunities/__a11y__/opportunity-card-actions-menu.a11y.test.js.map +1 -0
- package/dist/opportunities/__a11y__/opportunity-celebration.a11y.test.d.ts +2 -0
- package/dist/opportunities/__a11y__/opportunity-celebration.a11y.test.d.ts.map +1 -0
- package/dist/opportunities/__a11y__/opportunity-celebration.a11y.test.js +31 -0
- package/dist/opportunities/__a11y__/opportunity-celebration.a11y.test.js.map +1 -0
- package/dist/opportunities/__a11y__/opportunity-detail-panel.a11y.test.d.ts +2 -0
- package/dist/opportunities/__a11y__/opportunity-detail-panel.a11y.test.d.ts.map +1 -0
- package/dist/opportunities/__a11y__/opportunity-detail-panel.a11y.test.js +42 -0
- package/dist/opportunities/__a11y__/opportunity-detail-panel.a11y.test.js.map +1 -0
- package/dist/opportunities/__a11y__/opportunity-filter-bar.a11y.test.d.ts +2 -0
- package/dist/opportunities/__a11y__/opportunity-filter-bar.a11y.test.d.ts.map +1 -0
- package/dist/opportunities/__a11y__/opportunity-filter-bar.a11y.test.js +59 -0
- package/dist/opportunities/__a11y__/opportunity-filter-bar.a11y.test.js.map +1 -0
- package/dist/opportunities/__a11y__/opportunity-stacked-card.a11y.test.d.ts +2 -0
- package/dist/opportunities/__a11y__/opportunity-stacked-card.a11y.test.d.ts.map +1 -0
- package/dist/opportunities/__a11y__/opportunity-stacked-card.a11y.test.js +54 -0
- package/dist/opportunities/__a11y__/opportunity-stacked-card.a11y.test.js.map +1 -0
- package/dist/opportunities/__a11y__/opportunity-stacked-list.a11y.test.d.ts +2 -0
- package/dist/opportunities/__a11y__/opportunity-stacked-list.a11y.test.d.ts.map +1 -0
- package/dist/opportunities/__a11y__/opportunity-stacked-list.a11y.test.js +40 -0
- package/dist/opportunities/__a11y__/opportunity-stacked-list.a11y.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-add-to-journey-button.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-add-to-journey-button.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-add-to-journey-button.test.js +40 -0
- package/dist/opportunities/__tests__/opportunity-add-to-journey-button.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-card-actions-menu.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-card-actions-menu.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-card-actions-menu.test.js +74 -0
- package/dist/opportunities/__tests__/opportunity-card-actions-menu.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-celebration.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-celebration.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-celebration.test.js +46 -0
- package/dist/opportunities/__tests__/opportunity-celebration.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-channel-badge.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-channel-badge.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-channel-badge.test.js +23 -0
- package/dist/opportunities/__tests__/opportunity-channel-badge.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-detail-panel.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-detail-panel.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-detail-panel.test.js +50 -0
- package/dist/opportunities/__tests__/opportunity-detail-panel.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-empty-state.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-empty-state.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-empty-state.test.js +19 -0
- package/dist/opportunities/__tests__/opportunity-empty-state.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-filter-bar-drawer.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-filter-bar-drawer.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-filter-bar-drawer.test.js +77 -0
- package/dist/opportunities/__tests__/opportunity-filter-bar-drawer.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-filter-bar.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-filter-bar.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-filter-bar.test.js +107 -0
- package/dist/opportunities/__tests__/opportunity-filter-bar.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-offers-count-chip.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-offers-count-chip.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-offers-count-chip.test.js +25 -0
- package/dist/opportunities/__tests__/opportunity-offers-count-chip.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-reopen-button.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-reopen-button.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-reopen-button.test.js +29 -0
- package/dist/opportunities/__tests__/opportunity-reopen-button.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-republish-button.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-republish-button.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-republish-button.test.js +29 -0
- package/dist/opportunities/__tests__/opportunity-republish-button.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-resume-draft-button.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-resume-draft-button.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-resume-draft-button.test.js +19 -0
- package/dist/opportunities/__tests__/opportunity-resume-draft-button.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-stacked-card.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-stacked-card.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-stacked-card.test.js +99 -0
- package/dist/opportunities/__tests__/opportunity-stacked-card.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-stacked-list.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-stacked-list.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-stacked-list.test.js +98 -0
- package/dist/opportunities/__tests__/opportunity-stacked-list.test.js.map +1 -0
- package/dist/opportunities/__tests__/opportunity-view-offers-button.test.d.ts +2 -0
- package/dist/opportunities/__tests__/opportunity-view-offers-button.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/opportunity-view-offers-button.test.js +23 -0
- package/dist/opportunities/__tests__/opportunity-view-offers-button.test.js.map +1 -0
- package/dist/opportunities/__tests__/section-field.test.d.ts +2 -0
- package/dist/opportunities/__tests__/section-field.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/section-field.test.js +28 -0
- package/dist/opportunities/__tests__/section-field.test.js.map +1 -0
- package/dist/opportunities/__tests__/two-column-section.test.d.ts +2 -0
- package/dist/opportunities/__tests__/two-column-section.test.d.ts.map +1 -0
- package/dist/opportunities/__tests__/two-column-section.test.js +25 -0
- package/dist/opportunities/__tests__/two-column-section.test.js.map +1 -0
- package/dist/opportunities/index.d.ts +51 -1
- package/dist/opportunities/index.d.ts.map +1 -1
- package/dist/opportunities/index.js +35 -0
- package/dist/opportunities/index.js.map +1 -1
- package/dist/opportunities/opportunities-table.d.ts +4 -0
- package/dist/opportunities/opportunities-table.d.ts.map +1 -1
- package/dist/opportunities/opportunities-table.js +4 -0
- package/dist/opportunities/opportunities-table.js.map +1 -1
- package/dist/opportunities/opportunity-add-to-journey-button.d.ts +12 -0
- package/dist/opportunities/opportunity-add-to-journey-button.d.ts.map +1 -0
- package/dist/opportunities/opportunity-add-to-journey-button.js +42 -0
- package/dist/opportunities/opportunity-add-to-journey-button.js.map +1 -0
- package/dist/opportunities/opportunity-card-actions-menu.d.ts +9 -0
- package/dist/opportunities/opportunity-card-actions-menu.d.ts.map +1 -0
- package/dist/opportunities/opportunity-card-actions-menu.js +33 -0
- package/dist/opportunities/opportunity-card-actions-menu.js.map +1 -0
- package/dist/opportunities/opportunity-card-actions-menu.stories.d.ts +14 -0
- package/dist/opportunities/opportunity-card-actions-menu.stories.d.ts.map +1 -0
- package/dist/opportunities/opportunity-card-actions-menu.stories.js +12 -0
- package/dist/opportunities/opportunity-card-actions-menu.stories.js.map +1 -0
- package/dist/opportunities/opportunity-celebration.d.ts +8 -0
- package/dist/opportunities/opportunity-celebration.d.ts.map +1 -0
- package/dist/opportunities/opportunity-celebration.js +17 -0
- package/dist/opportunities/opportunity-celebration.js.map +1 -0
- package/dist/opportunities/opportunity-celebration.stories.d.ts +17 -0
- package/dist/opportunities/opportunity-celebration.stories.d.ts.map +1 -0
- package/dist/opportunities/opportunity-celebration.stories.js +30 -0
- package/dist/opportunities/opportunity-celebration.stories.js.map +1 -0
- package/dist/opportunities/opportunity-channel-badge.d.ts +7 -0
- package/dist/opportunities/opportunity-channel-badge.d.ts.map +1 -0
- package/dist/opportunities/opportunity-channel-badge.js +13 -0
- package/dist/opportunities/opportunity-channel-badge.js.map +1 -0
- package/dist/opportunities/opportunity-channel-badge.stories.d.ts +13 -0
- package/dist/opportunities/opportunity-channel-badge.stories.d.ts.map +1 -0
- package/dist/opportunities/opportunity-channel-badge.stories.js +11 -0
- package/dist/opportunities/opportunity-channel-badge.stories.js.map +1 -0
- package/dist/opportunities/opportunity-detail-panel.d.ts +13 -0
- package/dist/opportunities/opportunity-detail-panel.d.ts.map +1 -0
- package/dist/opportunities/opportunity-detail-panel.js +19 -0
- package/dist/opportunities/opportunity-detail-panel.js.map +1 -0
- package/dist/opportunities/opportunity-detail-panel.stories.d.ts +14 -0
- package/dist/opportunities/opportunity-detail-panel.stories.d.ts.map +1 -0
- package/dist/opportunities/opportunity-detail-panel.stories.js +53 -0
- package/dist/opportunities/opportunity-detail-panel.stories.js.map +1 -0
- package/dist/opportunities/opportunity-empty-state.d.ts +10 -0
- package/dist/opportunities/opportunity-empty-state.d.ts.map +1 -0
- package/dist/opportunities/opportunity-empty-state.js +6 -0
- package/dist/opportunities/opportunity-empty-state.js.map +1 -0
- package/dist/opportunities/opportunity-empty-state.stories.d.ts +13 -0
- package/dist/opportunities/opportunity-empty-state.stories.d.ts.map +1 -0
- package/dist/opportunities/opportunity-empty-state.stories.js +13 -0
- package/dist/opportunities/opportunity-empty-state.stories.js.map +1 -0
- package/dist/opportunities/opportunity-filter-bar-drawer.d.ts +10 -0
- package/dist/opportunities/opportunity-filter-bar-drawer.d.ts.map +1 -0
- package/dist/opportunities/opportunity-filter-bar-drawer.js +54 -0
- package/dist/opportunities/opportunity-filter-bar-drawer.js.map +1 -0
- package/dist/opportunities/opportunity-filter-bar.d.ts +14 -0
- package/dist/opportunities/opportunity-filter-bar.d.ts.map +1 -0
- package/dist/opportunities/opportunity-filter-bar.js +65 -0
- package/dist/opportunities/opportunity-filter-bar.js.map +1 -0
- package/dist/opportunities/opportunity-filter-bar.stories.d.ts +25 -0
- package/dist/opportunities/opportunity-filter-bar.stories.d.ts.map +1 -0
- package/dist/opportunities/opportunity-filter-bar.stories.js +63 -0
- package/dist/opportunities/opportunity-filter-bar.stories.js.map +1 -0
- package/dist/opportunities/opportunity-offers-count-chip.d.ts +6 -0
- package/dist/opportunities/opportunity-offers-count-chip.d.ts.map +1 -0
- package/dist/opportunities/opportunity-offers-count-chip.js +8 -0
- package/dist/opportunities/opportunity-offers-count-chip.js.map +1 -0
- package/dist/opportunities/opportunity-offers-count-chip.stories.d.ts +13 -0
- package/dist/opportunities/opportunity-offers-count-chip.stories.d.ts.map +1 -0
- package/dist/opportunities/opportunity-offers-count-chip.stories.js +11 -0
- package/dist/opportunities/opportunity-offers-count-chip.stories.js.map +1 -0
- package/dist/opportunities/opportunity-reopen-button.d.ts +11 -0
- package/dist/opportunities/opportunity-reopen-button.d.ts.map +1 -0
- package/dist/opportunities/opportunity-reopen-button.js +20 -0
- package/dist/opportunities/opportunity-reopen-button.js.map +1 -0
- package/dist/opportunities/opportunity-republish-button.d.ts +7 -0
- package/dist/opportunities/opportunity-republish-button.d.ts.map +1 -0
- package/dist/opportunities/opportunity-republish-button.js +14 -0
- package/dist/opportunities/opportunity-republish-button.js.map +1 -0
- package/dist/opportunities/opportunity-resume-draft-button.d.ts +7 -0
- package/dist/opportunities/opportunity-resume-draft-button.d.ts.map +1 -0
- package/dist/opportunities/opportunity-resume-draft-button.js +7 -0
- package/dist/opportunities/opportunity-resume-draft-button.js.map +1 -0
- package/dist/opportunities/opportunity-stacked-card.d.ts +20 -0
- package/dist/opportunities/opportunity-stacked-card.d.ts.map +1 -0
- package/dist/opportunities/opportunity-stacked-card.js +48 -0
- package/dist/opportunities/opportunity-stacked-card.js.map +1 -0
- package/dist/opportunities/opportunity-stacked-card.stories.d.ts +23 -0
- package/dist/opportunities/opportunity-stacked-card.stories.d.ts.map +1 -0
- package/dist/opportunities/opportunity-stacked-card.stories.js +143 -0
- package/dist/opportunities/opportunity-stacked-card.stories.js.map +1 -0
- package/dist/opportunities/opportunity-stacked-list.d.ts +28 -0
- package/dist/opportunities/opportunity-stacked-list.d.ts.map +1 -0
- package/dist/opportunities/opportunity-stacked-list.js +51 -0
- package/dist/opportunities/opportunity-stacked-list.js.map +1 -0
- package/dist/opportunities/opportunity-stacked-list.stories.d.ts +16 -0
- package/dist/opportunities/opportunity-stacked-list.stories.d.ts.map +1 -0
- package/dist/opportunities/opportunity-stacked-list.stories.js +38 -0
- package/dist/opportunities/opportunity-stacked-list.stories.js.map +1 -0
- package/dist/opportunities/opportunity-view-offers-button.d.ts +7 -0
- package/dist/opportunities/opportunity-view-offers-button.d.ts.map +1 -0
- package/dist/opportunities/opportunity-view-offers-button.js +8 -0
- package/dist/opportunities/opportunity-view-offers-button.js.map +1 -0
- package/dist/opportunities/section-field.d.ts +8 -0
- package/dist/opportunities/section-field.d.ts.map +1 -0
- package/dist/opportunities/section-field.js +9 -0
- package/dist/opportunities/section-field.js.map +1 -0
- package/dist/opportunities/section-field.stories.d.ts +13 -0
- package/dist/opportunities/section-field.stories.d.ts.map +1 -0
- package/dist/opportunities/section-field.stories.js +15 -0
- package/dist/opportunities/section-field.stories.js.map +1 -0
- package/dist/opportunities/two-column-section.d.ts +10 -0
- package/dist/opportunities/two-column-section.d.ts.map +1 -0
- package/dist/opportunities/two-column-section.js +22 -0
- package/dist/opportunities/two-column-section.js.map +1 -0
- package/dist/opportunities/two-column-section.stories.d.ts +12 -0
- package/dist/opportunities/two-column-section.stories.d.ts.map +1 -0
- package/dist/opportunities/two-column-section.stories.js +26 -0
- package/dist/opportunities/two-column-section.stories.js.map +1 -0
- package/dist/opportunities/types.d.ts +76 -0
- package/dist/opportunities/types.d.ts.map +1 -0
- package/dist/opportunities/types.js +2 -0
- package/dist/opportunities/types.js.map +1 -0
- package/dist/opportunities/wizard/__a11y__/opportunity-wizard.a11y.test.d.ts +2 -0
- package/dist/opportunities/wizard/__a11y__/opportunity-wizard.a11y.test.d.ts.map +1 -0
- package/dist/opportunities/wizard/__a11y__/opportunity-wizard.a11y.test.js +53 -0
- package/dist/opportunities/wizard/__a11y__/opportunity-wizard.a11y.test.js.map +1 -0
- package/dist/opportunities/wizard/__a11y__/wizard-stepper.a11y.test.d.ts +2 -0
- package/dist/opportunities/wizard/__a11y__/wizard-stepper.a11y.test.d.ts.map +1 -0
- package/dist/opportunities/wizard/__a11y__/wizard-stepper.a11y.test.js +32 -0
- package/dist/opportunities/wizard/__a11y__/wizard-stepper.a11y.test.js.map +1 -0
- package/dist/opportunities/wizard/__tests__/opportunity-wizard.test.d.ts +2 -0
- package/dist/opportunities/wizard/__tests__/opportunity-wizard.test.d.ts.map +1 -0
- package/dist/opportunities/wizard/__tests__/opportunity-wizard.test.js +127 -0
- package/dist/opportunities/wizard/__tests__/opportunity-wizard.test.js.map +1 -0
- package/dist/opportunities/wizard/__tests__/step-opportunities.test.d.ts +2 -0
- package/dist/opportunities/wizard/__tests__/step-opportunities.test.d.ts.map +1 -0
- package/dist/opportunities/wizard/__tests__/step-opportunities.test.js +93 -0
- package/dist/opportunities/wizard/__tests__/step-opportunities.test.js.map +1 -0
- package/dist/opportunities/wizard/__tests__/step-pricing-timeline.test.d.ts +2 -0
- package/dist/opportunities/wizard/__tests__/step-pricing-timeline.test.d.ts.map +1 -0
- package/dist/opportunities/wizard/__tests__/step-pricing-timeline.test.js +141 -0
- package/dist/opportunities/wizard/__tests__/step-pricing-timeline.test.js.map +1 -0
- package/dist/opportunities/wizard/__tests__/step-review.test.d.ts +2 -0
- package/dist/opportunities/wizard/__tests__/step-review.test.d.ts.map +1 -0
- package/dist/opportunities/wizard/__tests__/step-review.test.js +80 -0
- package/dist/opportunities/wizard/__tests__/step-review.test.js.map +1 -0
- package/dist/opportunities/wizard/__tests__/step-tender-basics.test.d.ts +2 -0
- package/dist/opportunities/wizard/__tests__/step-tender-basics.test.d.ts.map +1 -0
- package/dist/opportunities/wizard/__tests__/step-tender-basics.test.js +76 -0
- package/dist/opportunities/wizard/__tests__/step-tender-basics.test.js.map +1 -0
- package/dist/opportunities/wizard/__tests__/use-wizard-draft.test.d.ts +2 -0
- package/dist/opportunities/wizard/__tests__/use-wizard-draft.test.d.ts.map +1 -0
- package/dist/opportunities/wizard/__tests__/use-wizard-draft.test.js +192 -0
- package/dist/opportunities/wizard/__tests__/use-wizard-draft.test.js.map +1 -0
- package/dist/opportunities/wizard/__tests__/wizard-stepper.test.d.ts +2 -0
- package/dist/opportunities/wizard/__tests__/wizard-stepper.test.d.ts.map +1 -0
- package/dist/opportunities/wizard/__tests__/wizard-stepper.test.js +61 -0
- package/dist/opportunities/wizard/__tests__/wizard-stepper.test.js.map +1 -0
- package/dist/opportunities/wizard/opportunity-wizard.d.ts +29 -0
- package/dist/opportunities/wizard/opportunity-wizard.d.ts.map +1 -0
- package/dist/opportunities/wizard/opportunity-wizard.js +196 -0
- package/dist/opportunities/wizard/opportunity-wizard.js.map +1 -0
- package/dist/opportunities/wizard/opportunity-wizard.stories.d.ts +12 -0
- package/dist/opportunities/wizard/opportunity-wizard.stories.d.ts.map +1 -0
- package/dist/opportunities/wizard/opportunity-wizard.stories.js +49 -0
- package/dist/opportunities/wizard/opportunity-wizard.stories.js.map +1 -0
- package/dist/opportunities/wizard/step-opportunities.d.ts +9 -0
- package/dist/opportunities/wizard/step-opportunities.d.ts.map +1 -0
- package/dist/opportunities/wizard/step-opportunities.js +80 -0
- package/dist/opportunities/wizard/step-opportunities.js.map +1 -0
- package/dist/opportunities/wizard/step-pricing-timeline.d.ts +9 -0
- package/dist/opportunities/wizard/step-pricing-timeline.d.ts.map +1 -0
- package/dist/opportunities/wizard/step-pricing-timeline.js +64 -0
- package/dist/opportunities/wizard/step-pricing-timeline.js.map +1 -0
- package/dist/opportunities/wizard/step-review.d.ts +9 -0
- package/dist/opportunities/wizard/step-review.d.ts.map +1 -0
- package/dist/opportunities/wizard/step-review.js +34 -0
- package/dist/opportunities/wizard/step-review.js.map +1 -0
- package/dist/opportunities/wizard/step-tender-basics.d.ts +16 -0
- package/dist/opportunities/wizard/step-tender-basics.d.ts.map +1 -0
- package/dist/opportunities/wizard/step-tender-basics.js +39 -0
- package/dist/opportunities/wizard/step-tender-basics.js.map +1 -0
- package/dist/opportunities/wizard/use-wizard-draft.d.ts +41 -0
- package/dist/opportunities/wizard/use-wizard-draft.d.ts.map +1 -0
- package/dist/opportunities/wizard/use-wizard-draft.js +214 -0
- package/dist/opportunities/wizard/use-wizard-draft.js.map +1 -0
- package/dist/opportunities/wizard/wizard-stepper.d.ts +20 -0
- package/dist/opportunities/wizard/wizard-stepper.d.ts.map +1 -0
- package/dist/opportunities/wizard/wizard-stepper.js +26 -0
- package/dist/opportunities/wizard/wizard-stepper.js.map +1 -0
- package/dist/opportunities/wizard/wizard-stepper.stories.d.ts +22 -0
- package/dist/opportunities/wizard/wizard-stepper.stories.d.ts.map +1 -0
- package/dist/opportunities/wizard/wizard-stepper.stories.js +47 -0
- package/dist/opportunities/wizard/wizard-stepper.stories.js.map +1 -0
- package/dist/opportunities/wizard/wizard.types.d.ts +176 -0
- package/dist/opportunities/wizard/wizard.types.d.ts.map +1 -0
- package/dist/opportunities/wizard/wizard.types.js +62 -0
- package/dist/opportunities/wizard/wizard.types.js.map +1 -0
- package/dist/org/invite-member-dialog.stories.d.ts +24 -0
- package/dist/org/invite-member-dialog.stories.d.ts.map +1 -0
- package/dist/org/invite-member-dialog.stories.js +34 -0
- package/dist/org/invite-member-dialog.stories.js.map +1 -0
- package/dist/org/team-hero-banner.stories.d.ts +25 -0
- package/dist/org/team-hero-banner.stories.d.ts.map +1 -0
- package/dist/org/team-hero-banner.stories.js +53 -0
- package/dist/org/team-hero-banner.stories.js.map +1 -0
- package/dist/org/team-member-menu.stories.d.ts +19 -0
- package/dist/org/team-member-menu.stories.d.ts.map +1 -0
- package/dist/org/team-member-menu.stories.js +27 -0
- package/dist/org/team-member-menu.stories.js.map +1 -0
- package/dist/org/team-member-row.stories.d.ts +26 -0
- package/dist/org/team-member-row.stories.d.ts.map +1 -0
- package/dist/org/team-member-row.stories.js +61 -0
- package/dist/org/team-member-row.stories.js.map +1 -0
- package/dist/org/team-pending-row.stories.d.ts +23 -0
- package/dist/org/team-pending-row.stories.d.ts.map +1 -0
- package/dist/org/team-pending-row.stories.js +45 -0
- package/dist/org/team-pending-row.stories.js.map +1 -0
- package/package.json +13 -4
- package/src/offer/offer-document.print.css +72 -0
- package/src/theme/tokens.css +78 -0
- package/dist/components/sidebar.d.ts +0 -68
- package/dist/components/sidebar.d.ts.map +0 -1
- package/dist/components/sidebar.js +0 -208
- package/dist/components/sidebar.js.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification-list.stories.js","sourceRoot":"","sources":["../../src/notifications/notification-list.stories.tsx"],"names":[],"mappings":";AAEA,OAAO,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AACzE,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,EAAE,oBAAoB,EAAE,MAAM,yBAAyB,CAAC;AAG/D,8EAA8E;AAC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AEF,MAAM,CAAC,MAAM,WAAW,GAAU;IAChC,IAAI,EAAE;QACJ,WAAW,EAAE,IAAI;KAClB;CACF,CAAC;AAEF,MAAM,CAAC,MAAM,UAAU,GAAU;IAC/B,IAAI,EAAE;QACJ,UAAU,EAAE,IAAI;QAChB,WAAW,EAAE,IAAI;KAClB;CACF,CAAC;AAEF,MAAM,CAAC,MAAM,OAAO,GAAU;IAC5B,IAAI,EAAE;QACJ,OAAO,EAAE,IAAI;QACb,QAAQ,EAAE,CAAC;KACZ;CACF,CAAC;AAEF,MAAM,CAAC,MAAM,YAAY,GAAU;IACjC,IAAI,EAAE;QACJ,OAAO,EAAE,IAAI;QACb,UAAU,EAAE,GAAG,EAAE,GAAE,CAAC;KACrB;CACF,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { StoryObj } from "@storybook/react-vite";
|
|
2
|
+
import { NotificationPage } from "./notification-page";
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof NotificationPage;
|
|
6
|
+
tags: string[];
|
|
7
|
+
parameters: {
|
|
8
|
+
layout: string;
|
|
9
|
+
};
|
|
10
|
+
args: {
|
|
11
|
+
onNavigate: () => void;
|
|
12
|
+
};
|
|
13
|
+
};
|
|
14
|
+
export default meta;
|
|
15
|
+
type Story = StoryObj<typeof meta>;
|
|
16
|
+
export declare const Default: Story;
|
|
17
|
+
export declare const Empty: Story;
|
|
18
|
+
export declare const AllRead: Story;
|
|
19
|
+
export declare const Loading: Story;
|
|
20
|
+
//# sourceMappingURL=notification-page.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification-page.stories.d.ts","sourceRoot":"","sources":["../../src/notifications/notification-page.stories.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAQ,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAE5D,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAoIvD,QAAA,MAAM,IAAI;;;;;;;;;;CAQ+B,CAAC;AAE1C,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,IAAI,CAAC,CAAC;AAMnC,eAAO,MAAM,OAAO,EAAE,KAErB,CAAC;AAEF,eAAO,MAAM,KAAK,EAAE,KAEnB,CAAC;AAEF,eAAO,MAAM,OAAO,EAAE,KASrB,CAAC;AAEF,eAAO,MAAM,OAAO,EAAE,KAIrB,CAAC"}
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
|
|
3
|
+
import { NotificationPage } from "./notification-page";
|
|
4
|
+
import { NotificationProvider } from "./notification-provider";
|
|
5
|
+
// ---------------------------------------------------------------------------
|
|
6
|
+
// Mock data
|
|
7
|
+
// ---------------------------------------------------------------------------
|
|
8
|
+
const hoursAgo = (h) => new Date(Date.now() - h * 60 * 60 * 1000).toISOString();
|
|
9
|
+
const daysAgo = (d) => new Date(Date.now() - d * 24 * 60 * 60 * 1000).toISOString();
|
|
10
|
+
const mockList = [
|
|
11
|
+
{
|
|
12
|
+
id: "n1",
|
|
13
|
+
type: "match",
|
|
14
|
+
title: "New match: Grenache 2021",
|
|
15
|
+
message: "94% match on Systembolaget Q3 tender",
|
|
16
|
+
isRead: false,
|
|
17
|
+
isDismissed: false,
|
|
18
|
+
createdAt: hoursAgo(1),
|
|
19
|
+
data: { matchId: "match-1" },
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
id: "n2",
|
|
23
|
+
type: "offer_status_update",
|
|
24
|
+
title: "Counter-offer received",
|
|
25
|
+
message: "Cantina Sant'Andrea proposed EUR 14.20 / bottle",
|
|
26
|
+
isRead: false,
|
|
27
|
+
isDismissed: false,
|
|
28
|
+
createdAt: hoursAgo(3),
|
|
29
|
+
data: { offerId: "offer-1" },
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
id: "n3",
|
|
33
|
+
type: "partnership_request",
|
|
34
|
+
title: "Partnership request",
|
|
35
|
+
message: "Vinoteca Global wants to partner with you",
|
|
36
|
+
isRead: true,
|
|
37
|
+
isDismissed: false,
|
|
38
|
+
createdAt: hoursAgo(8),
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
id: "n4",
|
|
42
|
+
type: "tender_new",
|
|
43
|
+
title: "New tender published",
|
|
44
|
+
message: "Alko Finland - Organic Red Wines",
|
|
45
|
+
isRead: true,
|
|
46
|
+
isDismissed: false,
|
|
47
|
+
createdAt: daysAgo(2),
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
id: "n5",
|
|
51
|
+
type: "partnership_approved",
|
|
52
|
+
title: "Partnership approved",
|
|
53
|
+
message: "Northern Cellars is now your approved partner",
|
|
54
|
+
isRead: true,
|
|
55
|
+
isDismissed: false,
|
|
56
|
+
createdAt: daysAgo(3),
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
id: "n6",
|
|
60
|
+
type: "global_announcement",
|
|
61
|
+
title: "Platform update",
|
|
62
|
+
message: "New AI matching engine available",
|
|
63
|
+
isRead: true,
|
|
64
|
+
isDismissed: false,
|
|
65
|
+
createdAt: daysAgo(5),
|
|
66
|
+
},
|
|
67
|
+
];
|
|
68
|
+
// ---------------------------------------------------------------------------
|
|
69
|
+
// Config factory
|
|
70
|
+
// ---------------------------------------------------------------------------
|
|
71
|
+
function buildConfig(opts) {
|
|
72
|
+
const notifications = opts.notifications ?? [];
|
|
73
|
+
const unread = opts.unread ?? notifications.filter((n) => !n.isRead).length;
|
|
74
|
+
const list = async () => {
|
|
75
|
+
if (opts.delay) {
|
|
76
|
+
await new Promise((r) => setTimeout(r, opts.delay));
|
|
77
|
+
}
|
|
78
|
+
return { notifications, hasMore: false };
|
|
79
|
+
};
|
|
80
|
+
return {
|
|
81
|
+
api: {
|
|
82
|
+
list,
|
|
83
|
+
unreadCount: async () => ({ count: unread }),
|
|
84
|
+
markRead: async () => { },
|
|
85
|
+
markAllRead: async () => { },
|
|
86
|
+
dismiss: async () => { },
|
|
87
|
+
},
|
|
88
|
+
resolveRoute: (type, data) => {
|
|
89
|
+
if (type === "match" && data?.matchId)
|
|
90
|
+
return `/matches/${data.matchId}`;
|
|
91
|
+
if (type === "offer_status_update" && data?.offerId)
|
|
92
|
+
return `/offers/${data.offerId}`;
|
|
93
|
+
return "#";
|
|
94
|
+
},
|
|
95
|
+
};
|
|
96
|
+
}
|
|
97
|
+
function withConfig(config) {
|
|
98
|
+
return (Story) => {
|
|
99
|
+
const qc = new QueryClient({
|
|
100
|
+
defaultOptions: { queries: { retry: false } },
|
|
101
|
+
});
|
|
102
|
+
return (_jsx(QueryClientProvider, { client: qc, children: _jsx(NotificationProvider, { config: config, children: _jsx(Story, {}) }) }));
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
// ---------------------------------------------------------------------------
|
|
106
|
+
// Meta
|
|
107
|
+
// ---------------------------------------------------------------------------
|
|
108
|
+
const meta = {
|
|
109
|
+
title: "Notifications/NotificationPage",
|
|
110
|
+
component: NotificationPage,
|
|
111
|
+
tags: ["autodocs"],
|
|
112
|
+
parameters: { layout: "padded" },
|
|
113
|
+
args: {
|
|
114
|
+
onNavigate: () => { },
|
|
115
|
+
},
|
|
116
|
+
};
|
|
117
|
+
export default meta;
|
|
118
|
+
// ---------------------------------------------------------------------------
|
|
119
|
+
// Stories
|
|
120
|
+
// ---------------------------------------------------------------------------
|
|
121
|
+
export const Default = {
|
|
122
|
+
decorators: [withConfig(buildConfig({ notifications: mockList }))],
|
|
123
|
+
};
|
|
124
|
+
export const Empty = {
|
|
125
|
+
decorators: [withConfig(buildConfig({ notifications: [], unread: 0 }))],
|
|
126
|
+
};
|
|
127
|
+
export const AllRead = {
|
|
128
|
+
decorators: [
|
|
129
|
+
withConfig(buildConfig({
|
|
130
|
+
notifications: mockList.map((n) => ({ ...n, isRead: true })),
|
|
131
|
+
unread: 0,
|
|
132
|
+
})),
|
|
133
|
+
],
|
|
134
|
+
};
|
|
135
|
+
export const Loading = {
|
|
136
|
+
decorators: [
|
|
137
|
+
withConfig(buildConfig({ notifications: mockList, delay: 10_000 })),
|
|
138
|
+
],
|
|
139
|
+
};
|
|
140
|
+
//# sourceMappingURL=notification-page.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification-page.stories.js","sourceRoot":"","sources":["../../src/notifications/notification-page.stories.tsx"],"names":[],"mappings":";AAEA,OAAO,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AACzE,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,EAAE,oBAAoB,EAAE,MAAM,yBAAyB,CAAC;AAO/D,8EAA8E;AAC9E,YAAY;AACZ,8EAA8E;AAE9E,MAAM,QAAQ,GAAG,CAAC,CAAS,EAAE,EAAE,CAC7B,IAAI,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC,CAAC,WAAW,EAAE,CAAC;AAC1D,MAAM,OAAO,GAAG,CAAC,CAAS,EAAE,EAAE,CAC5B,IAAI,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC,CAAC,WAAW,EAAE,CAAC;AAE/D,MAAM,QAAQ,GAAmB;IAC/B;QACE,EAAE,EAAE,IAAI;QACR,IAAI,EAAE,OAAO;QACb,KAAK,EAAE,0BAA0B;QACjC,OAAO,EAAE,sCAAsC;QAC/C,MAAM,EAAE,KAAK;QACb,WAAW,EAAE,KAAK;QAClB,SAAS,EAAE,QAAQ,CAAC,CAAC,CAAC;QACtB,IAAI,EAAE,EAAE,OAAO,EAAE,SAAS,EAAE;KAC7B;IACD;QACE,EAAE,EAAE,IAAI;QACR,IAAI,EAAE,qBAAqB;QAC3B,KAAK,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@@ -0,0 +1,21 @@
|
|
|
1
|
+
import type { StoryObj } from "@storybook/react-vite";
|
|
2
|
+
import { NotificationTray } from "./notification-tray";
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof NotificationTray;
|
|
6
|
+
tags: string[];
|
|
7
|
+
parameters: {
|
|
8
|
+
layout: string;
|
|
9
|
+
};
|
|
10
|
+
args: {
|
|
11
|
+
viewAllHref: string;
|
|
12
|
+
onNavigate: () => void;
|
|
13
|
+
};
|
|
14
|
+
};
|
|
15
|
+
export default meta;
|
|
16
|
+
type Story = StoryObj<typeof meta>;
|
|
17
|
+
export declare const Default: Story;
|
|
18
|
+
export declare const Empty: Story;
|
|
19
|
+
export declare const ManyUnread: Story;
|
|
20
|
+
export declare const Loading: Story;
|
|
21
|
+
//# sourceMappingURL=notification-tray.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification-tray.stories.d.ts","sourceRoot":"","sources":["../../src/notifications/notification-tray.stories.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAQ,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAE5D,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAoHvD,QAAA,MAAM,IAAI;;;;;;;;;;;CAS+B,CAAC;AAE1C,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,IAAI,CAAC,CAAC;AAMnC,eAAO,MAAM,OAAO,EAAE,KAErB,CAAC;AAEF,eAAO,MAAM,KAAK,EAAE,KAEnB,CAAC;AAEF,eAAO,MAAM,UAAU,EAAE,KASxB,CAAC;AAEF,eAAO,MAAM,OAAO,EAAE,KAIrB,CAAC"}
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
|
|
3
|
+
import { NotificationTray } from "./notification-tray";
|
|
4
|
+
import { NotificationProvider } from "./notification-provider";
|
|
5
|
+
// ---------------------------------------------------------------------------
|
|
6
|
+
// Mock data
|
|
7
|
+
// ---------------------------------------------------------------------------
|
|
8
|
+
const hoursAgo = (h) => new Date(Date.now() - h * 60 * 60 * 1000).toISOString();
|
|
9
|
+
const daysAgo = (d) => new Date(Date.now() - d * 24 * 60 * 60 * 1000).toISOString();
|
|
10
|
+
const mockList = [
|
|
11
|
+
{
|
|
12
|
+
id: "n1",
|
|
13
|
+
type: "match",
|
|
14
|
+
title: "New match: Grenache 2021",
|
|
15
|
+
message: "94% match on Systembolaget Q3 tender",
|
|
16
|
+
isRead: false,
|
|
17
|
+
isDismissed: false,
|
|
18
|
+
createdAt: hoursAgo(1),
|
|
19
|
+
data: { matchId: "match-1" },
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
id: "n2",
|
|
23
|
+
type: "offer_status_update",
|
|
24
|
+
title: "Counter-offer received",
|
|
25
|
+
message: "Cantina Sant'Andrea proposed EUR 14.20 / bottle",
|
|
26
|
+
isRead: false,
|
|
27
|
+
isDismissed: false,
|
|
28
|
+
createdAt: hoursAgo(3),
|
|
29
|
+
data: { offerId: "offer-1" },
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
id: "n3",
|
|
33
|
+
type: "partnership_request",
|
|
34
|
+
title: "Partnership request",
|
|
35
|
+
message: "Vinoteca Global wants to partner with you",
|
|
36
|
+
isRead: true,
|
|
37
|
+
isDismissed: false,
|
|
38
|
+
createdAt: hoursAgo(8),
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
id: "n4",
|
|
42
|
+
type: "tender_new",
|
|
43
|
+
title: "New tender published",
|
|
44
|
+
message: "Alko Finland - Organic Red Wines",
|
|
45
|
+
isRead: true,
|
|
46
|
+
isDismissed: false,
|
|
47
|
+
createdAt: daysAgo(2),
|
|
48
|
+
},
|
|
49
|
+
];
|
|
50
|
+
// ---------------------------------------------------------------------------
|
|
51
|
+
// Config factory
|
|
52
|
+
// ---------------------------------------------------------------------------
|
|
53
|
+
function buildConfig(opts) {
|
|
54
|
+
const notifications = opts.notifications ?? [];
|
|
55
|
+
const unread = opts.unread ?? notifications.filter((n) => !n.isRead).length;
|
|
56
|
+
const list = async () => {
|
|
57
|
+
if (opts.delay) {
|
|
58
|
+
await new Promise((r) => setTimeout(r, opts.delay));
|
|
59
|
+
}
|
|
60
|
+
return { notifications, hasMore: false };
|
|
61
|
+
};
|
|
62
|
+
return {
|
|
63
|
+
api: {
|
|
64
|
+
list,
|
|
65
|
+
unreadCount: async () => ({ count: unread }),
|
|
66
|
+
markRead: async () => { },
|
|
67
|
+
markAllRead: async () => { },
|
|
68
|
+
dismiss: async () => { },
|
|
69
|
+
},
|
|
70
|
+
resolveRoute: (type, data) => {
|
|
71
|
+
if (type === "match" && data?.matchId)
|
|
72
|
+
return `/matches/${data.matchId}`;
|
|
73
|
+
if (type === "offer_status_update" && data?.offerId)
|
|
74
|
+
return `/offers/${data.offerId}`;
|
|
75
|
+
return "#";
|
|
76
|
+
},
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
function withConfig(config) {
|
|
80
|
+
return (Story) => {
|
|
81
|
+
const qc = new QueryClient({
|
|
82
|
+
defaultOptions: { queries: { retry: false } },
|
|
83
|
+
});
|
|
84
|
+
return (_jsx(QueryClientProvider, { client: qc, children: _jsx(NotificationProvider, { config: config, children: _jsx("div", { className: "flex min-h-40 items-start justify-end p-8", children: _jsx(Story, {}) }) }) }));
|
|
85
|
+
};
|
|
86
|
+
}
|
|
87
|
+
// ---------------------------------------------------------------------------
|
|
88
|
+
// Meta
|
|
89
|
+
// ---------------------------------------------------------------------------
|
|
90
|
+
const meta = {
|
|
91
|
+
title: "Notifications/NotificationTray",
|
|
92
|
+
component: NotificationTray,
|
|
93
|
+
tags: ["autodocs"],
|
|
94
|
+
parameters: { layout: "fullscreen" },
|
|
95
|
+
args: {
|
|
96
|
+
viewAllHref: "/notifications",
|
|
97
|
+
onNavigate: () => { },
|
|
98
|
+
},
|
|
99
|
+
};
|
|
100
|
+
export default meta;
|
|
101
|
+
// ---------------------------------------------------------------------------
|
|
102
|
+
// Stories
|
|
103
|
+
// ---------------------------------------------------------------------------
|
|
104
|
+
export const Default = {
|
|
105
|
+
decorators: [withConfig(buildConfig({ notifications: mockList }))],
|
|
106
|
+
};
|
|
107
|
+
export const Empty = {
|
|
108
|
+
decorators: [withConfig(buildConfig({ notifications: [], unread: 0 }))],
|
|
109
|
+
};
|
|
110
|
+
export const ManyUnread = {
|
|
111
|
+
decorators: [
|
|
112
|
+
withConfig(buildConfig({
|
|
113
|
+
notifications: mockList.map((n) => ({ ...n, isRead: false })),
|
|
114
|
+
unread: 12,
|
|
115
|
+
})),
|
|
116
|
+
],
|
|
117
|
+
};
|
|
118
|
+
export const Loading = {
|
|
119
|
+
decorators: [
|
|
120
|
+
withConfig(buildConfig({ notifications: mockList, delay: 10_000 })),
|
|
121
|
+
],
|
|
122
|
+
};
|
|
123
|
+
//# sourceMappingURL=notification-tray.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification-tray.stories.js","sourceRoot":"","sources":["../../src/notifications/notification-tray.stories.tsx"],"names":[],"mappings":";AAEA,OAAO,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AACzE,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,EAAE,oBAAoB,EAAE,MAAM,yBAAyB,CAAC;AAO/D,8EAA8E;AAC9E,YAAY;AACZ,8EAA8E;AAE9E,MAAM,QAAQ,GAAG,CAAC,CAAS,EAAE,EAAE,CAC7B,IAAI,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE,GAAG,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC,CAAC,WAAW,EAAE,CAAC;AAC1D,MAAM,OAAO,GAAG,CAAC,CAAS,EAAE,EAAE,CAC5B,IAAI,IAAI,CA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V,UAAU,CAAC,WAAW,CAAC,EAAE,aAAa,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,EAAE,CAAC,CAAC;KACpE;CACF,CAAC"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { StoryObj } from "@storybook/react-vite";
|
|
2
|
+
import { PushPromptBanner } from "./push-prompt-banner";
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof PushPromptBanner;
|
|
6
|
+
tags: string[];
|
|
7
|
+
parameters: {
|
|
8
|
+
layout: string;
|
|
9
|
+
};
|
|
10
|
+
argTypes: {
|
|
11
|
+
variant: {
|
|
12
|
+
control: "radio";
|
|
13
|
+
options: string[];
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
args: {
|
|
17
|
+
variant: "rich";
|
|
18
|
+
onEnable: () => void;
|
|
19
|
+
onDismiss: () => void;
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
export default meta;
|
|
23
|
+
type Story = StoryObj<typeof meta>;
|
|
24
|
+
export declare const Rich: Story;
|
|
25
|
+
export declare const Compact: Story;
|
|
26
|
+
export declare const CustomLabels: Story;
|
|
27
|
+
//# sourceMappingURL=push-prompt-banner.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"push-prompt-banner.stories.d.ts","sourceRoot":"","sources":["../../src/notifications/push-prompt-banner.stories.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAQ,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAExD,QAAA,MAAM,IAAI;;;;;;;;;;;;;;;;;;CAa+B,CAAC;AAE1C,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,IAAI,CAAC,CAAC;AAEnC,eAAO,MAAM,IAAI,EAAE,KAAU,CAAC;AAE9B,eAAO,MAAM,OAAO,EAAE,KAIrB,CAAC;AAEF,eAAO,MAAM,YAAY,EAAE,KAU1B,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { PushPromptBanner } from "./push-prompt-banner";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: "Notifications/PushPromptBanner",
|
|
4
|
+
component: PushPromptBanner,
|
|
5
|
+
tags: ["autodocs"],
|
|
6
|
+
parameters: { layout: "padded" },
|
|
7
|
+
argTypes: {
|
|
8
|
+
variant: { control: "radio", options: ["rich", "compact"] },
|
|
9
|
+
},
|
|
10
|
+
args: {
|
|
11
|
+
variant: "rich",
|
|
12
|
+
onEnable: () => { },
|
|
13
|
+
onDismiss: () => { },
|
|
14
|
+
},
|
|
15
|
+
};
|
|
16
|
+
export default meta;
|
|
17
|
+
export const Rich = {};
|
|
18
|
+
export const Compact = {
|
|
19
|
+
args: {
|
|
20
|
+
variant: "compact",
|
|
21
|
+
},
|
|
22
|
+
};
|
|
23
|
+
export const CustomLabels = {
|
|
24
|
+
args: {
|
|
25
|
+
labels: {
|
|
26
|
+
heading: "Stay in the loop",
|
|
27
|
+
description: "We'll ping your browser when a producer replies to your offer.",
|
|
28
|
+
enable: "Turn on alerts",
|
|
29
|
+
dismiss: "Not now",
|
|
30
|
+
},
|
|
31
|
+
},
|
|
32
|
+
};
|
|
33
|
+
//# sourceMappingURL=push-prompt-banner.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"push-prompt-banner.stories.js","sourceRoot":"","sources":["../../src/notifications/push-prompt-banner.stories.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAExD,MAAM,IAAI,GAAG;IACX,KAAK,EAAE,gCAAgC;IACvC,SAAS,EAAE,gBAAgB;IAC3B,IAAI,EAAE,CAAC,UAAU,CAAC;IAClB,UAAU,EAAE,EAAE,MAAM,EAAE,QAAQ,EAAE;IAChC,QAAQ,EAAE;QACR,OAAO,EAAE,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,CAAC,MAAM,EAAE,SAAS,CAAC,EAAE;KAC5D;IACD,IAAI,EAAE;QACJ,OAAO,EAAE,MAAM;QACf,QAAQ,EAAE,GAAG,EAAE,GAAE,CAAC;QAClB,SAAS,EAAE,GAAG,EAAE,GAAE,CAAC;KACpB;CACsC,CAAC;AAE1C,eAAe,IAAI,CAAC;AAGpB,MAAM,CAAC,MAAM,IAAI,GAAU,EAAE,CAAC;AAE9B,MAAM,CAAC,MAAM,OAAO,GAAU;IAC5B,IAAI,EAAE;QACJ,OAAO,EAAE,SAAS;KACnB;CACF,CAAC;AAEF,MAAM,CAAC,MAAM,YAAY,GAAU;IACjC,IAAI,EAAE;QACJ,MAAM,EAAE;YACN,OAAO,EAAE,kBAAkB;YAC3B,WAAW,EACT,gEAAgE;YAClE,MAAM,EAAE,gBAAgB;YACxB,OAAO,EAAE,SAAS;SACnB;KACF;CACF,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"opportunity-requirements.test.d.ts","sourceRoot":"","sources":["../../../src/offer/__tests__/opportunity-requirements.test.tsx"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { describe, expect, it } from "vitest";
|
|
3
|
+
import { render } from "@testing-library/react";
|
|
4
|
+
import { OpportunityRequirements } from "../opportunity-requirements";
|
|
5
|
+
describe("OpportunityRequirements — alcohol range rendering", () => {
|
|
6
|
+
it("renders 'X – Y %' when min != max", () => {
|
|
7
|
+
const { container } = render(_jsx(OpportunityRequirements, { alcoholContent: { min: 12.0, max: 14.5 } }));
|
|
8
|
+
const normalised = (container.textContent ?? "").replace(/\s+/g, " ");
|
|
9
|
+
expect(normalised).toMatch(/12.*%.*–.*14\.5.*%/);
|
|
10
|
+
});
|
|
11
|
+
it("collapses min === max to a single 'X %' (Task 5.0 fix)", () => {
|
|
12
|
+
const { container } = render(_jsx(OpportunityRequirements, { alcoholContent: { min: 14, max: 14 } }));
|
|
13
|
+
const normalised = (container.textContent ?? "").replace(/\s+/g, " ");
|
|
14
|
+
expect(normalised).toMatch(/14\s*%/);
|
|
15
|
+
// Pre-fix output was "14 % – 14 %" — the en-dash pair must NOT appear.
|
|
16
|
+
expect(normalised).not.toMatch(/14\s*%\s*–\s*14/);
|
|
17
|
+
});
|
|
18
|
+
it("renders '14 %+' when only min is set", () => {
|
|
19
|
+
const { container } = render(_jsx(OpportunityRequirements, { alcoholContent: { min: 17 } }));
|
|
20
|
+
const normalised = (container.textContent ?? "").replace(/\s+/g, " ");
|
|
21
|
+
expect(normalised).toMatch(/17\s*%\+/);
|
|
22
|
+
});
|
|
23
|
+
it("renders 'up to 14 %' when only max is set", () => {
|
|
24
|
+
const { container } = render(_jsx(OpportunityRequirements, { alcoholContent: { max: 14 } }));
|
|
25
|
+
const normalised = (container.textContent ?? "").replace(/\s+/g, " ");
|
|
26
|
+
expect(normalised).toMatch(/up to 14\s*%/);
|
|
27
|
+
});
|
|
28
|
+
it("omits Alcohol Content row when both bounds null", () => {
|
|
29
|
+
const { container } = render(_jsx(OpportunityRequirements, { alcoholContent: null }));
|
|
30
|
+
expect(container.textContent ?? "").not.toMatch(/Alcohol Content/i);
|
|
31
|
+
});
|
|
32
|
+
});
|
|
33
|
+
//# sourceMappingURL=opportunity-requirements.test.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"opportunity-requirements.test.js","sourceRoot":"","sources":["../../../src/offer/__tests__/opportunity-requirements.test.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,QAAQ,CAAC;AAC9C,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAChD,OAAO,EAAE,uBAAuB,EAAE,MAAM,6BAA6B,CAAC;AAEtE,QAAQ,CAAC,mDAAmD,EAAE,GAAG,EAAE;IACjE,EAA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AAU,CAAC,CAAC;IACzC,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,2CAA2C,EAAE,GAAG,EAAE;QACnD,MAAM,EAAE,SAAS,EAAE,GAAG,MAAM,CAAC,KAAC,uBAAuB,IAAC,cAAc,EAAE,EAAE,GAAG,EAAE,EAAE,EAAE,GAAI,CAAC,CAAC;QACvF,MAAM,UAAU,GAAG,CAAC,SAAS,CAAC,WAAW,IAAI,EAAE,CAAC,CAAC,OAAO,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;QACtE,MAAM,CAAC,UAAU,CAAC,CAAC,OAAO,CAAC,cAAc,CAAC,CAAC;IAC7C,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,iDAAiD,EAAE,GAAG,EAAE;QACzD,MAAM,EAAE,SAAS,EAAE,GAAG,MAAM,CAAC,KAAC,uBAAuB,IAAC,cAAc,EAAE,IAAI,GAAI,CAAC,CAAC;QAChF,MAAM,CAAC,SAAS,CAAC,WAAW,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,kBAAkB,CAAC,CAAC;IACtE,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { OfferAttachmentItem } from "./types";
|
|
2
|
+
export interface AttachmentsCardProps {
|
|
3
|
+
attachments: OfferAttachmentItem[];
|
|
4
|
+
onOpen: (attachment: OfferAttachmentItem) => void;
|
|
5
|
+
onDelete?: (attachment: OfferAttachmentItem) => void;
|
|
6
|
+
className?: string;
|
|
7
|
+
}
|
|
8
|
+
export declare function AttachmentsCard({ attachments, onOpen, onDelete, className, }: AttachmentsCardProps): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
//# sourceMappingURL=attachments-card.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"attachments-card.d.ts","sourceRoot":"","sources":["../../src/offer/attachments-card.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,SAAS,CAAC;AAEnD,MAAM,WAAW,oBAAoB;IACnC,WAAW,EAAE,mBAAmB,EAAE,CAAC;IACnC,MAAM,EAAE,CAAC,UAAU,EAAE,mBAAmB,KAAK,IAAI,CAAC;IAClD,QAAQ,CAAC,EAAE,CAAC,UAAU,EAAE,mBAAmB,KAAK,IAAI,CAAC;IACrD,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAQD,wBAAgB,eAAe,CAAC,EAC9B,WAAW,EACX,MAAM,EACN,QAAQ,EACR,SAAS,GACV,EAAE,oBAAoB,2CAmDtB"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { FileText, Trash2 } from "lucide-react";
|
|
3
|
+
import { cn } from "../lib/utils";
|
|
4
|
+
import { ShadcnBadge as Badge } from "../components/shadcn-badge";
|
|
5
|
+
import { ShadcnButton as Button } from "../components/shadcn-button";
|
|
6
|
+
function formatBytes(n) {
|
|
7
|
+
if (n < 1024)
|
|
8
|
+
return `${n} B`;
|
|
9
|
+
if (n < 1024 * 1024)
|
|
10
|
+
return `${(n / 1024).toFixed(1)} KB`;
|
|
11
|
+
return `${(n / 1024 / 1024).toFixed(1)} MB`;
|
|
12
|
+
}
|
|
13
|
+
export function AttachmentsCard({ attachments, onOpen, onDelete, className, }) {
|
|
14
|
+
return (_jsxs("section", { "aria-labelledby": "attachments-heading", className: cn("rounded-2xl border border-border/60 bg-card p-4", className), children: [_jsx("h2", { id: "attachments-heading", className: "text-xs/5 font-semibold uppercase tracking-wide text-muted-foreground", children: "Attachments" }), attachments.length === 0 ? (_jsx("p", { className: "mt-3 text-sm/6 text-muted-foreground", children: "No attachments yet." })) : (_jsx("ul", { className: "mt-3 grid grid-cols-1 gap-2 sm:grid-cols-2", children: attachments.map((a) => (_jsxs("li", { className: "flex items-start gap-3 rounded-lg border border-border/60 p-3", children: [_jsx(FileText, { "aria-hidden": true, className: "size-5 shrink-0 text-muted-foreground" }), _jsxs("div", { className: "min-w-0 flex-1", children: [_jsx("button", { type: "button", onClick: () => onOpen(a), className: "block truncate text-left text-sm/6 font-medium hover:underline", "aria-label": `Open ${a.fileName}`, children: a.fileName }), _jsxs("div", { className: "mt-1 flex flex-wrap items-center gap-2 text-xs text-muted-foreground", children: [_jsx("span", { children: formatBytes(a.sizeBytes) }), _jsx(Badge, { variant: "ghost", className: "text-[10px]", children: a.sourceLabel ?? a.source })] })] }), onDelete && (_jsx(Button, { variant: "ghost", size: "icon", "aria-label": `Remove ${a.fileName}`, onClick: () => onDelete(a), children: _jsx(Trash2, { "aria-hidden": true, className: "size-4" }) }))] }, a.id))) }))] }));
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=attachments-card.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"attachments-card.js","sourceRoot":"","sources":["../../src/offer/attachments-card.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,cAAc,CAAC;AAChD,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AAClC,OAAO,EAAE,WAAW,IAAI,KAAK,EAAE,MAAM,4BAA4B,CAAC;AAClE,OAAO,EAAE,YAAY,IAAI,MAAM,EAAE,MAAM,6BAA6B,CAAC;AAUrE,SAAS,WAAW,CAAC,CAAS;IAC5B,IAAI,CAAC,GAAG,IAAI;QAAE,OAAO,GAAG,CAAC,IAAI,CAAC;IAC9B,IAAI,CAAC,GAAG,IAAI,GAAG,IAAI;QAAE,OAAO,GAAG,CAAC,CAAC,GAAG,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC;IAC1D,OAAO,GAAG,CAAC,CAAC,GAAG,IAAI,GAAG,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,KAAK,CAAC;AAC9C,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,EAC9B,WAAW,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ACN,IACO,CACX,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { StoryObj } from "@storybook/react-vite";
|
|
2
|
+
import { AttachmentsCard } from "./attachments-card";
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof AttachmentsCard;
|
|
6
|
+
tags: string[];
|
|
7
|
+
parameters: {
|
|
8
|
+
layout: string;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof meta>;
|
|
13
|
+
export declare const Default: Story;
|
|
14
|
+
export declare const Empty: Story;
|
|
15
|
+
export declare const MixedSources: Story;
|
|
16
|
+
export declare const WithDelete: Story;
|
|
17
|
+
//# sourceMappingURL=attachments-card.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"attachments-card.stories.d.ts","sourceRoot":"","sources":["../../src/offer/attachments-card.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAQ,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD,QAAA,MAAM,IAAI;;;;;;;CAK8B,CAAC;AAEzC,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,IAAI,CAAC,CAAC;AAQnC,eAAO,MAAM,OAAO,EAAE,KAAmD,CAAC;AAC1E,eAAO,MAAM,KAAK,EAAE,KAAuD,CAAC;AAC5E,eAAO,MAAM,YAAY,EAAE,KAAmD,CAAC;AAC/E,eAAO,MAAM,UAAU,EAAE,KAMxB,CAAC"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { AttachmentsCard } from "./attachments-card";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: "Offer/AttachmentsCard",
|
|
4
|
+
component: AttachmentsCard,
|
|
5
|
+
tags: ["autodocs"],
|
|
6
|
+
parameters: { layout: "padded" },
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
const attachments = [
|
|
10
|
+
{ id: "a1", fileName: "product-sheet.pdf", mimeType: "application/pdf", sizeBytes: 245_000, uploadedAt: "2026-04-18T10:00:00Z", source: "formal", sourceLabel: "formal attachment" },
|
|
11
|
+
{ id: "a2", fileName: "lab-certificate.pdf", mimeType: "application/pdf", sizeBytes: 120_000, uploadedAt: "2026-04-19T11:15:00Z", source: "chat", sourceLabel: "shared in chat" },
|
|
12
|
+
{ id: "a3", fileName: "counter-r2-terms.pdf", mimeType: "application/pdf", sizeBytes: 95_000, uploadedAt: "2026-04-19T13:42:00Z", source: "round", sourceLabel: "attached to R2 counter" },
|
|
13
|
+
];
|
|
14
|
+
export const Default = { args: { attachments, onOpen: () => { } } };
|
|
15
|
+
export const Empty = { args: { attachments: [], onOpen: () => { } } };
|
|
16
|
+
export const MixedSources = { args: { attachments, onOpen: () => { } } };
|
|
17
|
+
export const WithDelete = {
|
|
18
|
+
args: {
|
|
19
|
+
attachments,
|
|
20
|
+
onOpen: () => { },
|
|
21
|
+
onDelete: () => { },
|
|
22
|
+
},
|
|
23
|
+
};
|
|
24
|
+
//# sourceMappingURL=attachments-card.stories.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"attachments-card.stories.js","sourceRoot":"","sources":["../../src/offer/attachments-card.stories.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD,MAAM,IAAI,GAAG;IACX,KAAK,EAAE,uBAAuB;IAC9B,SAAS,EAAE,eAAe;IAC1B,IAAI,EAAE,CAAC,UAAU,CAAC;IAClB,UAAU,EAAE,EAAE,MAAM,EAAE,QAAQ,EAAE;CACM,CAAC;AAEzC,eAAe,IAAI,CAAC;AAGpB,MAAM,WAAW,GAAG;IAClB,EAAE,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,mBAAmB,EAAE,QAAQ,EAAE,iBAAi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
|
+
export declare function BuyerNotesCard({ notes, className }: BuyerNotesCardProps): import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
//# sourceMappingURL=buyer-notes-card.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"buyer-notes-card.d.ts","sourceRoot":"","sources":["../../src/offer/buyer-notes-card.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAEzC,MAAM,WAAW,mBAAmB;IAClC,KAAK,EAAE,SAAS,EAAE,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,wBAAgB,cAAc,CAAC,EAAE,KAAK,EAAE,SAAS,EAAE,EAAE,mBAAmB,2CAuBvE"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { cn } from "../lib/utils";
|
|
3
|
+
export function BuyerNotesCard({ notes, className }) {
|
|
4
|
+
return (_jsxs("section", { "aria-labelledby": "notes-heading", className: cn("rounded-2xl border border-border/60 bg-card p-4", className), children: [_jsx("h2", { id: "notes-heading", className: "text-xs/5 font-semibold uppercase tracking-wide text-muted-foreground", children: "Buyer's notes" }), notes.length === 0 ? (_jsx("p", { className: "mt-3 text-sm/6 text-muted-foreground", children: "No buyer notes." })) : (_jsx("dl", { className: "mt-3 space-y-3", children: notes.map((n) => (_jsxs("div", { children: [_jsx("dt", { className: "text-xs uppercase tracking-wide text-muted-foreground", children: n.label }), _jsx("dd", { className: "mt-1 whitespace-pre-line text-sm/6", children: n.value })] }, n.id))) }))] }));
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=buyer-notes-card.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"buyer-notes-card.js","sourceRoot":"","sources":["../../src/offer/buyer-notes-card.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,EAAE,EAAE,MAAM,cAAc,CAAC;AAQlC,MAAM,UAAU,cAAc,CAAC,EAAE,KAAK,EAAE,SAAS,EAAuB;IACtE,OAAO,CACL,sCACkB,eAAe,EAC/B,SAAS,EAAE,EAAE,CAAC,iDAAiD,EAAE,SAAS,CAAC,aAE3E,aAAI,EAAE,EAAC,eAAe,EAAC,SAAS,EAAC,uEAAuE,8BAEnG,EACJ,KAAK,CAAC,MAAM,KAAK,CAAC,CAAC,CAAC,CAAC,CACpB,YAAG,SAAS,EAAC,sCAAsC,gCAAoB,CACxE,CAAC,CAAC,CAAC,CACF,aAAI,SAAS,EAAC,gBAAgB,YAC3B,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAChB,0BACE,aAAI,SAAS,EAAC,uDAAuD,YAAE,CAAC,CAAC,KAAK,GAAM,EACpF,aAAI,SAAS,EAAC,oCAAoC,YAAE,CAAC,CAAC,KAAK,GAAM,KAFzD,CAAC,CAAC,EAAE,CAGR,CACP,CAAC,GACC,CACN,IACO,CACX,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { StoryObj } from "@storybook/react-vite";
|
|
2
|
+
import { BuyerNotesCard } from "./buyer-notes-card";
|
|
3
|
+
declare const meta: {
|
|
4
|
+
title: string;
|
|
5
|
+
component: typeof BuyerNotesCard;
|
|
6
|
+
tags: string[];
|
|
7
|
+
parameters: {
|
|
8
|
+
layout: string;
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
export default meta;
|
|
12
|
+
type Story = StoryObj<typeof meta>;
|
|
13
|
+
export declare const Default: Story;
|
|
14
|
+
export declare const Empty: Story;
|
|
15
|
+
export declare const AllFieldsPopulated: Story;
|
|
16
|
+
//# sourceMappingURL=buyer-notes-card.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"buyer-notes-card.stories.d.ts","sourceRoot":"","sources":["../../src/offer/buyer-notes-card.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAQ,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAEpD,QAAA,MAAM,IAAI;;;;;;;CAK6B,CAAC;AAExC,eAAe,IAAI,CAAC;AACpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,IAAI,CAAC,CAAC;AAQnC,eAAO,MAAM,OAAO,EAAE,KAA2B,CAAC;AAClD,eAAO,MAAM,KAAK,EAAE,KAA+B,CAAC;AACpD,eAAO,MAAM,kBAAkB,EAAE,KAQhC,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { BuyerNotesCard } from "./buyer-notes-card";
|
|
2
|
+
const meta = {
|
|
3
|
+
title: "Offer/BuyerNotesCard",
|
|
4
|
+
component: BuyerNotesCard,
|
|
5
|
+
tags: ["autodocs"],
|
|
6
|
+
parameters: { layout: "padded" },
|
|
7
|
+
};
|
|
8
|
+
export default meta;
|
|
9
|
+
const notes = [
|
|
10
|
+
{ id: "styleTasteProfile", label: "Style / taste profile", value: "Fresh, fruit-forward, medium-bodied with bright acidity." },
|
|
11
|
+
{ id: "agingProcess", label: "Aging process", value: "At least 12 months in Slavonian oak, 6 months in bottle." },
|
|
12
|
+
{ id: "color", label: "Color", value: "Deep ruby with garnet reflections" },
|
|
13
|
+
];
|
|
14
|
+
export const Default = { args: { notes } };
|
|
15
|
+
export const Empty = { args: { notes: [] } };
|
|
16
|
+
export const AllFieldsPopulated = {
|
|
17
|
+
args: {
|
|
18
|
+
notes: [
|
|
19
|
+
...notes,
|
|
20
|
+
{ id: "distribution", label: "Distribution", value: "On-trade preferred" },
|
|
21
|
+
{ id: "otherRequirements", label: "Other requirements", value: "Labels in Italian + English; case of 6." },
|
|
22
|
+
],
|
|
23
|
+
},
|
|
24
|
+
};
|
|
25
|
+
//# sourceMappingURL=buyer-notes-card.stories.js.map
|