themelia-react-ui 1.0.2 → 2.0.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/CHANGELOG.md +281 -1
- package/README.md +10 -5
- package/dist/{accordion-BRTcsp8J.js → accordion-CQXVcd7Q.js} +13 -13
- package/dist/accordion-CQXVcd7Q.js.map +1 -0
- package/dist/action-menu-BTpyPWJ2.js +264 -0
- package/dist/action-menu-BTpyPWJ2.js.map +1 -0
- package/dist/{affordance-geometry.generated-CL84ZN9A.js → affordance-geometry.generated-CCIXb2A1.js} +7 -2
- package/dist/affordance-geometry.generated-CCIXb2A1.js.map +1 -0
- package/dist/{ai-artifact-DLVdK0Py.js → ai-artifact-2PQ2fItc.js} +171 -176
- package/dist/ai-artifact-2PQ2fItc.js.map +1 -0
- package/dist/{app-shell-C_fKpljx.js → app-shell-BE_j8-AT.js} +4 -4
- package/dist/{app-shell-C_fKpljx.js.map → app-shell-BE_j8-AT.js.map} +1 -1
- package/dist/{attachment-DbjUWsP0.js → attachment-q69dlt5Y.js} +9 -9
- package/dist/{attachment-DbjUWsP0.js.map → attachment-q69dlt5Y.js.map} +1 -1
- package/dist/{auth-CAQcasMV.js → auth-M3vGMgDR.js} +42 -42
- package/dist/{auth-CAQcasMV.js.map → auth-M3vGMgDR.js.map} +1 -1
- package/dist/{avatar-Bu2HhitA.js → avatar-djdaaQ_s.js} +14 -12
- package/dist/avatar-djdaaQ_s.js.map +1 -0
- package/dist/{badge-CzId1Wlm.js → badge-0tATj-tW.js} +9 -9
- package/dist/badge-0tATj-tW.js.map +1 -0
- package/dist/base/accordion.js +1 -1
- package/dist/base/action-menu.js +1 -1
- package/dist/base/attachment.js +1 -1
- package/dist/base/avatar.js +1 -1
- package/dist/base/badge.js +1 -1
- package/dist/base/buttons.js +2 -2
- package/dist/base/cards.js +2 -2
- package/dist/base/carousel.js +11 -11
- package/dist/base/carousel.js.map +1 -1
- package/dist/base/cascader.js +244 -222
- package/dist/base/cascader.js.map +1 -1
- package/dist/base/chart.js +1 -1
- package/dist/base/choice-inputs.js +2 -2
- package/dist/base/code-block.js +1 -1
- package/dist/base/combobox.js +1 -1
- package/dist/base/command.js +1 -1
- package/dist/base/copyable.js +1 -1
- package/dist/base/date-pickers.js +2 -2
- package/dist/base/display.js +6 -6
- package/dist/base/feedback.js +3 -3
- package/dist/base/forms-numeric.js +1 -1
- package/dist/base/forms.js +2 -2
- package/dist/base/inline-edit.js +81 -76
- package/dist/base/inline-edit.js.map +1 -1
- package/dist/base/item.js +1 -1
- package/dist/base/media-gallery.js +1 -1
- package/dist/base/navigation.js +6 -6
- package/dist/base/popover-menu.js +1 -1
- package/dist/base/popover.js +1 -1
- package/dist/base/qr-code.js +7 -4
- package/dist/base/qr-code.js.map +1 -1
- package/dist/base/repeaters.js +42 -42
- package/dist/base/repeaters.js.map +1 -1
- package/dist/base/sheet.js +1 -1
- package/dist/base/sidebar.js +1 -1
- package/dist/base/signature-pad.js +9 -9
- package/dist/base/signature-pad.js.map +1 -1
- package/dist/base/skeleton.js +1 -1
- package/dist/base/spinner.js +1 -1
- package/dist/base/structure.js +1 -1
- package/dist/base/table.js +1 -1
- package/dist/base/text-inputs.js +2 -2
- package/dist/base/toaster.js +4 -4
- package/dist/base/toaster.js.map +1 -1
- package/dist/base/tree.js +1 -1
- package/dist/base/upload-queue.js +1 -1
- package/dist/base/upload.js +3 -3
- package/dist/base/value-inputs.js +1 -1
- package/dist/blocks/admin.js +229 -220
- package/dist/blocks/admin.js.map +1 -1
- package/dist/blocks/ai.js +147 -180
- package/dist/blocks/ai.js.map +1 -1
- package/dist/blocks/analytics/usage-card.js +1 -1
- package/dist/blocks/analytics.js +530 -523
- package/dist/blocks/analytics.js.map +1 -1
- package/dist/blocks/collaboration.js +1 -1
- package/dist/blocks/commerce/receipt.js +1 -1
- package/dist/blocks/commerce.js +1390 -1516
- package/dist/blocks/commerce.js.map +1 -1
- package/dist/blocks/data-display.js +1 -1
- package/dist/blocks/onboarding.js +5 -5
- package/dist/blocks/planning.js +82 -91
- package/dist/blocks/planning.js.map +1 -1
- package/dist/blocks/timelines.js +1 -1
- package/dist/{breadcrumbs-BuYz5SDU.js → breadcrumbs-BG_FfMK4.js} +5 -5
- package/dist/{breadcrumbs-BuYz5SDU.js.map → breadcrumbs-BG_FfMK4.js.map} +1 -1
- package/dist/{button-BZDasD04.js → button-BS3KDg00.js} +185 -162
- package/dist/button-BS3KDg00.js.map +1 -0
- package/dist/{button-BZyfTvwm.js → button-R9CCoH7A.js} +2 -2
- package/dist/{button-BZyfTvwm.js.map → button-R9CCoH7A.js.map} +1 -1
- package/dist/{buttons-D_6KJvEE.js → buttons-DS0ZIwJ_.js} +11 -11
- package/dist/buttons-DS0ZIwJ_.js.map +1 -0
- package/dist/{cards-qGSErLw_.js → cards-QoJ4syG9.js} +7 -7
- package/dist/{cards-qGSErLw_.js.map → cards-QoJ4syG9.js.map} +1 -1
- package/dist/{chart-Bsc5BICK.js → chart-DwYRKKc-.js} +17 -15
- package/dist/chart-DwYRKKc-.js.map +1 -0
- package/dist/checkbox-B7ygNTYp.js +35 -0
- package/dist/checkbox-B7ygNTYp.js.map +1 -0
- package/dist/choice-inputs-DrJ17tpL.js +752 -0
- package/dist/choice-inputs-DrJ17tpL.js.map +1 -0
- package/dist/{code-block-DzHKRybS.js → code-block-CD0B7M93.js} +19 -19
- package/dist/{code-block-DzHKRybS.js.map → code-block-CD0B7M93.js.map} +1 -1
- package/dist/{collapsible-ClvC7Bj3.js → collapsible-oMUGM4tr.js} +3 -3
- package/dist/{collapsible-ClvC7Bj3.js.map → collapsible-oMUGM4tr.js.map} +1 -1
- package/dist/{collection-content-D6S8cv_n.js → collection-content-Ys-OZOkY.js} +3 -3
- package/dist/{collection-content-D6S8cv_n.js.map → collection-content-Ys-OZOkY.js.map} +1 -1
- package/dist/{combobox-BFnbJJp3.js → combobox-6dvVny2q.js} +96 -97
- package/dist/combobox-6dvVny2q.js.map +1 -0
- package/dist/{combobox-hozNwUcc.js → combobox-CB7039j7.js} +326 -308
- package/dist/combobox-CB7039j7.js.map +1 -0
- package/dist/{command-BnmSchli.js → command-kPMPjIxJ.js} +34 -30
- package/dist/command-kPMPjIxJ.js.map +1 -0
- package/dist/{comments-u5L0OGip.js → comments-You0Bzbr.js} +349 -348
- package/dist/comments-You0Bzbr.js.map +1 -0
- package/dist/components/base/accordion/accordion-variants.d.ts +3 -3
- package/dist/components/base/action-menu/action-menu.d.ts +7 -2
- package/dist/components/base/avatar/stacked-avatars.d.ts +5 -4
- package/dist/components/base/badge/badge.d.ts +1 -1
- package/dist/components/base/badge/badge.recipes.d.ts +4 -4
- package/dist/components/base/buttons/base-button.d.ts +7 -0
- package/dist/components/base/buttons/button-group.recipes.d.ts +2 -2
- package/dist/components/base/buttons/button.variants.d.ts +1 -0
- package/dist/components/base/buttons/loader-button.d.ts +3 -1
- package/dist/components/base/buttons/text-button.d.ts +2 -2
- package/dist/components/base/carousel/carousel.d.ts +3 -1
- package/dist/components/base/chart/chart.d.ts +7 -7
- package/dist/components/base/choice-inputs/checkbox.d.ts +6 -7
- package/dist/components/base/choice-inputs/choice-types.d.ts +10 -1
- package/dist/components/base/choice-inputs/pill-radio-group.d.ts +9 -0
- package/dist/components/base/choice-inputs/select-popup.d.ts +9 -1
- package/dist/components/base/choice-inputs/switch-card.d.ts +1 -1
- package/dist/components/base/date-pickers/date-picker-field.d.ts +23 -0
- package/dist/components/base/date-pickers/datepicker.types.d.ts +13 -3
- package/dist/components/base/display/alert-dialog.d.ts +8 -2
- package/dist/components/base/display/content-block.d.ts +4 -2
- package/dist/components/base/display/date-block.d.ts +1 -1
- package/dist/components/base/display/dialog.d.ts +12 -5
- package/dist/components/base/display/surface-title.d.ts +6 -1
- package/dist/components/base/feedback/alert.d.ts +1 -1
- package/dist/components/base/feedback/state-display.d.ts +5 -4
- package/dist/components/base/forms/form-sizing.d.ts +32 -0
- package/dist/components/base/forms/workflow.d.ts +2 -0
- package/dist/components/base/forms-numeric/coordinates-input.d.ts +3 -0
- package/dist/components/base/forms-numeric/rounding-mode-select.d.ts +4 -1
- package/dist/components/base/navigation/dropdown-menu.d.ts +2 -2
- package/dist/components/base/navigation/language-switcher.d.ts +4 -1
- package/dist/components/base/navigation/overflow-tab-bar.d.ts +7 -0
- package/dist/components/base/navigation/page-header/page-header.d.ts +4 -1
- package/dist/components/base/qr-code/qr-code.d.ts +2 -0
- package/dist/components/base/sheet/index.d.ts +29 -1
- package/dist/components/base/sheet/sheet.d.ts +14 -5
- package/dist/components/base/spinner/spinner.d.ts +3 -2
- package/dist/components/base/structure/structure.types.d.ts +1 -1
- package/dist/components/base/text-inputs/input-group.d.ts +2 -2
- package/dist/components/base/upload/upload.recipes.d.ts +11 -0
- package/dist/components/base/value-inputs/date-time-input.d.ts +4 -2
- package/dist/components/base/value-inputs/tags-input.d.ts +2 -0
- package/dist/components/blocks/admin/api-key-list/api-key-list.types.d.ts +1 -1
- package/dist/components/blocks/analytics/format-metric-value.d.ts +11 -1
- package/dist/components/blocks/analytics/index.d.ts +1 -1
- package/dist/components/blocks/analytics/use-metric-format-options.d.ts +3 -0
- package/dist/components/blocks/commerce/address-card/address-card.d.ts +1 -1
- package/dist/components/blocks/commerce/address-card/types.d.ts +3 -1
- package/dist/components/blocks/commerce/booking-calendar-event-card/booking-calendar-event-card.d.ts +4 -0
- package/dist/components/blocks/commerce/booking-calendar-event-card/booking-calendar-event-card.types.d.ts +2 -2
- package/dist/components/blocks/commerce/discount-stack/types.d.ts +1 -1
- package/dist/components/blocks/commerce/inventory-section/types.d.ts +4 -1
- package/dist/components/blocks/commerce/loyalty-points/types.d.ts +1 -1
- package/dist/components/blocks/commerce/order-status/types.d.ts +4 -0
- package/dist/components/blocks/commerce/payment-method/payment-method.d.ts +1 -1
- package/dist/components/blocks/commerce/payment-method/types.d.ts +3 -1
- package/dist/components/blocks/commerce/seo-listing/seo-listing-card.d.ts +1 -1
- package/dist/components/blocks/commerce/seo-listing/types.d.ts +3 -1
- package/dist/components/blocks/commerce/vendor-profile/types.d.ts +4 -1
- package/dist/components/blocks/data-display/dense-info-card/dense-info.strings.d.ts +4 -1
- package/dist/components/blocks/data-display/inline-stat/inline-stat.d.ts +4 -1
- package/dist/components/features/global-search/partials/global-search-idle-state.d.ts +1 -1
- package/dist/components/features/overlays/alert-dialog.d.ts +1 -1
- package/dist/components/features/overlays/drawer.d.ts +1 -1
- package/dist/components/features/overlays/hooks/use-overlay-actions.d.ts +2 -2
- package/dist/components/features/overlays/hooks/use-overlay-visibility.d.ts +11 -4
- package/dist/components/features/overlays/overlay-tone-icon.d.ts +37 -0
- package/dist/components/features/overlays/overlays.types.d.ts +42 -19
- package/dist/components/features/products/components/product-variants-manager.d.ts +1 -1
- package/dist/components/features/products/partials/index.d.ts +1 -1
- package/dist/components/features/products/partials/product-metric-tile.d.ts +6 -0
- package/dist/components/features/products/partials/product-tone.d.ts +11 -1
- package/dist/components/features/products/products.types.d.ts +2 -1
- package/dist/components/features/table/partials/cell-renderers.d.ts +1 -1
- package/dist/components/layout/page/index.d.ts +1 -1
- package/dist/components/layout/page/page.types.d.ts +53 -3
- package/dist/components/layout/page/partials/page-header-commands.d.ts +13 -0
- package/dist/components/layout/page/partials/page-header.d.ts +1 -1
- package/dist/components/primitives/date.d.ts +16 -3
- package/dist/components/primitives/dimensions.d.ts +6 -0
- package/dist/components/primitives/duration.d.ts +6 -0
- package/dist/components/primitives/file-size.d.ts +6 -0
- package/dist/components/primitives/index.d.ts +1 -1
- package/dist/components/primitives/initials.d.ts +11 -2
- package/dist/components/primitives/link.d.ts +7 -0
- package/dist/components/primitives/money.d.ts +29 -7
- package/dist/components/primitives/number.d.ts +17 -0
- package/dist/components/primitives/value-typography.d.ts +54 -0
- package/dist/components/primitives/value.d.ts +31 -6
- package/dist/components/typography/heading.d.ts +9 -1
- package/dist/components/typography/label.d.ts +3 -0
- package/dist/components/typography/running-text.d.ts +12 -0
- package/dist/components/typography/text-link.d.ts +23 -1
- package/dist/components/typography/text.d.ts +12 -0
- package/dist/components/typography/text.styles.d.ts +35 -13
- package/dist/components/ui/button.d.ts +1 -1
- package/dist/components/ui/checkbox.d.ts +5 -0
- package/dist/components/ui/overlay.recipes.d.ts +15 -2
- package/dist/components/ui/select.d.ts +3 -1
- package/dist/components/ui/switch.d.ts +5 -0
- package/dist/{containers-DqB-bSYE.js → containers-D_L4mTVb.js} +3 -3
- package/dist/{containers-DqB-bSYE.js.map → containers-D_L4mTVb.js.map} +1 -1
- package/dist/{copyable-BTSByfmq.js → copyable-DDjTeW_j.js} +4 -4
- package/dist/{copyable-BTSByfmq.js.map → copyable-DDjTeW_j.js.map} +1 -1
- package/dist/{data-display-Bihs9Ven.js → data-display-3xWQUnMA.js} +471 -478
- package/dist/data-display-3xWQUnMA.js.map +1 -0
- package/dist/date-picker-DrDFj8Lo.js +1527 -0
- package/dist/date-picker-DrDFj8Lo.js.map +1 -0
- package/dist/date-pickers-CnFCb0n2.js +174 -0
- package/dist/date-pickers-CnFCb0n2.js.map +1 -0
- package/dist/date-uf3z37Nm.js +144 -0
- package/dist/date-uf3z37Nm.js.map +1 -0
- package/dist/{display-CS6Hbk18.js → display-DrdvPwF0.js} +25 -25
- package/dist/display-DrdvPwF0.js.map +1 -0
- package/dist/{dropdown-menu-D-boNgGO.js → dropdown-menu-CURh59jb.js} +22 -15
- package/dist/dropdown-menu-CURh59jb.js.map +1 -0
- package/dist/features/activities.js +38 -35
- package/dist/features/activities.js.map +1 -1
- package/dist/features/ai-chat.js +36 -35
- package/dist/features/ai-chat.js.map +1 -1
- package/dist/features/async-preview.js +8 -8
- package/dist/features/combobox.js +1 -1
- package/dist/features/comments.js +1 -1
- package/dist/features/data-view.js +10 -10
- package/dist/features/email-composer.js +325 -326
- package/dist/features/email-composer.js.map +1 -1
- package/dist/features/event-calendar.js +190 -200
- package/dist/features/event-calendar.js.map +1 -1
- package/dist/features/filters.js +1 -1
- package/dist/features/global-search.js +77 -77
- package/dist/features/global-search.js.map +1 -1
- package/dist/features/kanban.js +4 -4
- package/dist/features/map.js +8 -8
- package/dist/features/media-library.js +499 -502
- package/dist/features/media-library.js.map +1 -1
- package/dist/features/mentions.js +1 -1
- package/dist/features/overlays.js +1 -1
- package/dist/features/products.js +1216 -1248
- package/dist/features/products.js.map +1 -1
- package/dist/features/questionnaire.js +46 -44
- package/dist/features/questionnaire.js.map +1 -1
- package/dist/features/resource-assignment.js +96 -88
- package/dist/features/resource-assignment.js.map +1 -1
- package/dist/features/resource.js +11 -11
- package/dist/features/rich-text-editor.js +2 -2
- package/dist/features/schema-form.js +188 -184
- package/dist/features/schema-form.js.map +1 -1
- package/dist/features/suggestions.js +3 -3
- package/dist/features/sync.js +7 -7
- package/dist/features/sync.js.map +1 -1
- package/dist/features/table.js +1 -1
- package/dist/features/theme-tweaker.js +469 -470
- package/dist/features/theme-tweaker.js.map +1 -1
- package/dist/{feedback-CJkUAapr.js → feedback-C7nR0UtT.js} +9 -10
- package/dist/feedback-C7nR0UtT.js.map +1 -0
- package/dist/field-affordance-recipes-CkOCdE2y.js +46 -0
- package/dist/field-affordance-recipes-CkOCdE2y.js.map +1 -0
- package/dist/{field-state-recipes-DQQpiLWC.js → field-state-recipes-C-MFBX_8.js} +3 -3
- package/dist/field-state-recipes-C-MFBX_8.js.map +1 -0
- package/dist/{filters-D6FF8L6s.js → filters-Da-gNPsE.js} +467 -467
- package/dist/filters-Da-gNPsE.js.map +1 -0
- package/dist/{form-field-CZwrkP7m.js → form-field-VZRULhUK.js} +7 -7
- package/dist/{form-field-CZwrkP7m.js.map → form-field-VZRULhUK.js.map} +1 -1
- package/dist/form-sizing-uWP4lzVh.js +126 -0
- package/dist/form-sizing-uWP4lzVh.js.map +1 -0
- package/dist/{forms-B5NCbkSC.js → forms-DDeEnXSY.js} +11 -11
- package/dist/forms-DDeEnXSY.js.map +1 -0
- package/dist/forms-numeric-D3CO60IF.js +905 -0
- package/dist/forms-numeric-D3CO60IF.js.map +1 -0
- package/dist/{header-kxruN3RM.js → header-2ycNqGOR.js} +43 -42
- package/dist/header-2ycNqGOR.js.map +1 -0
- package/dist/{hooks-BrlnCwQd.js → hooks-DQ5SPwZw.js} +2 -2
- package/dist/{hooks-BrlnCwQd.js.map → hooks-DQ5SPwZw.js.map} +1 -1
- package/dist/{icon-badge-Btc6pQrp.js → icon-badge-DKlaKXoo.js} +3 -3
- package/dist/{icon-badge-Btc6pQrp.js.map → icon-badge-DKlaKXoo.js.map} +1 -1
- package/dist/index.js +2 -2
- package/dist/{input-vxcaNCYC.js → input-BoLm9Hks.js} +3 -3
- package/dist/{input-vxcaNCYC.js.map → input-BoLm9Hks.js.map} +1 -1
- package/dist/input-DhQdBnV3.js +255 -0
- package/dist/{input-SX9V0AL3.js.map → input-DhQdBnV3.js.map} +1 -1
- package/dist/item-xzh8Df65.js +264 -0
- package/dist/item-xzh8Df65.js.map +1 -0
- package/dist/layout/app-shell.js +1 -1
- package/dist/layout/auth.js +1 -1
- package/dist/layout/containers.js +1 -1
- package/dist/layout/header.js +1 -1
- package/dist/layout/hooks.js +1 -1
- package/dist/layout/navigation.js +1 -1
- package/dist/layout/page.js +1 -1
- package/dist/layout/settings.js +1 -1
- package/dist/layout/sidebar.js +2 -2
- package/dist/layout/workspace.js +1 -1
- package/dist/layout.js +10 -10
- package/dist/lib/affordance-geometry.generated.d.ts +6 -1
- package/dist/lib/field-affordance-recipes.d.ts +35 -0
- package/dist/lib/field-state-recipes.d.ts +4 -2
- package/dist/lib/format.d.ts +9 -0
- package/dist/lib/money-format.d.ts +30 -0
- package/dist/lib/overlay-anatomy-recipes.d.ts +1 -1
- package/dist/lib/surface-recipes.d.ts +8 -6
- package/dist/lib/token-merge.generated.d.ts +11 -11
- package/dist/lib/track-recipes.d.ts +1 -1
- package/dist/lib/ui-provider/provider.d.ts +7 -2
- package/dist/lib/ui-provider/store.d.ts +6 -2
- package/dist/lib/ui-provider/types.d.ts +5 -2
- package/dist/lib/utils.js +1 -1
- package/dist/{media-gallery-DLp3HAz0.js → media-gallery-DQUQ0m3O.js} +8 -8
- package/dist/media-gallery-DQUQ0m3O.js.map +1 -0
- package/dist/{mentions-Cl0Kt_Pd.js → mentions-DwnO1hh4.js} +34 -35
- package/dist/{mentions-Cl0Kt_Pd.js.map → mentions-DwnO1hh4.js.map} +1 -1
- package/dist/{message-SZUNB1eX.js → message-YfFmbXNP.js} +5 -5
- package/dist/{message-SZUNB1eX.js.map → message-YfFmbXNP.js.map} +1 -1
- package/dist/{navigation-DyytsLRB.js → navigation-Cbp5V8gG.js} +33 -34
- package/dist/navigation-Cbp5V8gG.js.map +1 -0
- package/dist/{navigation-DnQSNMT0.js → navigation-Cs1npsPm.js} +111 -87
- package/dist/navigation-Cs1npsPm.js.map +1 -0
- package/dist/{navigation-row-recipes-DQEXQcqY.js → navigation-row-recipes-DlU-4QYO.js} +2 -2
- package/dist/{navigation-row-recipes-DQEXQcqY.js.map → navigation-row-recipes-DlU-4QYO.js.map} +1 -1
- package/dist/number-CKRBYmZK.js +352 -0
- package/dist/number-CKRBYmZK.js.map +1 -0
- package/dist/overlay.recipes-CNO2S9V6.js +34 -0
- package/dist/overlay.recipes-CNO2S9V6.js.map +1 -0
- package/dist/overlays-DhZO7N-I.js +994 -0
- package/dist/overlays-DhZO7N-I.js.map +1 -0
- package/dist/page-C6R_8jFt.js +325 -0
- package/dist/page-C6R_8jFt.js.map +1 -0
- package/dist/{page-header-D8nERkn5.js → page-header-hUTzcRZX.js} +9 -9
- package/dist/page-header-hUTzcRZX.js.map +1 -0
- package/dist/{pagination-NLGqRirf.js → pagination-Cm0jqa3I.js} +8 -8
- package/dist/{pagination-NLGqRirf.js.map → pagination-Cm0jqa3I.js.map} +1 -1
- package/dist/{popover-CghIYdQf.js → popover-Dcv_9jxr.js} +6 -6
- package/dist/{popover-CghIYdQf.js.map → popover-Dcv_9jxr.js.map} +1 -1
- package/dist/{popover-menu-B4PoWhRl.js → popover-menu-DnRFKnHP.js} +6 -6
- package/dist/{popover-menu-B4PoWhRl.js.map → popover-menu-DnRFKnHP.js.map} +1 -1
- package/dist/{popover.recipes-QlD4JenO.js → popover.recipes-wmbvL8Ah.js} +2 -2
- package/dist/{popover.recipes-QlD4JenO.js.map → popover.recipes-wmbvL8Ah.js.map} +1 -1
- package/dist/primitives-BHrwQXFC.js +379 -0
- package/dist/primitives-BHrwQXFC.js.map +1 -0
- package/dist/primitives.js +5 -5
- package/dist/{progress-BroqrAyV.js → progress-Br9WTFya.js} +7 -7
- package/dist/progress-Br9WTFya.js.map +1 -0
- package/dist/{receipt-BuJynLgf.js → receipt-CV89q1fs.js} +6 -6
- package/dist/{receipt-BuJynLgf.js.map → receipt-CV89q1fs.js.map} +1 -1
- package/dist/{rich-text-editor-BKyG7rWz.js → rich-text-editor-CF8QYt5p.js} +6 -6
- package/dist/{rich-text-editor-BKyG7rWz.js.map → rich-text-editor-CF8QYt5p.js.map} +1 -1
- package/dist/{rich-text-editor.recipes-B72Nfuze.js → rich-text-editor.recipes-CnrbmTS1.js} +4 -4
- package/dist/{rich-text-editor.recipes-B72Nfuze.js.map → rich-text-editor.recipes-CnrbmTS1.js.map} +1 -1
- package/dist/{rich-text-DlxDOtf4.js → rich-text-j-FGAeZW.js} +4 -4
- package/dist/{rich-text-DlxDOtf4.js.map → rich-text-j-FGAeZW.js.map} +1 -1
- package/dist/{scroll-area-D-pIhEKl.js → scroll-area-DRdr16Pt.js} +3 -3
- package/dist/scroll-area-DRdr16Pt.js.map +1 -0
- package/dist/{separator-BhtFyo4x.js → separator-BMEvwnSX.js} +2 -2
- package/dist/{separator-BhtFyo4x.js.map → separator-BMEvwnSX.js.map} +1 -1
- package/dist/{separator-BNIgG3au.js → separator-Do5GWDYi.js} +4 -4
- package/dist/separator-Do5GWDYi.js.map +1 -0
- package/dist/services/actions/action-adapters.d.ts +4 -0
- package/dist/services/actions.js +8 -3
- package/dist/services/actions.js.map +1 -1
- package/dist/{settings-DOTOzeZ2.js → settings-DHk0L2MF.js} +17 -17
- package/dist/settings-DHk0L2MF.js.map +1 -0
- package/dist/sheet-DRFNY1_D.js +207 -0
- package/dist/sheet-DRFNY1_D.js.map +1 -0
- package/dist/sidebar-Cb8WzOvE.js +511 -0
- package/dist/sidebar-Cb8WzOvE.js.map +1 -0
- package/dist/{sidebar-CyR4XKwR.js → sidebar-Crc9M9JV.js} +18 -18
- package/dist/sidebar-Crc9M9JV.js.map +1 -0
- package/dist/{skeleton-3F0uhYn3.js → skeleton-DVMXr15h.js} +4 -4
- package/dist/{skeleton-3F0uhYn3.js.map → skeleton-DVMXr15h.js.map} +1 -1
- package/dist/{smart-card-DjGVV2xr.js → smart-card-Bek-TwUp.js} +222 -207
- package/dist/smart-card-Bek-TwUp.js.map +1 -0
- package/dist/{spinner-Cpf7oRkF.js → spinner-CmTAbEp0.js} +8 -6
- package/dist/spinner-CmTAbEp0.js.map +1 -0
- package/dist/{structure-CRdqVawd.js → structure-hzCW-XsV.js} +3 -3
- package/dist/{structure-CRdqVawd.js.map → structure-hzCW-XsV.js.map} +1 -1
- package/dist/{structure.recipes-Bqhf9oIh.js → structure.recipes-EPz60cU8.js} +37 -19
- package/dist/structure.recipes-EPz60cU8.js.map +1 -0
- package/dist/style.css +1 -1
- package/dist/surface-recipes-DOdoBXGm.js +28 -0
- package/dist/surface-recipes-DOdoBXGm.js.map +1 -0
- package/dist/table-D6zKeYQX.js +162 -0
- package/dist/table-D6zKeYQX.js.map +1 -0
- package/dist/{table-CcRDZiLP.js → table-Dn4XSrSB.js} +348 -348
- package/dist/table-Dn4XSrSB.js.map +1 -0
- package/dist/{tabs-BNgu7g0u.js → tabs-Dk8E_knt.js} +14 -13
- package/dist/tabs-Dk8E_knt.js.map +1 -0
- package/dist/{text-inputs-DsR56TR-.js → text-inputs-BFpku0Qd.js} +150 -149
- package/dist/text-inputs-BFpku0Qd.js.map +1 -0
- package/dist/{text.styles-Q4sGAIgA.js → text.styles-g4He6UIW.js} +17 -14
- package/dist/text.styles-g4He6UIW.js.map +1 -0
- package/dist/theme.css +16 -12
- package/dist/themes/green.css +24 -0
- package/dist/{timelines-D1pkt3se.js → timelines-CxuAFIc2.js} +25 -38
- package/dist/timelines-CxuAFIc2.js.map +1 -0
- package/dist/track-recipes-CDcKmndW.js +10 -0
- package/dist/track-recipes-CDcKmndW.js.map +1 -0
- package/dist/{tree-BtmYyMZV.js → tree-BotPlyiD.js} +13 -13
- package/dist/{tree-BtmYyMZV.js.map → tree-BotPlyiD.js.map} +1 -1
- package/dist/typography/rich-text.js +1 -1
- package/dist/typography-CAr3dQhX.js +116 -0
- package/dist/typography-CAr3dQhX.js.map +1 -0
- package/dist/typography.js +2 -2
- package/dist/{ui-provider-DRPn3qNl.js → ui-provider-D2_TeLqw.js} +20 -21
- package/dist/ui-provider-D2_TeLqw.js.map +1 -0
- package/dist/ui-provider.js +1 -1
- package/dist/{upload-CDbYw1WN.js → upload-B0WHW7ak.js} +221 -220
- package/dist/upload-B0WHW7ak.js.map +1 -0
- package/dist/{upload-queue-CNd_hH_a.js → upload-queue-BHZ_wBfd.js} +59 -62
- package/dist/upload-queue-BHZ_wBfd.js.map +1 -0
- package/dist/{usage-card-VyJLUwRr.js → usage-card-U0YBLTNT.js} +42 -43
- package/dist/{usage-card-VyJLUwRr.js.map → usage-card-U0YBLTNT.js.map} +1 -1
- package/dist/{utils-BvH9PSmq.js → utils-Cospvlj1.js} +221 -51
- package/dist/utils-Cospvlj1.js.map +1 -0
- package/dist/value-inputs-CjfzGMsN.js +854 -0
- package/dist/value-inputs-CjfzGMsN.js.map +1 -0
- package/dist/value-typography-Deb3yQZg.js +116 -0
- package/dist/value-typography-Deb3yQZg.js.map +1 -0
- package/dist/{workspace-CcR8r-Nt.js → workspace-YoFjXi6i.js} +44 -45
- package/dist/workspace-YoFjXi6i.js.map +1 -0
- package/docs/consumer-skill/SKILL.md +51 -38
- package/docs/consumer-skill/examples/app-layout.tsx +2 -4
- package/docs/consumer-skill/examples/detail.tsx +3 -4
- package/docs/consumer-skill/examples/edit.tsx +1 -1
- package/docs/consumer-skill/examples/layout-blocks.tsx +20 -0
- package/docs/consumer-skill/examples/manifest.json +28 -6
- package/docs/consumer-skill/examples/scoped-directory.tsx +2 -2
- package/docs/consumer-skill/references/composition.md +89 -17
- package/docs/consumer-skill/references/discovery.md +4 -0
- package/docs/consumer-skill/references/installation.md +22 -0
- package/docs/consumer-skill/references/integration.md +32 -1
- package/docs/consumer-skill/references/public-api.json +111 -70
- package/docs/consumer-skill/references/review.md +20 -4
- package/docs/consumer-skill/references/theming.md +7 -1
- package/docs/consumer-skill/references/tokens.json +5 -2
- package/docs/consumer-skill/references/workflows.md +4 -2
- package/docs/consumer-skill/scripts/composition-policy.mjs +93 -2
- package/docs/consumer-skill/scripts/discovery.mjs +11 -3
- package/docs/consumer-skill/scripts/pin-button-defaults.mjs +95 -0
- package/package.json +5 -3
- package/dist/accordion-BRTcsp8J.js.map +0 -1
- package/dist/action-menu-Drxw_vJk.js +0 -265
- package/dist/action-menu-Drxw_vJk.js.map +0 -1
- package/dist/affordance-geometry.generated-CL84ZN9A.js.map +0 -1
- package/dist/ai-artifact-DLVdK0Py.js.map +0 -1
- package/dist/avatar-Bu2HhitA.js.map +0 -1
- package/dist/badge-CzId1Wlm.js.map +0 -1
- package/dist/button-BZDasD04.js.map +0 -1
- package/dist/buttons-D_6KJvEE.js.map +0 -1
- package/dist/chart-Bsc5BICK.js.map +0 -1
- package/dist/checkbox-BQNDjUCh.js +0 -34
- package/dist/checkbox-BQNDjUCh.js.map +0 -1
- package/dist/choice-inputs-Mk3iWbhr.js +0 -725
- package/dist/choice-inputs-Mk3iWbhr.js.map +0 -1
- package/dist/combobox-BFnbJJp3.js.map +0 -1
- package/dist/combobox-hozNwUcc.js.map +0 -1
- package/dist/command-BnmSchli.js.map +0 -1
- package/dist/comments-u5L0OGip.js.map +0 -1
- package/dist/data-display-Bihs9Ven.js.map +0 -1
- package/dist/date-DOKhJPu7.js +0 -140
- package/dist/date-DOKhJPu7.js.map +0 -1
- package/dist/date-picker-DzP5HQq7.js +0 -1541
- package/dist/date-picker-DzP5HQq7.js.map +0 -1
- package/dist/date-pickers-BpgGz7S-.js +0 -196
- package/dist/date-pickers-BpgGz7S-.js.map +0 -1
- package/dist/display-CS6Hbk18.js.map +0 -1
- package/dist/dropdown-menu-D-boNgGO.js.map +0 -1
- package/dist/feedback-CJkUAapr.js.map +0 -1
- package/dist/field-affordance-recipes-uKY4MsZ_.js +0 -25
- package/dist/field-affordance-recipes-uKY4MsZ_.js.map +0 -1
- package/dist/field-state-recipes-DQQpiLWC.js.map +0 -1
- package/dist/filters-D6FF8L6s.js.map +0 -1
- package/dist/form-sizing-QP8aIRaW.js +0 -103
- package/dist/form-sizing-QP8aIRaW.js.map +0 -1
- package/dist/format-iamDSqs2.js +0 -110
- package/dist/format-iamDSqs2.js.map +0 -1
- package/dist/forms-B5NCbkSC.js.map +0 -1
- package/dist/forms-numeric-Crrm80Lm.js +0 -867
- package/dist/forms-numeric-Crrm80Lm.js.map +0 -1
- package/dist/header-kxruN3RM.js.map +0 -1
- package/dist/input-SX9V0AL3.js +0 -255
- package/dist/item-DE4YnuJx.js +0 -258
- package/dist/item-DE4YnuJx.js.map +0 -1
- package/dist/media-gallery-DLp3HAz0.js.map +0 -1
- package/dist/navigation-DnQSNMT0.js.map +0 -1
- package/dist/navigation-DyytsLRB.js.map +0 -1
- package/dist/number-DasMFWEG.js +0 -269
- package/dist/number-DasMFWEG.js.map +0 -1
- package/dist/overlay.recipes-BxW5FIfK.js +0 -6
- package/dist/overlay.recipes-BxW5FIfK.js.map +0 -1
- package/dist/overlays-DUbs1KEi.js +0 -1011
- package/dist/overlays-DUbs1KEi.js.map +0 -1
- package/dist/page-hGmT4nWK.js +0 -213
- package/dist/page-hGmT4nWK.js.map +0 -1
- package/dist/page-header-D8nERkn5.js.map +0 -1
- package/dist/primitives-C7ff0QaI.js +0 -337
- package/dist/primitives-C7ff0QaI.js.map +0 -1
- package/dist/progress-BroqrAyV.js.map +0 -1
- package/dist/scroll-area-D-pIhEKl.js.map +0 -1
- package/dist/separator-BNIgG3au.js.map +0 -1
- package/dist/settings-DOTOzeZ2.js.map +0 -1
- package/dist/sheet-BFhrNehm.js +0 -205
- package/dist/sheet-BFhrNehm.js.map +0 -1
- package/dist/sidebar-CyR4XKwR.js.map +0 -1
- package/dist/sidebar-SvGJ0Zwi.js +0 -506
- package/dist/sidebar-SvGJ0Zwi.js.map +0 -1
- package/dist/smart-card-DjGVV2xr.js.map +0 -1
- package/dist/spinner-Cpf7oRkF.js.map +0 -1
- package/dist/structure.recipes-Bqhf9oIh.js.map +0 -1
- package/dist/surface-recipes-Dd__PD-w.js +0 -28
- package/dist/surface-recipes-Dd__PD-w.js.map +0 -1
- package/dist/table-CLtJTxoR.js +0 -147
- package/dist/table-CLtJTxoR.js.map +0 -1
- package/dist/table-CcRDZiLP.js.map +0 -1
- package/dist/tabs-BNgu7g0u.js.map +0 -1
- package/dist/text-inputs-DsR56TR-.js.map +0 -1
- package/dist/text.styles-Q4sGAIgA.js.map +0 -1
- package/dist/timelines-D1pkt3se.js.map +0 -1
- package/dist/track-recipes-LLPNVwFg.js +0 -10
- package/dist/track-recipes-LLPNVwFg.js.map +0 -1
- package/dist/typography-BxQgiZyw.js +0 -96
- package/dist/typography-BxQgiZyw.js.map +0 -1
- package/dist/ui-provider-DRPn3qNl.js.map +0 -1
- package/dist/upload-CDbYw1WN.js.map +0 -1
- package/dist/upload-queue-CNd_hH_a.js.map +0 -1
- package/dist/utils-BvH9PSmq.js.map +0 -1
- package/dist/value-inputs-D0KCrfVC.js +0 -840
- package/dist/value-inputs-D0KCrfVC.js.map +0 -1
- package/dist/workspace-CcR8r-Nt.js.map +0 -1
|
@@ -1,32 +1,34 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { _ as e, s as t } from "../ui-provider-
|
|
2
|
+
import { _ as e, s as t } from "../ui-provider-D2_TeLqw.js";
|
|
3
3
|
import { interpolateString as n, useStrings as r } from "../lib/strings.js";
|
|
4
|
-
import { t as i } from "../utils-
|
|
5
|
-
import { a,
|
|
6
|
-
import { t as s } from "../button-
|
|
7
|
-
import { r as c, t as l } from "../structure-
|
|
8
|
-
import { t as u } from "../
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import { t as _ } from "../
|
|
14
|
-
import { t as v } from "../
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import { t as
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
4
|
+
import { t as i } from "../utils-Cospvlj1.js";
|
|
5
|
+
import { a, s as o } from "../typography-CAr3dQhX.js";
|
|
6
|
+
import { t as s } from "../button-BS3KDg00.js";
|
|
7
|
+
import { r as c, t as l } from "../structure-hzCW-XsV.js";
|
|
8
|
+
import { t as u } from "../smart-card-Bek-TwUp.js";
|
|
9
|
+
import { t as d } from "../progress-Br9WTFya.js";
|
|
10
|
+
import { i as f, t as p } from "../overlays-DhZO7N-I.js";
|
|
11
|
+
import { _ as m, g as h } from "../primitives-BHrwQXFC.js";
|
|
12
|
+
import { n as g } from "../number-CKRBYmZK.js";
|
|
13
|
+
import { t as _ } from "../badge-0tATj-tW.js";
|
|
14
|
+
import { t as v } from "../separator-Do5GWDYi.js";
|
|
15
|
+
import { t as y } from "../field-affordance-recipes-CkOCdE2y.js";
|
|
16
|
+
import { t as b } from "../input-DhQdBnV3.js";
|
|
17
|
+
import { t as x } from "../form-field-VZRULhUK.js";
|
|
18
|
+
import { d as S } from "../text-inputs-BFpku0Qd.js";
|
|
19
|
+
import { c as C, s as w } from "../choice-inputs-DrJ17tpL.js";
|
|
20
|
+
import { t as T } from "../checkbox-B7ygNTYp.js";
|
|
21
|
+
import { n as E } from "../display-DrdvPwF0.js";
|
|
22
|
+
import { r as D, t as O } from "../control-group-recipes-DBXmfh2E.js";
|
|
23
|
+
import { c as k, i as A, n as j, o as M, r as N, t as P, u as F } from "../item-xzh8Df65.js";
|
|
24
|
+
import { c as ee, i as I, n as te, o as ne, s as re, t as ie } from "../table-D6zKeYQX.js";
|
|
25
|
+
import { g as ae, l as oe, n as se } from "../data-display-3xWQUnMA.js";
|
|
26
|
+
import { O as L, f as ce } from "../table-Dn4XSrSB.js";
|
|
27
|
+
import { Fragment as le, useCallback as R, useId as z, useMemo as B, useState as ue } from "react";
|
|
28
|
+
import { Fragment as de, jsx as V, jsxs as H } from "react/jsx-runtime";
|
|
29
|
+
import { ArrowLeft as fe, ChevronDown as pe, Copy as me, Eye as he, GripVertical as ge, ListFilter as U, Pencil as W, Plus as G, PlusCircle as _e, Search as ve, SlidersHorizontal as K, Trash2 as q, X as ye } from "lucide-react";
|
|
28
30
|
//#region src/components/features/products/products.strings.ts
|
|
29
|
-
var
|
|
31
|
+
var J = {
|
|
30
32
|
title: "Readiness",
|
|
31
33
|
description: "Publishing checks and operational setup.",
|
|
32
34
|
scoreLabel: "Overall readiness",
|
|
@@ -38,7 +40,7 @@ var Te = {
|
|
|
38
40
|
emptyTitle: "No readiness checks",
|
|
39
41
|
emptyDescription: "Pass readiness items from your product workflow to show progress.",
|
|
40
42
|
actionLabel: "Open"
|
|
41
|
-
},
|
|
43
|
+
}, Y = {
|
|
42
44
|
title: "Structure",
|
|
43
45
|
description: "Media, taxonomy, options, and content coverage.",
|
|
44
46
|
createLabel: "Add metric",
|
|
@@ -48,7 +50,7 @@ var Te = {
|
|
|
48
50
|
actionsLabel: "Metric actions",
|
|
49
51
|
emptyTitle: "No structure metrics",
|
|
50
52
|
emptyDescription: "Pass structure metrics to summarize the product setup."
|
|
51
|
-
},
|
|
53
|
+
}, be = {
|
|
52
54
|
title: "Operations",
|
|
53
55
|
description: "Availability, channels, service rules, and fulfilment signals.",
|
|
54
56
|
createLabel: "Add signal",
|
|
@@ -58,13 +60,13 @@ var Te = {
|
|
|
58
60
|
emptyTitle: "No operational signals",
|
|
59
61
|
emptyDescription: "Pass operational rows to show channel and availability health.",
|
|
60
62
|
actionLabel: "Open"
|
|
61
|
-
},
|
|
63
|
+
}, xe = {
|
|
62
64
|
title: "Product details",
|
|
63
65
|
description: "Core identity and catalogue fields.",
|
|
64
66
|
editLabel: "Edit details",
|
|
65
67
|
emptyTitle: "No details",
|
|
66
68
|
emptyDescription: "Pass metadata rows to render product details."
|
|
67
|
-
},
|
|
69
|
+
}, Se = {
|
|
68
70
|
title: "Contract",
|
|
69
71
|
description: "Commercial terms, pricing rules, and customer-facing conditions.",
|
|
70
72
|
termsTitle: "Terms",
|
|
@@ -78,7 +80,7 @@ var Te = {
|
|
|
78
80
|
ruleActionsLabel: "Rule actions",
|
|
79
81
|
emptyTitle: "No contract summary",
|
|
80
82
|
emptyDescription: "Pass metrics, terms, or rules to summarize the product contract."
|
|
81
|
-
},
|
|
83
|
+
}, Ce = {
|
|
82
84
|
title: "Options",
|
|
83
85
|
description: "Variant-driving choices and add-ons customers can select.",
|
|
84
86
|
manageLabel: "Manage options",
|
|
@@ -89,12 +91,12 @@ var Te = {
|
|
|
89
91
|
actionsLabel: "Option actions",
|
|
90
92
|
emptyTitle: "No options",
|
|
91
93
|
emptyDescription: "Pass option groups to summarize configurable product choices."
|
|
92
|
-
},
|
|
94
|
+
}, we = {
|
|
93
95
|
viewLabel: "Open option",
|
|
94
96
|
editLabel: "Edit option",
|
|
95
97
|
deleteLabel: "Delete option",
|
|
96
98
|
actionsLabel: "Option actions"
|
|
97
|
-
},
|
|
99
|
+
}, Te = {
|
|
98
100
|
title: "Variant options",
|
|
99
101
|
description: "Define option groups and values before generating sellable variants.",
|
|
100
102
|
createLabel: "Add attribute",
|
|
@@ -124,7 +126,7 @@ var Te = {
|
|
|
124
126
|
emptyTitle: "No option groups",
|
|
125
127
|
emptyDescription: "Add options such as size, color, or packaging to create variant combinations.",
|
|
126
128
|
noValuesLabel: "No values"
|
|
127
|
-
},
|
|
129
|
+
}, Ee = {
|
|
128
130
|
title: "Quote preview",
|
|
129
131
|
description: "How the product appears in a compact customer quote.",
|
|
130
132
|
subtotalLabel: "Subtotal",
|
|
@@ -139,7 +141,7 @@ var Te = {
|
|
|
139
141
|
lineActionsLabel: "Line actions",
|
|
140
142
|
emptyTitle: "No quote lines",
|
|
141
143
|
emptyDescription: "Pass quote lines to preview pricing."
|
|
142
|
-
},
|
|
144
|
+
}, X = {
|
|
143
145
|
title: "Policies",
|
|
144
146
|
description: "Cancellation, booking, service, and customer-facing rules.",
|
|
145
147
|
createLabel: "Add policy",
|
|
@@ -149,7 +151,7 @@ var Te = {
|
|
|
149
151
|
actionsLabel: "Policy actions",
|
|
150
152
|
emptyTitle: "No policies",
|
|
151
153
|
emptyDescription: "Pass policies to summarize customer-facing rules."
|
|
152
|
-
},
|
|
154
|
+
}, Z = {
|
|
153
155
|
title: "Variants",
|
|
154
156
|
description: "Sellable combinations with price, availability, and SKU.",
|
|
155
157
|
createLabel: "Add variant",
|
|
@@ -168,7 +170,7 @@ var Te = {
|
|
|
168
170
|
updated: "Updated",
|
|
169
171
|
actions: "Actions"
|
|
170
172
|
}
|
|
171
|
-
},
|
|
173
|
+
}, De = {
|
|
172
174
|
title: "Variants",
|
|
173
175
|
description: "Review generated combinations, select rows, and apply bulk operations.",
|
|
174
176
|
createLabel: "Add variant",
|
|
@@ -196,7 +198,7 @@ var Te = {
|
|
|
196
198
|
updated: "Updated",
|
|
197
199
|
actions: "Actions"
|
|
198
200
|
}
|
|
199
|
-
},
|
|
201
|
+
}, Oe = {
|
|
200
202
|
title: "Variants",
|
|
201
203
|
description: "Configure option groups first, then manage the generated sellable variants.",
|
|
202
204
|
optionsTitle: "Variant options",
|
|
@@ -207,13 +209,13 @@ var Te = {
|
|
|
207
209
|
generateLabel: "Generate variants",
|
|
208
210
|
createVariantLabel: "Add variant",
|
|
209
211
|
actionsLabel: "Variant manager actions"
|
|
210
|
-
},
|
|
212
|
+
}, ke = {
|
|
211
213
|
viewLabel: "Open variant",
|
|
212
214
|
editLabel: "Edit",
|
|
213
215
|
duplicateLabel: "Duplicate",
|
|
214
216
|
deleteLabel: "Delete",
|
|
215
217
|
actionsLabel: "Variant actions"
|
|
216
|
-
},
|
|
218
|
+
}, Q = {
|
|
217
219
|
title: "Variant",
|
|
218
220
|
description: "Sellable variant details, options, pricing, and fulfilment data.",
|
|
219
221
|
backLabel: "Back",
|
|
@@ -230,7 +232,7 @@ var Te = {
|
|
|
230
232
|
channels: "Channels",
|
|
231
233
|
updated: "Updated"
|
|
232
234
|
}
|
|
233
|
-
},
|
|
235
|
+
}, Ae = {
|
|
234
236
|
title: "Edit variant",
|
|
235
237
|
description: "Controlled form for variant identity, pricing, inventory, and option values.",
|
|
236
238
|
identityTitle: "Identity",
|
|
@@ -260,14 +262,14 @@ var Te = {
|
|
|
260
262
|
status: "Active",
|
|
261
263
|
channels: "Online store, POS"
|
|
262
264
|
}
|
|
263
|
-
},
|
|
265
|
+
}, je = {
|
|
264
266
|
mainLabel: "Product overview",
|
|
265
267
|
railLabel: "Product supporting information"
|
|
266
268
|
};
|
|
267
269
|
//#endregion
|
|
268
270
|
//#region src/components/features/products/partials/product-empty-state.tsx
|
|
269
|
-
function
|
|
270
|
-
return /* @__PURE__ */
|
|
271
|
+
function $({ title: e, description: t, action: n, className: r }) {
|
|
272
|
+
return /* @__PURE__ */ V(oe, {
|
|
271
273
|
padding: "md",
|
|
272
274
|
border: !0,
|
|
273
275
|
title: e,
|
|
@@ -278,30 +280,37 @@ function Be({ title: e, description: t, action: n, className: r }) {
|
|
|
278
280
|
}
|
|
279
281
|
//#endregion
|
|
280
282
|
//#region src/components/features/products/partials/product-tone.tsx
|
|
281
|
-
var
|
|
283
|
+
var Me = {
|
|
282
284
|
neutral: "secondary",
|
|
283
|
-
primary: "
|
|
285
|
+
primary: "secondary",
|
|
284
286
|
success: "success",
|
|
285
287
|
warning: "warning",
|
|
286
288
|
destructive: "destructive",
|
|
287
289
|
info: "info"
|
|
288
|
-
},
|
|
289
|
-
neutral:
|
|
290
|
-
primary:
|
|
291
|
-
success: "
|
|
292
|
-
warning: "
|
|
293
|
-
destructive: "
|
|
294
|
-
info: "
|
|
295
|
-
}
|
|
296
|
-
|
|
290
|
+
}, Ne = {
|
|
291
|
+
neutral: void 0,
|
|
292
|
+
primary: void 0,
|
|
293
|
+
success: "text-success",
|
|
294
|
+
warning: "text-warning-accent",
|
|
295
|
+
destructive: "text-destructive",
|
|
296
|
+
info: "text-info"
|
|
297
|
+
}, Pe = /* @__PURE__ */ new Set([
|
|
298
|
+
"success",
|
|
299
|
+
"warning",
|
|
300
|
+
"destructive",
|
|
301
|
+
"info"
|
|
302
|
+
]);
|
|
303
|
+
function Fe(e) {
|
|
304
|
+
return e !== void 0 && Pe.has(e);
|
|
305
|
+
}
|
|
306
|
+
function Ie(e) {
|
|
297
307
|
return Number.isFinite(e) ? Math.min(100, Math.max(0, Math.round(e))) : 0;
|
|
298
308
|
}
|
|
299
|
-
function
|
|
300
|
-
return /* @__PURE__ */
|
|
309
|
+
function Le({ tone: e = "neutral" }) {
|
|
310
|
+
return /* @__PURE__ */ V("span", {
|
|
301
311
|
"aria-hidden": "true",
|
|
302
|
-
className: i("product-tone-dot--component size-2 rounded-full", {
|
|
303
|
-
"bg-muted-foreground": e === "neutral",
|
|
304
|
-
"bg-primary": e === "primary",
|
|
312
|
+
className: i("product-tone-dot--component size-2 shrink-0 rounded-full", {
|
|
313
|
+
"bg-muted-foreground": e === "neutral" || e === "primary",
|
|
305
314
|
"bg-success": e === "success",
|
|
306
315
|
"bg-warning": e === "warning",
|
|
307
316
|
"bg-destructive": e === "destructive",
|
|
@@ -311,46 +320,48 @@ function We({ tone: e = "neutral" }) {
|
|
|
311
320
|
}
|
|
312
321
|
//#endregion
|
|
313
322
|
//#region src/components/features/products/partials/product-metric-tile.tsx
|
|
314
|
-
function
|
|
315
|
-
let t = e.
|
|
316
|
-
return /* @__PURE__ */
|
|
323
|
+
function Re({ metric: e }) {
|
|
324
|
+
let t = "icon" in e ? e.icon : void 0;
|
|
325
|
+
return /* @__PURE__ */ H(l, {
|
|
317
326
|
gap: "dense",
|
|
318
|
-
className:
|
|
319
|
-
children: [
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
className: "
|
|
339
|
-
children: e.
|
|
340
|
-
})
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
327
|
+
className: "product-metric-tile--component min-w-0",
|
|
328
|
+
children: [
|
|
329
|
+
/* @__PURE__ */ H(l, {
|
|
330
|
+
direction: "horizontal",
|
|
331
|
+
gap: "sm",
|
|
332
|
+
wrap: !1,
|
|
333
|
+
children: [
|
|
334
|
+
Fe(e.tone) && /* @__PURE__ */ V(Le, { tone: e.tone }),
|
|
335
|
+
!!t && /* @__PURE__ */ V("span", {
|
|
336
|
+
className: "flex shrink-0 text-muted-foreground",
|
|
337
|
+
children: t
|
|
338
|
+
}),
|
|
339
|
+
/* @__PURE__ */ V(a, {
|
|
340
|
+
className: "truncate",
|
|
341
|
+
children: e.label
|
|
342
|
+
})
|
|
343
|
+
]
|
|
344
|
+
}),
|
|
345
|
+
/* @__PURE__ */ V(m, {
|
|
346
|
+
weight: "semibold",
|
|
347
|
+
className: "tabular-nums",
|
|
348
|
+
children: e.value
|
|
349
|
+
}),
|
|
350
|
+
!!e.description && /* @__PURE__ */ V(o, {
|
|
351
|
+
size: "xs",
|
|
352
|
+
type: "secondary",
|
|
353
|
+
lineHeight: "snug",
|
|
354
|
+
children: e.description
|
|
355
|
+
})
|
|
356
|
+
]
|
|
346
357
|
});
|
|
347
358
|
}
|
|
348
359
|
//#endregion
|
|
349
360
|
//#region src/components/features/products/partials/product-actions.tsx
|
|
350
|
-
function
|
|
351
|
-
return t.length === 0 ? null : /* @__PURE__ */
|
|
361
|
+
function ze({ item: e, actions: t, menuLabel: n, className: r }) {
|
|
362
|
+
return t.length === 0 ? null : /* @__PURE__ */ V("div", {
|
|
352
363
|
className: i("product-row-actions--component flex justify-end", r),
|
|
353
|
-
children: /* @__PURE__ */
|
|
364
|
+
children: /* @__PURE__ */ V(L, {
|
|
354
365
|
row: e,
|
|
355
366
|
actions: t,
|
|
356
367
|
menuLabel: n,
|
|
@@ -360,252 +371,227 @@ function Ke({ item: e, actions: t, menuLabel: n, className: r }) {
|
|
|
360
371
|
}
|
|
361
372
|
//#endregion
|
|
362
373
|
//#region src/components/features/products/partials/product-rows.tsx
|
|
363
|
-
var
|
|
364
|
-
function
|
|
365
|
-
let
|
|
366
|
-
|
|
374
|
+
var Be = "min-w-0 basis-48", Ve = "line-clamp-none break-words overflow-visible", He = "ml-auto shrink-0 flex-wrap justify-end gap-space-md";
|
|
375
|
+
function Ue({ label: e, value: t, tone: n, badge: r }) {
|
|
376
|
+
let i = /* @__PURE__ */ V(F, {
|
|
377
|
+
className: Ve,
|
|
378
|
+
children: e
|
|
379
|
+
});
|
|
380
|
+
return !t && !r ? i : /* @__PURE__ */ H(l, {
|
|
381
|
+
direction: "horizontal",
|
|
382
|
+
gap: "sm",
|
|
383
|
+
className: "product-row--heading",
|
|
384
|
+
children: [
|
|
385
|
+
i,
|
|
386
|
+
!!t && (Fe(n) ? /* @__PURE__ */ V(_, {
|
|
387
|
+
tone: Me[n],
|
|
388
|
+
children: t
|
|
389
|
+
}) : /* @__PURE__ */ V(o, {
|
|
390
|
+
tag: "span",
|
|
391
|
+
type: "secondary",
|
|
392
|
+
lineHeight: "tight",
|
|
393
|
+
children: t
|
|
394
|
+
})),
|
|
395
|
+
r
|
|
396
|
+
]
|
|
397
|
+
});
|
|
398
|
+
}
|
|
399
|
+
function We({ label: e, onSelect: t }) {
|
|
400
|
+
return /* @__PURE__ */ V(s, {
|
|
401
|
+
type: "button",
|
|
402
|
+
tone: "secondary",
|
|
403
|
+
buttonStyle: "ghost",
|
|
404
|
+
onClick: t,
|
|
405
|
+
children: e
|
|
406
|
+
});
|
|
407
|
+
}
|
|
408
|
+
function Ge({ metric: e, actions: t }) {
|
|
409
|
+
return /* @__PURE__ */ H(P, {
|
|
367
410
|
className: "product-structure-metric-row--component product-structure-card--item",
|
|
368
411
|
children: [
|
|
369
|
-
/* @__PURE__ */
|
|
412
|
+
!!e.icon && /* @__PURE__ */ V(k, {
|
|
370
413
|
variant: "icon",
|
|
371
|
-
className:
|
|
372
|
-
children: e.icon
|
|
414
|
+
className: "text-muted-foreground",
|
|
415
|
+
children: e.icon
|
|
373
416
|
}),
|
|
374
|
-
/* @__PURE__ */
|
|
375
|
-
className:
|
|
376
|
-
children: [/* @__PURE__ */
|
|
377
|
-
className:
|
|
417
|
+
/* @__PURE__ */ H(N, {
|
|
418
|
+
className: Be,
|
|
419
|
+
children: [/* @__PURE__ */ V(F, {
|
|
420
|
+
className: Ve,
|
|
378
421
|
children: e.label
|
|
379
|
-
}), !!e.description && /* @__PURE__ */
|
|
422
|
+
}), !!e.description && /* @__PURE__ */ V(A, {
|
|
380
423
|
clamp: 2,
|
|
381
424
|
children: e.description
|
|
382
425
|
})]
|
|
383
426
|
}),
|
|
384
|
-
/* @__PURE__ */
|
|
427
|
+
/* @__PURE__ */ H(j, {
|
|
385
428
|
className: "ml-auto shrink-0 gap-space-md",
|
|
386
|
-
children: [/* @__PURE__ */
|
|
429
|
+
children: [/* @__PURE__ */ V(m, {
|
|
387
430
|
weight: "semibold",
|
|
388
|
-
className: "tabular-nums",
|
|
431
|
+
className: i("tabular-nums", e.tone && Ne[e.tone]),
|
|
389
432
|
children: e.value
|
|
390
433
|
}), t]
|
|
391
434
|
})
|
|
392
435
|
]
|
|
393
436
|
});
|
|
394
437
|
}
|
|
395
|
-
function
|
|
396
|
-
let
|
|
397
|
-
return /* @__PURE__ */
|
|
438
|
+
function Ke({ item: e, actionFallback: t, onSelect: n, actions: r }) {
|
|
439
|
+
let i = e.tone ?? (e.completed ? "success" : "neutral"), a = e.onSelect ?? n;
|
|
440
|
+
return /* @__PURE__ */ H(P, {
|
|
398
441
|
className: "product-readiness-row--component product-readiness-card--item",
|
|
399
442
|
children: [
|
|
400
|
-
/* @__PURE__ */
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
children: /* @__PURE__ */ R(We, { tone: a })
|
|
443
|
+
/* @__PURE__ */ V(k, {
|
|
444
|
+
className: "product-readiness-row--state h-icon-lg",
|
|
445
|
+
children: /* @__PURE__ */ V(Le, { tone: i })
|
|
404
446
|
}),
|
|
405
|
-
/* @__PURE__ */
|
|
406
|
-
className:
|
|
407
|
-
children: [/* @__PURE__ */
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
447
|
+
/* @__PURE__ */ H(N, {
|
|
448
|
+
className: Be,
|
|
449
|
+
children: [/* @__PURE__ */ V(Ue, {
|
|
450
|
+
label: e.label,
|
|
451
|
+
value: e.value,
|
|
452
|
+
tone: e.tone
|
|
453
|
+
}), !!e.description && /* @__PURE__ */ V(A, {
|
|
411
454
|
clamp: 2,
|
|
412
455
|
children: e.description
|
|
413
456
|
})]
|
|
414
457
|
}),
|
|
415
|
-
!!(
|
|
416
|
-
className:
|
|
417
|
-
children: [
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
}),
|
|
422
|
-
!!o && /* @__PURE__ */ R(s, {
|
|
423
|
-
type: "button",
|
|
424
|
-
tone: "secondary",
|
|
425
|
-
buttonStyle: "ghost",
|
|
426
|
-
onClick: o,
|
|
427
|
-
icon: V,
|
|
428
|
-
iconPosition: "right",
|
|
429
|
-
children: e.actionLabel ?? t
|
|
430
|
-
}),
|
|
431
|
-
r
|
|
432
|
-
]
|
|
458
|
+
!!(a || r) && /* @__PURE__ */ H(j, {
|
|
459
|
+
className: He,
|
|
460
|
+
children: [!!a && /* @__PURE__ */ V(We, {
|
|
461
|
+
label: e.actionLabel ?? t,
|
|
462
|
+
onSelect: a
|
|
463
|
+
}), r]
|
|
433
464
|
})
|
|
434
465
|
]
|
|
435
466
|
});
|
|
436
467
|
}
|
|
437
|
-
function
|
|
438
|
-
let
|
|
439
|
-
return /* @__PURE__ */
|
|
468
|
+
function qe({ item: e, actionFallback: t, onSelect: n, actions: r }) {
|
|
469
|
+
let i = e.onSelect ?? n;
|
|
470
|
+
return /* @__PURE__ */ H(P, {
|
|
440
471
|
className: "product-operation-row--component product-operations-card--item",
|
|
441
|
-
children: [
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
/* @__PURE__ */
|
|
448
|
-
|
|
449
|
-
children:
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
}),
|
|
457
|
-
|
|
458
|
-
className: "ml-auto shrink-0 flex-wrap justify-end gap-space-md",
|
|
459
|
-
children: [
|
|
460
|
-
!!e.value && /* @__PURE__ */ R(a, {
|
|
461
|
-
tag: "span",
|
|
462
|
-
weight: "semibold",
|
|
463
|
-
children: e.value
|
|
464
|
-
}),
|
|
465
|
-
!!c && /* @__PURE__ */ R(s, {
|
|
466
|
-
type: "button",
|
|
467
|
-
tone: "secondary",
|
|
468
|
-
buttonStyle: "ghost",
|
|
469
|
-
onClick: c,
|
|
470
|
-
icon: V,
|
|
471
|
-
iconPosition: "right",
|
|
472
|
-
children: e.actionLabel ?? t
|
|
473
|
-
}),
|
|
474
|
-
r
|
|
475
|
-
]
|
|
476
|
-
})
|
|
477
|
-
]
|
|
472
|
+
children: [/* @__PURE__ */ H(N, {
|
|
473
|
+
className: Be,
|
|
474
|
+
children: [/* @__PURE__ */ V(Ue, {
|
|
475
|
+
label: e.label,
|
|
476
|
+
value: e.value,
|
|
477
|
+
tone: e.tone
|
|
478
|
+
}), !!e.description && /* @__PURE__ */ V(A, {
|
|
479
|
+
clamp: 2,
|
|
480
|
+
children: e.description
|
|
481
|
+
})]
|
|
482
|
+
}), !!(i || r) && /* @__PURE__ */ H(j, {
|
|
483
|
+
className: He,
|
|
484
|
+
children: [!!i && /* @__PURE__ */ V(We, {
|
|
485
|
+
label: e.actionLabel ?? t,
|
|
486
|
+
onSelect: i
|
|
487
|
+
}), r]
|
|
488
|
+
})]
|
|
478
489
|
});
|
|
479
490
|
}
|
|
480
|
-
function
|
|
481
|
-
let
|
|
482
|
-
return /* @__PURE__ */
|
|
491
|
+
function Je({ item: e, actionLabel: t, onSelect: n, actions: r }) {
|
|
492
|
+
let i = "values" in e ? e.values : void 0;
|
|
493
|
+
return /* @__PURE__ */ H(P, {
|
|
483
494
|
className: "product-summary-row--component",
|
|
484
|
-
children: [
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
}),
|
|
501
|
-
!!c?.length && /* @__PURE__ */ R("div", {
|
|
502
|
-
className: "mt-space-md flex flex-wrap gap-space-xs",
|
|
503
|
-
children: c.map((e, t) => /* @__PURE__ */ R(g, {
|
|
504
|
-
tone: "secondary",
|
|
505
|
-
children: e
|
|
506
|
-
}, t))
|
|
507
|
-
})
|
|
508
|
-
]
|
|
509
|
-
}),
|
|
510
|
-
!!(e.value || e.badge || n || r) && /* @__PURE__ */ z(D, {
|
|
511
|
-
className: "ml-auto shrink-0 flex-wrap justify-end gap-space-md",
|
|
512
|
-
children: [
|
|
513
|
-
!!e.value && /* @__PURE__ */ R(a, {
|
|
514
|
-
tag: "span",
|
|
515
|
-
weight: "semibold",
|
|
516
|
-
children: e.value
|
|
517
|
-
}),
|
|
518
|
-
!!e.badge && e.badge,
|
|
519
|
-
!!n && /* @__PURE__ */ R(s, {
|
|
520
|
-
type: "button",
|
|
495
|
+
children: [/* @__PURE__ */ H(N, {
|
|
496
|
+
className: Be,
|
|
497
|
+
children: [
|
|
498
|
+
/* @__PURE__ */ V(Ue, {
|
|
499
|
+
label: e.label,
|
|
500
|
+
value: e.value,
|
|
501
|
+
tone: e.tone,
|
|
502
|
+
badge: e.badge
|
|
503
|
+
}),
|
|
504
|
+
!!e.description && /* @__PURE__ */ V(A, {
|
|
505
|
+
clamp: 2,
|
|
506
|
+
children: e.description
|
|
507
|
+
}),
|
|
508
|
+
!!i?.length && /* @__PURE__ */ V("div", {
|
|
509
|
+
className: "mt-space-md flex flex-wrap gap-space-xs",
|
|
510
|
+
children: i.map((e, t) => /* @__PURE__ */ V(_, {
|
|
521
511
|
tone: "secondary",
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
512
|
+
children: e
|
|
513
|
+
}, t))
|
|
514
|
+
})
|
|
515
|
+
]
|
|
516
|
+
}), !!(n || r) && /* @__PURE__ */ H(j, {
|
|
517
|
+
className: He,
|
|
518
|
+
children: [!!n && /* @__PURE__ */ V(We, {
|
|
519
|
+
label: t,
|
|
520
|
+
onSelect: n
|
|
521
|
+
}), r]
|
|
522
|
+
})]
|
|
532
523
|
});
|
|
533
524
|
}
|
|
534
525
|
//#endregion
|
|
535
526
|
//#region src/components/features/products/components/product-contract-overview.tsx
|
|
536
|
-
function
|
|
537
|
-
let x = r(
|
|
527
|
+
function Ye({ metrics: e = [], terms: t = [], rules: n = [], onOpenContract: a, onEditContract: u, onCreateRule: d, onSelectRule: f, onEditRule: p, onDeleteRule: m, renderRuleActions: h, actions: g, footerSlot: _, empty: v, className: y, strings: b }) {
|
|
528
|
+
let x = r(Se, b), S = e.length > 0 || t.length > 0 || n.length > 0, C = a || u || d ? /* @__PURE__ */ H("div", {
|
|
538
529
|
className: "flex items-center gap-space-md",
|
|
539
530
|
children: [
|
|
540
|
-
!!d && /* @__PURE__ */
|
|
531
|
+
!!d && /* @__PURE__ */ V(s, {
|
|
541
532
|
type: "button",
|
|
542
533
|
tone: "secondary",
|
|
543
534
|
buttonStyle: "ghost",
|
|
544
535
|
onClick: d,
|
|
545
|
-
icon:
|
|
536
|
+
icon: G,
|
|
546
537
|
children: x.createRuleLabel
|
|
547
538
|
}),
|
|
548
|
-
!!u && /* @__PURE__ */
|
|
539
|
+
!!u && /* @__PURE__ */ V(s, {
|
|
549
540
|
type: "button",
|
|
550
541
|
tone: "secondary",
|
|
551
542
|
buttonStyle: "ghost",
|
|
552
543
|
onClick: u,
|
|
553
|
-
icon: K,
|
|
554
544
|
children: x.editLabel
|
|
555
545
|
}),
|
|
556
|
-
!!
|
|
546
|
+
!!a && /* @__PURE__ */ V(s, {
|
|
557
547
|
type: "button",
|
|
558
548
|
tone: "secondary",
|
|
559
549
|
buttonStyle: "ghost",
|
|
560
|
-
onClick:
|
|
561
|
-
icon: V,
|
|
562
|
-
iconPosition: "right",
|
|
550
|
+
onClick: a,
|
|
563
551
|
children: x.actionLabel
|
|
564
552
|
})
|
|
565
553
|
]
|
|
566
554
|
}) : void 0;
|
|
567
|
-
return /* @__PURE__ */
|
|
568
|
-
icon: /* @__PURE__ */ R(U, { className: "size-icon" }),
|
|
555
|
+
return /* @__PURE__ */ V(E, {
|
|
569
556
|
title: x.title,
|
|
570
557
|
description: x.description,
|
|
571
558
|
actions: g,
|
|
572
|
-
headerAction:
|
|
559
|
+
headerAction: C,
|
|
573
560
|
footerSlot: _,
|
|
574
|
-
contentClassName: "mt-1",
|
|
575
561
|
className: i("product-contract-overview--component w-full", y),
|
|
576
|
-
children: S ? /* @__PURE__ */
|
|
577
|
-
gap: "
|
|
562
|
+
children: S ? /* @__PURE__ */ H(l, {
|
|
563
|
+
gap: "2xl",
|
|
578
564
|
children: [
|
|
579
|
-
e.length > 0 && /* @__PURE__ */
|
|
565
|
+
e.length > 0 && /* @__PURE__ */ V(c, {
|
|
580
566
|
columns: {
|
|
581
567
|
base: 1,
|
|
582
568
|
sm: 3
|
|
583
569
|
},
|
|
584
570
|
gap: "md",
|
|
585
|
-
children: e.map((e) => /* @__PURE__ */
|
|
571
|
+
children: e.map((e) => /* @__PURE__ */ V(Re, { metric: e }, e.id))
|
|
586
572
|
}),
|
|
587
|
-
t.length > 0 && /* @__PURE__ */
|
|
573
|
+
t.length > 0 && /* @__PURE__ */ H(l, {
|
|
588
574
|
gap: "md",
|
|
589
|
-
children: [/* @__PURE__ */
|
|
575
|
+
children: [/* @__PURE__ */ V(o, {
|
|
590
576
|
weight: "semibold",
|
|
591
577
|
children: x.termsTitle
|
|
592
|
-
}), /* @__PURE__ */
|
|
578
|
+
}), /* @__PURE__ */ V(se, {
|
|
593
579
|
items: t,
|
|
594
580
|
columns: 2,
|
|
595
581
|
density: "compact"
|
|
596
582
|
})]
|
|
597
583
|
}),
|
|
598
|
-
n.length > 0 && /* @__PURE__ */
|
|
584
|
+
n.length > 0 && /* @__PURE__ */ H(l, {
|
|
599
585
|
gap: "md",
|
|
600
|
-
children: [/* @__PURE__ */
|
|
586
|
+
children: [/* @__PURE__ */ V(o, {
|
|
601
587
|
weight: "semibold",
|
|
602
588
|
children: x.rulesTitle
|
|
603
|
-
}), /* @__PURE__ */
|
|
589
|
+
}), /* @__PURE__ */ V(M, { children: n.map((e, t) => {
|
|
604
590
|
let n = f ? () => f(e) : void 0, r = p ? () => p(e) : void 0, i = m ? () => m(e) : void 0, a = [
|
|
605
591
|
...n ? [{
|
|
606
592
|
id: "open",
|
|
607
593
|
label: x.viewRuleLabel,
|
|
608
|
-
icon: /* @__PURE__ */
|
|
594
|
+
icon: /* @__PURE__ */ V(he, { className: "size-icon-md" }),
|
|
609
595
|
onClick: () => n(),
|
|
610
596
|
tone: "secondary",
|
|
611
597
|
buttonStyle: "ghost"
|
|
@@ -613,7 +599,7 @@ function $e({ metrics: e = [], terms: t = [], rules: n = [], onOpenContract: o,
|
|
|
613
599
|
...r ? [{
|
|
614
600
|
id: "edit",
|
|
615
601
|
label: x.editRuleLabel,
|
|
616
|
-
icon: /* @__PURE__ */
|
|
602
|
+
icon: /* @__PURE__ */ V(W, { className: "size-icon-md" }),
|
|
617
603
|
onClick: () => r(),
|
|
618
604
|
tone: "secondary",
|
|
619
605
|
buttonStyle: "ghost"
|
|
@@ -621,7 +607,7 @@ function $e({ metrics: e = [], terms: t = [], rules: n = [], onOpenContract: o,
|
|
|
621
607
|
...i ? [{
|
|
622
608
|
id: "delete",
|
|
623
609
|
label: x.deleteRuleLabel,
|
|
624
|
-
icon: /* @__PURE__ */
|
|
610
|
+
icon: /* @__PURE__ */ V(q, { className: "size-icon-md" }),
|
|
625
611
|
onClick: () => i(),
|
|
626
612
|
tone: "destructive"
|
|
627
613
|
}] : []
|
|
@@ -630,63 +616,61 @@ function $e({ metrics: e = [], terms: t = [], rules: n = [], onOpenContract: o,
|
|
|
630
616
|
onSelect: n,
|
|
631
617
|
onEdit: r,
|
|
632
618
|
onDelete: i
|
|
633
|
-
}) : /* @__PURE__ */
|
|
619
|
+
}) : /* @__PURE__ */ V(ze, {
|
|
634
620
|
item: e,
|
|
635
621
|
actions: a,
|
|
636
622
|
menuLabel: x.ruleActionsLabel
|
|
637
623
|
});
|
|
638
|
-
return /* @__PURE__ */
|
|
624
|
+
return /* @__PURE__ */ V(Je, {
|
|
639
625
|
item: e,
|
|
640
626
|
actions: o
|
|
641
627
|
}, e.id);
|
|
642
628
|
}) })]
|
|
643
629
|
})
|
|
644
630
|
]
|
|
645
|
-
}) : v ?? /* @__PURE__ */
|
|
631
|
+
}) : v ?? /* @__PURE__ */ V($, {
|
|
646
632
|
title: x.emptyTitle,
|
|
647
633
|
description: x.emptyDescription,
|
|
648
|
-
action: d ? /* @__PURE__ */
|
|
634
|
+
action: d ? /* @__PURE__ */ V(s, {
|
|
635
|
+
tone: "primary",
|
|
649
636
|
type: "button",
|
|
650
637
|
onClick: d,
|
|
651
|
-
icon:
|
|
638
|
+
icon: G,
|
|
652
639
|
children: x.createRuleLabel
|
|
653
640
|
}) : void 0
|
|
654
641
|
})
|
|
655
642
|
});
|
|
656
643
|
}
|
|
657
|
-
|
|
644
|
+
Ye.displayName = "ProductContractOverview";
|
|
658
645
|
//#endregion
|
|
659
646
|
//#region src/components/features/products/components/product-details-card.tsx
|
|
660
|
-
function
|
|
661
|
-
let m = r(
|
|
647
|
+
function Xe({ title: e, description: t, metadata: n = [], media: a, onEditDetails: o, actions: c, headerEnd: l, footerSlot: u, empty: d, className: f, strings: p }) {
|
|
648
|
+
let m = r(xe, p), h = o ? /* @__PURE__ */ V(s, {
|
|
662
649
|
type: "button",
|
|
663
650
|
tone: "secondary",
|
|
664
651
|
buttonStyle: "ghost",
|
|
665
652
|
onClick: o,
|
|
666
|
-
icon: K,
|
|
667
653
|
children: m.editLabel
|
|
668
654
|
}) : void 0;
|
|
669
|
-
return /* @__PURE__ */
|
|
670
|
-
icon: /* @__PURE__ */ R(pe, { className: "size-icon" }),
|
|
655
|
+
return /* @__PURE__ */ V(E, {
|
|
671
656
|
title: e ?? m.title,
|
|
672
657
|
description: t === !1 ? void 0 : t ?? m.description,
|
|
673
658
|
actions: c,
|
|
674
659
|
headerAction: h,
|
|
675
660
|
headerEnd: l,
|
|
676
661
|
footerSlot: u,
|
|
677
|
-
contentClassName: "mt-1",
|
|
678
662
|
className: i("product-details-card--component w-full", f),
|
|
679
|
-
children: n.length === 0 ? d ?? /* @__PURE__ */
|
|
663
|
+
children: n.length === 0 ? d ?? /* @__PURE__ */ V($, {
|
|
680
664
|
title: m.emptyTitle,
|
|
681
665
|
description: m.emptyDescription
|
|
682
|
-
}) : /* @__PURE__ */
|
|
666
|
+
}) : /* @__PURE__ */ V("div", {
|
|
683
667
|
className: "@container/product-details",
|
|
684
|
-
children: /* @__PURE__ */
|
|
668
|
+
children: /* @__PURE__ */ H("div", {
|
|
685
669
|
className: i("grid min-w-0 grid-cols-1 gap-space-xl", a && "@xl/product-details:grid-cols-[12rem_minmax(0,1fr)]"),
|
|
686
|
-
children: [!!a && /* @__PURE__ */
|
|
687
|
-
className: "product-details-card--media overflow-hidden rounded-inner border border-border bg-muted/30",
|
|
670
|
+
children: [!!a && /* @__PURE__ */ V("div", {
|
|
671
|
+
className: "product-details-card--media self-start overflow-hidden rounded-inner border border-border bg-muted/30",
|
|
688
672
|
children: a
|
|
689
|
-
}), /* @__PURE__ */
|
|
673
|
+
}), /* @__PURE__ */ V(se, {
|
|
690
674
|
items: n,
|
|
691
675
|
columns: a ? 1 : 2,
|
|
692
676
|
density: "compact",
|
|
@@ -696,12 +680,12 @@ function et({ title: e, description: t, metadata: n = [], media: a, onEditDetail
|
|
|
696
680
|
})
|
|
697
681
|
});
|
|
698
682
|
}
|
|
699
|
-
|
|
683
|
+
Xe.displayName = "ProductDetailsCard";
|
|
700
684
|
//#endregion
|
|
701
685
|
//#region src/components/features/products/components/product-option-action-menu.tsx
|
|
702
|
-
function
|
|
703
|
-
let d = r(
|
|
704
|
-
return f || p || m || s ? s ? /* @__PURE__ */
|
|
686
|
+
function Ze({ option: e, index: t = 0, onSelectOption: n, onEditOption: a, onDeleteOption: o, renderOptionActions: s, menuLabel: c, className: l, strings: u }) {
|
|
687
|
+
let d = r(we, u), f = n ? () => n(e) : void 0, p = a ? () => a(e) : void 0, m = o ? () => o(e) : void 0;
|
|
688
|
+
return f || p || m || s ? s ? /* @__PURE__ */ V("div", {
|
|
705
689
|
className: i("product-option-action-menu--component flex justify-end", l),
|
|
706
690
|
children: s(e, {
|
|
707
691
|
index: t,
|
|
@@ -709,7 +693,7 @@ function tt({ option: e, index: t = 0, onSelectOption: n, onEditOption: a, onDel
|
|
|
709
693
|
onEdit: p,
|
|
710
694
|
onDelete: m
|
|
711
695
|
})
|
|
712
|
-
}) : /* @__PURE__ */
|
|
696
|
+
}) : /* @__PURE__ */ V(ze, {
|
|
713
697
|
item: e,
|
|
714
698
|
menuLabel: c ?? d.actionsLabel,
|
|
715
699
|
className: i("product-option-action-menu--component", l),
|
|
@@ -717,7 +701,7 @@ function tt({ option: e, index: t = 0, onSelectOption: n, onEditOption: a, onDel
|
|
|
717
701
|
...f ? [{
|
|
718
702
|
id: "open",
|
|
719
703
|
label: d.viewLabel,
|
|
720
|
-
icon: /* @__PURE__ */
|
|
704
|
+
icon: /* @__PURE__ */ V(he, { className: "size-icon-md" }),
|
|
721
705
|
onClick: () => f(),
|
|
722
706
|
tone: "secondary",
|
|
723
707
|
buttonStyle: "ghost"
|
|
@@ -725,7 +709,7 @@ function tt({ option: e, index: t = 0, onSelectOption: n, onEditOption: a, onDel
|
|
|
725
709
|
...p ? [{
|
|
726
710
|
id: "edit",
|
|
727
711
|
label: d.editLabel,
|
|
728
|
-
icon: /* @__PURE__ */
|
|
712
|
+
icon: /* @__PURE__ */ V(W, { className: "size-icon-md" }),
|
|
729
713
|
onClick: () => p(),
|
|
730
714
|
tone: "secondary",
|
|
731
715
|
buttonStyle: "ghost"
|
|
@@ -733,55 +717,54 @@ function tt({ option: e, index: t = 0, onSelectOption: n, onEditOption: a, onDel
|
|
|
733
717
|
...m ? [{
|
|
734
718
|
id: "delete",
|
|
735
719
|
label: d.deleteLabel,
|
|
736
|
-
icon: /* @__PURE__ */
|
|
720
|
+
icon: /* @__PURE__ */ V(q, { className: "size-icon-md" }),
|
|
737
721
|
onClick: () => m(),
|
|
738
722
|
tone: "destructive"
|
|
739
723
|
}] : []
|
|
740
724
|
]
|
|
741
725
|
}) : null;
|
|
742
726
|
}
|
|
743
|
-
|
|
727
|
+
Ze.displayName = "ProductOptionActionMenu";
|
|
744
728
|
//#endregion
|
|
745
729
|
//#region src/components/features/products/components/product-operations-card.tsx
|
|
746
|
-
function
|
|
747
|
-
let h = r(
|
|
730
|
+
function Qe({ items: e = [], onCreateOperation: t, onSelectOperation: n, onEditOperation: a, onDeleteOperation: o, renderOperationActions: c, actions: l, footerSlot: u, renderItem: d, empty: f, className: p, strings: m }) {
|
|
731
|
+
let h = r(be, m), g = t ? /* @__PURE__ */ V(s, {
|
|
748
732
|
type: "button",
|
|
749
733
|
tone: "secondary",
|
|
750
734
|
buttonStyle: "ghost",
|
|
751
735
|
onClick: t,
|
|
752
|
-
icon:
|
|
736
|
+
icon: G,
|
|
753
737
|
children: h.createLabel
|
|
754
738
|
}) : void 0;
|
|
755
|
-
return /* @__PURE__ */
|
|
756
|
-
icon: /* @__PURE__ */ R(ye, { className: "size-icon" }),
|
|
739
|
+
return /* @__PURE__ */ V(E, {
|
|
757
740
|
title: h.title,
|
|
758
741
|
description: h.description,
|
|
759
742
|
actions: l,
|
|
760
743
|
headerAction: g,
|
|
761
744
|
footerSlot: u,
|
|
762
|
-
contentClassName: "mt-1",
|
|
763
745
|
className: i("product-operations-card--component w-full", p),
|
|
764
|
-
children: e.length === 0 ? f ?? /* @__PURE__ */
|
|
746
|
+
children: e.length === 0 ? f ?? /* @__PURE__ */ V($, {
|
|
765
747
|
title: h.emptyTitle,
|
|
766
748
|
description: h.emptyDescription,
|
|
767
|
-
action: t ? /* @__PURE__ */
|
|
749
|
+
action: t ? /* @__PURE__ */ V(s, {
|
|
750
|
+
tone: "primary",
|
|
768
751
|
type: "button",
|
|
769
752
|
onClick: t,
|
|
770
|
-
icon:
|
|
753
|
+
icon: G,
|
|
771
754
|
children: h.createLabel
|
|
772
755
|
}) : void 0
|
|
773
|
-
}) : /* @__PURE__ */
|
|
756
|
+
}) : /* @__PURE__ */ V(M, { children: e.map((e, t) => {
|
|
774
757
|
let r = n ? () => n(e) : void 0, i = a ? () => a(e) : void 0, s = o ? () => o(e) : void 0, l = [...i ? [{
|
|
775
758
|
id: "edit",
|
|
776
759
|
label: h.editLabel,
|
|
777
|
-
icon: /* @__PURE__ */
|
|
760
|
+
icon: /* @__PURE__ */ V(W, { className: "size-icon-md" }),
|
|
778
761
|
onClick: () => i(),
|
|
779
762
|
tone: "secondary",
|
|
780
763
|
buttonStyle: "ghost"
|
|
781
764
|
}] : [], ...s ? [{
|
|
782
765
|
id: "delete",
|
|
783
766
|
label: h.deleteLabel,
|
|
784
|
-
icon: /* @__PURE__ */
|
|
767
|
+
icon: /* @__PURE__ */ V(q, { className: "size-icon-md" }),
|
|
785
768
|
onClick: () => s(),
|
|
786
769
|
tone: "destructive"
|
|
787
770
|
}] : []], u = c ? c(e, {
|
|
@@ -789,12 +772,12 @@ function nt({ items: e = [], onCreateOperation: t, onSelectOperation: n, onEditO
|
|
|
789
772
|
onSelect: r,
|
|
790
773
|
onEdit: i,
|
|
791
774
|
onDelete: s
|
|
792
|
-
}) : /* @__PURE__ */
|
|
775
|
+
}) : /* @__PURE__ */ V(ze, {
|
|
793
776
|
item: e,
|
|
794
777
|
actions: l,
|
|
795
778
|
menuLabel: h.actionsLabel
|
|
796
779
|
});
|
|
797
|
-
return d ? /* @__PURE__ */
|
|
780
|
+
return d ? /* @__PURE__ */ V("div", { children: d(e, t) }, e.id) : /* @__PURE__ */ V(qe, {
|
|
798
781
|
item: e,
|
|
799
782
|
actionFallback: h.actionLabel,
|
|
800
783
|
onSelect: r,
|
|
@@ -803,236 +786,236 @@ function nt({ items: e = [], onCreateOperation: t, onSelectOperation: n, onEditO
|
|
|
803
786
|
}) })
|
|
804
787
|
});
|
|
805
788
|
}
|
|
806
|
-
|
|
789
|
+
Qe.displayName = "ProductOperationsCard";
|
|
807
790
|
//#endregion
|
|
808
791
|
//#region src/components/features/products/components/product-options-matrix.tsx
|
|
809
|
-
function
|
|
792
|
+
function $e(e) {
|
|
810
793
|
return typeof e == "string" || typeof e == "number" ? String(e) : "";
|
|
811
794
|
}
|
|
812
|
-
function
|
|
795
|
+
function et(e) {
|
|
813
796
|
return typeof e == "string" || typeof e == "number" || typeof e == "bigint";
|
|
814
797
|
}
|
|
815
|
-
function
|
|
816
|
-
let n =
|
|
798
|
+
function tt(e, t) {
|
|
799
|
+
let n = $e(t.name);
|
|
817
800
|
return n ? `${e}: ${n}` : e;
|
|
818
801
|
}
|
|
819
|
-
function
|
|
802
|
+
function nt(e) {
|
|
820
803
|
return {
|
|
821
|
-
name:
|
|
804
|
+
name: $e(e.name),
|
|
822
805
|
values: (e.values ?? []).map((e) => ({
|
|
823
806
|
...e,
|
|
824
|
-
label:
|
|
807
|
+
label: $e(e.label)
|
|
825
808
|
}))
|
|
826
809
|
};
|
|
827
810
|
}
|
|
828
|
-
function
|
|
829
|
-
let
|
|
830
|
-
|
|
811
|
+
function rt({ optionGroups: e = [], surface: t = "card", collapsedOptionIds: a, defaultCollapsedOptionIds: c = [], onCollapsedOptionIdsChange: u, editingOptionId: d, defaultEditingOptionId: m, onEditingOptionIdChange: h, onCreateOption: g, onEditOption: _, onDeleteOption: v, confirmDelete: S, onAddValue: C, onDeleteValue: T, onOptionNameChange: D, onValueLabelChange: O, onDoneEditingOption: k, onSaveEditingOption: A, onCancelEditingOption: j, onToggleUsedForVariants: M, renderOptionActions: N, renderValue: P, showHeader: F, showCollapseControls: ee = !0, showInlineActions: I = !0, showVariantToggle: te = !0, actions: ne, headerEnd: re, footerSlot: ie, empty: ae, className: oe, strings: se }) {
|
|
812
|
+
let L = r(Te, se), ce = a !== void 0, [z, fe] = ue(c), me = ce ? a : z, he = B(() => new Set(me), [me]), U = d !== void 0 || m !== void 0 || !!h || !!D || !!O || !!k || !!A || !!j, W = d !== void 0, [ve, K] = ue(m ?? null), [J, Y] = ue({}), be = U ? W ? d : ve : null, xe = e.length > 0, Se = t === "embedded" && F !== !1, Ce = xe && !!g, we = R((t) => {
|
|
813
|
+
ce || fe(t), u?.(t, e.filter((e) => t.includes(e.id)));
|
|
831
814
|
}, [
|
|
832
|
-
|
|
815
|
+
ce,
|
|
833
816
|
u,
|
|
834
817
|
e
|
|
835
|
-
]),
|
|
836
|
-
let t =
|
|
837
|
-
|
|
818
|
+
]), Ee = R((e) => {
|
|
819
|
+
let t = he.has(e.id) ? me.filter((t) => t !== e.id) : [...me, e.id];
|
|
820
|
+
we(t);
|
|
838
821
|
}, [
|
|
839
|
-
ge,
|
|
840
822
|
he,
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
823
|
+
me,
|
|
824
|
+
we
|
|
825
|
+
]), X = R((e, t) => {
|
|
826
|
+
U && (W || K(e), h?.(e, t));
|
|
844
827
|
}, [
|
|
845
|
-
|
|
828
|
+
W,
|
|
846
829
|
h,
|
|
847
|
-
|
|
848
|
-
]),
|
|
849
|
-
|
|
830
|
+
U
|
|
831
|
+
]), Z = R((e) => {
|
|
832
|
+
Y((t) => ({
|
|
850
833
|
...t,
|
|
851
|
-
[e.id]:
|
|
852
|
-
})), X(e.id, e),
|
|
853
|
-
}, [
|
|
854
|
-
|
|
834
|
+
[e.id]: nt(e)
|
|
835
|
+
})), X(e.id, e), _?.(e);
|
|
836
|
+
}, [_, X]), De = R((e) => J[e.id] ?? nt(e), [J]), Oe = R((e, t) => {
|
|
837
|
+
Y((n) => ({
|
|
855
838
|
...n,
|
|
856
|
-
[e.id]: t(n[e.id] ??
|
|
839
|
+
[e.id]: t(n[e.id] ?? nt(e))
|
|
857
840
|
}));
|
|
858
|
-
}, []),
|
|
859
|
-
let t =
|
|
860
|
-
|
|
841
|
+
}, []), ke = R((e) => {
|
|
842
|
+
let t = De(e);
|
|
843
|
+
Y((t) => {
|
|
861
844
|
let { [e.id]: n, ...r } = t;
|
|
862
845
|
return r;
|
|
863
846
|
}), X(null, e), j?.(e, t);
|
|
864
847
|
}, [
|
|
865
|
-
|
|
848
|
+
De,
|
|
866
849
|
j,
|
|
867
850
|
X
|
|
868
|
-
]),
|
|
869
|
-
let t =
|
|
851
|
+
]), Q = R((e) => {
|
|
852
|
+
let t = De(e), n = e.values ?? [], r = new Set(n.map((e) => e.id)), i = new Set(t.values.map((e) => e.id));
|
|
870
853
|
A?.(e, t), D?.(e, t.name), n.forEach((n) => {
|
|
871
854
|
let r = t.values.find((e) => e.id === n.id);
|
|
872
|
-
r &&
|
|
855
|
+
r && $e(n.label) !== $e(r.label) && O?.(e, n, $e(r.label));
|
|
873
856
|
}), t.values.forEach((t) => {
|
|
874
|
-
r.has(t.id) ||
|
|
857
|
+
r.has(t.id) || C?.(e);
|
|
875
858
|
}), n.forEach((t) => {
|
|
876
|
-
i.has(t.id) ||
|
|
877
|
-
}),
|
|
859
|
+
i.has(t.id) || T?.(e, t);
|
|
860
|
+
}), Y((t) => {
|
|
878
861
|
let { [e.id]: n, ...r } = t;
|
|
879
862
|
return r;
|
|
880
863
|
}), X(null, e), k?.(e);
|
|
881
864
|
}, [
|
|
882
|
-
|
|
865
|
+
De,
|
|
866
|
+
C,
|
|
883
867
|
T,
|
|
884
|
-
E,
|
|
885
868
|
k,
|
|
886
869
|
D,
|
|
887
870
|
A,
|
|
888
871
|
O,
|
|
889
872
|
X
|
|
890
|
-
]),
|
|
891
|
-
let t =
|
|
873
|
+
]), Ae = f(), [je, Me] = ue(null), Ne = R((e) => {
|
|
874
|
+
let t = De(e), n = new Set(t.values.map((e) => e.id)), r = (e.values ?? []).filter((e) => !n.has(e.id)).length;
|
|
892
875
|
if (S === !1 || r === 0) {
|
|
893
|
-
|
|
876
|
+
Q(e);
|
|
894
877
|
return;
|
|
895
878
|
}
|
|
896
|
-
|
|
879
|
+
Me({
|
|
897
880
|
option: e,
|
|
898
881
|
removed: r
|
|
899
|
-
}),
|
|
882
|
+
}), Ae.show();
|
|
900
883
|
}, [
|
|
901
|
-
De,
|
|
902
|
-
S,
|
|
903
884
|
Q,
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
885
|
+
S,
|
|
886
|
+
De,
|
|
887
|
+
Ae
|
|
888
|
+
]), Pe = R((e) => {
|
|
889
|
+
be === e.id && (Y((t) => {
|
|
907
890
|
let { [e.id]: n, ...r } = t;
|
|
908
891
|
return r;
|
|
909
|
-
}), X(null, e)),
|
|
892
|
+
}), X(null, e)), v?.(e);
|
|
910
893
|
}, [
|
|
911
|
-
|
|
912
|
-
|
|
894
|
+
v,
|
|
895
|
+
be,
|
|
913
896
|
X
|
|
914
|
-
]),
|
|
897
|
+
]), Fe = f(), [Ie, Le] = ue(null), Re = R((e) => {
|
|
915
898
|
if (S === !1) {
|
|
916
|
-
|
|
899
|
+
Pe(e);
|
|
917
900
|
return;
|
|
918
901
|
}
|
|
919
|
-
|
|
902
|
+
Le(e), Fe.show();
|
|
920
903
|
}, [
|
|
921
904
|
S,
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
]),
|
|
905
|
+
Pe,
|
|
906
|
+
Fe
|
|
907
|
+
]), Be = g ? /* @__PURE__ */ V(s, {
|
|
925
908
|
type: "button",
|
|
926
909
|
tone: "neutral",
|
|
927
910
|
onClick: g,
|
|
928
|
-
icon:
|
|
929
|
-
children:
|
|
930
|
-
}) : void 0,
|
|
911
|
+
icon: G,
|
|
912
|
+
children: L.createLabel
|
|
913
|
+
}) : void 0, Ve = Se ? /* @__PURE__ */ V("div", {
|
|
931
914
|
className: "product-options-matrix--panel-header p-surface",
|
|
932
|
-
children: /* @__PURE__ */
|
|
915
|
+
children: /* @__PURE__ */ H(l, {
|
|
933
916
|
direction: "horizontal",
|
|
934
917
|
gap: "md",
|
|
935
918
|
justify: "between",
|
|
936
|
-
children: [/* @__PURE__ */
|
|
919
|
+
children: [/* @__PURE__ */ V(o, {
|
|
937
920
|
weight: "semibold",
|
|
938
|
-
children:
|
|
939
|
-
}),
|
|
921
|
+
children: L.title
|
|
922
|
+
}), Be]
|
|
940
923
|
})
|
|
941
|
-
}) : null,
|
|
924
|
+
}) : null, He = /* @__PURE__ */ H("div", {
|
|
942
925
|
className: "product-options-matrix--body min-w-0",
|
|
943
926
|
children: [
|
|
944
|
-
/* @__PURE__ */
|
|
927
|
+
/* @__PURE__ */ H("div", {
|
|
945
928
|
className: "product-options-matrix--panel overflow-hidden rounded-radius border border-border bg-background",
|
|
946
|
-
children: [
|
|
947
|
-
className: i("product-options-matrix--list",
|
|
929
|
+
children: [Ve, xe ? /* @__PURE__ */ H("div", {
|
|
930
|
+
className: i("product-options-matrix--list", Se && "border-t border-border/70"),
|
|
948
931
|
children: [e.map((e, t) => {
|
|
949
|
-
let n = e.values ?? [], r =
|
|
932
|
+
let n = e.values ?? [], r = he.has(e.id), a = be === e.id, c = !!_ || U, u = !!v, d = !!C, f = De(e), p = N?.(e, {
|
|
950
933
|
index: t,
|
|
951
|
-
onEdit: c ? () =>
|
|
952
|
-
onDelete:
|
|
953
|
-
onAddValue:
|
|
954
|
-
onToggleCollapsed: () =>
|
|
934
|
+
onEdit: c ? () => Z(e) : void 0,
|
|
935
|
+
onDelete: v ? () => Re(e) : void 0,
|
|
936
|
+
onAddValue: C ? () => C(e) : void 0,
|
|
937
|
+
onToggleCollapsed: () => Ee(e),
|
|
955
938
|
collapsed: r
|
|
956
939
|
}), m = [...d ? [{
|
|
957
940
|
id: "add-value",
|
|
958
|
-
label:
|
|
959
|
-
icon: /* @__PURE__ */
|
|
960
|
-
onClick: () =>
|
|
941
|
+
label: L.addValueLabel,
|
|
942
|
+
icon: /* @__PURE__ */ V(G, { className: "size-icon-md" }),
|
|
943
|
+
onClick: () => C?.(e),
|
|
961
944
|
tone: "secondary",
|
|
962
945
|
buttonStyle: "ghost"
|
|
963
946
|
}] : [], ...u ? [{
|
|
964
947
|
id: "delete",
|
|
965
|
-
label:
|
|
966
|
-
icon: /* @__PURE__ */
|
|
967
|
-
onClick: () =>
|
|
948
|
+
label: L.deleteLabel,
|
|
949
|
+
icon: /* @__PURE__ */ V(q, { className: "size-icon-md" }),
|
|
950
|
+
onClick: () => Re(e),
|
|
968
951
|
tone: "destructive"
|
|
969
|
-
}] : []], h =
|
|
952
|
+
}] : []], h = I ? /* @__PURE__ */ H(de, { children: [!!c && /* @__PURE__ */ V(s, {
|
|
970
953
|
type: "button",
|
|
971
954
|
tone: "secondary",
|
|
972
955
|
buttonStyle: "ghost",
|
|
973
|
-
onClick: () =>
|
|
974
|
-
children:
|
|
975
|
-
}), /* @__PURE__ */
|
|
956
|
+
onClick: () => Z(e),
|
|
957
|
+
children: L.editLabel
|
|
958
|
+
}), /* @__PURE__ */ V(ze, {
|
|
976
959
|
item: e,
|
|
977
960
|
actions: m,
|
|
978
|
-
menuLabel:
|
|
961
|
+
menuLabel: L.actionsLabel
|
|
979
962
|
})] }) : null, g = p === void 0 ? h : p;
|
|
980
|
-
if (
|
|
963
|
+
if (a) return /* @__PURE__ */ V("div", {
|
|
981
964
|
className: "product-options-matrix--item product-options-matrix--item-editing border-b border-border/70 p-surface last:border-b-0",
|
|
982
|
-
children: /* @__PURE__ */
|
|
965
|
+
children: /* @__PURE__ */ H("div", {
|
|
983
966
|
className: "grid min-w-0 grid-cols-[auto_minmax(0,1fr)] gap-x-space-md gap-y-space-lg",
|
|
984
|
-
children: [/* @__PURE__ */
|
|
967
|
+
children: [/* @__PURE__ */ V("span", {
|
|
985
968
|
className: "product-options-matrix--drag-handle self-start flex size-icon-lg items-center justify-center text-muted-foreground",
|
|
986
969
|
"aria-hidden": "true",
|
|
987
|
-
children: /* @__PURE__ */
|
|
988
|
-
}), /* @__PURE__ */
|
|
970
|
+
children: /* @__PURE__ */ V(ge, { className: "size-icon-sm" })
|
|
971
|
+
}), /* @__PURE__ */ H(l, {
|
|
989
972
|
gap: "lg",
|
|
990
973
|
className: "product-options-matrix--editor",
|
|
991
974
|
children: [
|
|
992
|
-
/* @__PURE__ */
|
|
993
|
-
label:
|
|
975
|
+
/* @__PURE__ */ V(x, {
|
|
976
|
+
label: L.optionNameLabel,
|
|
994
977
|
className: "product-options-matrix--editor-field",
|
|
995
|
-
children: /* @__PURE__ */
|
|
978
|
+
children: /* @__PURE__ */ V(b, {
|
|
996
979
|
value: f.name,
|
|
997
980
|
onChange: (t) => {
|
|
998
981
|
let n = t.currentTarget.value;
|
|
999
|
-
|
|
982
|
+
Oe(e, (e) => ({
|
|
1000
983
|
...e,
|
|
1001
984
|
name: n
|
|
1002
985
|
}));
|
|
1003
986
|
},
|
|
1004
|
-
"aria-label":
|
|
987
|
+
"aria-label": L.optionNameLabel,
|
|
1005
988
|
className: "bg-background"
|
|
1006
989
|
})
|
|
1007
990
|
}),
|
|
1008
|
-
/* @__PURE__ */
|
|
991
|
+
/* @__PURE__ */ H(l, {
|
|
1009
992
|
gap: "sm",
|
|
1010
993
|
className: "product-options-matrix--editor-field",
|
|
1011
|
-
children: [/* @__PURE__ */
|
|
994
|
+
children: [/* @__PURE__ */ V(o, {
|
|
1012
995
|
weight: "medium",
|
|
1013
|
-
children:
|
|
1014
|
-
}), /* @__PURE__ */
|
|
996
|
+
children: L.optionValuesLabel
|
|
997
|
+
}), /* @__PURE__ */ H(l, {
|
|
1015
998
|
gap: "xs",
|
|
1016
999
|
className: "product-options-matrix--editor-values",
|
|
1017
1000
|
children: [
|
|
1018
|
-
f.values.length === 0 && /* @__PURE__ */
|
|
1001
|
+
f.values.length === 0 && /* @__PURE__ */ V(o, {
|
|
1019
1002
|
size: "xs",
|
|
1020
1003
|
type: "secondary",
|
|
1021
|
-
children:
|
|
1004
|
+
children: L.noValuesLabel
|
|
1022
1005
|
}),
|
|
1023
|
-
f.values.map((t) => /* @__PURE__ */
|
|
1006
|
+
f.values.map((t) => /* @__PURE__ */ H("div", {
|
|
1024
1007
|
className: "product-options-matrix--editor-value grid min-w-0 grid-cols-[auto_minmax(0,1fr)_auto] items-center gap-space-sm",
|
|
1025
1008
|
children: [
|
|
1026
|
-
/* @__PURE__ */
|
|
1009
|
+
/* @__PURE__ */ V("span", {
|
|
1027
1010
|
className: "flex size-icon-lg items-center justify-center text-muted-foreground",
|
|
1028
1011
|
"aria-hidden": "true",
|
|
1029
|
-
children: /* @__PURE__ */
|
|
1012
|
+
children: /* @__PURE__ */ V(ge, { className: "size-icon-sm" })
|
|
1030
1013
|
}),
|
|
1031
|
-
/* @__PURE__ */
|
|
1032
|
-
value:
|
|
1014
|
+
/* @__PURE__ */ V(b, {
|
|
1015
|
+
value: $e(t.label),
|
|
1033
1016
|
onChange: (n) => {
|
|
1034
1017
|
let r = n.currentTarget.value;
|
|
1035
|
-
|
|
1018
|
+
Oe(e, (e) => ({
|
|
1036
1019
|
...e,
|
|
1037
1020
|
values: e.values.map((e) => e.id === t.id ? {
|
|
1038
1021
|
...e,
|
|
@@ -1040,45 +1023,45 @@ function st({ optionGroups: e = [], surface: t = "card", collapsedOptionIds: o,
|
|
|
1040
1023
|
} : e)
|
|
1041
1024
|
}));
|
|
1042
1025
|
},
|
|
1043
|
-
"aria-label": `${
|
|
1026
|
+
"aria-label": `${L.optionValuesLabel}: ${$e(t.label)}`,
|
|
1044
1027
|
className: "bg-background"
|
|
1045
1028
|
}),
|
|
1046
|
-
/* @__PURE__ */
|
|
1029
|
+
/* @__PURE__ */ H(s, {
|
|
1047
1030
|
type: "button",
|
|
1048
1031
|
size: "sm",
|
|
1049
1032
|
iconOnly: !0,
|
|
1050
1033
|
tone: "secondary",
|
|
1051
1034
|
buttonStyle: "ghost",
|
|
1052
|
-
onClick: () =>
|
|
1035
|
+
onClick: () => Oe(e, (e) => ({
|
|
1053
1036
|
...e,
|
|
1054
1037
|
values: e.values.filter((e) => e.id !== t.id)
|
|
1055
1038
|
})),
|
|
1056
|
-
"aria-label":
|
|
1039
|
+
"aria-label": L.deleteValueLabel,
|
|
1057
1040
|
className: "text-muted-foreground hover:text-destructive",
|
|
1058
|
-
children: [/* @__PURE__ */
|
|
1041
|
+
children: [/* @__PURE__ */ V(q, {
|
|
1059
1042
|
className: "size-icon-sm",
|
|
1060
1043
|
"aria-hidden": "true"
|
|
1061
|
-
}), /* @__PURE__ */
|
|
1044
|
+
}), /* @__PURE__ */ V(o, {
|
|
1062
1045
|
tag: "span",
|
|
1063
1046
|
size: "pxs",
|
|
1064
1047
|
className: "sr-only",
|
|
1065
|
-
children:
|
|
1048
|
+
children: L.deleteValueLabel
|
|
1066
1049
|
})]
|
|
1067
1050
|
})
|
|
1068
1051
|
]
|
|
1069
1052
|
}, t.id)),
|
|
1070
|
-
/* @__PURE__ */
|
|
1053
|
+
/* @__PURE__ */ H("div", {
|
|
1071
1054
|
className: "product-options-matrix--editor-add-value grid min-w-0 grid-cols-[auto_minmax(0,1fr)_auto] items-center gap-space-sm",
|
|
1072
1055
|
children: [
|
|
1073
|
-
/* @__PURE__ */
|
|
1056
|
+
/* @__PURE__ */ V("span", {
|
|
1074
1057
|
className: "size-icon-lg",
|
|
1075
1058
|
"aria-hidden": "true"
|
|
1076
1059
|
}),
|
|
1077
|
-
/* @__PURE__ */
|
|
1060
|
+
/* @__PURE__ */ V(s, {
|
|
1078
1061
|
type: "button",
|
|
1079
1062
|
tone: "secondary",
|
|
1080
1063
|
buttonStyle: "outline",
|
|
1081
|
-
onClick: () =>
|
|
1064
|
+
onClick: () => Oe(e, (t) => {
|
|
1082
1065
|
let n = t.values.length + 1;
|
|
1083
1066
|
return {
|
|
1084
1067
|
...t,
|
|
@@ -1090,9 +1073,9 @@ function st({ optionGroups: e = [], surface: t = "card", collapsedOptionIds: o,
|
|
|
1090
1073
|
}),
|
|
1091
1074
|
fullWidth: !0,
|
|
1092
1075
|
className: "justify-start border-input bg-background text-muted-foreground hover:bg-muted/60",
|
|
1093
|
-
children:
|
|
1076
|
+
children: L.addAnotherValueLabel
|
|
1094
1077
|
}),
|
|
1095
|
-
/* @__PURE__ */
|
|
1078
|
+
/* @__PURE__ */ V("span", {
|
|
1096
1079
|
className: "size-action-sm",
|
|
1097
1080
|
"aria-hidden": "true"
|
|
1098
1081
|
})
|
|
@@ -1101,34 +1084,34 @@ function st({ optionGroups: e = [], surface: t = "card", collapsedOptionIds: o,
|
|
|
1101
1084
|
]
|
|
1102
1085
|
})]
|
|
1103
1086
|
}),
|
|
1104
|
-
/* @__PURE__ */
|
|
1087
|
+
/* @__PURE__ */ H(l, {
|
|
1105
1088
|
direction: "horizontal",
|
|
1106
1089
|
gap: "md",
|
|
1107
1090
|
justify: "between",
|
|
1108
1091
|
wrap: !1,
|
|
1109
1092
|
className: "product-options-matrix--editor-actions",
|
|
1110
|
-
children: [/* @__PURE__ */
|
|
1093
|
+
children: [/* @__PURE__ */ V("div", { children: !!v && /* @__PURE__ */ V(s, {
|
|
1111
1094
|
type: "button",
|
|
1112
1095
|
tone: "destructive",
|
|
1113
1096
|
buttonStyle: "outline",
|
|
1114
|
-
onClick: () =>
|
|
1115
|
-
children:
|
|
1116
|
-
}) }), /* @__PURE__ */
|
|
1097
|
+
onClick: () => Re(e),
|
|
1098
|
+
children: L.deleteLabel
|
|
1099
|
+
}) }), /* @__PURE__ */ H(l, {
|
|
1117
1100
|
direction: "horizontal",
|
|
1118
1101
|
gap: "sm",
|
|
1119
1102
|
justify: "end",
|
|
1120
1103
|
wrap: !1,
|
|
1121
|
-
children: [/* @__PURE__ */
|
|
1104
|
+
children: [/* @__PURE__ */ V(s, {
|
|
1122
1105
|
type: "button",
|
|
1123
1106
|
tone: "secondary",
|
|
1124
1107
|
buttonStyle: "ghost",
|
|
1125
|
-
onClick: () =>
|
|
1126
|
-
children:
|
|
1127
|
-
}), /* @__PURE__ */
|
|
1108
|
+
onClick: () => ke(e),
|
|
1109
|
+
children: L.cancelLabel
|
|
1110
|
+
}), /* @__PURE__ */ V(s, {
|
|
1128
1111
|
type: "button",
|
|
1129
1112
|
tone: "neutral",
|
|
1130
|
-
onClick: () =>
|
|
1131
|
-
children:
|
|
1113
|
+
onClick: () => Ne(e),
|
|
1114
|
+
children: L.saveLabel ?? L.doneLabel
|
|
1132
1115
|
})]
|
|
1133
1116
|
})]
|
|
1134
1117
|
})
|
|
@@ -1136,69 +1119,69 @@ function st({ optionGroups: e = [], surface: t = "card", collapsedOptionIds: o,
|
|
|
1136
1119
|
})]
|
|
1137
1120
|
})
|
|
1138
1121
|
}, e.id);
|
|
1139
|
-
let S = /* @__PURE__ */
|
|
1140
|
-
render: /* @__PURE__ */
|
|
1122
|
+
let S = /* @__PURE__ */ H(l, {
|
|
1123
|
+
render: /* @__PURE__ */ V("span", {}),
|
|
1141
1124
|
gap: "sm",
|
|
1142
1125
|
children: [
|
|
1143
|
-
/* @__PURE__ */
|
|
1144
|
-
render: /* @__PURE__ */
|
|
1126
|
+
/* @__PURE__ */ H(l, {
|
|
1127
|
+
render: /* @__PURE__ */ V("span", {}),
|
|
1145
1128
|
direction: "horizontal",
|
|
1146
1129
|
gap: "sm",
|
|
1147
|
-
children: [/* @__PURE__ */
|
|
1130
|
+
children: [/* @__PURE__ */ V(o, {
|
|
1148
1131
|
tag: "span",
|
|
1149
1132
|
weight: "semibold",
|
|
1150
1133
|
className: "min-w-0 whitespace-normal break-words",
|
|
1151
1134
|
children: e.name
|
|
1152
1135
|
}), e.badge]
|
|
1153
1136
|
}),
|
|
1154
|
-
!!e.description && /* @__PURE__ */
|
|
1137
|
+
!!e.description && /* @__PURE__ */ V(o, {
|
|
1155
1138
|
tag: "span",
|
|
1156
1139
|
size: "xs",
|
|
1157
1140
|
type: "secondary",
|
|
1158
1141
|
className: "max-w-prose",
|
|
1159
1142
|
children: e.description
|
|
1160
1143
|
}),
|
|
1161
|
-
!r && /* @__PURE__ */
|
|
1162
|
-
render: /* @__PURE__ */
|
|
1144
|
+
!r && /* @__PURE__ */ V(l, {
|
|
1145
|
+
render: /* @__PURE__ */ V("span", {}),
|
|
1163
1146
|
gap: "sm",
|
|
1164
1147
|
className: "product-options-matrix--values",
|
|
1165
|
-
children: n.length === 0 ? /* @__PURE__ */
|
|
1148
|
+
children: n.length === 0 ? /* @__PURE__ */ V(o, {
|
|
1166
1149
|
tag: "span",
|
|
1167
1150
|
size: "xs",
|
|
1168
1151
|
type: "secondary",
|
|
1169
|
-
children:
|
|
1170
|
-
}) : /* @__PURE__ */
|
|
1152
|
+
children: L.noValuesLabel
|
|
1153
|
+
}) : /* @__PURE__ */ V("span", {
|
|
1171
1154
|
className: "flex flex-wrap gap-space-xs",
|
|
1172
1155
|
children: n.map((n, r) => {
|
|
1173
|
-
let
|
|
1156
|
+
let a = T ? () => T(e, n) : void 0, s = P?.(n, {
|
|
1174
1157
|
option: e,
|
|
1175
1158
|
optionIndex: t,
|
|
1176
1159
|
valueIndex: r,
|
|
1177
|
-
onDelete:
|
|
1160
|
+
onDelete: a
|
|
1178
1161
|
});
|
|
1179
|
-
return s ? /* @__PURE__ */
|
|
1162
|
+
return s ? /* @__PURE__ */ V(le, { children: s }, n.id) : /* @__PURE__ */ H("span", {
|
|
1180
1163
|
className: i("product-options-matrix--value inline-flex max-w-full items-center gap-space-xs rounded-radius bg-muted px-space-sm py-space-xs text-pxs font-medium leading-none text-muted-foreground", n.disabled && "opacity-60"),
|
|
1181
1164
|
children: [
|
|
1182
|
-
|
|
1165
|
+
et(n.label) ? /* @__PURE__ */ V(o, {
|
|
1183
1166
|
tag: "span",
|
|
1184
1167
|
size: "inherit",
|
|
1185
1168
|
className: "min-w-0 whitespace-normal break-words",
|
|
1186
1169
|
children: n.label
|
|
1187
1170
|
}) : n.label,
|
|
1188
1171
|
n.badge,
|
|
1189
|
-
!!
|
|
1172
|
+
!!a && I && /* @__PURE__ */ H("button", {
|
|
1190
1173
|
type: "button",
|
|
1191
|
-
onClick:
|
|
1192
|
-
"aria-label":
|
|
1193
|
-
className: i(
|
|
1194
|
-
children: [/* @__PURE__ */
|
|
1195
|
-
className:
|
|
1174
|
+
onClick: a,
|
|
1175
|
+
"aria-label": L.deleteValueLabel,
|
|
1176
|
+
className: i(y.target, y.focus, y.clear, "hover:text-destructive"),
|
|
1177
|
+
children: [/* @__PURE__ */ V(ye, {
|
|
1178
|
+
className: y.icon,
|
|
1196
1179
|
"aria-hidden": "true"
|
|
1197
|
-
}), /* @__PURE__ */
|
|
1180
|
+
}), /* @__PURE__ */ V(o, {
|
|
1198
1181
|
tag: "span",
|
|
1199
1182
|
size: "pxs",
|
|
1200
1183
|
className: "sr-only",
|
|
1201
|
-
children:
|
|
1184
|
+
children: L.deleteValueLabel
|
|
1202
1185
|
})]
|
|
1203
1186
|
})
|
|
1204
1187
|
]
|
|
@@ -1208,59 +1191,59 @@ function st({ optionGroups: e = [], surface: t = "card", collapsedOptionIds: o,
|
|
|
1208
1191
|
})
|
|
1209
1192
|
]
|
|
1210
1193
|
});
|
|
1211
|
-
return /* @__PURE__ */
|
|
1194
|
+
return /* @__PURE__ */ V("div", {
|
|
1212
1195
|
className: "product-options-matrix--item border-b border-border/70 last:border-b-0",
|
|
1213
|
-
children: /* @__PURE__ */
|
|
1196
|
+
children: /* @__PURE__ */ H("div", {
|
|
1214
1197
|
className: "grid min-w-0 grid-cols-[auto_minmax(0,1fr)] items-center gap-x-space-md gap-y-space-md p-surface @2xl/product-options-matrix:grid-cols-[auto_minmax(0,1fr)_auto]",
|
|
1215
1198
|
children: [
|
|
1216
|
-
|
|
1199
|
+
ee ? /* @__PURE__ */ H(s, {
|
|
1217
1200
|
type: "button",
|
|
1218
1201
|
size: "sm",
|
|
1219
1202
|
iconOnly: !0,
|
|
1220
1203
|
tone: "secondary",
|
|
1221
1204
|
buttonStyle: "ghost",
|
|
1222
|
-
onClick: () =>
|
|
1205
|
+
onClick: () => Ee(e),
|
|
1223
1206
|
"aria-expanded": !r,
|
|
1224
|
-
"aria-label": r ?
|
|
1207
|
+
"aria-label": r ? L.expandOptionLabel : L.collapseOptionLabel,
|
|
1225
1208
|
className: "product-options-matrix--collapse-trigger mt-space-2xs shrink-0 text-muted-foreground",
|
|
1226
|
-
children: [/* @__PURE__ */
|
|
1209
|
+
children: [/* @__PURE__ */ V(pe, {
|
|
1227
1210
|
className: i("size-icon-sm transition-transform", r && "-rotate-90"),
|
|
1228
1211
|
"aria-hidden": "true"
|
|
1229
|
-
}), /* @__PURE__ */
|
|
1212
|
+
}), /* @__PURE__ */ V(o, {
|
|
1230
1213
|
tag: "span",
|
|
1231
1214
|
size: "pxs",
|
|
1232
1215
|
className: "sr-only",
|
|
1233
|
-
children: r ?
|
|
1216
|
+
children: r ? L.expandOptionLabel : L.collapseOptionLabel
|
|
1234
1217
|
})]
|
|
1235
|
-
}) : /* @__PURE__ */
|
|
1218
|
+
}) : /* @__PURE__ */ V("span", {
|
|
1236
1219
|
className: "product-options-matrix--drag-handle flex size-icon-lg items-center justify-center text-muted-foreground",
|
|
1237
1220
|
"aria-hidden": "true",
|
|
1238
|
-
children: /* @__PURE__ */
|
|
1221
|
+
children: /* @__PURE__ */ V(ge, { className: "size-icon-sm" })
|
|
1239
1222
|
}),
|
|
1240
|
-
/* @__PURE__ */
|
|
1223
|
+
/* @__PURE__ */ V("div", {
|
|
1241
1224
|
className: "product-options-matrix--item-main min-w-0",
|
|
1242
|
-
children: c && !
|
|
1225
|
+
children: c && !I ? /* @__PURE__ */ V("button", {
|
|
1243
1226
|
type: "button",
|
|
1244
|
-
onClick: () =>
|
|
1245
|
-
"aria-label":
|
|
1227
|
+
onClick: () => Z(e),
|
|
1228
|
+
"aria-label": tt(L.editLabel, e),
|
|
1246
1229
|
className: "product-options-matrix--edit-summary box-border block w-full cursor-pointer whitespace-normal rounded-inner border-0 bg-transparent p-0 text-start font-sans text-foreground outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",
|
|
1247
1230
|
children: S
|
|
1248
1231
|
}) : S
|
|
1249
1232
|
}),
|
|
1250
|
-
(
|
|
1233
|
+
(te || !!g) && /* @__PURE__ */ H("div", {
|
|
1251
1234
|
className: "product-options-matrix--item-actions col-start-2 flex min-w-fit items-center gap-space-md justify-start @2xl/product-options-matrix:justify-end lg:col-start-auto",
|
|
1252
|
-
children: [!!
|
|
1235
|
+
children: [!!M && te && /* @__PURE__ */ H("div", {
|
|
1253
1236
|
className: "inline-flex items-center gap-space-sm",
|
|
1254
|
-
children: [/* @__PURE__ */
|
|
1237
|
+
children: [/* @__PURE__ */ V(o, {
|
|
1255
1238
|
tag: "span",
|
|
1256
1239
|
id: `product-option-${e.id}-variant-toggle-label`,
|
|
1257
1240
|
size: "pxs",
|
|
1258
1241
|
type: "secondary",
|
|
1259
1242
|
weight: "medium",
|
|
1260
|
-
children:
|
|
1261
|
-
}), /* @__PURE__ */
|
|
1243
|
+
children: L.useForVariantsLabel
|
|
1244
|
+
}), /* @__PURE__ */ V(w, {
|
|
1262
1245
|
checked: !!e.usedForVariants,
|
|
1263
|
-
onValueChange: (t) =>
|
|
1246
|
+
onValueChange: (t) => M(e, t),
|
|
1264
1247
|
"aria-labelledby": `product-option-${e.id}-variant-toggle-label`
|
|
1265
1248
|
})]
|
|
1266
1249
|
}), g]
|
|
@@ -1268,107 +1251,106 @@ function st({ optionGroups: e = [], surface: t = "card", collapsedOptionIds: o,
|
|
|
1268
1251
|
]
|
|
1269
1252
|
})
|
|
1270
1253
|
}, e.id);
|
|
1271
|
-
}), !!
|
|
1254
|
+
}), !!Ce && /* @__PURE__ */ V("div", {
|
|
1272
1255
|
className: "product-options-matrix--create-row border-t border-border/70 p-surface-xs",
|
|
1273
|
-
children: /* @__PURE__ */
|
|
1256
|
+
children: /* @__PURE__ */ V(s, {
|
|
1274
1257
|
type: "button",
|
|
1275
1258
|
tone: "secondary",
|
|
1276
1259
|
buttonStyle: "ghost",
|
|
1277
1260
|
onClick: g,
|
|
1278
|
-
icon:
|
|
1261
|
+
icon: _e,
|
|
1279
1262
|
size: "sm",
|
|
1280
1263
|
fullWidth: !0,
|
|
1281
1264
|
className: "justify-start text-foreground",
|
|
1282
|
-
children:
|
|
1265
|
+
children: L.addAnotherOptionLabel
|
|
1283
1266
|
})
|
|
1284
1267
|
})]
|
|
1285
|
-
}) : /* @__PURE__ */
|
|
1286
|
-
className: i(
|
|
1287
|
-
children:
|
|
1288
|
-
title:
|
|
1289
|
-
description:
|
|
1290
|
-
action: g && !
|
|
1268
|
+
}) : /* @__PURE__ */ V("div", {
|
|
1269
|
+
className: i(Se && "border-t border-border/70"),
|
|
1270
|
+
children: ae ?? /* @__PURE__ */ V($, {
|
|
1271
|
+
title: L.emptyTitle,
|
|
1272
|
+
description: L.emptyDescription,
|
|
1273
|
+
action: g && !Se ? /* @__PURE__ */ V(s, {
|
|
1274
|
+
tone: "primary",
|
|
1291
1275
|
type: "button",
|
|
1292
1276
|
onClick: g,
|
|
1293
|
-
icon:
|
|
1294
|
-
children:
|
|
1277
|
+
icon: G,
|
|
1278
|
+
children: L.createLabel
|
|
1295
1279
|
}) : void 0
|
|
1296
1280
|
})
|
|
1297
1281
|
})]
|
|
1298
1282
|
}),
|
|
1299
|
-
!!(S !== !1 &&
|
|
1300
|
-
...
|
|
1283
|
+
!!(S !== !1 && je) && /* @__PURE__ */ V(p, {
|
|
1284
|
+
...Ae.overlayProps,
|
|
1301
1285
|
destructive: !0,
|
|
1302
|
-
title:
|
|
1303
|
-
description: n(
|
|
1304
|
-
strings: { confirm:
|
|
1305
|
-
onConfirm: () =>
|
|
1286
|
+
title: L.confirmRemoveValuesTitle,
|
|
1287
|
+
description: n(L.confirmRemoveValuesDescription, { count: je.removed }),
|
|
1288
|
+
strings: { confirm: L.confirmRemoveValuesLabel },
|
|
1289
|
+
onConfirm: () => Q(je.option)
|
|
1306
1290
|
}),
|
|
1307
|
-
!!(S !== !1 &&
|
|
1308
|
-
...
|
|
1291
|
+
!!(S !== !1 && v) && /* @__PURE__ */ V(p, {
|
|
1292
|
+
...Fe.overlayProps,
|
|
1309
1293
|
destructive: !0,
|
|
1310
|
-
title:
|
|
1311
|
-
description:
|
|
1312
|
-
strings: { confirm:
|
|
1294
|
+
title: L.confirmDeleteOptionTitle,
|
|
1295
|
+
description: L.confirmDeleteOptionDescription,
|
|
1296
|
+
strings: { confirm: L.deleteLabel },
|
|
1313
1297
|
onConfirm: () => {
|
|
1314
|
-
|
|
1298
|
+
Ie && Pe(Ie);
|
|
1315
1299
|
}
|
|
1316
1300
|
})
|
|
1317
1301
|
]
|
|
1318
1302
|
});
|
|
1319
|
-
return t === "embedded" ? /* @__PURE__ */
|
|
1320
|
-
"aria-label":
|
|
1321
|
-
className: i("product-options-matrix--component @container/product-options-matrix min-w-0",
|
|
1322
|
-
children:
|
|
1323
|
-
}) : /* @__PURE__ */
|
|
1324
|
-
title:
|
|
1325
|
-
description:
|
|
1326
|
-
actions:
|
|
1327
|
-
headerAction:
|
|
1328
|
-
headerEnd:
|
|
1329
|
-
footerSlot:
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
children: Ve
|
|
1303
|
+
return t === "embedded" ? /* @__PURE__ */ V("section", {
|
|
1304
|
+
"aria-label": L.title,
|
|
1305
|
+
className: i("product-options-matrix--component @container/product-options-matrix min-w-0", oe),
|
|
1306
|
+
children: He
|
|
1307
|
+
}) : /* @__PURE__ */ V(E, {
|
|
1308
|
+
title: L.title,
|
|
1309
|
+
description: L.description,
|
|
1310
|
+
actions: ne,
|
|
1311
|
+
headerAction: Be,
|
|
1312
|
+
headerEnd: re,
|
|
1313
|
+
footerSlot: ie,
|
|
1314
|
+
className: i("product-options-matrix--component @container/product-options-matrix w-full", oe),
|
|
1315
|
+
children: He
|
|
1333
1316
|
});
|
|
1334
1317
|
}
|
|
1335
|
-
|
|
1318
|
+
rt.displayName = "ProductOptionsMatrix";
|
|
1336
1319
|
//#endregion
|
|
1337
1320
|
//#region src/components/features/products/components/product-options-summary.tsx
|
|
1338
|
-
function
|
|
1339
|
-
let g = r(
|
|
1321
|
+
function it({ options: e = [], onManageOptions: t, onCreateOption: n, onSelectOption: a, onEditOption: o, onDeleteOption: c, renderOptionActions: l, actions: u, footerSlot: d, renderOption: f, empty: p, className: m, strings: h }) {
|
|
1322
|
+
let g = r(Ce, h), _ = !!(a || o || c || l), v = [...u ?? [], ...n && t ? [{
|
|
1340
1323
|
id: "manage-options",
|
|
1341
1324
|
label: g.manageLabel,
|
|
1342
|
-
icon: /* @__PURE__ */
|
|
1325
|
+
icon: /* @__PURE__ */ V(K, { className: "size-icon-md" }),
|
|
1343
1326
|
onClick: t
|
|
1344
|
-
}] : []], y = n || t ? /* @__PURE__ */
|
|
1327
|
+
}] : []], y = n || t ? /* @__PURE__ */ V(s, {
|
|
1345
1328
|
type: "button",
|
|
1346
1329
|
tone: "secondary",
|
|
1347
1330
|
buttonStyle: "ghost",
|
|
1348
1331
|
onClick: n ?? t,
|
|
1349
|
-
icon: n ?
|
|
1332
|
+
icon: n ? G : void 0,
|
|
1350
1333
|
children: n ? g.createLabel : g.manageLabel
|
|
1351
1334
|
}) : void 0;
|
|
1352
|
-
return /* @__PURE__ */
|
|
1353
|
-
icon: /* @__PURE__ */ R(X, { className: "size-icon" }),
|
|
1335
|
+
return /* @__PURE__ */ V(E, {
|
|
1354
1336
|
title: g.title,
|
|
1355
1337
|
description: g.description,
|
|
1356
1338
|
actions: v.length > 0 ? v : void 0,
|
|
1357
1339
|
headerAction: y,
|
|
1358
1340
|
footerSlot: d,
|
|
1359
|
-
contentClassName: "mt-1",
|
|
1360
1341
|
className: i("product-options-summary--component w-full", m),
|
|
1361
|
-
children: e.length === 0 ? p ?? /* @__PURE__ */
|
|
1342
|
+
children: e.length === 0 ? p ?? /* @__PURE__ */ V($, {
|
|
1362
1343
|
title: g.emptyTitle,
|
|
1363
1344
|
description: g.emptyDescription,
|
|
1364
|
-
action: n ? /* @__PURE__ */
|
|
1345
|
+
action: n ? /* @__PURE__ */ V(s, {
|
|
1346
|
+
tone: "primary",
|
|
1365
1347
|
type: "button",
|
|
1366
1348
|
onClick: n,
|
|
1367
|
-
icon:
|
|
1349
|
+
icon: G,
|
|
1368
1350
|
children: g.createLabel
|
|
1369
1351
|
}) : void 0
|
|
1370
|
-
}) : /* @__PURE__ */
|
|
1371
|
-
let n = _ ? /* @__PURE__ */
|
|
1352
|
+
}) : /* @__PURE__ */ V(M, { children: e.map((e, t) => (() => {
|
|
1353
|
+
let n = _ ? /* @__PURE__ */ V(Ze, {
|
|
1372
1354
|
option: e,
|
|
1373
1355
|
index: t,
|
|
1374
1356
|
onSelectOption: a,
|
|
@@ -1383,55 +1365,54 @@ function ct({ options: e = [], onManageOptions: t, onCreateOption: n, onSelectOp
|
|
|
1383
1365
|
actionsLabel: g.actionsLabel
|
|
1384
1366
|
}
|
|
1385
1367
|
}) : void 0;
|
|
1386
|
-
return f ? /* @__PURE__ */
|
|
1368
|
+
return f ? /* @__PURE__ */ V("div", { children: f(e, t) }, e.id) : /* @__PURE__ */ V(Je, {
|
|
1387
1369
|
item: e,
|
|
1388
1370
|
actions: n
|
|
1389
1371
|
}, e.id);
|
|
1390
1372
|
})()) })
|
|
1391
1373
|
});
|
|
1392
1374
|
}
|
|
1393
|
-
|
|
1375
|
+
it.displayName = "ProductOptionsSummary";
|
|
1394
1376
|
//#endregion
|
|
1395
1377
|
//#region src/components/features/products/components/product-policies-card.tsx
|
|
1396
|
-
function
|
|
1397
|
-
let h = r(
|
|
1378
|
+
function at({ policies: e = [], onCreatePolicy: t, onSelectPolicy: n, onEditPolicy: a, onDeletePolicy: o, renderPolicyActions: c, actions: l, footerSlot: u, renderPolicy: d, empty: f, className: p, strings: m }) {
|
|
1379
|
+
let h = r(X, m), g = t ? /* @__PURE__ */ V(s, {
|
|
1398
1380
|
type: "button",
|
|
1399
1381
|
tone: "secondary",
|
|
1400
1382
|
buttonStyle: "ghost",
|
|
1401
1383
|
onClick: t,
|
|
1402
|
-
icon:
|
|
1384
|
+
icon: G,
|
|
1403
1385
|
children: h.createLabel
|
|
1404
1386
|
}) : void 0;
|
|
1405
|
-
return /* @__PURE__ */
|
|
1406
|
-
icon: /* @__PURE__ */ R(Ce, { className: "size-icon" }),
|
|
1387
|
+
return /* @__PURE__ */ V(E, {
|
|
1407
1388
|
title: h.title,
|
|
1408
1389
|
description: h.description,
|
|
1409
1390
|
actions: l,
|
|
1410
1391
|
headerAction: g,
|
|
1411
1392
|
footerSlot: u,
|
|
1412
|
-
contentClassName: "mt-1",
|
|
1413
1393
|
className: i("product-policies-card--component w-full", p),
|
|
1414
|
-
children: e.length === 0 ? f ?? /* @__PURE__ */
|
|
1394
|
+
children: e.length === 0 ? f ?? /* @__PURE__ */ V($, {
|
|
1415
1395
|
title: h.emptyTitle,
|
|
1416
1396
|
description: h.emptyDescription,
|
|
1417
|
-
action: t ? /* @__PURE__ */
|
|
1397
|
+
action: t ? /* @__PURE__ */ V(s, {
|
|
1398
|
+
tone: "primary",
|
|
1418
1399
|
type: "button",
|
|
1419
1400
|
onClick: t,
|
|
1420
|
-
icon:
|
|
1401
|
+
icon: G,
|
|
1421
1402
|
children: h.createLabel
|
|
1422
1403
|
}) : void 0
|
|
1423
|
-
}) : /* @__PURE__ */
|
|
1404
|
+
}) : /* @__PURE__ */ V(M, { children: e.map((e, t) => (() => {
|
|
1424
1405
|
let r = n ? () => n(e) : void 0, i = a ? () => a(e) : void 0, s = o ? () => o(e) : void 0, l = [...i ? [{
|
|
1425
1406
|
id: "edit",
|
|
1426
1407
|
label: h.editLabel,
|
|
1427
|
-
icon: /* @__PURE__ */
|
|
1408
|
+
icon: /* @__PURE__ */ V(W, { className: "size-icon-md" }),
|
|
1428
1409
|
onClick: () => i(),
|
|
1429
1410
|
tone: "secondary",
|
|
1430
1411
|
buttonStyle: "ghost"
|
|
1431
1412
|
}] : [], ...s ? [{
|
|
1432
1413
|
id: "delete",
|
|
1433
1414
|
label: h.deleteLabel,
|
|
1434
|
-
icon: /* @__PURE__ */
|
|
1415
|
+
icon: /* @__PURE__ */ V(q, { className: "size-icon-md" }),
|
|
1435
1416
|
onClick: () => s(),
|
|
1436
1417
|
tone: "destructive"
|
|
1437
1418
|
}] : []], u = c ? c(e, {
|
|
@@ -1439,12 +1420,12 @@ function lt({ policies: e = [], onCreatePolicy: t, onSelectPolicy: n, onEditPoli
|
|
|
1439
1420
|
onSelect: r,
|
|
1440
1421
|
onEdit: i,
|
|
1441
1422
|
onDelete: s
|
|
1442
|
-
}) : /* @__PURE__ */
|
|
1423
|
+
}) : /* @__PURE__ */ V(ze, {
|
|
1443
1424
|
item: e,
|
|
1444
1425
|
actions: l,
|
|
1445
1426
|
menuLabel: h.actionsLabel
|
|
1446
1427
|
});
|
|
1447
|
-
return d ? /* @__PURE__ */
|
|
1428
|
+
return d ? /* @__PURE__ */ V("div", { children: d(e, t) }, e.id) : /* @__PURE__ */ V(Je, {
|
|
1448
1429
|
item: e,
|
|
1449
1430
|
actionLabel: h.viewLabel,
|
|
1450
1431
|
onSelect: r,
|
|
@@ -1453,71 +1434,69 @@ function lt({ policies: e = [], onCreatePolicy: t, onSelectPolicy: n, onEditPoli
|
|
|
1453
1434
|
})()) })
|
|
1454
1435
|
});
|
|
1455
1436
|
}
|
|
1456
|
-
|
|
1437
|
+
at.displayName = "ProductPoliciesCard";
|
|
1457
1438
|
//#endregion
|
|
1458
1439
|
//#region src/components/features/products/components/product-quote-preview-card.tsx
|
|
1459
|
-
function
|
|
1460
|
-
let
|
|
1440
|
+
function ot({ lines: e = [], subtotal: t, tax: n, discount: a, total: c, onOpenQuote: u, onCreateLine: d, onSelectLine: f, onEditLine: p, onDeleteLine: h, renderLineActions: g, actions: _, footerSlot: y, empty: b, className: x, strings: S }) {
|
|
1441
|
+
let C = r(Ee, S), w = t !== void 0 || n !== void 0 || a !== void 0, T = d || u ? /* @__PURE__ */ H("div", {
|
|
1461
1442
|
className: "flex items-center gap-space-md",
|
|
1462
|
-
children: [!!d && /* @__PURE__ */
|
|
1443
|
+
children: [!!d && /* @__PURE__ */ V(s, {
|
|
1463
1444
|
type: "button",
|
|
1464
1445
|
tone: "secondary",
|
|
1465
1446
|
buttonStyle: "ghost",
|
|
1466
1447
|
onClick: d,
|
|
1467
|
-
icon:
|
|
1468
|
-
children:
|
|
1469
|
-
}), !!u && /* @__PURE__ */
|
|
1448
|
+
icon: G,
|
|
1449
|
+
children: C.createLineLabel
|
|
1450
|
+
}), !!u && /* @__PURE__ */ V(s, {
|
|
1470
1451
|
type: "button",
|
|
1471
1452
|
tone: "secondary",
|
|
1472
1453
|
buttonStyle: "ghost",
|
|
1473
1454
|
onClick: u,
|
|
1474
|
-
|
|
1475
|
-
iconPosition: "right",
|
|
1476
|
-
children: S.actionLabel
|
|
1455
|
+
children: C.actionLabel
|
|
1477
1456
|
})]
|
|
1478
1457
|
}) : void 0;
|
|
1479
|
-
return /* @__PURE__ */
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
description: S.description,
|
|
1458
|
+
return /* @__PURE__ */ V(E, {
|
|
1459
|
+
title: C.title,
|
|
1460
|
+
description: C.description,
|
|
1483
1461
|
actions: _,
|
|
1484
|
-
headerAction:
|
|
1485
|
-
footerSlot:
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1462
|
+
headerAction: T,
|
|
1463
|
+
footerSlot: y,
|
|
1464
|
+
className: i("product-quote-preview-card--component w-full", x),
|
|
1465
|
+
children: e.length === 0 ? b ?? /* @__PURE__ */ V($, {
|
|
1466
|
+
title: C.emptyTitle,
|
|
1467
|
+
description: C.emptyDescription,
|
|
1468
|
+
action: d ? /* @__PURE__ */ V(s, {
|
|
1469
|
+
tone: "primary",
|
|
1492
1470
|
type: "button",
|
|
1493
1471
|
onClick: d,
|
|
1494
|
-
icon:
|
|
1495
|
-
children:
|
|
1472
|
+
icon: G,
|
|
1473
|
+
children: C.createLineLabel
|
|
1496
1474
|
}) : void 0
|
|
1497
|
-
}) : /* @__PURE__ */
|
|
1498
|
-
gap: "
|
|
1499
|
-
|
|
1500
|
-
|
|
1475
|
+
}) : /* @__PURE__ */ H(l, {
|
|
1476
|
+
gap: "2xl",
|
|
1477
|
+
className: "product-quote-preview-card--body",
|
|
1478
|
+
children: [/* @__PURE__ */ V(M, { children: e.map((e, t) => {
|
|
1479
|
+
let n = f ? () => f(e) : void 0, r = p ? () => p(e) : void 0, i = h ? () => h(e) : void 0, a = [
|
|
1501
1480
|
...n ? [{
|
|
1502
1481
|
id: "open",
|
|
1503
|
-
label:
|
|
1504
|
-
icon: /* @__PURE__ */
|
|
1482
|
+
label: C.viewLineLabel,
|
|
1483
|
+
icon: /* @__PURE__ */ V(he, { className: "size-icon-md" }),
|
|
1505
1484
|
onClick: () => n(),
|
|
1506
1485
|
tone: "secondary",
|
|
1507
1486
|
buttonStyle: "ghost"
|
|
1508
1487
|
}] : [],
|
|
1509
1488
|
...r ? [{
|
|
1510
1489
|
id: "edit",
|
|
1511
|
-
label:
|
|
1512
|
-
icon: /* @__PURE__ */
|
|
1490
|
+
label: C.editLineLabel,
|
|
1491
|
+
icon: /* @__PURE__ */ V(W, { className: "size-icon-md" }),
|
|
1513
1492
|
onClick: () => r(),
|
|
1514
1493
|
tone: "secondary",
|
|
1515
1494
|
buttonStyle: "ghost"
|
|
1516
1495
|
}] : [],
|
|
1517
1496
|
...i ? [{
|
|
1518
1497
|
id: "delete",
|
|
1519
|
-
label:
|
|
1520
|
-
icon: /* @__PURE__ */
|
|
1498
|
+
label: C.deleteLineLabel,
|
|
1499
|
+
icon: /* @__PURE__ */ V(q, { className: "size-icon-md" }),
|
|
1521
1500
|
onClick: () => i(),
|
|
1522
1501
|
tone: "destructive"
|
|
1523
1502
|
}] : []
|
|
@@ -1526,193 +1505,190 @@ function ut({ lines: e = [], subtotal: t, tax: n, discount: o, total: c, onOpenQ
|
|
|
1526
1505
|
onSelect: n,
|
|
1527
1506
|
onEdit: r,
|
|
1528
1507
|
onDelete: i
|
|
1529
|
-
}) : /* @__PURE__ */
|
|
1508
|
+
}) : /* @__PURE__ */ V(ze, {
|
|
1530
1509
|
item: e,
|
|
1531
1510
|
actions: a,
|
|
1532
|
-
menuLabel:
|
|
1511
|
+
menuLabel: C.lineActionsLabel
|
|
1533
1512
|
});
|
|
1534
|
-
return /* @__PURE__ */
|
|
1535
|
-
|
|
1536
|
-
|
|
1537
|
-
|
|
1538
|
-
/* @__PURE__ */
|
|
1539
|
-
!!e.
|
|
1540
|
-
|
|
1541
|
-
] }), /* @__PURE__ */ z(D, { children: [/* @__PURE__ */ R(p, {
|
|
1542
|
-
weight: "semibold",
|
|
1513
|
+
return /* @__PURE__ */ H(P, {
|
|
1514
|
+
className: "product-quote-preview-card--line",
|
|
1515
|
+
children: [/* @__PURE__ */ H(N, { children: [
|
|
1516
|
+
/* @__PURE__ */ V(F, { children: e.label }),
|
|
1517
|
+
!!e.description && /* @__PURE__ */ V(A, { children: e.description }),
|
|
1518
|
+
!!e.quantity && /* @__PURE__ */ V(A, { children: e.quantity })
|
|
1519
|
+
] }), /* @__PURE__ */ H(j, { children: [/* @__PURE__ */ V(m, {
|
|
1543
1520
|
className: "tabular-nums",
|
|
1544
1521
|
children: e.amount
|
|
1545
1522
|
}), o] })]
|
|
1546
1523
|
}, e.id);
|
|
1547
|
-
}) }), /* @__PURE__ */
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
label: S.taxLabel,
|
|
1559
|
-
value: n,
|
|
1560
|
-
mono: !0
|
|
1561
|
-
}),
|
|
1562
|
-
o !== void 0 && /* @__PURE__ */ R(re, {
|
|
1563
|
-
label: S.discountLabel,
|
|
1564
|
-
value: o,
|
|
1565
|
-
mono: !0,
|
|
1566
|
-
valueClassName: "text-success"
|
|
1567
|
-
}),
|
|
1568
|
-
/* @__PURE__ */ R(re, {
|
|
1569
|
-
label: /* @__PURE__ */ R(a, {
|
|
1570
|
-
tag: "span",
|
|
1571
|
-
weight: "semibold",
|
|
1572
|
-
lineHeight: "tight",
|
|
1573
|
-
children: S.totalLabel
|
|
1524
|
+
}) }), /* @__PURE__ */ H(l, {
|
|
1525
|
+
gap: "lg",
|
|
1526
|
+
className: "product-quote-preview-card--totals",
|
|
1527
|
+
children: [
|
|
1528
|
+
!!w && /* @__PURE__ */ H(l, {
|
|
1529
|
+
gap: "sm",
|
|
1530
|
+
children: [
|
|
1531
|
+
t !== void 0 && /* @__PURE__ */ V(ae, {
|
|
1532
|
+
label: C.subtotalLabel,
|
|
1533
|
+
value: t,
|
|
1534
|
+
valueClassName: "tabular-nums"
|
|
1574
1535
|
}),
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1536
|
+
n !== void 0 && /* @__PURE__ */ V(ae, {
|
|
1537
|
+
label: C.taxLabel,
|
|
1538
|
+
value: n,
|
|
1539
|
+
valueClassName: "tabular-nums"
|
|
1540
|
+
}),
|
|
1541
|
+
a !== void 0 && /* @__PURE__ */ V(ae, {
|
|
1542
|
+
label: C.discountLabel,
|
|
1543
|
+
value: a,
|
|
1544
|
+
valueClassName: "tabular-nums text-success"
|
|
1545
|
+
})
|
|
1546
|
+
]
|
|
1547
|
+
}),
|
|
1548
|
+
!!w && /* @__PURE__ */ V(v, {}),
|
|
1549
|
+
/* @__PURE__ */ V(ae, {
|
|
1550
|
+
label: /* @__PURE__ */ V(o, {
|
|
1551
|
+
tag: "span",
|
|
1552
|
+
weight: "semibold",
|
|
1553
|
+
lineHeight: "tight",
|
|
1554
|
+
children: C.totalLabel
|
|
1555
|
+
}),
|
|
1556
|
+
value: c ?? "-",
|
|
1557
|
+
valueClassName: "font-semibold tabular-nums"
|
|
1558
|
+
})
|
|
1559
|
+
]
|
|
1581
1560
|
})]
|
|
1582
1561
|
})
|
|
1583
1562
|
});
|
|
1584
1563
|
}
|
|
1585
|
-
|
|
1564
|
+
ot.displayName = "ProductQuotePreviewCard";
|
|
1586
1565
|
//#endregion
|
|
1587
1566
|
//#region src/components/features/products/components/product-readiness-card.tsx
|
|
1588
|
-
function
|
|
1589
|
-
let S = r(
|
|
1567
|
+
function st({ items: e = [], score: t, scoreLabel: n, summary: a, onCreateReadinessItem: c, onSelectReadinessItem: u, onEditReadinessItem: f, onDeleteReadinessItem: p, renderReadinessItemActions: m, actions: h, footerSlot: _, renderItem: v, empty: y, className: b, strings: x }) {
|
|
1568
|
+
let S = r(J, x), C = t === void 0 ? void 0 : Ie(t), w = c ? /* @__PURE__ */ V(s, {
|
|
1590
1569
|
type: "button",
|
|
1591
1570
|
tone: "secondary",
|
|
1592
1571
|
buttonStyle: "ghost",
|
|
1593
1572
|
onClick: c,
|
|
1594
|
-
icon:
|
|
1573
|
+
icon: G,
|
|
1595
1574
|
children: S.createLabel
|
|
1596
1575
|
}) : void 0;
|
|
1597
|
-
return /* @__PURE__ */
|
|
1598
|
-
icon: /* @__PURE__ */ R(he, { className: "size-icon" }),
|
|
1576
|
+
return /* @__PURE__ */ H(E, {
|
|
1599
1577
|
title: S.title,
|
|
1600
1578
|
description: S.description,
|
|
1601
|
-
actions:
|
|
1602
|
-
headerAction:
|
|
1579
|
+
actions: h,
|
|
1580
|
+
headerAction: w,
|
|
1603
1581
|
footerSlot: _,
|
|
1604
|
-
contentGap: "
|
|
1582
|
+
contentGap: "2xl",
|
|
1605
1583
|
className: i("product-readiness-card--component w-full", b),
|
|
1606
|
-
children: [
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1584
|
+
children: [(C !== void 0 || !!a) && /* @__PURE__ */ H(l, {
|
|
1585
|
+
gap: "lg",
|
|
1586
|
+
className: "product-readiness-card--summary",
|
|
1587
|
+
children: [C !== void 0 && /* @__PURE__ */ H(l, {
|
|
1588
|
+
gap: "sm",
|
|
1589
|
+
className: "product-readiness-card--score",
|
|
1590
|
+
children: [/* @__PURE__ */ H(l, {
|
|
1610
1591
|
direction: "horizontal",
|
|
1611
|
-
align: "center",
|
|
1612
1592
|
justify: "between",
|
|
1613
1593
|
gap: "lg",
|
|
1614
|
-
|
|
1615
|
-
children: [/* @__PURE__ */ R(a, {
|
|
1594
|
+
children: [/* @__PURE__ */ V(o, {
|
|
1616
1595
|
size: "xs",
|
|
1617
1596
|
type: "secondary",
|
|
1618
1597
|
children: n ?? S.scoreLabel
|
|
1619
|
-
}), /* @__PURE__ */
|
|
1620
|
-
value:
|
|
1598
|
+
}), /* @__PURE__ */ V(g, {
|
|
1599
|
+
value: C,
|
|
1621
1600
|
scaled: !0,
|
|
1622
1601
|
size: "xs",
|
|
1623
1602
|
weight: "semibold"
|
|
1624
1603
|
})]
|
|
1625
|
-
}), /* @__PURE__ */
|
|
1626
|
-
value:
|
|
1604
|
+
}), /* @__PURE__ */ V(d, {
|
|
1605
|
+
value: C,
|
|
1627
1606
|
"aria-label": typeof n == "string" ? n : S.progressLabel,
|
|
1628
|
-
"aria-valuetext": `${
|
|
1607
|
+
"aria-valuetext": `${C}%`,
|
|
1629
1608
|
className: "h-1.5"
|
|
1630
1609
|
})]
|
|
1631
|
-
}),
|
|
1632
|
-
!!o && /* @__PURE__ */ R(a, {
|
|
1610
|
+
}), !!a && /* @__PURE__ */ V(o, {
|
|
1633
1611
|
type: "secondary",
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
|
|
1653
|
-
|
|
1654
|
-
|
|
1655
|
-
|
|
1656
|
-
|
|
1657
|
-
|
|
1658
|
-
|
|
1659
|
-
|
|
1660
|
-
|
|
1661
|
-
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1672
|
-
|
|
1673
|
-
|
|
1674
|
-
|
|
1675
|
-
|
|
1676
|
-
|
|
1677
|
-
]
|
|
1612
|
+
children: a
|
|
1613
|
+
})]
|
|
1614
|
+
}), e.length === 0 ? y ?? /* @__PURE__ */ V($, {
|
|
1615
|
+
title: S.emptyTitle,
|
|
1616
|
+
description: S.emptyDescription,
|
|
1617
|
+
action: c ? /* @__PURE__ */ V(s, {
|
|
1618
|
+
tone: "primary",
|
|
1619
|
+
type: "button",
|
|
1620
|
+
onClick: c,
|
|
1621
|
+
icon: G,
|
|
1622
|
+
children: S.createLabel
|
|
1623
|
+
}) : void 0
|
|
1624
|
+
}) : /* @__PURE__ */ V(M, { children: e.map((e, t) => {
|
|
1625
|
+
let n = u ? () => u(e) : void 0, r = f ? () => f(e) : void 0, i = p ? () => p(e) : void 0, a = [...r ? [{
|
|
1626
|
+
id: "edit",
|
|
1627
|
+
label: S.editLabel,
|
|
1628
|
+
icon: /* @__PURE__ */ V(W, { className: "size-icon-md" }),
|
|
1629
|
+
onClick: () => r(),
|
|
1630
|
+
tone: "secondary",
|
|
1631
|
+
buttonStyle: "ghost"
|
|
1632
|
+
}] : [], ...i ? [{
|
|
1633
|
+
id: "delete",
|
|
1634
|
+
label: S.deleteLabel,
|
|
1635
|
+
icon: /* @__PURE__ */ V(q, { className: "size-icon-md" }),
|
|
1636
|
+
onClick: () => i(),
|
|
1637
|
+
tone: "destructive"
|
|
1638
|
+
}] : []], o = m ? m(e, {
|
|
1639
|
+
index: t,
|
|
1640
|
+
onSelect: n,
|
|
1641
|
+
onEdit: r,
|
|
1642
|
+
onDelete: i
|
|
1643
|
+
}) : /* @__PURE__ */ V(ze, {
|
|
1644
|
+
item: e,
|
|
1645
|
+
actions: a,
|
|
1646
|
+
menuLabel: S.actionsLabel
|
|
1647
|
+
});
|
|
1648
|
+
return v ? /* @__PURE__ */ V("div", { children: v(e, t) }, e.id) : /* @__PURE__ */ V(Ke, {
|
|
1649
|
+
item: e,
|
|
1650
|
+
actionFallback: S.actionLabel,
|
|
1651
|
+
onSelect: n,
|
|
1652
|
+
actions: o
|
|
1653
|
+
}, e.id);
|
|
1654
|
+
}) })]
|
|
1678
1655
|
});
|
|
1679
1656
|
}
|
|
1680
|
-
|
|
1657
|
+
st.displayName = "ProductReadinessCard";
|
|
1681
1658
|
//#endregion
|
|
1682
1659
|
//#region src/components/features/products/components/product-structure-card.tsx
|
|
1683
|
-
function
|
|
1684
|
-
let m = r(
|
|
1660
|
+
function ct({ metrics: e = [], onCreateMetric: t, onSelectMetric: n, onEditMetric: a, onDeleteMetric: o, renderMetricActions: c, actions: l, footerSlot: u, empty: d, className: f, strings: p }) {
|
|
1661
|
+
let m = r(Y, p), h = t ? /* @__PURE__ */ V(s, {
|
|
1685
1662
|
type: "button",
|
|
1686
1663
|
tone: "secondary",
|
|
1687
1664
|
buttonStyle: "ghost",
|
|
1688
1665
|
onClick: t,
|
|
1689
|
-
icon:
|
|
1666
|
+
icon: G,
|
|
1690
1667
|
children: m.createLabel
|
|
1691
1668
|
}) : void 0;
|
|
1692
|
-
return /* @__PURE__ */
|
|
1693
|
-
icon: /* @__PURE__ */ R(_e, { className: "size-icon" }),
|
|
1669
|
+
return /* @__PURE__ */ V(E, {
|
|
1694
1670
|
title: m.title,
|
|
1695
1671
|
description: m.description,
|
|
1696
1672
|
actions: l,
|
|
1697
1673
|
headerAction: h,
|
|
1698
1674
|
footerSlot: u,
|
|
1699
|
-
contentClassName: "mt-1",
|
|
1700
1675
|
className: i("product-structure-card--component w-full", f),
|
|
1701
|
-
children: e.length === 0 ? d ?? /* @__PURE__ */
|
|
1676
|
+
children: e.length === 0 ? d ?? /* @__PURE__ */ V($, {
|
|
1702
1677
|
title: m.emptyTitle,
|
|
1703
1678
|
description: m.emptyDescription,
|
|
1704
|
-
action: t ? /* @__PURE__ */
|
|
1679
|
+
action: t ? /* @__PURE__ */ V(s, {
|
|
1680
|
+
tone: "primary",
|
|
1705
1681
|
type: "button",
|
|
1706
1682
|
onClick: t,
|
|
1707
|
-
icon:
|
|
1683
|
+
icon: G,
|
|
1708
1684
|
children: m.createLabel
|
|
1709
1685
|
}) : void 0
|
|
1710
|
-
}) : /* @__PURE__ */
|
|
1686
|
+
}) : /* @__PURE__ */ V(M, { children: e.map((e, t) => {
|
|
1711
1687
|
let r = n ? () => n(e) : void 0, i = a ? () => a(e) : void 0, s = o ? () => o(e) : void 0, l = [
|
|
1712
1688
|
...r ? [{
|
|
1713
1689
|
id: "open",
|
|
1714
1690
|
label: m.viewLabel,
|
|
1715
|
-
icon: /* @__PURE__ */
|
|
1691
|
+
icon: /* @__PURE__ */ V(he, { className: "size-icon-md" }),
|
|
1716
1692
|
onClick: () => r(),
|
|
1717
1693
|
tone: "secondary",
|
|
1718
1694
|
buttonStyle: "ghost"
|
|
@@ -1720,7 +1696,7 @@ function ft({ metrics: e = [], onCreateMetric: t, onSelectMetric: n, onEditMetri
|
|
|
1720
1696
|
...i ? [{
|
|
1721
1697
|
id: "edit",
|
|
1722
1698
|
label: m.editLabel,
|
|
1723
|
-
icon: /* @__PURE__ */
|
|
1699
|
+
icon: /* @__PURE__ */ V(W, { className: "size-icon-md" }),
|
|
1724
1700
|
onClick: () => i(),
|
|
1725
1701
|
tone: "secondary",
|
|
1726
1702
|
buttonStyle: "ghost"
|
|
@@ -1728,7 +1704,7 @@ function ft({ metrics: e = [], onCreateMetric: t, onSelectMetric: n, onEditMetri
|
|
|
1728
1704
|
...s ? [{
|
|
1729
1705
|
id: "delete",
|
|
1730
1706
|
label: m.deleteLabel,
|
|
1731
|
-
icon: /* @__PURE__ */
|
|
1707
|
+
icon: /* @__PURE__ */ V(q, { className: "size-icon-md" }),
|
|
1732
1708
|
onClick: () => s(),
|
|
1733
1709
|
tone: "destructive"
|
|
1734
1710
|
}] : []
|
|
@@ -1737,54 +1713,53 @@ function ft({ metrics: e = [], onCreateMetric: t, onSelectMetric: n, onEditMetri
|
|
|
1737
1713
|
onSelect: r,
|
|
1738
1714
|
onEdit: i,
|
|
1739
1715
|
onDelete: s
|
|
1740
|
-
}) : /* @__PURE__ */
|
|
1716
|
+
}) : /* @__PURE__ */ V(ze, {
|
|
1741
1717
|
item: e,
|
|
1742
1718
|
actions: l,
|
|
1743
1719
|
menuLabel: m.actionsLabel
|
|
1744
1720
|
});
|
|
1745
|
-
return /* @__PURE__ */
|
|
1721
|
+
return /* @__PURE__ */ V(Ge, {
|
|
1746
1722
|
metric: e,
|
|
1747
1723
|
actions: u
|
|
1748
1724
|
}, e.id);
|
|
1749
1725
|
}) })
|
|
1750
1726
|
});
|
|
1751
1727
|
}
|
|
1752
|
-
|
|
1728
|
+
ct.displayName = "ProductStructureCard";
|
|
1753
1729
|
//#endregion
|
|
1754
1730
|
//#region src/components/features/products/components/product-variants-table.tsx
|
|
1755
|
-
function
|
|
1756
|
-
return /* @__PURE__ */
|
|
1731
|
+
function lt({ variant: e, channelsLabel: t }) {
|
|
1732
|
+
return /* @__PURE__ */ H(l, {
|
|
1733
|
+
gap: "xs",
|
|
1757
1734
|
className: "product-variants-table--variant-cell min-w-0",
|
|
1758
|
-
children: [/* @__PURE__ */
|
|
1735
|
+
children: [/* @__PURE__ */ H(l, {
|
|
1759
1736
|
gap: "dense",
|
|
1760
|
-
children: [/* @__PURE__ */
|
|
1737
|
+
children: [/* @__PURE__ */ H(l, {
|
|
1761
1738
|
direction: "horizontal",
|
|
1762
1739
|
gap: "sm",
|
|
1763
|
-
children: [/* @__PURE__ */
|
|
1740
|
+
children: [/* @__PURE__ */ V(o, {
|
|
1764
1741
|
weight: "semibold",
|
|
1765
1742
|
className: "truncate",
|
|
1766
1743
|
children: e.name
|
|
1767
|
-
}), !!e.status && /* @__PURE__ */
|
|
1744
|
+
}), !!e.status && /* @__PURE__ */ V(_, {
|
|
1768
1745
|
tone: e.statusTone ?? "secondary",
|
|
1769
1746
|
children: e.status
|
|
1770
1747
|
})]
|
|
1771
|
-
}), !!e.description && /* @__PURE__ */
|
|
1748
|
+
}), !!e.description && /* @__PURE__ */ V(o, {
|
|
1772
1749
|
size: "xs",
|
|
1773
1750
|
type: "secondary",
|
|
1774
1751
|
children: e.description
|
|
1775
1752
|
})]
|
|
1776
|
-
}), !!(e.options?.length || e.channels) && /* @__PURE__ */
|
|
1753
|
+
}), !!(e.options?.length || e.channels) && /* @__PURE__ */ H(l, {
|
|
1777
1754
|
direction: "horizontal",
|
|
1778
1755
|
gap: "xs",
|
|
1779
|
-
|
|
1780
|
-
children: [e.options?.map((e, t) => /* @__PURE__ */ R(g, {
|
|
1756
|
+
children: [e.options?.map((e, t) => /* @__PURE__ */ V(_, {
|
|
1781
1757
|
tone: "secondary",
|
|
1782
1758
|
children: e
|
|
1783
|
-
}, t)), !!e.channels && /* @__PURE__ */
|
|
1759
|
+
}, t)), !!e.channels && /* @__PURE__ */ H(o, {
|
|
1784
1760
|
tag: "span",
|
|
1785
1761
|
size: "xs",
|
|
1786
1762
|
type: "secondary",
|
|
1787
|
-
className: "pl-space-2xs",
|
|
1788
1763
|
children: [
|
|
1789
1764
|
t,
|
|
1790
1765
|
": ",
|
|
@@ -1794,21 +1769,21 @@ function pt({ variant: e, channelsLabel: t }) {
|
|
|
1794
1769
|
})]
|
|
1795
1770
|
});
|
|
1796
1771
|
}
|
|
1797
|
-
function
|
|
1798
|
-
return /* @__PURE__ */
|
|
1772
|
+
function ut({ value: e, emphasis: t = !1 }) {
|
|
1773
|
+
return /* @__PURE__ */ V(e ? m : h, {
|
|
1799
1774
|
weight: t ? "semibold" : void 0,
|
|
1800
1775
|
className: "min-w-0 tabular-nums",
|
|
1801
1776
|
children: e ?? "-"
|
|
1802
1777
|
});
|
|
1803
1778
|
}
|
|
1804
|
-
function
|
|
1805
|
-
let h = r(
|
|
1779
|
+
function dt({ variants: e = [], onCreateVariant: t, onSelectVariant: n, onEditVariant: a, onDuplicateVariant: o, onDeleteVariant: c, renderVariantActions: l, actions: u, footerSlot: d, empty: f, className: p, strings: m }) {
|
|
1780
|
+
let h = r(Z, m), g = B(() => {
|
|
1806
1781
|
if (l) return;
|
|
1807
1782
|
let e = [
|
|
1808
1783
|
...n ? [{
|
|
1809
1784
|
id: "open",
|
|
1810
1785
|
label: h.viewLabel,
|
|
1811
|
-
icon: /* @__PURE__ */
|
|
1786
|
+
icon: /* @__PURE__ */ V(he, {
|
|
1812
1787
|
className: "size-icon-sm",
|
|
1813
1788
|
"aria-hidden": "true"
|
|
1814
1789
|
}),
|
|
@@ -1818,7 +1793,7 @@ function ht({ variants: e = [], onCreateVariant: t, onSelectVariant: n, onEditVa
|
|
|
1818
1793
|
...a ? [{
|
|
1819
1794
|
id: "edit",
|
|
1820
1795
|
label: h.editLabel,
|
|
1821
|
-
icon: /* @__PURE__ */
|
|
1796
|
+
icon: /* @__PURE__ */ V(W, {
|
|
1822
1797
|
className: "size-icon-sm",
|
|
1823
1798
|
"aria-hidden": "true"
|
|
1824
1799
|
}),
|
|
@@ -1828,7 +1803,7 @@ function ht({ variants: e = [], onCreateVariant: t, onSelectVariant: n, onEditVa
|
|
|
1828
1803
|
...o ? [{
|
|
1829
1804
|
id: "duplicate",
|
|
1830
1805
|
label: h.duplicateLabel,
|
|
1831
|
-
icon: /* @__PURE__ */
|
|
1806
|
+
icon: /* @__PURE__ */ V(me, {
|
|
1832
1807
|
className: "size-icon-sm",
|
|
1833
1808
|
"aria-hidden": "true"
|
|
1834
1809
|
}),
|
|
@@ -1838,7 +1813,7 @@ function ht({ variants: e = [], onCreateVariant: t, onSelectVariant: n, onEditVa
|
|
|
1838
1813
|
...c ? [{
|
|
1839
1814
|
id: "delete",
|
|
1840
1815
|
label: h.deleteLabel,
|
|
1841
|
-
icon: /* @__PURE__ */
|
|
1816
|
+
icon: /* @__PURE__ */ V(q, {
|
|
1842
1817
|
className: "size-icon-sm",
|
|
1843
1818
|
"aria-hidden": "true"
|
|
1844
1819
|
}),
|
|
@@ -1857,12 +1832,12 @@ function ht({ variants: e = [], onCreateVariant: t, onSelectVariant: n, onEditVa
|
|
|
1857
1832
|
h.duplicateLabel,
|
|
1858
1833
|
h.editLabel,
|
|
1859
1834
|
h.viewLabel
|
|
1860
|
-
]), _ =
|
|
1835
|
+
]), _ = B(() => {
|
|
1861
1836
|
let e = [
|
|
1862
1837
|
{
|
|
1863
1838
|
accessorKey: "name",
|
|
1864
1839
|
header: h.headers.variant,
|
|
1865
|
-
cell: ({ row: e }) => /* @__PURE__ */
|
|
1840
|
+
cell: ({ row: e }) => /* @__PURE__ */ V(lt, {
|
|
1866
1841
|
variant: e.original,
|
|
1867
1842
|
channelsLabel: h.headers.channels
|
|
1868
1843
|
})
|
|
@@ -1870,7 +1845,7 @@ function ht({ variants: e = [], onCreateVariant: t, onSelectVariant: n, onEditVa
|
|
|
1870
1845
|
{
|
|
1871
1846
|
accessorKey: "price",
|
|
1872
1847
|
header: h.headers.price,
|
|
1873
|
-
cell: ({ row: e }) => /* @__PURE__ */
|
|
1848
|
+
cell: ({ row: e }) => /* @__PURE__ */ V(ut, {
|
|
1874
1849
|
value: e.original.price,
|
|
1875
1850
|
emphasis: !0
|
|
1876
1851
|
}),
|
|
@@ -1879,17 +1854,17 @@ function ht({ variants: e = [], onCreateVariant: t, onSelectVariant: n, onEditVa
|
|
|
1879
1854
|
{
|
|
1880
1855
|
accessorKey: "inventory",
|
|
1881
1856
|
header: h.headers.inventory,
|
|
1882
|
-
cell: ({ row: e }) => /* @__PURE__ */
|
|
1857
|
+
cell: ({ row: e }) => /* @__PURE__ */ V(ut, { value: e.original.inventory })
|
|
1883
1858
|
},
|
|
1884
1859
|
{
|
|
1885
1860
|
accessorKey: "sku",
|
|
1886
1861
|
header: h.headers.sku,
|
|
1887
|
-
cell: ({ row: e }) => /* @__PURE__ */
|
|
1862
|
+
cell: ({ row: e }) => /* @__PURE__ */ V(ut, { value: e.original.sku })
|
|
1888
1863
|
},
|
|
1889
1864
|
{
|
|
1890
1865
|
accessorKey: "updatedAt",
|
|
1891
1866
|
header: h.headers.updated,
|
|
1892
|
-
cell: ({ row: e }) => /* @__PURE__ */
|
|
1867
|
+
cell: ({ row: e }) => /* @__PURE__ */ V(ut, { value: e.original.updatedAt })
|
|
1893
1868
|
}
|
|
1894
1869
|
];
|
|
1895
1870
|
return l && e.push({
|
|
@@ -1917,33 +1892,32 @@ function ht({ variants: e = [], onCreateVariant: t, onSelectVariant: n, onEditVa
|
|
|
1917
1892
|
h.headers.sku,
|
|
1918
1893
|
h.headers.updated,
|
|
1919
1894
|
h.headers.variant
|
|
1920
|
-
]), v = t ? /* @__PURE__ */
|
|
1895
|
+
]), v = t ? /* @__PURE__ */ V(s, {
|
|
1921
1896
|
type: "button",
|
|
1922
1897
|
tone: "secondary",
|
|
1923
1898
|
buttonStyle: "ghost",
|
|
1924
1899
|
onClick: t,
|
|
1925
|
-
icon:
|
|
1900
|
+
icon: G,
|
|
1926
1901
|
children: h.createLabel
|
|
1927
1902
|
}) : void 0;
|
|
1928
|
-
return /* @__PURE__ */
|
|
1929
|
-
icon: /* @__PURE__ */ R(ve, { className: "size-icon" }),
|
|
1903
|
+
return /* @__PURE__ */ V(E, {
|
|
1930
1904
|
title: h.title,
|
|
1931
1905
|
description: h.description,
|
|
1932
1906
|
actions: u,
|
|
1933
1907
|
headerAction: v,
|
|
1934
1908
|
footerSlot: d,
|
|
1935
|
-
contentClassName: "mt-1",
|
|
1936
1909
|
className: i("product-variants-table--component w-full", p),
|
|
1937
|
-
children: e.length === 0 ? f ?? /* @__PURE__ */
|
|
1910
|
+
children: e.length === 0 ? f ?? /* @__PURE__ */ V($, {
|
|
1938
1911
|
title: h.emptyTitle,
|
|
1939
1912
|
description: h.emptyDescription,
|
|
1940
|
-
action: t ? /* @__PURE__ */
|
|
1913
|
+
action: t ? /* @__PURE__ */ V(s, {
|
|
1914
|
+
tone: "primary",
|
|
1941
1915
|
type: "button",
|
|
1942
1916
|
onClick: t,
|
|
1943
|
-
icon:
|
|
1917
|
+
icon: G,
|
|
1944
1918
|
children: h.createLabel
|
|
1945
1919
|
}) : void 0
|
|
1946
|
-
}) : /* @__PURE__ */
|
|
1920
|
+
}) : /* @__PURE__ */ V(ce, {
|
|
1947
1921
|
data: e,
|
|
1948
1922
|
columns: _,
|
|
1949
1923
|
getRowId: (e) => e.id,
|
|
@@ -1960,43 +1934,43 @@ function ht({ variants: e = [], onCreateVariant: t, onSelectVariant: n, onEditVa
|
|
|
1960
1934
|
})
|
|
1961
1935
|
});
|
|
1962
1936
|
}
|
|
1963
|
-
|
|
1937
|
+
dt.displayName = "ProductVariantsTable";
|
|
1964
1938
|
//#endregion
|
|
1965
1939
|
//#region src/components/features/products/components/product-overview.tsx
|
|
1966
|
-
function
|
|
1967
|
-
let _ = r(
|
|
1968
|
-
return /* @__PURE__ */
|
|
1969
|
-
gap: "
|
|
1940
|
+
function ft({ details: e, contract: t, options: n, variants: a, readiness: o, structure: s, operations: c, quote: u, policies: d, slots: f, className: p, mainClassName: m, railClassName: h, strings: g }) {
|
|
1941
|
+
let _ = r(je, g), v = !!(o || s || c || u || d || f?.railTop || f?.railBottom);
|
|
1942
|
+
return /* @__PURE__ */ H(l, {
|
|
1943
|
+
gap: "3xl",
|
|
1970
1944
|
className: i("product-overview--component @container/product-overview", p),
|
|
1971
1945
|
children: [
|
|
1972
1946
|
f?.before,
|
|
1973
|
-
/* @__PURE__ */
|
|
1974
|
-
className: i("grid min-w-0 grid-cols-1 gap-space-
|
|
1975
|
-
children: [/* @__PURE__ */
|
|
1976
|
-
render: /* @__PURE__ */
|
|
1977
|
-
gap: "
|
|
1947
|
+
/* @__PURE__ */ H("div", {
|
|
1948
|
+
className: i("grid min-w-0 grid-cols-1 gap-space-3xl", v && "@5xl/product-overview:grid-cols-[minmax(0,1fr)_22rem]"),
|
|
1949
|
+
children: [/* @__PURE__ */ H(l, {
|
|
1950
|
+
render: /* @__PURE__ */ V("section", {}),
|
|
1951
|
+
gap: "3xl",
|
|
1978
1952
|
"aria-label": _.mainLabel,
|
|
1979
1953
|
className: i("product-overview--main", m),
|
|
1980
1954
|
children: [
|
|
1981
1955
|
f?.mainTop,
|
|
1982
|
-
!!e && /* @__PURE__ */
|
|
1983
|
-
!!t && /* @__PURE__ */
|
|
1984
|
-
!!n && /* @__PURE__ */
|
|
1985
|
-
!!a && /* @__PURE__ */
|
|
1956
|
+
!!e && /* @__PURE__ */ V(Xe, { ...e }),
|
|
1957
|
+
!!t && /* @__PURE__ */ V(Ye, { ...t }),
|
|
1958
|
+
!!n && /* @__PURE__ */ V(it, { ...n }),
|
|
1959
|
+
!!a && /* @__PURE__ */ V(dt, { ...a }),
|
|
1986
1960
|
f?.mainBottom
|
|
1987
1961
|
]
|
|
1988
|
-
}), !!v && /* @__PURE__ */
|
|
1989
|
-
render: /* @__PURE__ */
|
|
1990
|
-
gap: "
|
|
1962
|
+
}), !!v && /* @__PURE__ */ H(l, {
|
|
1963
|
+
render: /* @__PURE__ */ V("aside", {}),
|
|
1964
|
+
gap: "3xl",
|
|
1991
1965
|
"aria-label": _.railLabel,
|
|
1992
1966
|
className: i("product-overview--rail", h),
|
|
1993
1967
|
children: [
|
|
1994
1968
|
f?.railTop,
|
|
1995
|
-
!!o && /* @__PURE__ */
|
|
1996
|
-
!!s && /* @__PURE__ */
|
|
1997
|
-
!!c && /* @__PURE__ */
|
|
1998
|
-
!!u && /* @__PURE__ */
|
|
1999
|
-
!!d && /* @__PURE__ */
|
|
1969
|
+
!!o && /* @__PURE__ */ V(st, { ...o }),
|
|
1970
|
+
!!s && /* @__PURE__ */ V(ct, { ...s }),
|
|
1971
|
+
!!c && /* @__PURE__ */ V(Qe, { ...c }),
|
|
1972
|
+
!!u && /* @__PURE__ */ V(ot, { ...u }),
|
|
1973
|
+
!!d && /* @__PURE__ */ V(at, { ...d }),
|
|
2000
1974
|
f?.railBottom
|
|
2001
1975
|
]
|
|
2002
1976
|
})]
|
|
@@ -2005,12 +1979,12 @@ function gt({ details: e, contract: t, options: n, variants: a, readiness: o, st
|
|
|
2005
1979
|
]
|
|
2006
1980
|
});
|
|
2007
1981
|
}
|
|
2008
|
-
|
|
1982
|
+
ft.displayName = "ProductOverview";
|
|
2009
1983
|
//#endregion
|
|
2010
1984
|
//#region src/components/features/products/components/product-variant-action-menu.tsx
|
|
2011
|
-
function
|
|
2012
|
-
let f = r(
|
|
2013
|
-
return p || m || h || g || c ? c ? /* @__PURE__ */
|
|
1985
|
+
function pt({ variant: e, index: t = 0, onSelectVariant: n, onEditVariant: a, onDuplicateVariant: o, onDeleteVariant: s, renderVariantActions: c, menuLabel: l, className: u, strings: d }) {
|
|
1986
|
+
let f = r(ke, d), p = n ? () => n(e) : void 0, m = a ? () => a(e) : void 0, h = o ? () => o(e) : void 0, g = s ? () => s(e) : void 0;
|
|
1987
|
+
return p || m || h || g || c ? c ? /* @__PURE__ */ V("div", {
|
|
2014
1988
|
className: i("product-variant-action-menu--component flex justify-end", u),
|
|
2015
1989
|
children: c(e, {
|
|
2016
1990
|
index: t,
|
|
@@ -2019,7 +1993,7 @@ function _t({ variant: e, index: t = 0, onSelectVariant: n, onEditVariant: a, on
|
|
|
2019
1993
|
onDuplicate: h,
|
|
2020
1994
|
onDelete: g
|
|
2021
1995
|
})
|
|
2022
|
-
}) : /* @__PURE__ */
|
|
1996
|
+
}) : /* @__PURE__ */ V(ze, {
|
|
2023
1997
|
item: e,
|
|
2024
1998
|
menuLabel: l ?? f.actionsLabel,
|
|
2025
1999
|
className: i("product-variant-action-menu--component", u),
|
|
@@ -2027,7 +2001,7 @@ function _t({ variant: e, index: t = 0, onSelectVariant: n, onEditVariant: a, on
|
|
|
2027
2001
|
...p ? [{
|
|
2028
2002
|
id: "open",
|
|
2029
2003
|
label: f.viewLabel,
|
|
2030
|
-
icon: /* @__PURE__ */
|
|
2004
|
+
icon: /* @__PURE__ */ V(he, { className: "size-icon-md" }),
|
|
2031
2005
|
onClick: () => p(),
|
|
2032
2006
|
tone: "secondary",
|
|
2033
2007
|
buttonStyle: "ghost"
|
|
@@ -2035,7 +2009,7 @@ function _t({ variant: e, index: t = 0, onSelectVariant: n, onEditVariant: a, on
|
|
|
2035
2009
|
...m ? [{
|
|
2036
2010
|
id: "edit",
|
|
2037
2011
|
label: f.editLabel,
|
|
2038
|
-
icon: /* @__PURE__ */
|
|
2012
|
+
icon: /* @__PURE__ */ V(W, { className: "size-icon-md" }),
|
|
2039
2013
|
onClick: () => m(),
|
|
2040
2014
|
tone: "secondary",
|
|
2041
2015
|
buttonStyle: "ghost"
|
|
@@ -2043,7 +2017,7 @@ function _t({ variant: e, index: t = 0, onSelectVariant: n, onEditVariant: a, on
|
|
|
2043
2017
|
...h ? [{
|
|
2044
2018
|
id: "duplicate",
|
|
2045
2019
|
label: f.duplicateLabel,
|
|
2046
|
-
icon: /* @__PURE__ */
|
|
2020
|
+
icon: /* @__PURE__ */ V(me, { className: "size-icon-md" }),
|
|
2047
2021
|
onClick: () => h(),
|
|
2048
2022
|
tone: "secondary",
|
|
2049
2023
|
buttonStyle: "ghost"
|
|
@@ -2051,18 +2025,18 @@ function _t({ variant: e, index: t = 0, onSelectVariant: n, onEditVariant: a, on
|
|
|
2051
2025
|
...g ? [{
|
|
2052
2026
|
id: "delete",
|
|
2053
2027
|
label: f.deleteLabel,
|
|
2054
|
-
icon: /* @__PURE__ */
|
|
2028
|
+
icon: /* @__PURE__ */ V(q, { className: "size-icon-md" }),
|
|
2055
2029
|
onClick: () => g(),
|
|
2056
2030
|
tone: "destructive"
|
|
2057
2031
|
}] : []
|
|
2058
2032
|
]
|
|
2059
2033
|
}) : null;
|
|
2060
2034
|
}
|
|
2061
|
-
|
|
2035
|
+
pt.displayName = "ProductVariantActionMenu";
|
|
2062
2036
|
//#endregion
|
|
2063
2037
|
//#region src/components/features/products/components/product-variant-details.tsx
|
|
2064
|
-
var
|
|
2065
|
-
function
|
|
2038
|
+
var mt = (e) => e != null && e !== !1 && e !== "";
|
|
2039
|
+
function ht(e, t) {
|
|
2066
2040
|
return [
|
|
2067
2041
|
{
|
|
2068
2042
|
label: t.price,
|
|
@@ -2084,19 +2058,19 @@ function yt(e, t) {
|
|
|
2084
2058
|
label: t.updated,
|
|
2085
2059
|
value: e.updatedAt
|
|
2086
2060
|
}
|
|
2087
|
-
].filter((e) =>
|
|
2061
|
+
].filter((e) => mt(e.value));
|
|
2088
2062
|
}
|
|
2089
|
-
function
|
|
2090
|
-
let
|
|
2063
|
+
function gt({ variant: e, metadata: t, optionItems: n = [], media: a, onBack: c, onSelectVariant: u, onEditVariant: d, onDuplicateVariant: f, onDeleteVariant: p, onSelectOption: m, actions: h, headerEnd: g, footerSlot: v, empty: y, renderActions: b, renderMetadata: x, renderOption: S, className: C, strings: w }) {
|
|
2064
|
+
let T = r(Q, w), D = e ? t ?? ht(e, T.metadata) : [], O = !!(e && (u || d || f || p || b)), k = /* @__PURE__ */ H("div", {
|
|
2091
2065
|
className: "product-variant-details--header-actions flex items-center gap-space-md",
|
|
2092
|
-
children: [!!c && /* @__PURE__ */
|
|
2066
|
+
children: [!!c && /* @__PURE__ */ V(s, {
|
|
2093
2067
|
type: "button",
|
|
2094
2068
|
tone: "secondary",
|
|
2095
2069
|
buttonStyle: "ghost",
|
|
2096
2070
|
onClick: c,
|
|
2097
|
-
icon:
|
|
2098
|
-
children:
|
|
2099
|
-
}), !!
|
|
2071
|
+
icon: fe,
|
|
2072
|
+
children: T.backLabel
|
|
2073
|
+
}), !!O && e && /* @__PURE__ */ V(pt, {
|
|
2100
2074
|
variant: e,
|
|
2101
2075
|
onSelectVariant: u,
|
|
2102
2076
|
onEditVariant: d,
|
|
@@ -2104,186 +2078,185 @@ function bt({ variant: e, metadata: t, optionItems: n = [], media: o, onBack: c,
|
|
|
2104
2078
|
onDeleteVariant: p,
|
|
2105
2079
|
renderVariantActions: b
|
|
2106
2080
|
})]
|
|
2107
|
-
}),
|
|
2108
|
-
return /* @__PURE__ */
|
|
2109
|
-
|
|
2110
|
-
|
|
2111
|
-
titleSuffix: e?.status ? /* @__PURE__ */ R(g, {
|
|
2081
|
+
}), A = e?.options ?? [];
|
|
2082
|
+
return /* @__PURE__ */ V(E, {
|
|
2083
|
+
title: e?.name ?? T.title,
|
|
2084
|
+
titleSuffix: e?.status ? /* @__PURE__ */ V(_, {
|
|
2112
2085
|
tone: e.statusTone ?? "secondary",
|
|
2113
2086
|
children: e.status
|
|
2114
2087
|
}) : void 0,
|
|
2115
|
-
description: e?.description ??
|
|
2088
|
+
description: e?.description ?? T.description,
|
|
2116
2089
|
actions: h,
|
|
2117
|
-
headerAction: c ||
|
|
2118
|
-
headerEnd:
|
|
2090
|
+
headerAction: c || O ? k : void 0,
|
|
2091
|
+
headerEnd: g,
|
|
2119
2092
|
footerSlot: v,
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
gap: "xl",
|
|
2093
|
+
className: i("product-variant-details--component w-full", C),
|
|
2094
|
+
children: e ? /* @__PURE__ */ H(l, {
|
|
2095
|
+
gap: "2xl",
|
|
2124
2096
|
className: "product-variant-details--body",
|
|
2125
2097
|
children: [
|
|
2126
|
-
!!
|
|
2098
|
+
!!a && /* @__PURE__ */ V("div", {
|
|
2127
2099
|
className: "product-variant-details--media overflow-hidden rounded-inner border border-border bg-muted/30",
|
|
2128
|
-
children:
|
|
2100
|
+
children: a
|
|
2129
2101
|
}),
|
|
2130
|
-
x ? x(e) : /* @__PURE__ */
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2102
|
+
x ? x(e) : D.some(Boolean) && /* @__PURE__ */ H(l, {
|
|
2103
|
+
gap: "md",
|
|
2104
|
+
className: "product-variant-details--facts",
|
|
2105
|
+
children: [/* @__PURE__ */ V(o, {
|
|
2106
|
+
weight: "semibold",
|
|
2107
|
+
children: T.factsTitle
|
|
2108
|
+
}), /* @__PURE__ */ V(se, {
|
|
2109
|
+
items: D,
|
|
2110
|
+
columns: 3,
|
|
2111
|
+
density: "compact",
|
|
2112
|
+
className: "product-variant-details--metadata"
|
|
2113
|
+
})]
|
|
2136
2114
|
}),
|
|
2137
|
-
!!
|
|
2115
|
+
!!A.length && /* @__PURE__ */ H(l, {
|
|
2138
2116
|
gap: "md",
|
|
2139
2117
|
className: "product-variant-details--selected-options",
|
|
2140
|
-
children: [/* @__PURE__ */
|
|
2118
|
+
children: [/* @__PURE__ */ V(o, {
|
|
2141
2119
|
weight: "semibold",
|
|
2142
|
-
children:
|
|
2143
|
-
}), /* @__PURE__ */
|
|
2120
|
+
children: T.selectedOptionsTitle
|
|
2121
|
+
}), /* @__PURE__ */ V("div", {
|
|
2144
2122
|
className: "flex flex-wrap gap-space-sm",
|
|
2145
|
-
children:
|
|
2123
|
+
children: A.map((e, t) => /* @__PURE__ */ V(_, {
|
|
2146
2124
|
tone: "secondary",
|
|
2147
2125
|
children: e
|
|
2148
2126
|
}, t))
|
|
2149
2127
|
})]
|
|
2150
2128
|
}),
|
|
2151
|
-
!!n.length && /* @__PURE__ */
|
|
2129
|
+
!!n.length && /* @__PURE__ */ H(l, {
|
|
2152
2130
|
gap: "md",
|
|
2153
2131
|
className: "product-variant-details--related-options",
|
|
2154
|
-
children: [/* @__PURE__ */
|
|
2132
|
+
children: [/* @__PURE__ */ V(o, {
|
|
2155
2133
|
weight: "semibold",
|
|
2156
|
-
children:
|
|
2157
|
-
}), /* @__PURE__ */
|
|
2134
|
+
children: T.relatedOptionsTitle
|
|
2135
|
+
}), /* @__PURE__ */ V(M, { children: n.map((e, t) => S ? /* @__PURE__ */ V("div", { children: S(e, t) }, e.id) : /* @__PURE__ */ V(Je, {
|
|
2158
2136
|
item: e,
|
|
2159
|
-
actionLabel:
|
|
2137
|
+
actionLabel: T.viewOptionLabel,
|
|
2160
2138
|
onSelect: m ? () => m(e) : void 0
|
|
2161
2139
|
}, e.id)) })]
|
|
2162
2140
|
})
|
|
2163
2141
|
]
|
|
2164
|
-
}) : y ?? /* @__PURE__ */
|
|
2165
|
-
title:
|
|
2166
|
-
description:
|
|
2142
|
+
}) : y ?? /* @__PURE__ */ V($, {
|
|
2143
|
+
title: T.emptyTitle,
|
|
2144
|
+
description: T.emptyDescription
|
|
2167
2145
|
})
|
|
2168
2146
|
});
|
|
2169
2147
|
}
|
|
2170
|
-
|
|
2148
|
+
gt.displayName = "ProductVariantDetails";
|
|
2171
2149
|
//#endregion
|
|
2172
2150
|
//#region src/components/features/products/components/product-variant-editor.tsx
|
|
2173
|
-
var
|
|
2151
|
+
var _t = (e) => e.map((e) => ({
|
|
2174
2152
|
value: e.value,
|
|
2175
2153
|
label: e.label,
|
|
2176
2154
|
disabled: e.disabled
|
|
2177
2155
|
}));
|
|
2178
|
-
function
|
|
2179
|
-
let
|
|
2156
|
+
function vt({ value: e, defaultValue: t, optionFields: n = [], statusOptions: a = [], onValueChange: c, onSubmit: u, onError: d, onCancel: f, onDelete: p, actions: m, headerEnd: h, footerSlot: g, disabled: _ = !1, submitting: v = !1, className: y, strings: w }) {
|
|
2157
|
+
let T = r(Ae, w), D = z(), O = e !== void 0, [k, A] = ue(t ?? {}), [j, M] = ue(!1), N = (O ? e : k) ?? {}, P = v || j, F = _ || P, ee = (e) => {
|
|
2180
2158
|
O || A(e), c?.(e);
|
|
2181
|
-
},
|
|
2182
|
-
|
|
2183
|
-
...
|
|
2159
|
+
}, I = (e, t) => {
|
|
2160
|
+
ee({
|
|
2161
|
+
...N,
|
|
2184
2162
|
[e]: t
|
|
2185
2163
|
});
|
|
2186
|
-
},
|
|
2187
|
-
|
|
2188
|
-
...
|
|
2164
|
+
}, te = (e, t) => {
|
|
2165
|
+
ee({
|
|
2166
|
+
...N,
|
|
2189
2167
|
options: {
|
|
2190
|
-
...
|
|
2168
|
+
...N.options,
|
|
2191
2169
|
[e.id]: t
|
|
2192
2170
|
}
|
|
2193
2171
|
});
|
|
2194
|
-
},
|
|
2195
|
-
if (e.preventDefault(), u && !
|
|
2196
|
-
|
|
2172
|
+
}, ne = async (e) => {
|
|
2173
|
+
if (e.preventDefault(), u && !P) {
|
|
2174
|
+
M(!0);
|
|
2197
2175
|
try {
|
|
2198
|
-
await u(
|
|
2176
|
+
await u(N);
|
|
2199
2177
|
} catch (e) {
|
|
2200
2178
|
d?.(e);
|
|
2201
2179
|
} finally {
|
|
2202
|
-
|
|
2180
|
+
M(!1);
|
|
2203
2181
|
}
|
|
2204
2182
|
}
|
|
2205
|
-
},
|
|
2183
|
+
}, re = /* @__PURE__ */ H("div", {
|
|
2206
2184
|
className: "product-variant-editor--footer flex flex-col-reverse gap-space-md @sm/product-variant-editor:flex-row @sm/product-variant-editor:items-center @sm/product-variant-editor:justify-between",
|
|
2207
|
-
children: [/* @__PURE__ */
|
|
2185
|
+
children: [/* @__PURE__ */ V("div", { children: !!p && /* @__PURE__ */ V(s, {
|
|
2208
2186
|
type: "button",
|
|
2209
2187
|
tone: "destructive",
|
|
2210
2188
|
buttonStyle: "ghost",
|
|
2211
|
-
onClick: () => p(
|
|
2212
|
-
disabled:
|
|
2213
|
-
|
|
2214
|
-
|
|
2215
|
-
}) }), /* @__PURE__ */ z("div", {
|
|
2189
|
+
onClick: () => p(N),
|
|
2190
|
+
disabled: F,
|
|
2191
|
+
children: T.deleteLabel
|
|
2192
|
+
}) }), /* @__PURE__ */ H("div", {
|
|
2216
2193
|
className: "flex flex-col-reverse gap-space-md @sm/product-variant-editor:flex-row @sm/product-variant-editor:justify-end",
|
|
2217
|
-
children: [!!f && /* @__PURE__ */
|
|
2194
|
+
children: [!!f && /* @__PURE__ */ V(s, {
|
|
2218
2195
|
type: "button",
|
|
2219
2196
|
tone: "secondary",
|
|
2220
2197
|
buttonStyle: "ghost",
|
|
2221
2198
|
onClick: f,
|
|
2222
|
-
disabled:
|
|
2223
|
-
|
|
2224
|
-
|
|
2225
|
-
|
|
2199
|
+
disabled: F,
|
|
2200
|
+
children: T.cancelLabel
|
|
2201
|
+
}), !!u && /* @__PURE__ */ V(s, {
|
|
2202
|
+
tone: "primary",
|
|
2226
2203
|
type: "submit",
|
|
2227
2204
|
form: D,
|
|
2228
|
-
disabled:
|
|
2229
|
-
|
|
2230
|
-
children: te ? E.savingLabel : E.saveLabel
|
|
2205
|
+
disabled: F,
|
|
2206
|
+
children: P ? T.savingLabel : T.saveLabel
|
|
2231
2207
|
})]
|
|
2232
2208
|
})]
|
|
2233
|
-
}),
|
|
2234
|
-
return /* @__PURE__ */
|
|
2235
|
-
|
|
2236
|
-
|
|
2237
|
-
description: E.description,
|
|
2209
|
+
}), ie = !!(p || f || u);
|
|
2210
|
+
return /* @__PURE__ */ V(E, {
|
|
2211
|
+
title: T.title,
|
|
2212
|
+
description: T.description,
|
|
2238
2213
|
actions: m,
|
|
2239
2214
|
headerEnd: h,
|
|
2240
|
-
footerSlot: g
|
|
2241
|
-
|
|
2242
|
-
|
|
2243
|
-
|
|
2244
|
-
children: /* @__PURE__ */ z(l, {
|
|
2245
|
-
render: /* @__PURE__ */ R("form", {
|
|
2215
|
+
footerSlot: g,
|
|
2216
|
+
className: i("product-variant-editor--component @container/product-variant-editor w-full", y),
|
|
2217
|
+
children: /* @__PURE__ */ H(l, {
|
|
2218
|
+
render: /* @__PURE__ */ V("form", {
|
|
2246
2219
|
id: D,
|
|
2247
|
-
onSubmit:
|
|
2220
|
+
onSubmit: ne
|
|
2248
2221
|
}),
|
|
2249
2222
|
gap: "2xl",
|
|
2250
2223
|
className: "product-variant-editor--form",
|
|
2251
2224
|
children: [
|
|
2252
|
-
/* @__PURE__ */
|
|
2225
|
+
/* @__PURE__ */ H("section", {
|
|
2253
2226
|
className: "product-variant-editor--section grid gap-space-lg",
|
|
2254
|
-
children: [/* @__PURE__ */
|
|
2227
|
+
children: [/* @__PURE__ */ V(o, {
|
|
2255
2228
|
weight: "semibold",
|
|
2256
|
-
children:
|
|
2257
|
-
}), /* @__PURE__ */
|
|
2229
|
+
children: T.identityTitle
|
|
2230
|
+
}), /* @__PURE__ */ H("div", {
|
|
2258
2231
|
className: "grid gap-space-lg @sm/product-variant-editor:grid-cols-2",
|
|
2259
2232
|
children: [
|
|
2260
|
-
/* @__PURE__ */
|
|
2261
|
-
label:
|
|
2233
|
+
/* @__PURE__ */ V(x, {
|
|
2234
|
+
label: T.fields.name,
|
|
2262
2235
|
required: !0,
|
|
2263
|
-
children: /* @__PURE__ */
|
|
2264
|
-
value:
|
|
2265
|
-
onChange: (e) =>
|
|
2266
|
-
placeholder:
|
|
2267
|
-
disabled:
|
|
2236
|
+
children: /* @__PURE__ */ V(b, {
|
|
2237
|
+
value: N.name ?? "",
|
|
2238
|
+
onChange: (e) => I("name", e.target.value),
|
|
2239
|
+
placeholder: T.placeholders.name,
|
|
2240
|
+
disabled: F
|
|
2268
2241
|
})
|
|
2269
2242
|
}),
|
|
2270
|
-
/* @__PURE__ */
|
|
2271
|
-
label:
|
|
2272
|
-
children: /* @__PURE__ */
|
|
2273
|
-
value:
|
|
2274
|
-
onChange: (e) =>
|
|
2275
|
-
placeholder:
|
|
2276
|
-
disabled:
|
|
2243
|
+
/* @__PURE__ */ V(x, {
|
|
2244
|
+
label: T.fields.sku,
|
|
2245
|
+
children: /* @__PURE__ */ V(b, {
|
|
2246
|
+
value: N.sku ?? "",
|
|
2247
|
+
onChange: (e) => I("sku", e.target.value),
|
|
2248
|
+
placeholder: T.placeholders.sku,
|
|
2249
|
+
disabled: F
|
|
2277
2250
|
})
|
|
2278
2251
|
}),
|
|
2279
|
-
/* @__PURE__ */
|
|
2280
|
-
label:
|
|
2252
|
+
/* @__PURE__ */ V(x, {
|
|
2253
|
+
label: T.fields.description,
|
|
2281
2254
|
className: "@sm/product-variant-editor:col-span-2",
|
|
2282
|
-
children: /* @__PURE__ */
|
|
2283
|
-
value:
|
|
2284
|
-
onChange: (e) =>
|
|
2285
|
-
placeholder:
|
|
2286
|
-
disabled:
|
|
2255
|
+
children: /* @__PURE__ */ V(S, {
|
|
2256
|
+
value: N.description ?? "",
|
|
2257
|
+
onChange: (e) => I("description", e.target.value),
|
|
2258
|
+
placeholder: T.placeholders.description,
|
|
2259
|
+
disabled: F,
|
|
2287
2260
|
autoResize: !0,
|
|
2288
2261
|
minRows: 2
|
|
2289
2262
|
})
|
|
@@ -2291,141 +2264,142 @@ function St({ value: e, defaultValue: t, optionFields: n = [], statusOptions: o
|
|
|
2291
2264
|
]
|
|
2292
2265
|
})]
|
|
2293
2266
|
}),
|
|
2294
|
-
/* @__PURE__ */
|
|
2267
|
+
/* @__PURE__ */ H("section", {
|
|
2295
2268
|
className: "product-variant-editor--section grid gap-space-lg",
|
|
2296
|
-
children: [/* @__PURE__ */
|
|
2269
|
+
children: [/* @__PURE__ */ V(o, {
|
|
2297
2270
|
weight: "semibold",
|
|
2298
|
-
children:
|
|
2299
|
-
}), /* @__PURE__ */
|
|
2271
|
+
children: T.commercialTitle
|
|
2272
|
+
}), /* @__PURE__ */ H("div", {
|
|
2300
2273
|
className: "grid gap-space-lg @sm/product-variant-editor:grid-cols-2",
|
|
2301
2274
|
children: [
|
|
2302
|
-
/* @__PURE__ */
|
|
2303
|
-
label:
|
|
2304
|
-
children: /* @__PURE__ */
|
|
2305
|
-
value:
|
|
2306
|
-
onChange: (e) =>
|
|
2307
|
-
placeholder:
|
|
2308
|
-
disabled:
|
|
2275
|
+
/* @__PURE__ */ V(x, {
|
|
2276
|
+
label: T.fields.price,
|
|
2277
|
+
children: /* @__PURE__ */ V(b, {
|
|
2278
|
+
value: N.price ?? "",
|
|
2279
|
+
onChange: (e) => I("price", e.target.value),
|
|
2280
|
+
placeholder: T.placeholders.price,
|
|
2281
|
+
disabled: F
|
|
2309
2282
|
})
|
|
2310
2283
|
}),
|
|
2311
|
-
/* @__PURE__ */
|
|
2312
|
-
label:
|
|
2313
|
-
children: /* @__PURE__ */
|
|
2314
|
-
value:
|
|
2315
|
-
onChange: (e) =>
|
|
2316
|
-
placeholder:
|
|
2317
|
-
disabled:
|
|
2284
|
+
/* @__PURE__ */ V(x, {
|
|
2285
|
+
label: T.fields.inventory,
|
|
2286
|
+
children: /* @__PURE__ */ V(b, {
|
|
2287
|
+
value: N.inventory ?? "",
|
|
2288
|
+
onChange: (e) => I("inventory", e.target.value),
|
|
2289
|
+
placeholder: T.placeholders.inventory,
|
|
2290
|
+
disabled: F,
|
|
2318
2291
|
inputMode: "numeric"
|
|
2319
2292
|
})
|
|
2320
2293
|
}),
|
|
2321
|
-
/* @__PURE__ */
|
|
2322
|
-
label:
|
|
2323
|
-
children:
|
|
2324
|
-
options:
|
|
2325
|
-
value:
|
|
2326
|
-
onValueChange: (e) =>
|
|
2327
|
-
placeholder:
|
|
2328
|
-
disabled:
|
|
2329
|
-
"aria-label":
|
|
2330
|
-
}) : /* @__PURE__ */
|
|
2331
|
-
value:
|
|
2332
|
-
onChange: (e) =>
|
|
2333
|
-
placeholder:
|
|
2334
|
-
disabled:
|
|
2294
|
+
/* @__PURE__ */ V(x, {
|
|
2295
|
+
label: T.fields.status,
|
|
2296
|
+
children: a.length > 0 ? /* @__PURE__ */ V(C, {
|
|
2297
|
+
options: _t(a),
|
|
2298
|
+
value: N.status ?? null,
|
|
2299
|
+
onValueChange: (e) => I("status", e ?? ""),
|
|
2300
|
+
placeholder: T.statusPlaceholder,
|
|
2301
|
+
disabled: F,
|
|
2302
|
+
"aria-label": T.fields.status
|
|
2303
|
+
}) : /* @__PURE__ */ V(b, {
|
|
2304
|
+
value: N.status ?? "",
|
|
2305
|
+
onChange: (e) => I("status", e.target.value),
|
|
2306
|
+
placeholder: T.placeholders.status,
|
|
2307
|
+
disabled: F
|
|
2335
2308
|
})
|
|
2336
2309
|
}),
|
|
2337
|
-
/* @__PURE__ */
|
|
2338
|
-
label:
|
|
2339
|
-
children: /* @__PURE__ */
|
|
2340
|
-
value:
|
|
2341
|
-
onChange: (e) =>
|
|
2342
|
-
placeholder:
|
|
2343
|
-
disabled:
|
|
2310
|
+
/* @__PURE__ */ V(x, {
|
|
2311
|
+
label: T.fields.channels,
|
|
2312
|
+
children: /* @__PURE__ */ V(b, {
|
|
2313
|
+
value: N.channels ?? "",
|
|
2314
|
+
onChange: (e) => I("channels", e.target.value),
|
|
2315
|
+
placeholder: T.placeholders.channels,
|
|
2316
|
+
disabled: F
|
|
2344
2317
|
})
|
|
2345
2318
|
})
|
|
2346
2319
|
]
|
|
2347
2320
|
})]
|
|
2348
2321
|
}),
|
|
2349
|
-
!!n.length && /* @__PURE__ */
|
|
2322
|
+
!!n.length && /* @__PURE__ */ H("section", {
|
|
2350
2323
|
className: "product-variant-editor--section grid gap-space-lg",
|
|
2351
|
-
children: [/* @__PURE__ */
|
|
2324
|
+
children: [/* @__PURE__ */ V(o, {
|
|
2352
2325
|
weight: "semibold",
|
|
2353
|
-
children:
|
|
2354
|
-
}), /* @__PURE__ */
|
|
2326
|
+
children: T.optionsTitle
|
|
2327
|
+
}), /* @__PURE__ */ V("div", {
|
|
2355
2328
|
className: "grid gap-space-lg @sm/product-variant-editor:grid-cols-2",
|
|
2356
2329
|
children: n.map((e) => {
|
|
2357
|
-
let t = e.value ??
|
|
2358
|
-
return /* @__PURE__ */
|
|
2330
|
+
let t = e.value ?? N.options?.[e.id] ?? "", n = !!e.choices?.length;
|
|
2331
|
+
return /* @__PURE__ */ V(x, {
|
|
2359
2332
|
label: e.label,
|
|
2360
2333
|
helperText: e.helperText,
|
|
2361
|
-
children: n ? /* @__PURE__ */
|
|
2362
|
-
options:
|
|
2334
|
+
children: n ? /* @__PURE__ */ V(C, {
|
|
2335
|
+
options: _t(e.choices ?? []),
|
|
2363
2336
|
value: t || null,
|
|
2364
|
-
onValueChange: (t) =>
|
|
2365
|
-
placeholder: e.placeholder ??
|
|
2366
|
-
disabled:
|
|
2337
|
+
onValueChange: (t) => te(e, t),
|
|
2338
|
+
placeholder: e.placeholder ?? T.optionPlaceholder,
|
|
2339
|
+
disabled: F,
|
|
2367
2340
|
"aria-label": e.label
|
|
2368
|
-
}) : /* @__PURE__ */
|
|
2341
|
+
}) : /* @__PURE__ */ V(b, {
|
|
2369
2342
|
value: t,
|
|
2370
|
-
onChange: (t) =>
|
|
2371
|
-
placeholder: e.placeholder ??
|
|
2372
|
-
disabled:
|
|
2343
|
+
onChange: (t) => te(e, t.target.value),
|
|
2344
|
+
placeholder: e.placeholder ?? T.optionPlaceholder,
|
|
2345
|
+
disabled: F
|
|
2373
2346
|
})
|
|
2374
2347
|
}, e.id);
|
|
2375
2348
|
})
|
|
2376
2349
|
})]
|
|
2377
|
-
})
|
|
2350
|
+
}),
|
|
2351
|
+
g == null && ie && re
|
|
2378
2352
|
]
|
|
2379
2353
|
})
|
|
2380
2354
|
});
|
|
2381
2355
|
}
|
|
2382
|
-
|
|
2356
|
+
vt.displayName = "ProductVariantEditor";
|
|
2383
2357
|
//#endregion
|
|
2384
2358
|
//#region src/components/features/products/components/product-variants-bulk-table.tsx
|
|
2385
|
-
var
|
|
2359
|
+
var yt = [
|
|
2386
2360
|
"variant",
|
|
2387
2361
|
"sku",
|
|
2388
2362
|
"price",
|
|
2389
2363
|
"inventory",
|
|
2390
2364
|
"status"
|
|
2391
|
-
],
|
|
2392
|
-
function
|
|
2365
|
+
], bt = "text", xt = "text", St = "multiple";
|
|
2366
|
+
function Ct(e) {
|
|
2393
2367
|
return typeof e == "string" || typeof e == "number" ? String(e) : "";
|
|
2394
2368
|
}
|
|
2395
|
-
function
|
|
2369
|
+
function wt(e, t) {
|
|
2396
2370
|
let n = e.optionValues?.[t.id];
|
|
2397
2371
|
if (n != null && n !== !1 && n !== "") return n;
|
|
2398
2372
|
let r = e.optionValueIds?.[t.id];
|
|
2399
2373
|
return t.values?.find((e) => e.id === r)?.label ?? void 0;
|
|
2400
2374
|
}
|
|
2401
|
-
function
|
|
2402
|
-
return e.name !== void 0 && e.name !== null && e.name !== "" ? e.name : t.filter((e) => e.usedForVariants !== !1).map((t) =>
|
|
2375
|
+
function Tt(e, t) {
|
|
2376
|
+
return e.name !== void 0 && e.name !== null && e.name !== "" ? e.name : t.filter((e) => e.usedForVariants !== !1).map((t) => wt(e, t)).filter((e) => e != null && e !== "").map((e) => Ct(e)).filter(Boolean).join(" / ") || "-";
|
|
2403
2377
|
}
|
|
2404
|
-
function
|
|
2405
|
-
return t.filter((e) => e.usedForVariants !== !1).map((t) =>
|
|
2378
|
+
function Et(e, t) {
|
|
2379
|
+
return t.filter((e) => e.usedForVariants !== !1).map((t) => wt(e, t)).filter((e) => e != null && e !== "");
|
|
2406
2380
|
}
|
|
2407
|
-
function
|
|
2408
|
-
return e.map(
|
|
2381
|
+
function Dt(e) {
|
|
2382
|
+
return e.map(Ct).filter(Boolean).join(" / ");
|
|
2409
2383
|
}
|
|
2410
|
-
function
|
|
2411
|
-
return
|
|
2384
|
+
function Ot(e, t) {
|
|
2385
|
+
return Ct(wt(e, t)) || "-";
|
|
2412
2386
|
}
|
|
2413
|
-
function
|
|
2387
|
+
function kt(e, t) {
|
|
2414
2388
|
return e.map((e) => t.get(e)).filter((e) => !!e);
|
|
2415
2389
|
}
|
|
2416
|
-
function
|
|
2390
|
+
function At(e) {
|
|
2417
2391
|
return e == null || e === "" ? "-" : e;
|
|
2418
2392
|
}
|
|
2419
|
-
function
|
|
2393
|
+
function jt(e) {
|
|
2420
2394
|
return e != null && e !== "";
|
|
2421
2395
|
}
|
|
2422
|
-
function
|
|
2396
|
+
function Mt(e) {
|
|
2423
2397
|
return e === "sku" || e === "price" || e === "inventory";
|
|
2424
2398
|
}
|
|
2425
|
-
function
|
|
2426
|
-
return e === "text" || e === "field" ? e : e[t] ??
|
|
2399
|
+
function Nt(e, t) {
|
|
2400
|
+
return e === "text" || e === "field" ? e : e[t] ?? xt;
|
|
2427
2401
|
}
|
|
2428
|
-
function
|
|
2402
|
+
function Pt(e, t, n, r) {
|
|
2429
2403
|
return {
|
|
2430
2404
|
index: e,
|
|
2431
2405
|
field: t,
|
|
@@ -2433,11 +2407,11 @@ function Rt(e, t, n, r) {
|
|
|
2433
2407
|
value: r
|
|
2434
2408
|
};
|
|
2435
2409
|
}
|
|
2436
|
-
function
|
|
2437
|
-
let o =
|
|
2410
|
+
function Ft(e, t, n, r, a) {
|
|
2411
|
+
let o = Ct(e);
|
|
2438
2412
|
if (n === "field") {
|
|
2439
2413
|
let e = !!r;
|
|
2440
|
-
return /* @__PURE__ */
|
|
2414
|
+
return /* @__PURE__ */ V(b, {
|
|
2441
2415
|
readOnly: !e,
|
|
2442
2416
|
value: o,
|
|
2443
2417
|
onChange: e ? (e) => r(e.currentTarget.value) : void 0,
|
|
@@ -2446,263 +2420,261 @@ function zt(e, t, n, r, a) {
|
|
|
2446
2420
|
className: i("h-control-lg w-full min-w-24 bg-background px-control shadow-xs", !e && "text-muted-foreground")
|
|
2447
2421
|
});
|
|
2448
2422
|
}
|
|
2449
|
-
let s =
|
|
2450
|
-
return /* @__PURE__ */
|
|
2423
|
+
let s = jt(e) ? m : h;
|
|
2424
|
+
return /* @__PURE__ */ V(s, {
|
|
2451
2425
|
className: "min-w-0 whitespace-normal break-words tabular-nums",
|
|
2452
|
-
children:
|
|
2426
|
+
children: At(e)
|
|
2453
2427
|
});
|
|
2454
2428
|
}
|
|
2455
|
-
function
|
|
2456
|
-
let
|
|
2457
|
-
|
|
2429
|
+
function It({ variants: e = [], optionGroups: t = [], groupByOptionId: n, visibleColumns: c = yt, optionCombinationDisplay: u = bt, cellDisplay: d = xt, selectionMode: f, renderOptionCombination: p, renderCell: m, selectedVariantIds: h, defaultSelectedVariantIds: g = [], onSelectedVariantIdsChange: v, onVariantFieldChange: y, onVariantFieldBlur: b, onCreateVariant: x, onGenerateVariants: S, onSelectVariant: C, onEditVariant: w, onDuplicateVariant: D, onDeleteVariant: O, onBulkEdit: k, onBulkApply: A, onBulkDelete: j, renderVariantActions: M, renderBulkActions: N, actions: P, headerEnd: F, footerSlot: ae, empty: oe, surface: se = "card", className: L, strings: ce }) {
|
|
2430
|
+
let z = r(De, ce), de = h !== void 0, [fe, pe] = ue(g), ge = !!(N || k || A || j), U = (f ?? (ge || de || v ? St : "none")) === "multiple", _e = B(() => U ? de ? h : fe : [], [
|
|
2431
|
+
fe,
|
|
2458
2432
|
U,
|
|
2459
|
-
|
|
2433
|
+
de,
|
|
2460
2434
|
h
|
|
2461
|
-
]),
|
|
2435
|
+
]), ve = B(() => new Map(e.map((e) => [e.id, e])), [e]), K = B(() => kt(_e, ve), [ve, _e]), ye = B(() => new Set(_e), [_e]), J = B(() => new Set(c), [c]), Y = B(() => t.find((e) => e.id === n), [t, n]), be = B(() => new Map(e.map((e, t) => [e.id, t])), [e]), xe = B(() => {
|
|
2462
2436
|
if (!Y) return e;
|
|
2463
2437
|
let t = new Map((Y.values ?? []).map((e, t) => [e.id, t]));
|
|
2464
2438
|
return [...e].sort((e, n) => {
|
|
2465
2439
|
let r = e.optionValueIds?.[Y.id], i = n.optionValueIds?.[Y.id], a = r === void 0 ? void 0 : t.get(r), o = i === void 0 ? void 0 : t.get(i), s = a ?? 2 ** 53 - 1, c = o ?? 2 ** 53 - 1;
|
|
2466
|
-
return s === c ? (
|
|
2440
|
+
return s === c ? (be.get(e.id) ?? 0) - (be.get(n.id) ?? 0) : s - c;
|
|
2467
2441
|
});
|
|
2468
2442
|
}, [
|
|
2469
2443
|
Y,
|
|
2470
|
-
|
|
2444
|
+
be,
|
|
2471
2445
|
e
|
|
2472
|
-
]),
|
|
2446
|
+
]), Se = B(() => {
|
|
2473
2447
|
if (!Y) return /* @__PURE__ */ new Map();
|
|
2474
2448
|
let t = /* @__PURE__ */ new Map();
|
|
2475
2449
|
return e.forEach((e) => {
|
|
2476
|
-
let n =
|
|
2450
|
+
let n = Ot(e, Y);
|
|
2477
2451
|
t.set(n, (t.get(n) ?? 0) + 1);
|
|
2478
2452
|
}), t;
|
|
2479
|
-
}, [Y, e]),
|
|
2480
|
-
let t =
|
|
2481
|
-
|
|
2453
|
+
}, [Y, e]), Ce = U && ge, we = e.length > 0, Te = U && we && e.every((e) => ye.has(e.id)), Ee = !!(C || w || D || O || M), X = c.filter((e) => J.has(e)).length + +!!U + +!!Ee, Z = R((e) => {
|
|
2454
|
+
let t = kt(e, ve);
|
|
2455
|
+
de || pe(e), v?.(e, t);
|
|
2482
2456
|
}, [
|
|
2483
|
-
|
|
2457
|
+
de,
|
|
2484
2458
|
v,
|
|
2485
|
-
|
|
2486
|
-
]),
|
|
2459
|
+
ve
|
|
2460
|
+
]), Oe = R(() => Z([]), [Z]), ke = R((e, t) => {
|
|
2487
2461
|
if (!U) return;
|
|
2488
|
-
let n = t === !0 ? Array.from(/* @__PURE__ */ new Set([...
|
|
2489
|
-
|
|
2462
|
+
let n = t === !0 ? Array.from(/* @__PURE__ */ new Set([..._e, e.id])) : _e.filter((t) => t !== e.id);
|
|
2463
|
+
Z(n);
|
|
2490
2464
|
}, [
|
|
2491
2465
|
U,
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
]),
|
|
2495
|
-
U &&
|
|
2466
|
+
_e,
|
|
2467
|
+
Z
|
|
2468
|
+
]), Q = R((t) => {
|
|
2469
|
+
U && Z(t === !0 ? e.map((e) => e.id) : []);
|
|
2496
2470
|
}, [
|
|
2497
2471
|
U,
|
|
2498
|
-
|
|
2472
|
+
Z,
|
|
2499
2473
|
e
|
|
2500
2474
|
]), Ae = {
|
|
2501
|
-
selectedRows:
|
|
2502
|
-
selectedIds:
|
|
2475
|
+
selectedRows: K,
|
|
2476
|
+
selectedIds: _e,
|
|
2503
2477
|
allRows: e,
|
|
2504
|
-
selectedCount:
|
|
2478
|
+
selectedCount: K.length,
|
|
2505
2479
|
totalCount: e.length,
|
|
2506
2480
|
allRowsSelected: Te,
|
|
2507
|
-
clearSelection:
|
|
2508
|
-
setSelectedIds:
|
|
2509
|
-
}, je = x ||
|
|
2481
|
+
clearSelection: Oe,
|
|
2482
|
+
setSelectedIds: Z
|
|
2483
|
+
}, je = x || S ? /* @__PURE__ */ H(l, {
|
|
2510
2484
|
direction: "horizontal",
|
|
2511
2485
|
gap: "sm",
|
|
2512
2486
|
justify: "end",
|
|
2513
2487
|
className: "product-variants-bulk-table--header-actions",
|
|
2514
|
-
children: [!!
|
|
2488
|
+
children: [!!S && /* @__PURE__ */ V(s, {
|
|
2515
2489
|
type: "button",
|
|
2516
2490
|
tone: "secondary",
|
|
2517
2491
|
buttonStyle: "outline",
|
|
2518
|
-
onClick:
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
}), !!x && /* @__PURE__ */ R(s, {
|
|
2492
|
+
onClick: S,
|
|
2493
|
+
children: z.generateLabel
|
|
2494
|
+
}), !!x && /* @__PURE__ */ V(s, {
|
|
2522
2495
|
type: "button",
|
|
2523
2496
|
tone: "secondary",
|
|
2524
2497
|
buttonStyle: "ghost",
|
|
2525
2498
|
onClick: x,
|
|
2526
|
-
icon:
|
|
2527
|
-
children:
|
|
2499
|
+
icon: G,
|
|
2500
|
+
children: z.createLabel
|
|
2528
2501
|
})]
|
|
2529
|
-
}) : void 0, Me =
|
|
2502
|
+
}) : void 0, Me = Ce ? /* @__PURE__ */ H(l, {
|
|
2530
2503
|
direction: "horizontal",
|
|
2531
2504
|
gap: "md",
|
|
2532
2505
|
justify: "between",
|
|
2533
2506
|
className: "product-variants-bulk-table--bulk-toolbar rounded-radius bg-muted/45 px-space-lg py-space-md",
|
|
2534
|
-
children: [/* @__PURE__ */
|
|
2507
|
+
children: [/* @__PURE__ */ H(l, {
|
|
2535
2508
|
direction: "horizontal",
|
|
2536
2509
|
gap: "md",
|
|
2537
|
-
children: [/* @__PURE__ */
|
|
2510
|
+
children: [/* @__PURE__ */ V(o, {
|
|
2538
2511
|
size: "xs",
|
|
2539
2512
|
type: "secondary",
|
|
2540
|
-
children:
|
|
2541
|
-
}), !!
|
|
2513
|
+
children: z.selectedLabel(K.length, e.length)
|
|
2514
|
+
}), !!K.length && /* @__PURE__ */ V(s, {
|
|
2542
2515
|
type: "button",
|
|
2543
2516
|
tone: "secondary",
|
|
2544
2517
|
buttonStyle: "ghost",
|
|
2545
2518
|
size: "sm",
|
|
2546
|
-
onClick:
|
|
2547
|
-
children:
|
|
2519
|
+
onClick: Oe,
|
|
2520
|
+
children: z.clearSelectionLabel
|
|
2548
2521
|
})]
|
|
2549
|
-
}), /* @__PURE__ */
|
|
2522
|
+
}), /* @__PURE__ */ H(l, {
|
|
2550
2523
|
direction: "horizontal",
|
|
2551
2524
|
gap: "md",
|
|
2552
2525
|
justify: "end",
|
|
2553
2526
|
children: [
|
|
2554
|
-
!!k && /* @__PURE__ */
|
|
2527
|
+
!!k && /* @__PURE__ */ V(s, {
|
|
2555
2528
|
type: "button",
|
|
2556
2529
|
tone: "secondary",
|
|
2557
2530
|
buttonStyle: "solid",
|
|
2558
|
-
disabled: !
|
|
2559
|
-
onClick: () => k(
|
|
2531
|
+
disabled: !K.length,
|
|
2532
|
+
onClick: () => k(K),
|
|
2560
2533
|
className: "bg-background text-foreground hover:bg-background/80",
|
|
2561
|
-
children:
|
|
2534
|
+
children: z.bulkEditLabel
|
|
2562
2535
|
}),
|
|
2563
|
-
!!j && /* @__PURE__ */
|
|
2536
|
+
!!j && /* @__PURE__ */ H(s, {
|
|
2564
2537
|
type: "button",
|
|
2565
2538
|
tone: "secondary",
|
|
2566
2539
|
buttonStyle: "ghost",
|
|
2567
|
-
disabled: !
|
|
2568
|
-
onClick: () => j(
|
|
2569
|
-
icon: Z,
|
|
2540
|
+
disabled: !K.length,
|
|
2541
|
+
onClick: () => j(K),
|
|
2570
2542
|
className: "text-muted-foreground hover:text-destructive disabled:text-muted-foreground/55",
|
|
2571
2543
|
children: [
|
|
2572
|
-
|
|
2544
|
+
z.bulkDeleteLabel,
|
|
2573
2545
|
" (",
|
|
2574
|
-
|
|
2546
|
+
K.length,
|
|
2575
2547
|
")"
|
|
2576
2548
|
]
|
|
2577
2549
|
}),
|
|
2578
|
-
!!A && /* @__PURE__ */
|
|
2550
|
+
!!A && /* @__PURE__ */ V(s, {
|
|
2579
2551
|
type: "button",
|
|
2580
2552
|
tone: "secondary",
|
|
2581
2553
|
buttonStyle: "ghost",
|
|
2582
|
-
disabled: !
|
|
2583
|
-
onClick: () => A(
|
|
2554
|
+
disabled: !K.length,
|
|
2555
|
+
onClick: () => A(K),
|
|
2584
2556
|
className: "text-muted-foreground disabled:text-muted-foreground/55",
|
|
2585
|
-
children:
|
|
2557
|
+
children: z.bulkApplyLabel
|
|
2586
2558
|
}),
|
|
2587
|
-
|
|
2559
|
+
N?.(Ae)
|
|
2588
2560
|
]
|
|
2589
2561
|
})]
|
|
2590
|
-
}) : null, Ne = e.length === 0 ?
|
|
2591
|
-
title:
|
|
2592
|
-
description:
|
|
2593
|
-
action:
|
|
2562
|
+
}) : null, Ne = e.length === 0 ? oe ?? /* @__PURE__ */ V($, {
|
|
2563
|
+
title: z.emptyTitle,
|
|
2564
|
+
description: z.emptyDescription,
|
|
2565
|
+
action: S ? /* @__PURE__ */ V(s, {
|
|
2566
|
+
tone: "primary",
|
|
2594
2567
|
type: "button",
|
|
2595
|
-
onClick:
|
|
2596
|
-
|
|
2597
|
-
children: B.generateLabel
|
|
2568
|
+
onClick: S,
|
|
2569
|
+
children: z.generateLabel
|
|
2598
2570
|
}) : void 0
|
|
2599
|
-
}) : /* @__PURE__ */
|
|
2571
|
+
}) : /* @__PURE__ */ H(l, {
|
|
2600
2572
|
gap: "md",
|
|
2601
2573
|
className: "product-variants-bulk-table--body",
|
|
2602
|
-
children: [Me, /* @__PURE__ */
|
|
2574
|
+
children: [Me, /* @__PURE__ */ V("div", {
|
|
2603
2575
|
className: "product-variants-bulk-table--table overflow-hidden rounded-radius border border-border bg-background",
|
|
2604
|
-
children: /* @__PURE__ */
|
|
2576
|
+
children: /* @__PURE__ */ H(ie, {
|
|
2605
2577
|
containerClassName: "[scrollbar-gutter:stable] [scrollbar-width:thin] [&::-webkit-scrollbar]:h-2.5 [&::-webkit-scrollbar-thumb]:rounded-full [&::-webkit-scrollbar-thumb]:bg-border [&::-webkit-scrollbar-track]:bg-muted/40",
|
|
2606
2578
|
className: "w-full border-collapse",
|
|
2607
2579
|
children: [
|
|
2608
|
-
/* @__PURE__ */
|
|
2609
|
-
U && /* @__PURE__ */
|
|
2580
|
+
/* @__PURE__ */ H("colgroup", { children: [
|
|
2581
|
+
U && /* @__PURE__ */ V("col", {
|
|
2610
2582
|
className: "w-14 min-w-14 max-w-14",
|
|
2611
2583
|
style: { width: "3.5rem" }
|
|
2612
2584
|
}),
|
|
2613
|
-
J.has("variant") && /* @__PURE__ */
|
|
2614
|
-
J.has("sku") && /* @__PURE__ */
|
|
2615
|
-
J.has("price") && /* @__PURE__ */
|
|
2616
|
-
J.has("inventory") && /* @__PURE__ */
|
|
2617
|
-
J.has("status") && /* @__PURE__ */
|
|
2618
|
-
J.has("updated") && /* @__PURE__ */
|
|
2619
|
-
|
|
2585
|
+
J.has("variant") && /* @__PURE__ */ V("col", {}),
|
|
2586
|
+
J.has("sku") && /* @__PURE__ */ V("col", {}),
|
|
2587
|
+
J.has("price") && /* @__PURE__ */ V("col", {}),
|
|
2588
|
+
J.has("inventory") && /* @__PURE__ */ V("col", {}),
|
|
2589
|
+
J.has("status") && /* @__PURE__ */ V("col", {}),
|
|
2590
|
+
J.has("updated") && /* @__PURE__ */ V("col", {}),
|
|
2591
|
+
Ee && /* @__PURE__ */ V("col", { style: { width: "4.5rem" } })
|
|
2620
2592
|
] }),
|
|
2621
|
-
/* @__PURE__ */
|
|
2593
|
+
/* @__PURE__ */ V(re, { children: /* @__PURE__ */ H(ee, {
|
|
2622
2594
|
className: "h-12 border-b border-border/70 bg-muted/45",
|
|
2623
2595
|
children: [
|
|
2624
|
-
U && /* @__PURE__ */
|
|
2596
|
+
U && /* @__PURE__ */ V(ne, {
|
|
2625
2597
|
className: "w-14 min-w-14 max-w-14 px-0 py-space-md text-center align-middle",
|
|
2626
2598
|
style: { width: "3.5rem" },
|
|
2627
|
-
children: /* @__PURE__ */
|
|
2599
|
+
children: /* @__PURE__ */ V(T, {
|
|
2628
2600
|
checked: Te,
|
|
2629
|
-
onCheckedChange:
|
|
2630
|
-
"aria-label":
|
|
2601
|
+
onCheckedChange: Q,
|
|
2602
|
+
"aria-label": z.selectAllLabel,
|
|
2631
2603
|
className: "mx-auto"
|
|
2632
2604
|
})
|
|
2633
2605
|
}),
|
|
2634
|
-
J.has("variant") && /* @__PURE__ */
|
|
2606
|
+
J.has("variant") && /* @__PURE__ */ V(ne, {
|
|
2635
2607
|
className: "px-space-lg py-space-md text-left align-middle",
|
|
2636
|
-
children: /* @__PURE__ */
|
|
2608
|
+
children: /* @__PURE__ */ V(a, {
|
|
2637
2609
|
className: "whitespace-normal",
|
|
2638
|
-
children:
|
|
2610
|
+
children: z.headers.variant
|
|
2639
2611
|
})
|
|
2640
2612
|
}),
|
|
2641
|
-
J.has("sku") && /* @__PURE__ */
|
|
2613
|
+
J.has("sku") && /* @__PURE__ */ V(ne, {
|
|
2642
2614
|
className: "px-space-lg py-space-md text-left align-middle",
|
|
2643
|
-
children: /* @__PURE__ */
|
|
2615
|
+
children: /* @__PURE__ */ V(a, {
|
|
2644
2616
|
className: "whitespace-normal",
|
|
2645
|
-
children:
|
|
2617
|
+
children: z.headers.sku
|
|
2646
2618
|
})
|
|
2647
2619
|
}),
|
|
2648
|
-
J.has("price") && /* @__PURE__ */
|
|
2620
|
+
J.has("price") && /* @__PURE__ */ V(ne, {
|
|
2649
2621
|
className: "px-space-lg py-space-md text-left align-middle",
|
|
2650
|
-
children: /* @__PURE__ */
|
|
2622
|
+
children: /* @__PURE__ */ V(a, {
|
|
2651
2623
|
className: "whitespace-normal",
|
|
2652
|
-
children:
|
|
2624
|
+
children: z.headers.price
|
|
2653
2625
|
})
|
|
2654
2626
|
}),
|
|
2655
|
-
J.has("inventory") && /* @__PURE__ */
|
|
2627
|
+
J.has("inventory") && /* @__PURE__ */ V(ne, {
|
|
2656
2628
|
className: "px-space-lg py-space-md text-left align-middle",
|
|
2657
|
-
children: /* @__PURE__ */
|
|
2629
|
+
children: /* @__PURE__ */ V(a, {
|
|
2658
2630
|
className: "whitespace-normal",
|
|
2659
|
-
children:
|
|
2631
|
+
children: z.headers.inventory
|
|
2660
2632
|
})
|
|
2661
2633
|
}),
|
|
2662
|
-
J.has("status") && /* @__PURE__ */
|
|
2634
|
+
J.has("status") && /* @__PURE__ */ V(ne, {
|
|
2663
2635
|
className: "px-space-lg py-space-md text-left align-middle",
|
|
2664
|
-
children: /* @__PURE__ */
|
|
2636
|
+
children: /* @__PURE__ */ V(a, {
|
|
2665
2637
|
className: "whitespace-normal",
|
|
2666
|
-
children:
|
|
2638
|
+
children: z.headers.status
|
|
2667
2639
|
})
|
|
2668
2640
|
}),
|
|
2669
|
-
J.has("updated") && /* @__PURE__ */
|
|
2641
|
+
J.has("updated") && /* @__PURE__ */ V(ne, {
|
|
2670
2642
|
className: "px-space-lg py-space-md text-left align-middle",
|
|
2671
|
-
children: /* @__PURE__ */
|
|
2643
|
+
children: /* @__PURE__ */ V(a, {
|
|
2672
2644
|
className: "whitespace-normal",
|
|
2673
|
-
children:
|
|
2645
|
+
children: z.headers.updated
|
|
2674
2646
|
})
|
|
2675
2647
|
}),
|
|
2676
|
-
|
|
2648
|
+
Ee && /* @__PURE__ */ V(ne, {
|
|
2677
2649
|
className: "px-space-lg py-space-md text-right align-middle",
|
|
2678
|
-
children: /* @__PURE__ */
|
|
2650
|
+
children: /* @__PURE__ */ V(a, {
|
|
2679
2651
|
className: "whitespace-normal",
|
|
2680
|
-
children:
|
|
2652
|
+
children: z.headers.actions
|
|
2681
2653
|
})
|
|
2682
2654
|
})
|
|
2683
2655
|
]
|
|
2684
2656
|
}) }),
|
|
2685
|
-
/* @__PURE__ */
|
|
2686
|
-
let r =
|
|
2657
|
+
/* @__PURE__ */ V(te, { children: xe.map((e, n) => {
|
|
2658
|
+
let r = be.get(e.id) ?? n, i = Y ? Ot(e, Y) : null, a = n > 0 ? xe[n - 1] : void 0, s = Y && a ? Ot(a, Y) : null, c = !!Y && i !== s, f = ye.has(e.id), h = {
|
|
2687
2659
|
index: r,
|
|
2688
|
-
onSelect:
|
|
2689
|
-
onEdit:
|
|
2660
|
+
onSelect: C ? () => C(e) : void 0,
|
|
2661
|
+
onEdit: w ? () => w(e) : void 0,
|
|
2690
2662
|
onDuplicate: D ? () => D(e) : void 0,
|
|
2691
2663
|
onDelete: O ? () => O(e) : void 0,
|
|
2692
2664
|
isSelected: f,
|
|
2693
|
-
onToggleSelected: U ? (t) =>
|
|
2694
|
-
},
|
|
2665
|
+
onToggleSelected: U ? (t) => ke(e, t) : void 0
|
|
2666
|
+
}, g = Y ? t.filter((e) => e.id !== Y.id) : t, v = Et(e, g), x = Y ? Tt({
|
|
2695
2667
|
...e,
|
|
2696
2668
|
name: void 0
|
|
2697
|
-
},
|
|
2698
|
-
let a =
|
|
2669
|
+
}, g) : Tt(e, t), S = x === "-" && Y ? Tt(e, t) : x, E = Dt(v), k = E === Ct(S), A = (t, n, i = xt) => {
|
|
2670
|
+
let a = Mt(t) && y ? (i) => y(e, t, i, Pt(r, t, n, i)) : void 0, o = Mt(t) && b ? (i) => b(e, t, i, Pt(r, t, n, i)) : void 0;
|
|
2699
2671
|
return {
|
|
2700
2672
|
index: r,
|
|
2701
2673
|
column: t,
|
|
2702
2674
|
value: n,
|
|
2703
|
-
variantName:
|
|
2675
|
+
variantName: S,
|
|
2704
2676
|
optionValues: v,
|
|
2705
|
-
optionLabel:
|
|
2677
|
+
optionLabel: E,
|
|
2706
2678
|
cellDisplay: i,
|
|
2707
2679
|
onValueChange: a,
|
|
2708
2680
|
onBlur: o
|
|
@@ -2710,101 +2682,101 @@ function Bt({ variants: e = [], optionGroups: t = [], groupByOptionId: n, visibl
|
|
|
2710
2682
|
}, j = (t, n, r, i) => {
|
|
2711
2683
|
let a = A(t, n, r), o = m?.(e, a);
|
|
2712
2684
|
return o === void 0 ? i(a) : o;
|
|
2713
|
-
},
|
|
2685
|
+
}, N = u !== "none" && v.length > 0 && (Y ? !k : u === "tags" || !k), P = u === "none" ? null : p?.(e, {
|
|
2714
2686
|
optionGroups: t,
|
|
2715
2687
|
optionValues: v,
|
|
2716
|
-
optionLabel:
|
|
2688
|
+
optionLabel: E,
|
|
2717
2689
|
display: u
|
|
2718
|
-
}),
|
|
2719
|
-
...
|
|
2690
|
+
}), F = [
|
|
2691
|
+
...C ? [{
|
|
2720
2692
|
id: "view",
|
|
2721
|
-
label:
|
|
2722
|
-
icon: /* @__PURE__ */
|
|
2723
|
-
onClick: () =>
|
|
2693
|
+
label: z.viewLabel,
|
|
2694
|
+
icon: /* @__PURE__ */ V(he, { className: "size-icon-md" }),
|
|
2695
|
+
onClick: () => C(e),
|
|
2724
2696
|
tone: "secondary",
|
|
2725
2697
|
buttonStyle: "ghost"
|
|
2726
2698
|
}] : [],
|
|
2727
|
-
...
|
|
2699
|
+
...w ? [{
|
|
2728
2700
|
id: "edit",
|
|
2729
|
-
label:
|
|
2730
|
-
icon: /* @__PURE__ */
|
|
2731
|
-
onClick: () =>
|
|
2701
|
+
label: z.editLabel,
|
|
2702
|
+
icon: /* @__PURE__ */ V(W, { className: "size-icon-md" }),
|
|
2703
|
+
onClick: () => w(e),
|
|
2732
2704
|
tone: "secondary",
|
|
2733
2705
|
buttonStyle: "ghost"
|
|
2734
2706
|
}] : [],
|
|
2735
2707
|
...D ? [{
|
|
2736
2708
|
id: "duplicate",
|
|
2737
|
-
label:
|
|
2738
|
-
icon: /* @__PURE__ */
|
|
2709
|
+
label: z.duplicateLabel,
|
|
2710
|
+
icon: /* @__PURE__ */ V(me, { className: "size-icon-md" }),
|
|
2739
2711
|
onClick: () => D(e),
|
|
2740
2712
|
tone: "secondary",
|
|
2741
2713
|
buttonStyle: "ghost"
|
|
2742
2714
|
}] : [],
|
|
2743
2715
|
...O ? [{
|
|
2744
2716
|
id: "delete",
|
|
2745
|
-
label:
|
|
2746
|
-
icon: /* @__PURE__ */
|
|
2717
|
+
label: z.deleteLabel,
|
|
2718
|
+
icon: /* @__PURE__ */ V(q, { className: "size-icon-md" }),
|
|
2747
2719
|
onClick: () => O(e),
|
|
2748
2720
|
tone: "destructive"
|
|
2749
2721
|
}] : []
|
|
2750
2722
|
];
|
|
2751
|
-
return /* @__PURE__ */
|
|
2723
|
+
return /* @__PURE__ */ H(le, { children: [c && /* @__PURE__ */ V(ee, {
|
|
2752
2724
|
className: "product-variants-bulk-table--group-row border-b border-border/70 bg-muted/30",
|
|
2753
|
-
children: /* @__PURE__ */
|
|
2754
|
-
colSpan:
|
|
2725
|
+
children: /* @__PURE__ */ V(I, {
|
|
2726
|
+
colSpan: X,
|
|
2755
2727
|
className: "px-space-lg py-space-md align-middle",
|
|
2756
|
-
children: /* @__PURE__ */
|
|
2728
|
+
children: /* @__PURE__ */ H(l, {
|
|
2757
2729
|
direction: "horizontal",
|
|
2758
2730
|
gap: "sm",
|
|
2759
2731
|
wrap: !1,
|
|
2760
|
-
children: [/* @__PURE__ */
|
|
2732
|
+
children: [/* @__PURE__ */ V(o, {
|
|
2761
2733
|
tag: "span",
|
|
2762
2734
|
weight: "semibold",
|
|
2763
2735
|
className: "min-w-0 whitespace-normal break-words",
|
|
2764
2736
|
children: i
|
|
2765
|
-
}), /* @__PURE__ */
|
|
2737
|
+
}), /* @__PURE__ */ V(o, {
|
|
2766
2738
|
tag: "span",
|
|
2767
2739
|
size: "xs",
|
|
2768
2740
|
type: "secondary",
|
|
2769
2741
|
className: "whitespace-nowrap",
|
|
2770
|
-
children:
|
|
2742
|
+
children: z.groupCountLabel(Se.get(i ?? "") ?? 0)
|
|
2771
2743
|
})]
|
|
2772
2744
|
})
|
|
2773
2745
|
})
|
|
2774
|
-
}), /* @__PURE__ */
|
|
2746
|
+
}), /* @__PURE__ */ H(ee, {
|
|
2775
2747
|
className: "h-20 border-b border-border/70 last:border-b-0",
|
|
2776
2748
|
children: [
|
|
2777
|
-
U && /* @__PURE__ */
|
|
2749
|
+
U && /* @__PURE__ */ V(I, {
|
|
2778
2750
|
className: "w-14 min-w-14 max-w-14 px-0 py-space-lg text-center align-middle",
|
|
2779
2751
|
style: { width: "3.5rem" },
|
|
2780
|
-
children: /* @__PURE__ */
|
|
2752
|
+
children: /* @__PURE__ */ V(T, {
|
|
2781
2753
|
checked: f,
|
|
2782
|
-
onCheckedChange: (t) =>
|
|
2783
|
-
"aria-label":
|
|
2754
|
+
onCheckedChange: (t) => ke(e, t),
|
|
2755
|
+
"aria-label": z.selectRowLabel(r),
|
|
2784
2756
|
className: "mx-auto"
|
|
2785
2757
|
})
|
|
2786
2758
|
}),
|
|
2787
|
-
J.has("variant") && /* @__PURE__ */
|
|
2759
|
+
J.has("variant") && /* @__PURE__ */ V(I, {
|
|
2788
2760
|
className: "px-space-lg py-space-lg align-middle",
|
|
2789
|
-
children: j("variant",
|
|
2761
|
+
children: j("variant", S, xt, () => /* @__PURE__ */ H(l, {
|
|
2790
2762
|
gap: "xs",
|
|
2791
2763
|
children: [
|
|
2792
|
-
/* @__PURE__ */
|
|
2764
|
+
/* @__PURE__ */ V(o, {
|
|
2793
2765
|
weight: "medium",
|
|
2794
2766
|
className: "min-w-0 whitespace-normal break-words",
|
|
2795
|
-
children:
|
|
2767
|
+
children: S
|
|
2796
2768
|
}),
|
|
2797
|
-
|
|
2798
|
-
!
|
|
2769
|
+
P,
|
|
2770
|
+
!P && N && u === "text" && /* @__PURE__ */ V(o, {
|
|
2799
2771
|
size: "xs",
|
|
2800
2772
|
type: "secondary",
|
|
2801
2773
|
className: "min-w-0 whitespace-normal break-words",
|
|
2802
|
-
children: v.map((t, n) => /* @__PURE__ */
|
|
2774
|
+
children: v.map((t, n) => /* @__PURE__ */ H("span", { children: [n > 0 ? " / " : null, t] }, `${e.id}-option-text-${n}`))
|
|
2803
2775
|
}),
|
|
2804
|
-
!
|
|
2776
|
+
!P && N && u === "tags" && /* @__PURE__ */ V(l, {
|
|
2805
2777
|
direction: "horizontal",
|
|
2806
2778
|
gap: "xs",
|
|
2807
|
-
children: v.map((t, n) => /* @__PURE__ */
|
|
2779
|
+
children: v.map((t, n) => /* @__PURE__ */ V(_, {
|
|
2808
2780
|
size: "sm",
|
|
2809
2781
|
tone: "secondary",
|
|
2810
2782
|
className: "max-w-full",
|
|
@@ -2814,42 +2786,38 @@ function Bt({ variants: e = [], optionGroups: t = [], groupByOptionId: n, visibl
|
|
|
2814
2786
|
]
|
|
2815
2787
|
}))
|
|
2816
2788
|
}),
|
|
2817
|
-
J.has("sku") && /* @__PURE__ */
|
|
2789
|
+
J.has("sku") && /* @__PURE__ */ V(I, {
|
|
2818
2790
|
className: "px-space-lg py-space-md align-middle",
|
|
2819
|
-
children: j("sku", e.sku,
|
|
2791
|
+
children: j("sku", e.sku, Nt(d, "sku"), (t) => Ft(e.sku, `${z.headers.sku}: ${Ct(S)}`, t.cellDisplay, t.onValueChange, t.onBlur))
|
|
2820
2792
|
}),
|
|
2821
|
-
J.has("price") && /* @__PURE__ */
|
|
2793
|
+
J.has("price") && /* @__PURE__ */ V(I, {
|
|
2822
2794
|
className: "px-space-lg py-space-md align-middle",
|
|
2823
|
-
children: j("price", e.price,
|
|
2795
|
+
children: j("price", e.price, Nt(d, "price"), (t) => Ft(e.price, `${z.headers.price}: ${Ct(S)}`, t.cellDisplay, t.onValueChange, t.onBlur))
|
|
2824
2796
|
}),
|
|
2825
|
-
J.has("inventory") && /* @__PURE__ */
|
|
2797
|
+
J.has("inventory") && /* @__PURE__ */ V(I, {
|
|
2826
2798
|
className: "px-space-lg py-space-md align-middle",
|
|
2827
|
-
children: j("inventory", e.inventory,
|
|
2799
|
+
children: j("inventory", e.inventory, Nt(d, "inventory"), (t) => Ft(e.inventory, `${z.headers.inventory}: ${Ct(S)}`, t.cellDisplay, t.onValueChange, t.onBlur))
|
|
2828
2800
|
}),
|
|
2829
|
-
J.has("status") && /* @__PURE__ */
|
|
2801
|
+
J.has("status") && /* @__PURE__ */ V(I, {
|
|
2830
2802
|
className: "px-space-lg py-space-lg align-middle",
|
|
2831
|
-
children: j("status", e.status,
|
|
2803
|
+
children: j("status", e.status, xt, () => e.status ? /* @__PURE__ */ V(_, {
|
|
2832
2804
|
tone: e.statusTone ?? "secondary",
|
|
2833
2805
|
children: e.status
|
|
2834
|
-
}) : /* @__PURE__ */
|
|
2806
|
+
}) : /* @__PURE__ */ V(o, {
|
|
2835
2807
|
type: "secondary",
|
|
2836
2808
|
children: "-"
|
|
2837
2809
|
}))
|
|
2838
2810
|
}),
|
|
2839
|
-
J.has("updated") && /* @__PURE__ */
|
|
2811
|
+
J.has("updated") && /* @__PURE__ */ V(I, {
|
|
2840
2812
|
className: "px-space-lg py-space-lg align-middle",
|
|
2841
|
-
children: j("updated", e.updatedAt,
|
|
2842
|
-
size: "xs",
|
|
2843
|
-
type: "secondary",
|
|
2844
|
-
children: Pt(e.updatedAt)
|
|
2845
|
-
}))
|
|
2813
|
+
children: j("updated", e.updatedAt, xt, () => Ft(e.updatedAt, `${z.headers.updated}: ${Ct(S)}`, "text"))
|
|
2846
2814
|
}),
|
|
2847
|
-
|
|
2815
|
+
Ee && /* @__PURE__ */ V(I, {
|
|
2848
2816
|
className: "px-space-lg py-space-lg text-right align-middle",
|
|
2849
|
-
children:
|
|
2817
|
+
children: M ? M(e, h) : /* @__PURE__ */ V(ze, {
|
|
2850
2818
|
item: e,
|
|
2851
|
-
actions:
|
|
2852
|
-
menuLabel:
|
|
2819
|
+
actions: F,
|
|
2820
|
+
menuLabel: z.headers.actions
|
|
2853
2821
|
})
|
|
2854
2822
|
})
|
|
2855
2823
|
]
|
|
@@ -2859,167 +2827,168 @@ function Bt({ variants: e = [], optionGroups: t = [], groupByOptionId: n, visibl
|
|
|
2859
2827
|
})
|
|
2860
2828
|
})]
|
|
2861
2829
|
});
|
|
2862
|
-
return
|
|
2863
|
-
"aria-label":
|
|
2864
|
-
className: i("product-variants-bulk-table--component min-w-0",
|
|
2830
|
+
return se === "embedded" ? /* @__PURE__ */ V("section", {
|
|
2831
|
+
"aria-label": z.title,
|
|
2832
|
+
className: i("product-variants-bulk-table--component min-w-0", L),
|
|
2865
2833
|
children: Ne
|
|
2866
|
-
}) : /* @__PURE__ */
|
|
2867
|
-
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
actions: ae,
|
|
2834
|
+
}) : /* @__PURE__ */ V(E, {
|
|
2835
|
+
title: z.title,
|
|
2836
|
+
description: z.description,
|
|
2837
|
+
actions: P,
|
|
2871
2838
|
headerAction: je,
|
|
2872
|
-
headerEnd:
|
|
2873
|
-
footerSlot:
|
|
2874
|
-
|
|
2875
|
-
className: i("product-variants-bulk-table--component w-full", I),
|
|
2839
|
+
headerEnd: F,
|
|
2840
|
+
footerSlot: ae,
|
|
2841
|
+
className: i("product-variants-bulk-table--component w-full", L),
|
|
2876
2842
|
children: Ne
|
|
2877
2843
|
});
|
|
2878
2844
|
}
|
|
2879
|
-
|
|
2845
|
+
It.displayName = "ProductVariantsBulkTable";
|
|
2880
2846
|
//#endregion
|
|
2881
2847
|
//#region src/components/features/products/components/product-variants-manager.tsx
|
|
2882
|
-
function
|
|
2883
|
-
let { defaultScale:
|
|
2848
|
+
function Lt({ optionGroups: n = [], variants: a = [], visibleColumns: c, optionCombinationDisplay: d, cellDisplay: f, selectionMode: p, renderOptionCombination: m, renderCell: h, selectedVariantIds: g, defaultSelectedVariantIds: _, onSelectedVariantIdsChange: v, onVariantFieldChange: y, onVariantFieldBlur: b, collapsedOptionIds: x, defaultCollapsedOptionIds: S, onCollapsedOptionIdsChange: w, editingOptionId: T, defaultEditingOptionId: E, onEditingOptionIdChange: k, onCreateOption: A, onEditOption: j, onDeleteOption: M, onAddValue: N, onDeleteValue: P, onOptionNameChange: F, onValueLabelChange: ee, onDoneEditingOption: I, onSaveEditingOption: te, onCancelEditingOption: ne, onToggleUsedForVariants: re, renderOptionActions: ie, renderValue: ae, onCreateVariant: oe, onGenerateVariants: se, onSelectVariant: L, onEditVariant: ce, onDuplicateVariant: le, onDeleteVariant: z, onBulkEdit: de, onBulkApply: fe, onBulkDelete: pe, renderVariantActions: me, renderBulkActions: he, groupByOptionId: ge, defaultGroupByOptionId: W, onGroupByOptionIdChange: _e, onSearchVariants: K, onFilterVariants: q, controlsEnd: ye, actions: J, headerEnd: Y, footerSlot: be, surface: xe = "flat", padding: Se = xe === "flat" ? "none" : "md", headerDivider: Ce = xe !== "flat" && void 0, footerDivider: we = xe !== "flat" && void 0, className: Te, strings: Ee, optionsStrings: X, variantsStrings: Z }) {
|
|
2849
|
+
let { defaultScale: De } = t(), ke = e(void 0, De), Q = r(Oe, Ee), Ae = B(() => n.filter((e) => e.usedForVariants !== !1), [n]), je = Ae[0]?.id ?? null, $ = ge !== void 0, [Me, Ne] = ue(W ?? je), Pe = ge ?? Me ?? je, Fe = B(() => Ae.map((e) => ({
|
|
2884
2850
|
value: e.id,
|
|
2885
2851
|
label: String(typeof e.name == "string" || typeof e.name == "number" ? e.name : e.id)
|
|
2886
|
-
})), [
|
|
2852
|
+
})), [Ae]), Ie = R((e) => {
|
|
2887
2853
|
let t = n.find((t) => t.id === e);
|
|
2888
|
-
|
|
2854
|
+
$ || Ne(e ?? null), _e?.(e, t);
|
|
2889
2855
|
}, [
|
|
2890
|
-
|
|
2891
|
-
|
|
2856
|
+
$,
|
|
2857
|
+
_e,
|
|
2892
2858
|
n
|
|
2893
|
-
]),
|
|
2859
|
+
]), Le = se || oe ? /* @__PURE__ */ H(l, {
|
|
2894
2860
|
direction: "horizontal",
|
|
2895
2861
|
gap: "sm",
|
|
2896
2862
|
justify: "end",
|
|
2897
2863
|
className: "product-variants-manager--header-actions",
|
|
2898
|
-
children: [!!se && /* @__PURE__ */
|
|
2864
|
+
children: [!!se && /* @__PURE__ */ V(s, {
|
|
2899
2865
|
type: "button",
|
|
2900
2866
|
tone: "secondary",
|
|
2901
2867
|
buttonStyle: "outline",
|
|
2902
2868
|
onClick: se,
|
|
2903
|
-
icon: be,
|
|
2904
2869
|
children: Q.generateLabel
|
|
2905
|
-
}), !!oe && /* @__PURE__ */
|
|
2870
|
+
}), !!oe && /* @__PURE__ */ V(s, {
|
|
2906
2871
|
type: "button",
|
|
2907
2872
|
tone: "secondary",
|
|
2908
2873
|
buttonStyle: "outline",
|
|
2909
2874
|
onClick: oe,
|
|
2910
|
-
icon:
|
|
2875
|
+
icon: G,
|
|
2911
2876
|
children: Q.createVariantLabel
|
|
2912
2877
|
})]
|
|
2913
2878
|
}) : void 0;
|
|
2914
|
-
return /* @__PURE__ */
|
|
2879
|
+
return /* @__PURE__ */ V(u, {
|
|
2880
|
+
surface: xe,
|
|
2881
|
+
padding: Se,
|
|
2882
|
+
headerDivider: Ce,
|
|
2883
|
+
footerDivider: we,
|
|
2915
2884
|
title: Q.title,
|
|
2916
2885
|
description: Q.description,
|
|
2917
|
-
actions:
|
|
2886
|
+
actions: J,
|
|
2918
2887
|
actionsLabel: Q.actionsLabel,
|
|
2919
|
-
headerAction:
|
|
2920
|
-
headerEnd:
|
|
2921
|
-
footerSlot:
|
|
2922
|
-
|
|
2923
|
-
|
|
2924
|
-
|
|
2925
|
-
gap: "none",
|
|
2888
|
+
headerAction: Le,
|
|
2889
|
+
headerEnd: Y,
|
|
2890
|
+
footerSlot: be,
|
|
2891
|
+
className: i("product-variants-manager--component w-full", Te),
|
|
2892
|
+
children: /* @__PURE__ */ H(l, {
|
|
2893
|
+
gap: "2xl",
|
|
2926
2894
|
className: "product-variants-manager--body",
|
|
2927
|
-
children: [
|
|
2928
|
-
|
|
2929
|
-
|
|
2930
|
-
|
|
2931
|
-
|
|
2932
|
-
|
|
2933
|
-
|
|
2934
|
-
|
|
2935
|
-
|
|
2936
|
-
|
|
2937
|
-
|
|
2938
|
-
|
|
2939
|
-
|
|
2940
|
-
|
|
2941
|
-
|
|
2942
|
-
|
|
2943
|
-
|
|
2944
|
-
|
|
2945
|
-
|
|
2946
|
-
|
|
2947
|
-
|
|
2948
|
-
|
|
2949
|
-
|
|
2950
|
-
|
|
2951
|
-
|
|
2952
|
-
|
|
2953
|
-
|
|
2954
|
-
|
|
2955
|
-
|
|
2956
|
-
|
|
2957
|
-
|
|
2958
|
-
|
|
2959
|
-
|
|
2960
|
-
|
|
2961
|
-
|
|
2962
|
-
|
|
2963
|
-
|
|
2964
|
-
|
|
2895
|
+
children: [/* @__PURE__ */ V("section", {
|
|
2896
|
+
className: "product-variants-manager--options min-w-0",
|
|
2897
|
+
children: /* @__PURE__ */ V(rt, {
|
|
2898
|
+
optionGroups: n,
|
|
2899
|
+
collapsedOptionIds: x,
|
|
2900
|
+
defaultCollapsedOptionIds: S,
|
|
2901
|
+
onCollapsedOptionIdsChange: w,
|
|
2902
|
+
editingOptionId: T,
|
|
2903
|
+
defaultEditingOptionId: E,
|
|
2904
|
+
onEditingOptionIdChange: k,
|
|
2905
|
+
surface: "embedded",
|
|
2906
|
+
onCreateOption: A,
|
|
2907
|
+
onEditOption: j,
|
|
2908
|
+
onDeleteOption: M,
|
|
2909
|
+
onAddValue: N,
|
|
2910
|
+
onDeleteValue: P,
|
|
2911
|
+
onOptionNameChange: F,
|
|
2912
|
+
onValueLabelChange: ee,
|
|
2913
|
+
onDoneEditingOption: I,
|
|
2914
|
+
onSaveEditingOption: te,
|
|
2915
|
+
onCancelEditingOption: ne,
|
|
2916
|
+
onToggleUsedForVariants: re,
|
|
2917
|
+
renderOptionActions: ie,
|
|
2918
|
+
renderValue: ae,
|
|
2919
|
+
showHeader: !1,
|
|
2920
|
+
showCollapseControls: !1,
|
|
2921
|
+
showInlineActions: !1,
|
|
2922
|
+
showVariantToggle: !1,
|
|
2923
|
+
strings: {
|
|
2924
|
+
title: Q.optionsTitle,
|
|
2925
|
+
...X
|
|
2926
|
+
}
|
|
2927
|
+
})
|
|
2928
|
+
}), /* @__PURE__ */ H(l, {
|
|
2929
|
+
gap: "md",
|
|
2930
|
+
className: "product-variants-manager--variants-region",
|
|
2931
|
+
children: [/* @__PURE__ */ V("div", {
|
|
2932
|
+
className: "product-variants-manager--controls",
|
|
2933
|
+
children: /* @__PURE__ */ H(l, {
|
|
2965
2934
|
direction: "horizontal",
|
|
2966
2935
|
gap: "md",
|
|
2967
2936
|
justify: "between",
|
|
2968
|
-
children: [/* @__PURE__ */
|
|
2937
|
+
children: [/* @__PURE__ */ H(l, {
|
|
2969
2938
|
direction: "horizontal",
|
|
2970
2939
|
gap: "sm",
|
|
2971
2940
|
wrap: !1,
|
|
2972
2941
|
className: "product-variants-manager--group-by",
|
|
2973
|
-
children: [/* @__PURE__ */
|
|
2942
|
+
children: [/* @__PURE__ */ V(o, {
|
|
2974
2943
|
type: "secondary",
|
|
2975
2944
|
className: "whitespace-nowrap",
|
|
2976
2945
|
children: Q.groupByLabel
|
|
2977
|
-
}),
|
|
2978
|
-
options:
|
|
2979
|
-
value:
|
|
2980
|
-
onValueChange:
|
|
2946
|
+
}), Fe.length > 0 && /* @__PURE__ */ V(C, {
|
|
2947
|
+
options: Fe,
|
|
2948
|
+
value: Pe,
|
|
2949
|
+
onValueChange: Ie,
|
|
2981
2950
|
"aria-label": Q.groupByLabel,
|
|
2982
2951
|
className: "min-w-32 bg-background"
|
|
2983
2952
|
})]
|
|
2984
|
-
}), /* @__PURE__ */
|
|
2953
|
+
}), /* @__PURE__ */ H(l, {
|
|
2985
2954
|
direction: "horizontal",
|
|
2986
2955
|
gap: "sm",
|
|
2987
2956
|
justify: "end",
|
|
2988
2957
|
wrap: !1,
|
|
2989
2958
|
className: "product-variants-manager--controls-end",
|
|
2990
|
-
children: [/* @__PURE__ */
|
|
2991
|
-
className: i("product-variants-manager--tool-buttons bg-background shadow-xs",
|
|
2992
|
-
children: [/* @__PURE__ */
|
|
2959
|
+
children: [/* @__PURE__ */ H("div", {
|
|
2960
|
+
className: i("product-variants-manager--tool-buttons bg-background shadow-xs", D.joinedFrame, O[ke]),
|
|
2961
|
+
children: [/* @__PURE__ */ H(s, {
|
|
2993
2962
|
type: "button",
|
|
2994
2963
|
size: "sm",
|
|
2995
2964
|
iconOnly: !0,
|
|
2996
2965
|
tone: "secondary",
|
|
2997
2966
|
buttonStyle: "ghost",
|
|
2998
|
-
onClick:
|
|
2967
|
+
onClick: K,
|
|
2999
2968
|
"aria-label": Q.searchLabel,
|
|
3000
|
-
className: i(
|
|
3001
|
-
children: [/* @__PURE__ */
|
|
2969
|
+
className: i(D.joinedItem, D.firstItem, "border-r border-border text-muted-foreground hover:text-foreground"),
|
|
2970
|
+
children: [/* @__PURE__ */ V(ve, {
|
|
3002
2971
|
className: "size-icon-sm",
|
|
3003
2972
|
"aria-hidden": "true"
|
|
3004
|
-
}), /* @__PURE__ */
|
|
2973
|
+
}), /* @__PURE__ */ V(o, {
|
|
3005
2974
|
tag: "span",
|
|
3006
2975
|
size: "pxs",
|
|
3007
2976
|
className: "sr-only",
|
|
3008
2977
|
children: Q.searchLabel
|
|
3009
2978
|
})]
|
|
3010
|
-
}), /* @__PURE__ */
|
|
2979
|
+
}), /* @__PURE__ */ H(s, {
|
|
3011
2980
|
type: "button",
|
|
3012
2981
|
size: "sm",
|
|
3013
2982
|
iconOnly: !0,
|
|
3014
2983
|
tone: "secondary",
|
|
3015
2984
|
buttonStyle: "ghost",
|
|
3016
|
-
onClick:
|
|
2985
|
+
onClick: q,
|
|
3017
2986
|
"aria-label": Q.filterLabel,
|
|
3018
|
-
className: i(
|
|
3019
|
-
children: [/* @__PURE__ */
|
|
2987
|
+
className: i(D.joinedItem, D.lastItem, "text-muted-foreground hover:text-foreground"),
|
|
2988
|
+
children: [/* @__PURE__ */ V(U, {
|
|
3020
2989
|
className: "size-icon-sm",
|
|
3021
2990
|
"aria-hidden": "true"
|
|
3022
|
-
}), /* @__PURE__ */
|
|
2991
|
+
}), /* @__PURE__ */ V(o, {
|
|
3023
2992
|
tag: "span",
|
|
3024
2993
|
size: "pxs",
|
|
3025
2994
|
className: "sr-only",
|
|
@@ -3029,49 +2998,48 @@ function Vt({ optionGroups: n = [], variants: o = [], visibleColumns: c, optionC
|
|
|
3029
2998
|
}), ye]
|
|
3030
2999
|
})]
|
|
3031
3000
|
})
|
|
3032
|
-
}),
|
|
3033
|
-
|
|
3034
|
-
|
|
3035
|
-
|
|
3036
|
-
variants: o,
|
|
3001
|
+
}), /* @__PURE__ */ V("section", {
|
|
3002
|
+
className: "product-variants-manager--variants min-w-0",
|
|
3003
|
+
children: /* @__PURE__ */ V(It, {
|
|
3004
|
+
variants: a,
|
|
3037
3005
|
optionGroups: n,
|
|
3038
|
-
groupByOptionId:
|
|
3006
|
+
groupByOptionId: Pe,
|
|
3039
3007
|
visibleColumns: c,
|
|
3040
|
-
optionCombinationDisplay:
|
|
3041
|
-
cellDisplay:
|
|
3042
|
-
selectionMode:
|
|
3043
|
-
renderOptionCombination:
|
|
3044
|
-
renderCell:
|
|
3008
|
+
optionCombinationDisplay: d,
|
|
3009
|
+
cellDisplay: f,
|
|
3010
|
+
selectionMode: p,
|
|
3011
|
+
renderOptionCombination: m,
|
|
3012
|
+
renderCell: h,
|
|
3045
3013
|
surface: "embedded",
|
|
3046
|
-
selectedVariantIds:
|
|
3047
|
-
defaultSelectedVariantIds:
|
|
3048
|
-
onSelectedVariantIdsChange:
|
|
3049
|
-
onVariantFieldChange:
|
|
3050
|
-
onVariantFieldBlur:
|
|
3014
|
+
selectedVariantIds: g,
|
|
3015
|
+
defaultSelectedVariantIds: _,
|
|
3016
|
+
onSelectedVariantIdsChange: v,
|
|
3017
|
+
onVariantFieldChange: y,
|
|
3018
|
+
onVariantFieldBlur: b,
|
|
3051
3019
|
onCreateVariant: oe,
|
|
3052
3020
|
onGenerateVariants: se,
|
|
3053
|
-
onSelectVariant:
|
|
3054
|
-
onEditVariant:
|
|
3055
|
-
onDuplicateVariant:
|
|
3056
|
-
onDeleteVariant:
|
|
3057
|
-
onBulkEdit:
|
|
3058
|
-
onBulkApply:
|
|
3059
|
-
onBulkDelete:
|
|
3060
|
-
renderVariantActions:
|
|
3061
|
-
renderBulkActions:
|
|
3021
|
+
onSelectVariant: L,
|
|
3022
|
+
onEditVariant: ce,
|
|
3023
|
+
onDuplicateVariant: le,
|
|
3024
|
+
onDeleteVariant: z,
|
|
3025
|
+
onBulkEdit: de,
|
|
3026
|
+
onBulkApply: fe,
|
|
3027
|
+
onBulkDelete: pe,
|
|
3028
|
+
renderVariantActions: me,
|
|
3029
|
+
renderBulkActions: he,
|
|
3062
3030
|
strings: {
|
|
3063
3031
|
title: Q.variantsTitle,
|
|
3064
3032
|
generateLabel: Q.generateLabel,
|
|
3065
3033
|
...Z
|
|
3066
3034
|
}
|
|
3067
3035
|
})
|
|
3068
|
-
})
|
|
3069
|
-
]
|
|
3036
|
+
})]
|
|
3037
|
+
})]
|
|
3070
3038
|
})
|
|
3071
3039
|
});
|
|
3072
3040
|
}
|
|
3073
|
-
|
|
3041
|
+
Lt.displayName = "ProductVariantsManager";
|
|
3074
3042
|
//#endregion
|
|
3075
|
-
export {
|
|
3043
|
+
export { Ye as ProductContractOverview, Xe as ProductDetailsCard, Qe as ProductOperationsCard, Ze as ProductOptionActionMenu, rt as ProductOptionsMatrix, it as ProductOptionsSummary, ft as ProductOverview, at as ProductPoliciesCard, ot as ProductQuotePreviewCard, st as ProductReadinessCard, ct as ProductStructureCard, pt as ProductVariantActionMenu, gt as ProductVariantDetails, vt as ProductVariantEditor, It as ProductVariantsBulkTable, Lt as ProductVariantsManager, dt as ProductVariantsTable, Se as defaultProductContractOverviewStrings, xe as defaultProductDetailsCardStrings, be as defaultProductOperationsCardStrings, we as defaultProductOptionActionMenuStrings, Te as defaultProductOptionsMatrixStrings, Ce as defaultProductOptionsSummaryStrings, je as defaultProductOverviewStrings, X as defaultProductPoliciesCardStrings, Ee as defaultProductQuotePreviewCardStrings, J as defaultProductReadinessCardStrings, Y as defaultProductStructureCardStrings, ke as defaultProductVariantActionMenuStrings, Q as defaultProductVariantDetailsStrings, Ae as defaultProductVariantEditorStrings, De as defaultProductVariantsBulkTableStrings, Oe as defaultProductVariantsManagerStrings, Z as defaultProductVariantsTableStrings };
|
|
3076
3044
|
|
|
3077
3045
|
//# sourceMappingURL=products.js.map
|