themelia-react-ui 2.0.0 → 2.0.2
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 +527 -0
- package/README.md +47 -14
- package/THIRD_PARTY_NOTICES.md +13 -0
- package/dist/accordion-Cjb6sx0G.js +208 -0
- package/dist/accordion-Cjb6sx0G.js.map +1 -0
- package/dist/action-menu-CllU52Mm.js +280 -0
- package/dist/action-menu-CllU52Mm.js.map +1 -0
- package/dist/affordance-geometry.generated-tF36bREk.js +140 -0
- package/dist/affordance-geometry.generated-tF36bREk.js.map +1 -0
- package/dist/ai-artifact-DvTwDVyL.js +1148 -0
- package/dist/ai-artifact-DvTwDVyL.js.map +1 -0
- package/dist/{app-shell-BE_j8-AT.js → app-shell-C4FhvCqF.js} +5 -5
- package/dist/{app-shell-BE_j8-AT.js.map → app-shell-C4FhvCqF.js.map} +1 -1
- package/dist/attachment-BxDfL2mw.js +246 -0
- package/dist/attachment-BxDfL2mw.js.map +1 -0
- package/dist/{auth-M3vGMgDR.js → auth-ax2BqjrI.js} +241 -235
- package/dist/auth-ax2BqjrI.js.map +1 -0
- package/dist/{avatar-djdaaQ_s.js → avatar-DAPlDvhJ.js} +67 -66
- package/dist/avatar-DAPlDvhJ.js.map +1 -0
- package/dist/badge-HpFqoqSY.js +93 -0
- package/dist/badge-HpFqoqSY.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/batch-action-bar.js +3 -0
- package/dist/base/buttons.js +2 -3
- package/dist/base/cards.js +2 -2
- package/dist/base/carousel.js +50 -46
- package/dist/base/carousel.js.map +1 -1
- package/dist/base/cascader.js +69 -81
- package/dist/base/cascader.js.map +1 -1
- package/dist/base/chart.js +1 -1
- package/dist/base/choice-inputs.js +3 -3
- package/dist/base/code-block.js +1 -1
- package/dist/base/combobox.js +2 -2
- 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 +7 -7
- 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 +20 -20
- 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/metadata-list.js +3 -0
- package/dist/base/navigation.js +7 -7
- package/dist/base/popover-menu.js +1 -1
- package/dist/base/popover.js +1 -1
- package/dist/base/qr-code.js +1 -1
- package/dist/base/repeaters.js +216 -220
- 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 +147 -137
- package/dist/base/signature-pad.js.map +1 -1
- package/dist/base/skeleton.js +1 -1
- package/dist/base/spinner.js +79 -2
- package/dist/base/spinner.js.map +1 -0
- 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 +46 -45
- 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 +2 -2
- package/dist/batch-action-bar-DnUJ21NQ.js +105 -0
- package/dist/batch-action-bar-DnUJ21NQ.js.map +1 -0
- package/dist/blocks/admin.js +171 -169
- package/dist/blocks/admin.js.map +1 -1
- package/dist/blocks/ai.js +308 -285
- package/dist/blocks/ai.js.map +1 -1
- package/dist/blocks/analytics/usage-card.js +1 -1
- package/dist/blocks/analytics.js +626 -589
- 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 +2051 -1329
- package/dist/blocks/commerce.js.map +1 -1
- package/dist/blocks/data-display.js +3 -2
- package/dist/blocks/onboarding.js +68 -58
- package/dist/blocks/onboarding.js.map +1 -1
- package/dist/blocks/planning.js +27 -26
- package/dist/blocks/planning.js.map +1 -1
- package/dist/blocks/timelines.js +1 -1
- package/dist/breadcrumbs-C-oqs1sQ.js +129 -0
- package/dist/breadcrumbs-C-oqs1sQ.js.map +1 -0
- package/dist/{button-R9CCoH7A.js → button-DVzspB_G.js} +15 -14
- package/dist/button-DVzspB_G.js.map +1 -0
- package/dist/{button-BS3KDg00.js → buttons-DPZekJFu.js} +208 -216
- package/dist/buttons-DPZekJFu.js.map +1 -0
- package/dist/cards-BaBZR-AU.js +68 -0
- package/dist/cards-BaBZR-AU.js.map +1 -0
- package/dist/{chart-DwYRKKc-.js → chart-ZOYyK2xG.js} +58 -55
- package/dist/chart-ZOYyK2xG.js.map +1 -0
- package/dist/checkbox-AWIhNhmo.js +36 -0
- package/dist/checkbox-AWIhNhmo.js.map +1 -0
- package/dist/choice-inputs-CNHvARCJ.js +770 -0
- package/dist/choice-inputs-CNHvARCJ.js.map +1 -0
- package/dist/code-block-DeneBJR_.js +185 -0
- package/dist/code-block-DeneBJR_.js.map +1 -0
- package/dist/{collapsible-oMUGM4tr.js → collapsible-C-_l4hpy.js} +4 -4
- package/dist/{collapsible-oMUGM4tr.js.map → collapsible-C-_l4hpy.js.map} +1 -1
- package/dist/{collection-content-Ys-OZOkY.js → collection-content-By56pLog.js} +3 -3
- package/dist/{collection-content-Ys-OZOkY.js.map → collection-content-By56pLog.js.map} +1 -1
- package/dist/combobox-C0EQW6dr.js +875 -0
- package/dist/combobox-C0EQW6dr.js.map +1 -0
- package/dist/combobox-xCQ2RMNE.js +309 -0
- package/dist/combobox-xCQ2RMNE.js.map +1 -0
- package/dist/{command-kPMPjIxJ.js → command-C25VMRII.js} +7 -7
- package/dist/{command-kPMPjIxJ.js.map → command-C25VMRII.js.map} +1 -1
- package/dist/{comments-You0Bzbr.js → comments-BYYlTA8E.js} +390 -379
- package/dist/comments-BYYlTA8E.js.map +1 -0
- package/dist/components/base/action-menu/action-menu.d.ts +21 -4
- package/dist/components/base/action-menu/action-menu.recipes.d.ts +21 -0
- package/dist/components/base/action-menu/index.d.ts +1 -0
- package/dist/components/base/badge/badge.recipes.d.ts +5 -5
- package/dist/components/base/batch-action-bar/batch-action-bar.d.ts +50 -0
- package/dist/components/base/batch-action-bar/batch-action-bar.strings.d.ts +20 -0
- package/dist/components/base/batch-action-bar/index.d.ts +8 -0
- package/dist/components/base/buttons/button-group.recipes.d.ts +1 -1
- package/dist/components/base/buttons/button.recipes.d.ts +2 -2
- package/dist/components/base/buttons/loader-button.d.ts +2 -1
- package/dist/components/base/cards/card.recipes.d.ts +2 -3
- package/dist/components/base/cards/partials/smart-card-skeleton.d.ts +3 -13
- package/dist/components/base/cards/smart-card.types.d.ts +11 -4
- package/dist/components/base/chart/chart.d.ts +2 -5
- package/dist/components/base/choice-inputs/checkbox.d.ts +2 -2
- package/dist/components/base/choice-inputs/choice-types.d.ts +18 -6
- package/dist/components/base/combobox/combobox.strings.d.ts +7 -0
- package/dist/components/base/combobox/index.d.ts +30 -4
- package/dist/components/base/display/alert-dialog.d.ts +6 -5
- package/dist/components/base/display/dialog.d.ts +4 -8
- package/dist/components/base/display/icon-badge/icon-badge.d.ts +1 -1
- package/dist/components/base/forms/form-sizing.d.ts +26 -15
- package/dist/components/base/metadata-list/index.d.ts +12 -0
- package/dist/components/{blocks/data-display/metadata → base/metadata-list}/metadata-list.d.ts +28 -25
- package/dist/components/{blocks/data-display/metadata → base/metadata-list}/metadata-value.d.ts +2 -2
- package/dist/components/base/navigation/index.d.ts +1 -1
- package/dist/components/base/navigation/page-header/index.d.ts +1 -0
- package/dist/components/base/navigation/page-header/page-header-commands.d.ts +73 -0
- package/dist/components/base/navigation/page-header/page-header.d.ts +26 -3
- package/dist/components/base/navigation/pagination.d.ts +5 -2
- package/dist/components/base/popover/popover.recipes.d.ts +15 -1
- package/dist/components/base/sheet/sheet.d.ts +4 -8
- package/dist/components/base/signature-pad/signature-pad.types.d.ts +5 -1
- package/dist/components/base/signature-pad/signature-pad.utils.d.ts +11 -3
- package/dist/components/base/table/index.d.ts +9 -2
- package/dist/components/base/text-inputs/field-clear-button.d.ts +6 -0
- package/dist/components/base/text-inputs/input-group.d.ts +2 -2
- package/dist/components/base/upload/upload.recipes.d.ts +25 -3
- package/dist/components/base/value-inputs/index.d.ts +5 -5
- package/dist/components/base/value-inputs/tags-input.d.ts +36 -12
- package/dist/components/blocks/ai/ai-shimmer/ai-shimmer.d.ts +1 -1
- package/dist/components/blocks/ai/ai-shimmer/types.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 +2 -1
- package/dist/components/blocks/commerce/cart-summary/cart-summary.d.ts +3 -1
- package/dist/components/blocks/commerce/cart-summary/index.d.ts +2 -2
- package/dist/components/blocks/commerce/cart-summary/types.d.ts +6 -1
- package/dist/components/blocks/commerce/discount-stack/discount-stack.d.ts +3 -1
- package/dist/components/blocks/commerce/discount-stack/index.d.ts +2 -2
- package/dist/components/blocks/commerce/discount-stack/types.d.ts +16 -4
- package/dist/components/blocks/commerce/fulfillment-group/fulfillment-group.d.ts +5 -0
- package/dist/components/blocks/commerce/fulfillment-group/index.d.ts +2 -0
- package/dist/components/blocks/commerce/fulfillment-group/types.d.ts +45 -0
- package/dist/components/blocks/commerce/index.d.ts +13 -5
- package/dist/components/blocks/commerce/invoice-header/invoice-header.d.ts +1 -1
- package/dist/components/blocks/commerce/invoice-header/types.d.ts +4 -2
- package/dist/components/blocks/commerce/invoice-mini/invoice-mini.d.ts +1 -1
- package/dist/components/blocks/commerce/invoice-mini/types.d.ts +2 -1
- package/dist/components/blocks/commerce/order-customer/index.d.ts +2 -0
- package/dist/components/blocks/commerce/order-customer/order-customer.d.ts +5 -0
- package/dist/components/blocks/commerce/order-customer/types.d.ts +48 -0
- package/dist/components/blocks/commerce/order-header/index.d.ts +2 -0
- package/dist/components/blocks/commerce/order-header/order-header.d.ts +5 -0
- package/dist/components/blocks/commerce/order-header/types.d.ts +37 -0
- package/dist/components/blocks/commerce/order-line-item/index.d.ts +2 -0
- package/dist/components/blocks/commerce/order-line-item/order-line-item.d.ts +5 -0
- package/dist/components/blocks/commerce/order-line-item/types.d.ts +46 -0
- package/dist/components/blocks/commerce/order-summary/index.d.ts +2 -0
- package/dist/components/blocks/commerce/order-summary/order-summary.d.ts +5 -0
- package/dist/components/blocks/commerce/order-summary/types.d.ts +42 -0
- package/dist/components/blocks/commerce/order-transactions/index.d.ts +2 -0
- package/dist/components/blocks/commerce/order-transactions/order-transactions.d.ts +5 -0
- package/dist/components/blocks/commerce/order-transactions/types.d.ts +46 -0
- package/dist/components/blocks/commerce/payment-method/index.d.ts +2 -2
- package/dist/components/blocks/commerce/payment-method/payment-method.d.ts +9 -1
- package/dist/components/blocks/commerce/payment-method/types.d.ts +12 -1
- package/dist/components/blocks/commerce/refund-status/index.d.ts +2 -2
- package/dist/components/blocks/commerce/refund-status/refund-status.d.ts +3 -1
- package/dist/components/blocks/commerce/refund-status/types.d.ts +6 -3
- package/dist/components/blocks/commerce/shared/address-lines.d.ts +21 -0
- package/dist/components/blocks/commerce/shared/line-thumbnail.d.ts +9 -0
- package/dist/components/blocks/commerce/shared/order-status.d.ts +51 -0
- package/dist/components/blocks/commerce/shipment-tracking/shipment-tracking.d.ts +1 -1
- package/dist/components/blocks/commerce/shipment-tracking/types.d.ts +27 -6
- package/dist/components/blocks/commerce/summary-panel/amount-row.d.ts +2 -0
- package/dist/components/blocks/commerce/summary-panel/index.d.ts +3 -0
- package/dist/components/blocks/commerce/summary-panel/summary-panel.d.ts +2 -0
- package/dist/components/blocks/commerce/summary-panel/types.d.ts +26 -0
- package/dist/components/blocks/commerce/tax-breakdown/tax-breakdown.d.ts +1 -1
- package/dist/components/blocks/commerce/tax-breakdown/types.d.ts +2 -1
- package/dist/components/blocks/data-display/inline-stat/inline-stat.d.ts +16 -8
- package/dist/components/blocks/data-display/metadata/index.d.ts +30 -4
- package/dist/components/features/activities/partials/activity-marker.d.ts +6 -3
- package/dist/components/features/activities/partials/activity-row.d.ts +6 -2
- package/dist/components/features/activities/partials/tone-tokens.d.ts +0 -6
- package/dist/components/features/appointment-calendar/appointment-calendar.d.ts +5 -0
- package/dist/components/features/appointment-calendar/appointment-calendar.types.d.ts +220 -0
- package/dist/components/features/appointment-calendar/appointment-calendar.utils.d.ts +41 -0
- package/dist/components/features/appointment-calendar/index.d.ts +3 -0
- package/dist/components/features/appointment-calendar/partials/appointment-agenda.d.ts +32 -0
- package/dist/components/features/appointment-calendar/partials/appointment-month.d.ts +13 -0
- package/dist/components/features/combobox/combobox.strings.d.ts +15 -1
- package/dist/components/features/combobox/types.d.ts +4 -0
- package/dist/components/features/global-search/partials/global-search-group-heading.d.ts +15 -0
- package/dist/components/features/global-search/partials/tone-palettes.d.ts +0 -5
- package/dist/components/features/kanban/kanban.d.ts +1 -1
- package/dist/components/features/kanban/kanban.strings.d.ts +1 -1
- package/dist/components/features/kanban/kanban.types.d.ts +2 -2
- package/dist/components/features/media-library/hooks/use-media-library.d.ts +1 -1
- package/dist/components/features/media-library/index.d.ts +1 -1
- package/dist/components/features/media-library/media-library.d.ts +1 -1
- package/dist/components/features/media-library/media-library.strings.d.ts +6 -0
- package/dist/components/features/media-library/media-library.types.d.ts +74 -1
- package/dist/components/features/media-library/partials/media-library-partials.d.ts +3 -3
- package/dist/components/features/mentions/partials/mention-kind-toggles.d.ts +16 -0
- package/dist/components/features/overlays/alert-dialog.d.ts +1 -1
- package/dist/components/features/overlays/dialog.d.ts +1 -1
- package/dist/components/features/overlays/index.d.ts +1 -1
- package/dist/components/features/overlays/overlay-tone-icon.d.ts +3 -3
- package/dist/components/features/overlays/overlays.types.d.ts +20 -0
- package/dist/components/features/products/components/product-contract-overview.d.ts +5 -0
- package/dist/components/features/products/components/product-details-card.d.ts +5 -0
- package/dist/components/features/products/components/product-operations-card.d.ts +5 -0
- package/dist/components/features/products/components/product-option-action-menu.d.ts +5 -0
- package/dist/components/features/products/components/product-options-summary.d.ts +5 -0
- package/dist/components/features/products/components/product-policies-card.d.ts +5 -0
- package/dist/components/features/products/components/product-quote-preview-card.d.ts +5 -0
- package/dist/components/features/products/components/product-readiness-card.d.ts +5 -0
- package/dist/components/features/products/components/product-structure-card.d.ts +5 -0
- package/dist/components/features/products/components/product-variant-action-menu.d.ts +23 -1
- package/dist/components/features/products/products.types.d.ts +9 -2
- package/dist/components/features/resource/index.d.ts +1 -1
- package/dist/components/features/resource/resource.d.ts +1 -1
- package/dist/components/features/resource/resource.types.d.ts +34 -6
- package/dist/components/features/rich-text-editor/index.d.ts +2 -1
- package/dist/components/features/rich-text-editor/partials/image-nodes.d.ts +13 -0
- package/dist/components/features/rich-text-editor/partials/image-uploads.d.ts +66 -0
- package/dist/components/features/rich-text-editor/partials/inline-reference-node.d.ts +19 -0
- package/dist/components/features/rich-text-editor/rich-text-editor.recipes.d.ts +7 -1
- package/dist/components/features/rich-text-editor/rich-text-editor.strings.d.ts +14 -0
- package/dist/components/features/rich-text-editor/rich-text-editor.types.d.ts +54 -1
- package/dist/components/features/rich-text-editor/use-rich-text-images.d.ts +18 -0
- package/dist/components/features/sync/index.d.ts +26 -3
- package/dist/components/features/table/data-table.d.ts +1 -1
- package/dist/components/features/table/table-header.d.ts +1 -1
- package/dist/components/features/table/table.strings.d.ts +55 -1
- package/dist/components/features/table/table.types.d.ts +49 -11
- package/dist/components/features/theme-tweaker/theme-tweaker.types.d.ts +5 -0
- package/dist/components/layout/page/index.d.ts +1 -1
- package/dist/components/layout/page/page.types.d.ts +33 -36
- package/dist/components/layout/page/partials/page-actions.d.ts +1 -0
- package/dist/components/layout/page/partials/page-header.d.ts +1 -1
- package/dist/components/layout/settings/settings.d.ts +16 -2
- package/dist/components/layout/workspace/workspace.types.d.ts +21 -4
- package/dist/components/primitives/number.d.ts +4 -2
- package/dist/components/primitives/value.d.ts +3 -1
- package/dist/components/typography/rich-text/index.d.ts +1 -1
- package/dist/components/typography/rich-text/rich-text-tree.d.ts +19 -0
- package/dist/components/typography/rich-text/rich-text.d.ts +16 -0
- package/dist/components/typography/text-link.d.ts +8 -3
- package/dist/components/ui/checkbox.d.ts +4 -3
- package/dist/components/ui/combobox.d.ts +6 -2
- package/dist/components/ui/item.d.ts +8 -8
- package/dist/components/ui/overlay.recipes.d.ts +0 -9
- package/dist/components/ui/switch.d.ts +2 -2
- package/dist/components/ui/tabs.d.ts +1 -1
- package/dist/{containers-D_L4mTVb.js → containers-Mu1LMGV1.js} +36 -35
- package/dist/containers-Mu1LMGV1.js.map +1 -0
- package/dist/{copyable-DDjTeW_j.js → copyable-ClBuk_UK.js} +6 -6
- package/dist/{copyable-DDjTeW_j.js.map → copyable-ClBuk_UK.js.map} +1 -1
- package/dist/data-display-DT_khPl_.js +971 -0
- package/dist/data-display-DT_khPl_.js.map +1 -0
- package/dist/{date-uf3z37Nm.js → date-DCrsDTZc.js} +5 -5
- package/dist/{date-uf3z37Nm.js.map → date-DCrsDTZc.js.map} +1 -1
- package/dist/date-picker-ay0Pha_a.js +1530 -0
- package/dist/date-picker-ay0Pha_a.js.map +1 -0
- package/dist/date-pickers-Ccw8DL2b.js +175 -0
- package/dist/date-pickers-Ccw8DL2b.js.map +1 -0
- package/dist/display-hAc1HjpI.js +344 -0
- package/dist/display-hAc1HjpI.js.map +1 -0
- package/dist/dropdown-menu-Cl4X7L5S.js +193 -0
- package/dist/dropdown-menu-Cl4X7L5S.js.map +1 -0
- package/dist/editable-text-recipe-Cn61kEcv.js +10 -0
- package/dist/editable-text-recipe-Cn61kEcv.js.map +1 -0
- package/dist/features/activities.js +478 -542
- package/dist/features/activities.js.map +1 -1
- package/dist/features/ai-chat.js +209 -199
- package/dist/features/ai-chat.js.map +1 -1
- package/dist/features/appointment-calendar.js +683 -0
- package/dist/features/appointment-calendar.js.map +1 -0
- package/dist/features/async-preview.js +109 -107
- package/dist/features/async-preview.js.map +1 -1
- package/dist/features/combobox.js +1 -1
- package/dist/features/comments.js +1 -1
- package/dist/features/data-view.js +30 -29
- package/dist/features/data-view.js.map +1 -1
- package/dist/features/email-composer/engine.js +1 -1
- package/dist/features/email-composer.js +285 -283
- package/dist/features/email-composer.js.map +1 -1
- package/dist/features/event-calendar.js +282 -273
- package/dist/features/event-calendar.js.map +1 -1
- package/dist/features/filters.js +1 -1
- package/dist/features/global-search.js +318 -318
- package/dist/features/global-search.js.map +1 -1
- package/dist/features/kanban.js +146 -147
- package/dist/features/kanban.js.map +1 -1
- package/dist/features/map.js +269 -268
- package/dist/features/map.js.map +1 -1
- package/dist/features/media-library.js +970 -863
- 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 +1137 -1124
- package/dist/features/products.js.map +1 -1
- package/dist/features/questionnaire.js +206 -194
- package/dist/features/questionnaire.js.map +1 -1
- package/dist/features/resource-assignment.js +24 -21
- package/dist/features/resource-assignment.js.map +1 -1
- package/dist/features/resource.js +77 -69
- package/dist/features/resource.js.map +1 -1
- package/dist/features/rich-text-editor.js +30 -11
- package/dist/features/rich-text-editor.js.map +1 -1
- package/dist/features/schema-form.js +35 -33
- package/dist/features/schema-form.js.map +1 -1
- package/dist/features/suggestions.js +3 -3
- package/dist/features/sync.js +11 -5
- package/dist/features/sync.js.map +1 -1
- package/dist/features/table.js +1 -1
- package/dist/features/theme-tweaker.js +501 -496
- package/dist/features/theme-tweaker.js.map +1 -1
- package/dist/feedback-BYIhtitP.js +239 -0
- package/dist/feedback-BYIhtitP.js.map +1 -0
- package/dist/field-affordance-recipes-DZhnIL_Y.js +41 -0
- package/dist/field-affordance-recipes-DZhnIL_Y.js.map +1 -0
- package/dist/field-state-recipes-BVA2CWHo.js +12 -0
- package/dist/field-state-recipes-BVA2CWHo.js.map +1 -0
- package/dist/{filters-Da-gNPsE.js → filters-BGfvjP4d.js} +483 -472
- package/dist/filters-BGfvjP4d.js.map +1 -0
- package/dist/focus-recipes-B653VaLq.js +12 -0
- package/dist/focus-recipes-B653VaLq.js.map +1 -0
- package/dist/{form-field-VZRULhUK.js → form-field-CwH9y77i.js} +6 -5
- package/dist/form-field-CwH9y77i.js.map +1 -0
- package/dist/{form-sizing-uWP4lzVh.js → form-sizing-BdP_Mf5p.js} +45 -46
- package/dist/form-sizing-BdP_Mf5p.js.map +1 -0
- package/dist/{forms-DDeEnXSY.js → forms-B9G_xwzi.js} +22 -22
- package/dist/{forms-DDeEnXSY.js.map → forms-B9G_xwzi.js.map} +1 -1
- package/dist/forms-numeric-B_jraJaQ.js +906 -0
- package/dist/forms-numeric-B_jraJaQ.js.map +1 -0
- package/dist/{header-2ycNqGOR.js → header-CGXuhcRm.js} +164 -161
- package/dist/header-CGXuhcRm.js.map +1 -0
- package/dist/{hooks-DQ5SPwZw.js → hooks-Dkz0K2WT.js} +2 -2
- package/dist/{hooks-DQ5SPwZw.js.map → hooks-Dkz0K2WT.js.map} +1 -1
- package/dist/{http-CdEIHyQf.js → http-D_6rOnzU.js} +2 -2
- package/dist/{http-CdEIHyQf.js.map → http-D_6rOnzU.js.map} +1 -1
- package/dist/icon-badge-DYKIwvOV.js +55 -0
- package/dist/icon-badge-DYKIwvOV.js.map +1 -0
- package/dist/index.js +7 -7
- package/dist/input-CZw8iU99.js +21 -0
- package/dist/input-CZw8iU99.js.map +1 -0
- package/dist/input-DQdEd0YD.js +263 -0
- package/dist/input-DQdEd0YD.js.map +1 -0
- package/dist/interaction-recipes-XR9ZpVYL.js +25 -0
- package/dist/interaction-recipes-XR9ZpVYL.js.map +1 -0
- package/dist/item-K5_ghvze.js +275 -0
- package/dist/item-K5_ghvze.js.map +1 -0
- package/dist/layer-recipes-CCpklYME.js +13 -0
- package/dist/layer-recipes-CCpklYME.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 +72 -0
- package/dist/lib/editable-text-recipe.d.ts +4 -4
- package/dist/lib/field-affordance-recipes.d.ts +8 -3
- package/dist/lib/field-state-recipes.d.ts +9 -8
- package/dist/lib/focus-recipes.d.ts +24 -0
- package/dist/lib/interaction-recipes.d.ts +40 -0
- package/dist/lib/layer-recipes.d.ts +19 -0
- package/dist/lib/motion-recipes.d.ts +1 -0
- package/dist/lib/overlay-anatomy-recipes.d.ts +1 -0
- package/dist/lib/safe-image-src.d.ts +10 -0
- package/dist/lib/sanitize-html.d.ts +15 -3
- package/dist/lib/surface-recipes.d.ts +47 -7
- package/dist/lib/theme-mode-css.d.ts +7 -0
- package/dist/lib/token-merge.generated.d.ts +9 -6
- package/dist/lib/tone-recipes.d.ts +87 -0
- package/dist/lib/ui-provider/hooks.d.ts +2 -1
- package/dist/lib/ui-provider/index.d.ts +2 -2
- package/dist/lib/ui-provider/types.d.ts +11 -2
- package/dist/lib/utils.js +1 -1
- package/dist/media-gallery-3zIVLMWH.js +203 -0
- package/dist/media-gallery-3zIVLMWH.js.map +1 -0
- package/dist/mentions-utuUvH1K.js +570 -0
- package/dist/mentions-utuUvH1K.js.map +1 -0
- package/dist/{message-YfFmbXNP.js → message-DZ_ruyUV.js} +7 -6
- package/dist/message-DZ_ruyUV.js.map +1 -0
- package/dist/metadata-list-8N16ZMW_.js +405 -0
- package/dist/metadata-list-8N16ZMW_.js.map +1 -0
- package/dist/{motion-recipes-B6jKXEcN.js → motion-recipes-ChBg4HBq.js} +3 -2
- package/dist/{motion-recipes-B6jKXEcN.js.map → motion-recipes-ChBg4HBq.js.map} +1 -1
- package/dist/navigation-Bnotn4AQ.js +145 -0
- package/dist/navigation-Bnotn4AQ.js.map +1 -0
- package/dist/navigation-BzhHI3lo.js +269 -0
- package/dist/navigation-BzhHI3lo.js.map +1 -0
- package/dist/{navigation-row-recipes-DlU-4QYO.js → navigation-row-recipes-BFLCk_Aq.js} +2 -2
- package/dist/{navigation-row-recipes-DlU-4QYO.js.map → navigation-row-recipes-BFLCk_Aq.js.map} +1 -1
- package/dist/{number-CKRBYmZK.js → number-DbV1Dija.js} +36 -34
- package/dist/{number-CKRBYmZK.js.map → number-DbV1Dija.js.map} +1 -1
- package/dist/overflow-tab-bar-CWY7Nogn.js +282 -0
- package/dist/overflow-tab-bar-CWY7Nogn.js.map +1 -0
- package/dist/overlay.recipes-8GHqmlb4.js +6 -0
- package/dist/overlay.recipes-8GHqmlb4.js.map +1 -0
- package/dist/overlays-DNWmZrJ4.js +1001 -0
- package/dist/overlays-DNWmZrJ4.js.map +1 -0
- package/dist/page-Bgl1F560.js +224 -0
- package/dist/page-Bgl1F560.js.map +1 -0
- package/dist/page-header-commands-DOb6WsfD.js +126 -0
- package/dist/page-header-commands-DOb6WsfD.js.map +1 -0
- package/dist/pagination-BL25hu2s.js +158 -0
- package/dist/pagination-BL25hu2s.js.map +1 -0
- package/dist/{popover-Dcv_9jxr.js → popover-7_m66eYW.js} +11 -10
- package/dist/popover-7_m66eYW.js.map +1 -0
- package/dist/popover-menu-B9WWygpa.js +100 -0
- package/dist/popover-menu-B9WWygpa.js.map +1 -0
- package/dist/{popover.recipes-wmbvL8Ah.js → popover.recipes-D3j8R8Yp.js} +18 -11
- package/dist/popover.recipes-D3j8R8Yp.js.map +1 -0
- package/dist/{primitives-BHrwQXFC.js → primitives-BFK08r9M.js} +45 -44
- package/dist/primitives-BFK08r9M.js.map +1 -0
- package/dist/primitives.js +4 -4
- package/dist/{progress-Br9WTFya.js → progress-B1VnCT0K.js} +9 -9
- package/dist/{progress-Br9WTFya.js.map → progress-B1VnCT0K.js.map} +1 -1
- package/dist/{receipt-CV89q1fs.js → receipt-BVSOH3Xo.js} +9 -6
- package/dist/{receipt-CV89q1fs.js.map → receipt-BVSOH3Xo.js.map} +1 -1
- package/dist/rich-text-GOUyKQ-s.js +78 -0
- package/dist/rich-text-GOUyKQ-s.js.map +1 -0
- package/dist/rich-text-editor-cRLC-eBK.js +1196 -0
- package/dist/rich-text-editor-cRLC-eBK.js.map +1 -0
- package/dist/rich-text-editor-toolbar-DfXg0-VC.js +94 -0
- package/dist/rich-text-editor-toolbar-DfXg0-VC.js.map +1 -0
- package/dist/rich-text-editor.strings-CB59ekH2.js +38 -0
- package/dist/rich-text-editor.strings-CB59ekH2.js.map +1 -0
- package/dist/safe-image-src-C6kQSMBZ.js +17 -0
- package/dist/safe-image-src-C6kQSMBZ.js.map +1 -0
- package/dist/sanitize-html-DsQmI48u.js +92 -0
- package/dist/sanitize-html-DsQmI48u.js.map +1 -0
- package/dist/scroll-area-DcI-M1UT.js +48 -0
- package/dist/scroll-area-DcI-M1UT.js.map +1 -0
- package/dist/{separator-Do5GWDYi.js → separator-BDV-Y648.js} +3 -3
- package/dist/{separator-Do5GWDYi.js.map → separator-BDV-Y648.js.map} +1 -1
- package/dist/{separator-BMEvwnSX.js → separator-Bom7NsGO.js} +2 -2
- package/dist/{separator-BMEvwnSX.js.map → separator-Bom7NsGO.js.map} +1 -1
- package/dist/services/actions/action-adapters.d.ts +18 -0
- package/dist/services/actions/index.d.ts +1 -1
- package/dist/services/actions.js +16 -4
- package/dist/services/actions.js.map +1 -1
- package/dist/settings-ybnjVwbd.js +171 -0
- package/dist/settings-ybnjVwbd.js.map +1 -0
- package/dist/sheet-CGpB3omz.js +211 -0
- package/dist/sheet-CGpB3omz.js.map +1 -0
- package/dist/{sidebar-Cb8WzOvE.js → sidebar-A0ElHINE.js} +17 -16
- package/dist/sidebar-A0ElHINE.js.map +1 -0
- package/dist/{sidebar-Crc9M9JV.js → sidebar-CPx_7YBa.js} +205 -203
- package/dist/sidebar-CPx_7YBa.js.map +1 -0
- package/dist/{skeleton-DVMXr15h.js → skeleton-Byjnt7qr.js} +9 -9
- package/dist/{skeleton-DVMXr15h.js.map → skeleton-Byjnt7qr.js.map} +1 -1
- package/dist/smart-card-DiC5aac3.js +604 -0
- package/dist/smart-card-DiC5aac3.js.map +1 -0
- package/dist/{structure-hzCW-XsV.js → structure-BmisBK-3.js} +2 -2
- package/dist/{structure-hzCW-XsV.js.map → structure-BmisBK-3.js.map} +1 -1
- package/dist/style.css +1 -1
- package/dist/surface-recipes-BKRVW8Os.js +43 -0
- package/dist/surface-recipes-BKRVW8Os.js.map +1 -0
- package/dist/table-BweFy_P9.js +1530 -0
- package/dist/table-BweFy_P9.js.map +1 -0
- package/dist/table-DsfzoUia.js +175 -0
- package/dist/table-DsfzoUia.js.map +1 -0
- package/dist/tabs-CDocW5D1.js +191 -0
- package/dist/tabs-CDocW5D1.js.map +1 -0
- package/dist/text-inputs-f9Ia-aCi.js +353 -0
- package/dist/text-inputs-f9Ia-aCi.js.map +1 -0
- package/dist/theme-mode-css-BB-_RYab.js +14 -0
- package/dist/theme-mode-css-BB-_RYab.js.map +1 -0
- package/dist/theme-scope-BJ6eE2xt.js +50 -0
- package/dist/theme-scope-BJ6eE2xt.js.map +1 -0
- package/dist/theme.css +285 -228
- package/dist/themes/green.css +16 -12
- package/dist/timelines-CwM_9IhD.js +457 -0
- package/dist/timelines-CwM_9IhD.js.map +1 -0
- package/dist/tone-recipes-BPsRAvhu.js +73 -0
- package/dist/tone-recipes-BPsRAvhu.js.map +1 -0
- package/dist/tooltip-yiRJUFjp.js +111 -0
- package/dist/tooltip-yiRJUFjp.js.map +1 -0
- package/dist/{tree-BotPlyiD.js → tree-WnKQzwbq.js} +69 -67
- package/dist/tree-WnKQzwbq.js.map +1 -0
- package/dist/typography/rich-text.js +1 -1
- package/dist/typography-UTnveOEy.js +117 -0
- package/dist/typography-UTnveOEy.js.map +1 -0
- package/dist/typography.js +2 -2
- package/dist/{ui-provider-D2_TeLqw.js → ui-provider-C_U0Xma4.js} +13 -5
- package/dist/ui-provider-C_U0Xma4.js.map +1 -0
- package/dist/ui-provider.js +3 -3
- package/dist/{upload-B0WHW7ak.js → upload-CXyxmQBP.js} +210 -209
- package/dist/upload-CXyxmQBP.js.map +1 -0
- package/dist/{upload-queue-BHZ_wBfd.js → upload-queue-Boscubn9.js} +111 -111
- package/dist/upload-queue-Boscubn9.js.map +1 -0
- package/dist/upload.recipes-BbxTqrCT.js +61 -0
- package/dist/upload.recipes-BbxTqrCT.js.map +1 -0
- package/dist/{usage-card-U0YBLTNT.js → usage-card-BhO5eqkX.js} +45 -29
- package/dist/usage-card-BhO5eqkX.js.map +1 -0
- package/dist/{utils-Cospvlj1.js → utils-BRhFDwuU.js} +114 -67
- package/dist/utils-BRhFDwuU.js.map +1 -0
- package/dist/value-inputs-DXPDjvBU.js +963 -0
- package/dist/value-inputs-DXPDjvBU.js.map +1 -0
- package/dist/{value-typography-Deb3yQZg.js → value-typography-BP8OG6h5.js} +2 -2
- package/dist/{value-typography-Deb3yQZg.js.map → value-typography-BP8OG6h5.js.map} +1 -1
- package/dist/workspace-Cdrg7k9f.js +408 -0
- package/dist/workspace-Cdrg7k9f.js.map +1 -0
- package/docs/consumer-skill/SKILL.md +21 -22
- package/docs/consumer-skill/examples/app-layout.tsx +1 -1
- package/docs/consumer-skill/examples/composition.tsx +3 -3
- package/docs/consumer-skill/examples/detail.tsx +59 -12
- package/docs/consumer-skill/examples/edit.tsx +1 -1
- package/docs/consumer-skill/examples/receipt.tsx +2 -2
- package/docs/consumer-skill/examples/scoped-directory.tsx +1 -1
- package/docs/consumer-skill/examples/website.tsx +1 -1
- package/docs/consumer-skill/references/agents-md.md +33 -0
- package/docs/consumer-skill/references/analytics.md +1 -1
- package/docs/consumer-skill/references/composition.md +58 -13
- package/docs/consumer-skill/references/design-contract.md +12 -3
- package/docs/consumer-skill/references/installation.md +11 -1
- package/docs/consumer-skill/references/integration.md +4 -3
- package/docs/consumer-skill/references/public-api.json +956 -453
- package/docs/consumer-skill/references/review.md +32 -5
- package/docs/consumer-skill/references/theming.md +78 -9
- package/docs/consumer-skill/references/tokens.json +1 -1
- package/docs/consumer-skill/references/workflows.md +54 -10
- package/docs/consumer-skill/scripts/composition-policy.mjs +42 -11
- package/docs/consumer-skill/scripts/surface-policy.mjs +150 -5
- package/package.json +17 -5
- package/dist/accordion-CQXVcd7Q.js +0 -205
- package/dist/accordion-CQXVcd7Q.js.map +0 -1
- package/dist/action-menu-BTpyPWJ2.js +0 -264
- package/dist/action-menu-BTpyPWJ2.js.map +0 -1
- package/dist/affordance-geometry.generated-CCIXb2A1.js +0 -68
- package/dist/affordance-geometry.generated-CCIXb2A1.js.map +0 -1
- package/dist/ai-artifact-2PQ2fItc.js +0 -1112
- package/dist/ai-artifact-2PQ2fItc.js.map +0 -1
- package/dist/attachment-q69dlt5Y.js +0 -244
- package/dist/attachment-q69dlt5Y.js.map +0 -1
- package/dist/auth-M3vGMgDR.js.map +0 -1
- package/dist/avatar-djdaaQ_s.js.map +0 -1
- package/dist/badge-0tATj-tW.js +0 -92
- package/dist/badge-0tATj-tW.js.map +0 -1
- package/dist/breadcrumbs-BG_FfMK4.js +0 -128
- package/dist/breadcrumbs-BG_FfMK4.js.map +0 -1
- package/dist/button-BS3KDg00.js.map +0 -1
- package/dist/button-R9CCoH7A.js.map +0 -1
- package/dist/buttons-DS0ZIwJ_.js +0 -99
- package/dist/buttons-DS0ZIwJ_.js.map +0 -1
- package/dist/cards-QoJ4syG9.js +0 -66
- package/dist/cards-QoJ4syG9.js.map +0 -1
- package/dist/chart-DwYRKKc-.js.map +0 -1
- package/dist/checkbox-B7ygNTYp.js +0 -35
- package/dist/checkbox-B7ygNTYp.js.map +0 -1
- package/dist/choice-inputs-DrJ17tpL.js +0 -752
- package/dist/choice-inputs-DrJ17tpL.js.map +0 -1
- package/dist/code-block-CD0B7M93.js +0 -183
- package/dist/code-block-CD0B7M93.js.map +0 -1
- package/dist/combobox-6dvVny2q.js +0 -272
- package/dist/combobox-6dvVny2q.js.map +0 -1
- package/dist/combobox-CB7039j7.js +0 -865
- package/dist/combobox-CB7039j7.js.map +0 -1
- package/dist/comments-You0Bzbr.js.map +0 -1
- package/dist/components/layout/page/partials/page-header-commands.d.ts +0 -13
- package/dist/containers-D_L4mTVb.js.map +0 -1
- package/dist/data-display-3xWQUnMA.js +0 -1335
- package/dist/data-display-3xWQUnMA.js.map +0 -1
- package/dist/date-picker-DrDFj8Lo.js +0 -1527
- package/dist/date-picker-DrDFj8Lo.js.map +0 -1
- package/dist/date-pickers-CnFCb0n2.js +0 -174
- package/dist/date-pickers-CnFCb0n2.js.map +0 -1
- package/dist/display-DrdvPwF0.js +0 -343
- package/dist/display-DrdvPwF0.js.map +0 -1
- package/dist/dropdown-menu-CURh59jb.js +0 -193
- package/dist/dropdown-menu-CURh59jb.js.map +0 -1
- package/dist/editable-text-recipe-Bkm6wKHp.js +0 -10
- package/dist/editable-text-recipe-Bkm6wKHp.js.map +0 -1
- package/dist/feedback-C7nR0UtT.js +0 -232
- package/dist/feedback-C7nR0UtT.js.map +0 -1
- package/dist/field-affordance-recipes-CkOCdE2y.js +0 -46
- package/dist/field-affordance-recipes-CkOCdE2y.js.map +0 -1
- package/dist/field-state-recipes-C-MFBX_8.js +0 -11
- package/dist/field-state-recipes-C-MFBX_8.js.map +0 -1
- package/dist/filters-Da-gNPsE.js.map +0 -1
- package/dist/form-field-VZRULhUK.js.map +0 -1
- package/dist/form-sizing-uWP4lzVh.js.map +0 -1
- package/dist/forms-numeric-D3CO60IF.js +0 -905
- package/dist/forms-numeric-D3CO60IF.js.map +0 -1
- package/dist/header-2ycNqGOR.js.map +0 -1
- package/dist/icon-badge-DKlaKXoo.js +0 -53
- package/dist/icon-badge-DKlaKXoo.js.map +0 -1
- package/dist/input-BoLm9Hks.js +0 -20
- package/dist/input-BoLm9Hks.js.map +0 -1
- package/dist/input-DhQdBnV3.js +0 -255
- package/dist/input-DhQdBnV3.js.map +0 -1
- package/dist/item-xzh8Df65.js +0 -264
- package/dist/item-xzh8Df65.js.map +0 -1
- package/dist/media-gallery-DQUQ0m3O.js +0 -201
- package/dist/media-gallery-DQUQ0m3O.js.map +0 -1
- package/dist/mentions-DwnO1hh4.js +0 -564
- package/dist/mentions-DwnO1hh4.js.map +0 -1
- package/dist/message-YfFmbXNP.js.map +0 -1
- package/dist/navigation-Cbp5V8gG.js +0 -264
- package/dist/navigation-Cbp5V8gG.js.map +0 -1
- package/dist/navigation-Cs1npsPm.js +0 -300
- package/dist/navigation-Cs1npsPm.js.map +0 -1
- package/dist/overlay.recipes-CNO2S9V6.js +0 -34
- package/dist/overlay.recipes-CNO2S9V6.js.map +0 -1
- package/dist/overlays-DhZO7N-I.js +0 -994
- package/dist/overlays-DhZO7N-I.js.map +0 -1
- package/dist/page-C6R_8jFt.js +0 -325
- package/dist/page-C6R_8jFt.js.map +0 -1
- package/dist/page-header-hUTzcRZX.js +0 -112
- package/dist/page-header-hUTzcRZX.js.map +0 -1
- package/dist/pagination-Cm0jqa3I.js +0 -149
- package/dist/pagination-Cm0jqa3I.js.map +0 -1
- package/dist/popover-Dcv_9jxr.js.map +0 -1
- package/dist/popover-menu-DnRFKnHP.js +0 -99
- package/dist/popover-menu-DnRFKnHP.js.map +0 -1
- package/dist/popover.recipes-wmbvL8Ah.js.map +0 -1
- package/dist/primitives-BHrwQXFC.js.map +0 -1
- package/dist/rich-text-editor-CF8QYt5p.js +0 -574
- package/dist/rich-text-editor-CF8QYt5p.js.map +0 -1
- package/dist/rich-text-editor.recipes-CnrbmTS1.js +0 -81
- package/dist/rich-text-editor.recipes-CnrbmTS1.js.map +0 -1
- package/dist/rich-text-editor.strings-BpnIQgMl.js +0 -25
- package/dist/rich-text-editor.strings-BpnIQgMl.js.map +0 -1
- package/dist/rich-text-j-FGAeZW.js +0 -32
- package/dist/rich-text-j-FGAeZW.js.map +0 -1
- package/dist/sanitize-html-BG9FGe-j.js +0 -64
- package/dist/sanitize-html-BG9FGe-j.js.map +0 -1
- package/dist/scroll-area-DRdr16Pt.js +0 -47
- package/dist/scroll-area-DRdr16Pt.js.map +0 -1
- package/dist/settings-DHk0L2MF.js +0 -161
- package/dist/settings-DHk0L2MF.js.map +0 -1
- package/dist/sheet-DRFNY1_D.js +0 -207
- package/dist/sheet-DRFNY1_D.js.map +0 -1
- package/dist/sidebar-Cb8WzOvE.js.map +0 -1
- package/dist/sidebar-Crc9M9JV.js.map +0 -1
- package/dist/smart-card-Bek-TwUp.js +0 -599
- package/dist/smart-card-Bek-TwUp.js.map +0 -1
- package/dist/spinner-CmTAbEp0.js +0 -80
- package/dist/spinner-CmTAbEp0.js.map +0 -1
- package/dist/surface-recipes-DOdoBXGm.js +0 -28
- package/dist/surface-recipes-DOdoBXGm.js.map +0 -1
- package/dist/table-D6zKeYQX.js +0 -162
- package/dist/table-D6zKeYQX.js.map +0 -1
- package/dist/table-Dn4XSrSB.js +0 -1444
- package/dist/table-Dn4XSrSB.js.map +0 -1
- package/dist/tabs-Dk8E_knt.js +0 -189
- package/dist/tabs-Dk8E_knt.js.map +0 -1
- package/dist/text-inputs-BFpku0Qd.js +0 -331
- package/dist/text-inputs-BFpku0Qd.js.map +0 -1
- package/dist/theme-scope-kStaAer0.js +0 -39
- package/dist/theme-scope-kStaAer0.js.map +0 -1
- package/dist/timelines-CxuAFIc2.js +0 -439
- package/dist/timelines-CxuAFIc2.js.map +0 -1
- package/dist/tree-BotPlyiD.js.map +0 -1
- package/dist/typography-CAr3dQhX.js +0 -116
- package/dist/typography-CAr3dQhX.js.map +0 -1
- package/dist/ui-provider-D2_TeLqw.js.map +0 -1
- package/dist/upload-B0WHW7ak.js.map +0 -1
- package/dist/upload-queue-BHZ_wBfd.js.map +0 -1
- package/dist/usage-card-U0YBLTNT.js.map +0 -1
- package/dist/use-file-drop-target-BX7GnhoQ.js +0 -39
- package/dist/use-file-drop-target-BX7GnhoQ.js.map +0 -1
- package/dist/utils-Cospvlj1.js.map +0 -1
- package/dist/value-inputs-CjfzGMsN.js +0 -854
- package/dist/value-inputs-CjfzGMsN.js.map +0 -1
- package/dist/workspace-YoFjXi6i.js +0 -394
- package/dist/workspace-YoFjXi6i.js.map +0 -1
- /package/dist/components/{blocks/data-display/metadata → base/metadata-list}/metadata-list.strings.d.ts +0 -0
|
@@ -1,29 +1,31 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { a as e, o as t } from "./ui-provider-
|
|
2
|
+
import { a as e, o as t } from "./ui-provider-C_U0Xma4.js";
|
|
3
3
|
import { interpolateString as n, useStrings as r } from "./lib/strings.js";
|
|
4
|
-
import { t as i } from "./utils-
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import { t as m } from "./structure-
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import { t as v } from "./
|
|
12
|
-
import { t as y } from "./
|
|
13
|
-
import { t as b } from "./
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import { i as
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
4
|
+
import { t as i } from "./utils-BRhFDwuU.js";
|
|
5
|
+
import { n as a, t as o } from "./buttons-DPZekJFu.js";
|
|
6
|
+
import { c as s, o as c, t as l } from "./typography-UTnveOEy.js";
|
|
7
|
+
import { i as u, n as d, r as f, t as p } from "./tooltip-yiRJUFjp.js";
|
|
8
|
+
import { t as m } from "./structure-BmisBK-3.js";
|
|
9
|
+
import { i as h } from "./tone-recipes-BPsRAvhu.js";
|
|
10
|
+
import { t as g } from "./row-recipes-DL8n7t_b.js";
|
|
11
|
+
import { i as _, t as v } from "./overlays-DNWmZrJ4.js";
|
|
12
|
+
import { t as y } from "./interaction-recipes-XR9ZpVYL.js";
|
|
13
|
+
import { t as b } from "./sanitize-html-DsQmI48u.js";
|
|
14
|
+
import { t as x } from "./content-typography-CnwgMJ37.js";
|
|
15
|
+
import { t as S } from "./rich-text-GOUyKQ-s.js";
|
|
16
|
+
import { g as C, i as w } from "./primitives-BFK08r9M.js";
|
|
17
|
+
import { n as ee, t as T } from "./number-DbV1Dija.js";
|
|
18
|
+
import { i as E } from "./date-DCrsDTZc.js";
|
|
19
|
+
import { i as D, n as O, s as te } from "./avatar-DAPlDvhJ.js";
|
|
20
|
+
import { t as k } from "./badge-HpFqoqSY.js";
|
|
21
|
+
import { n as A } from "./field-affordance-recipes-DZhnIL_Y.js";
|
|
22
|
+
import { c as ne, o as re } from "./popover-7_m66eYW.js";
|
|
23
|
+
import { s as j } from "./data-display-DT_khPl_.js";
|
|
24
|
+
import { t as ie } from "./rich-text-editor-cRLC-eBK.js";
|
|
25
|
+
import { l as M, n as ae, o as oe, r as N, t as se } from "./mentions-utuUvH1K.js";
|
|
26
|
+
import { Fragment as P, createElement as F, forwardRef as I, memo as L, useCallback as R, useEffect as z, useImperativeHandle as ce, useMemo as B, useRef as V, useState as H } from "react";
|
|
27
|
+
import { Fragment as U, jsx as W, jsxs as G } from "react/jsx-runtime";
|
|
28
|
+
import { AtSign as le, CornerDownRight as ue, File as K, FileText as de, Image as q, Loader2 as fe, MessageCircle as J, Paperclip as pe, Pencil as me, Pin as he, Smile as ge, Trash2 as _e, X as Y } from "lucide-react";
|
|
27
29
|
//#region src/components/features/comments/comments.strings.ts
|
|
28
30
|
var X = {
|
|
29
31
|
title: "Comments",
|
|
@@ -73,12 +75,12 @@ var X = {
|
|
|
73
75
|
};
|
|
74
76
|
//#endregion
|
|
75
77
|
//#region src/components/features/comments/comments-provider.tsx
|
|
76
|
-
function
|
|
78
|
+
function Z(e) {
|
|
77
79
|
return r(X, e);
|
|
78
80
|
}
|
|
79
|
-
function
|
|
81
|
+
function ve(e) {
|
|
80
82
|
let n = t();
|
|
81
|
-
return
|
|
83
|
+
return B(() => ({
|
|
82
84
|
getMediaUrl: e?.getMediaUrl,
|
|
83
85
|
getMediaName: e?.getMediaName,
|
|
84
86
|
getStatusLabel: e?.getStatusLabel,
|
|
@@ -87,16 +89,16 @@ function _e(e) {
|
|
|
87
89
|
}
|
|
88
90
|
//#endregion
|
|
89
91
|
//#region src/components/features/comments/hooks/use-comments.ts
|
|
90
|
-
function
|
|
91
|
-
let { onSubmit: t, onUpdate: n, onDelete: r, onAfterMutate: i, onError: a } = e, [o, s] =
|
|
92
|
+
function Q(e = {}) {
|
|
93
|
+
let { onSubmit: t, onUpdate: n, onDelete: r, onAfterMutate: i, onError: a } = e, [o, s] = H({ kind: "idle" }), [c, l] = H(!1), u = V(!1), [d, f] = H({}), [p, m] = H(0), h = R((e) => {
|
|
92
94
|
u.current = e, l(e);
|
|
93
|
-
}, []), g =
|
|
95
|
+
}, []), g = R(() => {
|
|
94
96
|
m((e) => e + 1), s({ kind: "idle" }), f({}), h(!1);
|
|
95
|
-
}, [h]), _ =
|
|
97
|
+
}, [h]), _ = B(() => ({
|
|
96
98
|
setErrors: f,
|
|
97
99
|
reset: g,
|
|
98
100
|
setSubmitting: h
|
|
99
|
-
}), [g, h]), v =
|
|
101
|
+
}), [g, h]), v = R((e) => {
|
|
100
102
|
try {
|
|
101
103
|
a?.(e);
|
|
102
104
|
} catch {}
|
|
@@ -106,23 +108,23 @@ function ve(e = {}) {
|
|
|
106
108
|
isSubmitting: c,
|
|
107
109
|
formErrors: d,
|
|
108
110
|
resetKey: p,
|
|
109
|
-
startReply:
|
|
111
|
+
startReply: R((e) => {
|
|
110
112
|
e.id && (f({}), s({
|
|
111
113
|
kind: "replying",
|
|
112
114
|
commentId: e.id,
|
|
113
115
|
authorName: e.user?.name
|
|
114
116
|
}));
|
|
115
117
|
}, []),
|
|
116
|
-
startEdit:
|
|
118
|
+
startEdit: R((e) => {
|
|
117
119
|
e.id && (f({}), s({
|
|
118
120
|
kind: "editing",
|
|
119
121
|
comment: e
|
|
120
122
|
}));
|
|
121
123
|
}, []),
|
|
122
|
-
cancelComposerMode:
|
|
124
|
+
cancelComposerMode: R(() => {
|
|
123
125
|
g();
|
|
124
126
|
}, [g]),
|
|
125
|
-
submit:
|
|
127
|
+
submit: R(async (e) => {
|
|
126
128
|
if (o.kind === "editing" && o.comment.id) {
|
|
127
129
|
if (!n || u.current) return;
|
|
128
130
|
let t = {
|
|
@@ -161,7 +163,7 @@ function ve(e = {}) {
|
|
|
161
163
|
v,
|
|
162
164
|
h
|
|
163
165
|
]),
|
|
164
|
-
deleteComment:
|
|
166
|
+
deleteComment: R(async (e) => {
|
|
165
167
|
if (r && e) try {
|
|
166
168
|
await r(e), i?.("delete", { commentId: e });
|
|
167
169
|
} catch (e) {
|
|
@@ -179,48 +181,48 @@ function ve(e = {}) {
|
|
|
179
181
|
//#endregion
|
|
180
182
|
//#region src/components/features/comments/partials/comment-attachment-chip.tsx
|
|
181
183
|
function ye(e) {
|
|
182
|
-
return e.mimeType?.startsWith("image/") ?
|
|
184
|
+
return e.mimeType?.startsWith("image/") ? q : e.mimeType === "application/pdf" || e.mimeType?.startsWith("text/") ? de : e.mimeType ? K : pe;
|
|
183
185
|
}
|
|
184
|
-
var be = ({ attachment: e, editable: t = !1, onRemove: n, onRetry:
|
|
185
|
-
let p = r(X, u), m =
|
|
186
|
+
var be = ({ attachment: e, editable: t = !1, onRemove: n, onRetry: a, accessors: c, strings: u, compact: d = !1, className: f }) => {
|
|
187
|
+
let p = r(X, u), m = c?.getMediaUrl?.(e) ?? e.url, _ = c?.getMediaName?.(e) ?? e.name ?? p.attachmentFallback, v = ye(e), b = e.status === "uploading", x = e.status === "failed", S = b ? /* @__PURE__ */ G(C, {
|
|
186
188
|
size: "xs",
|
|
187
189
|
className: "shrink-0",
|
|
188
|
-
children: [p.attachmentUploadingLabel, typeof e.progress == "number" ? /* @__PURE__ */ U
|
|
190
|
+
children: [p.attachmentUploadingLabel, typeof e.progress == "number" ? /* @__PURE__ */ G(U, { children: [" ", /* @__PURE__ */ W(ee, {
|
|
189
191
|
value: Math.round(e.progress),
|
|
190
192
|
scaled: !0,
|
|
191
193
|
size: "xs",
|
|
192
194
|
align: "left",
|
|
193
195
|
type: "secondary"
|
|
194
196
|
})] }) : null]
|
|
195
|
-
}) :
|
|
197
|
+
}) : x ? /* @__PURE__ */ W(C, {
|
|
196
198
|
size: "xs",
|
|
197
199
|
className: "shrink-0",
|
|
198
200
|
children: e.error ?? p.attachmentFailedLabel
|
|
199
|
-
}) : typeof e.size == "number" ? /* @__PURE__ */
|
|
201
|
+
}) : typeof e.size == "number" ? /* @__PURE__ */ W(w, {
|
|
200
202
|
value: e.size,
|
|
201
203
|
size: "xs",
|
|
202
204
|
className: "shrink-0"
|
|
203
|
-
}) : null,
|
|
205
|
+
}) : null, T = i("comment-attachment-chip--component", "relative inline-flex min-w-0 max-w-[20rem] items-center gap-space-sm rounded-radius", "ring-1 ring-inset transition-colors", d ? "px-control-xs" : "px-control-sm", g.compact, x ? `${h.destructive.tint} ${h.destructive.halo}` : `bg-muted ring-border/60 ${y.rowHover}`, f), E = b ? /* @__PURE__ */ W(fe, {
|
|
204
206
|
className: i("shrink-0 animate-spin text-muted-foreground", "size-icon-md"),
|
|
205
207
|
"aria-hidden": !0
|
|
206
|
-
}) : /* @__PURE__ */
|
|
207
|
-
className: i("shrink-0", "size-icon-md",
|
|
208
|
+
}) : /* @__PURE__ */ W(v, {
|
|
209
|
+
className: i("shrink-0", "size-icon-md", x ? "text-destructive" : "text-muted-foreground"),
|
|
208
210
|
"aria-hidden": !0
|
|
209
|
-
}),
|
|
211
|
+
}), D = /* @__PURE__ */ G("span", {
|
|
210
212
|
className: "inline-flex min-w-0 items-baseline gap-space-sm",
|
|
211
|
-
children: [/* @__PURE__ */
|
|
213
|
+
children: [/* @__PURE__ */ W(s, {
|
|
212
214
|
tag: "span",
|
|
213
215
|
size: "xs",
|
|
214
216
|
weight: "medium",
|
|
215
|
-
className: i("truncate",
|
|
216
|
-
children:
|
|
217
|
-
}),
|
|
217
|
+
className: i("truncate", x && "text-destructive"),
|
|
218
|
+
children: _
|
|
219
|
+
}), S]
|
|
218
220
|
});
|
|
219
|
-
return /* @__PURE__ */
|
|
220
|
-
className:
|
|
221
|
+
return /* @__PURE__ */ G("div", {
|
|
222
|
+
className: T,
|
|
221
223
|
children: [
|
|
222
|
-
|
|
223
|
-
m && !
|
|
224
|
+
E,
|
|
225
|
+
m && !b && !x ? /* @__PURE__ */ W(l, {
|
|
224
226
|
href: m,
|
|
225
227
|
size: "inherit",
|
|
226
228
|
underline: !1,
|
|
@@ -228,21 +230,21 @@ var be = ({ attachment: e, editable: t = !1, onRemove: n, onRetry: o, accessors:
|
|
|
228
230
|
rel: "noreferrer noopener",
|
|
229
231
|
className: "inline-flex min-w-0 flex-1 items-baseline gap-space-sm hover:underline",
|
|
230
232
|
"aria-label": p.attachmentDownloadLabel,
|
|
231
|
-
children:
|
|
232
|
-
}) :
|
|
233
|
-
|
|
234
|
-
className:
|
|
235
|
-
children: /* @__PURE__ */
|
|
233
|
+
children: D
|
|
234
|
+
}) : D,
|
|
235
|
+
b && typeof e.progress == "number" && /* @__PURE__ */ W("div", {
|
|
236
|
+
className: i(h.primary.line, "absolute bottom-0 left-2 right-2 h-px overflow-hidden rounded-full"),
|
|
237
|
+
children: /* @__PURE__ */ W("div", {
|
|
236
238
|
className: "bg-primary h-full transition-[width]",
|
|
237
239
|
style: { width: `${Math.min(100, Math.max(0, e.progress))}%` }
|
|
238
240
|
})
|
|
239
241
|
}),
|
|
240
|
-
|
|
242
|
+
x && a && /* @__PURE__ */ W(o, {
|
|
241
243
|
type: "button",
|
|
242
244
|
size: "sm",
|
|
243
|
-
onClick: () =>
|
|
245
|
+
onClick: () => a(e.id),
|
|
244
246
|
className: "shrink-0 text-destructive decoration-destructive/30 hover:decoration-destructive/60",
|
|
245
|
-
children: /* @__PURE__ */
|
|
247
|
+
children: /* @__PURE__ */ W(s, {
|
|
246
248
|
tag: "span",
|
|
247
249
|
size: "xs",
|
|
248
250
|
weight: "medium",
|
|
@@ -250,14 +252,14 @@ var be = ({ attachment: e, editable: t = !1, onRemove: n, onRetry: o, accessors:
|
|
|
250
252
|
children: p.attachmentRetryLabel
|
|
251
253
|
})
|
|
252
254
|
}),
|
|
253
|
-
t && n && /* @__PURE__ */
|
|
255
|
+
t && n && /* @__PURE__ */ W("button", {
|
|
254
256
|
type: "button",
|
|
255
257
|
onClick: () => n(e.id),
|
|
256
|
-
className: i(
|
|
258
|
+
className: i(A.target, A.focus, A.toggle),
|
|
257
259
|
"aria-label": p.attachmentRemoveLabel,
|
|
258
260
|
title: p.attachmentRemoveLabel,
|
|
259
|
-
children: /* @__PURE__ */
|
|
260
|
-
className:
|
|
261
|
+
children: /* @__PURE__ */ W(Y, {
|
|
262
|
+
className: A.icon,
|
|
261
263
|
"aria-hidden": "true"
|
|
262
264
|
})
|
|
263
265
|
})
|
|
@@ -269,19 +271,19 @@ var be = ({ attachment: e, editable: t = !1, onRemove: n, onRetry: o, accessors:
|
|
|
269
271
|
attachmentFailedLabel: X.attachmentFailedLabel
|
|
270
272
|
};
|
|
271
273
|
function Se(e = {}) {
|
|
272
|
-
let { onUpload: t, maxSize: n, maxFiles: i, disabled: a, initialAttachments: o, onValueChange: s, onError: c, strings: l } = e, u = r(xe, l), [d, f] =
|
|
274
|
+
let { onUpload: t, maxSize: n, maxFiles: i, disabled: a, initialAttachments: o, onValueChange: s, onError: c, strings: l } = e, u = r(xe, l), [d, f] = H(() => o ? [...o] : []), p = V(/* @__PURE__ */ new Map()), m = V(/* @__PURE__ */ new Map()), h = V(d), g = R((e) => {
|
|
273
275
|
let t = [...e];
|
|
274
276
|
h.current = t, f(t);
|
|
275
|
-
}, []), _ =
|
|
277
|
+
}, []), _ = V(s);
|
|
276
278
|
_.current = s;
|
|
277
|
-
let v =
|
|
279
|
+
let v = R((e, t) => {
|
|
278
280
|
g(h.current.map((n) => n.id === e ? {
|
|
279
281
|
...n,
|
|
280
282
|
...t
|
|
281
283
|
} : n));
|
|
282
|
-
}, [g]), y =
|
|
284
|
+
}, [g]), y = R((e) => {
|
|
283
285
|
g(e);
|
|
284
|
-
}, [g]), b =
|
|
286
|
+
}, [g]), b = R((e, n) => {
|
|
285
287
|
if (!t || !m.current.has(e)) return;
|
|
286
288
|
let r = new AbortController();
|
|
287
289
|
p.current.set(e, { controller: r }), v(e, {
|
|
@@ -315,7 +317,7 @@ function Se(e = {}) {
|
|
|
315
317
|
t,
|
|
316
318
|
u.attachmentFailedLabel,
|
|
317
319
|
v
|
|
318
|
-
]), x =
|
|
320
|
+
]), x = R((e) => {
|
|
319
321
|
if (a || !t) return;
|
|
320
322
|
let r = Array.from(e);
|
|
321
323
|
if (r.length === 0) return;
|
|
@@ -354,19 +356,19 @@ function Se(e = {}) {
|
|
|
354
356
|
t,
|
|
355
357
|
u.attachmentTooLargeError,
|
|
356
358
|
u.attachmentTooManyError
|
|
357
|
-
]), S =
|
|
359
|
+
]), S = R((e) => {
|
|
358
360
|
let t = p.current.get(e);
|
|
359
361
|
t && (t.controller.abort(), p.current.delete(e)), m.current.delete(e), g(h.current.filter((t) => t.id !== e));
|
|
360
|
-
}, [g]), C =
|
|
362
|
+
}, [g]), C = R((e) => {
|
|
361
363
|
let t = m.current.get(e);
|
|
362
364
|
t && b(e, t);
|
|
363
|
-
}, [b]), w =
|
|
365
|
+
}, [b]), w = R(() => {
|
|
364
366
|
for (let e of p.current.values()) e.controller.abort();
|
|
365
367
|
p.current.clear(), m.current.clear(), g([]);
|
|
366
368
|
}, [g]);
|
|
367
|
-
return
|
|
369
|
+
return z(() => {
|
|
368
370
|
_.current?.(d);
|
|
369
|
-
}, [d]),
|
|
371
|
+
}, [d]), z(() => {
|
|
370
372
|
let e = p.current, t = m.current;
|
|
371
373
|
return () => {
|
|
372
374
|
for (let t of e.values()) t.controller.abort();
|
|
@@ -374,8 +376,8 @@ function Se(e = {}) {
|
|
|
374
376
|
};
|
|
375
377
|
}, []), {
|
|
376
378
|
attachments: d,
|
|
377
|
-
uploadedAttachments:
|
|
378
|
-
isUploading:
|
|
379
|
+
uploadedAttachments: B(() => d.filter((e) => e.status === "uploaded" || !e.status), [d]),
|
|
380
|
+
isUploading: B(() => d.some((e) => e.status === "uploading"), [d]),
|
|
379
381
|
addFiles: x,
|
|
380
382
|
removeAttachment: S,
|
|
381
383
|
retryAttachment: C,
|
|
@@ -388,8 +390,8 @@ function Se(e = {}) {
|
|
|
388
390
|
function Ce(e) {
|
|
389
391
|
return !e || typeof e != "string" ? !1 : e.replace(/<[^>]*>/g, "").trim().length > 0;
|
|
390
392
|
}
|
|
391
|
-
var
|
|
392
|
-
let C =
|
|
393
|
+
var $ = I(function({ context: e, canComment: t = !0, submitting: n = !1, errors: r, resetKey: i = 0, onSubmit: o, onCancel: c, editingComment: l, replyingTo: u, strings: d, resources: f, onResourceSearch: p, attachments: h, maxAttachments: g, allowAttachments: _, initialValues: v, autoFocus: y = !1, inlineSubmit: b = !0, placeholder: x }, S) {
|
|
394
|
+
let C = Z(d), w = f, ee = p, T = _ ?? !0, E = h?.maxFiles ?? g ?? 5, D = B(() => ({
|
|
393
395
|
...h,
|
|
394
396
|
maxFiles: E,
|
|
395
397
|
disabled: h?.disabled === !0 || !T
|
|
@@ -397,81 +399,81 @@ var Z = N(function({ context: e, canComment: t = !0, submitting: n = !1, errors:
|
|
|
397
399
|
T,
|
|
398
400
|
h,
|
|
399
401
|
E
|
|
400
|
-
]), O =
|
|
402
|
+
]), O = V(null), [te, k] = H(() => v?.content ?? l?.content ?? ""), [A, j] = H(null), [oe, P] = H(null), F = M({
|
|
401
403
|
resources: w,
|
|
402
404
|
onResourceSearch: ee,
|
|
403
405
|
editorRef: O,
|
|
404
|
-
initialMentions: v?.references ??
|
|
405
|
-
}),
|
|
406
|
+
initialMentions: v?.references ?? l?.references
|
|
407
|
+
}), I = Se({
|
|
406
408
|
...D,
|
|
407
409
|
initialAttachments: v?.attachments ?? void 0,
|
|
408
410
|
strings: C,
|
|
409
|
-
onError:
|
|
410
|
-
}),
|
|
411
|
-
|
|
411
|
+
onError: P
|
|
412
|
+
}), L = () => {
|
|
413
|
+
I.reset(), P(null), c?.();
|
|
412
414
|
};
|
|
413
|
-
|
|
415
|
+
ce(S, () => ({
|
|
414
416
|
focus: () => O.current?.focus(),
|
|
415
417
|
clear: () => {
|
|
416
|
-
O.current?.clear(),
|
|
418
|
+
O.current?.clear(), F.reset(), I.reset(), j(null), P(null);
|
|
417
419
|
},
|
|
418
420
|
setBody: (e) => {
|
|
419
421
|
O.current?.setHTML(e);
|
|
420
422
|
}
|
|
421
|
-
}), [
|
|
422
|
-
O.current?.setHTML(v?.content ?? ""),
|
|
423
|
+
}), [I, F]), z(() => {
|
|
424
|
+
O.current?.setHTML(v?.content ?? ""), F.setMentions(v?.references ?? []), I.reset(), I.setAttachments(v?.attachments ?? []), j(null), P(null);
|
|
423
425
|
}, [
|
|
424
426
|
e.id,
|
|
425
427
|
e.type,
|
|
426
428
|
i
|
|
427
|
-
]),
|
|
428
|
-
if (!
|
|
429
|
-
O.current?.setHTML(
|
|
430
|
-
let e = (
|
|
431
|
-
|
|
432
|
-
}, [
|
|
433
|
-
r?.content &&
|
|
429
|
+
]), z(() => {
|
|
430
|
+
if (!l) return;
|
|
431
|
+
O.current?.setHTML(l.content ?? ""), F.setMentions(l.references ?? []);
|
|
432
|
+
let e = (l.attachments ?? []).filter((e) => !!e);
|
|
433
|
+
I.reset(), I.setAttachments(e), P(null);
|
|
434
|
+
}, [l?.id]), z(() => {
|
|
435
|
+
r?.content && j(r.content);
|
|
434
436
|
}, [r]);
|
|
435
|
-
let
|
|
436
|
-
if (t?.preventDefault(), n ||
|
|
437
|
-
let r = O.current?.getHTML() ??
|
|
437
|
+
let R = (t) => {
|
|
438
|
+
if (t?.preventDefault(), n || I.isUploading) return;
|
|
439
|
+
let r = O.current?.getHTML() ?? te;
|
|
438
440
|
if (!Ce(r)) {
|
|
439
|
-
|
|
441
|
+
j(C.invalidContent);
|
|
440
442
|
return;
|
|
441
443
|
}
|
|
442
|
-
|
|
444
|
+
j(null), o({
|
|
443
445
|
content: r,
|
|
444
446
|
commentableId: e.id,
|
|
445
447
|
commentableType: e.type,
|
|
446
448
|
moduleKey: e.moduleKey,
|
|
447
449
|
contentType: "html",
|
|
448
|
-
references:
|
|
449
|
-
attachments:
|
|
450
|
-
replyToId:
|
|
451
|
-
editingId:
|
|
450
|
+
references: F.mentions,
|
|
451
|
+
attachments: I.uploadedAttachments,
|
|
452
|
+
replyToId: u?.commentId ?? v?.replyToId,
|
|
453
|
+
editingId: l?.id
|
|
452
454
|
});
|
|
453
|
-
},
|
|
454
|
-
e?.length && (
|
|
455
|
-
},
|
|
455
|
+
}, U = V(null), ue = () => U.current?.click(), K = (e) => {
|
|
456
|
+
e?.length && (P(null), I.addFiles(e));
|
|
457
|
+
}, de = I.attachments.length > 0, q = !!l, J = !q && !!u, me = n ? C.composerSubmitting : q ? C.composerSave : C.composerSubmit, he = q ? /* @__PURE__ */ W(we, {
|
|
456
458
|
label: C.composerEditingEyebrow,
|
|
457
459
|
closeLabel: C.composerCancel,
|
|
458
|
-
onClose:
|
|
459
|
-
}) : J ? /* @__PURE__ */
|
|
460
|
-
label:
|
|
460
|
+
onClose: c ? L : void 0
|
|
461
|
+
}) : J ? /* @__PURE__ */ W(we, {
|
|
462
|
+
label: Te(C.composerReplyingEyebrow, u.authorName),
|
|
461
463
|
closeLabel: C.composerCancel,
|
|
462
|
-
onClose:
|
|
463
|
-
}) : null,
|
|
464
|
+
onClose: c ? L : void 0
|
|
465
|
+
}) : null, ge = B(() => {
|
|
464
466
|
let e = [];
|
|
465
467
|
return w && Object.keys(w).length > 0 && e.push({
|
|
466
468
|
id: "reference",
|
|
467
469
|
icon: le,
|
|
468
470
|
label: C.composerReferenceLabel,
|
|
469
|
-
onClick: () =>
|
|
471
|
+
onClick: () => F.setPickerOpen(!0)
|
|
470
472
|
}), D?.onUpload && !D.disabled && e.push({
|
|
471
473
|
id: "attachment",
|
|
472
474
|
icon: pe,
|
|
473
475
|
label: C.composerAttachmentLabel,
|
|
474
|
-
onClick:
|
|
476
|
+
onClick: ue
|
|
475
477
|
}), e;
|
|
476
478
|
}, [
|
|
477
479
|
w,
|
|
@@ -481,77 +483,77 @@ var Z = N(function({ context: e, canComment: t = !0, submitting: n = !1, errors:
|
|
|
481
483
|
C.composerAttachmentLabel
|
|
482
484
|
]);
|
|
483
485
|
if (!t) return null;
|
|
484
|
-
let
|
|
486
|
+
let _e = /* @__PURE__ */ W(a, {
|
|
485
487
|
tone: "primary",
|
|
486
488
|
type: "button",
|
|
487
|
-
onClick: () =>
|
|
488
|
-
disabled: n ||
|
|
489
|
+
onClick: () => R(),
|
|
490
|
+
disabled: n || I.isUploading,
|
|
489
491
|
icon: n ? fe : void 0,
|
|
490
492
|
children: me
|
|
491
|
-
}),
|
|
493
|
+
}), Y = q || J || c ? /* @__PURE__ */ W(a, {
|
|
492
494
|
type: "button",
|
|
493
495
|
tone: "secondary",
|
|
494
496
|
buttonStyle: "ghost",
|
|
495
|
-
onClick:
|
|
497
|
+
onClick: L,
|
|
496
498
|
disabled: n,
|
|
497
499
|
children: C.composerCancel
|
|
498
|
-
}) : null,
|
|
500
|
+
}) : null, X = de ? /* @__PURE__ */ W(m, {
|
|
499
501
|
direction: "horizontal",
|
|
500
502
|
wrap: !0,
|
|
501
503
|
align: "center",
|
|
502
504
|
gap: "sm",
|
|
503
|
-
children:
|
|
505
|
+
children: I.attachments.map((e) => /* @__PURE__ */ W(be, {
|
|
504
506
|
attachment: e,
|
|
505
507
|
editable: !0,
|
|
506
508
|
onRemove: (e) => {
|
|
507
|
-
|
|
509
|
+
P(null), I.removeAttachment(e);
|
|
508
510
|
},
|
|
509
511
|
onRetry: (e) => {
|
|
510
|
-
|
|
512
|
+
P(null), I.retryAttachment(e);
|
|
511
513
|
},
|
|
512
|
-
strings:
|
|
514
|
+
strings: d
|
|
513
515
|
}, e.id))
|
|
514
|
-
}) : null,
|
|
515
|
-
return /* @__PURE__ */
|
|
516
|
-
render: /* @__PURE__ */
|
|
516
|
+
}) : null, ve = de ? X : null, Q = b !== !1 && !q && !J ? _e : null, ye = b === !1 || q || J;
|
|
517
|
+
return /* @__PURE__ */ G(m, {
|
|
518
|
+
render: /* @__PURE__ */ W("form", {}),
|
|
517
519
|
gap: "md",
|
|
518
|
-
onSubmit:
|
|
520
|
+
onSubmit: R,
|
|
519
521
|
className: "comment-composer--component",
|
|
520
522
|
children: [
|
|
521
523
|
he,
|
|
522
|
-
/* @__PURE__ */
|
|
523
|
-
ref:
|
|
524
|
+
/* @__PURE__ */ W("input", {
|
|
525
|
+
ref: U,
|
|
524
526
|
type: "file",
|
|
525
527
|
multiple: !0,
|
|
526
528
|
hidden: !0,
|
|
527
529
|
accept: D?.accept,
|
|
528
530
|
onChange: (e) => {
|
|
529
|
-
|
|
531
|
+
K(e.target.files), e.target.value = "";
|
|
530
532
|
}
|
|
531
533
|
}),
|
|
532
|
-
!
|
|
533
|
-
open:
|
|
534
|
-
onOpenChange:
|
|
535
|
-
children: [/* @__PURE__ */
|
|
534
|
+
!F.triggerActive && /* @__PURE__ */ G(re, {
|
|
535
|
+
open: F.pickerOpen,
|
|
536
|
+
onOpenChange: F.setPickerOpen,
|
|
537
|
+
children: [/* @__PURE__ */ W(ne, { render: /* @__PURE__ */ W(a, {
|
|
536
538
|
type: "button",
|
|
537
539
|
tone: "secondary",
|
|
538
540
|
buttonStyle: "ghost",
|
|
539
541
|
className: "sr-only",
|
|
540
542
|
tabIndex: -1,
|
|
541
543
|
children: C.composerReferenceLabel
|
|
542
|
-
}) }), /* @__PURE__ */
|
|
543
|
-
open:
|
|
544
|
-
activeKind:
|
|
544
|
+
}) }), /* @__PURE__ */ W(N, {
|
|
545
|
+
open: F.pickerOpen,
|
|
546
|
+
activeKind: F.activeKind,
|
|
545
547
|
setActiveKind: (e) => {
|
|
546
|
-
|
|
548
|
+
F.setActiveKind(e), F.setManualKindOverride(!0);
|
|
547
549
|
},
|
|
548
|
-
kinds:
|
|
550
|
+
kinds: F.kinds,
|
|
549
551
|
resources: w,
|
|
550
|
-
query:
|
|
551
|
-
setQuery:
|
|
552
|
-
suggestions:
|
|
553
|
-
loading:
|
|
554
|
-
onSelect:
|
|
552
|
+
query: F.query,
|
|
553
|
+
setQuery: F.setQuery,
|
|
554
|
+
suggestions: F.suggestions,
|
|
555
|
+
loading: F.isLoading,
|
|
556
|
+
onSelect: F.pickSuggestion,
|
|
555
557
|
strings: {
|
|
556
558
|
title: C.composerReferenceMenuTitle,
|
|
557
559
|
searchPlaceholder: C.composerReferenceSearchPlaceholder,
|
|
@@ -560,40 +562,40 @@ var Z = N(function({ context: e, canComment: t = !0, submitting: n = !1, errors:
|
|
|
560
562
|
}
|
|
561
563
|
})]
|
|
562
564
|
}),
|
|
563
|
-
/* @__PURE__ */
|
|
565
|
+
/* @__PURE__ */ G("div", {
|
|
564
566
|
className: "comment-composer--editor relative",
|
|
565
|
-
children: [/* @__PURE__ */
|
|
567
|
+
children: [/* @__PURE__ */ W(ie, {
|
|
566
568
|
ref: O,
|
|
567
|
-
value:
|
|
569
|
+
value: te,
|
|
568
570
|
onValueChange: (e) => {
|
|
569
|
-
|
|
570
|
-
let t = se(e), n =
|
|
571
|
+
k(e);
|
|
572
|
+
let t = se(e), n = F.mentions;
|
|
571
573
|
if (n.map((e) => e.id).join("|") !== t.map((e) => e.id).join("|")) {
|
|
572
574
|
let e = new Map(n.map((e) => [e.id, e])), r = t.map((t) => e.get(t.id) ?? t);
|
|
573
|
-
|
|
575
|
+
F.setMentions(r);
|
|
574
576
|
}
|
|
575
577
|
},
|
|
576
578
|
placeholder: x ?? C.composerPlaceholder,
|
|
577
579
|
strings: { editorLabel: x ?? C.composerPlaceholder },
|
|
578
|
-
|
|
580
|
+
bodyHeight: "field",
|
|
579
581
|
autoFocus: y || q || J,
|
|
580
|
-
extraToolbarItems:
|
|
581
|
-
toolbarTrailing:
|
|
582
|
-
footerSlot:
|
|
583
|
-
onCaretChange:
|
|
584
|
-
}), /* @__PURE__ */
|
|
585
|
-
open:
|
|
586
|
-
activeKind:
|
|
582
|
+
extraToolbarItems: ge,
|
|
583
|
+
toolbarTrailing: Q,
|
|
584
|
+
footerSlot: ve,
|
|
585
|
+
onCaretChange: F.handleCaretChange
|
|
586
|
+
}), /* @__PURE__ */ W(ae, {
|
|
587
|
+
open: F.triggerActive && F.pickerOpen,
|
|
588
|
+
activeKind: F.activeKind,
|
|
587
589
|
setActiveKind: (e) => {
|
|
588
|
-
|
|
590
|
+
F.setActiveKind(e), F.setManualKindOverride(!0);
|
|
589
591
|
},
|
|
590
|
-
kinds:
|
|
592
|
+
kinds: F.kinds,
|
|
591
593
|
resources: w,
|
|
592
|
-
query:
|
|
593
|
-
suggestions:
|
|
594
|
-
suggestionsByKind:
|
|
595
|
-
loading:
|
|
596
|
-
onSelect:
|
|
594
|
+
query: F.query,
|
|
595
|
+
suggestions: F.suggestions,
|
|
596
|
+
suggestionsByKind: F.suggestionsByKind,
|
|
597
|
+
loading: F.isLoading,
|
|
598
|
+
onSelect: F.pickSuggestion,
|
|
597
599
|
strings: {
|
|
598
600
|
title: C.composerReferenceMenuTitle,
|
|
599
601
|
empty: C.composerReferenceEmpty,
|
|
@@ -601,55 +603,55 @@ var Z = N(function({ context: e, canComment: t = !0, submitting: n = !1, errors:
|
|
|
601
603
|
}
|
|
602
604
|
})]
|
|
603
605
|
}),
|
|
604
|
-
|
|
606
|
+
oe && /* @__PURE__ */ W(s, {
|
|
605
607
|
role: "alert",
|
|
606
608
|
size: "xs",
|
|
607
609
|
type: "error",
|
|
608
610
|
className: "comment-composer--attachment-error",
|
|
609
|
-
children:
|
|
611
|
+
children: oe
|
|
610
612
|
}),
|
|
611
|
-
|
|
613
|
+
A && /* @__PURE__ */ W(s, {
|
|
612
614
|
size: "xs",
|
|
613
615
|
type: "error",
|
|
614
|
-
children:
|
|
616
|
+
children: A
|
|
615
617
|
}),
|
|
616
|
-
|
|
618
|
+
ye && /* @__PURE__ */ G(m, {
|
|
617
619
|
direction: "horizontal",
|
|
618
620
|
align: "center",
|
|
619
621
|
justify: "end",
|
|
620
622
|
gap: "md",
|
|
621
623
|
className: "comment-composer--footer-actions",
|
|
622
|
-
children: [
|
|
624
|
+
children: [Y, _e]
|
|
623
625
|
})
|
|
624
626
|
]
|
|
625
627
|
});
|
|
626
628
|
});
|
|
627
629
|
function we({ label: e, closeLabel: t, onClose: n }) {
|
|
628
|
-
return /* @__PURE__ */
|
|
629
|
-
className: i("comment-composer--eyebrow bg-muted/
|
|
630
|
-
children: [/* @__PURE__ */
|
|
630
|
+
return /* @__PURE__ */ G("div", {
|
|
631
|
+
className: i("comment-composer--eyebrow bg-muted/30 ring-border/60 flex min-w-0 items-center justify-between gap-space-sm rounded-radius px-row-x ring-1 ring-inset", g.compact),
|
|
632
|
+
children: [/* @__PURE__ */ W(c, { children: e }), n ? /* @__PURE__ */ W("button", {
|
|
631
633
|
type: "button",
|
|
632
634
|
onClick: n,
|
|
633
|
-
className: i(
|
|
635
|
+
className: i(A.target, A.focus, A.toggle),
|
|
634
636
|
"aria-label": t,
|
|
635
|
-
children: /* @__PURE__ */
|
|
636
|
-
className:
|
|
637
|
+
children: /* @__PURE__ */ W(Y, {
|
|
638
|
+
className: A.icon,
|
|
637
639
|
"aria-hidden": "true"
|
|
638
640
|
})
|
|
639
641
|
}) : null]
|
|
640
642
|
});
|
|
641
643
|
}
|
|
642
|
-
function
|
|
644
|
+
function Te(e, t) {
|
|
643
645
|
return n(e, { name: t }, { missing: "empty" });
|
|
644
646
|
}
|
|
645
647
|
//#endregion
|
|
646
648
|
//#region src/components/features/comments/partials/comment-empty.tsx
|
|
647
|
-
var
|
|
648
|
-
let r =
|
|
649
|
-
return /* @__PURE__ */
|
|
649
|
+
var Ee = ({ strings: e, icon: t, className: n }) => {
|
|
650
|
+
let r = Z(e);
|
|
651
|
+
return /* @__PURE__ */ W(j, {
|
|
650
652
|
title: r.empty,
|
|
651
653
|
description: r.emptyHint || !1,
|
|
652
|
-
media: t ?? /* @__PURE__ */
|
|
654
|
+
media: t ?? /* @__PURE__ */ W(J, {
|
|
653
655
|
className: "size-icon",
|
|
654
656
|
"aria-hidden": "true"
|
|
655
657
|
}),
|
|
@@ -660,18 +662,19 @@ var $ = ({ strings: e, icon: t, className: n }) => {
|
|
|
660
662
|
};
|
|
661
663
|
//#endregion
|
|
662
664
|
//#region src/components/features/comments/partials/comment-content.tsx
|
|
663
|
-
function
|
|
665
|
+
function De(e) {
|
|
664
666
|
let { comment: t, resources: n, renderReference: r, sanitizer: i } = e, a = t.contentType ?? t.content_type ?? "text";
|
|
665
667
|
if (a === "rich") {
|
|
666
|
-
let e =
|
|
667
|
-
return e ? /* @__PURE__ */
|
|
668
|
+
let e = Oe(t.content);
|
|
669
|
+
return e ? /* @__PURE__ */ W("div", {
|
|
668
670
|
className: "comment-content--component",
|
|
669
671
|
children: e
|
|
670
672
|
}) : null;
|
|
671
673
|
}
|
|
672
|
-
if (a === "html") return /* @__PURE__ */
|
|
674
|
+
if (a === "html") return /* @__PURE__ */ W("div", {
|
|
673
675
|
className: "comment-content--component",
|
|
674
|
-
children: /* @__PURE__ */
|
|
676
|
+
children: /* @__PURE__ */ W(oe, {
|
|
677
|
+
className: "text-inherit",
|
|
675
678
|
html: t.content ?? "",
|
|
676
679
|
mentions: t.references,
|
|
677
680
|
resources: n,
|
|
@@ -679,91 +682,95 @@ function Te(e) {
|
|
|
679
682
|
sanitizer: i
|
|
680
683
|
})
|
|
681
684
|
});
|
|
682
|
-
let o =
|
|
683
|
-
return /* @__PURE__ */
|
|
685
|
+
let o = je(t.content ?? "");
|
|
686
|
+
return /* @__PURE__ */ W(s, {
|
|
687
|
+
type: "inherit",
|
|
684
688
|
className: "comment-content--component whitespace-pre-line",
|
|
685
689
|
children: o
|
|
686
690
|
});
|
|
687
691
|
}
|
|
688
|
-
function
|
|
692
|
+
function Oe(e) {
|
|
689
693
|
if (!e) return null;
|
|
690
694
|
try {
|
|
691
695
|
let t = JSON.parse(e);
|
|
692
|
-
return !t || !Array.isArray(t.blocks) || t.blocks.length === 0 ? null : /* @__PURE__ */
|
|
696
|
+
return !t || !Array.isArray(t.blocks) || t.blocks.length === 0 ? null : /* @__PURE__ */ W(s, {
|
|
693
697
|
tag: "div",
|
|
694
|
-
|
|
695
|
-
|
|
698
|
+
type: "inherit",
|
|
699
|
+
className: x,
|
|
700
|
+
children: t.blocks.map((e, t) => /* @__PURE__ */ W(P, { children: ke(e) }, e.id ?? `${e.type}-${t}`))
|
|
696
701
|
});
|
|
697
702
|
} catch {
|
|
698
|
-
let t =
|
|
699
|
-
return /* @__PURE__ */
|
|
703
|
+
let t = je(e);
|
|
704
|
+
return /* @__PURE__ */ W(s, {
|
|
705
|
+
type: "inherit",
|
|
700
706
|
className: "whitespace-pre-line",
|
|
701
707
|
children: t
|
|
702
708
|
});
|
|
703
709
|
}
|
|
704
710
|
}
|
|
705
|
-
function
|
|
711
|
+
function ke(e) {
|
|
706
712
|
let t = e.data ?? {};
|
|
707
713
|
switch (e.type) {
|
|
708
714
|
case "paragraph": {
|
|
709
715
|
let e = String(t.text ?? "").trim();
|
|
710
716
|
if (!e) return null;
|
|
711
|
-
let n =
|
|
712
|
-
return n ? /* @__PURE__ */
|
|
717
|
+
let n = b(e);
|
|
718
|
+
return n ? /* @__PURE__ */ W("p", { dangerouslySetInnerHTML: { __html: n } }) : null;
|
|
713
719
|
}
|
|
714
720
|
case "header": {
|
|
715
|
-
let e =
|
|
716
|
-
return e ?
|
|
721
|
+
let e = Ae(String(t.text ?? "")), n = Number(t.level ?? 3);
|
|
722
|
+
return e ? F(`h${Math.min(Math.max(n, 1), 6)}`, null, e) : null;
|
|
717
723
|
}
|
|
718
724
|
case "list": {
|
|
719
|
-
let e = (Array.isArray(t.items) ? t.items : []).map((e) =>
|
|
720
|
-
return e.length === 0 ? null : t.style === "ordered" ? /* @__PURE__ */
|
|
725
|
+
let e = (Array.isArray(t.items) ? t.items : []).map((e) => Ae(String(e ?? ""))).filter((e) => e.length > 0);
|
|
726
|
+
return e.length === 0 ? null : t.style === "ordered" ? /* @__PURE__ */ W("ol", { children: e.map((e, t) => /* @__PURE__ */ W("li", { children: /* @__PURE__ */ W(s, {
|
|
721
727
|
tag: "span",
|
|
728
|
+
type: "inherit",
|
|
722
729
|
children: e
|
|
723
|
-
}) }, `${e}-${t}`)) }) : /* @__PURE__ */
|
|
730
|
+
}) }, `${e}-${t}`)) }) : /* @__PURE__ */ W("ul", { children: e.map((e) => /* @__PURE__ */ W("li", { children: /* @__PURE__ */ W(s, {
|
|
724
731
|
tag: "span",
|
|
732
|
+
type: "inherit",
|
|
725
733
|
children: e
|
|
726
734
|
}) }, e)) });
|
|
727
735
|
}
|
|
728
736
|
case "quote": {
|
|
729
737
|
let e = String(t.text ?? "").trim();
|
|
730
738
|
if (!e) return null;
|
|
731
|
-
let n =
|
|
732
|
-
return /* @__PURE__ */
|
|
739
|
+
let n = Ae(String(t.caption ?? ""));
|
|
740
|
+
return /* @__PURE__ */ G("blockquote", {
|
|
733
741
|
className: "italic",
|
|
734
|
-
children: [/* @__PURE__ */
|
|
742
|
+
children: [/* @__PURE__ */ W(S, {
|
|
735
743
|
tag: "div",
|
|
736
744
|
html: e,
|
|
737
745
|
type: "secondary"
|
|
738
|
-
}), n.length > 0 && /* @__PURE__ */
|
|
746
|
+
}), n.length > 0 && /* @__PURE__ */ W("cite", {
|
|
739
747
|
className: "mt-1 block not-italic",
|
|
740
|
-
children: /* @__PURE__ */
|
|
748
|
+
children: /* @__PURE__ */ G(s, {
|
|
741
749
|
tag: "span",
|
|
742
750
|
size: "xs",
|
|
743
751
|
type: "secondary",
|
|
744
|
-
className: "opacity-80",
|
|
745
752
|
children: ["— ", n]
|
|
746
753
|
})
|
|
747
754
|
})]
|
|
748
755
|
});
|
|
749
756
|
}
|
|
750
|
-
case "delimiter": return /* @__PURE__ */
|
|
757
|
+
case "delimiter": return /* @__PURE__ */ W("hr", {
|
|
751
758
|
className: "border-dashed",
|
|
752
759
|
"aria-hidden": "true"
|
|
753
760
|
});
|
|
754
761
|
default: {
|
|
755
|
-
let e =
|
|
756
|
-
return e ? /* @__PURE__ */
|
|
762
|
+
let e = Ae(String(t.text ?? ""));
|
|
763
|
+
return e ? /* @__PURE__ */ W("p", {
|
|
757
764
|
className: "whitespace-pre-line",
|
|
758
765
|
children: e
|
|
759
766
|
}) : null;
|
|
760
767
|
}
|
|
761
768
|
}
|
|
762
769
|
}
|
|
763
|
-
function
|
|
770
|
+
function Ae(e) {
|
|
764
771
|
return e.replace(/<[^>]*>/g, "").trim();
|
|
765
772
|
}
|
|
766
|
-
function
|
|
773
|
+
function je(e) {
|
|
767
774
|
if (typeof e != "string") return "";
|
|
768
775
|
let t = e.trim();
|
|
769
776
|
if (t === "") return "";
|
|
@@ -776,148 +783,152 @@ function ke(e) {
|
|
|
776
783
|
}
|
|
777
784
|
//#endregion
|
|
778
785
|
//#region src/components/features/comments/partials/comment-item.tsx
|
|
779
|
-
var
|
|
780
|
-
let
|
|
786
|
+
var Me = "?", Ne = (e) => e?.url, Pe = (e) => e?.name, Fe = (e) => e.charAt(0).toUpperCase() + e.slice(1).replace(/_/g, " "), Ie = L(function({ comment: e, canModerate: t, onDelete: r, onAttachmentRemove: o, onEdit: c, onPinToggle: l, onReact: h, onReply: g, allowReactions: y, allowReplies: b, sanitizer: x, strings: S, getMediaUrl: C, getMediaName: w, getStatusLabel: ee, formatRelativeTime: ne, resources: re, renderAttachment: j, renderReference: ie }) {
|
|
787
|
+
let M = Z(S), ae = y ?? !0, oe = b ?? !0, N = ve({
|
|
781
788
|
getMediaUrl: C,
|
|
782
|
-
getMediaName:
|
|
783
|
-
getStatusLabel:
|
|
784
|
-
formatRelativeTime:
|
|
785
|
-
}),
|
|
786
|
-
if (!L) return
|
|
789
|
+
getMediaName: w,
|
|
790
|
+
getStatusLabel: ee,
|
|
791
|
+
formatRelativeTime: ne
|
|
792
|
+
}), se = N.getMediaUrl ?? Ne, P = N.getMediaName ?? Pe, F = N.getStatusLabel ?? Fe, I = N.formatRelativeTime, L = e.user?.name ?? M.fallbackAuthor, z = e.user?.avatar ?? void 0, ce = B(() => {
|
|
793
|
+
if (!L) return Me;
|
|
787
794
|
let e = L.trim();
|
|
788
|
-
return e === "" ?
|
|
789
|
-
}, [L]),
|
|
790
|
-
|
|
791
|
-
}, [
|
|
792
|
-
return /* @__PURE__ */
|
|
793
|
-
className: i("comment-item--component group relative overflow-hidden rounded-radius border transition-colors", "border-border/60 bg-card
|
|
795
|
+
return e === "" ? Me : e.charAt(0).toUpperCase();
|
|
796
|
+
}, [L]), V = B(() => Array.isArray(e.tagsArray) ? e.tagsArray.filter((e) => typeof e == "string") : e.tagsArray && typeof e.tagsArray == "object" ? Object.values(e.tagsArray).filter((e) => typeof e == "string") : [], [e.tagsArray]), U = B(() => (e.attachments ?? []).filter((e) => !!e && typeof e == "object"), [e.attachments]), le = ae ? e.reactions ?? [] : [], K = e.isPinned === !0, de = e.isEdited === !0, q = e.status && e.status !== "active", fe = q && e.status ? F(e.status) : null, J = e.canDelete === !0 || t === !0, pe = e.canEdit === !0 || t === !0, Y = !!oe && !!g && !!e.id, Q = !!ae && !!h && !!e.id, ye = !!l && !!t, xe = !!pe && !!c && !!e.id, Se = !!J && !!r && !!e.id, Ce = Y || Q || ye || xe || Se, $ = _(), [we, Te] = H(null), Ee = R((e) => {
|
|
797
|
+
Te(e), $.show();
|
|
798
|
+
}, [$]), Oe = U.length > 0;
|
|
799
|
+
return /* @__PURE__ */ G("article", {
|
|
800
|
+
className: i("comment-item--component group relative overflow-hidden rounded-radius border transition-colors", "border-border/60 bg-card text-card-foreground px-surface pt-surface", Ce ? "pb-surface-xs" : "pb-surface"),
|
|
794
801
|
"data-comment-id": e.id,
|
|
795
|
-
children: [/* @__PURE__ */
|
|
802
|
+
children: [/* @__PURE__ */ G(m, {
|
|
796
803
|
direction: "horizontal",
|
|
797
804
|
align: "start",
|
|
798
805
|
gap: "lg",
|
|
799
806
|
className: "min-w-0",
|
|
800
|
-
children: [/* @__PURE__ */
|
|
801
|
-
className: "
|
|
802
|
-
children: [!!z && /* @__PURE__ */
|
|
807
|
+
children: [/* @__PURE__ */ G(O, {
|
|
808
|
+
className: "size-avatar shrink-0",
|
|
809
|
+
children: [!!z && /* @__PURE__ */ W(te, {
|
|
803
810
|
src: z,
|
|
804
811
|
alt: L
|
|
805
|
-
}), /* @__PURE__ */
|
|
812
|
+
}), /* @__PURE__ */ W(D, {
|
|
806
813
|
className: "bg-muted text-muted-foreground text-xs font-medium",
|
|
807
|
-
children:
|
|
814
|
+
children: ce
|
|
808
815
|
})]
|
|
809
|
-
}), /* @__PURE__ */
|
|
816
|
+
}), /* @__PURE__ */ G("div", {
|
|
810
817
|
className: "comment-item--body min-w-0 flex-1",
|
|
811
818
|
children: [
|
|
812
|
-
/* @__PURE__ */
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
843
|
-
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
819
|
+
/* @__PURE__ */ G(m, {
|
|
820
|
+
gap: "xs",
|
|
821
|
+
className: "comment-item--message min-w-0",
|
|
822
|
+
children: [/* @__PURE__ */ G(m, {
|
|
823
|
+
direction: "horizontal",
|
|
824
|
+
align: "baseline",
|
|
825
|
+
gap: "md",
|
|
826
|
+
className: "min-w-0",
|
|
827
|
+
children: [
|
|
828
|
+
/* @__PURE__ */ W(s, {
|
|
829
|
+
tag: "span",
|
|
830
|
+
type: "inherit",
|
|
831
|
+
weight: "semibold",
|
|
832
|
+
className: "truncate",
|
|
833
|
+
children: L
|
|
834
|
+
}),
|
|
835
|
+
!!K && /* @__PURE__ */ W(f, {
|
|
836
|
+
delayDuration: 0,
|
|
837
|
+
children: /* @__PURE__ */ G(p, { children: [/* @__PURE__ */ W(u, {
|
|
838
|
+
render: /* @__PURE__ */ W("span", { className: "inline-flex shrink-0 self-center" }),
|
|
839
|
+
children: /* @__PURE__ */ W(he, {
|
|
840
|
+
className: "text-muted-foreground size-icon-sm",
|
|
841
|
+
"aria-hidden": !0
|
|
842
|
+
})
|
|
843
|
+
}), /* @__PURE__ */ W(d, {
|
|
844
|
+
side: "top",
|
|
845
|
+
className: "text-xs",
|
|
846
|
+
children: M.pinned
|
|
847
|
+
})] })
|
|
848
|
+
}),
|
|
849
|
+
/* @__PURE__ */ W(E, {
|
|
850
|
+
value: e.createdAt,
|
|
851
|
+
formatRelativeTime: I,
|
|
852
|
+
size: "xs",
|
|
853
|
+
className: "shrink-0 tabular-nums"
|
|
854
|
+
}),
|
|
855
|
+
!!de && /* @__PURE__ */ W(s, {
|
|
856
|
+
tag: "span",
|
|
857
|
+
size: "xs",
|
|
858
|
+
type: "secondary",
|
|
859
|
+
className: "shrink-0",
|
|
860
|
+
children: M.edited
|
|
861
|
+
}),
|
|
862
|
+
!!q && !!fe && /* @__PURE__ */ W(k, {
|
|
863
|
+
size: "sm",
|
|
864
|
+
tone: "secondary",
|
|
865
|
+
className: "self-center",
|
|
866
|
+
children: fe
|
|
867
|
+
})
|
|
868
|
+
]
|
|
869
|
+
}), /* @__PURE__ */ W("div", {
|
|
870
|
+
className: "leading-relaxed",
|
|
871
|
+
children: /* @__PURE__ */ W(De, {
|
|
872
|
+
comment: e,
|
|
873
|
+
resources: re,
|
|
874
|
+
renderReference: ie,
|
|
875
|
+
sanitizer: x
|
|
856
876
|
})
|
|
857
|
-
]
|
|
858
|
-
}),
|
|
859
|
-
/* @__PURE__ */ H("div", {
|
|
860
|
-
className: "mt-1 leading-relaxed",
|
|
861
|
-
children: /* @__PURE__ */ H(Te, {
|
|
862
|
-
comment: e,
|
|
863
|
-
resources: ie,
|
|
864
|
-
renderReference: ae,
|
|
865
|
-
sanitizer: x
|
|
866
|
-
})
|
|
877
|
+
})]
|
|
867
878
|
}),
|
|
868
|
-
|
|
879
|
+
V.length > 0 && /* @__PURE__ */ W("div", {
|
|
869
880
|
className: "mt-space-md flex flex-wrap gap-space-sm",
|
|
870
|
-
children:
|
|
881
|
+
children: V.map((e) => /* @__PURE__ */ W(k, {
|
|
871
882
|
size: "sm",
|
|
872
883
|
tone: "secondary",
|
|
873
884
|
children: e
|
|
874
885
|
}, e))
|
|
875
886
|
}),
|
|
876
|
-
Oe && /* @__PURE__ */
|
|
887
|
+
Oe && /* @__PURE__ */ W("div", {
|
|
877
888
|
className: "mt-space-md flex flex-wrap gap-space-sm",
|
|
878
|
-
children:
|
|
879
|
-
if (
|
|
880
|
-
let t = !!
|
|
881
|
-
return /* @__PURE__ */
|
|
889
|
+
children: U.map((e) => {
|
|
890
|
+
if (j) return /* @__PURE__ */ W("div", { children: j(e) }, e.id ?? e.name);
|
|
891
|
+
let t = !!o && !!e.id && J;
|
|
892
|
+
return /* @__PURE__ */ W(be, {
|
|
882
893
|
attachment: e,
|
|
883
894
|
editable: t,
|
|
884
|
-
onRemove: t ? () =>
|
|
895
|
+
onRemove: t ? () => Ee(e.id) : void 0,
|
|
885
896
|
accessors: {
|
|
886
|
-
getMediaUrl:
|
|
887
|
-
getMediaName:
|
|
897
|
+
getMediaUrl: se,
|
|
898
|
+
getMediaName: P
|
|
888
899
|
},
|
|
889
900
|
strings: S
|
|
890
901
|
}, e.id ?? e.name);
|
|
891
902
|
})
|
|
892
903
|
}),
|
|
893
|
-
|
|
904
|
+
le.length > 0 && /* @__PURE__ */ W(m, {
|
|
894
905
|
direction: "horizontal",
|
|
895
906
|
wrap: !0,
|
|
896
907
|
align: "center",
|
|
897
908
|
gap: "xs",
|
|
898
909
|
className: "mt-space-md",
|
|
899
|
-
children:
|
|
910
|
+
children: le.map((t) => /* @__PURE__ */ W("button", {
|
|
900
911
|
type: "button",
|
|
901
|
-
"aria-label": n(
|
|
912
|
+
"aria-label": n(M.reactionLabel ?? X.reactionLabel, {
|
|
902
913
|
emoji: t.emoji,
|
|
903
914
|
count: t.count
|
|
904
915
|
}),
|
|
905
916
|
"aria-pressed": t.mine ?? !1,
|
|
906
917
|
onClick: () => h && e.id ? h(e.id, t.emoji) : void 0,
|
|
907
918
|
title: t.users?.join(", "),
|
|
908
|
-
className: i(
|
|
909
|
-
children: /* @__PURE__ */
|
|
919
|
+
className: i(A.inline, A.focus),
|
|
920
|
+
children: /* @__PURE__ */ G(k, {
|
|
910
921
|
size: "sm",
|
|
911
922
|
tone: t.mine ? "info" : "secondary",
|
|
912
|
-
className: "cursor-pointer transition-colors
|
|
913
|
-
children: [/* @__PURE__ */
|
|
923
|
+
className: "cursor-pointer transition-colors",
|
|
924
|
+
children: [/* @__PURE__ */ W(s, {
|
|
914
925
|
tag: "span",
|
|
915
926
|
size: "inherit",
|
|
916
927
|
lineHeight: "none",
|
|
917
928
|
className: "text-inherit",
|
|
918
929
|
"aria-hidden": !0,
|
|
919
930
|
children: t.emoji
|
|
920
|
-
}), /* @__PURE__ */
|
|
931
|
+
}), /* @__PURE__ */ W(T, {
|
|
921
932
|
value: t.count,
|
|
922
933
|
size: "inherit",
|
|
923
934
|
align: "left",
|
|
@@ -926,86 +937,86 @@ var Ae = "?", je = (e) => e?.url, Me = (e) => e?.name, Ne = (e) => e.charAt(0).t
|
|
|
926
937
|
})
|
|
927
938
|
}, t.emoji))
|
|
928
939
|
}),
|
|
929
|
-
|
|
930
|
-
className: i("comment-item--actions relative mt-space-
|
|
940
|
+
Ce && /* @__PURE__ */ G("div", {
|
|
941
|
+
className: i("comment-item--actions relative mt-space-xs ms-auto w-fit max-w-full flex-wrap opacity-100 transition-opacity", "group-hover:opacity-100 focus-within:opacity-100", "inline-flex items-center gap-space-2xs"),
|
|
931
942
|
children: [
|
|
932
|
-
|
|
943
|
+
Y && /* @__PURE__ */ W(a, {
|
|
933
944
|
type: "button",
|
|
934
945
|
size: "sm",
|
|
935
946
|
iconOnly: !0,
|
|
936
947
|
tone: "secondary",
|
|
937
948
|
buttonStyle: "ghost",
|
|
938
|
-
onClick: () => e.id &&
|
|
939
|
-
title:
|
|
940
|
-
"aria-label":
|
|
941
|
-
children: /* @__PURE__ */
|
|
949
|
+
onClick: () => e.id && g(e.id),
|
|
950
|
+
title: M.replyLabel,
|
|
951
|
+
"aria-label": M.replyLabel,
|
|
952
|
+
children: /* @__PURE__ */ W(ue, { className: "size-icon-md" })
|
|
942
953
|
}),
|
|
943
|
-
|
|
954
|
+
Q && /* @__PURE__ */ W(a, {
|
|
944
955
|
type: "button",
|
|
945
956
|
size: "sm",
|
|
946
957
|
iconOnly: !0,
|
|
947
958
|
tone: "secondary",
|
|
948
959
|
buttonStyle: "ghost",
|
|
949
960
|
onClick: () => e.id && h(e.id, "👍"),
|
|
950
|
-
title:
|
|
951
|
-
"aria-label":
|
|
952
|
-
children: /* @__PURE__ */
|
|
961
|
+
title: M.addReactionLabel,
|
|
962
|
+
"aria-label": M.addReactionLabel,
|
|
963
|
+
children: /* @__PURE__ */ W(ge, { className: "size-icon-md" })
|
|
953
964
|
}),
|
|
954
|
-
|
|
965
|
+
ye && /* @__PURE__ */ W(a, {
|
|
955
966
|
type: "button",
|
|
956
967
|
size: "sm",
|
|
957
968
|
iconOnly: !0,
|
|
958
969
|
tone: "secondary",
|
|
959
970
|
buttonStyle: "ghost",
|
|
960
|
-
onClick: () =>
|
|
961
|
-
title:
|
|
962
|
-
"aria-label":
|
|
963
|
-
children: /* @__PURE__ */
|
|
971
|
+
onClick: () => l(e),
|
|
972
|
+
title: K ? M.unpinLabel : M.pinLabel,
|
|
973
|
+
"aria-label": K ? M.unpinLabel : M.pinLabel,
|
|
974
|
+
children: /* @__PURE__ */ W(he, { className: i("size-icon-md", K && "text-foreground") })
|
|
964
975
|
}),
|
|
965
|
-
|
|
976
|
+
xe && /* @__PURE__ */ W(a, {
|
|
966
977
|
type: "button",
|
|
967
978
|
size: "sm",
|
|
968
979
|
iconOnly: !0,
|
|
969
980
|
tone: "secondary",
|
|
970
981
|
buttonStyle: "ghost",
|
|
971
|
-
title:
|
|
972
|
-
"aria-label":
|
|
973
|
-
onClick: () =>
|
|
974
|
-
children: /* @__PURE__ */
|
|
982
|
+
title: M.editLabel,
|
|
983
|
+
"aria-label": M.editLabel,
|
|
984
|
+
onClick: () => c(e),
|
|
985
|
+
children: /* @__PURE__ */ W(me, { className: "size-icon-md" })
|
|
975
986
|
}),
|
|
976
|
-
|
|
987
|
+
Se && /* @__PURE__ */ W(a, {
|
|
977
988
|
type: "button",
|
|
978
989
|
size: "sm",
|
|
979
990
|
iconOnly: !0,
|
|
980
991
|
tone: "secondary",
|
|
981
992
|
buttonStyle: "ghost",
|
|
982
|
-
className: "hover:
|
|
993
|
+
className: "hover:text-destructive",
|
|
983
994
|
onClick: () => r(e.id),
|
|
984
|
-
title:
|
|
985
|
-
"aria-label":
|
|
986
|
-
children: /* @__PURE__ */
|
|
995
|
+
title: M.deleteLabel,
|
|
996
|
+
"aria-label": M.deleteLabel,
|
|
997
|
+
children: /* @__PURE__ */ W(_e, { className: "size-icon-md" })
|
|
987
998
|
})
|
|
988
999
|
]
|
|
989
1000
|
})
|
|
990
1001
|
]
|
|
991
1002
|
})]
|
|
992
|
-
}), !!
|
|
993
|
-
|
|
1003
|
+
}), !!o && /* @__PURE__ */ W(v, {
|
|
1004
|
+
...$.overlayProps,
|
|
994
1005
|
destructive: !0,
|
|
995
|
-
title:
|
|
996
|
-
description:
|
|
997
|
-
strings: { confirm:
|
|
1006
|
+
title: M.confirmRemoveAttachmentTitle,
|
|
1007
|
+
description: M.confirmRemoveAttachmentDescription,
|
|
1008
|
+
strings: { confirm: M.attachmentRemoveLabel },
|
|
998
1009
|
onConfirm: () => {
|
|
999
|
-
|
|
1010
|
+
we && e.id && o(e.id, we);
|
|
1000
1011
|
}
|
|
1001
1012
|
})]
|
|
1002
1013
|
});
|
|
1003
|
-
}),
|
|
1004
|
-
return e.length ? /* @__PURE__ */
|
|
1014
|
+
}), Le = function({ comments: e, canModerate: t, onDelete: n, onAttachmentRemove: r, onEdit: i, onPinToggle: a, onReact: o, onReply: s, allowReactions: c, allowReplies: l, sanitizer: u, strings: d, getMediaUrl: f, getMediaName: p, getStatusLabel: h, formatRelativeTime: g, resources: _, renderItem: v, renderAttachment: y, renderReference: b, emptySlot: x }) {
|
|
1015
|
+
return e.length ? /* @__PURE__ */ W(m, {
|
|
1005
1016
|
gap: "sm",
|
|
1006
1017
|
className: "comment-timeline--component",
|
|
1007
1018
|
children: e.map((e, m) => {
|
|
1008
|
-
let x = /* @__PURE__ */
|
|
1019
|
+
let x = /* @__PURE__ */ W(Ie, {
|
|
1009
1020
|
comment: e,
|
|
1010
1021
|
canModerate: t,
|
|
1011
1022
|
onDelete: n,
|
|
@@ -1026,27 +1037,27 @@ var Ae = "?", je = (e) => e?.url, Me = (e) => e?.name, Ne = (e) => e.charAt(0).t
|
|
|
1026
1037
|
renderAttachment: y,
|
|
1027
1038
|
renderReference: b
|
|
1028
1039
|
});
|
|
1029
|
-
return v ? /* @__PURE__ */
|
|
1040
|
+
return v ? /* @__PURE__ */ W("div", { children: v({
|
|
1030
1041
|
comment: e,
|
|
1031
1042
|
canModerate: t ?? !1,
|
|
1032
1043
|
onDelete: n,
|
|
1033
1044
|
onAttachmentRemove: r,
|
|
1034
1045
|
onEdit: i,
|
|
1035
1046
|
defaultItem: x
|
|
1036
|
-
}) }, e.id ?? `comment-${m}`) : /* @__PURE__ */
|
|
1047
|
+
}) }, e.id ?? `comment-${m}`) : /* @__PURE__ */ W("div", { children: x }, e.id ?? `comment-${m}`);
|
|
1037
1048
|
})
|
|
1038
|
-
}) : /* @__PURE__ */
|
|
1049
|
+
}) : /* @__PURE__ */ W(U, { children: x ?? /* @__PURE__ */ W(Ee, { strings: d }) });
|
|
1039
1050
|
};
|
|
1040
1051
|
//#endregion
|
|
1041
1052
|
//#region src/components/features/comments/comments.tsx
|
|
1042
|
-
function
|
|
1043
|
-
let n = e(), r = t.composerPosition ?? n.composerPosition ?? "top", a = t.maxAttachments ?? 5, o = t.allowAttachments ?? !0, c = t.allowReactions ?? !0, l = t.allowReplies ?? !0, u = t.canComment ?? !1, d = t.canModerate ?? !1, f = t.onPinToggle, p = t.resources, h = t.attachments,
|
|
1053
|
+
function Re(t) {
|
|
1054
|
+
let n = e(), r = t.composerPosition ?? n.composerPosition ?? "top", a = t.maxAttachments ?? 5, o = t.allowAttachments ?? !0, c = t.allowReactions ?? !0, l = t.allowReplies ?? !0, u = t.canComment ?? !1, d = t.canModerate ?? !1, f = t.onPinToggle, p = t.resources, h = t.attachments, g = Z(t.strings), y = t.title === void 0 ? g.title : t.title, b = t.confirmDelete ?? !0, x = _(), [S, C] = H(null), w = Q({
|
|
1044
1055
|
onSubmit: t.onSubmit,
|
|
1045
1056
|
onUpdate: t.onUpdate,
|
|
1046
1057
|
onDelete: t.onDelete,
|
|
1047
1058
|
onAfterMutate: t.onAfterMutate,
|
|
1048
1059
|
onError: t.onError
|
|
1049
|
-
}), ee =
|
|
1060
|
+
}), ee = R((e) => {
|
|
1050
1061
|
if (!b) {
|
|
1051
1062
|
w.deleteComment(e);
|
|
1052
1063
|
return;
|
|
@@ -1056,24 +1067,24 @@ function Ie(t) {
|
|
|
1056
1067
|
b,
|
|
1057
1068
|
w,
|
|
1058
1069
|
x
|
|
1059
|
-
]), T = w.startReply, E = t.comments, D = t.onReply, O =
|
|
1070
|
+
]), T = w.startReply, E = t.comments, D = t.onReply, O = R((e) => {
|
|
1060
1071
|
let t = E.find((t) => t.id === e);
|
|
1061
1072
|
t && T(t), D?.(e);
|
|
1062
1073
|
}, [
|
|
1063
1074
|
E,
|
|
1064
1075
|
D,
|
|
1065
1076
|
T
|
|
1066
|
-
]),
|
|
1077
|
+
]), te = w.composerMode.kind === "editing" ? w.composerMode.comment : void 0, k = w.composerMode.kind === "replying" ? {
|
|
1067
1078
|
commentId: w.composerMode.commentId,
|
|
1068
1079
|
authorName: w.composerMode.authorName
|
|
1069
|
-
} : void 0,
|
|
1080
|
+
} : void 0, A = t.composerSlot ?? (u ? /* @__PURE__ */ W($, {
|
|
1070
1081
|
context: t.context,
|
|
1071
1082
|
canComment: u,
|
|
1072
1083
|
submitting: w.isSubmitting,
|
|
1073
1084
|
errors: w.formErrors,
|
|
1074
1085
|
resetKey: w.resetKey,
|
|
1075
|
-
editingComment:
|
|
1076
|
-
replyingTo:
|
|
1086
|
+
editingComment: te,
|
|
1087
|
+
replyingTo: k,
|
|
1077
1088
|
onCancel: w.composerMode.kind === "idle" ? void 0 : w.cancelComposerMode,
|
|
1078
1089
|
onSubmit: w.submit,
|
|
1079
1090
|
strings: t.strings,
|
|
@@ -1082,7 +1093,7 @@ function Ie(t) {
|
|
|
1082
1093
|
attachments: h,
|
|
1083
1094
|
maxAttachments: a,
|
|
1084
1095
|
allowAttachments: o
|
|
1085
|
-
}) : null),
|
|
1096
|
+
}) : null), ne = /* @__PURE__ */ W(Le, {
|
|
1086
1097
|
comments: t.comments,
|
|
1087
1098
|
canModerate: d,
|
|
1088
1099
|
onDelete: t.onDelete ? ee : void 0,
|
|
@@ -1103,46 +1114,46 @@ function Ie(t) {
|
|
|
1103
1114
|
renderItem: t.renderItem,
|
|
1104
1115
|
renderAttachment: t.renderAttachment,
|
|
1105
1116
|
renderReference: t.renderReference,
|
|
1106
|
-
emptySlot: t.emptySlot ?? /* @__PURE__ */
|
|
1107
|
-
}),
|
|
1117
|
+
emptySlot: t.emptySlot ?? /* @__PURE__ */ W(Ee, { strings: t.strings })
|
|
1118
|
+
}), re = A ? /* @__PURE__ */ W("div", { children: A }) : null, j = /* @__PURE__ */ G(m, {
|
|
1108
1119
|
gap: "xl",
|
|
1109
1120
|
className: "comments--body",
|
|
1110
1121
|
children: [
|
|
1111
1122
|
t.headerSlot,
|
|
1112
|
-
r === "top" &&
|
|
1113
|
-
|
|
1114
|
-
r === "bottom" &&
|
|
1123
|
+
r === "top" && re,
|
|
1124
|
+
ne,
|
|
1125
|
+
r === "bottom" && re,
|
|
1115
1126
|
t.footerSlot
|
|
1116
1127
|
]
|
|
1117
1128
|
});
|
|
1118
|
-
if (t.bare) return
|
|
1119
|
-
let
|
|
1120
|
-
return /* @__PURE__ */
|
|
1121
|
-
render: /* @__PURE__ */
|
|
1129
|
+
if (t.bare) return j;
|
|
1130
|
+
let ie = typeof y == "string" ? y : void 0;
|
|
1131
|
+
return /* @__PURE__ */ G(m, {
|
|
1132
|
+
render: /* @__PURE__ */ W("section", {}),
|
|
1122
1133
|
gap: "lg",
|
|
1123
1134
|
"data-component": "comments",
|
|
1124
1135
|
"data-slot": "comments",
|
|
1125
1136
|
className: i("comments--component", t.className),
|
|
1126
|
-
"aria-label":
|
|
1137
|
+
"aria-label": ie,
|
|
1127
1138
|
children: [
|
|
1128
|
-
!(y === !1 || !y && !
|
|
1139
|
+
!(y === !1 || !y && !g.subtitle) && /* @__PURE__ */ G(m, {
|
|
1129
1140
|
gap: "normal",
|
|
1130
1141
|
className: "comments--header",
|
|
1131
|
-
children: [!!y && /* @__PURE__ */
|
|
1142
|
+
children: [!!y && /* @__PURE__ */ W(s, {
|
|
1132
1143
|
weight: "semibold",
|
|
1133
1144
|
children: y
|
|
1134
|
-
}), !!
|
|
1145
|
+
}), !!g.subtitle && /* @__PURE__ */ W(s, {
|
|
1135
1146
|
type: "secondary",
|
|
1136
|
-
children:
|
|
1147
|
+
children: g.subtitle
|
|
1137
1148
|
})]
|
|
1138
1149
|
}),
|
|
1139
|
-
|
|
1140
|
-
!!(b && t.onDelete) && /* @__PURE__ */
|
|
1150
|
+
j,
|
|
1151
|
+
!!(b && t.onDelete) && /* @__PURE__ */ W(v, {
|
|
1141
1152
|
...x.overlayProps,
|
|
1142
1153
|
destructive: !0,
|
|
1143
|
-
title:
|
|
1144
|
-
description:
|
|
1145
|
-
strings: { confirm:
|
|
1154
|
+
title: g.confirmDeleteTitle,
|
|
1155
|
+
description: g.confirmDeleteDescription,
|
|
1156
|
+
strings: { confirm: g.confirmDeleteLabel },
|
|
1146
1157
|
onAsyncConfirm: async () => {
|
|
1147
1158
|
S && await w.deleteComment(S);
|
|
1148
1159
|
},
|
|
@@ -1152,6 +1163,6 @@ function Ie(t) {
|
|
|
1152
1163
|
});
|
|
1153
1164
|
}
|
|
1154
1165
|
//#endregion
|
|
1155
|
-
export {
|
|
1166
|
+
export { Ee as a, Se as c, ve as d, Z as f, De as i, be as l, Le as n, $ as o, X as p, Ie as r, Te as s, Re as t, Q as u };
|
|
1156
1167
|
|
|
1157
|
-
//# sourceMappingURL=comments-
|
|
1168
|
+
//# sourceMappingURL=comments-BYYlTA8E.js.map
|